/* GoUmbrella web storefront. Tokens from the design canvas; mobile first. */
:root {
  --brand: #0B5D45; --brand-dark: #073F2F; --brand-tint: #E3F1EA;
  --sun: #FFC93C; --sun-ink: #2A1F00; --sun-soft: #FFF4D6; --sun-soft-ink: #5A4A1A;
  --ground: #F4F6F3; --surface: #FFFFFF; --muted-bg: #EEF2EE;
  --ink: #15201B; --ink-soft: #3A4640; --ink-muted: #5A6660;
  --line: #E2E8E4; --line-strong: #CBD5CF;
  --info: #1D3F8F; --info-bg: #E6ECFA; --danger: #B3261E; --danger-bg: #FDE8E4;
  --r-sm: 10px; --r-md: 12px; --r-lg: 16px;
  --shadow: 0 1px 2px rgba(21, 32, 27, .06);
  --font: 'Plus Jakarta Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--ground); color: var(--ink); font: 15px/1.5 var(--font); }
img { max-width: 100%; display: block; }
a { color: var(--brand); text-decoration: none; }
a:hover { color: var(--brand-dark); text-decoration: underline; }
h1, h2, h3 { line-height: 1.25; margin: 0 0 .5rem; letter-spacing: -.01em; }
h1 { font-size: 1.6rem; font-weight: 800; }
h2 { font-size: 1.15rem; font-weight: 800; }
p { margin: 0 0 .75rem; }
.wrap { max-width: 1180px; margin: 0 auto; padding: 0 16px; }
.muted { color: var(--ink-muted); }
.small { font-size: .85rem; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--surface); padding: 8px 12px; border-radius: var(--r-sm); z-index: 10; }
.skip:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--sun); outline-offset: 2px; }

/* Header */
.site-header { background: var(--brand); color: #fff; }
.site-header a { color: #fff; }
.header-row { display: flex; align-items: center; gap: 12px; padding: 12px 0; flex-wrap: wrap; }
.logo { display: inline-flex; align-items: center; gap: 6px; font-weight: 800; font-size: 1.35rem; letter-spacing: -.02em; }
.logo:hover { text-decoration: none; }
.logo span { color: var(--sun); }
.logo svg { flex-shrink: 0; }
.header-actions { margin-left: auto; display: flex; align-items: center; gap: 4px; }
.icon-link { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 10px; border-radius: var(--r-md); font-weight: 600; }
.icon-link:hover { background: rgba(255,255,255,.12); text-decoration: none; }
.badge-count { background: var(--sun); color: var(--sun-ink); font-size: .72rem; font-weight: 800; border-radius: 10px; padding: 1px 7px; }
.search { order: 3; flex-basis: 100%; display: flex; background: var(--surface); border-radius: var(--r-md); overflow: hidden; }
.search input { flex: 1; min-width: 0; border: 0; padding: 0 14px; height: 46px; font: inherit; color: var(--ink); }
.search input:focus { outline: none; }
.search:focus-within { outline: 3px solid var(--sun); }
.search button { border: 0; background: var(--sun); color: var(--sun-ink); padding: 0 16px; font: inherit; font-weight: 700; cursor: pointer; }
.location-bar { background: var(--brand-dark); font-size: .9rem; }
.location-bar .wrap { display: flex; align-items: center; gap: 8px; min-height: 40px; flex-wrap: wrap; }
.location-bar button.linkish { color: var(--sun); }
@media (min-width: 820px) {
  .search { order: 0; flex-basis: auto; flex: 1; max-width: 560px; margin-left: 24px; }
}

/* Service tabs (Dawai live, the rest coming soon) */
.services { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; padding: 0 0 14px; }
.service { position: relative; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 10px 4px; border-radius: 14px; background: rgba(255,255,255,.14); color: #fff; font-weight: 700; font-size: .85rem; }
.service.active { background: var(--surface); color: var(--brand); }
.service:hover { text-decoration: none; background: rgba(255,255,255,.22); }
.service.active:hover { background: var(--surface); }
.soon { position: absolute; top: -7px; right: 4px; background: var(--sun); color: var(--sun-ink); font-size: .62rem; font-weight: 800; padding: 1px 6px; border-radius: 8px; letter-spacing: .03em; }

/* Layout bits */
main { padding: 20px 0 48px; min-height: 60vh; }
.section { margin-top: 28px; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.card { background: var(--surface); border-radius: var(--r-lg); padding: 16px; box-shadow: var(--shadow); }
.stack > * + * { margin-top: 12px; }
.breadcrumbs { font-size: .85rem; color: var(--ink-muted); margin-bottom: 12px; }
.breadcrumbs a { color: var(--ink-muted); }
.notice { display: flex; gap: 12px; align-items: center; background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--r-lg); padding: 12px 14px; }
.notice.info { background: var(--info-bg); border-color: transparent; color: var(--info); }
.notice.warn { background: var(--sun-soft); border-color: transparent; color: var(--sun-soft-ink); }
.notice.error { background: var(--danger-bg); border-color: transparent; color: var(--danger); }
.flash { margin-bottom: 16px; }
.empty { text-align: center; padding: 40px 16px; color: var(--ink-muted); }

/* Prescription banner */
.rx-banner { display: flex; align-items: center; gap: 14px; background: var(--sun-soft); border-radius: var(--r-lg); padding: 16px; }
.rx-banner .tile { width: 52px; height: 52px; border-radius: 14px; background: var(--sun); color: var(--sun-ink); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.rx-banner p { margin: 0; color: var(--sun-soft-ink); font-size: .9rem; }

/* Category grid */
.cat-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
@media (min-width: 820px) { .cat-grid { grid-template-columns: repeat(8, minmax(0, 1fr)); } }
.cat { display: flex; flex-direction: column; align-items: center; gap: 6px; color: var(--ink); text-align: center; font-size: .8rem; font-weight: 600; line-height: 1.25; }
.cat:hover { text-decoration: none; color: var(--brand); }
.cat .tile { width: 100%; aspect-ratio: 1; border-radius: var(--r-lg); display: flex; align-items: center; justify-content: center; font-size: 1.2rem; font-weight: 800; }

/* Product grid and card */
.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (min-width: 640px) { .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 980px) { .grid { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
.pcard { background: var(--surface); border-radius: var(--r-lg); padding: 10px; display: flex; flex-direction: column; gap: 6px; box-shadow: var(--shadow); }
.pcard a.title { color: var(--ink); font-weight: 700; font-size: .92rem; line-height: 1.3; }
.pcard .pack { font-size: .78rem; color: var(--ink-muted); }
.pcard .foot { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.thumb { position: relative; aspect-ratio: 4 / 3; border-radius: var(--r-md); background: var(--muted-bg); display: flex; align-items: center; justify-content: center; overflow: hidden; color: var(--ink-muted); }
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.price { font-weight: 800; }
.mrp { color: var(--ink-muted); text-decoration: line-through; font-size: .85rem; margin-left: 6px; }
.tag { display: inline-block; font-size: .68rem; font-weight: 800; letter-spacing: .03em; padding: 2px 7px; border-radius: 8px; }
.tag.rx { background: var(--info); color: #fff; }
.tag.out { background: var(--danger-bg); color: var(--danger); }
.thumb .tag { position: absolute; top: 6px; left: 6px; }
.scroller { display: flex; gap: 12px; overflow-x: auto; padding-bottom: 6px; scroll-snap-type: x mandatory; }
.scroller .pcard { flex: 0 0 160px; scroll-snap-align: start; }

/* Buttons and forms */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 18px; border-radius: var(--r-md); border: 1.5px solid transparent; font: inherit; font-weight: 700; cursor: pointer; background: var(--brand); color: #fff; text-decoration: none; }
.btn:hover { background: var(--brand-dark); color: #fff; text-decoration: none; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }
.btn.block { width: 100%; }
.btn.outline { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn.outline:hover { background: var(--muted-bg); color: var(--ink); }
.btn.ghost { background: transparent; color: var(--brand); }
.btn.ghost:hover { background: var(--brand-tint); }
.btn.dark { background: var(--ink); }
.btn.danger { background: transparent; color: var(--danger); border-color: var(--danger); }
.btn.sm { min-height: 36px; padding: 0 12px; font-size: .88rem; }
button.linkish { background: none; border: 0; padding: 0; font: inherit; font-weight: 700; color: var(--brand); cursor: pointer; text-decoration: underline; }
.qty { display: inline-flex; align-items: center; background: var(--brand); border-radius: var(--r-sm); color: #fff; }
.qty button { width: 40px; height: 36px; border: 0; background: none; color: #fff; font-size: 1.15rem; font-weight: 700; cursor: pointer; }
.qty span { min-width: 22px; text-align: center; font-weight: 800; }
.add { width: 44px; height: 36px; border-radius: var(--r-sm); border: 0; background: var(--brand); color: #fff; font-size: 1.3rem; font-weight: 700; cursor: pointer; }
label.field { display: block; font-size: .85rem; font-weight: 600; color: var(--ink-soft); }
label.field > span { display: block; margin-bottom: 6px; }
.input, select.input, textarea.input { width: 100%; min-height: 46px; border: 1.5px solid var(--line-strong); border-radius: var(--r-md); padding: 10px 14px; font: inherit; color: var(--ink); background: var(--surface); }
.input:focus { border-color: var(--brand); outline: none; box-shadow: 0 0 0 3px rgba(11,93,69,.15); }
.error-text { color: var(--danger); font-size: .85rem; font-weight: 600; margin-top: 4px; }
.row { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; }
.row > .grow { flex: 1; min-width: 160px; }
.choice { display: flex; gap: 12px; align-items: flex-start; padding: 12px; border: 1.5px solid var(--line-strong); border-radius: var(--r-md); cursor: pointer; }
.choice:has(input:checked) { border-color: var(--brand); background: var(--brand-tint); }
.choice input { margin-top: 4px; accent-color: var(--brand); width: 18px; height: 18px; }

/* Two-column pages */
.two-col { display: grid; gap: 20px; }
@media (min-width: 900px) { .two-col { grid-template-columns: minmax(0, 1fr) 360px; align-items: start; } .sticky { position: sticky; top: 16px; } }
.product-hero { display: grid; gap: 20px; }
@media (min-width: 820px) { .product-hero { grid-template-columns: 420px minmax(0, 1fr); } }
.facts { width: 100%; border-collapse: collapse; }
.facts th, .facts td { text-align: left; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: .92rem; }
.facts th { color: var(--ink-muted); font-weight: 600; width: 40%; }
.totals div { display: flex; justify-content: space-between; padding: 4px 0; }
.totals .grand { font-weight: 800; font-size: 1.05rem; border-top: 1px solid var(--line); margin-top: 6px; padding-top: 10px; }
.totals .saving { color: var(--brand); font-weight: 700; }
.line { display: flex; gap: 12px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); }
.line:last-child { border-bottom: 0; }
.line .thumb { width: 64px; flex-shrink: 0; aspect-ratio: 1; }
.line .info { flex: 1; min-width: 0; }

/* Order tracking */
.tracker { display: flex; align-items: center; margin: 14px 0 6px; }
.tracker .dot { width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--line-strong); background: var(--surface); flex-shrink: 0; }
.tracker .dot.done { background: var(--brand); border-color: var(--brand); }
.tracker .bar { flex: 1; height: 3px; background: var(--line); }
.tracker .bar.done { background: var(--brand); }
.status { display: inline-block; padding: 3px 10px; border-radius: 12px; font-size: .8rem; font-weight: 700; background: var(--sun-soft); color: #7A5300; }
.status.delivered { background: var(--brand-tint); color: var(--brand); }
.status.cancelled { background: var(--danger-bg); color: #9A3412; }
.status.rx_review { background: var(--info-bg); color: var(--info); }
.code-box { text-align: center; background: var(--sun-soft); border-radius: var(--r-md); padding: 12px; }
.code-box strong { display: block; font-size: 2rem; letter-spacing: .4em; color: var(--sun-ink); }
.stars { display: inline-flex; gap: 2px; }
.stars button { background: none; border: 0; font-size: 1.8rem; line-height: 1; cursor: pointer; color: var(--line-strong); padding: 2px; min-width: 40px; min-height: 40px; }
.stars button.on { color: var(--sun); }

/* Footer */
.site-footer { background: var(--ink); color: #C9D2CD; padding: 32px 0; font-size: .9rem; }
.site-footer a { color: #fff; }
.footer-grid { display: grid; gap: 20px; }
@media (min-width: 720px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr; } }
.site-footer h3 { color: #fff; font-size: .95rem; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin: 6px 0; }

.loading-bar { position: fixed; top: 0; left: 0; right: 0; height: 3px; background: var(--sun); z-index: 50; }

[x-cloak] { display: none !important; }
