:root{
  --ink:#13271f;
  --muted:#5e7068;
  --forest:#163a2a;
  --forest-2:#24523c;
  --sage:#dce9df;
  --sage-2:#eff5ef;
  --cream:#fbfaf6;
  --paper:#ffffff;
  --line:#dfe7e1;
  --line-strong:#c9d7ce;
  --gold:#f5efcf;
  --shadow:0 18px 54px rgba(24,55,42,.08);
  --max:1180px;
  --radius-xl:28px;
  --radius-lg:20px;
  --radius-md:14px;
  --space-1:6px;
  --space-2:10px;
  --space-3:16px;
  --space-4:24px;
  --space-5:36px;
  --space-6:56px;
  --space-7:84px;
}
*{box-sizing:border-box}
html{scroll-behavior:smooth}
body{margin:0;background:var(--cream);color:var(--ink);font-family:Inter,ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;-webkit-font-smoothing:antialiased}
button,input,select{font:inherit;color:inherit}
button,a{touch-action:manipulation}
a{color:inherit}
.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
.site-header{position:sticky;top:0;z-index:40;display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:24px;min-height:68px;padding:0 max(20px,calc((100vw - var(--max))/2));background:rgba(251,250,246,.92);border-bottom:1px solid rgba(201,215,206,.75);backdrop-filter:blur(18px)}
.brand{text-decoration:none;font-weight:760;letter-spacing:-.03em}
.primary-nav{display:flex;justify-content:center;gap:22px}
.primary-nav a,.header-actions a,.text-button{font-size:13px;text-decoration:none;color:var(--muted)}
.primary-nav a:hover,.header-actions a:hover,.text-button:hover{color:var(--ink)}
.header-actions{display:flex;align-items:center;gap:12px}
.text-button{border:0;background:none;padding:8px 0;cursor:pointer}
.text-button [data-saved-count]{display:inline-grid;place-items:center;min-width:20px;height:20px;margin-left:3px;padding:0 6px;border-radius:999px;background:var(--sage);color:var(--forest);font-size:10px;font-weight:760}
main{overflow:hidden}
.search-hero,.results-section,.comparison-section,.system-note{max-width:var(--max);margin:0 auto;padding-left:22px;padding-right:22px}
.search-hero{padding-top:74px;padding-bottom:70px}
.hero-wordmark{position:relative;width:210px;height:52px;margin-bottom:54px;overflow:hidden;border-radius:12px;background:#07100d}
.simple-particle-canvas{display:block;width:100%;height:100%}
.simple-motion-fallback{position:absolute;inset:0;display:grid;place-items:center;color:transparent;-webkit-text-stroke:1px rgba(255,255,255,.08);font-size:34px;font-weight:820;letter-spacing:-.06em;pointer-events:none}
.hero-copy{max-width:790px}
.eyebrow{margin:0 0 10px;font-size:10px;font-weight:800;letter-spacing:.14em;color:var(--forest-2)}
h1,h2,h3,p{margin-top:0}
h1{max-width:900px;margin-bottom:18px;font-size:clamp(52px,7.7vw,92px);line-height:.95;letter-spacing:-.065em;font-weight:700}
.hero-copy>p:last-child{max-width:760px;margin-bottom:0;color:var(--muted);font-size:19px;line-height:1.55}
.search-shell{display:grid;grid-template-columns:26px minmax(0,1fr) auto;align-items:center;gap:12px;margin-top:38px;padding:8px 8px 8px 18px;background:#fff;border:1px solid var(--line-strong);border-radius:20px;box-shadow:var(--shadow)}
.search-shell svg{width:22px;fill:none;stroke:var(--muted);stroke-width:1.6}
.search-shell input{height:58px;min-width:0;border:0;outline:0;background:transparent;font-size:17px}
.search-shell button,.primary-button{min-height:46px;padding:0 18px;border:0;border-radius:12px;background:var(--forest);color:#fff;font-weight:720;text-decoration:none;cursor:pointer}
.quick-prompts{display:flex;gap:8px;flex-wrap:wrap;margin-top:14px}
.quick-prompts button,.filter-chip,.compact-button{min-height:36px;padding:0 12px;border:1px solid var(--line);border-radius:999px;background:rgba(255,255,255,.82);color:var(--muted);font-size:12px;cursor:pointer}
.quick-prompts button:hover,.filter-chip:hover,.compact-button:hover{border-color:var(--line-strong);color:var(--ink)}
.search-principles{display:flex;gap:18px;flex-wrap:wrap;margin-top:24px;color:#77877f;font-size:11px}
.search-principles span{display:flex;align-items:center;gap:6px}
.search-principles span:before{content:"";width:4px;height:4px;border-radius:50%;background:#8fa497}
.results-section{padding-top:70px;padding-bottom:96px;border-top:1px solid var(--line)}
.results-topbar,.comparison-header{display:flex;align-items:end;justify-content:space-between;gap:24px}
.results-topbar h2,.comparison-header h2,.system-note h2{margin-bottom:0;font-size:clamp(34px,4.2vw,54px);line-height:1.03;letter-spacing:-.05em;font-weight:660}
.results-actions{display:flex;align-items:center;gap:8px}
.results-actions select{height:36px;padding:0 30px 0 11px;border:1px solid var(--line);border-radius:10px;background:#fff;font-size:12px}
.refine-panel{display:flex;gap:8px;flex-wrap:wrap;margin-top:24px;padding:16px 0;border-top:1px solid var(--line);border-bottom:1px solid var(--line)}
.filter-chip.active{background:var(--sage);border-color:#b8cdbf;color:var(--forest)}
.results-summary{display:flex;gap:10px;align-items:center;margin:24px 0 12px;color:var(--muted);font-size:12px}
.preview-badge{padding:4px 7px;border-radius:6px;background:var(--gold);color:#655b22;font-size:10px;font-weight:740}
.resource-list{display:grid;gap:1px;border-top:1px solid var(--line)}
.resource-row{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:28px;padding:28px 0;border-bottom:1px solid var(--line)}
.resource-main{min-width:0}
.resource-kicker{display:flex;gap:9px;align-items:center;flex-wrap:wrap;margin-bottom:9px}
.source-name,.resource-type,.source-trust{font-size:10px;font-weight:780;letter-spacing:.05em;text-transform:uppercase}
.source-name{color:var(--forest)}
.resource-type{padding:4px 7px;border-radius:6px;background:var(--sage-2);color:var(--forest-2)}
.source-trust{color:#718079}
.resource-row h3{margin-bottom:8px;font-size:24px;line-height:1.15;letter-spacing:-.035em}
.resource-description{max-width:760px;margin-bottom:16px;color:var(--muted);line-height:1.55;font-size:14px}
.resource-metrics{display:flex;gap:18px;flex-wrap:wrap;margin-bottom:15px}
.metric{display:grid;gap:2px;min-width:78px}
.metric-label{font-size:9px;text-transform:uppercase;letter-spacing:.08em;color:#87958e;font-weight:760}
.metric-value{font-size:13px;font-weight:680;color:var(--ink)}
.fit-line{display:flex;align-items:flex-start;gap:10px;max-width:820px;padding-top:14px;border-top:1px solid #edf1ee}
.fit-line strong{white-space:nowrap;font-size:11px;color:var(--forest)}
.fit-line span{color:var(--muted);font-size:12px;line-height:1.5}
.resource-side{display:flex;flex-direction:column;align-items:flex-end;justify-content:space-between;gap:16px}
.resource-actions{display:flex;gap:7px;align-items:center}
.source-link,.compare-button,.save-button{display:inline-flex;align-items:center;justify-content:center;min-height:38px;padding:0 12px;border-radius:10px;font-size:12px;font-weight:700;text-decoration:none;cursor:pointer}
.source-link{background:var(--forest);color:#fff;border:1px solid var(--forest)}
.compare-button,.save-button{background:#fff;border:1px solid var(--line)}
.compare-button.active,.save-button.saved{background:var(--sage);border-color:#b8cdbf;color:var(--forest)}
.empty-state{padding:64px 20px;text-align:center;border:1px dashed var(--line-strong);border-radius:18px;background:rgba(255,255,255,.5)}
.empty-state p{max-width:520px;margin:0 auto 18px;color:var(--muted)}
.comparison-section{padding-top:80px;padding-bottom:96px;border-top:1px solid var(--line)}
.comparison-scroll{margin-top:26px;overflow-x:auto;border:1px solid var(--line);border-radius:18px;background:#fff;box-shadow:var(--shadow)}
.comparison-table{width:100%;min-width:760px;border-collapse:collapse;font-size:13px}
.comparison-table th,.comparison-table td{padding:15px 16px;border-bottom:1px solid #edf1ee;text-align:left;vertical-align:top}
.comparison-table thead th{background:#f8faf8;font-size:11px;letter-spacing:.04em;text-transform:uppercase;color:var(--muted)}
.comparison-table tbody th{width:150px;color:var(--muted);font-weight:620}
.system-note{display:grid;grid-template-columns:.78fr 1.22fr;gap:54px;align-items:start;padding-top:74px;padding-bottom:90px;border-top:1px solid var(--line)}
.system-flow{display:grid;grid-template-columns:1fr auto 1fr auto 1fr;gap:14px;align-items:center;padding:22px 24px;border-radius:18px;background:var(--sage-2)}
.system-flow div{display:grid;gap:4px}
.system-flow strong{font-size:13px;color:var(--forest)}
.system-flow span{font-size:12px;color:var(--muted);line-height:1.45}
.system-flow>span{font-size:16px;color:#91a295}
.saved-drawer{position:fixed;z-index:60;top:0;right:0;width:min(420px,100vw);height:100dvh;padding:24px;background:var(--cream);box-shadow:-20px 0 60px rgba(0,0,0,.16);transform:translateX(105%);transition:transform .25s ease;display:grid;grid-template-rows:auto 1fr auto}
.saved-drawer.open{transform:translateX(0)}
.saved-drawer-header{display:flex;justify-content:space-between;align-items:start;padding-bottom:18px;border-bottom:1px solid var(--line)}
.saved-drawer-header h2{margin:0;font-size:30px;letter-spacing:-.04em}
.icon-button{width:36px;height:36px;border:1px solid var(--line);border-radius:10px;background:#fff;font-size:22px;cursor:pointer}
.saved-items{overflow:auto;padding:12px 0}
.saved-item{padding:14px 0;border-bottom:1px solid var(--line)}
.saved-item strong{display:block;margin-bottom:4px}
.saved-item span{font-size:11px;color:var(--muted)}
.drawer-backdrop{position:fixed;z-index:50;inset:0;background:rgba(10,30,22,.3);backdrop-filter:blur(2px)}
.site-footer{display:flex;justify-content:space-between;gap:20px;flex-wrap:wrap;padding:34px max(22px,calc((100vw - var(--max))/2));background:#0d2d20;color:#fff;font-size:12px}
.site-footer span{color:#b8c9bf}
.site-footer a{text-decoration:none;color:#dce9e0}
@media(max-width:980px){
  .site-header{grid-template-columns:auto 1fr}
  .primary-nav{display:none}
  .header-actions{justify-content:flex-end}
  .resource-row{grid-template-columns:1fr}
  .resource-side{align-items:flex-start}
  .system-note{grid-template-columns:1fr}
}
@media(max-width:680px){
  .site-header{min-height:62px;padding-left:16px;padding-right:16px}
    .search-hero,.results-section,.comparison-section,.system-note{padding-left:16px;padding-right:16px}
  .search-hero{padding-top:54px}
  .hero-wordmark{margin-bottom:38px}
  h1{font-size:54px}
  .hero-copy>p:last-child{font-size:16px}
  .search-shell{grid-template-columns:22px minmax(0,1fr);padding:8px 10px;border-radius:16px}
  .search-shell button{grid-column:1/-1;width:100%}
  .results-topbar,.comparison-header{align-items:flex-start;flex-direction:column}
  .results-actions{width:100%;justify-content:space-between}
  .resource-row{padding:22px 0}
  .resource-row h3{font-size:21px}
  .resource-actions{flex-wrap:wrap}
  .system-flow{grid-template-columns:1fr;gap:10px}
  .system-flow>span{transform:rotate(90deg);width:max-content}
}
@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto!important;transition:none!important}}


.query-readout{
  display:flex;align-items:center;gap:8px;flex-wrap:wrap;
  margin:0 0 18px;padding:12px 0 18px;border-bottom:1px solid var(--line)
}
.readout-label{
  margin-right:4px;font-size:10px;font-weight:800;letter-spacing:.12em;text-transform:uppercase;color:#829189
}
.readout-token{
  display:inline-flex;align-items:center;gap:6px;min-height:32px;padding:0 10px;
  border:1px solid var(--line);border-radius:999px;background:#fff;font-size:11px;font-weight:680;color:var(--ink)
}
.readout-token small{font-size:9px;text-transform:uppercase;letter-spacing:.07em;color:#87958e;font-weight:760}
.details-button{
  display:inline-flex;align-items:center;justify-content:center;min-height:38px;padding:0 12px;
  border:1px solid var(--line);border-radius:10px;background:transparent;font-size:12px;font-weight:700;cursor:pointer;color:var(--muted)
}
.details-button:hover{color:var(--ink);border-color:var(--line-strong);background:#fff}
.resource-details{
  display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;
  margin-top:16px;padding:16px;border:1px solid #e6ece8;border-radius:14px;background:#f8faf8
}
.resource-details>div{display:grid;gap:4px}
.detail-label{font-size:9px;font-weight:800;letter-spacing:.08em;text-transform:uppercase;color:#87958e}
.resource-details strong{font-size:12px;font-weight:680}
.grocery-options{grid-column:1/-1;display:grid!important;grid-template-columns:1fr repeat(3,minmax(0,1fr));gap:8px!important;align-items:center}
.grocery-options>.detail-label{grid-column:1/-1}
.grocery-options>span:not(.detail-label){
  display:grid;gap:2px;padding:10px;border-radius:10px;background:#fff;border:1px solid var(--line)
}
.grocery-options em{font-style:normal;font-size:12px;color:var(--forest)}
.grocery-options small{font-size:10px;color:var(--muted)}
.data-note{grid-column:1/-1;margin:0;color:#7c8a83;font-size:10px;line-height:1.5}
.compare-dock{
  position:fixed;z-index:45;left:50%;bottom:18px;transform:translateX(-50%);
  width:min(720px,calc(100vw - 28px));display:flex;align-items:center;justify-content:space-between;gap:18px;
  padding:12px 14px 12px 16px;border:1px solid rgba(203,216,207,.9);border-radius:16px;
  background:rgba(255,255,255,.92);box-shadow:0 18px 50px rgba(17,43,31,.16);backdrop-filter:blur(18px)
}
.compare-dock>div{display:grid;gap:2px}
.compare-dock strong{font-size:12px}
.compare-dock span{font-size:10px;color:var(--muted)}
.compare-dock .primary-button{min-height:38px;padding:0 14px}
@media(max-width:680px){
  .query-readout{align-items:flex-start}
  .resource-details{grid-template-columns:1fr}
  .grocery-options{grid-template-columns:1fr}
  .grocery-options>.detail-label{grid-column:auto}
  .resource-side{width:100%}
  .resource-actions{width:100%}
  .source-link{flex:1}
  .compare-dock{bottom:10px;width:calc(100vw - 20px)}
}


.resource-layout{display:grid;grid-template-columns:72px minmax(0,1fr);gap:18px;align-items:start}
.result-visual{
  position:relative;display:grid;place-items:center;width:72px;height:92px;border-radius:20px;
  background:linear-gradient(160deg,#f4f8f3 0%,#e4eee6 55%,#d7e6dc 100%);
  border:1px solid var(--line);overflow:hidden
}
.result-visual:after{
  content:"";position:absolute;inset:auto -18px -24px auto;width:72px;height:72px;border-radius:50%;
  background:radial-gradient(circle,rgba(22,58,42,.12),transparent 68%)
}
.visual-rank{position:absolute;top:9px;left:10px;font-size:9px;font-weight:800;letter-spacing:.08em;color:#7b8e83}
.visual-glyph{font-size:31px;line-height:1;color:var(--forest)}
.match-label{
  display:inline-flex;align-items:center;min-height:23px;padding:0 8px;border-radius:999px;
  background:var(--forest);color:#fff;font-size:9px;font-weight:800;letter-spacing:.06em;text-transform:uppercase
}
.featured-result{
  margin:0 -14px;padding:30px 14px;border-radius:22px;
  background:linear-gradient(180deg,rgba(239,245,239,.75),rgba(251,250,246,0))
}
.featured-result .result-visual{box-shadow:0 16px 34px rgba(21,54,40,.08)}
.resource-details{grid-template-columns:repeat(3,minmax(0,1fr))}
.detail-pair{padding:2px 0}
.retailer-panel{
  grid-column:1/-1!important;display:grid!important;gap:12px!important;padding-top:14px;border-top:1px solid var(--line)
}
.retailer-panel-head{display:flex!important;align-items:end;justify-content:space-between;gap:16px}
.retailer-panel-head>div{display:grid;gap:3px}
.retailer-panel-head>span{font-size:9px;color:#89978f}
.retailer-list{display:grid;gap:7px}
.retailer-row{
  display:grid;grid-template-columns:minmax(0,1fr) auto auto;gap:14px;align-items:center;
  padding:11px 12px;border:1px solid var(--line);border-radius:12px;background:#fff
}
.retailer-row>div:first-child{display:grid;gap:2px}
.retailer-row>div:first-child strong{font-size:12px}
.retailer-row>div:first-child span{font-size:10px;color:var(--muted)}
.retailer-price{display:grid;justify-items:end;gap:1px}
.retailer-price strong{font-size:13px}
.retailer-price small{font-size:9px;color:var(--forest-2)}
.retailer-action{
  min-height:32px;padding:0 10px;border:1px solid var(--line);border-radius:9px;background:#f6f8f6;
  color:#8b9991;font-size:10px;font-weight:700
}
.retailer-empty{margin:0;color:var(--muted);font-size:11px}
@media(max-width:760px){
  .resource-layout{grid-template-columns:52px minmax(0,1fr);gap:12px}
  .result-visual{width:52px;height:70px;border-radius:15px}
  .visual-glyph{font-size:24px}
  .resource-details{grid-template-columns:1fr}
  .retailer-panel{grid-column:auto!important}
  .retailer-panel-head{align-items:flex-start;flex-direction:column}
  .retailer-row{grid-template-columns:1fr auto}
  .retailer-action{grid-column:1/-1;width:100%}
}


.search-notice{
  display:flex;align-items:flex-start;gap:12px;margin:-6px 0 18px;padding:12px 14px;
  border:1px solid var(--line);border-radius:12px;background:rgba(255,255,255,.7)
}
.search-notice strong{font-size:11px;color:var(--forest);white-space:nowrap}
.search-notice span{font-size:11px;line-height:1.5;color:var(--muted)}
.source-status{
  display:inline-flex;align-items:center;gap:5px;font-size:9px;font-weight:760;letter-spacing:.05em;text-transform:uppercase
}
.source-status:before{content:"";width:6px;height:6px;border-radius:50%}
.source-status.is-available{color:#557160}
.source-status.is-available:before{background:#6f9a7a}
.source-status.is-limited{color:#8a6c47}
.source-status.is-limited:before{background:#c39a61}
.loading-stack{display:grid;gap:1px;border-top:1px solid var(--line)}
.loading-row{
  height:164px;border-bottom:1px solid var(--line);
  background:linear-gradient(90deg,transparent 0%,rgba(255,255,255,.9) 45%,transparent 72%);
  background-size:220% 100%;animation:hs-shimmer 1.25s linear infinite
}
@keyframes hs-shimmer{from{background-position:220% 0}to{background-position:-40% 0}}
@media(max-width:680px){
  .search-notice{flex-direction:column;gap:4px}
  .loading-row{height:210px}
}
@media(prefers-reduced-motion:reduce){
  .loading-row{animation:none;background:rgba(255,255,255,.5)}
}

.source-status.is-prototype{color:#6b6a5a}
.source-status.is-prototype:before{background:#c8b97c}

.source-status.is-pending{color:#74674e}
.source-status.is-pending:before{background:#b9a36f}

.compare-dock .primary-button:disabled{opacity:.45;cursor:default}

.constraint-note{display:flex;align-items:flex-start;gap:10px;margin-top:8px;padding:10px 12px;border-radius:10px;background:#faf5eb}
.constraint-note strong{white-space:nowrap;font-size:10px;color:#7d6540}
.constraint-note span{font-size:11px;line-height:1.45;color:#786d5b}
.constraint-note.is-unknown{background:#f4f6f4}
.constraint-note.is-unknown strong{color:#68776f}
.constraint-note.is-unknown span{color:#748179}

/* Phase 2 refinement */
:root{
  --surface-soft:rgba(255,255,255,.72);
  --surface-strong:rgba(255,255,255,.94);
  --hairline:rgba(43,78,61,.10);
  --focus:0 0 0 3px rgba(76,126,96,.18);
}
body{letter-spacing:-.005em}
.site-header{min-height:64px}
.brand-word{font-size:15px}
.primary-nav a,.text-button{font-size:12px;font-weight:620}
.search-hero{padding-top:68px;padding-bottom:64px}
.hero-wordmark{width:232px;height:58px;margin-bottom:46px;border-radius:16px;box-shadow:inset 0 0 0 1px rgba(255,255,255,.04),0 18px 50px rgba(7,16,13,.14)}
.hero-copy{max-width:840px}
h1{margin-bottom:16px;font-size:clamp(54px,7.2vw,88px)}
.hero-copy>p:last-child{max-width:720px;font-size:18px;line-height:1.5}
.search-shell{margin-top:34px;border-radius:18px;box-shadow:0 14px 42px rgba(24,55,42,.07),inset 0 1px 0 rgba(255,255,255,.9)}
.search-shell:focus-within{border-color:#a8c3b2;box-shadow:var(--focus),0 14px 42px rgba(24,55,42,.07)}
.search-shell input{height:54px}
.search-shell button,.primary-button{min-height:44px;border-radius:11px}
.quick-prompts{margin-top:12px}
.quick-prompts button,.filter-chip,.compact-button{min-height:34px;padding:0 11px;font-size:11px;background:rgba(255,255,255,.66)}
.search-principles{margin-top:20px}
.results-section{padding-top:64px;padding-bottom:88px}
.results-topbar h2,.comparison-header h2,.system-note h2{font-size:clamp(32px,3.8vw,48px)}
.results-summary{margin-top:20px}
.preview-badge{background:#f2f0e4;color:#6f6950}
.query-readout{margin-bottom:10px;padding-bottom:16px}
.resource-list{border-top:0}
.resource-row{
  position:relative;
  grid-template-columns:minmax(0,1fr) auto;
  gap:24px;
  padding:26px 24px;
  margin:0 -24px;
  border-bottom:1px solid var(--hairline);
  transition:background .18s ease,transform .18s ease;
}
.resource-row:hover{background:rgba(255,255,255,.42)}
.resource-row.featured-result{
  margin-top:6px;
  border:1px solid rgba(105,144,120,.18);
  border-radius:20px;
  background:linear-gradient(145deg,rgba(255,255,255,.88),rgba(241,247,242,.78));
  box-shadow:0 16px 42px rgba(28,62,45,.06);
}
.resource-layout{display:grid;grid-template-columns:54px minmax(0,1fr);gap:18px}
.result-visual{
  width:54px;height:68px;display:flex;flex-direction:column;justify-content:space-between;
  padding:8px;border-radius:15px;background:linear-gradient(180deg,#f1f6f2,#e5efe8);
  border:1px solid rgba(95,132,109,.12)
}
.visual-rank{font-size:9px;font-weight:800;letter-spacing:.08em;color:#7f9187}
.visual-glyph{align-self:flex-end;font-size:24px;line-height:1;color:var(--forest-2)}
.resource-kicker{gap:7px;margin-bottom:8px}
.source-name,.resource-type,.source-trust,.source-status{font-size:9px}
.match-label{font-size:10px;font-weight:780;color:var(--forest)}
.resource-row h3{font-size:23px}
.resource-description{max-width:720px;margin-bottom:14px}
.resource-metrics{gap:14px;margin-bottom:14px}
.metric{min-width:72px}
.metric-value{font-size:12px}
.fit-line{padding-top:12px}
.constraint-note{border:1px solid rgba(151,128,83,.10)}
.resource-actions{gap:6px}
.source-link,.compare-button,.save-button,.details-button{min-height:36px;padding:0 11px;font-size:11px}
.source-link{box-shadow:inset 0 -1px 0 rgba(0,0,0,.08)}
.resource-details{margin-top:14px;padding:14px;border-radius:13px;background:rgba(248,250,248,.92)}
.retailer-panel{border-top:1px solid var(--hairline)}
.saved-drawer{width:min(390px,100vw);padding:22px;grid-template-rows:auto 1fr}
.saved-item{padding:16px 2px}
.saved-item strong{font-size:14px}
.compare-dock{
  width:min(660px,calc(100vw - 28px));
  padding:10px 12px 10px 14px;
  border-radius:15px;
  background:rgba(255,255,255,.95)
}
.comparison-scroll{border-radius:16px;box-shadow:0 14px 38px rgba(17,43,31,.08)}
.system-note{padding-top:68px;padding-bottom:82px}
.system-flow{padding:20px 22px;border-radius:16px}
button:focus-visible,a:focus-visible,select:focus-visible,input:focus-visible{outline:none;box-shadow:var(--focus)}
@media(max-width:980px){
  .resource-row{margin-left:0;margin-right:0;padding-left:0;padding-right:0}
  .resource-row.featured-result{padding-left:18px;padding-right:18px}
}
@media(max-width:680px){
  .search-hero{padding-top:46px;padding-bottom:54px}
  .hero-wordmark{width:196px;height:50px;margin-bottom:34px}
  h1{font-size:50px;line-height:.96}
  .search-shell input{height:50px;font-size:16px}
  .results-section{padding-top:52px}
  .resource-layout{grid-template-columns:42px minmax(0,1fr);gap:12px}
  .result-visual{width:42px;height:58px;border-radius:12px}
  .resource-row.featured-result{padding:18px 14px}
  .resource-metrics{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
  .resource-actions{width:100%}
  .source-link,.compare-button,.save-button,.details-button{flex:1 1 auto}
  .fit-line{display:grid;gap:4px}
  .query-readout{gap:6px}
  .readout-token{min-height:30px;padding:0 9px}
  .compare-dock{bottom:10px}
}

.saved-item{display:grid;gap:12px}
.saved-item-copy{display:grid;gap:4px}
.saved-item-actions{display:flex;align-items:center;gap:12px}
.saved-item-actions a,.saved-item-actions button{
  border:0;background:none;padding:0;color:var(--forest);font-size:11px;font-weight:700;text-decoration:none;cursor:pointer
}
.saved-item-actions button{color:var(--muted)}
.saved-item-actions a:hover,.saved-item-actions button:hover{color:var(--ink)}
.empty-state.compact{padding:34px 14px;border-radius:14px}
.empty-state.compact h3{font-size:18px;margin-bottom:6px}
.empty-state.compact p{font-size:12px;margin-bottom:0}

.loading-stack{display:grid;gap:1px}
.loading-row{display:grid;grid-template-columns:54px minmax(0,1fr) 150px;gap:18px;align-items:center;padding:26px 24px;margin:0 -24px;border-bottom:1px solid var(--hairline)}
.loading-row span,.loading-row i,.loading-row b{display:block;background:linear-gradient(90deg,#eef3ef 25%,#f7f9f7 50%,#eef3ef 75%);background-size:200% 100%;animation:hs-shimmer 1.25s linear infinite}
.loading-row span{width:54px;height:58px;border-radius:14px}
.loading-row i{height:64px;border-radius:12px}
.loading-row b{width:150px;height:36px;border-radius:10px}
@keyframes hs-shimmer{to{background-position:-200% 0}}
@media(max-width:980px){
  .loading-row{grid-template-columns:42px minmax(0,1fr);margin-left:0;margin-right:0;padding-left:0;padding-right:0}
  .loading-row b{display:none}
}
@media(prefers-reduced-motion:reduce){
  .loading-row span,.loading-row i,.loading-row b{animation:none}
}

/* Browse taxonomy + live source imagery */
.browse-categories{
  display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin-top:20px;padding-top:18px;
  border-top:1px solid var(--hairline)
}
.browse-label{
  margin-right:2px;font-size:9px;font-weight:800;letter-spacing:.12em;text-transform:uppercase;color:#819087
}
.browse-categories button{
  min-height:34px;padding:0 12px;border:1px solid rgba(78,108,91,.12);border-radius:999px;
  background:rgba(238,245,239,.82);color:var(--forest-2);font-size:11px;font-weight:680;cursor:pointer
}
.browse-categories button:hover{background:#fff;border-color:#afc5b6;color:var(--ink)}
.result-visual.has-image{padding:0;background:#edf2ee}
.result-visual.has-image:after{display:none}
.result-visual.has-image img{width:100%;height:100%;object-fit:cover;display:block}
.result-visual.has-image .visual-rank{
  top:6px;left:6px;padding:3px 5px;border-radius:6px;background:rgba(7,16,13,.72);color:#fff
}
.savings-badge{
  display:inline-flex;align-items:center;min-height:23px;padding:0 8px;border-radius:999px;
  background:#f4edc9;color:#63591d;font-size:9px;font-weight:800;letter-spacing:.05em;text-transform:uppercase
}
@media(max-width:680px){
  .browse-categories{gap:6px}
  .browse-categories button{min-height:32px;padding:0 10px;font-size:10px}
}

.result-visual.category-medications{background:linear-gradient(160deg,#f8f2f1,#eadfdd)}
.result-visual.category-movement{background:linear-gradient(160deg,#eef7ef,#dbeadf)}
.result-visual.category-care{background:linear-gradient(160deg,#eef5f5,#dce9e8)}
.result-visual.category-labs{background:linear-gradient(160deg,#eef3f8,#dbe5ee)}
.result-visual.category-mental-wellness{background:linear-gradient(160deg,#f3f0f8,#e4deee)}
.result-visual.category-sleep{background:linear-gradient(160deg,#edf0f6,#dce2ec)}
.result-visual.category-financial,.result-visual.category-public-programs{background:linear-gradient(160deg,#faf5df,#eee3b9)}
.result-visual.category-insurance{background:linear-gradient(160deg,#eef4f2,#dce8e3)}
.result-visual.category-education{background:linear-gradient(160deg,#f5f2ea,#e9e1d2)}
.result-visual.category-local{background:linear-gradient(160deg,#edf6f2,#d8e8e0)}

/* Mobile interaction refinement */
@media(max-width:680px){
  .text-button{min-height:44px;display:inline-flex;align-items:center}
  .quick-prompts{flex-wrap:nowrap;overflow-x:auto;padding-bottom:4px;scrollbar-width:none}
  .quick-prompts::-webkit-scrollbar,.browse-categories::-webkit-scrollbar{display:none}
  .quick-prompts button{flex:0 0 auto;min-height:44px;padding:0 14px}
  .browse-categories{flex-wrap:nowrap;overflow-x:auto;padding:14px 0 5px;scrollbar-width:none}
  .browse-label{position:sticky;left:0;z-index:2;align-self:stretch;display:flex;align-items:center;padding-right:7px;background:var(--cream)}
  .browse-categories button{flex:0 0 auto;min-height:44px;padding:0 13px;font-size:10px}
  .results-actions{gap:10px}
  .results-actions select,.compact-button,.filter-chip{min-height:44px}
  .resource-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
  .source-link,.compare-button,.save-button,.details-button{width:100%;min-height:44px}
  .compare-dock .primary-button{min-height:44px}
}

/* Mobile card composition fix */
@media(max-width:680px){
  .resource-row{
    display:grid;
    grid-template-columns:minmax(0,1fr);
    gap:16px;
    margin:0;
    padding:22px 0;
  }
  .resource-row.featured-result{
    margin:6px 0 0;
    padding:18px 14px;
  }
  .resource-layout{
    width:100%;
    grid-template-columns:42px minmax(0,1fr);
    gap:12px;
  }
  .resource-main{
    min-width:0;
    width:100%;
  }
  .resource-row h3{
    font-size:21px;
    line-height:1.12;
    overflow-wrap:normal;
    word-break:normal;
  }
  .resource-description{
    max-width:none;
    font-size:13px;
    line-height:1.5;
    overflow-wrap:break-word;
  }
  .resource-kicker{
    align-items:flex-start;
  }
  .resource-side{
    width:100%;
    min-width:0;
    align-items:stretch;
  }
  .resource-actions{
    width:100%;
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
  .resource-metrics{
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
  .metric{
    min-width:0;
  }
  .resource-details{
    width:100%;
    min-width:0;
  }
  .retailer-row{
    grid-template-columns:minmax(0,1fr) auto;
  }
  .retailer-row>div:first-child{
    min-width:0;
  }
  .compare-dock{
    left:10px;
    right:10px;
    width:auto;
    transform:none;
    bottom:max(10px,env(safe-area-inset-bottom));
  }
}

/* Result alignment polish */
.result-visual{position:relative}
.visual-rank{position:absolute;top:8px;left:8px;line-height:1}
.resource-kicker{min-height:23px;align-items:center}
.resource-metrics{align-items:stretch}
.metric{display:grid;grid-template-rows:auto 1fr;align-content:start;gap:3px}
.metric-label{line-height:1.2}
.metric-value{line-height:1.3}
.compare-dock{align-items:center}
.compare-dock>div{align-content:center}
@media(max-width:680px){
  .result-visual{align-self:start}
  .visual-rank{top:7px;left:7px}
  .visual-glyph{margin-top:auto}
  .resource-kicker{min-height:0;align-items:center;row-gap:6px}
  .resource-metrics{gap:12px 14px}
  .metric{padding-right:6px}
  .compare-dock{min-height:64px;padding:10px 10px 10px 14px;gap:10px}
  .compare-dock>div{min-width:0}
  .compare-dock span{line-height:1.3}
  .compare-dock .primary-button{flex:0 0 auto;min-width:104px}
}

/* Mobile alignment convergence */
.result-visual{
  grid-template-rows:auto 1fr;
  place-items:stretch;
  padding:8px;
}
.visual-rank{
  position:static;
  justify-self:start;
  align-self:start;
  min-width:18px;
  font-variant-numeric:tabular-nums;
}
.visual-glyph{
  align-self:center;
  justify-self:center;
  margin:0;
  transform:translateY(-1px);
}
.resource-metrics{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(92px,max-content));
  column-gap:18px;
  row-gap:10px;
}
.metric{
  min-width:0;
  align-content:start;
}
.metric-label,.metric-value{
  display:block;
}
.compare-dock{
  min-height:64px;
}
.compare-dock>div{
  min-width:0;
}
.compare-dock strong,.compare-dock span{
  display:block;
}
.compare-dock .primary-button{
  flex:0 0 auto;
  white-space:nowrap;
}
@media(max-width:680px){
  .resource-layout{
    grid-template-columns:44px minmax(0,1fr);
    align-items:start;
  }
  .result-visual{
    width:44px;
    height:62px;
    padding:7px 6px 6px;
    border-radius:12px;
  }
  .visual-rank{
    font-size:9px;
    line-height:1;
  }
  .visual-glyph{
    font-size:22px;
    line-height:1;
    transform:none;
  }
  .resource-metrics{
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:12px 14px;
  }
  .metric{
    padding-right:0;
  }
  .metric-label{
    min-height:22px;
    line-height:1.2;
  }
  .metric-value{
    line-height:1.25;
  }
  .compare-dock{
    display:grid;
    grid-template-columns:minmax(0,1fr) auto;
    align-items:center;
    min-height:66px;
    padding:10px 10px 10px 14px;
    gap:10px;
  }
  .compare-dock>div{
    align-content:center;
  }
  .compare-dock strong{
    font-size:12px;
    line-height:1.2;
  }
  .compare-dock span{
    margin-top:3px;
    line-height:1.25;
  }
  .compare-dock .primary-button{
    min-width:112px;
    min-height:44px;
    padding:0 14px;
  }
}

/* Mobile comparison usability */
@media(max-width:680px){
  .comparison-section{padding-bottom:110px}
  .comparison-header{gap:12px}
  .comparison-scroll{
    position:relative;margin-left:-16px;margin-right:-16px;border-left:0;border-right:0;border-radius:0;
    overscroll-behavior-inline:contain;scrollbar-width:thin;scroll-snap-type:x proximity
  }
  .comparison-table{min-width:680px;font-size:12px}
  .comparison-table th,.comparison-table td{padding:13px 14px;line-height:1.35}
  .comparison-table thead th:first-child,.comparison-table tbody th{
    position:sticky;left:0;z-index:2;width:118px;min-width:118px;max-width:118px;
    background:var(--cream);box-shadow:1px 0 0 var(--line)
  }
  .comparison-table thead th:first-child{z-index:3;background:#f8faf8}
  .comparison-table thead th:not(:first-child),.comparison-table td{min-width:220px;scroll-snap-align:start}
  .comparison-table thead th{white-space:normal;overflow-wrap:anywhere}
}


/* UX foundation: visual resources use imagery as decision support, not decoration. */
.result-visual.has-image{
  width:180px;
  height:auto;
  aspect-ratio:16/9;
  border-radius:16px;
  overflow:hidden;
  align-self:start;
}
.result-visual.has-image img{width:100%;height:100%;object-fit:cover;display:block}
@media(max-width:680px){
  .resource-layout:has(.result-visual.has-image){grid-template-columns:minmax(0,1fr)}
  .result-visual.has-image{width:100%;height:auto;aspect-ratio:16/9}
}


/* Production mobile viewport containment */
@media(max-width:680px){
  html,body{width:100%;max-width:100%;overflow-x:hidden}
  main,.search-hero,.results-section,.comparison-section,.system-note{width:100%;max-width:100%;min-width:0}
  .hero-copy,h1,.hero-copy>p:last-child,.search-shell,.quick-prompts,.browse-categories,.results-topbar,.results-actions{max-width:100%;min-width:0}
  h1{font-size:clamp(40px,12vw,50px);overflow-wrap:break-word}
  .search-shell{width:100%}
  .search-shell input{width:100%;max-width:100%}
  .quick-prompts,.browse-categories{width:100%}
  .results-actions select{min-width:0;max-width:100%}
  .compare-dock{left:10px;right:10px;width:auto;max-width:calc(100vw - 20px);transform:none}
}

/* Source identity: readable attribution without unlicensed brand artwork. */
.resource-layout{grid-template-columns:64px minmax(0,1fr)}
.result-visual.source-tile{width:64px;height:72px;background:#e8f1ea;border-color:#cbded0}
.visual-monogram{align-self:center;margin:auto 0;color:var(--forest);font-size:22px;font-weight:800;line-height:1;letter-spacing:-.05em}
.resource-kicker{align-items:center;gap:10px;margin-bottom:10px}
.source-identity{display:inline-flex;flex-direction:column;align-items:flex-start;gap:2px;max-width:100%;min-width:0}
.source-identity .source-name{color:var(--forest);font-size:15px;font-weight:780;line-height:1.15;letter-spacing:-.02em;text-transform:none;overflow-wrap:anywhere}
.source-context{color:#62776a;font-size:10px;font-weight:600;line-height:1.3;overflow-wrap:anywhere}
.result-visual.has-image{position:relative}
.result-visual.has-image .visual-fallback{position:absolute;inset:0;display:grid;place-items:center;color:var(--forest);font-size:30px;font-weight:800}
.result-visual.has-image img{position:absolute;inset:0;z-index:1}
.result-visual.has-image .visual-rank{position:relative;z-index:2;padding:3px 5px;border-radius:5px;background:rgba(255,255,255,.88)}
@media(max-width:680px){
  .resource-layout{grid-template-columns:54px minmax(0,1fr)}
  .result-visual.source-tile{width:54px;height:64px}
  .visual-monogram{font-size:19px}
  .source-identity .source-name{font-size:14px}
}
.source-logo{width:28px;height:28px;object-fit:contain;flex:0 0 28px;border-radius:7px;background:#fff}
.source-text-mark{display:inline-flex;align-items:center;justify-content:center;min-height:28px;padding:5px 9px;border:1px solid rgba(29,74,54,.16);border-radius:8px;background:#f5f8f5;color:var(--forest);font-size:12px;font-weight:760;line-height:1.1;white-space:nowrap}
.source-identity{flex-direction:row;align-items:center;gap:9px}
.source-identity-copy{display:flex;flex-direction:column;gap:1px;min-width:0}
.result-visual.has-image.type-video img{object-fit:contain;background:#000}

/* Release convergence: identity supports the answer; it is not a decorative card rail. */
.resource-layout{grid-template-columns:auto minmax(0,1fr);gap:24px;align-items:start}
.result-visual{overflow:hidden;border-radius:16px;background:#f3f1eb;padding:0;display:block;flex-shrink:0}
.result-visual:after{display:none}
.result-visual img{display:block;width:100%;height:100%;object-fit:cover;position:static}
.result-visual--landscape{width:180px;height:auto!important;aspect-ratio:16/9}
.result-visual--medium{width:120px;height:auto!important;aspect-ratio:4/3}
.source-logo{width:24px;height:24px;object-fit:contain;flex:0 0 24px;border-radius:6px;background:#fff}
.source-identity{display:inline-flex;flex-direction:row;align-items:center;gap:8px;max-width:100%;min-width:0}
.source-identity-copy{display:flex;flex-direction:column;gap:2px;min-width:0}
.source-identity .source-name{font-size:13px;font-weight:760;line-height:1.2}
.source-context{font-size:10px;line-height:1.25}
.resource-details[hidden]{display:none!important}
@media(max-width:720px){
  .resource-layout{grid-template-columns:1fr;gap:16px}
  .result-visual--landscape,.result-visual--medium{width:100%;height:auto!important;aspect-ratio:16/9}
}
.compare-dock[hidden]{display:none!important}


/* Product visual convergence: governed imagery and comparison data are decision support. */
.resource-row{align-items:start}
.resource-layout:has(.result-visual.has-image){grid-template-columns:minmax(180px,220px) minmax(0,1fr);gap:26px}
.resource-row.featured-result .resource-layout:has(.result-visual.has-image){grid-template-columns:minmax(240px,310px) minmax(0,1fr)}
.result-visual.has-image{position:relative;width:100%;height:auto!important;aspect-ratio:4/3;border-radius:18px;margin:0;background:#edf2ee;box-shadow:0 12px 30px rgba(26,55,42,.10)}
.result-visual--landscape.has-image{aspect-ratio:16/10}
.result-visual.has-image img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}
.result-visual-caption{position:absolute;z-index:2;left:10px;bottom:10px;max-width:calc(100% - 20px);padding:5px 8px;border:1px solid rgba(255,255,255,.56);border-radius:999px;background:rgba(255,255,255,.90);backdrop-filter:blur(10px);color:var(--forest);font-size:10px;font-weight:760;line-height:1.1;box-shadow:0 4px 16px rgba(20,45,33,.08)}
.resource-metrics{display:grid;grid-template-columns:repeat(auto-fit,minmax(112px,1fr));gap:8px;margin:0 0 16px}
.metric{min-width:0;padding:10px 11px;border:1px solid rgba(34,73,53,.09);border-radius:12px;background:rgba(248,250,248,.88)}
.metric-label{font-size:8px;line-height:1.2}
.metric-value{font-size:13px;line-height:1.3;overflow-wrap:anywhere}
.featured-result .metric{background:rgba(255,255,255,.72)}
@media(max-width:900px){
  .resource-layout:has(.result-visual.has-image),
  .resource-row.featured-result .resource-layout:has(.result-visual.has-image){grid-template-columns:minmax(150px,190px) minmax(0,1fr)}
}
@media(max-width:720px){
  .resource-layout:has(.result-visual.has-image),
  .resource-row.featured-result .resource-layout:has(.result-visual.has-image){grid-template-columns:1fr;gap:16px}
  .result-visual.has-image,.result-visual--landscape.has-image{width:100%;aspect-ratio:16/9}
  .resource-metrics{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
}
