/* ============================================================
   HYDRATE — design system
   Porcelain light surface · deep-ink structure · glacial aqua
   accent. One OS pane, masterful transitions, command bar dock.
   ============================================================ */

:root {
  --porcelain: #FBFAF7;     /* near-white, a whisper warm */
  --porcelain-2: #F3F1EB;
  --ink: #29261F;           /* warm near-black */
  --deep: #3E362C;          /* deep warm brown — buttons, brand chip */
  --deep-2: #4A4136;
  --tan: #F0EDE5;           /* the "darker" surfaces — barely, deliberately */
  --tan-2: #E9E4D8;
  --aqua: #0E9CC9;          /* pure-water blue — validated, passes all six checks */
  --aqua-ink: #0B7FA5;
  --ice: #7FD9F2;
  --mint: #4E8F55;
  --ink-rgb: 41, 38, 31;      /* every ink-tinted overlay reads from here */
  --surf-rgb: 255, 255, 255;  /* every glass/card surface reads from here */
  --shade-rgb: 62, 54, 44;    /* every shadow reads from here */
  --gloss: rgb(255 255 255 / .5); /* the top-edge specular hairline */
  --line: rgba(var(--ink-rgb), .09);
  --line-strong: rgba(var(--ink-rgb), .17);
  --muted: rgba(var(--ink-rgb), .58);
  --faint: rgba(var(--ink-rgb), .38);
  --glass: rgba(var(--surf-rgb), .68);
  --glass-solid: rgba(var(--surf-rgb), .92);
  --shadow: 0 1px 2px rgba(var(--shade-rgb),.05), 0 12px 40px -12px rgba(var(--shade-rgb),.15);
  --shadow-lift: 0 2px 6px rgba(var(--shade-rgb),.07), 0 24px 60px -16px rgba(var(--shade-rgb),.24);
  --r: 22px;
  --r-sm: 12px;
  --font-display: 'Sora', sans-serif;
  --font-body: 'Instrument Sans', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --dock-h: 104px; /* handle + input only — tabs live in the top bar now */
  --ease-master: cubic-bezier(.32, .72, .18, 1);
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
/* the living water layer — fixed; content floats and scrolls, water doesn't */
#waterLoop { position: fixed; inset: 0; z-index: 0; pointer-events: none; }
#waterLoop svg, #waterLoop video { width: 100%; height: 100%; object-fit: cover; display: block; }
#siteScroll, .topbar, .dock, .palette, .auth-sheet { position: relative; z-index: 1; }
.topbar { z-index: 40; } .dock { z-index: 50; } .palette { z-index: 90; } .auth-sheet { z-index: 95; }

body {
  background: var(--porcelain);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  overflow: hidden; /* scroll shell below */
  -webkit-font-smoothing: antialiased;
}

/* ---------- scroll shell (composition-gate safe) ---------- */
#siteScroll {
  height: 100dvh;
  overflow-y: auto;
  overflow-x: hidden;
  scroll-behavior: smooth;
  padding-bottom: calc(var(--dock-h) + 40px);
}

.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 12px; z-index: 99; background: var(--deep); color: #fff; padding: 8px 14px; border-radius: 8px; }

a { color: var(--aqua-ink); text-decoration: none; }
img { max-width: 100%; display: block; }
button { font-family: inherit; }

/* ---------- masterful pane transitions ---------- */
::view-transition-old(root) { animation: paneOut .26s var(--ease-master) both; }
::view-transition-new(root) { animation: paneIn .44s var(--ease-master) both; }
@keyframes paneOut { to { opacity: 0; transform: translateY(-14px) scale(.992); filter: blur(3px); } }
@keyframes paneIn { from { opacity: 0; transform: translateY(22px) scale(.996); filter: blur(4px); } }
#view.pane-leave { opacity: 0; transform: translateY(-14px); filter: blur(3px); transition: all .18s var(--ease-master); }
#view.pane-enter { animation: paneIn .44s var(--ease-master) both; }
#view { will-change: opacity, transform; }

/* ---------- system bar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 40;
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px;
  padding: 8px clamp(16px, 4vw, 40px);
  background: linear-gradient(rgba(251,250,247,.88), rgba(251,250,247,.66));
  backdrop-filter: blur(18px) saturate(1.5);
  -webkit-backdrop-filter: blur(18px) saturate(1.5);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); font-family: var(--font-display); font-weight: 700; letter-spacing: -.01em; }
.brand .drop { width: 30px; height: 30px; border-radius: 9px; background: var(--deep); display: grid; place-items: center; }
.brand .drop svg { width: 17px; height: 17px; stroke: #EFC9AE; fill: none; stroke-width: 1.7; }
.brand .b-name { font-size: 16px; line-height: 1.15; }
.brand .b-sub { display: block; font-family: var(--font-mono); font-size: 9px; font-weight: 500; letter-spacing: .12em; color: var(--muted); text-transform: uppercase; }
.sys { display: flex; align-items: center; gap: 10px; font-family: var(--font-mono); font-size: 11.5px; color: var(--muted); }
.sys .chip {
  display: inline-flex; align-items: center; gap: 6px;
  border: 1px solid var(--line); border-radius: 999px;
  background: var(--glass); padding: 5px 11px; white-space: nowrap;
}
.acc-chip { cursor: pointer; color: var(--ink); font-family: var(--font-body); font-weight: 600; font-size: 12.5px; }
.acc-chip:hover { border-color: var(--aqua); }
#sndBtn { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
#sndBtn.snd-on { color: var(--aqua-ink); border-color: rgba(14,156,201,.45); background: rgba(14,156,201,.08); }
#sndBtn.snd-on svg { animation: sndPulse 1.8s ease-in-out infinite; }
@keyframes sndPulse { 0%,100% { opacity: 1; } 50% { opacity: .55; } }
.chip-ico { width: 14px; height: 14px; stroke: var(--aqua-ink); fill: none; stroke-width: 1.8; }
.live-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--mint); box-shadow: 0 0 0 3px rgba(43,179,163,.18); display: inline-block; }
.live-dot.closed { background: #B4832B; box-shadow: 0 0 0 3px rgba(180,131,43,.16); }
.k-hint { cursor: pointer; border: 1px solid var(--line); border-radius: 8px; background: var(--glass); color: var(--muted); font-family: var(--font-mono); font-size: 11px; padding: 5px 9px; }
.k-hint:hover { border-color: var(--line-strong); color: var(--ink); }
@media (max-width: 700px) { .hide-sm { display: none !important; } }
.brand .b-sub { white-space: nowrap; }
@media (max-width: 700px) {
  .topbar { padding: 8px 12px; gap: 8px; }
  .brand .b-name { font-size: 14px; }
  .brand .b-sub { font-size: 7.5px; letter-spacing: .08em; }
  .k-hint { display: none; }
  .sys { gap: 6px; }
  .sys .chip { padding: 4px 9px; }
}

/* ---------- command bar dock (the OS pane's one control) ---------- */
.dock {
  position: fixed; z-index: 50;
  left: 50%; transform: translateX(-50%);
  bottom: calc(10px + env(safe-area-inset-bottom, 0px));
  width: min(680px, calc(100vw - 16px));
  background: rgba(242, 239, 231, .9);
  backdrop-filter: blur(18px) saturate(1.2);
  -webkit-backdrop-filter: blur(18px) saturate(1.2);
  border: 1px solid rgba(var(--ink-rgb),.10);
  border-radius: 26px;
  box-shadow: inset 0 1px 0 var(--gloss), 0 14px 44px -10px rgba(var(--shade-rgb),.35);
  overflow: hidden;
  transition: height .5s var(--ease-master), width .5s var(--ease-master);
  display: flex; flex-direction: column;
  height: var(--dock-h);
}
.dock.chat-open { height: min(62dvh, 560px); width: min(720px, calc(100vw - 16px)); }
.dock-handle {
  flex: none; align-self: center; margin-top: 4px;
  width: 46px; height: 20px; border: 0; cursor: grab; background: none;
  color: rgba(var(--ink-rgb),.4); display: grid; place-items: center;
  touch-action: none;
}
.dock-handle:hover { color: var(--ink); }
.dock-handle svg { width: 18px; height: 18px; transition: transform .4s var(--ease-master); }
.dock.chat-open .dock-handle svg { transform: rotate(180deg); }
.dock-icons {
  display: flex; gap: 2px; padding: 2px 8px 2px;
  overflow-x: auto; scrollbar-width: none; flex: none;
}
.dock-icons::-webkit-scrollbar { display: none; }
.dock-icons a {
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  min-width: 58px; padding: 6px 8px 5px;
  border-radius: 14px;
  color: rgba(var(--ink-rgb),.58);
  font-size: 9.5px; font-weight: 500; letter-spacing: .02em;
  transition: background .18s, color .18s;
  white-space: nowrap;
}
.dock-icons a svg { width: 19px; height: 19px; stroke: currentColor; fill: none; stroke-width: 1.7; }
.dock-icons a svg.digi-ico { width: 22px; height: 22px; stroke: none; overflow: visible; transition: transform .25s var(--ease-master); }
.dock-icons a:hover { color: var(--ink); background: rgba(var(--ink-rgb),.06); }
.dock-icons a:hover svg.digi-ico { transform: translateY(-2px) scale(1.06); }
.dock-icons a[aria-current="page"] { color: var(--ink); background: rgba(14,156,201,.14); }
.dock-icons a[aria-current="page"] svg { stroke: var(--aqua); }
.dock-icons a[aria-current="page"] svg.digi-ico { animation: digiBob 2.6s ease-in-out infinite; }
@keyframes digiBob { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-2.5px); } }
.dg-shine { animation: dgShine 3.2s ease-in-out infinite; }
@keyframes dgShine { 0%,100% { opacity: .5; } 50% { opacity: .95; } }
.dg-wheel { transform-box: fill-box; transform-origin: center; }
a[aria-current="page"] .dg-wheel, a:hover .dg-wheel { animation: dgSpin 1.4s linear infinite; }
@keyframes dgSpin { to { transform: rotate(360deg); } }
.dg-wave { transform-box: fill-box; transform-origin: center; animation: dgWave 3.4s ease-in-out infinite; }
@keyframes dgWave { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-1.3px); } }
.dg-dot { transform-box: fill-box; transform-origin: center; }
a:hover .dg-dot, a[aria-current="page"] .dg-dot { animation: dgPop 1.2s ease-in-out infinite; }
.dg-dot:nth-of-type(2) { animation-delay: .12s !important; }
.dg-dot:nth-of-type(3) { animation-delay: .24s !important; }
.dg-dot:nth-of-type(4) { animation-delay: .36s !important; }
@keyframes dgPop { 0%,100% { transform: scale(1); } 50% { transform: scale(1.22); } }
@media (prefers-reduced-motion: reduce) { .digi-ico, .dg-shine, .dg-wheel, .dg-wave, .dg-dot { animation: none !important; } }

.dock-chat { flex: 1; display: flex; flex-direction: column; min-height: 0; }
.chat-log {
  flex: 1; overflow-y: auto; min-height: 0;
  display: none; flex-direction: column; gap: 10px;
  padding: 12px 16px 6px;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  touch-action: pan-y;
}
.chat-x {
  display: none; position: absolute; top: 10px; right: 12px; z-index: 5;
  width: 30px; height: 30px; border-radius: 50%; border: 0; cursor: pointer;
  background: rgba(var(--ink-rgb),.08); color: rgba(var(--ink-rgb),.6); font-size: 13px; line-height: 1;
}
.chat-x:hover { background: rgba(var(--ink-rgb),.14); color: var(--ink); }
.dock { position: fixed; } /* anchor context for .chat-x */
.dock.chat-open .chat-x { display: grid; place-items: center; }
.ora-ava { width: 26px; height: 26px; border-radius: 8px; flex: none; margin-right: 2px; background: #fff; padding: 2px; }
.dock.chat-open .chat-log { display: flex; }
.msg { max-width: 86%; font-size: 13.5px; line-height: 1.55; border-radius: 16px; padding: 9px 13px; animation: msgIn .32s var(--ease-master) both; }
@keyframes msgIn { from { opacity: 0; transform: translateY(8px); } }
.msg.me { align-self: flex-end; background: var(--aqua); color: #fff; border-bottom-right-radius: 6px; }
.msg.bot { align-self: flex-start; background: rgba(var(--surf-rgb),.78); color: var(--ink); border-bottom-left-radius: 6px; box-shadow: 0 1px 2px rgba(var(--shade-rgb),.06); }
.msg.bot b { color: var(--ink); }
.msg.bot a { color: var(--aqua-ink); }
.msg.typing { display: inline-flex; gap: 5px; align-items: center; padding: 12px 15px; }
.tdot { width: 6px; height: 6px; border-radius: 50%; background: rgba(var(--ink-rgb),.4); animation: tdot 1.1s ease-in-out infinite; }
.tdot:nth-child(2) { animation-delay: .18s; }
.tdot:nth-child(3) { animation-delay: .36s; }
@keyframes tdot { 0%,100% { opacity: .3; transform: translateY(0); } 40% { opacity: 1; transform: translateY(-3px); } }
.chat-chips { display: flex; flex-wrap: wrap; gap: 6px; align-self: flex-start; }
a.chat-chip { text-decoration: none; display: inline-block; }
.chat-chip {
  cursor: pointer; border: 1px solid rgba(14,156,201,.4); border-radius: 999px;
  background: rgba(var(--surf-rgb),.6); color: var(--aqua-ink);
  font-size: 12px; font-weight: 600; padding: 6px 12px;
  transition: background .15s;
}
.chat-chip:hover { background: rgba(14,156,201,.14); }
.dock-input {
  flex: none; display: flex; align-items: center; gap: 9px;
  padding: 10px 14px 16px;
}
.dock-input input {
  flex: 1; border: 1px solid rgba(var(--ink-rgb),.12); border-radius: 18px;
  background: #FFFFFF; outline: none;
  color: var(--ink); font: 500 15px var(--font-body);
  padding: 14px 18px; min-height: 50px;
  box-shadow: 0 1px 3px rgba(var(--shade-rgb),.07);
  transition: border-color .2s, box-shadow .2s;
}
.dock-input input::placeholder { color: rgba(var(--ink-rgb),.4); }
.dock-input input:focus { border-color: rgba(14,156,201,.5); box-shadow: 0 0 0 3px rgba(14,156,201,.12); }
.dock-send {
  width: 44px; height: 44px; border-radius: 14px; border: 0; cursor: pointer;
  background: var(--aqua); color: #fff; display: grid; place-items: center;
  transition: transform .15s, background .2s; flex: none;
}
.dock-send:hover { background: var(--aqua-ink); }
.dock-send:active { transform: scale(.92); }
.dock-send svg { width: 17px; height: 17px; stroke: currentColor; fill: none; stroke-width: 2; }
.chat-close {
  display: none; flex: none; align-self: center; margin-top: 6px;
  border: 0; background: none; color: rgba(var(--ink-rgb),.42);
  font-family: var(--font-mono); font-size: 10px; letter-spacing: .1em; cursor: pointer; padding: 4px 10px;
}
.dock.chat-open .chat-close { display: block; }
.chat-note { flex: none; text-align: center; font-family: var(--font-mono); font-size: 9px; letter-spacing: .08em; color: rgba(var(--ink-rgb),.36); padding-bottom: 6px; display: none; }
.dock.chat-open .chat-note { display: block; }

/* ---------- layout primitives ---------- */
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 40px); }
.panel { padding-top: clamp(22px, 4vw, 42px); padding-bottom: 12px; }
.p-head { max-width: 720px; padding-top: clamp(18px, 3vw, 34px); }
.kicker { font-family: var(--font-mono); font-size: 11px; font-weight: 500; letter-spacing: .18em; text-transform: uppercase; color: var(--aqua-ink); margin-bottom: 14px; }
.display {
  font-family: var(--font-display); font-weight: 700; letter-spacing: -.03em;
  font-size: clamp(26px, 4.6vw, 46px); line-height: 1.07; margin: 0 0 14px;
}
.display .soft { color: var(--aqua-ink); }
h2.h { font-family: var(--font-display); font-weight: 600; letter-spacing: -.02em; font-size: clamp(21px, 2.6vw, 28px); margin: 0 0 8px; }
h3 { font-family: var(--font-display); font-weight: 600; font-size: 16px; margin: 0 0 6px; letter-spacing: -.01em; }
.lede { font-size: clamp(16px, 1.8vw, 18.5px); color: var(--muted); max-width: 620px; margin: 0; }
.section { margin: clamp(24px, 3.6vw, 44px) 0; }
.grid { display: grid; gap: 14px; }
.g2 { grid-template-columns: repeat(2, 1fr); }
.g3 { grid-template-columns: repeat(3, 1fr); }
.g4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 940px) { .g4 { grid-template-columns: repeat(2, 1fr); } .g3 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .g2, .g3, .g4 { grid-template-columns: 1fr; } }

/* ---------- glass tiles ---------- */
.glass {
  background: rgba(var(--surf-rgb),.62);
  border: 1px solid rgba(var(--surf-rgb),.75);
  border-radius: var(--r);
  box-shadow: inset 0 1px 0 var(--gloss), var(--shadow);
  backdrop-filter: blur(16px) saturate(1.5);
  -webkit-backdrop-filter: blur(16px) saturate(1.5);
}
.tile { padding: 22px; position: relative; overflow: hidden; }
.tile.link { display: block; color: var(--ink); transition: transform .22s ease, box-shadow .22s ease, border-color .22s; }
.tile.link:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); border-color: var(--line-strong); }
.tile .t-icon { width: 26px; height: 26px; stroke: var(--aqua-ink); fill: none; stroke-width: 1.6; margin-bottom: 12px; }
.tile p { color: var(--muted); font-size: 14px; margin: 4px 0 0; }
.tile .t-go { position: absolute; top: 18px; right: 18px; font-family: var(--font-mono); font-size: 11px; color: var(--faint); }
.tile-dark { background: linear-gradient(150deg, var(--tan), var(--tan-2)); color: var(--ink); border-color: rgba(var(--ink-rgb),.10); }
.tile-dark p { color: var(--muted); }
.tile-dark .t-icon { stroke: var(--aqua); }
.tile-dark h3, .tile-dark .stat-n { color: var(--ink); }

/* ---------- stat tiles ---------- */
.stat { padding: 18px 20px; }
.stat .stat-k { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.stat .stat-n { font-family: var(--font-display); font-weight: 700; font-size: clamp(26px, 3vw, 34px); letter-spacing: -.02em; line-height: 1.1; margin-top: 6px; }
.stat .stat-s { font-size: 12.5px; color: var(--faint); margin-top: 3px; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--font-body); font-weight: 600; font-size: 14.5px;
  border-radius: 999px; padding: 12px 22px; cursor: pointer;
  border: 1px solid transparent;
  transition: transform .15s ease, box-shadow .2s, background .2s;
}
.btn:active { transform: scale(.98); }
.btn-primary { background: var(--deep); color: #fff; box-shadow: 0 8px 24px -8px rgba(10,53,71,.5); }
.btn-primary:hover { background: var(--deep-2); }
.btn-aqua { background: var(--aqua); color: #fff; box-shadow: 0 8px 24px -8px rgba(14,139,168,.55); }
.btn-aqua:hover { background: var(--aqua-ink); }
.btn-ghost { background: var(--glass); border-color: var(--line-strong); color: var(--ink); }
.btn-ghost:hover { border-color: var(--ink); }
.btn-sm { padding: 8px 16px; font-size: 13px; }
.p-cta { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-top: 22px; }
.p-cta .aside { font-size: 13px; color: var(--faint); }

/* ---------- arrival geo popup ---------- */
.geo-pop {
  position: fixed; inset: 0; z-index: 96; display: grid; place-items: center;
  background: rgba(var(--ink-rgb),.28); backdrop-filter: blur(7px);
}
.geo-panel {
  width: min(400px, calc(100vw - 32px)); text-align: center;
  background: rgba(var(--surf-rgb),.92); border: 1px solid rgba(var(--surf-rgb),.8);
  border-radius: 26px; box-shadow: var(--shadow-lift);
  padding: 30px 26px 24px;
  animation: sheetIn .5s var(--ease-master) both;
}
.geo-drop { width: 54px; height: 54px; margin: 0 auto 14px; animation: geoBob 2.4s ease-in-out infinite; }
@keyframes geoBob { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }
.geo-panel h2 { font-family: var(--font-display); font-weight: 700; letter-spacing: -.02em; font-size: 21px; margin: 0 0 6px; }
.geo-panel p { font-size: 13.5px; color: var(--muted); margin: 0 0 16px; }
.geo-fine { font-size: 10.5px; color: var(--faint); margin-top: 12px !important; line-height: 1.5; }
.geo-fine a { color: var(--muted); text-decoration: underline; }

/* ---------- marketplace (home = the app, viewport-locked) ---------- */
body.cockpit-mode #siteScroll { overflow: hidden; padding-bottom: 0; }
.mkt {
  display: grid; gap: 12px;
  grid-template-columns: minmax(360px, 43%) 1fr;
  /* every component ends ABOVE the input bar — empty space flanks the bar */
  height: calc(100dvh - 54px - var(--dock-h) - 22px);
  padding: 10px clamp(10px, 1.6vw, 20px) 0;
  max-width: 1600px; margin: 0 auto; width: 100%;
}
.mkt-left {
  overflow-y: auto; min-height: 0; scrollbar-width: none;
  display: flex; flex-direction: column; gap: 12px;
  padding-bottom: 10px;
}
.mkt-left::-webkit-scrollbar { display: none; }
@media (max-width: 980px) {
  .mkt { grid-template-columns: 1fr; height: auto; }
  body.cockpit-mode #siteScroll { overflow-y: auto; padding-bottom: calc(var(--dock-h) + 40px); }
  .mkt-map { height: 46dvh; min-height: 320px; order: -1; }
  .mkt-left { overflow: visible; padding-bottom: 0; }
}
.mkt-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; flex: none; }
.mkt-head .ck-mode { margin: 0; flex: none; }
.mkt-head .ck-mode button { padding: 7px 14px; flex: none; }
.mkt-head .ck-chips { margin: 0; }
.tile-carousel {
  flex: none; display: flex; gap: 10px;
  overflow-x: auto; scroll-snap-type: x proximity; scrollbar-width: none;
  padding: 2px 2px 6px;
}
/* gallery tiles — the bottom-left exploration grid */
.gal-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.gal {
  display: block; position: relative; border-radius: 16px; overflow: hidden;
  aspect-ratio: 16/10; color: #fff;
  background: linear-gradient(150deg, #0E9CC9, #0B7FA5);
  box-shadow: var(--shadow); transition: transform .2s var(--ease-master);
}
.gal:hover { transform: translateY(-2px); }
.gal img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .9; }
.gal .g-scrim { position: absolute; inset: 0; background: linear-gradient(180deg, transparent 30%, rgba(10,40,52,.72)); }
.gal .g-t { position: absolute; left: 12px; right: 12px; bottom: 10px; font: 600 13.5px var(--font-body); letter-spacing: -.01em; text-shadow: 0 1px 3px rgba(0,0,0,.3); }
.gal .g-s { position: absolute; left: 12px; top: 10px; font-family: var(--font-mono); font-size: 9px; letter-spacing: .12em; text-transform: uppercase; opacity: .85; }
.gal.gal-soft { background: linear-gradient(150deg, #E8F4F9, #D3ECF4); color: var(--ink); }
.gal.gal-soft .g-scrim { background: none; }
.gal.gal-deep { background: linear-gradient(150deg, #143C4C, #0B2833); }
.tile-carousel::-webkit-scrollbar { display: none; }
.pt {
  flex: none; width: 148px; scroll-snap-align: start;
  background: rgba(var(--surf-rgb),.72); backdrop-filter: blur(14px);
  border: 1px solid rgba(var(--surf-rgb),.8); border-radius: 16px;
  box-shadow: var(--shadow); padding: 9px; position: relative;
  transition: transform .2s var(--ease-master), box-shadow .2s;
}
.pt:hover { transform: translateY(-2px); box-shadow: var(--shadow-lift); }
.pt-img { width: 100%; aspect-ratio: 1; border-radius: 11px; object-fit: cover; background: linear-gradient(150deg, #E8F4F9, #D8EDF5); display: grid; place-items: center; }
.pt-img svg { width: 34px; height: 34px; stroke: var(--aqua); fill: none; stroke-width: 1.5; }
.pt-t { font: 600 12px var(--font-body); line-height: 1.25; margin-top: 7px; color: var(--ink); min-height: 30px; }
.pt-p { font-family: var(--font-mono); font-size: 10.5px; color: var(--aqua-ink); margin-top: 2px; }
.pt-add {
  position: absolute; top: 14px; right: 14px;
  width: 28px; height: 28px; border-radius: 50%; border: 0; cursor: pointer;
  background: var(--aqua); color: #fff; font-size: 16px; line-height: 1;
  box-shadow: 0 2px 8px rgba(11,127,165,.4);
}
.pt-add:hover { background: var(--aqua-ink); }
.mkt-map { position: relative; flex: 1; min-height: 0; border-radius: var(--r); overflow: hidden; border: 1px solid rgba(var(--surf-rgb),.75); box-shadow: var(--shadow); }
.mkt-map .leaflet-container, .mkt-map > svg { width: 100%; height: 100%; }
.map-cart {
  position: absolute; top: 12px; right: 12px; z-index: 900;
  width: min(280px, calc(100% - 24px));
  background: rgba(var(--surf-rgb),.92); backdrop-filter: blur(14px);
  border: 1.5px solid rgba(14,156,201,.4); border-radius: 16px;
  box-shadow: var(--shadow); padding: 12px 14px;
  max-height: 55%; overflow-y: auto;
}
.mkt-fixed {
  position: sticky; top: 0; z-index: 6;
  display: flex; flex-direction: column; gap: 10px;
  background: linear-gradient(rgba(251,250,247,.97) 78%, rgba(251,250,247,0));
  padding-bottom: 10px; margin-bottom: -4px;
}
.store-panel {
  position: absolute; inset: 0; z-index: 950; overflow-y: auto;
  background: rgba(251,250,247,.96); backdrop-filter: blur(14px);
  padding: 16px 18px calc(var(--dock-h) + 20px);
  animation: sheetIn .4s var(--ease-master) both;
}
.sp-crumbs { font-family: var(--font-mono); font-size: 11px; color: var(--faint); display: flex; gap: 6px; align-items: center; margin-bottom: 12px; }
.sp-back { border: 1px solid var(--line-strong); background: #fff; border-radius: 999px; padding: 5px 12px; cursor: pointer; font: 600 11px var(--font-mono); color: var(--ink); }
.sp-back:hover { border-color: var(--aqua); color: var(--aqua-ink); }
.sp-title { font-family: var(--font-display); font-weight: 700; letter-spacing: -.02em; font-size: 24px; margin: 0 0 4px; }
.sp-sub { font-size: 13px; color: var(--muted); margin: 0 0 14px; }
.sp-grid { display: grid; gap: 10px; }
.map-cart-pill {
  position: absolute; top: 12px; right: 12px; z-index: 900;
  background: rgba(var(--surf-rgb),.92); border: 1px solid rgba(var(--surf-rgb),.85);
  border-radius: 999px; padding: 8px 14px; font: 600 12px var(--font-body);
  color: var(--muted); box-shadow: var(--shadow);
}
.ck-rail { overflow-y: auto; min-height: 0; display: flex; flex-direction: column; gap: 10px; scrollbar-width: thin; padding-bottom: 6px; }
.ck-center { position: relative; min-height: 0; border-radius: var(--r); overflow: hidden; border: 1px solid rgba(var(--surf-rgb),.75); box-shadow: var(--shadow); }
.ck-center svg { width: 100%; height: 100%; display: block; background: linear-gradient(160deg, #E8F2EC, #F1F5EC); }
.ck-card { background: rgba(var(--surf-rgb),.66); backdrop-filter: blur(16px) saturate(1.5); -webkit-backdrop-filter: blur(16px) saturate(1.5); border: 1px solid rgba(var(--surf-rgb),.78); border-radius: 16px; box-shadow: var(--shadow); padding: 14px 15px; }
.ck-h { font-family: var(--font-mono); font-size: 9.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--faint); margin-bottom: 8px; }
.ck-town { display: flex; align-items: center; justify-content: space-between; width: 100%; text-align: left; border: 0; background: none; cursor: pointer; padding: 7px 8px; border-radius: 9px; font: 500 13px var(--font-body); color: var(--muted); }
.ck-town:hover { background: rgba(var(--ink-rgb),.05); color: var(--ink); }
.ck-town.on { background: rgba(14,156,201,.12); color: var(--aqua-ink); font-weight: 600; }
.ck-link { display: block; font-size: 12.5px; color: var(--muted); padding: 5px 8px; border-radius: 8px; }
.ck-link:hover { background: rgba(var(--ink-rgb),.05); color: var(--ink); }
.ck-prod { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px dashed var(--line); }
.cp-img { width: 44px; height: 44px; border-radius: 10px; object-fit: cover; flex: none; background: #EAF4F7; }
.cp-img-ph { display: grid; place-items: center; }
.cp-drop { width: 20px; height: 20px; stroke: var(--aqua); fill: none; stroke-width: 1.6; }
.ck-chips { display: flex; flex-wrap: wrap; gap: 5px; margin-bottom: 10px; }
.ck-chip { border: 1px solid var(--line-strong); background: #fff; border-radius: 999px; padding: 4px 10px; font: 600 10.5px var(--font-mono); letter-spacing: .04em; text-transform: uppercase; color: var(--muted); cursor: pointer; }
.ck-chip.on { border-color: var(--aqua); color: var(--aqua-ink); background: rgba(14,156,201,.1); }
.leaflet-tile { filter: saturate(.82) brightness(1.05); }
.leaflet-container { font-family: var(--font-body); }
.leaflet-control-attribution svg, .leaflet-attribution-flag { width: 1em !important; height: .67em !important; display: inline !important; vertical-align: baseline !important; }
.leaflet-control-attribution { font-size: 10px; border-radius: 8px 0 0 0; }
@media (max-width: 980px) { .nm-cta { bottom: 26px; } }
.nm-pin { filter: drop-shadow(0 2px 4px rgba(11,127,165,.4)); }
.nm-station-pin svg { animation: geoBob 2.6s ease-in-out infinite; }
.ck-prod:last-child { border-bottom: 0; }
.ck-prod .cp-n { flex: 1; min-width: 0; }
.ck-prod .cp-t { font-weight: 600; font-size: 13px; line-height: 1.3; }
.ck-prod .cp-p { font-family: var(--font-mono); font-size: 11px; color: var(--aqua-ink); }
.ck-add { width: 28px; height: 28px; border-radius: 50%; border: 1.5px solid var(--line-strong); background: #fff; cursor: pointer; font-size: 15px; line-height: 1; color: var(--ink); flex: none; }
.ck-add:hover { border-color: var(--aqua); color: var(--aqua-ink); }
.ck-cart { border: 1.5px solid rgba(14,156,201,.4); }
.ck-cart-row { display: flex; justify-content: space-between; gap: 8px; font-size: 12.5px; padding: 5px 0; }
.ck-cart-total { display: flex; justify-content: space-between; font-family: var(--font-display); font-weight: 700; font-size: 16px; border-top: 1px solid var(--line); padding-top: 9px; margin-top: 6px; }
.ck-mode { display: flex; gap: 6px; margin: 8px 0 10px; }
.ck-mode button { flex: 1; border: 1.5px solid var(--line-strong); background: #fff; border-radius: 999px; padding: 7px 4px; font: 600 11.5px var(--font-body); cursor: pointer; color: var(--muted); }
.ck-mode button.on { border-color: var(--aqua); color: var(--aqua-ink); background: rgba(14,156,201,.08); }
@media (max-width: 980px) {
  .cockpit { grid-template-columns: 1fr; height: auto; overflow-y: auto; }
  body.cockpit-mode #siteScroll { overflow-y: auto; padding-bottom: calc(var(--dock-h) + 40px); }
  .ck-center { height: 42dvh; min-height: 300px; order: -1; }
  .ck-rail { overflow: visible; }
}

/* ---------- map search pill (the ONE location field, Uber-style) ---------- */
.map-search {
  position: absolute; top: 12px; left: 12px; right: 12px; z-index: 900;
  max-width: 420px;
  display: flex; align-items: center; gap: 7px; flex-wrap: wrap;
  background: rgba(var(--surf-rgb),.9); backdrop-filter: blur(14px);
  border: 1px solid rgba(var(--surf-rgb),.85); border-radius: 18px;
  box-shadow: var(--shadow); padding: 8px 9px;
}
.map-search input {
  flex: 1; min-width: 150px; border: 0; outline: none; background: transparent;
  font: 500 14px var(--font-body); color: var(--ink); padding: 6px 8px;
}
.map-search input::placeholder { color: var(--faint); }
.map-search #locOut { flex-basis: 100%; font-size: 11.5px; padding: 0 8px 2px; min-height: 0; margin: 0; }
.map-search #locOut:empty { display: none; }

/* ---------- the node map ---------- */
.node-map { position: relative; overflow: hidden; border-radius: var(--r); margin-top: 14px; }
.node-map svg { display: block; width: 100%; height: auto; background: linear-gradient(160deg, #EAF3F2, #F2F6F1); }
.nm-zoom { transition: transform 1.1s var(--ease-master); transform-origin: center; }
.nm-town { font-family: var(--font-mono); font-size: 10px; fill: rgba(var(--ink-rgb),.55); }
.nm-dot { fill: rgba(var(--ink-rgb),.3); }
.nm-cov { fill: rgba(95,122,74,.10); stroke: rgba(95,122,74,.35); stroke-width: 1; stroke-dasharray: 3 4; }
.nm-station { animation: geoBob 2.6s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
.nm-you { animation: youPulse 2s ease-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes youPulse { 0% { opacity: 1; } 50% { opacity: .55; } 100% { opacity: 1; } }
.nm-cta {
  position: absolute; left: 12px; bottom: 12px; right: 12px;
  display: flex; gap: 8px; flex-wrap: wrap; align-items: center;
  background: rgba(var(--surf-rgb),.85); backdrop-filter: blur(12px);
  border: 1px solid rgba(var(--surf-rgb),.8); border-radius: 16px; padding: 10px 14px;
  font-size: 13px;
}
.nm-cta b { font-family: var(--font-display); font-size: 13.5px; }
.nm-cta .spacer { flex: 1; }

/* ---------- app location row ---------- */
.loc-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.loc-ico { width: 20px; height: 20px; stroke: var(--aqua); fill: none; stroke-width: 1.7; flex: none; }
.water-card h3 { font-size: 18px; }

/* ---------- hero ---------- */
.hero-os { display: grid; grid-template-columns: 1.1fr .9fr; gap: 18px; align-items: stretch; margin-top: clamp(20px, 3vw, 36px); }
@media (max-width: 880px) { .hero-os { grid-template-columns: 1fr; } }
.ticker {
  display: flex; gap: 22px; flex-wrap: wrap;
  font-family: var(--font-mono); font-size: 11.5px; color: var(--muted);
  border-top: 1px solid var(--line); margin-top: clamp(26px, 4vw, 44px); padding-top: 16px;
}
.ticker b { color: var(--ink); font-weight: 500; }

/* ---------- order flow ---------- */
.steps { display: flex; gap: 8px; flex-wrap: wrap; margin: 22px 0 18px; }
.step-pill {
  font-family: var(--font-mono); font-size: 11px; letter-spacing: .06em;
  border: 1px solid var(--line); border-radius: 999px; padding: 6px 13px; color: var(--faint);
  background: var(--glass);
}
.step-pill.on { border-color: var(--aqua); color: var(--aqua-ink); background: rgba(14,139,168,.08); }
.step-pill.done { color: var(--mint); border-color: rgba(43,179,163,.4); }
.choice-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 12px; }
.choice {
  text-align: left; cursor: pointer; padding: 18px;
  background: var(--glass); border: 1.5px solid var(--line); border-radius: var(--r-sm);
  transition: border-color .15s, background .15s, transform .15s;
  color: var(--ink);
}
.choice:hover { border-color: var(--line-strong); transform: translateY(-2px); }
.choice.sel { border-color: var(--aqua); background: rgba(14,139,168,.07); box-shadow: 0 0 0 3px rgba(14,139,168,.12); }
.choice .c-t { font-weight: 600; font-size: 15px; display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.choice .c-p { font-family: var(--font-mono); font-size: 12px; color: var(--aqua-ink); white-space: nowrap; }
.choice .c-d { font-size: 12.5px; color: var(--muted); margin-top: 5px; line-height: 1.45; }
.order-review { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; align-items: start; }
@media (max-width: 800px) { .order-review { grid-template-columns: 1fr; } }
.receipt { font-size: 14px; }
.receipt .r-row { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px dashed var(--line); }
.receipt .r-row:last-child { border-bottom: 0; }
.receipt .r-row b { font-family: var(--font-mono); font-weight: 500; }
.receipt .r-total { font-family: var(--font-display); font-weight: 700; font-size: 20px; }

/* ---------- coverage checker ---------- */
.cov { display: flex; gap: 10px; margin-top: 14px; flex-wrap: wrap; }
.cov input {
  flex: 1; min-width: 200px;
  font: 500 15px var(--font-body); color: var(--ink);
  background: var(--glass-solid); border: 1.5px solid var(--line-strong); border-radius: 999px;
  padding: 12px 20px; outline: none;
}
.cov input:focus { border-color: var(--aqua); box-shadow: 0 0 0 3px rgba(14,139,168,.14); }
.cov-out { margin-top: 12px; font-size: 14px; min-height: 22px; }
.cov-out .ok { color: var(--mint); font-weight: 600; }
.cov-out .near { color: #B4832B; font-weight: 600; }
.town-cloud { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.town-cloud span { font-family: var(--font-mono); font-size: 11px; border: 1px solid var(--line); border-radius: 999px; padding: 4px 11px; color: var(--muted); background: var(--glass); }

/* ---------- process rail ---------- */
.rail { display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; counter-reset: st; }
@media (max-width: 940px) { .rail { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 600px) { .rail { grid-template-columns: repeat(2, 1fr); } }
.rail .r-step { padding: 16px 14px; counter-increment: st; }
.rail .r-step::before { content: "0" counter(st); font-family: var(--font-mono); font-size: 10.5px; color: var(--aqua-ink); letter-spacing: .1em; }
.rail .r-step h3 { font-size: 13.5px; margin-top: 8px; }
.rail .r-step p { font-size: 12px; color: var(--muted); margin: 4px 0 0; }

/* ---------- commerce cards ---------- */
.shop-block { margin-top: 8px; }
.fwd-embed-note { font-size: 13px; color: var(--faint); margin-top: 10px; }
.fwd-product-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; }
.fwd-card { background: var(--glass); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; box-shadow: var(--shadow); }
.fwd-card:hover { border-color: var(--line-strong); }
.fwd-card-img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 12px; margin-bottom: 12px; background: var(--porcelain-2); }
.fwd-card-title { font-family: var(--font-display); font-weight: 600; font-size: 15px; letter-spacing: -.01em; }
.fwd-card-price { font-family: var(--font-mono); font-size: 13px; color: var(--aqua-ink); margin-top: 4px; }
.fwd-card-desc { font-size: 12.5px; color: var(--muted); margin-top: 6px; }

/* ---------- dashboard ---------- */
.dash-grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: 14px; }
.dash-grid > * { grid-column: span 12; }
@media (min-width: 880px) {
  .dg-4 { grid-column: span 4 !important; }
  .dg-6 { grid-column: span 6 !important; }
  .dg-8 { grid-column: span 8 !important; }
}
.countdown-strip { display: flex; gap: 14px; align-items: baseline; flex-wrap: wrap; }
.countdown-strip .cd-n { font-family: var(--font-display); font-weight: 700; font-size: 40px; letter-spacing: -.03em; }
.dash-note { font-family: var(--font-mono); font-size: 10.5px; color: var(--faint); letter-spacing: .06em; }
select.dash-sel, input.dash-in {
  font: 500 14px var(--font-body); color: var(--ink);
  background: var(--glass-solid); border: 1.5px solid var(--line-strong); border-radius: 10px;
  padding: 9px 12px; outline: none; max-width: 100%;
}
select.dash-sel:focus, input.dash-in:focus { border-color: var(--aqua); }
.hydro-controls { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-top: 10px; }
.chart-wrap { position: relative; margin-top: 12px; }
.chart-wrap svg { display: block; width: 100%; height: auto; }
.chart-tip {
  position: absolute; pointer-events: none; transform: translate(-50%, -130%);
  background: var(--deep); color: #fff; font-family: var(--font-mono); font-size: 11px;
  padding: 5px 9px; border-radius: 8px; white-space: nowrap; opacity: 0; transition: opacity .12s;
}
.chart-tip.show { opacity: 1; }
.bottle-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 0; border-bottom: 1px dashed var(--line); font-size: 14px; }
.bottle-row:last-child { border-bottom: 0; }
.stepper { display: inline-flex; align-items: center; gap: 10px; }
.stepper button { width: 28px; height: 28px; border-radius: 50%; border: 1px solid var(--line-strong); background: var(--glass); cursor: pointer; font-size: 15px; color: var(--ink); line-height: 1; }
.stepper button:hover { border-color: var(--ink); }
.stepper b { font-family: var(--font-mono); font-size: 14px; min-width: 18px; text-align: center; }

/* ---------- hours table ---------- */
.hours { font-size: 14px; width: 100%; border-collapse: collapse; }
.hours td { padding: 8px 0; border-bottom: 1px dashed var(--line); }
.hours td:last-child { text-align: right; font-family: var(--font-mono); font-size: 12.5px; }
.hours tr.today td { color: var(--aqua-ink); font-weight: 600; }

/* ---------- insights / articles ---------- */
.art-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }
.art-card { display: block; color: var(--ink); padding: 22px; transition: transform .22s ease, box-shadow .22s, border-color .22s; }
.art-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); border-color: var(--line-strong); }
.art-tag { font-family: var(--font-mono); font-size: 10px; letter-spacing: .14em; text-transform: uppercase; color: var(--aqua-ink); }
.art-card h3 { font-size: 18px; margin-top: 8px; }
.art-card p { font-size: 13.5px; color: var(--muted); margin-top: 6px; }
.art-min { font-family: var(--font-mono); font-size: 11px; color: var(--faint); margin-top: 12px; display: block; }
.article { max-width: 720px; }
.article h2 { font-family: var(--font-display); font-weight: 600; letter-spacing: -.02em; font-size: 22px; margin: 34px 0 10px; }
.article p { font-size: 16.5px; line-height: 1.75; color: rgba(7,34,46,.82); margin: 14px 0; }
.article strong { color: var(--ink); }
.article .art-cta { margin: 30px 0; }
.crumbs { font-family: var(--font-mono); font-size: 11px; color: var(--faint); margin-bottom: 14px; }
.crumbs a { color: var(--muted); }

/* ---------- command palette ---------- */
.palette { position: fixed; inset: 0; z-index: 90; background: rgba(var(--ink-rgb),.35); backdrop-filter: blur(6px); display: grid; place-items: start center; padding-top: 12vh; }
.palette[hidden] { display: none; }
.palette-panel { width: min(560px, calc(100vw - 32px)); background: var(--glass-solid); border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow-lift); overflow: hidden; }
.palette-panel input { width: 100%; border: 0; outline: none; background: transparent; font: 500 16px var(--font-body); color: var(--ink); padding: 18px 20px; border-bottom: 1px solid var(--line); }
.palette-results { max-height: 320px; overflow-y: auto; padding: 8px; }
.palette-results a { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; padding: 11px 14px; border-radius: 10px; color: var(--ink); }
.palette-results a.sel, .palette-results a:hover { background: rgba(14,139,168,.09); }
.pr-name { font-weight: 600; font-size: 14px; }
.pr-desc { font-size: 12px; color: var(--faint); }
.palette-empty { padding: 20px; font-size: 14px; color: var(--muted); }
.palette-foot { display: flex; gap: 16px; padding: 10px 16px; border-top: 1px solid var(--line); font-family: var(--font-mono); font-size: 10.5px; color: var(--faint); }

/* ---------- auth sheet ---------- */
.auth-sheet { position: fixed; inset: 0; z-index: 95; background: rgba(var(--ink-rgb),.4); backdrop-filter: blur(8px); display: grid; place-items: end center; }
.auth-sheet[hidden] { display: none; }
@media (min-width: 700px) { .auth-sheet { place-items: center; } }
.auth-panel {
  position: relative;
  width: min(440px, 100vw);
  background: var(--glass-solid); border: 1px solid var(--line);
  border-radius: 26px 26px 0 0; box-shadow: var(--shadow-lift);
  padding: 30px 26px calc(26px + env(safe-area-inset-bottom, 0px));
  text-align: center;
  animation: sheetIn .45s var(--ease-master) both;
}
@media (min-width: 700px) { .auth-panel { border-radius: 26px; } }
@keyframes sheetIn { from { opacity: 0; transform: translateY(40px); } }
.auth-x { position: absolute; top: 14px; right: 16px; border: 0; background: none; color: var(--faint); font-size: 15px; cursor: pointer; padding: 6px; }
.auth-drop { width: 52px; height: 52px; border-radius: 16px; background: var(--deep); display: grid; place-items: center; margin: 0 auto 14px; }
.auth-drop svg { width: 26px; height: 26px; stroke: var(--ice); fill: none; stroke-width: 1.7; }
.auth-panel h2 { font-family: var(--font-display); font-weight: 700; letter-spacing: -.02em; font-size: 22px; margin: 0 0 6px; }
.auth-sub { font-size: 14px; color: var(--muted); margin: 0 0 18px; }
.auth-btns { display: grid; gap: 9px; }
.auth-btn {
  display: flex; align-items: center; justify-content: center; gap: 9px;
  width: 100%; padding: 13px 18px; border-radius: 999px; cursor: pointer;
  border: 1.5px solid var(--line-strong); background: #fff;
  font: 600 14.5px var(--font-body); color: var(--ink);
  transition: border-color .15s, transform .12s;
}
.auth-btn:hover { border-color: var(--ink); }
.auth-btn:active { transform: scale(.985); }
.auth-btn .a-logo, .a-logo { width: 18px; height: 18px; flex: none; }
.auth-phone { display: grid; gap: 9px; }
.auth-phone input {
  width: 100%; text-align: center; font: 600 16px var(--font-body); color: var(--ink);
  background: #fff; border: 1.5px solid var(--line-strong); border-radius: 999px;
  padding: 13px 18px; outline: none; letter-spacing: .02em;
}
.auth-phone input:focus { border-color: var(--aqua); box-shadow: 0 0 0 3px rgba(0,113,227,.15); }
.auth-primary { background: var(--aqua); color: #fff; border-color: transparent; }
.auth-primary:hover { background: var(--aqua-ink); border-color: transparent; }
.auth-or { font-family: var(--font-mono); font-size: 10px; letter-spacing: .16em; text-transform: uppercase; color: var(--faint); margin: 2px 0; }
.auth-ghost { background: transparent; border-style: dashed; color: var(--muted); }
.auth-note { font-size: 12.5px; color: var(--aqua-ink); min-height: 0; margin: 12px 0 0; }
.auth-note b { color: var(--ink); }
.auth-fine { font-size: 11px; color: var(--faint); margin: 14px 0 0; line-height: 1.55; }

/* ---------- reveal ---------- */
.reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } }

/* ---------- footer ---------- */
.microline { display: block; font-family: var(--font-mono); font-size: 11px; color: var(--faint); border-top: 1px solid var(--line); margin-top: clamp(40px, 6vw, 72px); padding: 18px 0 8px; line-height: 1.8; }
.microline a { color: var(--muted); }

.noscript { max-width: 640px; margin: 60px auto; padding: 0 24px; font-family: var(--font-body); }

/* proposed-terms tag */
.proposed { display: inline-block; font-family: var(--font-mono); font-size: 9.5px; letter-spacing: .1em; text-transform: uppercase; color: #B4832B; border: 1px solid rgba(180,131,43,.35); border-radius: 6px; padding: 2px 7px; vertical-align: middle; margin-left: 8px; }

/* ---------- top-bar app tabs (moved out of the dock) ---------- */
.top-tabs { flex: none; gap: 0; padding: 0; margin-right: 2px; overflow: visible; }
.top-tabs a { min-width: 46px; padding: 4px 7px 3px; font-size: 8.5px; gap: 2px; border-radius: 11px; }
.top-tabs a svg.digi-ico { width: 19px; height: 19px; }
@media (max-width: 700px) { .top-tabs a span { display: none; } .top-tabs a { min-width: 36px; padding: 6px; } }

/* ---------- Airbnb-style command pill ---------- */
.cmd-pill {
  position: relative; flex: none;
  display: flex; align-items: center;
  background: #fff; border: 1px solid var(--line-strong); border-radius: 999px;
  box-shadow: 0 1px 2px rgba(var(--shade-rgb),.06), 0 6px 20px -8px rgba(var(--shade-rgb),.18);
  padding: 4px 4px 4px 6px;
  transition: box-shadow .2s;
}
.cmd-pill:hover, .cmd-pill.cp-open { box-shadow: 0 2px 4px rgba(var(--shade-rgb),.08), 0 10px 30px -8px rgba(var(--shade-rgb),.26); }
.cp-seg {
  border: 0; background: none; cursor: pointer; text-align: left;
  display: flex; flex-direction: column; gap: 0;
  padding: 5px 16px; border-radius: 999px; min-width: 96px;
}
.cp-seg:hover { background: rgba(var(--ink-rgb),.05); }
.cp-k { font-family: var(--font-mono); font-size: 8.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--faint); }
.cp-v { font: 600 12.5px var(--font-body); color: var(--ink); white-space: nowrap; }
.cp-div { width: 1px; height: 24px; background: var(--line); flex: none; }
.cp-go {
  width: 34px; height: 34px; border-radius: 50%; border: 0; cursor: pointer; flex: none;
  background: var(--aqua); color: #fff; display: grid; place-items: center; margin-left: 6px;
  transition: background .2s, transform .15s;
}
.cp-go:hover { background: var(--aqua-ink); }
.cp-go:active { transform: scale(.94); }
.cp-go svg { width: 15px; height: 15px; }
.cp-pop {
  position: absolute; top: calc(100% + 8px); left: 0; z-index: 60;
  width: min(320px, 84vw); max-height: 300px; overflow-y: auto;
  background: var(--glass-solid); border: 1px solid var(--line); border-radius: 18px;
  box-shadow: var(--shadow-lift); padding: 10px;
  backdrop-filter: blur(16px);
}
.cp-pop input {
  width: 100%; border: 1.5px solid var(--line-strong); border-radius: 12px; outline: none;
  font: 500 13.5px var(--font-body); color: var(--ink); background: #fff;
  padding: 10px 12px; margin-bottom: 8px;
}
.cp-pop input:focus { border-color: var(--aqua); }
.cp-opts { display: flex; flex-direction: column; gap: 2px; }
.cp-opts button {
  border: 0; background: none; cursor: pointer; text-align: left;
  font: 500 13px var(--font-body); color: var(--ink);
  padding: 9px 10px; border-radius: 10px;
}
.cp-opts button:hover { background: rgba(var(--ink-rgb),.05); }
.cp-opts button.on { background: rgba(14,156,201,.1); color: var(--aqua-ink); font-weight: 600; }
@media (max-width: 1080px) { .cmd-pill { display: none; } } /* the map pill carries location on small screens */

/* ---------- in-app form sheet (forms never leave the app) ---------- */
.form-sheet { position: fixed; inset: 0; z-index: 96; background: rgba(var(--ink-rgb),.4); backdrop-filter: blur(8px); display: grid; place-items: center; }
.fs-panel {
  width: min(560px, calc(100vw - 24px)); height: min(78dvh, 720px);
  background: var(--porcelain); border: 1px solid var(--line); border-radius: 22px;
  box-shadow: var(--shadow-lift); overflow: hidden; display: flex; flex-direction: column;
  animation: sheetIn .45s var(--ease-master) both;
}
.fs-bar { flex: none; display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-bottom: 1px solid var(--line); background: var(--glass-solid); }
.fs-back { border: 0; background: none; cursor: pointer; font: 600 12.5px var(--font-body); color: var(--aqua-ink); padding: 4px 6px; white-space: nowrap; }
.fs-t { flex: 1; text-align: center; font: 600 13px var(--font-body); color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fs-ext { font-size: 14px; color: var(--faint); padding: 2px 6px; }
.fs-panel iframe { flex: 1; border: 0; width: 100%; background: #fff; }

/* ---------- pages open OVER the OS (never leave the interface) ---------- */
body.page-over #view {
  position: fixed; inset: 54px 0 0 0; z-index: 45;
  overflow-y: auto; overscroll-behavior: contain;
  background: rgba(var(--ink-rgb),.30);
  backdrop-filter: blur(9px) saturate(1.1); -webkit-backdrop-filter: blur(9px) saturate(1.1);
  cursor: zoom-out;
  animation: pageOverIn .4s var(--ease-master) both;
}
@keyframes pageOverIn { from { opacity: 0; } }
body.page-over #view > .wrap {
  cursor: auto;
  background: var(--porcelain);
  border: 1px solid rgba(var(--surf-rgb),.7); border-radius: 26px;
  box-shadow: var(--shadow-lift);
  max-width: 1020px; margin: 20px auto calc(var(--dock-h) + 40px);
  padding-top: 8px; padding-bottom: 30px;
  animation: sheetIn .5s var(--ease-master) both;
  min-height: 60dvh;
}
@media (max-width: 720px) { body.page-over #view > .wrap { margin: 10px 8px calc(var(--dock-h) + 30px); border-radius: 20px; } }

/* ---------- checkout expansion + real payment marks ---------- */
.map-cart.ck-open { width: min(390px, calc(100% - 24px)); max-height: calc(100% - 24px); overflow-y: auto; scrollbar-width: thin; }
.ck-fields { display: grid; gap: 7px; }
.ck-f {
  width: 100%; font: 500 13px var(--font-body); color: var(--ink);
  background: #fff; border: 1.5px solid var(--line-strong); border-radius: 11px;
  padding: 10px 12px; outline: none;
}
.ck-f:focus { border-color: var(--aqua); box-shadow: 0 0 0 3px rgba(14,156,201,.12); }
.pay-marks { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 10px; flex-wrap: wrap; }
.pm-svg { width: 34px; height: 21px; display: block; }
.pm-ap { font: 600 12px -apple-system, 'Instrument Sans', sans-serif; border: 1px solid rgba(var(--ink-rgb),.14); background: #fff; border-radius: 4px; padding: 1px 7px; color: #000; }
.pm-soon { font: 500 9px var(--font-mono); letter-spacing: .05em; color: var(--faint); }

/* ---------- the bar owns its bottom strip ---------- */
body.cockpit-mode #siteScroll { padding-bottom: 0; }
/* chat open → the map CTA tucks right so "Bring me water" stays reachable */
body:has(.dock.chat-open) .nm-cta { left: auto; right: 12px; max-width: 300px; }
body:has(.dock.chat-open) .nm-cta #nmLabel { display: none; }
/* the open chat still clears the components above it as it rises */
.dock.chat-open { box-shadow: inset 0 1px 0 var(--gloss), 0 -8px 50px -12px rgba(var(--shade-rgb),.35), 0 14px 44px -10px rgba(var(--shade-rgb),.35); }
@media (max-width: 980px) {
  .mkt { height: auto; } /* mobile stacks; the bar floats as before */
  .mkt-left { padding-bottom: calc(var(--dock-h) + 40px); }
}

/* ---------- the pins: grabbable you + spring fountain station ---------- */
.you-pin { cursor: grab; }
.you-pin:active { cursor: grabbing; }
.yp-dot { position: absolute; inset: 4px; border-radius: 50%; background: var(--aqua); border: 2.5px solid #fff; box-shadow: 0 2px 8px rgba(11,127,165,.45); }
.yp-ring { position: absolute; inset: -6px; border-radius: 50%; border: 2px solid rgba(14,156,201,.5); animation: ypPulse 1.8s ease-out infinite; }
@keyframes ypPulse { from { transform: scale(.6); opacity: 1; } to { transform: scale(1.5); opacity: 0; } }
.st-pin img { width: 44px; height: 44px; object-fit: contain; filter: drop-shadow(0 3px 6px rgba(11,127,165,.35)); animation: geoBob 2.6s ease-in-out infinite; }
.st-ring { position: absolute; left: 50%; top: 50%; width: 40px; height: 40px; margin: -20px 0 0 -20px; border-radius: 50%; border: 2px solid rgba(14,156,201,.45); animation: ypPulse 2.2s ease-out infinite; }
.ck-dist {
  display: flex; align-items: center; gap: 6px;
  font-size: 11.5px; color: var(--muted); line-height: 1.35;
  background: rgba(14,156,201,.07); border: 1px solid rgba(14,156,201,.22);
  border-radius: 10px; padding: 6px 9px; margin-bottom: 8px;
}
.ck-dist b { color: var(--ink); font-weight: 600; }

/* ---------- border beam — the orbiting light on the command input ----------
   Idle: a slow, calm orbit. Focused: the beam quickens. (Ref: border-beam) */
@property --bb { syntax: '<angle>'; initial-value: 0deg; inherits: false; }
.beam-wrap { position: relative; flex: 1; border-radius: 19px; display: flex; }
.beam-wrap input { width: 100%; }
.beam-wrap::before {
  content: ''; position: absolute; inset: -1.5px; border-radius: 20px; padding: 1.5px;
  background: conic-gradient(from var(--bb),
    transparent 0deg 270deg,
    rgba(14,156,201,.0) 285deg,
    rgba(14,156,201,.85) 322deg,
    rgba(127,217,242,.95) 342deg,
    transparent 360deg);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  animation: bbSpin 7.5s linear infinite;
  pointer-events: none;
}
.beam-wrap:focus-within::before { animation-duration: 2.4s; }
@keyframes bbSpin { to { --bb: 360deg; } }
@media (prefers-reduced-motion: reduce) { .beam-wrap::before { animation: none; opacity: .5; } }

/* ---------- crisp text tabs — the Apple pass ---------- */
.top-tabs a { min-width: 0; padding: 7px 12px; font: 600 12.5px var(--font-body); letter-spacing: -.01em; gap: 0; border-radius: 999px; flex-direction: row; color: rgba(var(--ink-rgb),.62); }
.top-tabs a:hover { background: rgba(var(--ink-rgb),.05); color: var(--ink); }
.top-tabs a[aria-current="page"] { background: var(--ink); color: var(--porcelain); }
@media (max-width: 700px) { .top-tabs a span { display: inline; } .top-tabs a { padding: 6px 9px; font-size: 11.5px; } }

/* ---------- nanoglass components: real cards, ample padding ---------- */
.mkt-fixed {
  border: 1px solid var(--line); border-radius: var(--r);
  background: var(--glass); backdrop-filter: blur(18px) saturate(1.4); -webkit-backdrop-filter: blur(18px) saturate(1.4);
  box-shadow: var(--shadow);
  padding: 14px 16px 16px;
}
.mkt-fixed::after { /* the fade: content vanishes BEFORE it touches */
  content: ''; position: absolute; left: 0; right: 0; top: 100%; height: 34px; pointer-events: none;
  background: linear-gradient(var(--porcelain) 12%, transparent);
}
.mkt-fixed { position: sticky; top: 0; z-index: 6; }
.gal-grid {
  background: var(--glass); border: 1px solid var(--line); border-radius: var(--r);
  padding: 14px; box-shadow: var(--shadow);
  backdrop-filter: blur(18px) saturate(1.4); -webkit-backdrop-filter: blur(18px) saturate(1.4);
}
.tile-carousel { padding: 4px 2px 8px; }

/* ---------- device theme: light / dark / auto ---------- */
html[data-theme="dark"] {
  color-scheme: dark;
  --ink-rgb: 239, 235, 226;   /* ink overlays invert to light */
  --surf-rgb: 44, 43, 39;     /* glass surfaces invert to charcoal */
  --shade-rgb: 0, 0, 0;       /* shadows go true-black in the dark */
  --gloss: rgb(255 255 255 / .05);
  --porcelain: #121210; --porcelain-2: #1A1917;
  --ink: #EFEBE2; --deep: #2A2A27; --deep-2: #35342F;
  --tan: #1E1D1A; --tan-2: #242320;
  --line: rgba(239,235,226,.09); --line-strong: rgba(239,235,226,.18);
  --muted: rgba(239,235,226,.6); --faint: rgba(239,235,226,.38);
  --glass: rgba(30,29,26,.6); --glass-solid: rgba(26,25,23,.94);
  --shadow: 0 1px 2px rgba(0,0,0,.3), 0 12px 40px -12px rgba(0,0,0,.5);
  --shadow-lift: 0 2px 6px rgba(0,0,0,.35), 0 24px 60px -16px rgba(0,0,0,.6);
}
html[data-theme="dark"] body { background: var(--porcelain); color: var(--ink); }
html[data-theme="dark"] .topbar { background: linear-gradient(rgba(18,18,16,.9), rgba(18,18,16,.7)); }
html[data-theme="dark"] .dock { background: rgba(26,25,22,.9); border-color: rgba(239,235,226,.1); }
html[data-theme="dark"] .dock-input input, html[data-theme="dark"] .ck-f, html[data-theme="dark"] .cp-pop input { background: #1E1D1A; color: var(--ink); border-color: rgba(239,235,226,.16); }
html[data-theme="dark"] .cmd-pill, html[data-theme="dark"] .ck-mode button, html[data-theme="dark"] .ck-chip, html[data-theme="dark"] .pt, html[data-theme="dark"] .map-cart, html[data-theme="dark"] .map-search, html[data-theme="dark"] .ck-card, html[data-theme="dark"] .geo-panel, html[data-theme="dark"] .auth-panel, html[data-theme="dark"] .store-panel, html[data-theme="dark"] .auth-btn, html[data-theme="dark"] .ck-add, html[data-theme="dark"] .auth-phone input { background: #201F1C; color: var(--ink); border-color: rgba(239,235,226,.14); }
html[data-theme="dark"] .msg.bot { background: #232220; color: var(--ink); }
html[data-theme="dark"] .leaflet-tile { filter: saturate(.7) brightness(.82) contrast(1.05); }
.theme-btn { cursor: pointer; border: 1px solid var(--line); border-radius: 8px; background: var(--glass); color: var(--muted); font-size: 13px; padding: 5px 9px; line-height: 1; }
.theme-btn:hover { border-color: var(--line-strong); color: var(--ink); }

/* ---------- the Fountain — every distributor is one. Find a fountain near you. */
.st-pin img {
  width: 68px; height: 68px; object-fit: contain;
  mix-blend-mode: multiply; /* melts the render's backdrop into the map */
  filter: drop-shadow(0 4px 8px rgba(11,127,165,.3));
  animation: geoBob 2.6s ease-in-out infinite;
  transition: transform .2s var(--ease-master);
  transform-origin: 50% 90%;
}
.st-pin:hover img { animation: ftWiggle .55s ease-in-out infinite; }
@keyframes ftWiggle {
  0%, 100% { transform: rotate(0deg) scale(1.12); }
  25% { transform: rotate(-6deg) scale(1.12); }
  75% { transform: rotate(6deg) scale(1.12); }
}
html[data-theme="dark"] .st-pin img { mix-blend-mode: screen; }
@media (prefers-reduced-motion: reduce) { .st-pin img, .st-pin:hover img { animation: none; } }

/* ---------- panel kickers + fountain name chip ---------- */
.panel-k { font: 500 9.5px var(--font-mono); letter-spacing: .16em; text-transform: uppercase; color: var(--faint); margin-bottom: 8px; }
.mkt-map::after { content: 'Explore'; position: absolute; top: 10px; right: 12px; z-index: 500; font: 500 9.5px var(--font-mono); letter-spacing: .16em; text-transform: uppercase; color: var(--faint); background: var(--glass); border: 1px solid var(--line); border-radius: 999px; padding: 4px 10px; pointer-events: none; }
.mkt-map { position: relative; }
.ft-chip { background: var(--glass-solid); border: 1px solid var(--line-strong); border-radius: 999px; padding: 4px 12px; font: 600 12px var(--font-body); color: var(--ink); box-shadow: var(--shadow); cursor: pointer; }
.ft-chip::before { display: none; }


/* ============================================================
   REFINEMENT LAYER — 2026-08-04
   (1) dark mode, actually dark   (2) the living brand mark
   (3) the concierge reads as alive: visible handle, header,
       and suggestions so you never stare at a blank room.
   Appended last on purpose: the cascade is the API.
   ============================================================ */

/* ---------- (1) DARK MODE: the page itself ----------
   The bug: #waterLoop is a fixed, full-viewport LIGHT svg at z-0.
   body DID go dark underneath — nobody could tell, because the
   water was painting over the entire screen. Darken the water. */
html { background: var(--porcelain); }
html[data-theme="dark"] body,
html[data-theme="dark"] #siteScroll { background: var(--porcelain); }
html[data-theme="dark"] #waterLoop { filter: brightness(.17) saturate(1.7) contrast(1.06); }
html[data-theme="dark"] #waterLoop video { filter: brightness(.42) saturate(.9); }

/* the light surfaces the token sweep couldn't reach (hex, gradients) */
html[data-theme="dark"] .cp-pop,
html[data-theme="dark"] .palette-panel,
html[data-theme="dark"] .fwd-card,
html[data-theme="dark"] .sp-back,
html[data-theme="dark"] .pm-ap,
html[data-theme="dark"] .cov input,
html[data-theme="dark"] .btn-ghost,
html[data-theme="dark"] .gal-grid,
html[data-theme="dark"] .mkt-fixed { background: var(--porcelain-2); color: var(--ink); border-color: var(--line); }
html[data-theme="dark"] .pt-img,
html[data-theme="dark"] .cp-img,
html[data-theme="dark"] .gal.gal-soft { background: linear-gradient(150deg, #16262C, #101C21); }
html[data-theme="dark"] .node-map svg,
html[data-theme="dark"] .ck-center svg { background: linear-gradient(160deg, #131C1B, #101614); }
html[data-theme="dark"] .fs-panel iframe { background: var(--porcelain-2); }
html[data-theme="dark"] .yp-dot { border-color: #14140F; }

/* the map search pill goes dark with everything else */
html[data-theme="dark"] .map-search { background: rgba(32,31,28,.93); border-color: rgba(239,235,226,.15); }
html[data-theme="dark"] .map-search input { color: var(--ink); background: transparent; }
html[data-theme="dark"] .map-search input::placeholder { color: rgba(239,235,226,.42); }

/* every grayish text goes light in the dark — the UNSELECTED tabs were the worst offender */
html[data-theme="dark"] .top-tabs a { color: rgba(239,235,226,.72); }
html[data-theme="dark"] .top-tabs a:hover { color: #FFF; background: rgba(239,235,226,.09); }
html[data-theme="dark"] .top-tabs a[aria-current="page"] { background: var(--ink); color: #16150F; }
html[data-theme="dark"] .dock-icons a { color: rgba(239,235,226,.7); }
html[data-theme="dark"] .cp-k, html[data-theme="dark"] .kicker,
html[data-theme="dark"] .microline, html[data-theme="dark"] .chat-note { color: rgba(239,235,226,.55); }
html[data-theme="dark"] .cp-v, html[data-theme="dark"] .msg.bot b { color: var(--ink); }
html[data-theme="dark"] .theme-btn, html[data-theme="dark"] .k-hint { color: rgba(239,235,226,.66); }
html[data-theme="dark"] .msg.bot { box-shadow: 0 1px 2px rgba(0,0,0,.4); }
html[data-theme="dark"] .chat-chip { background: rgba(14,156,201,.13); color: #7FD9F2; border-color: rgba(127,217,242,.34); }
html[data-theme="dark"] .chat-chip:hover { background: rgba(14,156,201,.26); color: #BFEEFB; }
html[data-theme="dark"] .tdot { background: rgba(239,235,226,.5); }
html[data-theme="dark"] .ora-ava { background: rgba(239,235,226,.08); }

/* ---------- (2) THE LIVING MARK ----------
   A drop that actually holds water: the level breathes, a wave
   crosses it, one specular glint travels, a ring leaves at the peak.
   6.4s cycle. Nothing bounces, nothing spins. */
.brand .drop { position: relative; overflow: visible; }
.brand .drop svg.brand-mark { width: 20px; height: 20px; display: block; overflow: visible; stroke: none; stroke-width: 0; fill: none; }
.bm-fill { animation: bmLevel 6.4s cubic-bezier(.45,0,.55,1) infinite; }
.bm-wave { animation: bmWave 3.6s linear infinite; }
.bm-glint { animation: bmGlint 6.4s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
.brand .drop::after { /* the ring that leaves when the level peaks */
  content: ''; position: absolute; inset: -1px; border-radius: 11px;
  border: 1.5px solid rgba(127,217,242,.55); opacity: 0; pointer-events: none;
  animation: bmRing 6.4s ease-out infinite;
}
@keyframes bmLevel { 0%, 100% { transform: translateY(1.7px); } 50% { transform: translateY(-1.1px); } }
@keyframes bmWave  { to { transform: translateX(-12px); } }
@keyframes bmGlint { 0%, 100% { opacity: .3; transform: translateY(0) scale(1); } 46% { opacity: .88; transform: translateY(-.6px) scale(1.09); } }
@keyframes bmRing  { 0%, 62% { opacity: 0; transform: scale(.86); } 72% { opacity: .5; } 100% { opacity: 0; transform: scale(1.55); } }
.brand:hover .bm-fill { animation-duration: 2.6s; }
.brand:hover .bm-wave { animation-duration: 1.5s; }
@media (prefers-reduced-motion: reduce) {
  .bm-fill, .bm-wave, .bm-glint, .brand .drop::after { animation: none; }
}

/* ---------- (3) THE CONCIERGE, ALIVE ---------- */
/* a handle you can actually see and hit */
.dock-handle {
  width: 62px; height: 26px; margin-top: 6px; border-radius: 999px;
  background: rgba(var(--ink-rgb), .07);
  color: rgba(var(--ink-rgb), .62);
  transition: background .2s, color .2s, width .3s var(--ease-master);
}
.dock-handle:hover { background: rgba(14,156,201,.16); color: var(--aqua-ink); width: 76px; }
.dock-handle svg { width: 20px; height: 20px; stroke-width: 2.4; }
html[data-theme="dark"] .dock-handle { background: rgba(239,235,226,.1); color: rgba(239,235,226,.74); }
html[data-theme="dark"] .dock-handle:hover { background: rgba(14,156,201,.28); color: #7FD9F2; }

/* the header: who you're talking to, and that it's listening */
.chat-head {
  display: none; flex: none; align-items: center; gap: 10px;
  padding: 10px 54px 9px 16px; border-bottom: 1px solid var(--line);
}
.dock.chat-open .chat-head { display: flex; }
.chat-head .ora-ava { width: 30px; height: 30px; margin: 0; }
.ch-name { font: 600 13px var(--font-body); color: var(--ink); line-height: 1.2; }
.ch-state {
  display: flex; align-items: center; gap: 5px;
  font-family: var(--font-mono); font-size: 9.5px; letter-spacing: .07em;
  text-transform: uppercase; color: var(--muted);
}
.ch-live { width: 6px; height: 6px; border-radius: 50%; background: var(--mint); flex: none; animation: chLive 2.4s ease-in-out infinite; }
.ch-state.thinking .ch-live { background: var(--aqua); animation-duration: .9s; }
@keyframes chLive { 0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(78,143,85,.5); } 50% { opacity: .6; box-shadow: 0 0 0 4px rgba(78,143,85,0); } }

/* the starter: the chat is never a blank room */
.chat-starter { display: flex; flex-direction: column; gap: 10px; padding: 2px 0; }
.cs-line { font: 500 13.5px var(--font-body); color: var(--muted); line-height: 1.5; }
.cs-line b { color: var(--ink); font-weight: 600; }

/* always-there suggestion rail, just above the input */
.chat-sugg {
  display: none; flex: none; gap: 6px; padding: 2px 14px 8px;
  overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.chat-sugg::-webkit-scrollbar { display: none; }
.dock.chat-open .chat-sugg { display: flex; }
.sg {
  flex: none; cursor: pointer; white-space: nowrap;
  border: 1px solid var(--line-strong); border-radius: 999px;
  background: rgba(var(--surf-rgb), .6); color: var(--muted);
  font: 500 11.5px var(--font-body); padding: 6px 12px;
  transition: background .16s, color .16s, border-color .16s, transform .16s;
}
.sg:hover { background: rgba(14,156,201,.12); color: var(--aqua-ink); border-color: rgba(14,156,201,.45); transform: translateY(-1px); }
html[data-theme="dark"] .sg { background: rgba(239,235,226,.06); color: rgba(239,235,226,.72); border-color: rgba(239,235,226,.16); }
html[data-theme="dark"] .sg:hover { background: rgba(14,156,201,.24); color: #7FD9F2; border-color: rgba(127,217,242,.4); }


/* ============================================================
   REFINEMENT LAYER II — 2026-08-04 evening
   The shell is permanent. The rail is a slot. The map is a map.
   ============================================================ */

/* ---------- the nanoglass action rail, sharing the handle's row ---------- */
.dock-rail { display: flex; align-items: center; gap: 6px; flex: none; padding: 7px 10px 3px; }
.rail-acts { flex: 1; display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.rail-acts::-webkit-scrollbar { display: none; }
.dock-rail .dock-handle { margin-top: 0; align-self: center; width: 46px; height: 28px; }
.dock-rail .dock-handle:hover { width: 54px; }
.na {
  flex: none; cursor: pointer; white-space: nowrap; border-radius: 999px;
  background: rgba(var(--surf-rgb), .40);
  backdrop-filter: blur(16px) saturate(1.8);
  -webkit-backdrop-filter: blur(16px) saturate(1.8);
  border: 1px solid var(--gloss);
  box-shadow: inset 0 1px 0 var(--gloss), 0 1px 2px rgba(var(--shade-rgb), .06);
  color: var(--ink); font: 600 11.5px var(--font-body); letter-spacing: -.005em;
  padding: 7px 13px;
  transition: background .18s, transform .18s, border-color .18s, color .18s;
}
.na:hover { background: rgba(var(--surf-rgb), .74); transform: translateY(-1px); }
.na:active { transform: translateY(0) scale(.97); }
.na.on { background: rgba(14,156,201,.15); border-color: rgba(14,156,201,.42); color: var(--aqua-ink); }
.na-cta { background: rgba(14,156,201,.92); color: #fff; border-color: rgba(14,156,201,.5); }
.na-cta:hover { background: var(--aqua); color: #fff; }
html[data-theme="dark"] .na { background: rgba(239,235,226,.07); border-color: rgba(239,235,226,.14); color: rgba(239,235,226,.88); box-shadow: inset 0 1px 0 rgb(255 255 255 / .06); }
html[data-theme="dark"] .na:hover { background: rgba(239,235,226,.14); color: #FFF; }
html[data-theme="dark"] .na.on { background: rgba(14,156,201,.26); border-color: rgba(127,217,242,.4); color: #7FD9F2; }
html[data-theme="dark"] .na-cta { background: rgba(14,156,201,.9); color: #fff; border-color: rgba(127,217,242,.45); }
@media (max-width: 700px) { .na { padding: 6px 11px; font-size: 11px; } }

/* ---------- the fountain is an artifact, not a card ----------
   The drop-shadow was casting the PNG's whole rectangle, which read as a
   white tile with an edge. No shadow, no ring, no container. */
.st-pin, .leaflet-marker-icon.st-pin {
  background: none !important; border: 0 !important; box-shadow: none !important;
}
.st-pin img { filter: none; }
.st-ring { display: none; }
html[data-theme="dark"] .st-pin img { mix-blend-mode: multiply; filter: brightness(1.35) saturate(1.05); }

/* ---------- the node label: real business name + what it actually offers ---------- */
.leaflet-tooltip.ft-tip, .leaflet-tooltip.ft-chip {
  background: var(--glass-solid); color: var(--ink);
  border: 1px solid var(--line); border-radius: 13px;
  box-shadow: var(--shadow); padding: 8px 11px;
  font-family: var(--font-body); white-space: normal; max-width: 230px;
}
.leaflet-tooltip.ft-tip::before, .leaflet-tooltip.ft-chip::before { display: none; }
.ft-name { display: block; font: 600 13px var(--font-body); letter-spacing: -.01em; }
.cap-row { display: inline-flex; flex-wrap: wrap; gap: 4px; margin-top: 5px; }
.cap {
  font-family: var(--font-mono); font-size: 8.5px; font-weight: 500;
  letter-spacing: .09em; text-transform: uppercase; line-height: 1.5;
  padding: 2px 6px; border-radius: 6px; border: 1px solid;
}
.cap[data-kind="water"]       { color: var(--aqua-ink); border-color: rgba(14,156,201,.34); background: rgba(14,156,201,.08); }
.cap[data-kind="cadence"]     { color: #4E8F55;         border-color: rgba(78,143,85,.34);  background: rgba(78,143,85,.08); }
.cap[data-kind="fulfillment"] { color: #B4832B;         border-color: rgba(180,131,43,.34); background: rgba(180,131,43,.08); }
.cap[data-kind="goods"]       { color: var(--muted);    border-color: var(--line-strong);   background: rgba(var(--ink-rgb), .04); }
.cap-more { color: var(--faint); border-color: var(--line-strong); }
html[data-theme="dark"] .cap[data-kind="water"]       { color: #7FD9F2; }
html[data-theme="dark"] .cap[data-kind="cadence"]     { color: #9BD1A1; }
html[data-theme="dark"] .cap[data-kind="fulfillment"] { color: #E3BE72; }

/* ---------- the rail as a page slot ----------
   Route components render into the SAME grid column the products use.
   Nothing about the shell moves. */
.mkt-fixed { position: static; }
.mkt-fixed::after { display: none; }
.rail-page { padding-right: 2px; }
.rail-page .wrap { max-width: none; padding: 0 2px; }
.rail-page .p-head { padding-top: 4px; max-width: none; }
.rail-page .display { font-size: clamp(21px, 2.1vw, 27px); line-height: 1.14; }
.rail-page .lede { font-size: 13.5px; }
.rail-page .h { font-size: 16px; }
.rail-page .section { padding-top: 14px; }
.rail-page .fwd-product-grid,
.rail-page .gal-grid,
.rail-page .sp-grid { grid-template-columns: 1fr 1fr; }
.rail-page .p-cta { flex-wrap: wrap; }
.rail-page .microline { font-size: 10px; line-height: 1.55; }

/* rail pages need breathing room the full-width layout got from .wrap */
.rail-page { padding: 2px 14px 20px 4px; }
.rail-page .wrap { padding: 0; }
.rail-page .fwd-card-title { font-size: 13px; line-height: 1.3; }
.rail-page .fwd-card-price { font-size: 11.5px; }
.rail-page .kicker { margin-bottom: 2px; }

/* page grids reflow to the rail's width instead of forcing two columns */
.rail-page [class*="grid"] { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)) !important; }
.rail-page .gal { min-height: 132px; }

/* the chevron is the only close affordance — the ✕ is gone */
.chat-x, .dock.chat-open .chat-x { display: none !important; }
.chat-head { padding-right: 16px; }


/* ============================================================
   CONTAINMENT LAYER — 2026-08-04 audit
   Nothing crosses the viewport edge. Ever. At any width.
   The bug class this kills: a grid/flex item's DEFAULT min-width
   is `auto`, meaning it refuses to shrink below its content. One
   wide child (the 8-tile product carousel) was therefore forcing
   the marketplace column to 1292px at EVERY width — pushing the
   cart, the "Check out" button and the whole checkout form off
   the right edge, silently, because .mkt-map clips instead of
   scrolling. min-width:0 is the fix, and it must be applied to
   every flex/grid child that holds variable-width content.
   ============================================================ */
.mkt, .mkt > *, .mkt-left, .mkt-map, .mkt-fixed, .mkt-head { min-width: 0; }
.tile-carousel { overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.tile-carousel::-webkit-scrollbar { display: none; }
.ck-chips, .ck-mode { flex-wrap: wrap; min-width: 0; }

/* the top bar: the brand holds, the tabs give, the controls never leave */
.topbar { min-width: 0; }
.brand { min-width: 0; flex: 0 1 auto; }
.brand > span { min-width: 0; overflow: hidden; }
.brand .b-name, .brand .b-sub { overflow: hidden; text-overflow: ellipsis; }
.sys { min-width: 0; flex: 0 1 auto; justify-content: flex-end; }
.top-tabs { min-width: 0; flex: 0 1 auto; overflow-x: auto; scrollbar-width: none; }
.top-tabs::-webkit-scrollbar { display: none; }
#accBtn, #paletteBtn, #themeBtn, #sndBtn { flex: none; }
@media (max-width: 900px) { .brand .b-sub { display: none; } }
@media (max-width: 620px) { .top-tabs { display: none; } } /* the palette owns nav on phones */

/* the map's search pill fits the map, not a fixed 420 */
.map-search { max-width: min(420px, calc(100% - 24px)); min-width: 0; flex-wrap: wrap; }
.map-search input { min-width: 0; }

/* the cart never hangs off its own container */
.map-cart { max-width: calc(100% - 24px); min-width: 0; }

/* the action rail scrolls, but Checkout is pinned and always reachable */
.dock, .dock-rail, .dock-chat, .dock-input { min-width: 0; }
.rail-acts { min-width: 0; }
.rail-cta { flex: none; }
.chat-sugg > * { flex: none; }
.dock-input input { min-width: 0; }

/* last-resort guard: no descendant of the shell may paint past the edge */
html, body { overflow-x: hidden; max-width: 100%; }

/* the "EXPLORE" chip was chip-shaped, chip-styled and did nothing */
.mkt-map::after { display: none; }

/* the consent modal outranks the command bar — it was inside #view's stacking
   context (below .dock), so the chat log was swallowing clicks aimed at it */
.geo-pop { position: fixed; inset: 0; z-index: 120; }
.geo-panel { position: relative; z-index: 121; }

/* honest payment state inside the checkout */
.pay-mount { margin-top: 4px; min-height: 44px; }
.pay-wait { font-size: 12px; color: var(--muted); padding: 10px 0 2px; }
.pay-wait.pay-down {
  color: var(--ink); background: rgba(180,131,43,.08);
  border: 1px solid rgba(180,131,43,.3); border-radius: 12px;
  padding: 10px 12px; font-size: 12.5px; line-height: 1.5;
}
.pay-wait.pay-down b { display: block; margin-bottom: 3px; }
.pay-wait a { color: var(--aqua-ink); font-weight: 600; }
