/* ============================================================
   MIEKO PEARL JEWELRY — storefront styles
   Mobile-first. Breakpoints: 560 / 768 / 1024 / 1280
   ============================================================ */

:root {
  --ink: #16130f;
  --ink-2: #3a342e;
  --muted: #857b72;
  --muted-2: #a89e94;
  --line: #e7e0d7;
  --line-2: #f0ebe4;
  --bg: #fbf9f6;
  --surface: #ffffff;
  --cream: #f4efe8;
  --accent: #1f4e5a;
  --accent-soft: #eaf1f2;
  --gold: #a8875a;
  --ok: #2f6b4f;
  --ok-soft: #e8f2ec;
  --warn: #8a6516;
  --warn-soft: #fbf1dc;
  --bad: #9c3838;
  --bad-soft: #fbeaea;
  --info: #24566b;
  --info-soft: #e8f1f4;

  --radius: 4px;
  --radius-lg: 10px;
  --shadow-sm: 0 1px 2px rgba(22, 19, 15, .05);
  --shadow: 0 4px 20px rgba(22, 19, 15, .07);
  --shadow-lg: 0 18px 50px rgba(22, 19, 15, .12);

  --font-display: "Cormorant Garamond", "Noto Serif Thai", Georgia, "Times New Roman", serif;
  --font-body: "Inter", "Noto Sans Thai", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --wrap: 1240px;
  --header-h: 60px;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.65;
  color: var(--ink-2);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 { font-family: var(--font-display); color: var(--ink); font-weight: 500; line-height: 1.2; margin: 0 0 .5em; letter-spacing: .005em; }
h1 { font-size: clamp(1.9rem, 6vw, 3.1rem); }
h2 { font-size: clamp(1.5rem, 4.6vw, 2.3rem); }
h3 { font-size: clamp(1.15rem, 3.2vw, 1.45rem); }
p { margin: 0 0 1em; }
hr { border: 0; border-top: 1px solid var(--line); margin: 2rem 0; }

/* Author `display` rules (e.g. .sum-row{display:flex}) outrank the UA rule for
   [hidden], so summary rows toggled from JS need this to actually disappear. */
[hidden] { display: none !important; }

::selection { background: var(--accent); color: #fff; }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 2px; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 16px; }
@media (min-width: 768px) { .wrap { padding: 0 28px; } }
@media (min-width: 1024px) { .wrap { padding: 0 40px; } }

.eyebrow {
  font-size: .68rem; letter-spacing: .22em; text-transform: uppercase;
  color: var(--muted); font-weight: 500; margin: 0 0 .8rem;
}
.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;
}
.muted { color: var(--muted); }
.small { font-size: .84rem; }
.tiny { font-size: .76rem; }
.center { text-align: center; }
.nowrap { white-space: nowrap; }
.stack > * + * { margin-top: .75rem; }

/* ── Announcement bar ─────────────────────────────────────── */
.announce {
  background: var(--ink); color: #f3efe9;
  font-size: .74rem; letter-spacing: .1em; text-transform: uppercase;
  text-align: center; padding: 8px 12px;
}
.announce a { text-decoration: underline; text-underline-offset: 3px; }

/* ── Header ───────────────────────────────────────────────── */
.header {
  position: sticky; top: 0; z-index: 60;
  background: rgba(251, 249, 246, .93);
  backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  height: var(--header-h);
  display: flex; align-items: center; gap: 10px;
}
.brand { display: flex; align-items: center; gap: 10px; flex: 0 0 auto; }
.brand img { height: 26px; width: auto; }
@media (min-width: 768px) { .brand img { height: 32px; } }

.nav-desktop { display: none; }
@media (min-width: 1024px) {
  :root { --header-h: 72px; }
  .nav-desktop {
    display: flex; gap: 30px; margin-left: 42px; flex: 1 1 auto;
  }
  .nav-desktop a {
    font-size: .82rem; letter-spacing: .12em; text-transform: uppercase;
    color: var(--ink-2); padding: 6px 0; position: relative;
  }
  .nav-desktop a::after {
    content: ''; position: absolute; left: 0; right: 100%; bottom: 0;
    height: 1px; background: var(--ink); transition: right .25s ease;
  }
  .nav-desktop a:hover::after, .nav-desktop a[aria-current="page"]::after { right: 0; }
}
.header-actions { display: flex; align-items: center; gap: 2px; margin-left: auto; }
.icon-btn {
  background: none; border: 0; padding: 9px; cursor: pointer;
  display: grid; place-items: center; border-radius: var(--radius);
  color: var(--ink); position: relative; line-height: 0;
}
.icon-btn:hover { background: var(--cream); }
.icon-btn svg { width: 21px; height: 21px; }
.cart-count {
  position: absolute; top: 2px; right: 2px;
  min-width: 17px; height: 17px; padding: 0 4px;
  background: var(--accent); color: #fff;
  border-radius: 99px; font-size: .62rem; font-weight: 600;
  display: grid; place-items: center; line-height: 1;
}
@media (min-width: 1024px) { .menu-toggle { display: none; } }

/* ── Mobile drawer ────────────────────────────────────────── */
.drawer-backdrop {
  position: fixed; inset: 0; background: rgba(22, 19, 15, .45);
  opacity: 0; pointer-events: none; transition: opacity .25s ease; z-index: 90;
}
.drawer-backdrop.open { opacity: 1; pointer-events: auto; }
.drawer {
  position: fixed; top: 0; bottom: 0; left: 0; width: min(85vw, 340px);
  background: var(--bg); z-index: 95; padding: 18px 20px 32px;
  transform: translateX(-101%); transition: transform .28s cubic-bezier(.4, 0, .2, 1);
  overflow-y: auto; display: flex; flex-direction: column;
}
.drawer.open { transform: none; }
.drawer-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 22px; }
.drawer nav { display: flex; flex-direction: column; }
.drawer nav a {
  padding: 13px 0; border-bottom: 1px solid var(--line-2);
  font-size: 1rem; display: flex; justify-content: space-between; align-items: center;
}
.drawer-foot { margin-top: auto; padding-top: 26px; }
.drawer-foot .social { display: flex; gap: 10px; margin-top: 12px; }

/* ── Buttons ──────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 24px; border: 1px solid var(--ink); background: var(--ink); color: #fff;
  border-radius: var(--radius); cursor: pointer; font-size: .84rem;
  letter-spacing: .1em; text-transform: uppercase; font-weight: 500;
  transition: background .2s, color .2s, border-color .2s, opacity .2s;
  text-align: center; min-height: 46px;
}
.btn:hover { background: var(--ink-2); border-color: var(--ink-2); }
.btn:disabled, .btn[aria-disabled="true"] { opacity: .45; cursor: not-allowed; }
.btn-outline { background: transparent; color: var(--ink); }
.btn-outline:hover { background: var(--ink); color: #fff; }
.btn-accent { background: var(--accent); border-color: var(--accent); }
.btn-accent:hover { background: #17414c; border-color: #17414c; }
.btn-ghost { background: transparent; border-color: var(--line); color: var(--ink-2); }
.btn-ghost:hover { background: var(--cream); border-color: var(--line); color: var(--ink); }
.btn-sm { padding: 8px 14px; min-height: 36px; font-size: .74rem; }
.btn-lg { padding: 16px 30px; min-height: 54px; }
.btn-block { display: flex; width: 100%; }
.btn-danger { background: var(--bad); border-color: var(--bad); }
.btn-danger:hover { background: #832f2f; border-color: #832f2f; }

.link-underline {
  border-bottom: 1px solid currentColor; padding-bottom: 1px;
  font-size: .84rem; letter-spacing: .06em;
}

/* ── Hero ─────────────────────────────────────────────────── */
.hero { position: relative; background: var(--cream); overflow: hidden; }
.hero-slide { display: none; }
.hero-slide.active { display: block; }
.hero-grid { display: grid; grid-template-columns: 1fr; }
.hero-media { position: relative; aspect-ratio: 4 / 3; background: #ece5db; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; }
.hero-body { padding: 30px 16px 38px; }
.hero-body h1 { white-space: pre-line; margin-bottom: .35em; }
.hero-body p { color: var(--ink-2); max-width: 46ch; margin-bottom: 1.6em; }
@media (min-width: 768px) {
  .hero-media { aspect-ratio: 16 / 10; }
  .hero-body { padding: 44px 28px 52px; }
}
@media (min-width: 1024px) {
  .hero-grid { grid-template-columns: 1fr 1.05fr; align-items: stretch; min-height: 560px; }
  .hero-media { aspect-ratio: auto; order: 2; height: clamp(520px, 72vh, 700px); }
  .hero-body { order: 1; padding: 72px 56px 72px 40px; display: flex; flex-direction: column; justify-content: center; }
}
@media (min-width: 1280px) { .hero-body { padding-left: max(40px, calc((100vw - var(--wrap)) / 2 + 40px)); } }

.hero-dots {
  position: absolute; left: 16px; bottom: 14px; display: flex; gap: 8px; z-index: 3;
}
@media (min-width: 1024px) { .hero-dots { left: 40px; bottom: 30px; } }
.hero-dots button {
  width: 30px; height: 3px; padding: 0; border: 0; cursor: pointer;
  background: rgba(22, 19, 15, .2); border-radius: 2px; transition: background .2s;
}
.hero-dots button[aria-selected="true"] { background: var(--ink); }

/* ── Sections ─────────────────────────────────────────────── */
.section { padding: 48px 0; }
@media (min-width: 768px) { .section { padding: 68px 0; } }
@media (min-width: 1024px) { .section { padding: 84px 0; } }
.section-head { margin-bottom: 26px; }
.section-head.center { text-align: center; }
.section-head p { color: var(--muted); max-width: 60ch; }
.section-head.center p { margin-left: auto; margin-right: auto; }
.section-alt { background: var(--cream); }

/* ── Marquee of trust badges ──────────────────────────────── */
.badges {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px;
  background: var(--line); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
}
@media (min-width: 768px) { .badges { grid-template-columns: repeat(4, 1fr); } }
.badge-cell { background: var(--bg); padding: 20px 14px; text-align: center; }
.badge-cell svg { width: 22px; height: 22px; margin: 0 auto 8px; color: var(--accent); }
.badge-cell strong { display: block; font-size: .84rem; color: var(--ink); font-weight: 600; }
.badge-cell span { font-size: .74rem; color: var(--muted); }

/* ── Product grid ─────────────────────────────────────────── */
.grid-products {
  display: grid; gap: 18px 12px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
@media (min-width: 640px) { .grid-products { gap: 26px 18px; grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1024px) { .grid-products { gap: 36px 24px; grid-template-columns: repeat(4, minmax(0, 1fr)); } }

.card { position: relative; display: flex; flex-direction: column; height: 100%; }
.card-media {
  position: relative; aspect-ratio: 1 / 1; overflow: hidden;
  background: var(--cream); border-radius: var(--radius);
}
.card-media img {
  width: 100%; height: 100%; object-fit: contain;
  transition: transform .6s cubic-bezier(.2, .6, .2, 1), opacity .3s;
}
.card:hover .card-media img { transform: scale(1.045); }
.card-media .alt-img { position: absolute; inset: 0; opacity: 0; }
.card:hover .alt-img { opacity: 1; }
.card-body { padding: 12px 2px 0; display: flex; flex-direction: column; flex: 1; }
.card-cat { font-size: .66rem; letter-spacing: .16em; text-transform: uppercase; color: var(--muted-2); margin-bottom: 4px; }
.card-title {
  font-family: var(--font-body); font-size: .88rem; line-height: 1.45;
  color: var(--ink); font-weight: 500; margin: 0 0 6px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.card-price { margin-top: auto; display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.price { font-size: .95rem; color: var(--ink); font-weight: 600; }
.price-was { font-size: .78rem; color: var(--muted-2); text-decoration: line-through; }
.card-link { position: absolute; inset: 0; z-index: 2; }

.tag {
  position: absolute; top: 8px; left: 8px; z-index: 3;
  background: var(--ink); color: #fff; font-size: .6rem; font-weight: 600;
  letter-spacing: .12em; text-transform: uppercase; padding: 4px 8px; border-radius: 2px;
}
.tag-sale { background: var(--bad); }
.tag-out { background: var(--muted); }

/* ── Category tiles ───────────────────────────────────────── */
.grid-cats { display: grid; gap: 14px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 640px) { .grid-cats { grid-template-columns: repeat(3, 1fr); gap: 20px; } }
/* Caption sits under the image, not over it — several product photos carry
   their own baked-in text along the bottom edge. */
.cat-tile { display: block; }
.cat-tile-media { overflow: hidden; border-radius: var(--radius); background: var(--cream); }
.cat-tile img { width: 100%; aspect-ratio: 4 / 3; object-fit: contain; transition: transform .6s cubic-bezier(.2, .6, .2, 1); }
@media (min-width: 640px) { .cat-tile img { aspect-ratio: 3 / 4; } }
.cat-tile:hover img { transform: scale(1.04); }
.cat-tile-body { padding: 14px 2px 0; }
.cat-tile-body h3 { margin-bottom: 1px; font-size: clamp(1.1rem, 3vw, 1.35rem); }
.cat-tile-body span { font-size: .68rem; color: var(--muted); letter-spacing: .16em; text-transform: uppercase; }

/* ── Breadcrumbs ──────────────────────────────────────────── */
.crumbs { font-size: .76rem; color: var(--muted); padding: 16px 0 4px; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.crumbs a:hover { color: var(--ink); }
.crumbs span { color: var(--muted-2); }

/* ── Product detail ───────────────────────────────────────── */
/* `minmax(0, 1fr)` + `min-width: 0` stop the horizontally-scrolling thumbnail
   strip from stretching its grid column past the viewport on phones. */
.pdp { display: grid; gap: 26px; padding: 8px 0 20px; grid-template-columns: minmax(0, 1fr); }
.pdp > * { min-width: 0; }
@media (min-width: 1024px) { .pdp { grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 56px; padding-top: 16px; align-items: start; } }

.gallery-main {
  position: relative; aspect-ratio: 1 / 1; background: var(--cream);
  border-radius: var(--radius); overflow: hidden;
}
.gallery-main img { width: 100%; height: 100%; object-fit: contain; }
.gallery-nav {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 38px; height: 38px; border-radius: 99px; border: 0;
  background: rgba(255, 255, 255, .9); color: var(--ink);
  display: grid; place-items: center; cursor: pointer; box-shadow: var(--shadow-sm);
}
.gallery-nav.prev { left: 8px; }
.gallery-nav.next { right: 8px; }
.gallery-nav svg { width: 16px; height: 16px; }
.gallery-counter {
  position: absolute; right: 10px; bottom: 10px; background: rgba(22,19,15,.6); color: #fff;
  font-size: .7rem; padding: 3px 9px; border-radius: 99px; letter-spacing: .05em;
}
.gallery-thumbs {
  display: grid; grid-auto-flow: column; grid-auto-columns: 62px; gap: 8px;
  overflow-x: auto; padding: 10px 2px 2px; scrollbar-width: thin;
  -webkit-overflow-scrolling: touch;
}
@media (min-width: 768px) { .gallery-thumbs { grid-auto-columns: 76px; } }
.gallery-thumbs button {
  padding: 0; border: 1px solid transparent; background: var(--cream);
  border-radius: 3px; overflow: hidden; cursor: pointer; aspect-ratio: 1/1;
}
.gallery-thumbs button[aria-selected="true"] { border-color: var(--ink); }
.gallery-thumbs img { width: 100%; height: 100%; object-fit: contain; }

.pdp-info h1 { font-size: clamp(1.5rem, 5vw, 2.15rem); margin-bottom: .25em; }
.pdp-sub { color: var(--muted); margin-bottom: 1.1rem; font-size: .92rem; }
.pdp-price { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 1.4rem; }
.pdp-price .price { font-size: 1.5rem; }
.pdp-price .price-was { font-size: 1rem; }
.pdp-save { font-size: .72rem; background: var(--bad-soft); color: var(--bad); padding: 3px 8px; border-radius: 2px; font-weight: 600; }

.opt-group { margin-bottom: 1.3rem; }
.opt-label { font-size: .78rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-bottom: 9px; display: block; }
.opt-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  border: 1px solid var(--line); background: var(--surface); color: var(--ink-2);
  padding: 9px 15px; border-radius: var(--radius); cursor: pointer; font-size: .84rem;
  transition: border-color .2s, background .2s, color .2s; min-height: 42px;
}
.chip:hover { border-color: var(--muted); }
.chip[aria-pressed="true"] { border-color: var(--ink); background: var(--ink); color: #fff; }
.chip:disabled { opacity: .4; cursor: not-allowed; text-decoration: line-through; }

.qty-row { display: flex; gap: 10px; align-items: stretch; margin-bottom: 14px; }
.qty {
  display: inline-flex; align-items: stretch; border: 1px solid var(--line);
  border-radius: var(--radius); background: var(--surface); flex: 0 0 auto;
}
.qty button { width: 42px; border: 0; background: none; cursor: pointer; font-size: 1.1rem; color: var(--ink); }
.qty button:hover { background: var(--cream); }
.qty input {
  width: 44px; border: 0; text-align: center; background: none;
  -moz-appearance: textfield; font-size: .95rem;
}
.qty input::-webkit-outer-spin-button, .qty input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.qty-row .btn { flex: 1; }

.pdp-meta { border-top: 1px solid var(--line); margin-top: 22px; padding-top: 18px; }
.acc { border-bottom: 1px solid var(--line); }
.acc summary {
  list-style: none; cursor: pointer; padding: 15px 0; display: flex;
  justify-content: space-between; align-items: center; gap: 12px;
  font-size: .88rem; font-weight: 500; color: var(--ink);
}
.acc summary::-webkit-details-marker { display: none; }
.acc summary::after { content: '+'; font-size: 1.15rem; color: var(--muted); line-height: 1; }
.acc[open] summary::after { content: '−'; }
.acc-body { padding: 0 0 18px; font-size: .9rem; color: var(--ink-2); }
.acc-body p:last-child { margin-bottom: 0; }

.spec-table { width: 100%; border-collapse: collapse; font-size: .86rem; }
.spec-table th, .spec-table td { text-align: left; padding: 8px 0; border-bottom: 1px solid var(--line-2); vertical-align: top; }
.spec-table th { color: var(--muted); font-weight: 400; width: 42%; }
.spec-table tr:last-child th, .spec-table tr:last-child td { border-bottom: 0; }

/* ── Filters bar ──────────────────────────────────────────── */
.filters {
  display: flex; gap: 8px; overflow-x: auto; padding: 4px 0 18px;
  -webkit-overflow-scrolling: touch; scrollbar-width: none;
}
.filters::-webkit-scrollbar { display: none; }
.filters a {
  flex: 0 0 auto; padding: 8px 16px; border: 1px solid var(--line);
  border-radius: 99px; font-size: .8rem; background: var(--surface); color: var(--ink-2);
  white-space: nowrap;
}
.filters a[aria-current="page"] { background: var(--ink); border-color: var(--ink); color: #fff; }

.toolbar { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding-bottom: 14px; flex-wrap: wrap; }
.toolbar .count { font-size: .82rem; color: var(--muted); }
select.sort {
  border: 1px solid var(--line); background: var(--surface); border-radius: var(--radius);
  padding: 9px 30px 9px 12px; font-size: .82rem; min-height: 40px;
  appearance: none;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M2 4.5 6 8.5 10 4.5' fill='none' stroke='%23857b72' stroke-width='1.4'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 10px center; background-size: 12px;
}

/* ── Forms ────────────────────────────────────────────────── */
.field { margin-bottom: 15px; }
.field label { display: block; font-size: .78rem; letter-spacing: .06em; color: var(--muted); margin-bottom: 6px; }
.field label .req { color: var(--bad); }
.input, .textarea, .select {
  width: 100%; padding: 12px 13px; border: 1px solid var(--line);
  border-radius: var(--radius); background: var(--surface); font-size: .95rem;
  min-height: 46px; transition: border-color .15s, box-shadow .15s;
}
.input:focus, .textarea:focus, .select:focus {
  outline: 0; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft);
}
.input[aria-invalid="true"], .textarea[aria-invalid="true"] { border-color: var(--bad); }
.textarea { min-height: 92px; resize: vertical; }
.select {
  appearance: none; padding-right: 34px;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M2 4.5 6 8.5 10 4.5' fill='none' stroke='%23857b72' stroke-width='1.4'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center; background-size: 12px;
}
.field-row { display: grid; gap: 0 12px; grid-template-columns: minmax(0, 1fr); }
.field-row > * { min-width: 0; }
@media (min-width: 560px) { .field-row.two { grid-template-columns: 1fr 1fr; } }
@media (min-width: 560px) { .field-row.three { grid-template-columns: 1fr 1fr 1fr; } }
.field-error { color: var(--bad); font-size: .78rem; margin-top: 5px; display: block; }
.hint { color: var(--muted); font-size: .78rem; margin-top: 5px; display: block; }

.check { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; font-size: .9rem; }
.check input { width: 18px; height: 18px; margin: 3px 0 0; flex: 0 0 auto; accent-color: var(--accent); }

.radio-card {
  display: flex; gap: 12px; align-items: flex-start; padding: 14px;
  border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface);
  cursor: pointer; margin-bottom: 10px; transition: border-color .2s, box-shadow .2s;
}
.radio-card:has(input:checked) { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent-soft); }
.radio-card input { width: 18px; height: 18px; margin: 2px 0 0; flex: 0 0 auto; accent-color: var(--accent); }
.radio-card .rc-body { flex: 1; min-width: 0; }
.radio-card strong { display: block; font-size: .92rem; color: var(--ink); font-weight: 600; }
.radio-card .rc-note { font-size: .8rem; color: var(--muted); }
.radio-card .rc-fee { font-size: .85rem; color: var(--ink); font-weight: 600; white-space: nowrap; }

/* ── Cart ─────────────────────────────────────────────────── */
.cart-layout { display: grid; gap: 26px; grid-template-columns: minmax(0, 1fr); }
.cart-layout > * { min-width: 0; }
@media (min-width: 1024px) { .cart-layout { grid-template-columns: minmax(0, 1fr) 370px; gap: 46px; align-items: start; } }

.cart-line {
  display: grid; grid-template-columns: 78px 1fr; gap: 14px;
  padding: 16px 0; border-bottom: 1px solid var(--line);
}
@media (min-width: 560px) { .cart-line { grid-template-columns: 96px 1fr auto; align-items: start; } }
.cart-line-media { border-radius: var(--radius); overflow: hidden; background: var(--cream); aspect-ratio: 1/1; }
.cart-line-media img { width: 100%; height: 100%; object-fit: cover; }
.cart-line h3 { font-family: var(--font-body); font-size: .92rem; font-weight: 500; margin: 0 0 3px; }
.cart-line .variant { font-size: .8rem; color: var(--muted); margin-bottom: 8px; }
.cart-line-actions { display: flex; align-items: center; gap: 12px; margin-top: 8px; flex-wrap: wrap; }
.cart-line-total { font-weight: 600; color: var(--ink); }
@media (min-width: 560px) { .cart-line-total { text-align: right; } }
.remove-btn { background: none; border: 0; padding: 0; color: var(--muted); font-size: .8rem; cursor: pointer; text-decoration: underline; text-underline-offset: 2px; }
.remove-btn:hover { color: var(--bad); }

.summary {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius-lg); padding: 20px; position: sticky; top: calc(var(--header-h) + 16px);
}
.summary h3 { font-size: 1.05rem; margin-bottom: 14px; }
.sum-row { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0; font-size: .9rem; }
.sum-row.total {
  border-top: 1px solid var(--line); margin-top: 10px; padding-top: 14px;
  font-size: 1.1rem; font-weight: 600; color: var(--ink);
}
.sum-row .discount-val { color: var(--ok); }
.promo-row { display: flex; gap: 8px; margin: 14px 0; }
.promo-row .input { flex: 1; min-height: 44px; }

.empty { text-align: center; padding: 56px 20px; }
.empty svg { width: 44px; height: 44px; color: var(--muted-2); margin: 0 auto 14px; }

/* ── Steps ────────────────────────────────────────────────── */
.steps { display: flex; gap: 6px; align-items: center; justify-content: center; margin: 6px 0 26px; flex-wrap: wrap; }
.step { display: flex; align-items: center; gap: 7px; font-size: .76rem; color: var(--muted-2); }
.step b { width: 22px; height: 22px; border-radius: 99px; background: var(--line-2); color: var(--muted); display: grid; place-items: center; font-size: .7rem; font-weight: 600; }
.step.done b, .step.now b { background: var(--ink); color: #fff; }
.step.now { color: var(--ink); font-weight: 500; }
.step-sep { width: 18px; height: 1px; background: var(--line); }

/* ── Payment ──────────────────────────────────────────────── */
.pay-layout { display: grid; gap: 24px; grid-template-columns: minmax(0, 1fr); }
.pay-layout > * { min-width: 0; }
@media (min-width: 1024px) { .pay-layout { grid-template-columns: minmax(0, 1fr) 360px; gap: 46px; align-items: start; } }
.panel {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius-lg); padding: 20px; margin-bottom: 16px;
}
@media (min-width: 768px) { .panel { padding: 26px; } }
.panel > h3 { margin-bottom: 4px; }
.panel-note { color: var(--muted); font-size: .86rem; margin-bottom: 16px; }

.pay-tabs { display: flex; gap: 8px; margin-bottom: 18px; flex-wrap: wrap; }
.pay-tab {
  border: 1px solid var(--line); background: var(--surface); border-radius: var(--radius);
  padding: 10px 16px; cursor: pointer; font-size: .85rem; min-height: 42px;
}
.pay-tab[aria-selected="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }

.qr-box { text-align: center; padding: 6px 0 4px; }
.qr-frame {
  display: inline-block; padding: 14px; background: #fff;
  border: 1px solid var(--line); border-radius: var(--radius-lg);
}
.qr-frame svg, .qr-frame img { width: min(240px, 62vw); height: auto; display: block; }
.qr-amount { font-size: 1.25rem; font-weight: 600; color: var(--ink); margin-top: 12px; }

.bank-row {
  display: flex; justify-content: space-between; gap: 12px; align-items: center;
  padding: 11px 0; border-bottom: 1px solid var(--line-2); font-size: .9rem;
}
.bank-row:last-child { border-bottom: 0; }
.bank-row .k { color: var(--muted); font-size: .82rem; }
.bank-row .v { font-weight: 600; color: var(--ink); text-align: right; word-break: break-word; }
.copy-btn {
  background: var(--cream); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 5px 10px; font-size: .72rem; cursor: pointer; color: var(--ink-2); white-space: nowrap;
}
.copy-btn:hover { background: var(--line-2); }

.dropzone {
  border: 1.5px dashed var(--line); border-radius: var(--radius-lg);
  padding: 28px 18px; text-align: center; background: var(--bg); cursor: pointer;
  transition: border-color .2s, background .2s;
}
.dropzone:hover, .dropzone.drag { border-color: var(--accent); background: var(--accent-soft); }
.dropzone svg { width: 30px; height: 30px; color: var(--muted); margin: 0 auto 10px; }
.slip-preview { margin-top: 14px; }
.slip-preview img { max-height: 320px; width: auto; margin: 0 auto; border-radius: var(--radius); border: 1px solid var(--line); }

/* ── Alerts ───────────────────────────────────────────────── */
.alert {
  padding: 13px 15px; border-radius: var(--radius); font-size: .88rem;
  margin-bottom: 16px; border: 1px solid transparent;
}
.alert-ok { background: var(--ok-soft); color: var(--ok); border-color: #cfe3d8; }
.alert-warn { background: var(--warn-soft); color: var(--warn); border-color: #eddcb8; }
.alert-bad { background: var(--bad-soft); color: var(--bad); border-color: #efcccc; }
.alert-info { background: var(--info-soft); color: var(--info); border-color: #cfe0e7; }

.pill {
  display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px;
  border-radius: 99px; font-size: .74rem; font-weight: 600; white-space: nowrap;
}
.pill-ok { background: var(--ok-soft); color: var(--ok); }
.pill-warn { background: var(--warn-soft); color: var(--warn); }
.pill-bad { background: var(--bad-soft); color: var(--bad); }
.pill-info { background: var(--info-soft); color: var(--info); }

/* ── Thank you ────────────────────────────────────────────── */
.thanks { text-align: center; max-width: 620px; margin: 0 auto; padding: 30px 0 10px; }
.thanks-mark {
  width: 62px; height: 62px; border-radius: 99px; background: var(--ok-soft);
  color: var(--ok); display: grid; place-items: center; margin: 0 auto 20px;
}
.thanks-mark svg { width: 30px; height: 30px; }
.order-no {
  display: inline-block; font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 1.05rem; letter-spacing: .06em; background: var(--cream);
  padding: 9px 16px; border-radius: var(--radius); margin: 4px 0 18px; color: var(--ink);
}

/* ── Footer ───────────────────────────────────────────────── */
.footer { background: var(--ink); color: #cfc8bf; padding: 44px 0 24px; margin-top: 60px; }
.footer h4 { color: #fff; font-family: var(--font-body); font-size: .76rem; letter-spacing: .18em; text-transform: uppercase; margin: 0 0 14px; font-weight: 600; }
.footer a:hover { color: #fff; }
.footer-grid { display: grid; gap: 30px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; } }
@media (min-width: 1024px) { .footer-grid { grid-template-columns: 1.6fr 1fr 1fr 1.2fr; } }
.footer-logo img { height: 30px; width: auto; margin-bottom: 14px; }
.footer ul { list-style: none; margin: 0; padding: 0; }
.footer li { margin-bottom: 9px; font-size: .87rem; }
.footer .social { display: flex; gap: 10px; margin-top: 6px; }
.social a {
  width: 38px; height: 38px; border: 1px solid rgba(255, 255, 255, .18);
  border-radius: 99px; display: grid; place-items: center; transition: background .2s, border-color .2s;
}
.social a:hover { background: rgba(255, 255, 255, .1); border-color: rgba(255, 255, 255, .35); }
.social svg { width: 17px; height: 17px; }
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, .12); margin-top: 34px; padding-top: 18px;
  display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  font-size: .78rem; color: #968d84;
}

/* ── Floating contact ─────────────────────────────────────── */
.fab {
  position: fixed; right: 14px; bottom: 14px; z-index: 50;
  display: flex; flex-direction: column; gap: 10px;
  transition: transform .25s ease;
}
body.has-sticky-buy .fab { transform: translateY(-72px); }
@media (min-width: 1024px) { body.has-sticky-buy .fab { transform: none; } }
.fab a {
  width: 46px; height: 46px; border-radius: 99px; display: grid; place-items: center;
  box-shadow: var(--shadow); color: #fff; background: var(--accent);
}
.fab a.line { background: #06c755; }
.fab svg { width: 24px; height: 24px; }
@media (min-width: 1024px) { .fab { right: 22px; bottom: 22px; } }

/* ── Toast ────────────────────────────────────────────────── */
.toast-host { position: fixed; left: 50%; bottom: 22px; transform: translateX(-50%); z-index: 200; display: flex; flex-direction: column; gap: 8px; width: min(92vw, 380px); }
.toast {
  background: var(--ink); color: #fff; padding: 12px 16px; border-radius: var(--radius);
  box-shadow: var(--shadow-lg); font-size: .88rem; display: flex; gap: 10px; align-items: center;
  animation: toast-in .25s ease;
}
.toast.ok { background: #21563f; }
.toast.bad { background: #7d2f2f; }
@keyframes toast-in { from { opacity: 0; transform: translateY(10px); } }

/* ── Utility ──────────────────────────────────────────────── */
.divider { height: 1px; background: var(--line); margin: 22px 0; }
.sticky-buy {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 55;
  background: rgba(251, 249, 246, .97); backdrop-filter: blur(10px);
  border-top: 1px solid var(--line); padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
  display: flex; gap: 12px; align-items: center;
  transform: translateY(110%); transition: transform .25s ease;
}
.sticky-buy.show { transform: none; }
.sticky-buy .sb-price { font-weight: 600; color: var(--ink); }
.sticky-buy .btn { flex: 1; }
@media (min-width: 1024px) { .sticky-buy { display: none; } }

@media print {
  .header, .footer, .fab, .announce, .no-print, .sticky-buy { display: none !important; }
  body { background: #fff; }
}
