@charset "UTF-8";
/* The Cheese Log — warm parchment / cheese-board aesthetic. No build, no deps. */
/* Display serif: Fraunces (OFL, self-hosted latin subset, wght 600–700 variable).
   Falls back to Georgia; the canvas share card intentionally stays Georgia. */
@font-face {
  font-family: "Fraunces";
  src: url("fraunces-latin.woff2?v=1") format("woff2");
  font-weight: 600 700;
  font-display: swap;
}
/* Theming: every surface colour is a token here. Light is the default; dark comes from
   prefers-color-scheme (auto) or an explicit html[data-theme] set by the ⚙ Appearance picker.
   The two dark blocks below MUST stay identical — CSS can't share a block across an @media
   boundary. Gold/foil premium surfaces are deliberately theme-independent (foil reads on both). */
:root {
  /* padlock glyph for the small ::after "gated" badges (CSS content: can't hold inline SVG, so a
     mask lets the badge tint to --gold-deep and stay crisp at any size) */
  --ico-lock: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 10.5V7.5a6 6 0 0 1 12 0v3h.8a1.7 1.7 0 0 1 1.7 1.7v7.6a1.7 1.7 0 0 1-1.7 1.7H5.2a1.7 1.7 0 0 1-1.7-1.7v-7.6a1.7 1.7 0 0 1 1.7-1.7zm2.2 0h7.6V7.5a3.8 3.8 0 0 0-7.6 0z'/%3E%3C/svg%3E");
  --bg: #faf5e9;
  --bg-2: #f3ead6;
  --card: #fffdf7;
  --ink: #3b2f1c;
  --ink-soft: #806f50;
  --line: #e6dcc4;
  --gold: #cf962b;
  --gold-deep: #a6701a;
  --rind: #e0a64c;
  --blue: #6b87a8;
  --danger: #b4472f;
  --danger-line: #e3c4ba;
  --on-gold: #43320f;            /* text set on gold fills (buttons, chips, avatars) */
  --btn-hover-bg: #a6701a;
  --btn-hover-fg: #fff;
  --header-bg: rgba(250, 245, 233, .92);
  --banner-bg: #fff6e3;
  --err-bg: #fbeae5;
  --star-off: #d9c9a0;
  --overlay: rgba(40, 30, 10, .45);
  --overlay-soft: rgba(40, 30, 10, .38);
  --toast-bg: #3b2f1c;
  --toast-fg: #fff7e6;
  --chipblue-bg: #eef2f7; --chipblue-fg: #4a6079; --chipblue-line: #d4ddea;
  --chipgreen-bg: #e9f4e0; --chipgreen-fg: #3b6d11; --chipgreen-line: #cfe6bf;
  --avail-every-bg: #e7f0e0; --avail-every-fg: #3f6b34;
  --avail-spec-bg: #f4e7c9; --avail-spec-fg: #8a6a1f;
  --avail-rare-bg: #e7e3f1; --avail-rare-fg: #5b4a86;
  --foilcard-1: #fffdf7;         /* premium gate / celebration card gradient stops */
  --foilcard-2: #fbf2dc;
  --foilcard-glow: rgba(255, 247, 222, .9);
  --foil-inset: rgba(255, 255, 255, .6);
  --sheen: rgba(255, 255, 255, .7);
  --shadow: 0 2px 10px rgba(80, 60, 20, .10);
  --shadow-lg: 0 10px 34px rgba(80, 60, 20, .18);
  --r: 14px;
  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  color-scheme: light;
}
/* ---- dark palette (auto via OS preference; html[data-theme="light"] opts back out) ---- */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #221c13;
    --bg-2: #1a150d;
    --card: #2b241a;
    --ink: #f0e7d5;
    --ink-soft: #b1a382;
    --line: #443a26;
    --gold: #d9a83c;
    --gold-deep: #e0b55e;
    --rind: #c9973f;
    --blue: #8aa3c0;
    --danger: #e08a76;
    --danger-line: #6b4033;
    --on-gold: #43320f;
    --btn-hover-bg: #e0b55e;
    --btn-hover-fg: #43320f;
    --header-bg: rgba(26, 21, 13, .92);
    --banner-bg: #2e2615;
    --err-bg: #3d2a23;
    --star-off: #55492f;
    --overlay: rgba(10, 7, 3, .6);
    --overlay-soft: rgba(10, 7, 3, .5);
    --toast-bg: #f0e7d5;
    --toast-fg: #3b2f1c;
    --chipblue-bg: #28313c; --chipblue-fg: #a9bdd2; --chipblue-line: #3b4a5c;
    --chipgreen-bg: #26331d; --chipgreen-fg: #a9cc8a; --chipgreen-line: #3c5230;
    --avail-every-bg: #26331d; --avail-every-fg: #a9cc8a;
    --avail-spec-bg: #38301a; --avail-spec-fg: #d9b96a;
    --avail-rare-bg: #2e2a3d; --avail-rare-fg: #b3a6d9;
    --foilcard-1: #332a1a;
    --foilcard-2: #2b2214;
    --foilcard-glow: rgba(217, 168, 60, .18);
    --foil-inset: rgba(255, 255, 255, .08);
    --sheen: rgba(255, 235, 190, .14);
    --shadow: 0 2px 10px rgba(0, 0, 0, .35);
    --shadow-lg: 0 10px 34px rgba(0, 0, 0, .5);
    color-scheme: dark;
  }
}
/* ---- explicit picker override (⚙ Appearance) — keep identical to the block above ---- */
:root[data-theme="dark"] {
  --bg: #221c13;
  --bg-2: #1a150d;
  --card: #2b241a;
  --ink: #f0e7d5;
  --ink-soft: #b1a382;
  --line: #443a26;
  --gold: #d9a83c;
  --gold-deep: #e0b55e;
  --rind: #c9973f;
  --blue: #8aa3c0;
  --danger: #e08a76;
  --danger-line: #6b4033;
  --on-gold: #43320f;
  --btn-hover-bg: #e0b55e;
  --btn-hover-fg: #43320f;
  --header-bg: rgba(26, 21, 13, .92);
  --banner-bg: #2e2615;
  --err-bg: #3d2a23;
  --star-off: #55492f;
  --overlay: rgba(10, 7, 3, .6);
  --overlay-soft: rgba(10, 7, 3, .5);
  --toast-bg: #f0e7d5;
  --toast-fg: #3b2f1c;
  --chipblue-bg: #28313c; --chipblue-fg: #a9bdd2; --chipblue-line: #3b4a5c;
  --chipgreen-bg: #26331d; --chipgreen-fg: #a9cc8a; --chipgreen-line: #3c5230;
  --avail-every-bg: #26331d; --avail-every-fg: #a9cc8a;
  --avail-spec-bg: #38301a; --avail-spec-fg: #d9b96a;
  --avail-rare-bg: #2e2a3d; --avail-rare-fg: #b3a6d9;
  --foilcard-1: #332a1a;
  --foilcard-2: #2b2214;
  --foilcard-glow: rgba(217, 168, 60, .18);
  --foil-inset: rgba(255, 255, 255, .08);
  --sheen: rgba(255, 235, 190, .14);
  --shadow: 0 2px 10px rgba(0, 0, 0, .35);
  --shadow-lg: 0 10px 34px rgba(0, 0, 0, .5);
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: linear-gradient(180deg, var(--bg), var(--bg-2));
  color: var(--ink);
  font: 16px/1.5 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3 { font-family: var(--serif); font-weight: 700; }
a { color: var(--gold-deep); }
.wrap { max-width: 1000px; margin: 0 auto; padding: 0 16px 80px; }

/* header */
header.app {
  position: sticky; top: 0; z-index: 30;
  background: var(--header-bg);
  backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid var(--line);
}
.bar { max-width: 1000px; margin: 0 auto; display: flex; align-items: center; gap: 12px; padding: 12px 16px; }
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--serif); font-weight: 700; font-size: 21px; }
.brand .logo { width: 54px; height: 54px; display: block; flex-shrink: 0; filter: drop-shadow(0 2px 5px rgba(80, 60, 20, .32)); }

/* compact account avatar (replaces the wide @handle chip) */
.avatarbtn { width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line); background: var(--bg-2); color: var(--ink); font: 700 15px var(--serif); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; padding: 0; flex-shrink: 0; position: relative; }
.avatarbtn:hover { border-color: var(--gold); }
.avatarbtn.premium { background: linear-gradient(140deg, #f3c759, #cf962b); color: var(--on-gold); border-color: var(--gold-deep); }
.avatarbtn.premium::after { content: "✦"; position: absolute; top: -3px; right: -3px; width: 14px; height: 14px; font-size: 9px; display: flex; align-items: center; justify-content: center; color: var(--gold-deep); background: var(--bg); border-radius: 50%; box-shadow: 0 0 0 1px var(--gold); }

/* Ask = AI chat bubble */
.askbtn { display: inline-flex; align-items: center; justify-content: center; }
.askbtn svg { display: block; }

/* floating Cheesemonger launcher — the flagship AI, labelled + always in reach (bottom-right).
   Gold = it's the premium feature; a 🔒 rides on it for free users. Sits above the bottom nav
   (z 90) but below modals/slide-overs so the chat panel covers it when open. */
.askfab {
  position: fixed; right: 20px; bottom: 22px; z-index: 95;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 20px 12px 15px; border: none; border-radius: 999px; cursor: pointer;
  background: linear-gradient(135deg, #f3c759, #cf962b); color: #43320f;
  font: inherit; font-weight: 700; font-size: 15px;
  box-shadow: 0 6px 22px rgba(120, 80, 20, .4);
  transition: transform .12s, box-shadow .12s, filter .12s;
}
.askfab:hover { transform: translateY(-2px); box-shadow: 0 9px 28px rgba(120, 80, 20, .5); filter: brightness(1.04); }
.askfab:focus-visible { outline: 3px solid var(--rind); outline-offset: 2px; }
.askfab svg { display: block; flex-shrink: 0; }
.askfab .asklabel { white-space: nowrap; }
.askfab.gated::after {
  content: ""; position: absolute; top: -4px; right: -3px; width: 15px; height: 15px;
  background: var(--gold-deep); filter: drop-shadow(0 1px 1px rgba(0, 0, 0, .35));
  -webkit-mask: var(--ico-lock) center/contain no-repeat; mask: var(--ico-lock) center/contain no-repeat;
}

/* hero logo on empty-shelf + sign-in */
.herologo { display: block; margin: 0 auto; filter: drop-shadow(0 3px 9px rgba(80, 60, 20, .30)); }
.empty .herologo { width: 116px; height: 116px; margin-bottom: 8px; }
.authhero { text-align: center; margin: -4px 0 10px; }
.authhero .herologo { width: 86px; height: 86px; margin-bottom: 8px; }
.authhero .authbrand { font-family: var(--serif); font-weight: 700; font-size: 23px; color: var(--ink); }
.authhero .authtag { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-soft); margin-top: 2px; }
.brand small { display: block; font: 400 11px/1 sans-serif; color: var(--ink-soft); letter-spacing: .12em; text-transform: uppercase; margin-top: 3px; }
.bar .spacer { flex: 1; }
.iconbtn { background: none; border: 1px solid var(--line); color: var(--ink); border-radius: 10px; padding: 7px 10px; cursor: pointer; font-size: 15px; }
.iconbtn:hover { background: var(--bg-2); }
/* Inline SVG icon set (see ic() in app.js). Sizes to the surrounding text so icon+label buttons
   align without per-call tweaking; a bit larger and centered in bare icon buttons. */
.mico { width: 1.08em; height: 1.08em; vertical-align: -0.16em; flex: none; }
.iconbtn .mico, .fab .mico { width: 1.3em; height: 1.3em; vertical-align: -0.28em; }
.iconbtn.xs .mico { width: 1.15em; height: 1.15em; vertical-align: -0.2em; }
.bico .mico { width: 1em; height: 1em; vertical-align: -0.12em; }
.cloud { font: inherit; font-size: 12px; color: var(--ink-soft); background: var(--card); border: 1px solid var(--line); border-radius: 999px; padding: 5px 11px; cursor: pointer; }
.cloud:hover { background: var(--bg-2); }
.cloud::before { content: "● "; color: #b9a06a; }
.cloud.online { color: var(--gold-deep); border-color: var(--gold); }
.cloud.online::before { color: #6f9a5a; }

/* cheesemonger chat */
.askmsg { display: flex; margin: 10px 0; }
.askmsg.you { justify-content: flex-end; }
.askmsg .bubble { max-width: 85%; padding: 10px 14px; border-radius: 14px; font-size: 14.5px; line-height: 1.5; box-shadow: var(--shadow); }
.askmsg.you .bubble { background: var(--gold); color: var(--on-gold); border-bottom-right-radius: 4px; }
.askmsg.mongr .bubble { background: var(--card); border: 1px solid var(--line); border-bottom-left-radius: 4px; }
.askmsg .bubble.err { background: var(--err-bg); border-color: var(--danger-line); color: var(--danger); }
.askmsg .bubble p { margin: 0 0 8px; } .askmsg .bubble p:last-child { margin: 0; }
.askmsg .bubble ul { margin: 4px 0; padding-left: 20px; } .askmsg .bubble li { margin: 2px 0; }

/* signed-out sign-up banner */
.banner { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; background: var(--banner-bg); border: 1px solid var(--gold); border-radius: var(--r); padding: 12px 16px; margin: 20px 0; box-shadow: var(--shadow); }
.banner span { flex: 1; min-width: 200px; font-size: 14px; }
/* persistent "Go Pro" bar under the header — gold/foil so it reads as an upgrade */
.protop { display: flex; align-items: center; justify-content: center; gap: 6px; width: 100%; border: none; border-bottom: 1px solid var(--gold); background: linear-gradient(100deg, #f3c759, #e0a64c); color: #43320f; font: inherit; font-size: 13.5px; padding: 9px 16px; cursor: pointer; text-align: center; }
.protop:hover { background: linear-gradient(100deg, #f6d06a, #e6ad52); }
.protop b { font-weight: 700; }
.protop .protop-arrow { font-weight: 700; font-size: 16px; margin-left: 2px; }
@media (max-width: 520px) { .protop { font-size: 12.5px; padding: 8px 12px; } }

/* private toggle */
.privrow { display: flex; align-items: center; gap: 8px; font-size: 14px; margin: 4px 0 16px; cursor: pointer; }
.privrow input { width: auto; }

/* feed */
.feeditem { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 14px 16px; margin-bottom: 12px; box-shadow: var(--shadow); }
.feeditem .who { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.feeditem .av { width: 30px; height: 30px; border-radius: 50%; background: var(--gold); color: var(--on-gold); display: flex; align-items: center; justify-content: center; font-weight: 700; font-family: var(--serif); }
.feeditem .who b { font-size: 14px; }
.feeditem .who .h { color: var(--ink-soft); font-size: 12px; }
.feeditem h3 { margin: 2px 0; font-size: 18px; }
.feeditem .when { margin-left: auto; font-size: 11px; color: var(--ink-soft); }
.feeditem img.fp { width: 100%; max-height: 240px; object-fit: cover; border-radius: 10px; margin-top: 8px; }

/* friends modal bits */
.frrow { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--bg-2); }
.frrow .av { width: 34px; height: 34px; border-radius: 50%; background: var(--gold); color: var(--on-gold); display: flex; align-items: center; justify-content: center; font-weight: 700; font-family: var(--serif); }
.frrow .nm { flex: 1; }
.frrow .nm small { color: var(--ink-soft); display: block; }
.handlebox { display: flex; gap: 8px; align-items: center; background: var(--bg); border: 1px dashed var(--rind); border-radius: 10px; padding: 8px 12px; margin: 10px 0; font-size: 14px; }
.handlebox b { font-family: var(--serif); }
.sectlabel { font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-soft); margin: 16px 0 6px; }

/* tabs — top bar on desktop; a fixed bottom bar + centre FAB on phones (see the 640px block) */
nav.tabs { display: flex; gap: 4px; max-width: 1000px; margin: 0 auto; padding: 0 16px; }
nav.tabs button {
  flex: 1; max-width: 200px; background: none; border: none; cursor: pointer;
  padding: 12px 8px; color: var(--ink-soft); font-weight: 600; font-size: 15px;
  border-bottom: 3px solid transparent;
}
nav.tabs button.active { color: var(--gold-deep); border-bottom-color: var(--gold); }
nav.tabs .ticon { width: 17px; height: 17px; vertical-align: -3px; margin-right: 5px; }
nav.tabs .fab { display: none; }   /* the raised ＋ exists only in the mobile bottom bar */

/* stats strip */
.stats { display: flex; gap: 10px; flex-wrap: wrap; margin: 20px 0; }
.stat { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 12px 16px; flex: 1; min-width: 120px; box-shadow: var(--shadow); cursor: pointer; transition: border-color .12s, transform .12s; }
.stat:hover { border-color: var(--gold); transform: translateY(-1px); }
.stat:focus-visible { outline: 2px solid var(--rind); }
.statlist { margin-top: 4px; }
.statrow { display: flex; align-items: center; gap: 10px; padding: 10px 2px; border-bottom: 1px solid var(--bg-2); cursor: pointer; }
.statrow:last-child { border-bottom: 0; }
.statrow:hover { background: var(--bg-2); }
.statmain { flex: 1; min-width: 0; }
.statmain small { display: block; color: var(--ink-soft); }
.stat .n { font-family: var(--serif); font-size: 26px; font-weight: 700; color: var(--gold-deep); }
.stat .l { font-size: 12px; color: var(--ink-soft); text-transform: uppercase; letter-spacing: .08em; }

/* controls row */
.toolbar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 16px; }
input, textarea, select {
  font: inherit; color: var(--ink); background: var(--card);
  border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; width: 100%;
}
input:focus, textarea:focus, select:focus { outline: 2px solid var(--rind); border-color: var(--rind); }
.toolbar input.search { flex: 1; min-width: 180px; }
.toolbar select { width: auto; }

/* buttons */
.btn { background: var(--gold); color: var(--on-gold); border: none; border-radius: 10px; padding: 11px 18px; font-weight: 700; cursor: pointer; box-shadow: var(--shadow); white-space: nowrap; }
.btn:hover { background: var(--btn-hover-bg); color: var(--btn-hover-fg); }
.btn.ghost { background: var(--card); color: var(--ink); border: 1px solid var(--line); box-shadow: none; }
.btn.ghost:hover { background: var(--bg-2); color: var(--ink); }
.btn.block { width: 100%; padding: 14px; font-size: 16px; }
.btn.sm { padding: 7px 12px; font-size: 14px; }
.btn.danger { background: none; color: var(--danger); border: 1px solid var(--danger-line); }

/* shelf grid */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
.cardx { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; box-shadow: var(--shadow); cursor: pointer; transition: transform .12s, box-shadow .12s; display: flex; flex-direction: column; }
.cardx:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.cardx .thumb { height: 130px; display: flex; align-items: center; justify-content: center; background: var(--bg-2); }
.cardx .thumb img { width: 100%; height: 100%; object-fit: cover; }
.cardx .body { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 6px; }
.cardx h3 { margin: 0; font-size: 17px; line-height: 1.2; }
.cardx .meta { font-size: 12px; color: var(--ink-soft); }
.cardx .note { font-size: 13px; color: var(--ink); opacity: .85; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cardx .date { font-size: 11px; color: var(--ink-soft); margin-top: auto; }

/* rating = cheese wedges (SVG sized at 1em so font-size still controls scale) */
.wedges { display: inline-flex; align-items: center; gap: 3px; font-size: 18px; color: var(--star-off); user-select: none; line-height: 1; }
.wedges span { display: inline-flex; }
.wedges svg { width: 1em; height: 1em; display: block; fill: currentColor; }
.wedges .on { color: var(--gold); }
.wedges.big { font-size: 30px; gap: 5px; }
.wedges.input span { cursor: pointer; }
.wedges.input span svg { pointer-events: none; }
.wsm { width: .9em; height: .9em; display: inline-block; vertical-align: -.12em; fill: currentColor; }
.unrated { font-size: 12px; font-style: italic; }

/* chips / tags */
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { font-size: 12.5px; padding: 4px 10px; border-radius: 999px; border: 1px solid var(--line); background: var(--bg); color: var(--ink-soft); cursor: pointer; }
.chip.on { background: var(--gold); color: var(--on-gold); border-color: var(--gold); font-weight: 600; }
.chip.suggest { border-style: dashed; }
.chip .x { margin-left: 6px; opacity: .6; }
.tagline { font-size: 12px; color: var(--ink-soft); margin: 10px 0 4px; }

/* form card */
.panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 18px; box-shadow: var(--shadow); }
.field { margin-bottom: 16px; }
.field > label { display: block; font-weight: 600; font-size: 13px; margin-bottom: 6px; color: var(--ink); }
.row2 { display: flex; gap: 12px; flex-wrap: wrap; }
.row2 > .field { flex: 1; min-width: 150px; }
.row3 { display: flex; gap: 8px; flex-wrap: wrap; }
.row3 > * { flex: 1; min-width: 96px; }
.row3 :disabled { opacity: .65; cursor: not-allowed; }

/* autocomplete */
.ac { position: relative; }
.ac-list { position: absolute; z-index: 50; left: 0; right: 0; top: calc(100% + 4px); background: var(--card); border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow-lg); max-height: 280px; overflow: auto; }
.ac-list .opt { padding: 9px 12px; cursor: pointer; border-bottom: 1px solid var(--bg-2); }
.ac-list .opt:last-child { border-bottom: none; }
.ac-list .opt:hover, .ac-list .opt.hl { background: var(--bg-2); }
.ac-list .opt b { font-weight: 700; }
.ac-list .opt small { color: var(--ink-soft); }

/* selected cheese info */
.cheeseinfo { background: var(--bg); border: 1px dashed var(--rind); border-radius: 12px; padding: 12px 14px; margin-top: 8px; font-size: 13px; }
.cheeseinfo .nm { font-family: var(--serif); font-weight: 700; font-size: 16px; }
.cheeseinfo .tt { color: var(--ink-soft); }

/* photo */
.photoprev { width: 100%; max-height: 220px; object-fit: cover; border-radius: 12px; margin-top: 8px; border: 1px solid var(--line); }

/* modal */
.modal-bg { position: fixed; inset: 0; background: var(--overlay); display: flex; align-items: flex-start; justify-content: center; padding: 24px 16px; z-index: 100; overflow: auto; }
.modal { background: var(--card); border-radius: 18px; max-width: 560px; width: 100%; box-shadow: var(--shadow-lg); padding: 20px; }
.modal .close { float: right; }

/* browse rows */
.brow { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; margin-bottom: 10px; box-shadow: var(--shadow); display: flex; gap: 12px; align-items: center; }
.browmain { flex: 1; min-width: 0; display: flex; gap: 12px; align-items: center; }
.browthumb { flex: 0 0 58px; width: 58px; height: 58px; border-radius: 10px; overflow: hidden; background: var(--bg-2); }
.browthumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.brow .gist { flex: 1; min-width: 0; }
.browactions { display: flex; flex-direction: column; gap: 6px; flex-shrink: 0; }
.brow h3 { margin: 0 0 3px; font-size: 16px; }
.brow .meta { font-size: 12px; color: var(--ink-soft); }
.brow .tt { font-size: 12.5px; color: var(--ink); opacity: .8; margin-top: 4px; }

/* misc */
.empty { text-align: center; color: var(--ink-soft); padding: 60px 20px; }
.emptycta { display: inline-flex; flex-direction: column; gap: 8px; align-items: stretch; }
.empty .big { font-size: 46px; }
/* SVG icons stand in for the old oversized emoji in empty-states, loaders, pro gates and teasers */
.empty .big .mico, .scanloading .big .mico { width: 50px; height: 50px; opacity: .82; vertical-align: middle; margin: 0 3px; }
.crown .mico { width: 44px; height: 44px; vertical-align: middle; margin: 0 2px; }
.teaserbox .tico .mico { width: 20px; height: 20px; vertical-align: -3px; }
.prem-perks .pk .mico { width: 22px; height: 22px; vertical-align: -4px; }
.thumb .wedge .mico { width: 46px; height: 46px; opacity: .5; }
.hide { display: none !important; }
.muted { color: var(--ink-soft); font-size: 12.5px; }
.center { text-align: center; }
.wedge { font-size: 52px; }

/* "user-added" badge on community (member-contributed) cheeses */
.commbadge { display: inline-block; font-size: 11px; font-weight: 600; vertical-align: 1px;
  padding: 1px 7px; border-radius: 999px; background: var(--chipblue-bg); color: var(--chipblue-fg);
  border: 1px solid var(--chipblue-line); letter-spacing: .02em; white-space: nowrap; }

/* Scan a menu (premium) */
.scanbtn { display: flex; align-items: center; justify-content: center; gap: 8px; }
.scanhint { margin: 7px 2px 18px; }
.scanloading { text-align: center; padding: 34px 12px; }
.scanloading .big { font-size: 48px; }
.scanloading h2 { margin: 12px 0 4px; }
.scanrow { display: flex; align-items: flex-start; gap: 11px; padding: 12px 2px; border-bottom: 1px solid var(--bg-2); }
.scanrow.sel { }
.scanpick { width: 18px; height: 18px; flex: 0 0 auto; margin-top: 3px; accent-color: var(--gold); }
.scanmain { flex: 1; min-width: 0; }
.scanname { font-size: 15px; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.scannameinput { font: inherit; font-weight: 600; color: var(--ink); background: var(--card); border: 1px solid var(--line); border-radius: 6px; padding: 4px 8px; width: 100%; max-width: 210px; }
.scannameinput:focus { outline: 2px solid var(--rind); border-color: var(--rind); }
.scanmeta { font-size: 12px; color: var(--ink-soft); margin-top: 2px; }
.scanchip { font-size: 10.5px; padding: 1px 8px; border-radius: 999px; vertical-align: 1px; white-space: nowrap; }
.scanchip.matched { background: var(--chipgreen-bg); color: var(--chipgreen-fg); border: 1px solid var(--chipgreen-line); }
.scanchip.new { background: var(--chipblue-bg); color: var(--chipblue-fg); border: 1px solid var(--chipblue-line); }
.scandetails { display: flex; gap: 6px; margin-top: 8px; flex-wrap: wrap; }
.scandetails select, .scandetails input { font-size: 12px; padding: 6px 8px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg); color: var(--ink); width: auto; flex: 1; min-width: 84px; }
.scanstars { font-size: 16px; flex: 0 0 auto; margin-top: 1px; }
/* Availability badge (🛒 everyday / 🧀 specialty / 💎 rare) — classed so it themes */
.availb { display: inline-block; font-size: 11px; font-weight: 600; padding: 1px 7px; border-radius: 999px; white-space: nowrap; vertical-align: middle; }
.availb.everyday { background: var(--avail-every-bg); color: var(--avail-every-fg); }
.availb.specialty { background: var(--avail-spec-bg); color: var(--avail-spec-fg); }
.availb.rare { background: var(--avail-rare-bg); color: var(--avail-rare-fg); }

/* Community rating badge (wedge + avg + count) */
.comrating { font-size: 12.5px; color: var(--gold-deep); white-space: nowrap; }
.comrating small { color: var(--ink-soft); }

/* Wishlist (below the shelf) */
.wishlist { display: flex; flex-direction: column; gap: 0; margin-top: 6px; }
.wishrow { display: flex; align-items: center; gap: 10px; padding: 10px 2px; border-bottom: 1px solid var(--bg-2); }
.wishrow:last-child { border-bottom: 0; }
.wishmain { flex: 1; min-width: 0; }
.iconbtn.sm { padding: 5px 9px; font-size: 14px; }

/* Reverse pairing panel (Ask tab) */
.pairpanel { background: var(--bg); border: 1px dashed var(--rind); border-radius: 12px; padding: 12px 14px; margin-bottom: 16px; }
.pairrow { display: flex; align-items: center; gap: 11px; padding: 10px 2px; border-bottom: 1px solid var(--bg-2); }
.pairrow:last-child { border-bottom: 0; }
.pairmain { flex: 1; min-width: 0; }

.scannote { font-size: 12.5px; color: var(--ink-soft); font-style: italic; margin-top: 4px; line-height: 1.4; }
.scantags { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 7px; }
.scantag { font-size: 11px; padding: 2px 8px; border-radius: 999px; border: 1px solid var(--line); background: var(--bg); color: var(--ink-soft); cursor: pointer; }
.scantag.on { background: var(--gold); color: var(--on-gold); border-color: var(--gold); font-weight: 600; }

/* Ask-tab chat header (question count + New chat) */
.askhead { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; padding-bottom: 10px; border-bottom: 1px solid var(--line); }

/* ============================ PREMIUM ============================ */
/* Brand becomes PROmagerie when premium */
#brandName .pro {
  background: linear-gradient(135deg, var(--gold), var(--gold-deep));
  -webkit-background-clip: text; background-clip: text; color: transparent;
  font-weight: 800;
}

/* Account chip turns to gold foil when premium */
.cloud.premium {
  color: #5a3d05; font-weight: 700;
  background: linear-gradient(135deg, #fbe9b8, #f3c759 55%, #e0a64c);
  border-color: var(--gold-deep);
  box-shadow: 0 1px 6px rgba(166, 112, 26, .35);
}
.cloud.premium::before { content: "✦ "; color: #a6701a; }

/* Lock / sparkle indicator on the Ask tab + pair buttons */
nav.tabs button .tabmark { font-size: 11px; margin-left: 1px; vertical-align: 1px; opacity: .85; }
.btn.locked { position: relative; opacity: .92; }
.btn.locked::after {
  content: "✦"; position: absolute; top: -6px; right: -6px;
  font-size: 11px; background: var(--gold-deep); color: #fff;
  width: 16px; height: 16px; line-height: 16px; text-align: center; border-radius: 50%;
  box-shadow: var(--shadow);
}

/* Rich premium gate (the upsell card on the Ask tab) */
.premgate { max-width: 520px; margin: 24px auto; text-align: center; }
.premgate .foil {
  position: relative; overflow: hidden;
  border-radius: 20px; padding: 30px 26px 28px;
  background:
    radial-gradient(120% 80% at 50% -10%, var(--foilcard-glow), transparent 60%),
    linear-gradient(160deg, var(--foilcard-1), var(--foilcard-2));
  border: 1.5px solid var(--gold);
  box-shadow: var(--shadow-lg), inset 0 0 0 1px var(--foil-inset);
}
.premgate .foil::before {
  content: ""; position: absolute; top: 0; left: -60%; width: 50%; height: 100%;
  background: linear-gradient(100deg, transparent, var(--sheen), transparent);
  transform: skewX(-18deg); animation: foilsheen 4.5s ease-in-out infinite;
}
@keyframes foilsheen { 0%, 60% { left: -60%; } 100% { left: 130%; } }
.premgate .crown { font-size: 50px; line-height: 1; filter: drop-shadow(0 3px 6px rgba(166, 112, 26, .3)); }
.premgate h2 { margin: 10px 0 4px; font-family: var(--serif); font-size: 22px; }
.premgate .lead { color: var(--ink-soft); font-size: 14px; margin: 0 auto 16px; max-width: 390px; }
.protitle { font-size: 22px; margin: 6px 0 4px; }
.prosub { text-align: center; color: var(--ink-soft); font-size: 13.5px; line-height: 1.45; max-width: 390px; margin: 0 auto 14px; }
.prem-badge {
  display: inline-block; font-size: 11px; font-weight: 800; letter-spacing: .14em;
  text-transform: uppercase; color: #5a3d05; padding: 4px 12px; border-radius: 999px;
  background: linear-gradient(135deg, #fbe9b8, #f3c759 55%, #e0a64c);
  box-shadow: 0 1px 5px rgba(166, 112, 26, .3);
}
.prem-perks { list-style: none; text-align: left; margin: 6px auto 18px; max-width: 390px; display: grid; gap: 12px; padding: 0; }
.prem-perks li { display: flex; gap: 12px; align-items: flex-start; }
.prem-perks .pk {
  flex: 0 0 36px; width: 36px; height: 36px; border-radius: 11px; font-size: 17px; line-height: 1;
  display: inline-flex; align-items: center; justify-content: center;
  background: linear-gradient(140deg, rgba(243, 199, 89, .30), rgba(207, 150, 43, .14));
  box-shadow: inset 0 0 0 1px rgba(207, 150, 43, .28);
}
.prem-perks .pkt { min-width: 0; padding-top: 1px; }
.prem-perks .pkt b { display: block; font-size: 14px; line-height: 1.3; color: var(--ink); }
.prem-perks .pkt small { display: block; font-size: 12.5px; line-height: 1.4; color: var(--ink-soft); margin-top: 2px; }
.prem-teaser { margin: 14px auto 0; max-width: 360px; }
.prem-teaser .sectlabel { text-align: center; }
.prem-teaser .chip { width: 100%; box-sizing: border-box; text-align: left; cursor: default; opacity: .6; position: relative; padding-right: 28px; }
.prem-teaser .chip::after { content: ""; position: absolute; right: 8px; top: 50%; transform: translateY(-50%); width: 13px; height: 13px; background: var(--gold-deep); opacity: .8; -webkit-mask: var(--ico-lock) center/contain no-repeat; mask: var(--ico-lock) center/contain no-repeat; }

/* gate teasers — a sample of the product inside the paywall card */
.teaser { margin: 2px auto 18px; max-width: 390px; text-align: left; }
.teaser .sectlabel { text-align: center; }
.teaserbox { position: relative; background: var(--bg); border: 1px dashed var(--rind); border-radius: 12px; padding: 12px 14px; }
.teaserbox .trow { display: flex; gap: 10px; align-items: flex-start; padding: 7px 0; }
.teaserbox .trow + .trow { border-top: 1px solid var(--line); }
.teaserbox .tico { font-size: 17px; }
.teaserbox .ttxt b { display: block; font-size: 13.5px; line-height: 1.3; }
.teaserbox .ttxt small { display: block; color: var(--ink-soft); font-size: 12.5px; line-height: 1.4; margin-top: 1px; }
.teaserbox .askmsg { margin: 6px 0; }
.teaserbox .askmsg .bubble { font-size: 13px; box-shadow: none; }
.teaserbox .shareimg { margin: 2px 0 0; box-shadow: var(--shadow); }
.tsample { position: absolute; top: -9px; right: 10px; font-size: 10px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; background: var(--card); color: var(--ink-soft); border: 1px solid var(--line); border-radius: 999px; padding: 1px 8px; }
.empty .teaser { margin-top: 22px; }

/* Premium status card in Settings */
.prem-status {
  display: flex; gap: 12px; align-items: center; margin-top: 10px;
  padding: 12px 14px; border-radius: 14px;
  background: linear-gradient(160deg, var(--foilcard-1), var(--foilcard-2)); border: 1px solid var(--gold);
  box-shadow: var(--shadow);
}
.prem-status .ico { font-size: 26px; }
.prem-status b { display: block; }
.prem-status small { color: var(--ink-soft); }

/* ===== Unlock celebration ===== */
.celebrate { position: fixed; inset: 0; z-index: 200; display: flex; align-items: center; justify-content: center;
  background: var(--overlay); padding: 24px; overflow: hidden; }
.celebrate .card {
  position: relative; z-index: 2; max-width: 420px; width: 100%; text-align: center;
  background: radial-gradient(120% 80% at 50% -10%, var(--foilcard-2), var(--foilcard-1) 60%);
  border: 1.5px solid var(--gold); border-radius: 22px; padding: 34px 28px 28px;
  box-shadow: var(--shadow-lg); animation: popin .5s cubic-bezier(.2, 1.3, .4, 1) both;
}
@keyframes popin { 0% { transform: scale(.7); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }
.celebrate .crown { font-size: 64px; line-height: 1; animation: crownpop 2.4s ease-in-out infinite; }
@keyframes crownpop { 0%, 100% { transform: translateY(0) rotate(-3deg); } 50% { transform: translateY(-6px) rotate(3deg); } }
.celebrate h2 { font-family: var(--serif); margin: 12px 0 6px; }
.celebrate p { color: var(--ink-soft); font-size: 14px; margin: 0 0 18px; }
.confetti { position: absolute; inset: 0; z-index: 1; pointer-events: none; overflow: hidden; }
.confetti i {
  position: absolute; top: -12px; width: 9px; height: 14px; border-radius: 2px;
  animation: fall linear forwards;
}
@keyframes fall {
  0% { transform: translateY(-20px) rotate(0); opacity: 1; }
  100% { transform: translateY(105vh) rotate(720deg); opacity: .9; }
}

@media (max-width: 520px) {
  .brand small { display: none; }
  .brand { font-size: 16px; gap: 6px; }
  .brand .logo { width: 44px; height: 44px; }
  .brand { font-size: 17px; }     /* wordmark stays visible alongside the big medallion */
  .bar { gap: 5px; padding: 10px 12px; }
  .bar .iconbtn { padding: 6px 8px; font-size: 15px; border-radius: 9px; }
  .cloud { font-size: 12px; padding: 5px 10px; }            /* full @handle, no truncation */
  body.authed #menuBtn { display: none; }                   /* gear is redundant on mobile — the chip opens Settings */
  .slideover { width: 100%; }
  .wrap { padding: 0 12px 80px; }

  /* Browse rows: stack the cheese info, then a full-width row of actions */
  .brow { flex-direction: column; align-items: stretch; gap: 10px; }
  .browactions { flex-direction: row; flex-wrap: wrap; }
  .browactions .btn { flex: 1; }
}

/* ---- My Board ---------------------------------------------------------- */
.btn.xs { padding: 4px 9px; font-size: 12px; }
.iconbtn.xs { padding: 3px 7px; font-size: 13px; border-radius: 8px; }
.cellartag { font-size: 10px; text-transform: uppercase; letter-spacing: .05em; color: var(--gold-deep); border: 1px solid var(--gold); border-radius: 6px; padding: 1px 5px; vertical-align: middle; }
.boardslot { position: relative; background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 12px 14px 10px 34px; margin-bottom: 10px; box-shadow: var(--shadow); }
.bslotnum { position: absolute; left: 10px; top: 12px; width: 18px; height: 18px; border-radius: 50%; background: var(--bg-2); color: var(--ink-soft); font-size: 11px; font-weight: 700; display: flex; align-items: center; justify-content: center; }
.bpair { display: flex; flex-direction: column; gap: 8px; }
.bcell { display: flex; align-items: center; gap: 8px; }
.bcell .bico { font-size: 18px; flex-shrink: 0; }
.bcell .binfo { flex: 1; min-width: 0; }
.bcell .binfo b { display: block; overflow: hidden; text-overflow: ellipsis; }
.bcell .binfo small { display: block; color: var(--ink-soft); font-size: 12px; }
.bplace { align-self: flex-start; border-style: dashed; color: var(--ink-soft); }
.bpairempty { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.bpairempty .ghost { color: var(--ink-soft); }
.bcell.pairing { opacity: .75; }
.bcell.pairing .bico { animation: bpulse 1s ease-in-out infinite; }
@keyframes bpulse { 0%,100% { opacity: .4; } 50% { opacity: 1; } }
.bslotfoot { display: flex; gap: 8px; justify-content: flex-end; margin-top: 8px; padding-top: 6px; border-top: 1px dashed var(--line); }
.accomp { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; margin-bottom: 6px; }
.accomp small { display: block; color: var(--ink-soft); font-size: 12.5px; margin-top: 2px; }
.savedboard { display: flex; align-items: center; gap: 10px; background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; margin-bottom: 6px; }
.savedboard .sbinfo { flex: 1; min-width: 0; }
.savedboard .sbinfo small { display: block; color: var(--ink-soft); font-size: 12px; }
.savedboard .sbactions { display: flex; gap: 6px; flex-shrink: 0; }

/* somm clarify-question modal (Board): tappable style options */
.clarifyopts { display: flex; flex-wrap: wrap; gap: 8px; }

/* crawlable site footer (also the human "what is this" one-liner) */
.sitefoot { max-width: 1000px; margin: 0 auto; padding: 8px 16px 28px; }
.sitefoot p { color: var(--ink-soft); font-size: 12.5px; line-height: 1.5; border-top: 1px solid var(--line); padding-top: 14px; margin: 0; }

/* profiles: tappable names + the profile modal header */
.proflink { cursor: pointer; }
.proflink:hover b, .proflink:hover { text-decoration: underline; text-decoration-color: var(--gold); }
.profhead { display: flex; align-items: center; gap: 12px; margin: 2px 0 10px; }
.profhead .av { width: 54px; height: 54px; border-radius: 50%; background: var(--gold); color: #43320f;
  display: flex; align-items: center; justify-content: center; font-weight: 700; font-family: var(--serif); font-size: 22px; flex-shrink: 0; }
.profhead .h { color: var(--ink-soft); }

/* 📸 share-the-board: generated-card preview modal */
.shareimg { display: block; width: 100%; border-radius: 12px; box-shadow: var(--shadow-lg); margin-top: 6px; }
.sharerow { display: flex; gap: 8px; margin-top: 12px; }
.sharerow .btn, .sharerow a.btn { flex: 1; text-align: center; text-decoration: none; }

/* ---- cellar card on the Pair tab -------------------------------------- */
.cellarcard { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 14px 16px; margin: 0 0 16px; box-shadow: var(--shadow); }
.cellarcard .cellarhead { font-size: 15px; }
.cellarcard .cellarhead .linkbtn,
.linkbtn { background: none; border: 0; padding: 0; font: inherit; color: var(--gold-deep, #8a6a1f); font-weight: 600; cursor: pointer; text-decoration: underline; text-underline-offset: 2px; }
.cellarcard .cellarhead .linkbtn:hover, .linkbtn:hover { opacity: .8; }
/* cellar-browse modal pager */
.cbpager { display: flex; justify-content: center; align-items: center; gap: 12px; margin-top: 12px; }
.cbpager .muted { font-size: 12.5px; }
.cellarcard .howto { margin: 2px 0 12px; padding-left: 20px; display: grid; gap: 5px; }
.cellarcard .howto li { font-size: 13px; color: var(--ink-soft); line-height: 1.45; }
.cellarcard .howto li b { color: var(--ink); }

/* ---- toast ------------------------------------------------------------- */
.toast { position: fixed; left: 50%; bottom: 84px; transform: translate(-50%, 12px); background: var(--toast-bg); color: var(--toast-fg); font-size: 13px; padding: 9px 16px; border-radius: 999px; box-shadow: var(--shadow-lg); opacity: 0; transition: opacity .25s, transform .25s; z-index: 300; pointer-events: none; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---- header overlays: ＋ menu + Ask/Social slide-overs ----------------- */
.iconbtn.gated { position: relative; }
.iconbtn.gated::after { content: ""; position: absolute; right: -3px; top: -5px; width: 12px; height: 12px; background: var(--gold-deep); -webkit-mask: var(--ico-lock) center/contain no-repeat; mask: var(--ico-lock) center/contain no-repeat; }
/* gated main tabs (Pair/Board for non-Pro) — small inline lock after the label */
nav.tabs button.gated::after { content: ""; display: inline-block; width: 11px; height: 11px; margin-left: 4px; vertical-align: middle; background: var(--gold-deep); -webkit-mask: var(--ico-lock) center/contain no-repeat; mask: var(--ico-lock) center/contain no-repeat; }
.popmenu { position: fixed; top: 56px; right: 12px; z-index: 260; background: var(--card); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-lg); overflow: hidden; min-width: 196px; display: flex; flex-direction: column; }
.popmenu button { font: inherit; font-size: 14.5px; text-align: left; background: none; border: none; color: var(--ink); padding: 12px 16px; cursor: pointer; }
.popmenu button + button { border-top: 1px solid var(--line); }
.popmenu button:hover { background: var(--bg-2); }
#soBackdrop { position: fixed; inset: 0; background: var(--overlay-soft); z-index: 240; opacity: 0; transition: opacity .25s; }
#soBackdrop.show { opacity: 1; }
.slideover { position: fixed; top: 0; right: 0; height: 100%; width: min(460px, 100%); background: linear-gradient(180deg, var(--bg), var(--bg-2)); border-left: 1px solid var(--line); box-shadow: var(--shadow-lg); z-index: 250; display: flex; flex-direction: column; transform: translateX(100%); transition: transform .26s ease; }
.slideover.open { transform: translateX(0); }
.slideover .sohead { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 16px 18px 12px; border-bottom: 1px solid var(--line); }
.slideover .sohead h2 { margin: 0; font-size: 20px; }
.slideover .sobody { flex: 1; overflow: auto; padding: 16px 18px 28px; -webkit-overflow-scrolling: touch; }
.slideover .subtabs { display: flex; gap: 0; padding: 0 18px; border-bottom: 1px solid var(--line); }
.slideover .subtabs button { font: inherit; font-weight: 600; font-size: 14px; background: none; border: none; border-bottom: 2px solid transparent; color: var(--ink-soft); padding: 10px 14px; cursor: pointer; }
.slideover .subtabs button.active { color: var(--ink); border-bottom-color: var(--gold); }

/* ---- ⚙ Appearance picker ------------------------------------------------ */
button.chip { font-family: inherit; }
.themerow { margin-top: 4px; }

/* ---- phone nav: fixed bottom tab bar + raised centre ＋ FAB -------------- */
@media (max-width: 640px) {
  #plusBtn { display: none; }                /* ＋ moves from the header to the FAB */
  /* the header's backdrop-filter would make it the containing block for position:fixed
     children — the bottom bar would pin to the header, not the viewport. Opaque bg instead. */
  header.app { backdrop-filter: none; background: var(--bg); }
  nav.tabs {
    position: fixed; bottom: 0; left: 0; right: 0; z-index: 90;   /* under modals (100) & slide-overs (250) */
    max-width: none; margin: 0; gap: 0;
    padding: 4px 6px calc(4px + env(safe-area-inset-bottom));
    background: var(--header-bg); backdrop-filter: saturate(140%) blur(10px);
    border-top: 1px solid var(--line);
  }
  nav.tabs button {
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
    max-width: none; padding: 6px 2px 5px; font-size: 10.5px; font-weight: 600;
    border-bottom: none; border-radius: 10px; position: relative;
  }
  nav.tabs button.active { color: var(--gold-deep); border-bottom: none; }
  nav.tabs .ticon { width: 22px; height: 22px; margin: 0; }
  nav.tabs button.gated::after { position: absolute; top: 0; right: 50%; margin-right: -24px; }
  nav.tabs .fab {
    display: flex; align-items: center; justify-content: center;
    flex: 0 0 54px; width: 54px; height: 54px; margin: -20px 4px 0;
    border-radius: 50%; background: var(--gold); color: var(--on-gold); border: none;
    font-size: 30px; line-height: 1; padding: 0; box-shadow: var(--shadow-lg); cursor: pointer;
  }
  .wrap { padding-bottom: 110px; }
  .sitefoot { padding-bottom: calc(96px + env(safe-area-inset-bottom)); }
  .popmenu { top: auto; bottom: calc(84px + env(safe-area-inset-bottom)); left: 50%; right: auto; transform: translateX(-50%); }
  .toast { bottom: calc(130px + env(safe-area-inset-bottom)); }
  /* launcher rides just above the bottom tab bar; "Ask" alone on phones (panel header says the rest) */
  .askfab { right: 14px; bottom: calc(78px + env(safe-area-inset-bottom)); padding: 11px 16px 11px 13px; font-size: 14px; }
  .askfab .al-rest { display: none; }
}
