:root {
  --bg: #fff8f2; --card: #ffffff; --ink: #3b2a2a; --muted: #8a7570; --line: #f0e1d8;
  --pink: #e8577a; --pink-d: #c93f62; --pink-l: #ffe3ea; --green: #6fae78; --gold: #ffd166;
  --radius: 18px; --shadow: 0 6px 24px rgba(120, 70, 60, .10);
  --font: 'Be Vietnam Pro', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --display: 'Playfair Display', Georgia, serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.55 var(--font); -webkit-text-size-adjust: 100%; }
img { max-width: 100%; display: block; }
a { color: inherit; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px; }
main { padding-top: 20px; padding-bottom: 56px; outline: none; min-height: 60vh; }
h1, h2, h3 { font-family: var(--display); line-height: 1.2; margin: 0 0 .5em; }
h1 { font-size: clamp(2rem, 6vw, 3.2rem); }
h2 { font-size: clamp(1.5rem, 4vw, 2rem); }

.announce { background: var(--pink); color: #fff; text-align: center; padding: 8px 16px; font-size: .9rem; }
.top { position: sticky; top: 0; z-index: 20; background: rgba(255, 248, 242, .94); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.bar { display: flex; align-items: center; gap: 12px; min-height: 60px; flex-wrap: wrap; padding-top: 6px; padding-bottom: 6px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-family: var(--display); font-weight: 700; font-size: 1.25rem; }
.logo { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 12px; background: var(--pink); color: #fff; font-size: 1.2rem; }
.nav { display: flex; gap: 4px; flex: 1 1 100%; overflow-x: auto; scrollbar-width: none; order: 3; width: 100%; }
.nav::-webkit-scrollbar { display: none; }
.nav a { white-space: nowrap; text-decoration: none; padding: 8px 14px; border-radius: 999px; font-weight: 500; color: var(--muted); }
.nav a:hover { color: var(--ink); background: var(--pink-l); }
.nav a.on { background: var(--pink); color: #fff; }
.tools { display: flex; gap: 8px; align-items: center; margin-left: auto; }
.cart { position: relative; display: inline-flex; align-items: center; gap: 6px; text-decoration: none; background: var(--card); border: 1px solid var(--line); border-radius: 999px; padding: 8px 14px; min-height: 44px; }
.cart b { background: var(--pink); color: #fff; border-radius: 999px; min-width: 22px; height: 22px; display: grid; place-items: center; font-size: .78rem; padding: 0 6px; }
@media (min-width: 820px) { .nav { order: 0; width: auto; flex: 1; } .bar { flex-wrap: nowrap; } }

.btn, .chip { font: inherit; cursor: pointer; border: 0; text-decoration: none; display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; transition: transform .12s, background .15s, box-shadow .15s; }
.btn { background: var(--pink); color: #fff; padding: 10px 22px; border-radius: 999px; font-weight: 600; box-shadow: 0 4px 14px rgba(232, 87, 122, .35); }
.btn:hover { background: var(--pink-d); }
.btn:active { transform: scale(.97); }
.btn.ghost { background: transparent; color: var(--pink-d); border: 2px solid var(--pink); box-shadow: none; }
.btn.ghost:hover { background: var(--pink-l); }
.btn.block { width: 100%; }
.btn[disabled] { opacity: .5; cursor: not-allowed; box-shadow: none; }
.chip { background: var(--card); border: 1px solid var(--line); color: var(--ink); padding: 8px 16px; border-radius: 999px; font-weight: 500; }
.chip.small { min-height: 44px; min-width: 52px; padding: 6px 12px; }
.chip.on { background: var(--ink); border-color: var(--ink); color: #fff; }
:focus-visible { outline: 3px solid #2a6df4; outline-offset: 2px; }

.hero { display: grid; gap: 24px; align-items: center; padding: 24px 0 36px; }
.hero p { font-size: 1.1rem; color: var(--muted); max-width: 46ch; }
.hero .cta { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 8px; }
.hero-art { border-radius: 28px; overflow: hidden; box-shadow: var(--shadow); aspect-ratio: 1; background: var(--pink-l); }
.hero-art img { width: 100%; height: 100%; object-fit: cover; }
@media (min-width: 820px) { .hero { grid-template-columns: 1.1fr .9fr; padding: 40px 0 56px; } }

.section { margin: 40px 0; }
.section-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 14px; }
.section-head a { color: var(--pink-d); font-weight: 600; text-decoration: none; }
.cats { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }
.cat-tile { position: relative; border-radius: var(--radius); overflow: hidden; text-decoration: none; background: var(--pink-l); aspect-ratio: 16/9; box-shadow: var(--shadow); }
.cat-tile img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s; }
.cat-tile:hover img { transform: scale(1.06); }
.cat-tile span { position: absolute; left: 12px; bottom: 10px; background: rgba(255, 255, 255, .92); padding: 6px 14px; border-radius: 999px; font-weight: 600; }

.grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
@media (min-width: 700px) { .grid { grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 20px; } }
.card { background: var(--card); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); text-decoration: none; display: flex; flex-direction: column; transition: transform .18s, box-shadow .18s; }
.card:hover { transform: translateY(-3px); box-shadow: 0 12px 30px rgba(120, 70, 60, .16); }
.card .img { aspect-ratio: 1; background: var(--pink-l); position: relative; }
.card .img img { width: 100%; height: 100%; object-fit: cover; }
.card .body { padding: 12px 14px 16px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.card .name { font-weight: 600; line-height: 1.3; }
.card .price { color: var(--pink-d); font-weight: 700; margin-top: auto; }
.badge { position: absolute; top: 10px; left: 10px; background: var(--gold); color: #5a3d00; font-size: .75rem; font-weight: 700; padding: 3px 10px; border-radius: 999px; }
.badge.out { background: #5b4a48; color: #fff; }

.filters .chip { white-space: nowrap; flex-shrink: 0; }
.filters { display: flex; gap: 8px; overflow-x: auto; padding: 4px 0 14px; scrollbar-width: none; }
.filters::-webkit-scrollbar { display: none; }

.product { display: grid; gap: 24px; }
@media (min-width: 820px) { .product { grid-template-columns: 1fr 1fr; gap: 40px; align-items: start; } }
.product .pic { border-radius: 24px; overflow: hidden; aspect-ratio: 1; background: var(--pink-l); box-shadow: var(--shadow); }
.product .pic img { width: 100%; height: 100%; object-fit: cover; }
.crumbs { color: var(--muted); font-size: .9rem; margin-bottom: 8px; }
.crumbs a { text-decoration: none; }
.big-price { font-size: 1.8rem; font-weight: 700; color: var(--pink-d); margin: 8px 0 16px; }
.label { font-weight: 600; margin: 16px 0 8px; display: block; }
.pills { display: flex; flex-wrap: wrap; gap: 8px; }
.qty { display: inline-flex; align-items: center; gap: 4px; background: var(--card); border: 1px solid var(--line); border-radius: 999px; }
.qty button { width: 44px; height: 44px; border: 0; background: none; font-size: 1.3rem; cursor: pointer; border-radius: 999px; }
.qty button:hover { background: var(--pink-l); }
.qty output { min-width: 28px; text-align: center; font-weight: 600; }

.panel { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px; }
.cart-line { display: grid; grid-template-columns: 72px 1fr auto; gap: 12px; align-items: center; padding: 14px 0; border-bottom: 1px solid var(--line); }
.cart-line:last-child { border-bottom: 0; }
.cart-line img { width: 72px; height: 72px; border-radius: 12px; object-fit: cover; background: var(--pink-l); }
.cart-line .meta { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.cart-line .sub { color: var(--muted); font-size: .9rem; }
.cart-line .rm { background: none; border: 0; color: var(--muted); cursor: pointer; text-decoration: underline; padding: 8px 0; min-height: 44px; font: inherit; }
.cart-line .right { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.total-row { display: flex; justify-content: space-between; font-size: 1.2rem; font-weight: 700; padding-top: 14px; }
.layout-2 { display: grid; gap: 20px; }
@media (min-width: 900px) { .layout-2 { grid-template-columns: 1.4fr 1fr; align-items: start; } }

form.f { display: grid; gap: 14px; }
.field { display: grid; gap: 6px; }
.field label { font-weight: 600; font-size: .92rem; }
input, textarea, select { font: inherit; color: inherit; background: #fff; border: 1.5px solid var(--line); border-radius: 12px; padding: 11px 14px; min-height: 46px; width: 100%; }
textarea { min-height: 96px; resize: vertical; }
input:focus, textarea:focus, select:focus { border-color: var(--pink); outline: 3px solid var(--pink-l); }
.err { color: #b3261e; font-weight: 500; min-height: 1.2em; }
.hint { color: var(--muted); font-size: .88rem; }

.steps { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); counter-reset: s; }
.step { background: var(--card); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); }
.step::before { counter-increment: s; content: counter(s); display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--pink-l); color: var(--pink-d); font-weight: 700; margin-bottom: 8px; }
.step b { display: block; margin-bottom: 4px; }
.done { text-align: center; max-width: 560px; margin: 24px auto; }
.done .code { font: 700 2rem var(--display); color: var(--pink-d); letter-spacing: .05em; margin: 8px 0; }
.done .row { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-top: 16px; }
.empty { text-align: center; color: var(--muted); padding: 48px 0; }

.foot { background: #3b2a2a; color: #f5e7e0; padding: 32px 0; margin-top: 24px; }
.foot .cols { display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.foot h3 { color: #fff; font-size: 1.1rem; }
.foot a { color: #ffd0dc; }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 140%); background: var(--ink); color: #fff; padding: 12px 22px; border-radius: 999px; transition: transform .25s; z-index: 50; max-width: calc(100vw - 32px); }
.toast.show { transform: translate(-50%, 0); }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; } }
