/* AVTOMATIK YARATILGAN — tools/gen_tokens.py. Qo'lda tahrirlanmaydi. */
/* CorelMed dizayn tizimi, tokens.json v1 */

@font-face { font-family: "Piazzolla"; src: url("/fonts/Piazzolla-Variable.woff2") format("woff2"); font-weight: 100 900; font-style: normal; font-display: swap; }
@font-face { font-family: "Piazzolla"; src: url("/fonts/Piazzolla-Italic-Variable.woff2") format("woff2"); font-weight: 100 900; font-style: italic; font-display: swap; }
@font-face { font-family: "Onest"; src: url("/fonts/Onest-Variable.woff2") format("woff2"); font-weight: 100 900; font-style: normal; font-display: swap; }
@font-face { font-family: "Geist Mono"; src: url("/fonts/GeistMono-Variable.woff2") format("woff2"); font-weight: 100 900; font-style: normal; font-display: swap; }

:root, [data-theme="tun"] {
  --surface-000: #0a1315;
  --surface-100: #0f1c1f;
  --surface-200: #16272a;
  --line: #233a3e;
  --line-strong: #5d7f82;
  --ink: #ede6d8;
  --ink-muted: #9fb1ae;
  --ink-faint: #6f8683;
  --brand: #ad1d1d;
  --brand-hover: #c52626;
  --on-brand: #ffffff;
  --teal: #e8635b;
  --teal-soft: #3a0b0b;
  --lamp: #f4b651;
  --lamp-ink: #f4b651;
  --on-lamp: #1f1403;
  --lamp-soft: #2d2412;
  --lamp-glow: #f4b65129;
  --page: #0f181a;
  --page-ink: #dcd4c4;
  --page-ink-muted: #93a39f;
  --watermark: #ede6d812;
  --success: #8fd6a8;
  --success-soft: #12301f;
  --danger: #ff9d8c;
  --danger-soft: #3a1814;
  --cover-1: #ad1d1d;
  --cover-2: #6e2d3b;
  --cover-3: #2c4a6e;
  --cover-4: #5b4a1c;
  --cover-5: #40395e;
  --cover-6: #7b3b1b;
  --cover-ink: #f3ecdd;
  --link: var(--teal);
  --focus: var(--lamp);
  --shadow-book: 0 2px 4px #00000099, 0 14px 28px -12px #000000cc;
  --shadow-float: 0 20px 48px -12px #000000e6;
  --focus-ring: 0 0 0 2px #0a1315, 0 0 0 4px #f4b651;
}

[data-theme="kun"] {
  --surface-000: #f4efe6;
  --surface-100: #fbf8f2;
  --surface-200: #ffffff;
  --line: #e3dccf;
  --line-strong: #74827f;
  --ink: #182224;
  --ink-muted: #556360;
  --ink-faint: #7d8986;
  --brand: #ad1d1d;
  --brand-hover: #8e1717;
  --on-brand: #ffffff;
  --teal: #ad1d1d;
  --teal-soft: #f7e2e0;
  --lamp: #bf7a1a;
  --lamp-ink: #8a4f00;
  --on-lamp: #1f1403;
  --lamp-soft: #fbecd2;
  --lamp-glow: #bf7a1a1f;
  --page: #faf5ea;
  --page-ink: #2a2620;
  --page-ink-muted: #6b6356;
  --watermark: #1b24260f;
  --success: #1e6b3e;
  --success-soft: #dff0e4;
  --danger: #b3261e;
  --danger-soft: #f9e1dd;
  --cover-1: #ad1d1d;
  --cover-2: #6e2d3b;
  --cover-3: #2c4a6e;
  --cover-4: #5b4a1c;
  --cover-5: #40395e;
  --cover-6: #7b3b1b;
  --cover-ink: #f3ecdd;
  --link: var(--teal);
  --focus: var(--brand);
  --shadow-book: 0 2px 4px #3a2a1426, 0 14px 28px -14px #3a2a1466;
  --shadow-float: 0 20px 48px -16px #3a2a1440;
  --focus-ring: 0 0 0 2px #f4efe6, 0 0 0 4px #ad1d1d;
}

:root {
  --font-serif: Piazzolla, "PT Serif", Georgia, serif;
  --font-sans: Onest, "Segoe UI", system-ui, sans-serif;
  --font-mono: "Geist Mono", ui-monospace, Menlo, monospace;
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  --space-6: 32px;
  --space-7: 48px;
  --space-8: 64px;
  --space-9: 96px;
  --radius-xs: 3px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-full: 9999px;
  --size-touch: 44px;
  --size-cover-sm: 56px;
  --size-cover-md: 132px;
  --size-cover-lg: 184px;
  --size-measure: 36em;
  --size-page: 1200px;
  --size-tabbar: 64px;
}

/* Matn uslublari — tokens.json dagi type.groups */
/* Sarlavhalar — Piazzolla, opsz 24–30: oʻtkir, kesilgan uchlar — kitob ruhi */
.display { font-family: var(--font-serif); font-size: 56px; line-height: 60px; font-weight: 600; letter-spacing: -0.02em; font-variation-settings: 'opsz' 30; }
.title-1 { font-family: var(--font-serif); font-size: 36px; line-height: 42px; font-weight: 600; letter-spacing: -0.015em; font-variation-settings: 'opsz' 30; }
.title-2 { font-family: var(--font-serif); font-size: 24px; line-height: 30px; font-weight: 600; letter-spacing: -0.01em; font-variation-settings: 'opsz' 24; }
.title-3 { font-family: var(--font-serif); font-size: 19px; line-height: 24px; font-weight: 600; font-variation-settings: 'opsz' 20; }

/* Interfeys — Onest — interfeys, tugmalar, forma */
.ui-lg { font-family: var(--font-sans); font-size: 18px; line-height: 26px; font-weight: 500; }
.body { font-family: var(--font-sans); font-size: 16px; line-height: 24px; font-weight: 400; }
.body-sm { font-family: var(--font-sans); font-size: 14px; line-height: 20px; font-weight: 400; }
.label { font-family: var(--font-sans); font-size: 15px; line-height: 20px; font-weight: 600; }

/* Oʻqish — Reader matni: Piazzolla opsz 14 — kichik oʻlchamda ham ochiq */
.reading { font-family: var(--font-serif); font-size: 19px; line-height: 31px; font-weight: 400; font-variation-settings: 'opsz' 14; }
.footnote { font-family: var(--font-serif); font-size: 14px; line-height: 21px; font-weight: 400; font-style: italic; font-variation-settings: 'opsz' 10; }

/* Jurnal — Geist Mono — smena jurnali: vaqt, bet, foiz, kod */
.stamp { font-family: var(--font-mono); font-size: 12px; line-height: 16px; font-weight: 500; letter-spacing: 0.06em; }
.code { font-family: var(--font-mono); font-size: 22px; line-height: 28px; font-weight: 500; letter-spacing: 0.12em; }

