/* LocLedger design system — warm-earth, Sisterlocks-grounded,
   built on Pico classless. Variables are the source of truth; map
   Pico's tokens to ours and style components from the same well. */

:root {
  /* ── Color: warm earth + cream + gold ────────────────────────── */
  --ll-cream:       #FBF7F1;  /* page background */
  --ll-cream-soft: #FFFCF6;   /* cards / surfaces */
  --ll-cream-deep: #F1E9DA;   /* alternating rows / hover */
  --ll-tan:        #E8DDC9;   /* subtle borders */
  --ll-tan-deep:   #C9B998;   /* strong borders / dividers */

  --ll-espresso:   #2D1F14;   /* primary text — warm dark brown */
  --ll-taupe:      #6B5544;   /* secondary text */
  --ll-taupe-soft: #9C8870;   /* muted / placeholder text */

  --ll-brand:        #8B4513;  /* saddle brown — brand primary */
  --ll-brand-hover:  #6F360F;  /* darker, on hover/active */
  --ll-brand-soft:   #A5663C;  /* lighter for soft-fills */
  --ll-brand-wash:   rgba(139, 69, 19, 0.08);

  --ll-gold:         #C49A4A;  /* burnished gold — accent / today */
  --ll-gold-deep:    #A07E32;
  --ll-gold-wash:    rgba(196, 154, 74, 0.12);

  --ll-sage:         #5E7A4B;  /* success / due-soon */
  --ll-sage-wash:    rgba(94, 122, 75, 0.10);

  --ll-terracotta:   #A85A2B;  /* warning / drift */
  --ll-terracotta-wash: rgba(168, 90, 43, 0.10);

  --ll-berry:        #8B2C3E;  /* error / overdue */
  --ll-berry-wash:   rgba(139, 44, 62, 0.08);

  /* ── Typography ──────────────────────────────────────────────── */
  /* ui-serif resolves to: New York on iOS, Noto/Source Serif on
     Android, Cambria/Georgia on Windows. Real warm serifs already
     on every device; no font download. */
  --ll-font-display: ui-serif, "New York", Cambria, Georgia, "Iowan Old Style", serif;
  --ll-font-body:    ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Inter", "Helvetica Neue", sans-serif;
  --ll-font-mono:    ui-monospace, "SF Mono", "Cascadia Mono", "JetBrains Mono", Menlo, Consolas, monospace;

  /* Modular scale (Major Second 1.125) */
  --ll-text-xs:  0.78rem;
  --ll-text-sm:  0.875rem;
  --ll-text-base: 1rem;
  --ll-text-md:  1.125rem;
  --ll-text-lg:  1.27rem;
  --ll-text-xl:  1.5rem;
  --ll-text-2xl: 1.875rem;
  --ll-text-3xl: 2.4rem;
  --ll-text-4xl: 3rem;

  --ll-leading-tight: 1.15;
  --ll-leading-snug:  1.3;
  --ll-leading-body:  1.55;
  --ll-leading-loose: 1.75;

  /* ── Spacing scale ──────────────────────────────────────────── */
  --ll-space-1: 0.25rem;
  --ll-space-2: 0.5rem;
  --ll-space-3: 0.75rem;
  --ll-space-4: 1rem;
  --ll-space-5: 1.5rem;
  --ll-space-6: 2rem;
  --ll-space-8: 3rem;
  --ll-space-10: 4rem;
  --ll-space-12: 6rem;

  /* ── Radius / Shadow ────────────────────────────────────────── */
  --ll-radius-sm: 6px;
  --ll-radius-md: 10px;
  --ll-radius-lg: 16px;
  --ll-radius-pill: 999px;

  --ll-shadow-sm: 0 1px 2px rgba(45, 31, 20, 0.06);
  --ll-shadow-md: 0 4px 16px rgba(45, 31, 20, 0.08);
  --ll-shadow-lg: 0 12px 36px rgba(45, 31, 20, 0.10);

  --pico-font-family-sans-serif: var(--ll-font-body);
  --pico-font-family-serif: var(--ll-font-display);
  --pico-font-family: var(--ll-font-body);
  --pico-line-height: var(--ll-leading-body);
}

/* CRITICAL: Pico defines its theme variables on [data-theme=light]
   (specificity 0,1,0). Overriding on :root (0,0,1) is INERT — Pico
   wins the cascade. We match Pico's selector specificity here, and
   source-order (this file loads after pico.classless.min.css) tips
   it our way. v0.21.31 had this bug; v0.21.32 fixes it. */
[data-theme=light] {
  --pico-background-color: var(--ll-cream);
  --pico-color: var(--ll-espresso);
  --pico-text-selection-color: var(--ll-gold-wash);

  --pico-h1-color: var(--ll-espresso);
  --pico-h2-color: var(--ll-espresso);
  --pico-h3-color: var(--ll-espresso);
  --pico-h4-color: var(--ll-espresso);
  --pico-h5-color: var(--ll-espresso);
  --pico-h6-color: var(--ll-espresso);

  --pico-muted-color: var(--ll-taupe);
  --pico-muted-border-color: var(--ll-tan);

  /* Primary = saddle brown brand. All seven primary-* axes. */
  --pico-primary: var(--ll-brand);
  --pico-primary-background: var(--ll-brand);
  --pico-primary-border: var(--ll-brand);
  --pico-primary-underline: var(--ll-brand-soft);
  --pico-primary-hover: var(--ll-brand-hover);
  --pico-primary-hover-background: var(--ll-brand-hover);
  --pico-primary-hover-border: var(--ll-brand-hover);
  --pico-primary-hover-underline: var(--ll-brand-hover);
  --pico-primary-focus: var(--ll-gold-wash);
  --pico-primary-inverse: var(--ll-cream);

  /* Secondary = taupe. Was slate-blue by default. */
  --pico-secondary: var(--ll-taupe);
  --pico-secondary-background: var(--ll-taupe);
  --pico-secondary-border: var(--ll-taupe);
  --pico-secondary-underline: var(--ll-tan-deep);
  --pico-secondary-hover: var(--ll-espresso);
  --pico-secondary-hover-background: var(--ll-espresso);
  --pico-secondary-hover-border: var(--ll-espresso);
  --pico-secondary-hover-underline: var(--ll-espresso);
  --pico-secondary-focus: var(--ll-gold-wash);
  --pico-secondary-inverse: var(--ll-cream);

  /* Contrast = warm dark espresso. Was near-black with blue tint. */
  --pico-contrast: var(--ll-espresso);
  --pico-contrast-background: var(--ll-espresso);
  --pico-contrast-border: var(--ll-espresso);
  --pico-contrast-underline: var(--ll-tan-deep);
  --pico-contrast-hover: var(--ll-brand);
  --pico-contrast-hover-background: var(--ll-brand);
  --pico-contrast-hover-border: var(--ll-brand);
  --pico-contrast-hover-underline: var(--ll-brand);
  --pico-contrast-focus: var(--ll-gold-wash);
  --pico-contrast-inverse: var(--ll-cream);

  /* Cards */
  --pico-card-background-color: var(--ll-cream-soft);
  --pico-card-sectioning-background-color: var(--ll-cream-soft);
  --pico-card-border-color: var(--ll-tan);
  --pico-card-box-shadow: var(--ll-shadow-sm);

  /* Form elements */
  --pico-form-element-background-color: var(--ll-cream-soft);
  --pico-form-element-color: var(--ll-espresso);
  --pico-form-element-border-color: var(--ll-tan-deep);
  --pico-form-element-placeholder-color: var(--ll-taupe-soft);
  --pico-form-element-focus-color: var(--ll-brand);
  --pico-form-element-active-background-color: var(--ll-cream-soft);
  --pico-form-element-active-border-color: var(--ll-brand);
  /* Checked checkbox/radio fill — Pico uses this for the box itself
     when ticked. Default was Pico azure; must be brand brown so it
     reads as part of the warm palette. The checkmark glyph inside
     comes from --pico-form-element-color (set to espresso elsewhere)
     against this brown background — high contrast. */
  --pico-form-element-selected-background-color: var(--ll-brand);
  --pico-form-element-spacing-vertical: 0.7rem;
  --pico-form-element-spacing-horizontal: 0.9rem;

  --pico-form-element-valid-border-color: var(--ll-sage);
  --pico-form-element-valid-active-border-color: var(--ll-sage);
  --pico-form-element-valid-focus-color: var(--ll-sage-wash);
  --pico-form-element-invalid-border-color: var(--ll-berry);
  --pico-form-element-invalid-active-border-color: var(--ll-berry);
  --pico-form-element-invalid-focus-color: var(--ll-berry-wash);

  /* Semantic + typographic accents */
  --pico-mark-background-color: var(--ll-gold-wash);
  --pico-mark-color: var(--ll-espresso);
  --pico-ins-color: var(--ll-sage);
  --pico-del-color: var(--ll-berry);

  /* Code */
  --pico-code-color: var(--ll-espresso);
  --pico-code-background: var(--ll-cream-deep);
  --pico-code-kbd-background-color: var(--ll-espresso);
  --pico-code-kbd-color: var(--ll-cream);

  /* Blockquote */
  --pico-blockquote-border-color: var(--ll-tan-deep);
  --pico-blockquote-footer-color: var(--ll-taupe);

  /* Switch / range / tables / tooltips */
  --pico-switch-background-color: var(--ll-tan-deep);
  --pico-switch-checked-background-color: var(--ll-brand);
  --pico-switch-color: var(--ll-cream);
  --pico-range-thumb-color: var(--ll-brand);
  --pico-range-thumb-border-color: var(--ll-brand);
  --pico-range-thumb-active-color: var(--ll-brand-hover);
  --pico-table-border-color: var(--ll-tan);
  --pico-table-row-stripped-background-color: var(--ll-cream-soft);
  --pico-tooltip-background-color: var(--ll-espresso);
  --pico-tooltip-color: var(--ll-cream);

  --pico-modal-overlay-background-color: rgba(45, 31, 20, 0.55);
}

/* Belt-and-braces background — explicit on html + body so even an
   ancient Pico build that hardcodes #fff somewhere is overridden. */
html, body {
  background: var(--ll-cream) !important;
  color: var(--ll-espresso);
}

/* ── Belt-and-braces button colors ────────────────────────────
   Pico's button rule is high-specificity multi-selector; the variable
   overrides above SHOULD reach it, but force direct property values
   too so a stale-cache victim still sees brand brown, not Pico teal. */
button:not([class*="outline"]),
[role="button"]:not([class*="outline"]),
input[type="submit"]:not([class*="outline"]),
input[type="button"]:not([class*="outline"]) {
  background-color: var(--ll-brand);
  border-color: var(--ll-brand);
  color: var(--ll-cream);
}
button:not([class*="outline"]):hover,
button:not([class*="outline"]):focus,
[role="button"]:not([class*="outline"]):hover,
[role="button"]:not([class*="outline"]):focus,
input[type="submit"]:not([class*="outline"]):hover,
input[type="button"]:not([class*="outline"]):hover {
  background-color: var(--ll-brand-hover);
  border-color: var(--ll-brand-hover);
  color: var(--ll-cream);
}
/* Outline variant — used for destructive secondary actions (Sign out) */
button.outline,
[role="button"].outline,
.outline[role="button"] {
  background-color: transparent;
  border: 1.5px solid var(--ll-brand);
  color: var(--ll-brand);
}
button.outline:hover,
[role="button"].outline:hover {
  background-color: var(--ll-brand-wash);
  border-color: var(--ll-brand-hover);
  color: var(--ll-brand-hover);
}

/* ── Belt-and-braces link colors ──────────────────────────────
   Default <a> tags throughout the app should read brown, not Pico teal. */
a:not(.brand):not(.brand-link):not([role="button"]):not(.primary-nav a):not(.tabs a):not(.landing-cta):not(.feature-card a) {
  color: var(--ll-brand);
  text-decoration-color: var(--ll-tan-deep);
  text-underline-offset: 0.18em;
}
a:not(.brand):not(.brand-link):not([role="button"]):hover {
  color: var(--ll-brand-hover);
  text-decoration-color: var(--ll-brand);
}

/* ── Sign-out confirmation page ───────────────────────────────── */
.logout-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  align-items: center;
  margin-top: var(--ll-space-3);
}

/* ── Header hgroup fix — stack wordmark + subtitle ───────────── */
/* Pico's <hgroup> puts h1 and the following <p> inline-block which
   creates the awkward "LocLedger Today, Saturday 13 June 2026." mash.
   Force vertical stack with the subtitle as a quiet eyebrow under
   the wordmark. */
body > header hgroup {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.25rem;
}
body > header hgroup > p {
  margin: 0;
  font-family: var(--ll-font-body);
  font-size: var(--ll-text-sm);
  color: var(--ll-taupe);
  letter-spacing: 0.01em;
  font-weight: 400;
}

/* ── Belt-and-braces checked-state ───────────────────────────
   Direct property override on :checked so a stale browser cache or
   any Pico-future-version change can't paint check boxes blue. */
[type="checkbox"]:checked,
[type="radio"]:checked {
  background-color: var(--ll-brand) !important;
  border-color: var(--ll-brand) !important;
}
[type="checkbox"][role="switch"]:checked {
  background-color: var(--ll-brand) !important;
  border-color: var(--ll-brand) !important;
}

/* ── Belt-and-braces input/select/textarea focus border ──────
   Pico's `[aria-invalid=false]:is(:active,:focus)` rule carries
   !important and pins border to --pico-form-element-valid-active-
   border-color which our :root chain SHOULD override but isn't reaching
   on Edge for select widgets. Force direct property values with
   !important and kill the browser-native focus outline that Edge
   draws on top of CSS borders for select. */
input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]):not([type="button"]):focus,
input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]):not([type="button"]):active,
select:focus,
select:active,
textarea:focus,
textarea:active {
  border-color: var(--ll-brand) !important;
  outline: none !important;
  box-shadow: 0 0 0 3px var(--ll-gold-wash);
}
/* Same for forms that mark fields valid/invalid via aria. */
input[aria-invalid="false"]:focus,
select[aria-invalid="false"]:focus,
textarea[aria-invalid="false"]:focus {
  border-color: var(--ll-brand) !important;
  box-shadow: 0 0 0 3px var(--ll-gold-wash);
}
input[aria-invalid="true"]:focus,
select[aria-invalid="true"]:focus,
textarea[aria-invalid="true"]:focus {
  border-color: var(--ll-berry) !important;
  box-shadow: 0 0 0 3px var(--ll-berry-wash);
}

/* ── Checkbox + label + help-text layout ─────────────────────
   Form template renders the checkbox, its label text, AND a long
   help-text <small> all inside one <label>. With Pico defaults the
   small wraps awkwardly underneath the checkbox. Force the small
   to be a separate block below the entire row, indented to align
   with the label text. */
label:has(> input[type="checkbox"]),
label:has(> input[type="radio"]) {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.25rem;
}
label:has(> input[type="checkbox"]) > small,
label:has(> input[type="radio"]) > small {
  display: block;
  flex-basis: 100%;
  margin-left: 1.85rem;
  margin-top: 0.3rem;
  color: var(--ll-taupe);
  font-size: var(--ll-text-sm);
  line-height: var(--ll-leading-snug);
}

/* ── Client / record metadata definition list ────────────────
   The bare <dl><dt><dd> from clients/detail.html rendered as
   undifferentiated text with no hierarchy. This converts it to a
   typographic table: labels become uppercase gold eyebrows, values
   are bigger serif in espresso, notes get a gold-bordered callout
   block. Built for `.client-meta` class specifically so it doesn't
   leak to other dl uses (e.g. session details). */
.client-meta {
  margin: var(--ll-space-4) 0 var(--ll-space-6);
  padding: 0;
  display: block;
}
.client-meta dt {
  font-family: var(--ll-font-body);
  font-size: var(--ll-text-xs);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--ll-gold-deep);
  font-weight: 600;
  margin-top: var(--ll-space-5);
  margin-bottom: 0.3rem;
  line-height: 1.4;
}
.client-meta dt:first-of-type {
  margin-top: 0;
}
.client-meta dd {
  font-family: var(--ll-font-display);
  font-size: var(--ll-text-lg);
  color: var(--ll-espresso);
  margin: 0 0 0.25rem;
  padding: 0;
  letter-spacing: -0.01em;
  line-height: var(--ll-leading-snug);
}
.client-meta dd strong {
  font-weight: 600;
  font-size: var(--ll-text-xl);
  color: var(--ll-brand);
  font-family: var(--ll-font-display);
}
.client-meta-notes {
  font-family: var(--ll-font-body);
  font-size: var(--ll-text-base);
  background: var(--ll-cream-soft);
  border-left: 3px solid var(--ll-gold);
  padding: 0.7rem 1rem;
  border-radius: 0 var(--ll-radius-sm) var(--ll-radius-sm) 0;
  color: var(--ll-espresso);
  line-height: var(--ll-leading-loose);
  margin-top: 0.2rem;
}
.client-meta-notes em.empty {
  color: var(--ll-taupe-soft);
  font-style: italic;
  font-family: var(--ll-font-display);
}

/* ── Bucket-empty / Add-first-item callouts ─────────────────── */
/* Improve the bare "No clients yet" / "No products yet" empty states
   so they feel intentional, not "we forgot to design this." */
.empty,
main > p:only-child {
  color: var(--ll-taupe);
}
main h1 + p.empty,
main h2 + p.empty {
  padding: var(--ll-space-4) 0;
  font-style: italic;
  font-family: var(--ll-font-display);
  font-size: var(--ll-text-md);
}

/* ── Base typography ──────────────────────────────────────────── */
html { font-family: var(--ll-font-body); }
body { background: var(--ll-cream); color: var(--ll-espresso); }

h1, h2, h3 {
  font-family: var(--ll-font-display);
  letter-spacing: -0.018em;
  line-height: var(--ll-leading-tight);
  color: var(--ll-espresso);
}
h1 { font-size: var(--ll-text-2xl); font-weight: 600; }
h2 { font-size: var(--ll-text-xl); font-weight: 600; }
h3 { font-size: var(--ll-text-lg); font-weight: 600; }
h4, h5, h6 { font-family: var(--ll-font-body); font-weight: 600; }

p, li { line-height: var(--ll-leading-body); }

/* ── Page chrome ──────────────────────────────────────────────── */
body > header,
body > main,
body > footer {
  max-width: 880px;
  margin-inline: auto;
  padding-inline: max(1.25rem, env(safe-area-inset-left)) max(1.25rem, env(safe-area-inset-right));
}

body > header {
  padding-block: max(1.25rem, env(safe-area-inset-top)) 1.25rem;
  border-bottom: 1px solid var(--ll-tan);
  margin-bottom: var(--ll-space-5);
}

body > main { padding-block: var(--ll-space-4) var(--ll-space-8); }

body > footer {
  border-top: 1px solid var(--ll-tan);
  margin-top: var(--ll-space-8);
  padding-block: var(--ll-space-5) max(var(--ll-space-5), env(safe-area-inset-bottom));
  color: var(--ll-taupe);
  font-size: var(--ll-text-sm);
}

body > footer a {
  color: var(--ll-taupe);
  text-decoration: none;
  border-bottom: 1px solid var(--ll-tan-deep);
  padding-bottom: 0.05em;
}
body > footer a:hover { color: var(--ll-brand); border-bottom-color: var(--ll-brand); }

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: var(--ll-space-4);
  margin-bottom: var(--ll-space-3);
}

/* ── Brand mark + wordmark ───────────────────────────────────── */
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  color: inherit;
}
.brand:hover, .brand:focus, .brand:visited { color: inherit; text-decoration: none; }

.brand-mark {
  display: inline-block;
  flex: 0 0 auto;
  width: 32px;
  height: 32px;
  color: var(--ll-brand);
}

.brand-wordmark {
  font-family: var(--ll-font-display);
  font-size: var(--ll-text-xl);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1;
  color: var(--ll-espresso);
}
.brand-wordmark .brand-loc { color: var(--ll-brand); }
.brand-wordmark .brand-ledger { color: var(--ll-espresso); }

.brand-tagline {
  font-size: var(--ll-text-sm);
  color: var(--ll-taupe);
  margin: 0.2rem 0 0;
  letter-spacing: 0;
}

/* legacy .brand-link class kept for compat with any straggling templates */
.brand-link { text-decoration: none; color: inherit; }
.brand-link:hover, .brand-link:focus { text-decoration: none; color: inherit; }

/* ── Primary nav ──────────────────────────────────────────────── */
.primary-nav {
  display: flex;
  gap: 0.5rem;
  margin: var(--ll-space-3) 0 0;
  flex-wrap: wrap;
}

.primary-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0.4rem 0.95rem;
  border-radius: var(--ll-radius-pill);
  text-decoration: none;
  color: var(--ll-taupe);
  background: transparent;
  border: 1px solid transparent;
  font-size: var(--ll-text-sm);
  font-weight: 500;
  transition: color 120ms ease, background 120ms ease, border-color 120ms ease;
}
.primary-nav a:hover {
  color: var(--ll-espresso);
  background: var(--ll-cream-deep);
}
.primary-nav a[aria-current="page"] {
  color: var(--ll-brand);
  background: var(--ll-brand-wash);
  border-color: var(--ll-brand-wash);
  font-weight: 600;
}

/* ── Buttons (Pico inherits, but lift the primary look) ──────── */
button, [role="button"], input[type="submit"] {
  font-family: var(--ll-font-body);
  font-weight: 600;
  letter-spacing: 0.01em;
  border-radius: var(--ll-radius-sm);
}

button.outline, [role="button"].outline {
  background: transparent;
  color: var(--ll-brand);
  border: 1.5px solid var(--ll-brand);
}
button.outline:hover {
  background: var(--ll-brand-wash);
  color: var(--ll-brand-hover);
  border-color: var(--ll-brand-hover);
}

/* ── Inputs ───────────────────────────────────────────────────── */
input, select, textarea {
  font-family: var(--ll-font-body);
  border-radius: var(--ll-radius-sm);
}

/* ── Cards ────────────────────────────────────────────────────── */
.card {
  background: var(--ll-cream-soft);
  border: 1px solid var(--ll-tan);
  border-radius: var(--ll-radius-md);
  padding: var(--ll-space-5);
  box-shadow: var(--ll-shadow-sm);
}

/* ── Auth surfaces (login, signup-closed, password-reset, MFA) ── */
.auth-card {
  max-width: 28rem;
  margin: var(--ll-space-6) auto;
  padding: var(--ll-space-6);
  background: var(--ll-cream-soft);
  border: 1px solid var(--ll-tan);
  border-radius: var(--ll-radius-lg);
  box-shadow: var(--ll-shadow-md);
}
.auth-card h1, .auth-card h2 { margin-top: 0; }

/* ── Tab pills ────────────────────────────────────────────────── */
.tabs {
  display: flex;
  gap: 0.5rem;
  margin-bottom: var(--ll-space-4);
  border-bottom: 1px solid var(--ll-tan);
  padding-bottom: var(--ll-space-2);
}
.tabs a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0.45rem 1rem;
  border-radius: var(--ll-radius-pill);
  text-decoration: none;
  background: transparent;
  color: var(--ll-taupe);
  border: 1px solid var(--ll-tan);
  font-weight: 500;
  font-size: var(--ll-text-sm);
}
.tabs a:hover { color: var(--ll-espresso); background: var(--ll-cream-deep); }
.tabs a[aria-current="page"] {
  background: var(--ll-brand);
  color: var(--ll-cream);
  border-color: var(--ll-brand);
}

/* ── List items (feed, clients) ──────────────────────────────── */
.item, .client-row {
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--ll-tan);
}
.item:last-child, .client-row:last-child { border-bottom: none; }
.item .meta, .client-row .meta {
  font-size: var(--ll-text-sm);
  color: var(--ll-taupe);
  margin-top: 0.2rem;
}
.client-row { display: flex; justify-content: space-between; align-items: center; }
.client-row a { font-weight: 600; color: var(--ll-espresso); text-decoration: none; }
.client-row a:hover { color: var(--ll-brand); }

.empty { color: var(--ll-taupe-soft); }

/* ── Dashboard hero (overdue/today/soon/upcoming bucket counts) ── */
.home-hero {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 0.85rem;
  margin: var(--ll-space-3) 0 var(--ll-space-6);
}
.home-hero > div {
  padding: 0.8rem 1rem;
  border-radius: var(--ll-radius-md);
  border: 1px solid var(--ll-tan);
  background: var(--ll-cream-soft);
}
.home-hero strong {
  display: block;
  font-family: var(--ll-font-display);
  font-size: var(--ll-text-2xl);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--ll-espresso);
}
.home-hero small {
  color: var(--ll-taupe);
  font-size: var(--ll-text-xs);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  display: block;
  margin-top: 0.4rem;
}
.home-hero .hero-overdue {
  border-color: var(--ll-berry);
  background: var(--ll-berry-wash);
}
.home-hero .hero-overdue strong { color: var(--ll-berry); }
.home-hero .hero-flag {
  border-color: var(--ll-terracotta);
  background: var(--ll-terracotta-wash);
}
.home-hero .hero-flag strong { color: var(--ll-terracotta); }

.bucket-overdue { color: var(--ll-berry); }
.bucket-today { color: var(--ll-gold-deep); }

.home-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.7rem 1rem;
  margin-bottom: 0.4rem;
  border-radius: var(--ll-radius-sm);
  background: transparent;
  gap: 1rem;
  transition: background 100ms ease;
}
.home-row:hover { background: var(--ll-cream-deep); }
.home-row.tone-overdue  { background: var(--ll-berry-wash);     border-left: 4px solid var(--ll-berry); }
.home-row.tone-today    { background: var(--ll-gold-wash);      border-left: 4px solid var(--ll-gold); }
.home-row.tone-soon     { background: var(--ll-sage-wash);      border-left: 4px solid var(--ll-sage); }
.home-row.tone-upcoming { border-left: 4px solid var(--ll-tan); }
.home-row.tone-new      { border-left: 4px solid var(--ll-tan); }

.home-row .meta {
  font-size: var(--ll-text-sm);
  color: var(--ll-taupe);
  margin-top: 0.2rem;
}
.home-flags { display: flex; gap: 0.3rem; flex-wrap: wrap; }

/* ── Retie / status badges ───────────────────────────────────── */
.retie-due {
  background: var(--ll-sage-wash);
  border-left: 4px solid var(--ll-sage);
  padding: 0.7rem 1rem;
  margin: var(--ll-space-4) 0;
  border-radius: 0 var(--ll-radius-sm) var(--ll-radius-sm) 0;
}

.status-warn    { color: var(--ll-terracotta); font-weight: 600; }
.status-overdue { color: var(--ll-berry);      font-weight: 600; }

.chip {
  display: inline-block;
  padding: 0.2rem 0.7rem;
  margin: 0.15rem 0.2rem 0.15rem 0;
  border-radius: var(--ll-radius-pill);
  border: 1px solid var(--ll-tan);
  background: var(--ll-cream-soft);
  color: var(--ll-taupe);
  font-size: var(--ll-text-xs);
  line-height: 1.7;
  white-space: nowrap;
}
.chip-warn {
  border-color: var(--ll-terracotta);
  color: var(--ll-terracotta);
  background: var(--ll-terracotta-wash);
}

.product-dot {
  display: inline-block;
  width: 0.55em;
  height: 0.55em;
  border-radius: 50%;
  background: var(--ll-gold);
  margin-right: 0.35em;
  vertical-align: middle;
}

/* ── Flash messages ──────────────────────────────────────────── */
.flash {
  padding: 0.75rem 1rem;
  margin-bottom: var(--ll-space-4);
  border-radius: var(--ll-radius-sm);
}
.flash-success { border-left: 4px solid var(--ll-sage);       background: var(--ll-sage-wash);       color: var(--ll-espresso); }
.flash-error   { border-left: 4px solid var(--ll-berry);      background: var(--ll-berry-wash);      color: var(--ll-espresso); }
.flash-warning { border-left: 4px solid var(--ll-terracotta); background: var(--ll-terracotta-wash); color: var(--ll-espresso); }

/* ── htmx loading ────────────────────────────────────────────── */
.htmx-indicator { opacity: 0; transition: opacity 200ms ease-in; }
.htmx-request .htmx-indicator,
.htmx-request.htmx-indicator { opacity: 1; }

/* ── Photo grids — central to a Sisterlocks app ──────────────── */
.progression-list {
  display: flex;
  flex-direction: column;
  gap: var(--ll-space-4);
  margin-top: var(--ll-space-3);
}
.progression-card {
  margin: 0;
  padding: var(--ll-space-3) var(--ll-space-4);
  background: var(--ll-cream-soft);
  border: 1px solid var(--ll-tan);
  border-radius: var(--ll-radius-md);
}
.progression-header { margin-bottom: var(--ll-space-2); }
.progression-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 0.5rem; }
.progression-tile {
  margin: 0;
  border-radius: var(--ll-radius-sm);
  overflow: hidden;
  border: 1px solid var(--ll-tan);
  background: var(--ll-cream-soft);
}
.progression-tile a { display: block; line-height: 0; }
.progression-tile img { width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; }
.progression-tile figcaption {
  padding: 0.4rem 0.6rem;
  background: var(--ll-cream-deep);
  text-align: center;
  font-size: var(--ll-text-xs);
  color: var(--ll-taupe);
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.photo-group { margin-top: var(--ll-space-4); }
.photo-group + .photo-group { margin-top: var(--ll-space-6); }
.photo-group-title {
  margin: 0 0 var(--ll-space-2);
  font-family: var(--ll-font-display);
  font-size: var(--ll-text-md);
  font-weight: 600;
  color: var(--ll-espresso);
}
.photo-group-count {
  color: var(--ll-taupe);
  font-weight: normal;
  font-family: var(--ll-font-body);
  font-size: var(--ll-text-sm);
  margin-left: 0.4rem;
}

.photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 0.75rem;
  margin: var(--ll-space-3) 0 0;
}
.photo-tile {
  margin: 0;
  border-radius: var(--ll-radius-md);
  overflow: hidden;
  border: 1px solid var(--ll-tan);
  background: var(--ll-cream-soft);
  box-shadow: var(--ll-shadow-sm);
  transition: transform 150ms ease, box-shadow 150ms ease;
}
.photo-tile:hover {
  transform: translateY(-2px);
  box-shadow: var(--ll-shadow-md);
}
.photo-tile a { display: block; line-height: 0; }
.photo-tile img { width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; }
.photo-tile figcaption {
  padding: 0.45rem 0.6rem;
  background: var(--ll-cream-soft);
  font-size: var(--ll-text-xs);
  color: var(--ll-taupe);
}

.photo-delete-btn {
  min-height: 44px;
  display: block;
  margin-top: 0.4rem;
  color: var(--ll-berry);
}

.share-status { margin-left: 0.5rem; display: inline-block; }
.share-status.flash { padding: 0.25rem 0.6rem; margin-bottom: 0; }

.bucket-hint {
  margin: -0.4rem 0 0.6rem;
  color: var(--ll-taupe);
  font-size: var(--ll-text-sm);
}

/* ── Landing page ─────────────────────────────────────────────── */
.landing {
  margin-top: var(--ll-space-2);
}

/* ── Landing — Hero ───────────────────────────────────────────── */
.landing-hero {
  padding: var(--ll-space-10) 0 var(--ll-space-10);
  text-align: center;
  position: relative;
}

.hero-ornament {
  display: block;
  width: 140px;
  height: 24px;
  margin: 0 auto var(--ll-space-5);
  color: var(--ll-gold-deep);
}

.hero-eyebrow {
  font-family: var(--ll-font-body);
  font-size: var(--ll-text-xs);
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--ll-taupe);
  margin: 0 0 var(--ll-space-5);
  font-weight: 600;
}

.hero-heading {
  font-family: var(--ll-font-display);
  font-size: clamp(2.6rem, 8.5vw, 5rem);
  font-weight: 500;
  letter-spacing: -0.035em;
  line-height: 1.02;
  margin: 0 0 var(--ll-space-6);
  color: var(--ll-espresso);
}
.hero-heading .hero-line { display: block; }
.hero-heading em {
  font-style: italic;
  font-weight: 400;
  color: var(--ll-brand);
}
.hero-heading .hero-line-accent {
  color: var(--ll-brand);
  font-style: italic;
  font-weight: 400;
}

.hero-lead {
  font-family: var(--ll-font-display);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(1.1rem, 2.6vw, 1.45rem);
  line-height: 1.5;
  color: var(--ll-taupe);
  max-width: 34rem;
  margin: 0 auto var(--ll-space-8);
  letter-spacing: 0;
}

.landing-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 1.05rem 2.4rem;
  background: var(--ll-brand);
  color: var(--ll-cream);
  font-family: var(--ll-font-body);
  font-weight: 600;
  font-size: var(--ll-text-md);
  letter-spacing: 0.01em;
  text-decoration: none;
  border-radius: var(--ll-radius-pill);
  border: 2px solid var(--ll-brand);
  box-shadow: 0 8px 22px rgba(139, 69, 19, 0.22);
  transition: transform 120ms ease, box-shadow 150ms ease, background 150ms ease;
}
.landing-cta:hover,
.landing-cta:focus {
  background: var(--ll-brand-hover);
  border-color: var(--ll-brand-hover);
  transform: translateY(-2px);
  box-shadow: 0 14px 34px rgba(139, 69, 19, 0.28);
  color: var(--ll-cream);
}

/* ── Landing — Ornament Divider ─────────────────────────────── */
.ornament-divider {
  margin: var(--ll-space-10) 0;
  text-align: center;
  color: var(--ll-gold-deep);
}
.ornament-divider svg {
  display: inline-block;
  width: 200px;
  height: 16px;
  max-width: 80%;
}

/* ── Landing — Belief / pull quote ───────────────────────────── */
.landing-belief {
  text-align: center;
  padding: var(--ll-space-4) 0;
}
.belief-quote {
  font-family: var(--ll-font-display);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(1.3rem, 3.5vw, 1.85rem);
  line-height: 1.4;
  letter-spacing: -0.01em;
  color: var(--ll-espresso);
  max-width: 38rem;
  margin: 0 auto;
  position: relative;
  padding: 0 var(--ll-space-3);
}
.belief-quote-mark {
  font-family: var(--ll-font-display);
  font-size: 2.4em;
  line-height: 0;
  color: var(--ll-brand);
  vertical-align: -0.5em;
  margin: 0 0.1em;
  font-style: normal;
}
.belief-quote-close { vertical-align: -0.7em; }

/* ── Landing — Features ───────────────────────────────────────── */
.landing-features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: var(--ll-space-6);
  margin: 0;
  padding: var(--ll-space-4) 0;
}
.feature-card {
  margin: 0;
  padding: var(--ll-space-5) var(--ll-space-4);
  text-align: center;
  background: transparent;
  border: none;
}
.feature-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto var(--ll-space-4);
  color: var(--ll-brand);
  background: var(--ll-cream-soft);
  border-radius: 50%;
  padding: 12px;
  border: 1px solid var(--ll-tan);
  display: flex;
  align-items: center;
  justify-content: center;
}
.feature-icon svg { width: 100%; height: 100%; display: block; }
.feature-card h3 {
  font-family: var(--ll-font-display);
  font-size: var(--ll-text-xl);
  font-weight: 500;
  margin: 0 0 var(--ll-space-2);
  color: var(--ll-espresso);
  letter-spacing: -0.015em;
}
.feature-card p {
  font-size: var(--ll-text-base);
  color: var(--ll-taupe);
  line-height: var(--ll-leading-loose);
  margin: 0;
  max-width: 22rem;
  margin-inline: auto;
}

/* ── Landing — "What it remembers" ────────────────────────────── */
.landing-remembers {
  background: var(--ll-cream-soft);
  border-top: 1px solid var(--ll-tan);
  border-bottom: 1px solid var(--ll-tan);
  margin: var(--ll-space-10) calc(-1 * max(1.25rem, env(safe-area-inset-left))) ;
  padding: var(--ll-space-8) var(--ll-space-6);
  text-align: center;
}
.landing-remembers h2 {
  font-family: var(--ll-font-display);
  font-size: clamp(1.7rem, 4.5vw, 2.4rem);
  font-weight: 500;
  letter-spacing: -0.02em;
  margin: 0 0 var(--ll-space-6);
  color: var(--ll-espresso);
}
.remembers-list {
  list-style: none;
  padding: 0;
  margin: 0 auto;
  max-width: 36rem;
  text-align: left;
}
.remembers-list li {
  padding: var(--ll-space-3) 0;
  border-bottom: 1px solid var(--ll-tan);
  font-family: var(--ll-font-body);
  font-size: var(--ll-text-md);
  color: var(--ll-taupe);
  line-height: var(--ll-leading-snug);
}
.remembers-list li:last-child { border-bottom: none; }
.remembers-list li span {
  font-family: var(--ll-font-display);
  font-weight: 600;
  color: var(--ll-espresso);
  display: block;
  font-size: var(--ll-text-lg);
  margin-bottom: 0.15em;
  letter-spacing: -0.015em;
}

/* ── Landing — Pitch ──────────────────────────────────────────── */
.landing-pitch {
  text-align: center;
  padding: var(--ll-space-10) var(--ll-space-4);
  max-width: 38rem;
  margin: 0 auto;
}
.landing-pitch h2 {
  font-family: var(--ll-font-display);
  font-size: clamp(1.9rem, 5vw, 2.8rem);
  font-weight: 500;
  letter-spacing: -0.025em;
  line-height: 1.1;
  margin: 0 0 var(--ll-space-5);
  color: var(--ll-espresso);
}
.pitch-body {
  font-family: var(--ll-font-body);
  font-size: var(--ll-text-md);
  color: var(--ll-taupe);
  line-height: var(--ll-leading-loose);
  margin: 0 0 var(--ll-space-5);
}
.pitch-body em {
  font-family: var(--ll-font-display);
  font-style: italic;
  color: var(--ll-brand);
  font-weight: 500;
}
.pitch-signoff {
  font-family: var(--ll-font-display);
  font-style: italic;
  font-size: var(--ll-text-md);
  color: var(--ll-gold-deep);
  margin: 0;
  letter-spacing: 0.01em;
}

/* ── Legal / static-content pages ─────────────────────────────── */
.prose {
  max-width: 38rem;
  margin: var(--ll-space-4) auto;
}
.prose h1 {
  font-size: var(--ll-text-3xl);
  margin-bottom: var(--ll-space-4);
}
.prose h2 {
  font-size: var(--ll-text-xl);
  margin-top: var(--ll-space-6);
  margin-bottom: var(--ll-space-3);
}
.prose p { line-height: var(--ll-leading-loose); margin-bottom: var(--ll-space-3); }
.prose ul, .prose ol { line-height: var(--ll-leading-loose); padding-left: var(--ll-space-5); }
.prose ul li, .prose ol li { margin-bottom: var(--ll-space-2); }
.prose .meta {
  font-size: var(--ll-text-sm);
  color: var(--ll-taupe-soft);
  margin-bottom: var(--ll-space-5);
}
