/* Design tokens. Names mirror the Android palette (ui/theme/Color.kt) so themes port 1:1.
   themes.css overrides these per [data-theme]; dark mode swaps them under .dark / prefers-color-scheme. */
@font-face { font-family: "Poppins"; src: url("../assets/fonts/poppins_regular.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Poppins"; src: url("../assets/fonts/poppins_semibold.woff2") format("woff2"); font-weight: 600 700; font-display: swap; }
@font-face { font-family: "Cormorant"; src: url("../assets/fonts/cormorant.woff2") format("woff2"); font-weight: 300 700; font-display: swap; }
@font-face { font-family: "Noto Sans Devanagari"; src: url("../assets/fonts/noto_sans_devanagari.woff2") format("woff2"); font-weight: 100 900; font-display: swap; unicode-range: U+0900-097F, U+1CD0-1CFF, U+A8E0-A8FF; }
@font-face { font-family: "Noto Sans Gujarati"; src: url("../assets/fonts/noto_sans_gujarati.woff2") format("woff2"); font-weight: 100 900; font-display: swap; unicode-range: U+0A80-0AFF; }

:root {
  --sand: #fbf4e9;  --sand-deep: #f2e6d4;  --cream: #fffdf8;  --card: #fffbf3;
  --plum: #805298;  --plum-deep: #574168;  --lavender: #b89bc7;  --lavender-soft: #eadcef;
  --blossom: #b0658f;  --blossom-soft: #f6e4ee;
  --sage: #7ba762;  --sage-deep: #5c7850;  --sage-soft: #e7efdf;
  --gold: #cba45c;  --gold-deep: #a97f36;
  --ink: #453a42;  --ink-soft: #5f5159;  --ink-faint: #6f616a;
  --danger: #b0453b;  --danger-bg: #f8e5e1;  --caution: #b9832c;  --caution-bg: #f8efd8;
  --good: #5c7850;  --good-bg: #e7efdf;
  --outline: #d8c9b8;  --outline-soft: #e8dccb;
  --on-plum: #ffffff;  --on-sage: #ffffff;  --on-gold: #2b2118;  --on-danger: #ffffff;

  /* Generic names used by area-care.css and area-health.css. They point at the palette above, so those areas follow the
     chosen theme and dark mode. Declared on :root with var(), so they resolve against whatever --plum etc. currently hold. */
  --primary: var(--plum);  --on-primary: var(--on-plum);  --accent: var(--plum);
  --bg: var(--cream);  --surface: var(--card);  --surface-2: var(--sand-deep);
  --text: var(--ink);  --text-muted: var(--ink-soft);  --border: var(--outline);  --success: var(--good);

  --font-body: "Poppins", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-display: "Cormorant", Georgia, "Times New Roman", serif;
  --font-indic: "Noto Sans Devanagari", "Noto Sans Gujarati", "Nirmala UI", "Mangal", "Shruti", sans-serif;
  --font-scale: 1;

  --radius-s: 8px;  --radius: 14px;  --radius-l: 22px;
  --space-1: 4px;  --space-2: 8px;  --space-3: 12px;  --space-4: 16px;  --space-5: 24px;  --space-6: 32px;
  --shadow-1: 0 1px 2px rgb(60 40 50 / 10%), 0 2px 8px rgb(60 40 50 / 6%);
  --shadow-2: 0 4px 18px rgb(60 40 50 / 16%);
  --nav-w: 244px;  --topbar-h: 58px;  --bottombar-h: 62px;
  --focus-ring: #805298;
  --focus: 0 0 0 3px var(--focus-ring);
  --backdrop: none;
  --backdrop-alpha: .12;
}

:root[data-mode="dark"] { color-scheme: dark; }

@media (prefers-color-scheme: dark) {
  :root:not([data-mode="light"]) {
    color-scheme: dark;
    --sand: #1f1a1d;  --sand-deep: #171316;  --cream: #262024;  --card: #2c252a;
    --plum: #d8b4ea;  --plum-deep: #ecd9f6;  --lavender: #a486b5;  --lavender-soft: #3b2f44;
    --blossom: #f0a3c9;  --blossom-soft: #46293a;
    --sage: #9ccb84;  --sage-deep: #b6dc9f;  --sage-soft: #29331f;
    --gold: #d8b468;  --gold-deep: #e6c47c;
    --ink: #f3ece6;  --ink-soft: #d6cbc7;  --ink-faint: #b3a7a8;
    --danger: #ff9a8d;  --danger-bg: #4a2622;  --caution: #e8b866;  --caution-bg: #40331b;
    --good: #a8d48f;  --good-bg: #26331f;
    --outline: #5a4d55;  --outline-soft: #443a41;
    --on-plum: #2a1a33;  --on-sage: #14210d;  --on-gold: #241a08;  --on-danger: #2c0b07;
    --shadow-1: 0 1px 2px rgb(0 0 0 / 40%);
    --shadow-2: 0 6px 24px rgb(0 0 0 / 50%);
    --focus-ring: #d8b4ea;
    --focus: 0 0 0 3px var(--focus-ring);
  }
}
:root[data-mode="dark"] {
  --sand: #1f1a1d;  --sand-deep: #171316;  --cream: #262024;  --card: #2c252a;
  --plum: #d8b4ea;  --plum-deep: #ecd9f6;  --lavender: #a486b5;  --lavender-soft: #3b2f44;
  --blossom: #f0a3c9;  --blossom-soft: #46293a;
  --sage: #9ccb84;  --sage-deep: #b6dc9f;  --sage-soft: #29331f;
  --gold: #d8b468;  --gold-deep: #e6c47c;
  --ink: #f3ece6;  --ink-soft: #d6cbc7;  --ink-faint: #b3a7a8;
  --danger: #ff9a8d;  --danger-bg: #4a2622;  --caution: #e8b866;  --caution-bg: #40331b;
  --good: #a8d48f;  --good-bg: #26331f;
  --outline: #5a4d55;  --outline-soft: #443a41;
  --on-plum: #2a1a33;  --on-sage: #14210d;  --on-gold: #241a08;  --on-danger: #2c0b07;
  --shadow-1: 0 1px 2px rgb(0 0 0 / 40%);
  --shadow-2: 0 6px 24px rgb(0 0 0 / 50%);
  --focus-ring: #d8b4ea;
  --focus: 0 0 0 3px var(--focus-ring);
}
