/* ═══════════════════════════════════════════════════════════════
   Honeydew · v2 — connector stems, Flow, feeds, Greenpages,
   community, account, dev bar, priority chain, Willow theme
   ═══════════════════════════════════════════════════════════════ */

/* ── glass connector stems bridging the gaps between rows ─────── */
.stem {
  position: absolute;
  top: -31px; left: 50%;
  width: 15px; height: 36px;
  transform: translateX(-50%);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(255, 244, 214, .55), var(--rim-mid) 45%, rgba(255, 250, 236, .95));
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, .65),
    inset 2px 0 3px rgba(255, 255, 255, .8),
    0 0 12px -2px var(--rim-glow);
  z-index: 0;
  pointer-events: none;
}
.stem::after { /* the bulge — matter moving down the chain */
  content: "";
  position: absolute; top: 34%; left: 50%;
  width: 23px; height: 23px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background:
    radial-gradient(circle at 34% 28%, rgba(255,255,255,.95), rgba(255,255,255,.2) 55%),
    linear-gradient(168deg, rgba(255, 249, 233, .95), rgba(248, 222, 168, .92));
  box-shadow:
    inset 0 -2px 4px rgba(218, 166, 78, .45),
    0 0 10px -1px var(--rim-glow);
  animation: stem-pulse 4.2s ease-in-out infinite;
  animation-delay: var(--chain-delay, 0s);
}
@keyframes stem-pulse {
  0%, 12%  { transform: translate(-50%, -110%) scale(.55); opacity: .0; }
  22%      { transform: translate(-50%, -75%) scale(.9); opacity: 1; }
  45%      { transform: translate(-50%, -40%) scale(1.06); }
  70%      { transform: translate(-50%, -8%) scale(.92); opacity: 1; }
  84%,100% { transform: translate(-50%, 30%) scale(.5); opacity: 0; }
}
body.reduced-motion .stem::after { animation: none; opacity: .8; transform: translate(-50%,-50%); }

/* mockup-style mini-card header: icon orb left, kicker right */
.mini-head { display: flex; align-items: center; justify-content: center; gap: 10px; }
.mini-head .mini-ico { margin: 0; }
.mini-head .kicker { white-space: nowrap; }

/* ── tabs & chips ─────────────────────────────────────────────── */
.tab-row { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 18px; }
.tab {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 8px 18px; border-radius: 999px;
  font-size: 12.5px; font-weight: 600;
  color: var(--card-ink, var(--ink));
  background: rgba(255, 255, 255, .35);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .6);
  transition: all .2s ease;
}
.tab svg { width: 14px; height: 14px; }
.tab:hover { background: rgba(255, 255, 255, .55); }
.tab.on {
  background: linear-gradient(160deg, rgba(255,255,255,.95), rgba(255,248,230,.85));
  color: var(--ink);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.9), 0 4px 12px -5px rgba(120,84,20,.4);
}
.chip {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 6px 13px; border-radius: 999px;
  font-size: 11.5px; font-weight: 600;
  color: var(--card-ink, var(--ink));
  background: rgba(255, 255, 255, .4);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .65);
  transition: all .2s ease;
  cursor: pointer;
}
.chip:hover { background: rgba(255,255,255,.6); }
.chip.on { background: linear-gradient(160deg, #8bcda3, #4a9a6e); color: #fff;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.45), 0 3px 8px -3px rgba(74,154,110,.7); }
.chip.mini { padding: 3px 9px; font-size: 10.5px; font-weight: 500; cursor: default; }
.chip[disabled] { opacity: .75; cursor: default; }
.chip-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 16px; }

/* ── the flow ─────────────────────────────────────────────────── */
.dewey-bar .glass-inner { display: flex; align-items: center; gap: 14px; padding: 16px 20px; }
.dewey-face {
  width: 46px; height: 46px; flex: none; border-radius: 50%;
  display: grid; place-items: center; color: #fff;
  background: linear-gradient(168deg, #86c9a0, #3f8f66);
  box-shadow: inset 0 2px 5px rgba(255,255,255,.55), inset 0 -4px 9px rgba(30,80,50,.35), 0 4px 12px -4px rgba(63,143,102,.6);
  animation: dewey-bob 3.4s ease-in-out infinite;
}
.dewey-face svg { width: 24px; height: 24px; }
.dewey-face.sm { width: 34px; height: 34px; }
.dewey-face.sm svg { width: 18px; height: 18px; }
@keyframes dewey-bob { 0%,100% { transform: translateY(0) rotate(-2deg); } 50% { transform: translateY(-3px) rotate(2deg); } }
body.reduced-motion .dewey-face { animation: none; }
.dewey-text { flex: 1; min-width: 0; }
.dewey-text strong { display: block; font-size: 13.5px; }
.dewey-text small { font-size: 12px; color: var(--card-ink-soft); }

.flow-add { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; }
.flow-add input, .flow-add select {
  border: 0; border-radius: 12px; padding: 9px 12px; font-size: 13px;
  background: rgba(255,255,255,.75);
  box-shadow: inset 0 0 0 1px rgba(201,173,114,.45);
  outline: none;
}
.flow-add input[name="title"] { flex: 1; min-width: 160px; }
.flow-add input:focus, .flow-add select:focus { box-shadow: inset 0 0 0 1.6px rgba(226,166,61,.8); }

.pill.pri-high { background: rgba(240, 150, 130, .5); }
.pill.pri-med { background: rgba(240, 196, 110, .45); }
.pill.pri-low { background: rgba(164, 197, 240, .4); }
.pill.alarm { background: rgba(240, 150, 130, .55); }
.done-label { font-size: 11px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase;
  color: var(--card-ink-soft, var(--ink-soft)); margin: 16px 2px 8px; }

.habit-strip { gap: 8px; flex-wrap: wrap; }
.habit-grid { align-items: stretch; }
.habit-card { position: relative; border-radius: 20px; padding: 18px 14px 16px; text-align: center;
  background: rgba(255,255,255,.55); box-shadow: inset 0 0 0 1.2px rgba(255,255,255,.85), 0 3px 10px -5px rgba(120,84,20,.3);
  display: flex; flex-direction: column; align-items: center; gap: 7px; }
.habit-card.done { opacity: .8; }
.habit-emoji { font-size: 30px; line-height: 1; }
.habit-card strong { font-size: 13.5px; }
.habit-card .streak { font-size: 12px; color: var(--card-ink-soft); font-weight: 600; }
.week-dots { display: flex; gap: 5px; margin: 2px 0 4px; }
.week-dots i { width: 9px; height: 9px; border-radius: 50%;
  background: rgba(120, 84, 20, .15); box-shadow: inset 0 0 0 1px rgba(120,84,20,.15); }
.week-dots i.on { background: linear-gradient(160deg, #8bcda3, #4a9a6e); box-shadow: 0 0 6px -1px rgba(74,154,110,.8); }
.habit-del { position: absolute; top: 8px; right: 8px; width: 24px; height: 24px; opacity: .5; }
.habit-del:hover { opacity: 1; }

/* dewey / willow toasts */
.toast.dewey { max-width: 380px; }
.toast.dewey .dewey-ico { background: linear-gradient(160deg, #86c9a0, #3f8f66); }
.toast.dewey.urgent { box-shadow: 0 0 0 1.5px rgba(255,255,255,.8), 0 0 18px 0 rgba(240, 150, 110, .8), 0 10px 26px -10px rgba(120,84,20,.5);
  animation: toast-in .4s cubic-bezier(.3,1.4,.6,1), toast-buzz .5s ease .4s 2; }
@keyframes toast-buzz { 0%,100% { transform: translateX(0); } 25% { transform: translateX(-3px); } 75% { transform: translateX(3px); } }

/* alarm takeover */
.alarm-veil { background: rgba(62, 40, 10, .5); }
.alarm-modal { animation: modal-in .38s cubic-bezier(.3,1.4,.6,1), alarm-shake 1.6s ease .5s infinite; }
@keyframes alarm-shake { 0%,100% { transform: rotate(0); } 4% { transform: rotate(-.8deg); } 8% { transform: rotate(.8deg); } 12% { transform: rotate(0); } }
.alarm-droplet { width: 74px; height: 74px; margin: 4px auto 0; border-radius: 50%;
  display: grid; place-items: center; color: #fff;
  background: linear-gradient(168deg, #f2b04c, #d98324);
  box-shadow: inset 0 2px 6px rgba(255,255,255,.5), inset 0 -5px 12px rgba(140,80,10,.4), 0 0 0 8px rgba(255, 244, 214, .55), 0 0 30px 2px rgba(240, 176, 76, .8);
  animation: alarm-pulse 1.1s ease-in-out infinite; }
.alarm-droplet svg { width: 36px; height: 36px; }
@keyframes alarm-pulse { 0%,100% { transform: scale(1); } 50% { transform: scale(1.1); } }
body.reduced-motion .alarm-modal, body.reduced-motion .alarm-droplet { animation: none; }

/* home flow strip */
.flow-strip .glass-inner { padding: 20px 24px; }
.flow-stats { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin-top: 12px; }
.flow-orb { display: flex; flex-direction: column; align-items: center; justify-content: center;
  width: 92px; height: 92px; border-radius: 50%; gap: 2px;
  background: radial-gradient(circle at 32% 26%, rgba(255,255,255,.8), rgba(255,255,255,.3));
  box-shadow: inset 0 0 0 1.6px rgba(255,255,255,.9), inset 0 -4px 9px rgba(120,84,20,.15), 0 5px 14px -5px rgba(120,84,20,.4);
  color: var(--card-ink); transition: transform .2s ease; }
.flow-orb:hover { transform: translateY(-2px) scale(1.03); }
.flow-orb b { font-size: 22px; font-weight: 600; }
.flow-orb small { font-size: 9.5px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; opacity: .8; }
.flow-quip { flex: 1; min-width: 180px; display: flex; align-items: center; gap: 10px;
  font-size: 13px; color: var(--card-ink-soft); }
.flow-strip.minimized .glass-inner { padding: 13px 22px; display: flex; align-items: center; gap: 14px; }
.flow-strip.minimized .kicker { margin: 0; }
.flow-strip.minimized .flow-min-note { flex: 1; font-size: 13px; color: var(--card-ink-soft); }

/* ── feeds ────────────────────────────────────────────────────── */
.swipe-zone { touch-action: pan-y; cursor: grab; }
.feed-story { text-align: center; padding: 18px 12px 4px; min-height: 120px; }
.feed-thumb { width: 84px; height: 84px; border-radius: 16px; object-fit: cover; margin: 0 auto 12px;
  box-shadow: 0 0 0 3px rgba(255,255,255,.8), 0 6px 14px -6px rgba(120,84,20,.5); }
.feed-title { font-size: 17px; line-height: 1.55; font-weight: 500; max-width: 560px; margin: 0 auto; }
.feed-meta { margin-top: 8px; font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--card-ink-soft); }
.feed-loading svg { animation: spin 1.4s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.meme-frame { display: grid; place-items: center; margin: 4px auto 12px; max-width: 460px; }
.meme-img { max-width: 100%; max-height: 420px; border-radius: 18px;
  box-shadow: 0 0 0 4px rgba(255,255,255,.85), 0 0 18px -2px var(--rim-glow), 0 10px 26px -10px rgba(120,84,20,.5); }
.meme-img.home { max-height: 190px; margin: 0 auto; border-radius: 14px; }
.meme-emoji { font-size: 74px; text-align: center; padding: 30px 0; }
.meme-emoji.home { font-size: 44px; padding: 10px 0; }
.meme-frame + .feed-title, .meme-frame ~ .feed-meta { text-align: center; }
.home-headlines { text-align: left; gap: 6px; flex: 1; }
.home-headline { font-size: 12.5px; line-height: 1.5; color: var(--card-ink); }

/* ── greenpages ───────────────────────────────────────────────── */
.gp-grid { align-items: stretch; }
.gp-card { border-radius: 20px; padding: 16px; background: rgba(255,255,255,.6);
  box-shadow: inset 0 0 0 1.2px rgba(255,255,255,.9), 0 3px 10px -5px rgba(120,84,20,.3);
  display: flex; flex-direction: column; gap: 9px; color: var(--ink); }
.gp-head { display: flex; align-items: center; gap: 11px; }
.gp-head > span:nth-child(2) { flex: 1; min-width: 0; }
.gp-head strong { display: block; font-size: 14px; }
.gp-head small { font-size: 11.5px; color: var(--ink-soft); }
.gp-tags { display: flex; gap: 5px; flex-wrap: wrap; }
.gp-offer { font-size: 12.5px; line-height: 1.5; color: var(--ink-soft); flex: 1; }
.gp-note { font-size: 12px; color: var(--card-ink-soft, var(--ink-soft)); margin-bottom: 14px; line-height: 1.5; }
.gp-search { flex: 1; min-width: 180px; border: 0; border-radius: 999px; padding: 10px 16px;
  background: rgba(255,255,255,.75); box-shadow: inset 0 0 0 1px rgba(201,173,114,.45); outline: none; }
.gp-search:focus { box-shadow: inset 0 0 0 1.6px rgba(226,166,61,.8); }
.lead-ava.xl { width: 74px; height: 74px; font-size: 23px; }
.pet-emoji { font-size: 40px; line-height: 1; }
.group-emoji { font-size: 28px; width: 44px; height: 44px; display: grid; place-items: center; flex: none;
  background: rgba(255,255,255,.7); border-radius: 50%; box-shadow: inset 0 0 0 1px rgba(255,255,255,.9); }

.kindred-deck { display: grid; place-items: center; margin-bottom: 10px; }
.kindred-card { max-width: 420px; width: 100%; text-align: center; align-items: center; padding: 24px; }

.gp-map { height: 480px; border-radius: 20px; overflow: hidden; z-index: 1;
  box-shadow: inset 0 0 0 2px rgba(255,255,255,.9), 0 6px 18px -8px rgba(120,84,20,.5); }
.map-pop { font-family: var(--font); font-size: 12.5px; min-width: 170px; }
.map-pop strong { font-size: 13px; }
.map-badge { font-size: 9px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
  background: #dcefe2; color: #2e7a52; border-radius: 99px; padding: 2px 7px; }
.map-badge.demo { background: #f2e8d5; color: #96702a; }
.map-offer { margin: 6px 0; font-size: 11.5px; color: #6b7a5f; }
.map-btn { border: 0; border-radius: 99px; padding: 6px 13px; font-size: 11.5px; font-weight: 600;
  background: linear-gradient(160deg, #8bcda3, #4a9a6e); color: #fff; cursor: pointer; }
.leaflet-popup-content-wrapper { border-radius: 14px; }

.active-acc { box-shadow: inset 0 0 0 1.6px rgba(139, 205, 163, .9), 0 2px 8px -4px rgba(120,84,20,.25); }
.gp-home { text-align: left; }

/* ═══════════════════════════════════════════════════════════════
   PRIORITY CHAIN — the current flows top → bottom.
   Root (foundational) work sits at the top; while it is open the
   current stops there: the root card runs hot (amber, urgent
   pulse), downstream stems run dry, leisure cards go cold. When
   the roots are satisfied, pulses cascade down the whole page on
   staggered delays (--chain-delay set per stem, in document
   order), reading as material flowing down the chain of command.
   ═══════════════════════════════════════════════════════════════ */
.chain-hot { --glow: rgba(240, 170, 70, .75); }
.chain-hot > .stem { box-shadow: inset 0 0 0 1px rgba(255,255,255,.7), 0 0 16px -1px rgba(240,170,70,.8); }
.chain-hot > .stem::after {
  animation: stem-urgent 1.3s ease-in-out infinite;
  background:
    radial-gradient(circle at 34% 28%, rgba(255,255,255,.95), rgba(255,255,255,.2) 55%),
    linear-gradient(168deg, #ffe2ae, #f0a952);
  box-shadow: inset 0 -2px 4px rgba(200, 120, 30, .55), 0 0 14px 0 rgba(240, 170, 70, .9);
}
@keyframes stem-urgent {
  0%, 100% { transform: translate(-50%, -50%) scale(1); }
  50%      { transform: translate(-50%, -50%) scale(1.28); }
}
.chain-badge {
  position: absolute; top: -12px; right: 18px; z-index: 6;
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 12px; border-radius: 999px;
  font-size: 10px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
  color: #7a4a10;
  background: linear-gradient(160deg, #ffe9c4, #f6c want)); /* fixed below */
  background: linear-gradient(160deg, #ffe9c4, #f2c274);
  box-shadow: 0 0 0 2px rgba(255,255,255,.85), 0 0 14px -2px rgba(240,170,70,.9);
}
.chain-badge svg { width: 11px; height: 11px; }

/* downstream of the block: dry stems, dimmed matter */
.chain-dry > .stem { opacity: .4; }
.chain-dry > .stem::after { animation: none; opacity: .35; transform: translate(-50%,-50%) scale(.7); }
.chain-cold { filter: saturate(.45); }
.chain-cold .glass-inner { opacity: .88; }
.chain-cold > .drip { opacity: .3; }
.chain-cold > .drip .drip-bead, .chain-cold > .drip .drip-neck { animation-play-state: paused; }

/* leisure lock overlay */
.lock-veil {
  position: absolute; inset: 0; z-index: 5;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px;
  border-radius: inherit;
  background: rgba(249, 240, 220, .72);
  -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px);
  color: var(--ink); text-align: center; padding: 18px;
}
.lock-veil svg { width: 30px; height: 30px; opacity: .75; }
.lock-veil strong { font-size: 13px; letter-spacing: .08em; text-transform: uppercase; }
.lock-veil small { font-size: 12px; color: var(--ink-soft); max-width: 300px; line-height: 1.5; }

/* ═══════════════════════════════════════════════════════════════
   DEV BAR — Decent Technologies
   ═══════════════════════════════════════════════════════════════ */
body { padding-bottom: 34px; }
#devbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 200;
  height: 28px;
  display: flex; align-items: center; gap: 10px;
  padding: 0 14px;
  background: rgba(255, 255, 255, .96);
  border-top: 1px solid rgba(0, 0, 0, .07);
  font-size: 10.5px; letter-spacing: .04em;
  color: #55606a;
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
#devbar .db-logo { width: 15px; height: 15px; color: #2e3a45; flex: none; }
#devbar .db-brand { font-weight: 700; letter-spacing: .14em; color: #2e3a45; white-space: nowrap; }
#devbar .db-sep { opacity: .4; }
#devbar .db-app { white-space: nowrap; opacity: .8; }
#devbar .spacer { flex: 1; }
#devbar .db-ver { font-variant-numeric: tabular-nums; opacity: .7; white-space: nowrap; }
#devbar button {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 3px 11px; border-radius: 99px;
  font-size: 10.5px; font-weight: 600; color: #2e3a45;
  background: #eef1f4; border: 1px solid rgba(0,0,0,.08);
  transition: background .2s ease;
}
#devbar button:hover { background: #e2e8ee; }
#devbar button svg { width: 11px; height: 11px; }
#toast-root { bottom: 44px; }

/* ═══════════════════════════════════════════════════════════════
   ASSISTANT — Dewey (Honeydew) / Willow (Willowtree)
   Floating guide with rule-based suggestions across every page.
   ═══════════════════════════════════════════════════════════════ */
#assistant { position: fixed; right: 18px; bottom: 42px; z-index: 150; }
#assistant-chip {
  width: 54px; height: 54px; border-radius: 50%;
  display: grid; place-items: center; color: #fff;
  background: linear-gradient(168deg, #86c9a0, #3f8f66);
  box-shadow:
    0 0 0 4px rgba(255, 250, 238, .85),
    0 0 0 5px rgba(226, 200, 140, .5),
    0 8px 20px -6px rgba(63, 143, 102, .7),
    inset 0 2px 5px rgba(255,255,255,.5), inset 0 -5px 10px rgba(30,80,50,.35);
  transition: transform .2s ease;
}
#assistant-chip:hover { transform: translateY(-2px) scale(1.05); }
#assistant-chip svg { width: 26px; height: 26px; }
#assistant-chip .a-dot {
  position: absolute; top: 1px; right: 1px;
  width: 13px; height: 13px; border-radius: 50%;
  background: linear-gradient(160deg, #ffce7a, #ef9f3e);
  box-shadow: 0 0 0 2px #fff, 0 0 8px rgba(240,170,70,.9);
  animation: alarm-pulse 1.6s ease-in-out infinite;
}
#assistant-panel {
  position: absolute; right: 0; bottom: 64px;
  width: 320px; max-width: calc(100vw - 36px);
  --r: 24px; --bw: 5px;
}
#assistant-panel .glass-inner { padding: 16px; }
.a-head { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.a-head .dewey-face { width: 38px; height: 38px; }
.a-head .dewey-face svg { width: 20px; height: 20px; }
.a-head strong { flex: 1; font-size: 13.5px; }
.a-sug { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left;
  padding: 9px 11px; border-radius: 14px; margin-bottom: 6px;
  background: rgba(255,255,255,.55); box-shadow: inset 0 0 0 1px rgba(255,255,255,.8);
  font-size: 12.5px; line-height: 1.45; transition: background .2s ease; }
.a-sug:hover { background: rgba(255,255,255,.8); }
.a-sug svg { width: 15px; height: 15px; flex: none; opacity: .8; }
.a-sug.hot { box-shadow: inset 0 0 0 1.4px rgba(240,170,70,.7); }

/* ═══════════════════════════════════════════════════════════════
   WILLOW THEME — Willowtree by Decent Technologies
   Cool sage glasshouse; droplets & stems become living circuit
   roots: hairline traces with node diamonds and travelling pulses.
   ═══════════════════════════════════════════════════════════════ */
body[data-theme="willow"] {
  --cream: #edf2e7;
  --cream-deep: #dee7d3;
  --ink: #33423a;
  --ink-soft: #5b6f60;
  --ink-faint: #8ba18d;
  --rim-hi: rgba(255, 255, 255, .96);
  --rim-mid: rgba(228, 240, 224, .75);
  --rim-lo: rgba(170, 200, 158, .5);
  --rim-glow: rgba(120, 176, 128, .38);
  --trace: #4e8f6e;
  --trace-soft: rgba(78, 143, 110, .65);
  --node: #6fcf9a;
  --node-glow: rgba(111, 207, 154, .85);
  --shadow-card: 0 18px 40px -18px rgba(64, 110, 74, .35),
                 0 4px 14px -6px rgba(64, 110, 74, .2);
}
body[data-theme="willow"] #bg-static { background-color: var(--cream); }
body[data-theme="willow"][data-bg="organic"] #bg-static {
  background-image:
    radial-gradient(90% 70% at 18% 12%, rgba(250, 253, 247, .9), transparent 60%),
    radial-gradient(80% 60% at 85% 85%, rgba(198, 216, 186, .55), transparent 60%);
}
/* cooler dispersion inside the glass ring */
body[data-theme="willow"] .glass::before {
  background:
    conic-gradient(from var(--sweep-a) at 50% 50%,
      transparent 0deg, rgba(255,255,255,0) 28deg,
      rgba(255,255,255,.85) 47deg, rgba(244,255,247,.95) 55deg,
      rgba(255,255,255,.5) 66deg, transparent 92deg,
      transparent 178deg, rgba(232,246,235,.38) 202deg,
      transparent 226deg, transparent 360deg),
    conic-gradient(from var(--sweep-b) at 50% 50%,
      rgba(150, 214, 170, .28) 0deg, rgba(235, 245, 235, .12) 55deg,
      rgba(150, 196, 235, .22) 120deg, rgba(255,255,255,.08) 170deg,
      rgba(196, 182, 226, .2) 226deg, rgba(178, 226, 190, .28) 290deg,
      rgba(150, 214, 170, .28) 360deg);
}
body[data-theme="willow"] .glass {
  box-shadow:
    0 0 0 1px rgba(255,255,255,.55),
    inset 0 0 0 1px rgba(255,255,255,.65),
    inset 0 2px 3px rgba(255,255,255,.9),
    inset 0 -2px 4px rgba(110, 160, 118, .3),
    0 0 18px -2px var(--glow, var(--rim-glow)),
    var(--shadow-card);
}
/* muted card colorways */
body[data-theme="willow"] .c-green  { --face: linear-gradient(168deg, rgba(112,168,132,.95), rgba(66,122,89,.96) 55%, rgba(46,96,68,.97)); --glow: rgba(90,150,110,.5); }
body[data-theme="willow"] .c-gold   { --face: linear-gradient(168deg, rgba(226,214,158,.95), rgba(196,178,110,.95) 55%, rgba(168,148,84,.96)); --glow: rgba(190,172,104,.5); --card-ink:#4c421c; --card-ink-soft:#6b6034; }
body[data-theme="willow"] .c-orange { --face: linear-gradient(168deg, rgba(214,178,122,.95), rgba(188,144,88,.96) 55%, rgba(158,114,64,.96)); --glow: rgba(190,150,96,.5); }
body[data-theme="willow"] .c-purple { --face: linear-gradient(168deg, rgba(186,182,212,.95), rgba(152,146,190,.95) 55%, rgba(120,112,164,.96)); --glow: rgba(150,142,190,.5); }
body[data-theme="willow"] .c-lav    { --face: linear-gradient(168deg, rgba(222,224,238,.95), rgba(196,198,224,.94)); --glow: rgba(160,162,200,.45); --card-ink:#454866; --card-ink-soft:#666a8c; }
body[data-theme="willow"] .c-blue   { --face: linear-gradient(168deg, rgba(178,204,208,.95), rgba(134,170,176,.95) 55%, rgba(100,140,148,.96)); --glow: rgba(130,170,175,.5); --card-ink:#1d3c40; --card-ink-soft:#3c5c60; }
body[data-theme="willow"] .c-sky    { --face: linear-gradient(168deg, rgba(206,224,228,.95), rgba(170,198,204,.94)); --glow: rgba(150,186,192,.45); --card-ink:#28484e; --card-ink-soft:#4a686e; }
body[data-theme="willow"] .c-mint   { --face: linear-gradient(168deg, rgba(228,238,220,.93), rgba(204,222,190,.9)); --glow: rgba(150,186,128,.4); }
body[data-theme="willow"] .c-pink   { --face: linear-gradient(168deg, rgba(234,216,212,.94), rgba(218,190,184,.93)); --glow: rgba(198,158,148,.45); --card-ink:#6e4038; --card-ink-soft:#8c625a; }
body[data-theme="willow"] .c-peach  { --face: linear-gradient(168deg, rgba(232,216,196,.94), rgba(214,190,160,.93)); --glow: rgba(200,170,130,.45); --card-ink:#6c4c28; --card-ink-soft:#8a6c48; }
body[data-theme="willow"] .brand-name { color: #55704e; }
body[data-theme="willow"] .hero-emblem,
body[data-theme="willow"] .dewey-face,
body[data-theme="willow"] #assistant-chip { background: linear-gradient(168deg, #7fb894, #3c7a58); }
body[data-theme="willow"] .toast .t-ico { background: linear-gradient(160deg, #7fb894, #3c7a58); }

/* ── circuit roots: droplets become node pulses on traces ─────── */
body[data-theme="willow"] .drip { filter: none; width: 14px; margin-left: -7px; height: 32px; }
body[data-theme="willow"] .drip-neck {
  width: 1.5px; height: 22px; top: -1px;
  border-radius: 0;
  background: linear-gradient(180deg, var(--trace-soft), rgba(78, 143, 110, .12));
  box-shadow: none;
  animation: trace-breathe var(--drip-dur, 4.6s) ease-in-out infinite;
  animation-delay: var(--drip-delay, 0s);
}
@keyframes trace-breathe { 0%,100% { opacity: .55; } 50% { opacity: 1; } }
body[data-theme="willow"] .drip-bead {
  top: 17px; left: 50%; width: 7px; height: 7px; margin-left: -3.5px;
  border-radius: 2px;
  background: linear-gradient(160deg, #a9e8c4, var(--node));
  box-shadow: 0 0 7px var(--node-glow), inset 0 0 2px rgba(255,255,255,.9);
  rotate: 45deg;
  animation: node-blink var(--drip-dur, 4.6s) ease-in-out infinite;
  animation-delay: var(--drip-delay, 0s);
}
@keyframes node-blink {
  0%, 100% { transform: scale(1); opacity: .8; }
  50%      { transform: scale(1.35); opacity: 1; }
}
body[data-theme="willow"] .drip-splash {
  border-radius: 3px; rotate: 45deg;
  border-color: var(--node);
  box-shadow: 0 0 10px var(--node-glow), inset 0 0 4px rgba(255,255,255,.8);
  width: 16px; height: 16px; margin: -8px 0 0 -8px;
}

/* stems become circuit traces with elbow branches */
body[data-theme="willow"] .stem {
  width: 2px; border-radius: 0;
  background: linear-gradient(180deg, rgba(78,143,110,.15), var(--trace-soft) 40%, var(--trace));
  box-shadow: none;
}
body[data-theme="willow"] .stem::before {
  content: ""; position: absolute; top: 30%; left: 1px;
  width: 11px; height: 1.5px;
  background: linear-gradient(90deg, var(--trace-soft), transparent);
}
body[data-theme="willow"] .stem::after {
  width: 8px; height: 8px; border-radius: 2px;
  background: linear-gradient(160deg, #a9e8c4, var(--node));
  box-shadow: 0 0 8px var(--node-glow), inset 0 0 2px rgba(255,255,255,.9);
  rotate: 45deg;
  animation: trace-pulse 4.2s ease-in-out infinite;
  animation-delay: var(--chain-delay, 0s);
}
@keyframes trace-pulse {
  0%, 14%  { transform: translate(-50%, -160%) scale(.5); opacity: 0; }
  26%      { transform: translate(-50%, -110%) scale(1); opacity: 1; }
  55%      { transform: translate(-50%, -30%) scale(1.1); opacity: 1; }
  80%,100% { transform: translate(-50%, 60%) scale(.4); opacity: 0; }
}
body[data-theme="willow"] .chain-hot > .stem::after {
  background: linear-gradient(160deg, #ffe0a6, #eda94e);
  box-shadow: 0 0 12px rgba(237, 169, 78, .95), inset 0 0 2px rgba(255,255,255,.9);
  animation: stem-urgent 1.3s ease-in-out infinite;
}
body[data-theme="willow"] .chain-hot > .stem {
  background: linear-gradient(180deg, rgba(237,169,78,.2), rgba(237,169,78,.75));
}
body[data-theme="willow"] .stem-root-note { color: var(--trace); }

@media (max-width: 860px) {
  .trio.duo { grid-template-columns: 1fr; }
  .flow-stats { justify-content: center; }
  .gp-map { height: 380px; }
  #assistant { right: 12px; }
}
