/* ==========================================================================
   Improve design tokens: "Forest Calm" (Dec 2026 overhaul). One dark theme: deep forest greens,
   warm cream text, gold accent, teal water. Components only use these vars.
   .paper (food + journal detail cards) swaps in a light "paper on the table" set.
   ========================================================================== */

/* Self-hosted so the app works offline (all SIL Open Font License 1.1):
   Fraunces for big numbers and titles, Nunito Sans for everything else, Nunito for journal writing. */
@font-face { font-family: Fraunces; font-style: normal; font-weight: 600 900; font-display: swap; src: url(../fonts/fraunces-latin-var.woff2) format('woff2'); }
@font-face { font-family: 'Nunito Sans'; font-style: normal; font-weight: 400 900; font-display: swap; src: url(../fonts/nunito-sans-latin-var.woff2) format('woff2'); }
@font-face { font-family: Nunito; font-style: normal; font-weight: 400 800; font-display: swap; src: url(../fonts/nunito-latin-var.woff2) format('woff2'); }

:root, :root[data-theme="dark"], :root[data-theme="light"] {
  color-scheme: dark;

  /* Surfaces */
  --imp-bg: #0d1813;
  --imp-surface: #15261e;
  --imp-surface-2: #193027;
  --imp-sunken: #0f1d17;
  --imp-frame: #26402f;
  --imp-divider: #1f3529;
  --imp-shadow: 0 1px 0 rgba(255, 255, 255, .03) inset, 0 2px 8px rgba(0, 0, 0, .35);
  --imp-shadow-lg: 0 20px 48px rgba(0, 0, 0, .55), 0 0 0 1px rgba(232, 176, 74, .08);

  /* Accent (gold) */
  --imp-accent: #e8b04a;
  --imp-accent-dim: rgba(232, 176, 74, .16);
  --imp-accent-deep: #c9932e;
  --imp-on-accent: #14261f;

  /* Text */
  --imp-text: #f2ecdc;
  --imp-muted: #a9b5a3;
  --imp-faint: #6f8273;

  /* Food: protein coral, water teal */
  --imp-protein: #f08a62;
  --imp-protein-deep: #d06a42;
  --imp-water: #5eead4;

  /* Old planner categories (unused, kept for old screens) */
  --imp-cat-online: #60a5fa;
  --imp-cat-online-missing: #a78bfa;
  --imp-cat-paper: #34d399;
  --imp-cat-paper-missing: #2dd4bf;
  --imp-cat-other: #fbbf24;

  /* Status */
  --imp-good: #7bd88f;
  --imp-danger: #f07a5f;
  --imp-danger-deep: #d0543a;
  --imp-warn: #f3c969;

  /* Type */
  --imp-font-display: Fraunces, Georgia, serif;
  --imp-font-head: 'Nunito Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --imp-font-body: 'Nunito Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --imp-font-hand: Nunito, 'Nunito Sans', sans-serif;
  --imp-font-emoji: 'Apple Color Emoji', 'Segoe UI Emoji', 'Noto Color Emoji', sans-serif;
  --imp-fs-xs: 12px;
  --imp-fs-sm: 14px;
  --imp-fs-md: 20px;
  --imp-fs-body: 16px;
  --imp-fs-body-lg: 16px;

  /* Shape + spacing */
  --imp-px: 1px;
  --imp-radius: 18px;
  --imp-radius-sm: 12px;
  --imp-gap: 16px;
  --imp-pad: 16px;
  --imp-gutter: 16px;
  --imp-tabbar-h: 0px;

  /* Motion */
  --imp-ease: cubic-bezier(.2, .8, .2, 1);
  --imp-steps: var(--imp-ease);
}

/* Paper: cards that sit on the food table or the journal desk */
.paper {
  color-scheme: light;
  --imp-surface: #f6efdd;
  --imp-surface-2: #efe5cc;
  --imp-sunken: #e6dbc0;
  --imp-frame: #d9cbab;
  --imp-divider: #e4d8bc;
  --imp-shadow: 0 1px 0 rgba(255, 255, 255, .6) inset, 0 6px 16px rgba(0, 0, 0, .35);
  --imp-accent: #2f5a3c;
  --imp-accent-dim: rgba(47, 90, 60, .12);
  --imp-accent-deep: #22452d;
  --imp-on-accent: #f6efdd;
  --imp-text: #1f2a22;
  --imp-muted: #5f6b5c;
  --imp-faint: #8f977f;
  --imp-protein: #c2562b;
  --imp-protein-deep: #9c4220;
  --imp-water: #0f766e;
  --imp-good: #2f7a3d;
  --imp-danger: #b4402a;
  --imp-warn: #b7791f;
  color: var(--imp-text);
}
