/* jckbn-ui — Foundation (Tokens, Typo, Reset)
 * Geteilt zwischen share.jckbn.de und cook.jckbn.de
 * Kanonische Quelle: K:\_space\_dev\JckbnDe\shared\jckbn-ui\
 */

@font-face {
  font-family: 'Ysabeau SC';
  src: url('fonts/ysabeau.woff2') format('woff2-variations'),
       url('fonts/ysabeau.woff2') format('woff2');
  font-weight: 100 1000;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Inconsolata';
  src: url('fonts/inconsolata.woff2') format('woff2-variations'),
       url('fonts/inconsolata.woff2') format('woff2');
  font-weight: 200 900;
  font-display: swap;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

:root {
  /* Farb-Tokens */
  --bg: #fefbf9;
  --surface: #fff;
  --surface2: #f1f1f1;
  --border: #282828;
  --text: #282828;
  --text2: #666;
  --text3: #999;
  --accent: #8b0000;
  --gold: #CFB53B;

  /* Typo */
  --font-sans: 'Ysabeau SC', BlinkMacSystemFont, -apple-system, sans-serif;
  --font-mono: 'Inconsolata', ui-monospace, SFMono-Regular, monospace;

  /* Touch-Targets (Apple HIG: min 44pt) */
  --touch-min: 44px;

  /* Safe-area-insets (iOS notch / home indicator) */
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-left: env(safe-area-inset-left, 0px);
  --safe-right: env(safe-area-inset-right, 0px);

  /* Radii, Schatten */
  --radius: 0;
  --shadow-sheet: 0 -2px 16px rgba(0, 0, 0, .12);
  --shadow-dialog: 2px 2px 8px rgba(0, 0, 0, .15);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #282828;
    --surface: #333;
    --surface2: #444;
    --border: #CFB53B;
    --text: #eee;
    --text2: #ccc;
    --text3: #888;
    --accent: #CFB53B;
    --gold: #E6BE8A;
    --shadow-sheet: 0 -2px 16px rgba(0, 0, 0, .4);
    --shadow-dialog: 2px 2px 8px rgba(0, 0, 0, .35);
  }
}

html, body {
  background: var(--bg);
  color: var(--text);
}
body {
  font-family: var(--font-sans);
  min-height: 100vh;
  /* iOS Safari dvh berücksichtigt dynamische URL-Bar */
  min-height: 100dvh;
}

/* Selection-Farbe */
::selection { background: var(--accent); color: var(--bg); }
