/* ==========================================================================
   Papan Kita — "Sky" theme (v2)
   A Bootstrap 5.3 theme. Load AFTER bootstrap.min.css.
   Spec: docs/design-system.md · Measured palette: docs/brand/palette-v2.json
   Rules: no inline styles (CSP style-src 'self'); every colour is a token.
   The living style guide (Areas/Template, /template) renders with this same file, so it never drifts from the app.
   ========================================================================== */

/* Fonts are self-hosted (CSP font-src 'self'). SIL OFL 1.1 — see lib/inter and lib/jetbrains-mono. */
@font-face {
  font-family: "Inter Variable"; font-style: normal; font-display: swap; font-weight: 100 900;
  src: url(../lib/inter/inter-latin-wght-normal.woff2) format("woff2-variations"), url(../lib/inter/inter-latin-wght-normal.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Inter Variable"; font-style: normal; font-display: swap; font-weight: 100 900;
  src: url(../lib/inter/inter-latin-ext-wght-normal.woff2) format("woff2-variations"), url(../lib/inter/inter-latin-ext-wght-normal.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "JetBrains Mono Variable"; font-style: normal; font-display: swap; font-weight: 100 800;
  src: url(../lib/jetbrains-mono/jetbrains-mono-latin-wght-normal.woff2) format("woff2-variations"), url(../lib/jetbrains-mono/jetbrains-mono-latin-wght-normal.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* --------------------------------------------------------------------------
   1. Tokens — light
   -------------------------------------------------------------------------- */
:root,
[data-bs-theme="light"] {
  /* Paper & ink */
  --paper: #f5f6f7;          /* page */
  --paper-2: #eceef0;        /* stat panel, chip fill, out-of-month */
  --paper-3: #e1e4e7;        /* pressed fill, track */
  --surface: #ffffff;        /* cards */
  --ink: #02070a;            /* text, primary button */
  --ink-2: #4a5359;          /* secondary text */
  --ink-3: #5f686e;          /* tertiary text, eyebrows, meta */
  --line: rgba(2, 7, 10, .08);        /* decorative hairlines */
  --line-strong: rgba(2, 7, 10, .15); /* dividers that matter */
  --input-border: #858e94;   /* 3.34:1 on surface — WCAG 1.4.11 */

  /* Sky (brand) */
  --blue: #0297de;           /* graphics only: progress, dots, icons (3.24:1) */
  --blue-strong: #0278b3;    /* focus ring, Task colour */
  --blue-ink: #0270a8;       /* link text (5.4:1) */
  --blue-soft: #b5e1f6;
  --blue-wash: #e7f4fb;
  --sky-1: #7fd3fa;
  --sky-2: #0297de;
  --sky-3: #0b4a7a;

  /* The one warm signal: "this needs you" */
  --orange: #fc734d;         /* fill behind ink text, or a decorative dot */
  --orange-ink: #b4401c;     /* text-safe sibling */
  --orange-wash: #ffefe9;

  /* Status */
  --mint: #34c38f;           /* done (fill behind ink text) */
  --mint-ink: #0f7a52;
  --mint-wash: #e3f6ef;
  --danger: #c8302a;
  --danger-wash: #fdecea;

  /* Information categories: colour + icon + word, always together */
  --cat-task: #0278b3;         --cat-task-ink: #035a87;         --cat-task-tint: #e7f4fb;
  --cat-event: #0f8a6a;        --cat-event-ink: #0a5e48;        --cat-event-tint: #e3f6ef;
  --cat-exam: #7c5cd6;         --cat-exam-ink: #5232b0;         --cat-exam-tint: #f0ecfb;
  --cat-announcement: #6b7680; --cat-announcement-ink: #4a5359; --cat-announcement-tint: #eceef0;
  --cat-notice: #d0342c;       --cat-notice-ink: #a3221b;       --cat-notice-tint: #fdecea;

  /* Glass */
  --glass-tint: rgba(255, 255, 255, .72);
  --glass-tint-thick: rgba(255, 255, 255, .9);
  --glass-rim: rgba(255, 255, 255, .9);
  --glass-inner: rgba(255, 255, 255, .4);
  --glass-edge: rgba(2, 7, 10, .07);
  --glass-shadow: 0 10px 30px -14px rgba(2, 7, 10, .22), 0 1px 3px rgba(2, 7, 10, .06);

  /* Elevation */
  --shadow-1: 0 1px 2px rgba(2, 7, 10, .05);
  --shadow-2: 0 2px 4px rgba(2, 7, 10, .03), 0 14px 34px -12px rgba(2, 7, 10, .16);
  --shadow-3: 0 4px 10px rgba(2, 7, 10, .04), 0 36px 70px -22px rgba(2, 7, 10, .3);

  /* Shape */
  --r-xs: 8px;    /* tags inside cards */
  --r-sm: 10px;   /* compact buttons, inputs on desktop */
  --r-md: 14px;   /* inputs, list tiles */
  --r-lg: 1rem;   /* inner panels */
  --r-xl: 1.5rem; /* cards */
  --r-2xl: 2rem;  /* hero, sheets */
  --r-pill: 999px;

  /* Motion */
  --ease-out: cubic-bezier(.22, 1, .36, 1);
  --ease-in-out: cubic-bezier(.4, 0, .2, 1);
  --ease-spring: linear(0, .006, .025 2.8%, .101 6.1%, .539 18.9%, .721 25.3%, .849 31.5%, .937 38.1%, .968 41.8%, .991 45.7%, 1.006 50.1%, 1.015 55%, 1.017 63.9%, 1.001 85%, 1);
  --dur-press: 120ms;
  --dur-fast: 150ms;
  --dur-base: 240ms;
  --dur-reveal: 640ms;

  /* Layout */
  --gutter: clamp(1rem, .6rem + 1.8vw, 2.5rem);
  --nav-h: 76px;
  --tabbar-h: 64px;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --target: 44px;

  /* Type */
  --font-sans: "Inter Variable", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: "JetBrains Mono Variable", "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  color-scheme: light;
}

/* --------------------------------------------------------------------------
   1b. Tokens — dark (explicit choice, or system when not forced light)
   -------------------------------------------------------------------------- */
[data-bs-theme="dark"] {
  --paper: #02070a; --paper-2: #0b151b; --paper-3: #142128; --surface: #0a1318;
  --ink: #f3f6f8; --ink-2: #a8b2b8; --ink-3: #8a959c;
  --line: rgba(255, 255, 255, .09); --line-strong: rgba(255, 255, 255, .17);
  --input-border: #5b666d;
  --blue: #29aaea; --blue-strong: #29aaea; --blue-ink: #5cc0f0; --blue-soft: #0d3b55; --blue-wash: rgba(2, 151, 222, .16);
  --sky-1: #c8eeff; --sky-2: #4cc0f6; --sky-3: #0297de;
  --orange-ink: #ff9b7a; --orange-wash: rgba(252, 115, 77, .14);
  --mint-ink: #5ad6a6; --mint-wash: rgba(52, 195, 143, .14);
  --danger: #ff7a70; --danger-wash: rgba(255, 122, 112, .12);
  --cat-task: #7cc9ef;         --cat-task-ink: #7cc9ef;         --cat-task-tint: #0d2533;
  --cat-event: #5ad6a6;        --cat-event-ink: #5ad6a6;        --cat-event-tint: #0b2620;
  --cat-exam: #b9a5f5;         --cat-exam-ink: #b9a5f5;         --cat-exam-tint: #1d1838;
  --cat-announcement: #a8b2b8; --cat-announcement-ink: #a8b2b8; --cat-announcement-tint: #142128;
  --cat-notice: #ff9b93;       --cat-notice-ink: #ff9b93;       --cat-notice-tint: #2e1514;
  --glass-tint: rgba(14, 24, 30, .55); --glass-tint-thick: rgba(10, 19, 24, .9);
  --glass-rim: rgba(255, 255, 255, .14); --glass-inner: rgba(255, 255, 255, .05);
  --glass-edge: rgba(0, 0, 0, .5); --glass-shadow: 0 10px 30px -14px rgba(0, 0, 0, .7);
  --shadow-1: 0 1px 2px rgba(0, 0, 0, .4);
  --shadow-2: 0 14px 34px -12px rgba(0, 0, 0, .6);
  --shadow-3: 0 36px 70px -22px rgba(0, 0, 0, .8);
  color-scheme: dark;
}

/* --------------------------------------------------------------------------
   2. Bootstrap remap — framework parts pick up the tokens
   -------------------------------------------------------------------------- */
:root, [data-bs-theme] {
  --bs-font-sans-serif: var(--font-sans);
  --bs-font-monospace: var(--font-mono);
  --bs-body-font-family: var(--font-sans);
  --bs-body-font-size: 1rem;
  --bs-body-line-height: 1.5;
  --bs-body-color: var(--ink);
  --bs-body-bg: var(--paper);
  --bs-secondary-color: var(--ink-2);
  --bs-tertiary-color: var(--ink-3);
  --bs-secondary-bg: var(--paper-2);
  --bs-tertiary-bg: var(--paper-2);
  --bs-emphasis-color: var(--ink);
  --bs-heading-color: var(--ink);
  --bs-link-color: var(--blue-ink);
  --bs-link-hover-color: var(--ink);
  --bs-link-color-rgb: 2, 112, 168;
  --bs-link-hover-color-rgb: 2, 7, 10;
  --bs-border-color: var(--line-strong);
  --bs-border-color-translucent: var(--line);
  --bs-border-radius: var(--r-md);
  --bs-border-radius-sm: var(--r-sm);
  --bs-border-radius-lg: var(--r-lg);
  --bs-border-radius-xl: var(--r-xl);
  --bs-border-radius-pill: var(--r-pill);
  --bs-focus-ring-color: var(--blue-strong);
  --bs-primary: var(--ink);
  --bs-primary-rgb: 2, 7, 10;
  --bs-danger-rgb: 200, 48, 42;
  --bs-success-rgb: 15, 122, 82;
}
[data-bs-theme="dark"] { --bs-primary-rgb: 243, 246, 248; --bs-link-color-rgb: 92, 192, 240; --bs-link-hover-color-rgb: 243, 246, 248; }

/* --------------------------------------------------------------------------
   3. Base
   -------------------------------------------------------------------------- */
html { -webkit-text-size-adjust: 100%; }
body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-sans);
  font-feature-settings: "cv11", "ss01", "ss03"; /* Inter: single-storey a, open digits */
  letter-spacing: -.006em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  touch-action: manipulation;
}
::selection { background: var(--blue-soft); color: var(--ink); }
a { color: var(--blue-ink); text-underline-offset: .2em; text-decoration-thickness: 1px; }
a:hover { color: var(--ink); }
:focus-visible { outline: 3px solid var(--blue-strong); outline-offset: 2px; border-radius: 6px; }
hr { border-color: var(--line-strong); opacity: 1; }
/* Lucide icons from the sprite (Ui.Icon). Component rules below set the size per context; this is the fallback. */
svg.i, svg.lucide { width: 1.25em; height: 1.25em; flex: none; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; vertical-align: -.25em; overflow: visible; }
.tnum { font-variant-numeric: tabular-nums; }
.mono { font-family: var(--font-mono); font-size: .875em; letter-spacing: 0; }
.min-w-0 { min-width: 0; }
.d-grid { grid-template-columns: minmax(0, 1fr); }          /* scrolling chip rows must not widen a grid track */
.table-responsive { position: relative; }                   /* keeps visually-hidden cells inside the scroller */
.flex-none { flex: none; }
.is-hidden { display: none !important; }
.text-ink { color: var(--ink) !important; }
.text-ink-2, .text-muted, .text-body-secondary { color: var(--ink-2) !important; }
.text-ink-3 { color: var(--ink-3) !important; }

/* --------------------------------------------------------------------------
   4. Type scale — medium weight, tight tracking, two-tone titles
   -------------------------------------------------------------------------- */
.t-display { font-size: clamp(2.3rem, 1.75rem + 2.4vw, 3.9rem); font-weight: 500; letter-spacing: -.04em; line-height: 1.03; }
.t-h1, .page-title { font-size: clamp(1.75rem, 1.45rem + 1.2vw, 2.55rem); font-weight: 500; letter-spacing: -.028em; line-height: 1.08; margin: 0; }
.t-h2 { font-size: clamp(1.3rem, 1.15rem + .5vw, 1.65rem); font-weight: 500; letter-spacing: -.02em; line-height: 1.2; }
.t-h3 { font-size: 1.15rem; font-weight: 500; letter-spacing: -.014em; line-height: 1.3; }
.t-body { font-size: 1rem; line-height: 1.55; }
.t-small { font-size: .9375rem; line-height: 1.47; letter-spacing: -.006em; }
.t-micro { font-size: .8125rem; line-height: 1.4; letter-spacing: 0; }
h1, h2, h3, h4, h5, h6, .h1, .h2, .h3, .h4, .h5, .h6 { font-weight: 500; letter-spacing: -.02em; }
.tail { color: var(--ink-3); }                 /* "Tasks. <span class=tail>Soonest first.</span>" */
.on-sky :is(h1, h2, h3, .t-display, .t-h1, .t-h2) { color: #fff; }
.on-sky .tail { color: rgba(255, 255, 255, .72); }
.eyebrow { display: inline-flex; align-items: center; gap: .5rem; font-size: .8125rem; color: var(--ink-3); font-weight: 500; letter-spacing: 0; margin-bottom: .75rem; }
.page-sub { color: var(--ink-2); font-size: 1rem; margin: .5rem 0 0; max-width: 46rem; }

/* --------------------------------------------------------------------------
   5. Glass & surfaces
   -------------------------------------------------------------------------- */
.glass {
  isolation: isolate;
  background-color: var(--glass-tint);
  -webkit-backdrop-filter: blur(22px) saturate(180%);
  backdrop-filter: blur(22px) saturate(180%);
  box-shadow: inset 0 1px 0 0 var(--glass-rim), inset 0 0 0 1px var(--glass-inner), 0 0 0 1px var(--glass-edge), var(--glass-shadow);
}
.glass-thick {
  background-color: var(--glass-tint-thick);
  -webkit-backdrop-filter: blur(28px) saturate(180%);
  backdrop-filter: blur(28px) saturate(180%);
  box-shadow: inset 0 1px 0 0 var(--glass-rim), 0 0 0 1px var(--glass-edge), var(--shadow-3);
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .glass, .glass-thick { background-color: var(--surface); }
}
.panel { background: var(--paper-2); border-radius: var(--r-xl); padding: 1.25rem 1.5rem; }

/* --------------------------------------------------------------------------
   6. App shell — floating glass navigation
   -------------------------------------------------------------------------- */
.shell { min-height: 100dvh; padding-top: calc(var(--nav-h) + var(--safe-top) + .5rem); padding-bottom: calc(var(--tabbar-h) + var(--safe-bottom) + 2rem); }
.shell-bare { min-height: 100dvh; display: grid; place-items: center; padding: 1.5rem 1rem; }
.page { width: 100%; max-width: 1240px; margin: 0 auto; padding: 0 var(--gutter); }

.topnav {
  position: fixed; inset: 0 0 auto 0; z-index: 1030;
  display: flex; align-items: flex-start; justify-content: space-between; gap: .75rem;
  padding: calc(.75rem + var(--safe-top)) max(.75rem, calc(var(--gutter) - .5rem)) 0;
  pointer-events: none;
}
.navpill { pointer-events: auto; display: flex; align-items: center; gap: .125rem; height: 52px; padding: 0 .375rem 0 .5rem; border-radius: var(--r-lg); }
.brand { display: inline-flex; align-items: center; gap: .55rem; padding: 0 .75rem 0 .375rem; height: 40px; color: var(--ink); text-decoration: none; font-weight: 600; letter-spacing: -.03em; font-size: 1.0625rem; }
.brand:hover { color: var(--ink); }
.brand img { width: 30px; height: 30px; border-radius: 9px; }
.navlink {
  display: inline-flex; align-items: center; gap: .4rem; height: 38px; padding: 0 .75rem; border-radius: var(--r-pill);
  color: var(--ink); text-decoration: none; font-size: .9375rem; white-space: nowrap;
  transition: opacity var(--dur-fast) var(--ease-in-out), background-color var(--dur-fast) var(--ease-in-out);
}
.navlink:hover { color: var(--ink); opacity: .6; }
.navlink[aria-current="page"] { background: var(--ink); color: var(--paper); opacity: 1; }
.navlink .count { margin-left: .1rem; }
.navlinks { display: none; }
@media (min-width: 992px) { .navlinks { display: flex; align-items: center; gap: .125rem; } }

.icon-btn {
  display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: var(--r-sm);
  border: 0; background: transparent; color: var(--ink); text-decoration: none;
  transition: background-color var(--dur-fast) var(--ease-in-out), transform var(--dur-press) var(--ease-spring);
}
.icon-btn:hover { background: rgba(2, 7, 10, .06); color: var(--ink); }
[data-bs-theme="dark"] .icon-btn:hover { background: rgba(255, 255, 255, .08); }
.icon-btn:active { transform: scale(.94); }
.icon-btn svg { width: 20px; height: 20px; }
.avatar-btn { padding: 0; }

/* Floating tab bar (phones & tablets) */
.tabbar {
  position: fixed; z-index: 1030; left: 50%; transform: translateX(-50%);
  bottom: calc(.75rem + var(--safe-bottom));
  width: min(calc(100% - 1.5rem), 440px); height: var(--tabbar-h);
  display: grid; grid-template-columns: repeat(5, 1fr); align-items: center; padding: 0 .375rem;
  border-radius: 22px;
}
.tab {
  position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  height: 54px; border-radius: 16px; border: 0; background: transparent;
  color: var(--ink-3); text-decoration: none; font-size: .6875rem; font-weight: 500; letter-spacing: 0;
  transition: color var(--dur-fast) var(--ease-in-out), background-color var(--dur-fast) var(--ease-in-out), transform var(--dur-press) var(--ease-spring);
}
.tab svg { width: 22px; height: 22px; stroke-width: 1.6; }
.tab:hover { color: var(--ink); }
.tab:active { transform: scale(.94); }
.tab[aria-current="page"], .tab.is-active { color: var(--ink); background: rgba(2, 7, 10, .06); }
[data-bs-theme="dark"] .tab[aria-current="page"], [data-bs-theme="dark"] .tab.is-active { background: rgba(255, 255, 255, .1); }
.tab[aria-current="page"] svg { stroke-width: 2; }
.tab .dot-count { position: absolute; top: 4px; left: calc(50% + 6px); }
@media (min-width: 992px) { .tabbar { display: none; } .shell { padding-bottom: 3rem; } }

/* Menu sheet (mobile "More", desktop overflow) */
.sheet {
  position: fixed; z-index: 1045; top: calc(var(--nav-h) + var(--safe-top) - .25rem); right: max(.75rem, calc(var(--gutter) - .5rem));
  width: min(calc(100% - 1.5rem), 380px); max-height: calc(100dvh - var(--nav-h) - 1.5rem); overflow: auto;
  border-radius: var(--r-xl); padding: .75rem 1rem 1rem;
  opacity: 0; transform: translateY(-8px) scale(.98); transform-origin: top right; visibility: hidden;
  transition: opacity var(--dur-base) var(--ease-out), transform var(--dur-base) var(--ease-out), visibility 0s linear var(--dur-base);
}
.sheet.is-open { opacity: 1; transform: none; visibility: visible; transition-delay: 0s; }
.sheet-backdrop { position: fixed; inset: 0; z-index: 1040; background: rgba(2, 7, 10, .18); opacity: 0; visibility: hidden; transition: opacity var(--dur-base) var(--ease-out), visibility 0s linear var(--dur-base); }
.sheet-backdrop.is-open { opacity: 1; visibility: visible; transition-delay: 0s; }
.sheet-links { list-style: none; margin: 0; padding: 0; }
.sheet-links a {
  display: flex; align-items: center; gap: .75rem; min-height: 52px; padding: .25rem .25rem;
  color: var(--ink); text-decoration: none; font-size: 1.1875rem; letter-spacing: -.018em;
  border-bottom: 1px solid var(--line);
}
.sheet-links a svg { width: 20px; height: 20px; color: var(--ink-3); }
.sheet-links a[aria-current="page"] { font-weight: 600; }
.sheet-links a[aria-current="page"] svg { color: var(--ink); }
.sheet-links a .badge-dot { margin-left: auto; }
.sheet-label { font-size: .8125rem; color: var(--ink-3); margin: 1rem 0 .5rem; }

/* --------------------------------------------------------------------------
   7. Buttons — pills, ink-first, spring press
   -------------------------------------------------------------------------- */
.btn {
  --bs-btn-font-weight: 500;
  --bs-btn-font-size: .9375rem;
  --bs-btn-padding-x: 1.125rem;
  --bs-btn-padding-y: 0;
  --bs-btn-border-radius: var(--r-pill);
  --bs-btn-border-width: 0;
  --bs-btn-focus-box-shadow: none;
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  min-height: 40px; white-space: nowrap; letter-spacing: -.006em;
  transition: background-color var(--dur-fast) var(--ease-in-out), box-shadow var(--dur-fast) var(--ease-in-out), color var(--dur-fast) var(--ease-in-out), opacity var(--dur-fast), transform var(--dur-press) var(--ease-spring);
}
.btn:active, .btn.active { transform: scale(.97); }
.btn svg { width: 18px; height: 18px; flex: none; }
.btn .arrow { transition: transform var(--dur-base) var(--ease-out); }
.btn:hover .arrow { transform: translateX(3px); }
.btn-lg { --bs-btn-padding-x: 1.5rem; --bs-btn-font-size: 1rem; min-height: 48px; }
.btn-sm { --bs-btn-padding-x: .875rem; --bs-btn-font-size: .875rem; min-height: 34px; }
.btn-square { --bs-btn-border-radius: var(--r-sm); }

.btn-primary, .btn-ink {
  --bs-btn-color: var(--paper); --bs-btn-bg: var(--ink);
  --bs-btn-hover-color: var(--paper); --bs-btn-hover-bg: #1b2328;
  --bs-btn-active-color: var(--paper); --bs-btn-active-bg: #000;
  --bs-btn-disabled-color: var(--ink-3); --bs-btn-disabled-bg: var(--paper-3); --bs-btn-disabled-opacity: 1;
}
[data-bs-theme="dark"] .btn-primary, [data-bs-theme="dark"] .btn-ink { --bs-btn-hover-bg: #fff; --bs-btn-active-bg: #dfe5e9; }
.btn-light, .btn-outline-primary, .btn-outline-secondary, .btn-secondary {
  --bs-btn-color: var(--ink); --bs-btn-bg: var(--surface);
  --bs-btn-hover-color: var(--ink); --bs-btn-hover-bg: var(--paper-2);
  --bs-btn-active-color: var(--ink); --bs-btn-active-bg: var(--paper-3);
  --bs-btn-disabled-color: var(--ink-3); --bs-btn-disabled-bg: var(--paper-2);
  box-shadow: inset 0 0 0 1px var(--line-strong);
}
.btn-white { --bs-btn-color: #02070a; --bs-btn-bg: #fff; --bs-btn-hover-color: #02070a; --bs-btn-hover-bg: #f5f6f7; --bs-btn-active-bg: #eceef0; --bs-btn-active-color: #02070a; box-shadow: 0 12px 30px -12px rgba(8, 36, 110, .55); }
.btn-ghost { --bs-btn-color: var(--ink-2); --bs-btn-bg: transparent; --bs-btn-hover-color: var(--ink); --bs-btn-hover-bg: rgba(2, 7, 10, .05); --bs-btn-active-bg: rgba(2, 7, 10, .08); --bs-btn-active-color: var(--ink); }
.btn-success, .btn-done { --bs-btn-color: #02070a; --bs-btn-bg: var(--mint); --bs-btn-hover-color: #02070a; --bs-btn-hover-bg: #2bb381; --bs-btn-active-bg: #23a073; --bs-btn-active-color: #02070a; }
.btn-warning, .btn-attention { --bs-btn-color: #02070a; --bs-btn-bg: var(--orange); --bs-btn-hover-color: #02070a; --bs-btn-hover-bg: #f2643c; --bs-btn-active-bg: #e4582f; --bs-btn-active-color: #02070a; }
.btn-outline-danger { --bs-btn-color: var(--danger); --bs-btn-bg: var(--surface); --bs-btn-hover-color: #fff; --bs-btn-hover-bg: var(--danger); --bs-btn-active-bg: var(--danger); --bs-btn-active-color: #fff; box-shadow: inset 0 0 0 1px var(--danger); }
.btn-link { --bs-btn-color: var(--blue-ink); --bs-btn-hover-color: var(--ink); --bs-btn-padding-x: .25rem; }
.btn:disabled, .btn.disabled { --bs-btn-disabled-bg: var(--paper-2); --bs-btn-disabled-color: var(--ink-3); --bs-btn-disabled-opacity: 1; --bs-btn-disabled-border-color: transparent; box-shadow: none; }
.btn-circle { --bs-btn-padding-x: 0; width: 40px; min-height: 40px; }
.btn-circle.btn-sm { width: 32px; min-height: 32px; }
.btn-check:checked + .btn, .btn[aria-pressed="true"] { --bs-btn-active-bg: var(--ink); --bs-btn-active-color: var(--paper); box-shadow: none; }
@media (max-width: 991.98px), (pointer: coarse) {
  .btn, .btn-sm { min-height: var(--target); }
  .btn-circle, .btn-circle.btn-sm { width: var(--target); min-height: var(--target); }
  .icon-btn { width: var(--target); height: var(--target); }
}

/* Text link with arrow ("See all →") */
.link-arrow { display: inline-flex; align-items: center; gap: .35rem; color: var(--ink); text-decoration: none; font-size: .9375rem; }
.link-arrow svg { width: 16px; height: 16px; transition: transform var(--dur-base) var(--ease-out); }
.link-arrow:hover { color: var(--ink); }
.link-arrow:hover svg { transform: translateX(3px); }

/* --------------------------------------------------------------------------
   8. Chips, tags, badges, dots
   -------------------------------------------------------------------------- */
.chipbar { display: flex; gap: .5rem; overflow-x: auto; scrollbar-width: none; padding: .125rem .125rem .25rem; margin: 0 -.125rem; scroll-snap-type: x proximity; }
.chipbar::-webkit-scrollbar { display: none; }
.chipbar.is-sticky { position: sticky; top: calc(var(--nav-h) + var(--safe-top) - .25rem); z-index: 5; padding: .5rem; margin: 0 -.5rem; border-radius: var(--r-pill); }
.chip {
  flex: none; scroll-snap-align: start;
  display: inline-flex; align-items: center; gap: .4rem; min-height: 38px; padding: 0 .9rem;
  border-radius: var(--r-pill); border: 0; background: var(--surface); color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--line-strong);
  font-size: .9375rem; text-decoration: none; white-space: nowrap;
  transition: background-color var(--dur-fast) var(--ease-in-out), color var(--dur-fast), transform var(--dur-press) var(--ease-spring);
}
.chip:hover { color: var(--ink); background: var(--paper-2); }
.chip:active { transform: scale(.96); }
.chip .n { color: var(--ink-3); font-variant-numeric: tabular-nums; }
.chip[aria-current], .chip[aria-pressed="true"], .chip.is-active { background: var(--ink); color: var(--paper); box-shadow: none; }
.chip[aria-current] .n, .chip[aria-pressed="true"] .n, .chip.is-active .n { color: rgba(245, 246, 247, .7); }
[data-bs-theme="dark"] .chip[aria-current] .n, [data-bs-theme="dark"] .chip.is-active .n { color: rgba(2, 7, 10, .65); }
.chip svg { width: 16px; height: 16px; }
.chip .avatar { width: 24px; height: 24px; font-size: .6875rem; margin-left: -.5rem; }
@media (max-width: 991.98px), (pointer: coarse) { .chip { min-height: var(--target); } }

/* Underline tabs (filters under a search, mappings sections) */
.utabs { display: flex; gap: 1.25rem; overflow-x: auto; scrollbar-width: none; border-bottom: 1px solid var(--line); }
.utabs::-webkit-scrollbar { display: none; }
.utab { position: relative; display: inline-flex; align-items: center; gap: .4rem; min-height: var(--target); color: var(--ink-3); text-decoration: none; white-space: nowrap; font-size: .9375rem; }
.utab:hover { color: var(--ink); }
.utab[aria-current] { color: var(--ink); }
.utab[aria-current]::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: var(--ink); border-radius: 2px; }
.utab svg { width: 16px; height: 16px; }

/* Tag: quiet label inside cards */
.tag { display: inline-flex; align-items: center; gap: .3rem; height: 24px; padding: 0 .6rem; border-radius: var(--r-pill); background: rgba(2, 7, 10, .05); color: var(--ink-2); font-size: .75rem; font-weight: 500; white-space: nowrap; letter-spacing: 0; }
:where([data-bs-theme="dark"]) .tag { background: rgba(255, 255, 255, .08); } /* :where keeps variants (.tag-attn…) winning */
.tag svg { width: 13px; height: 13px; }
.tag-ink { background: var(--ink); color: var(--paper); }
.tag-attn { background: var(--orange); color: #02070a; }
.tag-attn-soft { background: var(--orange-wash); color: var(--orange-ink); }
.tag-done { background: var(--mint-wash); color: var(--mint-ink); }
.tag-info { background: var(--blue-wash); color: var(--cat-task-ink); }
.tag-danger { background: var(--danger-wash); color: var(--danger); }
.tag-outline { background: transparent; box-shadow: inset 0 0 0 1px var(--line-strong); }
.tag-mono { font-family: var(--font-mono); font-weight: 500; letter-spacing: 0; }

/* Category tag = tint + icon + word */
.cat { display: inline-flex; align-items: center; gap: .35rem; height: 24px; padding: 0 .6rem 0 .5rem; border-radius: var(--r-pill); font-size: .75rem; font-weight: 600; letter-spacing: .01em; }
.cat svg { width: 13px; height: 13px; stroke-width: 2; }
.cat-task { background: var(--cat-task-tint); color: var(--cat-task-ink); }
.cat-event { background: var(--cat-event-tint); color: var(--cat-event-ink); }
.cat-exam { background: var(--cat-exam-tint); color: var(--cat-exam-ink); }
.cat-announcement { background: var(--cat-announcement-tint); color: var(--cat-announcement-ink); }
.cat-notice { background: var(--cat-notice-tint); color: var(--cat-notice-ink); }

/* Bootstrap badge → tag look */
.badge { --bs-badge-font-weight: 500; --bs-badge-border-radius: var(--r-pill); --bs-badge-padding-x: .6em; --bs-badge-padding-y: .4em; letter-spacing: 0; }

/* Dots */
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--orange); flex: none; }
.dot-blue { background: var(--blue); }
.dot-mint { background: var(--mint); }
.dot-pulse { animation: pulse-dot 1.8s var(--ease-out) infinite; }
.dot-count { display: inline-grid; place-items: center; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--orange); color: #02070a; font-size: .6875rem; font-weight: 700; font-variant-numeric: tabular-nums; box-shadow: 0 0 0 2px var(--surface); }

/* Live pill: "● Live  3 new today →" */
.live-pill { display: inline-flex; align-items: center; gap: .6rem; height: 32px; padding: 0 .75rem 0 .25rem; border-radius: var(--r-pill); color: var(--ink); text-decoration: none; font-size: .875rem; }
.live-pill:hover { color: var(--ink); }
.live-pill .live { display: inline-flex; align-items: center; gap: .35rem; height: 24px; padding: 0 .55rem; border-radius: var(--r-pill); background: var(--ink); color: var(--paper); font-weight: 600; font-size: .75rem; }
.live-pill .live .dot { width: 6px; height: 6px; background: var(--mint); }
.live-pill svg { width: 14px; height: 14px; }

/* --------------------------------------------------------------------------
   9. Cards
   -------------------------------------------------------------------------- */
.card {
  --bs-card-bg: var(--surface);
  --bs-card-border-width: 0;
  --bs-card-border-radius: var(--r-xl);
  --bs-card-inner-border-radius: var(--r-xl);
  --bs-card-spacer-x: 1.25rem;
  --bs-card-spacer-y: 1.25rem;
  --bs-card-cap-bg: transparent;
  --bs-card-cap-padding-y: 1rem;
  --bs-card-cap-padding-x: 1.25rem;
  box-shadow: inset 0 0 0 1px var(--line), var(--shadow-1);
  color: var(--ink);
}
.card-header { font-weight: 500; font-size: 1.0625rem; letter-spacing: -.014em; border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: .5rem; }
.card-header svg { width: 18px; height: 18px; color: var(--ink-3); }
@media (min-width: 768px) { .card { --bs-card-spacer-x: 1.5rem; --bs-card-spacer-y: 1.5rem; --bs-card-cap-padding-x: 1.5rem; } }
a.card, .card-link-wrap { text-decoration: none; color: inherit; }
.card-lift { transition: box-shadow var(--dur-base) var(--ease-out), transform var(--dur-base) var(--ease-out); }
.card-lift:hover { box-shadow: inset 0 0 0 1px var(--line), var(--shadow-2); transform: translateY(-2px); }
.card-lift:active { transform: translateY(0) scale(.99); }
.card-flat { box-shadow: none; background: var(--paper-2); }

/* Dark feature card (ink with a sky glow) */
.card-night {
  --bs-card-bg: #02070a; color: #f3f6f8; position: relative; overflow: hidden; isolation: isolate;
  box-shadow: var(--shadow-2);
}
.card-night::before { content: ""; position: absolute; inset: -30% -20% auto auto; width: 80%; height: 90%; z-index: -1; background: radial-gradient(closest-side, rgba(2, 151, 222, .45), transparent); filter: blur(10px); animation: glow-drift 12s var(--ease-in-out) infinite alternate; }
.card-night :is(h1, h2, h3, h4, .t-h1, .t-h2, .t-h3), .sky :is(h1, h2, h3, h4) { color: inherit; }
.card-night .tail, .card-night .t-micro, .card-night .text-ink-3 { color: rgba(243, 246, 248, .66) !important; }
.card-night a:not(.btn) { color: #9fdcfa; }

/* --------------------------------------------------------------------------
   10. Sky hero — our own illustration in CSS (no photography)
   -------------------------------------------------------------------------- */
.sky {
  position: relative; overflow: hidden; isolation: isolate; color: #fff; border-radius: var(--r-2xl);
  background:
    radial-gradient(120% 70% at 15% 105%, rgba(255, 255, 255, .55), transparent 60%),
    radial-gradient(60% 45% at 85% 95%, rgba(255, 255, 255, .45), transparent 70%),
    linear-gradient(178deg, #0b4a7a 0%, #145f98 28%, #1c6fae 46%, #3d95cf 70%, #7cc9ef 100%);
  padding: clamp(1.5rem, 1rem + 2.5vw, 3rem);
}
.sky::before, .sky::after { content: ""; position: absolute; z-index: -1; pointer-events: none; }
/* soft clouds */
.sky::before {
  inset: -10%;
  background:
    radial-gradient(28% 18% at 22% 30%, rgba(255, 255, 255, .28), transparent 70%),
    radial-gradient(34% 20% at 70% 18%, rgba(255, 255, 255, .22), transparent 70%),
    radial-gradient(40% 22% at 58% 62%, rgba(255, 255, 255, .26), transparent 70%),
    radial-gradient(30% 16% at 12% 72%, rgba(255, 255, 255, .2), transparent 70%);
  filter: blur(14px);
  animation: cloud-drift 38s var(--ease-in-out) infinite alternate;
}
/* dot grain */
.sky::after {
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, .22) 1px, transparent 1.3px);
  background-size: 7px 7px;
  -webkit-mask-image: linear-gradient(180deg, transparent 20%, #000 75%);
  mask-image: linear-gradient(180deg, transparent 20%, #000 75%);
}
.sky .t-display, .sky .t-h1, .sky h1 { color: #fff; text-wrap: balance; }
.sky .lede { color: rgba(255, 255, 255, .9); font-size: clamp(1rem, .95rem + .3vw, 1.1875rem); max-width: 34rem; }
.sky .live-pill { color: var(--ink); }
[data-bs-theme="dark"] .sky { background:
    radial-gradient(120% 70% at 15% 105%, rgba(124, 201, 239, .28), transparent 60%),
    linear-gradient(178deg, #041a2b 0%, #08304f 40%, #0b4a7a 75%, #1c6fae 100%); }

/* --------------------------------------------------------------------------
   11. Stats
   -------------------------------------------------------------------------- */
.stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .25rem; background: var(--paper-2); border-radius: var(--r-xl); padding: .5rem; }
@media (min-width: 768px) { .stats { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.stat { display: block; padding: .875rem 1rem 1rem; border-radius: var(--r-lg); color: var(--ink); text-decoration: none; transition: background-color var(--dur-fast) var(--ease-in-out); }
.stat:hover { background: var(--surface); color: var(--ink); }
.stat .lbl { display: flex; align-items: center; gap: .4rem; font-size: .875rem; color: var(--ink-3); }
.stat .num { font-size: clamp(1.9rem, 1.6rem + 1.2vw, 2.5rem); font-weight: 500; letter-spacing: -.03em; line-height: 1.1; font-variant-numeric: tabular-nums; margin-top: .15rem; }
.stat.is-attn .num::after { content: ""; display: inline-block; width: 9px; height: 9px; margin-left: .4rem; vertical-align: super; border-radius: 50%; background: var(--orange); animation: pulse-dot 1.8s var(--ease-out) infinite; }

/* --------------------------------------------------------------------------
   12. Section head: eyebrow + two-tone title + "See all →"
   -------------------------------------------------------------------------- */
.section { margin-top: clamp(2.5rem, 2rem + 2vw, 4rem); }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; margin-bottom: 1.25rem; }
.section-head .t-h2 { margin: 0; }
.section-head .count { color: var(--ink-3); font-variant-numeric: tabular-nums; }

/* --------------------------------------------------------------------------
   13. Information item (the product's core unit)
   -------------------------------------------------------------------------- */
.item {
  position: relative; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: .25rem 1rem;
  background: var(--surface); border-radius: var(--r-xl); padding: 1.125rem 1.125rem 1.125rem 1rem;
  box-shadow: inset 0 0 0 1px var(--line), var(--shadow-1);
  transition: box-shadow var(--dur-base) var(--ease-out), transform var(--dur-base) var(--ease-out), opacity var(--dur-base);
}
.item + .item { margin-top: .625rem; }
.item:hover { box-shadow: inset 0 0 0 1px var(--line), var(--shadow-2); }
.item > :not(.item-icon) { grid-column: 2; }
.item-icon { grid-column: 1; grid-row: 1 / span 3; width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; }
.item-icon svg { width: 20px; height: 20px; stroke-width: 1.75; }
.item.cat-task .item-icon { background: var(--cat-task-tint); color: var(--cat-task-ink); }
.item.cat-event .item-icon { background: var(--cat-event-tint); color: var(--cat-event-ink); }
.item.cat-exam .item-icon { background: var(--cat-exam-tint); color: var(--cat-exam-ink); }
.item.cat-announcement .item-icon { background: var(--cat-announcement-tint); color: var(--cat-announcement-ink); }
.item.cat-notice .item-icon { background: var(--cat-notice-tint); color: var(--cat-notice-ink); }
.item.cat-task, .item.cat-event, .item.cat-exam, .item.cat-announcement, .item.cat-notice { background: var(--surface); color: var(--ink); }
.item-tags { display: flex; flex-wrap: wrap; align-items: center; gap: .375rem; }
.item-title { display: block; color: var(--ink); text-decoration: none; font-size: 1.0625rem; font-weight: 500; letter-spacing: -.014em; line-height: 1.35; margin-top: .375rem; }
.item-title::after { content: ""; position: absolute; inset: 0; border-radius: inherit; } /* whole card is the link */
.item-title:hover { color: var(--ink); }
.item-sum { color: var(--ink-2); font-size: .9375rem; margin-top: .125rem; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.item-meta { display: flex; flex-wrap: wrap; gap: .25rem 1rem; color: var(--ink-3); font-size: .875rem; margin-top: .5rem; }
.item-meta span { display: inline-flex; align-items: center; gap: .35rem; }
.item-meta svg { width: 15px; height: 15px; }
.item-meta .is-late { color: var(--orange-ink); font-weight: 500; }
.item-actions { grid-column: 2; display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .875rem; position: relative; z-index: 1; }
.item-actions form { margin: 0; }
.item-note { grid-column: 2; position: relative; z-index: 1; margin-top: .625rem; }
.item.is-unread .item-title::before { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--blue); margin-right: .5rem; vertical-align: middle; }
.item.is-overdue { box-shadow: inset 0 0 0 1px rgba(252, 115, 77, .45), var(--shadow-1); }
.item.is-done { opacity: .62; }
.item.is-done .item-title { text-decoration: line-through; text-decoration-color: var(--ink-3); }
.item.is-leaving { opacity: 0; transform: translateX(16px) scale(.98); }
@media (max-width: 575.98px) {
  .item { grid-template-columns: minmax(0, 1fr); padding: 1rem; }
  .item-icon { grid-row: auto; width: 36px; height: 36px; border-radius: 12px; position: absolute; top: 1rem; right: 1rem; }
  .item-icon svg { width: 18px; height: 18px; }
  .item-tags { padding-right: 2.75rem; }
  .item > :not(.item-icon), .item-actions, .item-note { grid-column: 1; }
}

/* Standalone icon tile (lists, settings rows) */
.icon-tile { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; flex: none; background: var(--paper-2); color: var(--ink-2); }
.icon-tile svg { width: 18px; height: 18px; }
.icon-tile.is-sky { background: var(--blue-wash); color: var(--cat-task-ink); }

/* Compact rank/agenda rows ("1  Title / sub   meta") */
.rows { list-style: none; margin: 0; padding: 0; }
.row-item { position: relative; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 1rem; padding: .875rem 0; border-bottom: 1px solid var(--line); }
.row-item:first-child { border-top: 1px solid var(--line); }
.row-item .lead-num { width: 2rem; font-size: 1.375rem; color: var(--ink-3); font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.row-item .title { color: var(--ink); text-decoration: none; font-weight: 500; letter-spacing: -.012em; display: block; }
.row-item .title::after { content: ""; position: absolute; inset: 0; }
.row-item .sub { color: var(--ink-3); font-size: .875rem; }
.row-item .end { text-align: right; font-size: .875rem; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.row-item .end small { display: block; color: var(--ink-3); font-size: .75rem; }
.row-item:hover .title { text-decoration: underline; text-decoration-color: var(--line-strong); }

/* Date tile: "THU / 20" */
.date-tile { width: 52px; border-radius: 14px; background: var(--paper-2); text-align: center; padding: .375rem 0 .4rem; line-height: 1; }
.date-tile .m { display: block; font-size: .6875rem; font-weight: 600; color: var(--ink-3); text-transform: uppercase; letter-spacing: .06em; }
.date-tile .d { display: block; font-size: 1.375rem; font-weight: 500; letter-spacing: -.03em; margin-top: .2rem; font-variant-numeric: tabular-nums; }
.date-tile.is-time .d { font-size: 1.0625rem; letter-spacing: -.02em; margin-top: .3rem; }
.date-tile.is-today { background: var(--ink); color: var(--paper); }
.date-tile.is-today .m { color: rgba(245, 246, 247, .7); }
[data-bs-theme="dark"] .date-tile.is-today .m { color: rgba(2, 7, 10, .65); }

/* Horizontal snap rail of cards (dashboard "Today") */
.rail { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(260px, 82%); gap: .75rem; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; padding: .25rem var(--gutter) .75rem; margin: 0 calc(var(--gutter) * -1); scroll-padding: 0 var(--gutter); }
.rail::-webkit-scrollbar { display: none; }
.rail > * { scroll-snap-align: start; }
@media (min-width: 768px) { .rail { grid-auto-columns: minmax(280px, 1fr); } }
.mini { display: flex; flex-direction: column; gap: .5rem; height: 100%; padding: 1.125rem; border-radius: var(--r-xl); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line), var(--shadow-1); color: var(--ink); text-decoration: none; position: relative; }
.mini .t { font-weight: 500; font-size: 1.0625rem; letter-spacing: -.014em; line-height: 1.3; }
.mini .s { color: var(--ink-2); font-size: .875rem; }
.mini .f { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: .5rem; padding-top: .5rem; color: var(--ink-3); font-size: .8125rem; }

/* --------------------------------------------------------------------------
   14. Search pill (alyn-style: input + ink button inside)
   -------------------------------------------------------------------------- */
.searchbar { display: flex; align-items: center; gap: .5rem; height: 56px; padding: 0 .375rem 0 1.125rem; border-radius: var(--r-pill); background: var(--surface); box-shadow: inset 0 0 0 1px var(--input-border), var(--shadow-2); }
.searchbar.mx-auto { max-width: 640px; }
.searchbar:focus-within { box-shadow: inset 0 0 0 2px var(--blue-strong), var(--shadow-2); }
.searchbar > svg { width: 18px; height: 18px; color: var(--ink-3); flex: none; }
.searchbar input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; color: var(--ink); font-size: 1rem; height: 100%; }
.searchbar input::placeholder { color: var(--ink-3); }
.searchbar .btn { min-height: 44px; }
.searchbar-sm { height: 48px; }
.searchbar-sm .btn { min-height: 38px; }

/* --------------------------------------------------------------------------
   15. Forms
   -------------------------------------------------------------------------- */
.form-label { font-size: .9375rem; font-weight: 500; color: var(--ink); margin-bottom: .4rem; }
.form-label.required::after { content: " *"; color: var(--danger); }
.form-text { color: var(--ink-3); font-size: .875rem; }
.form-control, .form-select {
  min-height: 48px; font-size: 1rem; color: var(--ink); background-color: var(--surface);
  border: 1px solid var(--input-border); border-radius: var(--r-md); padding: .65rem .9rem;
  transition: border-color var(--dur-fast), box-shadow var(--dur-fast);
}
textarea.form-control { min-height: 96px; }
.form-control::placeholder { color: var(--ink-3); }
.form-control:focus, .form-select:focus { border-color: var(--blue-strong); box-shadow: 0 0 0 3px var(--blue-wash), 0 0 0 1px var(--blue-strong); background-color: var(--surface); color: var(--ink); }
.form-control-sm, .form-select-sm { min-height: 40px; font-size: .9375rem; border-radius: var(--r-sm); }
.form-check-input { width: 1.25em; height: 1.25em; border: 1.5px solid var(--input-border); background-color: var(--surface); }
.form-check-input:checked { background-color: var(--ink); border-color: var(--ink); }
.form-check-input:focus { box-shadow: 0 0 0 3px var(--blue-wash); border-color: var(--blue-strong); }
.form-switch .form-check-input { width: 2.5em; height: 1.4em; }
.form-check { min-height: 1.75rem; }
.form-check-label { cursor: pointer; }
.choice { display: flex; gap: .875rem; align-items: flex-start; padding: 1rem 1.125rem; border-radius: var(--r-lg); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line-strong); cursor: pointer; transition: box-shadow var(--dur-fast); }
.choice:hover { box-shadow: inset 0 0 0 1px var(--ink-3); }
.choice:has(input:checked) { box-shadow: inset 0 0 0 2px var(--ink); }
.choice input { margin-top: .2rem; flex: none; }
.segmented { display: flex; flex-wrap: wrap; gap: .5rem; }
.segmented .btn { min-height: 44px; }
.field-group { padding: 1.25rem; border-radius: var(--r-lg); background: var(--paper-2); }
fieldset legend { font-size: .9375rem; font-weight: 500; }

/* Details/accordion (FAQ style) */
.faq { border-bottom: 1px solid var(--line-strong); }
.faq:first-of-type { border-top: 1px solid var(--line-strong); }
.faq > summary { list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 64px; padding: .75rem 0; cursor: pointer; font-size: 1.0625rem; font-weight: 500; letter-spacing: -.012em; }
.faq > summary::-webkit-details-marker { display: none; }
.faq > summary .pm { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: var(--paper-2); flex: none; transition: transform var(--dur-base) var(--ease-out), background-color var(--dur-fast); }
.faq > summary .pm svg { width: 16px; height: 16px; }
.faq[open] > summary .pm { transform: rotate(45deg); }
.faq > summary:hover .pm { background: var(--paper-3); }
.faq-body { padding: 0 0 1.25rem; color: var(--ink-2); animation: fade-rise var(--dur-base) var(--ease-out); }
.card .faq { border-color: var(--line); }

/* --------------------------------------------------------------------------
   16. Meter, ring, avatars, quote, bubbles
   -------------------------------------------------------------------------- */
.meter { height: 6px; border-radius: 3px; background: var(--paper-3); overflow: hidden; }
.meter > span { display: block; height: 100%; border-radius: inherit; background: var(--blue); transform-origin: left; animation: grow-x 900ms var(--ease-out) both; }
.meter.is-mint > span { background: var(--mint); }
.meter-25 > span { width: 25%; } .meter-50 > span { width: 50%; } .meter-75 > span { width: 75%; } .meter-100 > span { width: 100%; }
.card-night .meter { background: rgba(255, 255, 255, .12); }

.ring { --p: 0; width: 76px; height: 76px; border-radius: 50%; display: grid; place-items: center; flex: none;
  background: radial-gradient(closest-side, var(--surface) 80%, transparent 81% 100%), conic-gradient(var(--blue) calc(var(--p) * 1%), var(--paper-3) 0); }
.ring b { font-size: 1.375rem; font-weight: 500; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.card-night .ring { background: radial-gradient(closest-side, #02070a 80%, transparent 81% 100%), conic-gradient(var(--blue) calc(var(--p) * 1%), rgba(255, 255, 255, .14) 0); }
/* No inline styles (CSP), so values come in steps of 5 (Ui.Step5): ring-0 … ring-100, meter-0 … meter-100. */
.ring-0 { --p: 0; } .ring-5 { --p: 5; } .ring-10 { --p: 10; } .ring-15 { --p: 15; } .ring-20 { --p: 20; } .ring-25 { --p: 25; } .ring-30 { --p: 30; } .ring-35 { --p: 35; } .ring-40 { --p: 40; } .ring-45 { --p: 45; } .ring-50 { --p: 50; } .ring-55 { --p: 55; } .ring-60 { --p: 60; } .ring-65 { --p: 65; } .ring-70 { --p: 70; } .ring-75 { --p: 75; } .ring-80 { --p: 80; } .ring-85 { --p: 85; } .ring-90 { --p: 90; } .ring-95 { --p: 95; } .ring-100 { --p: 100; }
.ring-91 { --p: 91; } .ring-62 { --p: 62; } .ring-84 { --p: 84; } /* odd values kept from the v2 prototype samples */
.meter-0 > span { width: 0%; } .meter-5 > span { width: 5%; } .meter-10 > span { width: 10%; } .meter-15 > span { width: 15%; } .meter-20 > span { width: 20%; } .meter-30 > span { width: 30%; } .meter-35 > span { width: 35%; } .meter-40 > span { width: 40%; } .meter-45 > span { width: 45%; } .meter-55 > span { width: 55%; } .meter-60 > span { width: 60%; } .meter-65 > span { width: 65%; } .meter-70 > span { width: 70%; } .meter-80 > span { width: 80%; } .meter-85 > span { width: 85%; } .meter-90 > span { width: 90%; } .meter-95 > span { width: 95%; }

.avatar { display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: var(--paper-3); color: var(--ink); font-size: .8125rem; font-weight: 600; flex: none; letter-spacing: 0; }
.avatar-lg { width: 52px; height: 52px; font-size: 1.0625rem; }
.avatar-sky { background: linear-gradient(135deg, var(--sky-1), var(--sky-2)); color: #02070a; }
.avatar-ink { background: var(--ink); color: var(--paper); }
.avatar-mint { background: var(--mint); color: #02070a; }
.avatar-violet { background: var(--cat-exam-tint); color: var(--cat-exam-ink); }
.avatars { display: inline-flex; }
.avatars .avatar { width: 28px; height: 28px; font-size: .6875rem; box-shadow: 0 0 0 2px var(--surface); }
.avatars .avatar + .avatar { margin-left: -8px; }

.quote { margin: 0; padding: .875rem 1rem; border-radius: var(--r-lg); background: var(--paper-2); color: var(--ink); font-size: .9375rem; white-space: pre-wrap; }
.quote-src { display: flex; align-items: center; gap: .5rem; color: var(--ink-3); font-size: .8125rem; margin-bottom: .5rem; }
.quote-src svg { width: 14px; height: 14px; }

.thread { display: flex; flex-direction: column; gap: .625rem; }
.bubble { max-width: 86%; padding: .75rem 1rem; border-radius: 20px; font-size: .9375rem; white-space: pre-wrap; animation: fade-rise var(--dur-base) var(--ease-out) both; }
.bubble .who { display: block; font-size: .75rem; font-weight: 500; margin-bottom: .2rem; opacity: .7; white-space: normal; }
.bubble-parent { align-self: flex-end; background: var(--ink); color: var(--paper); border-bottom-right-radius: 6px; }
.bubble-ai { align-self: flex-start; background: var(--paper-2); color: var(--ink); border-bottom-left-radius: 6px; }
.bubble-system { align-self: center; max-width: 100%; background: transparent; color: var(--ink-3); font-size: .8125rem; padding: .25rem; }
.typing-dots { display: inline-flex; gap: 4px; }
.typing-dots i { width: 6px; height: 6px; border-radius: 50%; background: var(--ink-3); animation: typing 1.2s var(--ease-in-out) infinite; }
.typing-dots i:nth-child(2) { animation-delay: .15s; } .typing-dots i:nth-child(3) { animation-delay: .3s; }
.composer { display: flex; align-items: flex-end; gap: .5rem; padding: .375rem .375rem .375rem 1rem; border-radius: 24px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--input-border); }
.composer:focus-within { box-shadow: inset 0 0 0 2px var(--blue-strong); }
.composer textarea { flex: 1; border: 0; outline: 0; resize: none; background: transparent; color: var(--ink); min-height: 44px; padding: .65rem 0; font-size: 1rem; }

/* What-we-understood box */
.ai-box { border-radius: var(--r-lg); padding: 1rem 1.125rem; background: var(--blue-wash); color: var(--ink); }
.ai-box .k { display: flex; align-items: center; gap: .4rem; font-size: .8125rem; font-weight: 600; color: var(--cat-task-ink); margin-bottom: .25rem; }
.ai-box .k svg { width: 15px; height: 15px; }
.kv { display: grid; grid-template-columns: minmax(7rem, 30%) 1fr; gap: .75rem 1rem; margin: 0; }
.kv dt { color: var(--ink-3); font-weight: 400; font-size: .9375rem; }
.kv dd { margin: 0; }
@media (max-width: 575.98px) { .kv { grid-template-columns: 1fr; gap: .1rem; } .kv dd { margin-bottom: .75rem; } }

/* --------------------------------------------------------------------------
   17. Lists & tables
   -------------------------------------------------------------------------- */
.list-group { --bs-list-group-bg: transparent; --bs-list-group-border-color: var(--line); --bs-list-group-color: var(--ink); --bs-list-group-action-hover-bg: var(--paper-2); --bs-list-group-action-hover-color: var(--ink); --bs-list-group-action-active-bg: var(--paper-3); --bs-list-group-item-padding-x: 1.25rem; --bs-list-group-item-padding-y: .875rem; }
.list-group-item svg { width: 18px; height: 18px; color: var(--ink-3); }
.list-group-item-action { display: flex; align-items: center; gap: .75rem; min-height: 56px; }
.list-group-item-action .chev { margin-left: auto; transition: transform var(--dur-base) var(--ease-out); }
.list-group-item-action:hover .chev { transform: translateX(3px); }
.table { --bs-table-bg: transparent; --bs-table-color: var(--ink); --bs-table-border-color: var(--line); --bs-table-hover-bg: var(--paper-2); margin: 0; }
.table > thead th { font-size: .8125rem; font-weight: 500; color: var(--ink-3); border-bottom-color: var(--line-strong); white-space: nowrap; }
.table > :not(caption) > * > * { padding: .875rem 1rem; vertical-align: middle; }
.cat-list { list-style: none; margin: 0; padding: 0; }
.cat-list li { display: flex; align-items: center; gap: .75rem; min-height: 48px; border-bottom: 1px solid var(--line); }
.cat-list li svg { width: 18px; height: 18px; color: var(--ink-3); }
.cat-list li .n { margin-left: auto; color: var(--ink-3); font-size: .875rem; font-variant-numeric: tabular-nums; }
.cat-list-head { font-size: .8125rem; color: var(--ink-3); padding-bottom: .625rem; border-bottom: 1.5px solid var(--ink); }

/* --------------------------------------------------------------------------
   18. Calendar
   -------------------------------------------------------------------------- */
.cal { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; background: var(--paper-2); padding: 4px; border-radius: var(--r-xl); }
.cal-head { font-size: .75rem; font-weight: 500; color: var(--ink-3); padding: .5rem .625rem .25rem; }
.cal-day { min-height: 116px; background: var(--surface); border-radius: 14px; padding: .5rem; display: flex; flex-direction: column; gap: 3px; }
.cal-day.is-out { background: transparent; }
.cal-day.is-out .cal-num { color: var(--ink-3); }
.cal-num { font-size: .8125rem; font-weight: 500; font-variant-numeric: tabular-nums; width: 26px; height: 26px; display: grid; place-items: center; border-radius: 50%; margin-bottom: 2px; }
.cal-day.is-today .cal-num { background: var(--ink); color: var(--paper); }
.cal-entry { display: flex; align-items: center; gap: 4px; padding: 3px 6px; border-radius: 7px; font-size: .75rem; font-weight: 500; text-decoration: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cal-entry svg { width: 12px; height: 12px; flex: none; }
.cal-entry.cat-task { background: var(--cat-task-tint); color: var(--cat-task-ink); }
.cal-entry.cat-event { background: var(--cat-event-tint); color: var(--cat-event-ink); }
.cal-entry.cat-exam { background: var(--cat-exam-tint); color: var(--cat-exam-ink); }
.cal-entry.cat-notice { background: var(--cat-notice-tint); color: var(--cat-notice-ink); }
.cal-more { font-size: .75rem; color: var(--ink-3); padding-left: 6px; }
.week-strip { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: .375rem; }
.week-strip a { display: flex; flex-direction: column; align-items: center; gap: .2rem; padding: .5rem 0 .55rem; border-radius: 16px; text-decoration: none; color: var(--ink); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.week-strip a .w { font-size: .6875rem; color: var(--ink-3); font-weight: 500; }
.week-strip a .d { font-size: 1.0625rem; font-weight: 500; font-variant-numeric: tabular-nums; }
.week-strip a .dots { display: flex; gap: 3px; height: 5px; }
.week-strip a .dots i { width: 5px; height: 5px; border-radius: 50%; background: var(--blue); }
.week-strip a .dots i.ex { background: var(--cat-exam); } .week-strip a .dots i.ev { background: var(--cat-event); }
.week-strip a[aria-current] { background: var(--ink); color: var(--paper); box-shadow: none; }
.week-strip a[aria-current] .w { color: rgba(245, 246, 247, .7); }
.agenda-day { display: flex; align-items: baseline; gap: .5rem; margin: 1.75rem 0 .75rem; font-size: 1.0625rem; font-weight: 500; letter-spacing: -.014em; }
.agenda-day .tail { font-weight: 400; }

/* --------------------------------------------------------------------------
   19. Floating card (install prompt, toasts), alerts, empty
   -------------------------------------------------------------------------- */
.float-card { position: fixed; z-index: 1035; left: max(.75rem, calc(var(--gutter) - .5rem)); bottom: calc(var(--tabbar-h) + var(--safe-bottom) + 1.25rem); width: min(calc(100% - 1.5rem), 340px); border-radius: var(--r-xl); padding: 1rem 1rem 1rem 1.125rem; animation: star-in 560ms var(--ease-out) both; }
@media (min-width: 992px) { .float-card { bottom: 1.25rem; } }
.float-card .x { position: absolute; top: .5rem; right: .5rem; }
.toast-pill { position: fixed; z-index: 1050; left: 50%; bottom: calc(var(--tabbar-h) + var(--safe-bottom) + 1.25rem); transform: translate(-50%, 12px); opacity: 0; display: flex; align-items: center; gap: .75rem; padding: .5rem .5rem .5rem 1.125rem; border-radius: var(--r-pill); background: var(--ink); color: var(--paper); font-size: .9375rem; box-shadow: var(--shadow-3); transition: opacity var(--dur-base) var(--ease-out), transform var(--dur-base) var(--ease-out); pointer-events: none; }
.toast-pill.is-shown { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
.toast-pill .btn { --bs-btn-color: var(--paper); --bs-btn-bg: rgba(255, 255, 255, .14); --bs-btn-hover-bg: rgba(255, 255, 255, .22); --bs-btn-hover-color: var(--paper); min-height: 34px; }
[data-bs-theme="dark"] .toast-pill .btn { --bs-btn-color: var(--paper); --bs-btn-bg: rgba(2, 7, 10, .1); --bs-btn-hover-bg: rgba(2, 7, 10, .18); --bs-btn-hover-color: var(--paper); }
@media (min-width: 992px) { .toast-pill { bottom: 1.5rem; } }

.alert { --bs-alert-border-width: 0; --bs-alert-border-radius: var(--r-lg); --bs-alert-padding-x: 1.125rem; --bs-alert-padding-y: 1rem; display: flex; align-items: flex-start; gap: .75rem; font-size: .9375rem; }
.alert svg { width: 20px; height: 20px; flex: none; margin-top: 1px; }
.alert-info { --bs-alert-bg: var(--blue-wash); --bs-alert-color: var(--ink); }
.alert-info svg { color: var(--cat-task-ink); }
.alert-success { --bs-alert-bg: var(--mint-wash); --bs-alert-color: var(--ink); }
.alert-success svg { color: var(--mint-ink); }
.alert-warning, .alert-attn { --bs-alert-bg: var(--orange-wash); --bs-alert-color: var(--ink); }
.alert-warning svg, .alert-attn svg { color: var(--orange-ink); }
.alert-danger { --bs-alert-bg: var(--danger-wash); --bs-alert-color: var(--ink); }
.alert-danger svg { color: var(--danger); }
.alert-secondary { --bs-alert-bg: var(--paper-2); --bs-alert-color: var(--ink); }

.empty { text-align: center; padding: 3rem 1rem; }
.empty .halo { width: 72px; height: 72px; margin: 0 auto 1rem; border-radius: 24px; display: grid; place-items: center; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line), var(--shadow-2); animation: float 6s var(--ease-in-out) infinite; }
.empty .halo svg { width: 28px; height: 28px; color: var(--blue); }
.empty .t-h3 { margin-bottom: .25rem; }
.empty p { color: var(--ink-2); margin: 0 auto; max-width: 26rem; }

.skeleton { border-radius: var(--r-sm); background: linear-gradient(90deg, var(--paper-2) 0%, var(--paper-3) 50%, var(--paper-2) 100%); background-size: 200% 100%; animation: shimmer 1.4s linear infinite; }
.sk-line { height: 12px; margin: .5rem 0; } .sk-60 { width: 60%; } .sk-40 { width: 40%; } .sk-80 { width: 80%; }

/* Pagination */
.pagination { --bs-pagination-border-width: 0; --bs-pagination-bg: transparent; --bs-pagination-color: var(--ink); --bs-pagination-hover-bg: var(--paper-2); --bs-pagination-hover-color: var(--ink); --bs-pagination-disabled-bg: transparent; --bs-pagination-disabled-color: var(--ink-3); --bs-pagination-active-bg: var(--ink); --bs-pagination-focus-box-shadow: none; gap: .25rem; }
.page-link { border-radius: var(--r-pill) !important; min-height: var(--target); display: inline-flex; align-items: center; padding: 0 1rem; }

/* Auth layout */
.auth { width: 100%; max-width: 420px; }
.auth-mark { width: 64px; height: 64px; border-radius: 18px; box-shadow: var(--shadow-2); }
.shell-bare.has-sky {
  background:
    radial-gradient(40% 14% at 25% 40%, rgba(255, 255, 255, .22), transparent 70%),
    radial-gradient(36% 12% at 78% 22%, rgba(255, 255, 255, .18), transparent 70%),
    linear-gradient(180deg, #0b4a7a 0%, #145f98 28%, #1c6fae 46%, #4aa2d8 58%, var(--paper) 58.2%);
}
.shell-bare.has-sky .lede { color: rgba(255, 255, 255, .9); font-size: 1.0625rem; }

/* --------------------------------------------------------------------------
   20. Motion — reveal on scroll, keyframes, reduced motion
   -------------------------------------------------------------------------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity var(--dur-reveal) var(--ease-out), transform var(--dur-reveal) var(--ease-out); }
.reveal.is-in { opacity: 1; transform: none; }
.reveal.d1 { transition-delay: 60ms; } .reveal.d2 { transition-delay: 120ms; } .reveal.d3 { transition-delay: 180ms; } .reveal.d4 { transition-delay: 240ms; }
.no-js .reveal { opacity: 1; transform: none; }
.press { transition: transform var(--dur-press) var(--ease-spring); }
.press:active { transform: scale(.97); }
.caret::after { content: ""; display: inline-block; width: 1.5px; height: 1.1em; margin-left: 2px; vertical-align: text-bottom; background: var(--orange); animation: caret 1s steps(1) infinite; }

@keyframes pulse-dot { 0% { box-shadow: 0 0 0 0 rgba(252, 115, 77, .6); } 80%, 100% { box-shadow: 0 0 0 8px rgba(252, 115, 77, 0); } }
@keyframes rise { from { transform: translateY(18px); } to { transform: none; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes fade-rise { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@keyframes star-in { from { opacity: 0; transform: translateY(16px) scale(.98); } to { opacity: 1; transform: none; } }
@keyframes caret { 50% { opacity: 0; } }
@keyframes shimmer { from { background-position: -200% 0; } to { background-position: 200% 0; } }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes cloud-drift { from { transform: translate3d(-2%, 0, 0); } to { transform: translate3d(3%, -2%, 0); } }
@keyframes glow-drift { to { opacity: .6; transform: translate(-40px, 30px) scale(1.15); } }
@keyframes grow-x { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes typing { 0%, 60%, 100% { transform: none; opacity: .5; } 30% { transform: translateY(-3px); opacity: 1; } }
@keyframes mark-breathe { 0%, 100% { transform: scale(1); } 50% { transform: scale(.72); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}

/* --------------------------------------------------------------------------
   20b. App wiring — what the real views need beyond the original theme
   -------------------------------------------------------------------------- */
/* ASP.NET hides an empty validation summary with an inline style, which the CSP blocks: hide it here instead. */
.validation-summary-valid { display: none !important; }
.validation-summary-errors ul { margin: 0; padding-left: 1.1rem; }
.field-error, .field-validation-error { display: block; color: var(--danger); font-size: .875rem; margin-top: .3rem; }
.field-validation-valid { display: none; }
.form-control.input-validation-error, .form-select.input-validation-error { border-color: var(--danger); }
.pre-wrap { white-space: pre-wrap; }
/* Signed-out pages: messages sit in the same centred column as the form. */
.bare-stack { width: 100%; display: grid; justify-items: center; gap: 1rem; }
[data-bs-theme="dark"] { --bs-danger-rgb: 255, 122, 112; --bs-success-rgb: 90, 214, 166; }

/* Sticky glass holder for the child chips (Tasks): the chip row scrolls inside it. */
.sticky-bar { position: sticky; top: calc(var(--nav-h) + var(--safe-top) - .25rem); z-index: 5; padding: .5rem; margin: 0 -.5rem; border-radius: var(--r-pill); }
.sticky-bar .chipbar { margin: 0; padding: 0; }

/* Attention count inside nav links, the sheet and the tab bar */
.navlink .dot-count { margin-left: .15rem; }
.navlink[aria-current="page"] .dot-count { box-shadow: none; }
.sheet-links a .badge-dot:empty { display: none; }

/* Announcements can appear in the calendar too */
.cal-entry.cat-announcement { background: var(--cat-announcement-tint); color: var(--cat-announcement-ink); }

/* "I have read this" on phones and tablets (item page): stays just above the tab bar until it is pressed. The message and the install card,
   which float in the same place, move above it or stay away. */
.ack-bar { position: sticky; z-index: 1020; bottom: calc(var(--tabbar-h) + var(--safe-bottom) + 1.25rem); display: flex; justify-content: center; margin: 0 calc(.75rem - var(--gutter)); pointer-events: none; }
.ack-bar form { width: 100%; max-width: 440px; padding: .5rem; border-radius: 22px; pointer-events: auto; }
@media (max-width: 991.98px) {
  html:has(.ack-bar) { scroll-padding-bottom: calc(var(--tabbar-h) + var(--safe-bottom) + 6rem); }
  body:has(.ack-bar) .toast-pill { bottom: calc(var(--tabbar-h) + var(--safe-bottom) + 1.75rem + 60px); }
  body:has(.ack-bar) [data-install-banner] { display: none; }
}

/* A card that needs setting up (unmapped group) gets the same quiet orange edge as an overdue item */
.card.is-attn { box-shadow: inset 0 0 0 1px rgba(252, 115, 77, .55), var(--shadow-1); }

/* A switched-off rule reads as quieter */
.list-group-item.is-off { color: var(--ink-3); }

/* Unread rows (recent news) get the blue dot, like unread items */
.row-item.is-unread .title::before { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--blue); margin-right: .5rem; vertical-align: middle; }

/* Avatars sitting on a button (desktop menu) and in chips */
.avatar-btn .avatar { width: 34px; height: 34px; }

/* The reply box grows with what the parent types (site.js) */
.composer textarea { max-height: 12rem; overflow-y: auto; }

/* A section opened by its address (reminders) stops below the floating navigation */
[data-reminders] [id] { scroll-margin-top: calc(var(--nav-h) + var(--safe-top) + .75rem); }

/* The page the parent is on, marked on a button of the menu sheet */
.sheet .btn[aria-current="page"] { box-shadow: inset 0 0 0 2px var(--ink); }

/* Labels on dark feature cards stay readable */
.card-night .tag { background: rgba(255, 255, 255, .1); color: #f3f6f8; }
.card-night .tag-ink { background: rgba(255, 255, 255, .14); color: #f3f6f8; }

/* --------------------------------------------------------------------------
   21. Print
   -------------------------------------------------------------------------- */
@media print {
  .topnav, .tabbar, .sheet, .sheet-backdrop, .float-card, .toast-pill, .no-print { display: none !important; }
  .shell { padding: 0; }
  .card, .item { box-shadow: none; border: 1px solid #ccc; }
  .sky { color: #000; background: none; border: 1px solid #ccc; }
}
