:root {
    color-scheme: light;
    --paper: #faf7f2;
    --card: #fffdfa;
    --ink: #302623;
    --muted: #63524e;
    --accent: #773e50;
    --line: #ded2c9;
    --rose: #f3e4e3;
    --serif: "Cormorant Garamond", "Noto Serif TC", "Songti TC", Georgia, serif;
    --sans: "Atkinson Hyperlegible Next", system-ui, "PingFang TC", "Microsoft JhengHei", sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 17px/1.55 var(--sans); }
a { color: var(--accent); text-underline-offset: .18em; }
img { display: block; max-width: 100%; }
button, input, textarea, select { font: inherit; }
button, .button { cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: .4em; min-height: 48px; border: 1px solid var(--accent); border-radius: 7px; padding: .63rem 1.1rem; background: var(--accent); color: #fff; text-decoration: none; font-weight: 650; text-align: center; }
button:hover, .button:hover { filter: brightness(.94); }
.secondary { background: var(--card); color: var(--accent); border-color: #b78d98; }
:focus-visible { outline: 3px solid #9a5470; outline-offset: 4px; }
input, select, textarea { display: block; width: 100%; min-height: 48px; padding: .56rem .7rem; border: 1px solid #af9991; border-radius: 6px; background: #fff; color: var(--ink); }
input[type=checkbox] { flex: none; width: 22px; min-height: 22px; accent-color: var(--accent); }
textarea { resize: vertical; }
label { display: grid; gap: .34rem; font-weight: 600; }
label.check { display: flex; align-items: center; gap: .6rem; min-height: 48px; }
fieldset { min-width: 0; border: 1px solid var(--line); border-radius: 7px; padding: .9rem; }
.shipping-options legend { padding-inline: .25rem; font-weight: 600; }
.shipping-options label { cursor: pointer; }
.shipping-options input[type=radio] { flex: none; width: 22px; min-height: 22px; margin: 0; padding: 0; accent-color: var(--accent); }
.shipping-fields { margin: 0; padding: 0; border: 0; }
h1,h2,h3 { font-family: var(--serif); line-height: 1.24; margin: 0 0 .7rem; }
h1 { font-size: clamp(2rem, 4vw, 3.2rem); font-weight: 600; }
h2 { font-size: clamp(1.4rem, 2.6vw, 2rem); font-weight: 600; }
h3 { font-size: 1.26rem; }
p { margin: .45em 0 .75em; }
summary { cursor: pointer; font-weight: 650; padding-block: .65rem; }
.skip { position: fixed; top: .5rem; left: .5rem; padding: .8rem; background: #fff; transform: translateY(-150%); z-index: 10; }
.skip:focus { transform: none; }
.wrap { width: min(1160px, 92%); margin-inline: auto; padding: clamp(1.4rem, 4vw, 3.1rem) 0; }
.narrow { width: min(1000px, 92%); min-height: 60vh; }
.login-wrap { width: min(490px, 92%); }
.login-wrap h1 { margin-top: 1.5rem; }
.brand { display: inline-flex; flex-direction: column; text-decoration: none; color: var(--accent); white-space: nowrap; }
.brand span { font: 2rem/1 var(--serif); }
.brand small { font-size: .75rem; letter-spacing: .16em; margin-top: .32rem; }
.announcement { text-align: center; background: #664453; color: #fff; padding: .4rem 1rem; font-size: .88rem; }
.store-header { display: flex; gap: 1rem; justify-content: space-between; align-items: center; padding: 1rem max(4vw, calc((100vw - 1160px)/2)); background: var(--card); border-bottom: 1px solid var(--line); }
.store-header nav { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: .2rem 1.1rem; }
.store-header nav a { min-height: 44px; display: flex; align-items: center; gap: .4rem; text-decoration: none; }
.cart-link b { display: inline-grid; place-items: center; background: var(--rose); border-radius: 50%; min-width: 26px; min-height: 26px; }
.hero { display: grid; grid-template-columns: 1fr 1fr; min-height: 440px; }
.hero-copy { padding: clamp(2rem, 7vw, 6rem) 1.6rem clamp(2rem, 6vw, 5rem) max(5vw, calc((100vw - 1160px)/2)); background: #f2e7df; }
.hero-copy h1 { font-size: clamp(2.6rem, 7vw, 5.6rem); }
.hero-copy .button { margin-top: .7rem; }
.hero-photo { position: relative; overflow: hidden; background: #e9ccc6; }
.hero-photo img { position: absolute; width: 100%; height: 100%; object-fit: cover; }
.hero-art { min-height: 100%; display: flex; align-items: center; justify-content: center; gap: 1.3rem; padding: 5.4rem 1.5rem 3rem; background: radial-gradient(ellipse at 38% 24%, #f8e6de, #cfa9a3); }
.bottle, .jar { position: relative; display: grid; place-content: center; text-align: center; color: #65434c; border: 1px solid #f3ded7; background: linear-gradient(100deg, #c98994, #f1c5c6 50%, #af707e); width: min(25vw, 138px); height: 205px; border-radius: 22px 22px 15px 15px; box-shadow: 14px 23px 24px #70434a33; }
.jar { background: linear-gradient(100deg, #c9a98f, #f8ead9 52%, #b5987e); align-self: center; height: 110px; width: min(27vw, 155px); margin-top: 115px; }
.bottle::before,.jar::before { content: ""; position: absolute; bottom: 100%; left: 30%; width: 40%; height: 44px; border-radius: 8px 8px 0 0; background: linear-gradient(90deg,#806458,#e7c8a9,#936f5a); }
.jar::before { left: 0; width: 100%; height: 29px; }
.bottle span,.jar span,.photo-empty span { font-family: var(--serif); font-size: clamp(1rem, 2.7vw, 1.55rem); }
.eyebrow { color: var(--accent); font-size: .86rem; letter-spacing: .07em; font-weight: 650; }
.pills { display: flex; flex-wrap: wrap; gap: .55rem; margin: 1rem 0 1.35rem; }
.pills a,.badge { background: var(--rose); color: #65354a; border-radius: 30px; padding: .4rem .8rem; text-decoration: none; white-space: normal; }
.pills a { min-height: 44px; display: inline-flex; align-items: center; }
.pills a.current { background: var(--accent); color: white; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(250px,100%), 1fr)); gap: 1.15rem; }
.product,.panel { background: var(--card); border: 1px solid var(--line); border-radius: 11px; }
.product { overflow: hidden; }
.product-body { padding: 1rem; }
.product-body h3 a { color: var(--ink); text-decoration: none; }
.product-photo { display: block; background: #efe4df; overflow: hidden; aspect-ratio: 4/3; border-radius: 7px; }
.product-photo img { width: 100%; height: 100%; object-fit: contain; }
.photo-empty { display: grid; place-content: center; text-align: center; min-height: 100%; height: 100%; background: #ead7d3; color: var(--accent); }
.product-detail { margin-top: .8rem; }
.panel { padding: clamp(1rem, 2.7vw, 1.65rem); margin-bottom: 1rem; }
.row,.line { display: flex; align-items: center; justify-content: space-between; gap: .55rem 1rem; flex-wrap: wrap; }
.line { padding: .72rem 0; border-bottom: 1px solid var(--line); }
.total { font-size: 1.2rem; margin-bottom: .8rem; }
.split { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 1rem; align-items: start; }
.stack { display: grid; gap: .78rem; }
.stack > button { justify-self: start; }
.filter,.inline { display: flex; flex-wrap: wrap; align-items: end; gap: .75rem; }
.inline input { width: 85px; }
.notice { border: 1px solid #a68e81; background: #f3e9df; border-radius: 6px; padding: .8rem; }
.home > .notice { margin: 1rem auto; width: min(1160px,92%); }
.error,.warning { color: #8b232e; }
.error { background: #fde9e9; border-color: #c28086; }
.muted,.hint,time { color: var(--muted); font-size: .92rem; }
.preserve { white-space: pre-wrap; overflow-wrap: anywhere; }
.empty { text-align: center; padding: 2rem 1rem; color: var(--muted); }
.back { display: inline-block; margin-bottom: .65rem; }
.footer { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1.25rem; padding: 2rem max(4vw, calc((100vw - 1160px)/2)); border-top: 1px solid var(--line); background: #efe4dd; }
.list-item { display: flex; align-items: center; flex-wrap: wrap; gap: .8rem 1.15rem; border-bottom: 1px solid var(--line); padding: .85rem 0; }
.list-item > div:not(.thumb) { flex: 1 1 190px; }
.list-item:last-child { border-bottom: 0; }
.list-item p { margin: .1rem 0; }
.order-no,.lookup-code { overflow-wrap: anywhere; font-family: ui-monospace, monospace; }
.lookup-code { font-size: clamp(1rem,3vw,1.5rem); font-weight: 700; }
.admin-layout { display: grid; grid-template-columns: 230px minmax(0,1fr); min-height: 100vh; }
.side { display: flex; flex-direction: column; gap: 1.4rem; padding: 2rem 1.15rem; background: #eee5dd; border-right: 1px solid var(--line); }
.side nav { display: grid; gap: .35rem; }
.side nav a { min-height: 48px; padding: .65rem .78rem; border-radius: 7px; text-decoration: none; color: var(--ink); }
.side nav a[aria-current=page] { background: var(--card); color: var(--accent); font-weight: 700; }
.side-bottom { display: flex; gap: .6rem; flex-wrap: wrap; align-items: center; margin-top: auto; }
.admin-main { width: min(100%, 1200px); margin-inline: auto; padding: clamp(1rem,4vw,3rem); }
.page-title { margin-bottom: 1rem; }
.page-title h1 { margin: 0; }
.dashboard { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: .85rem; }
.task { text-decoration: none; color: var(--muted); display: grid; gap: .34rem; }
.task strong { font: 2.9rem/1.2 var(--serif); color: var(--accent); }
.thumb { width: 74px; height: 65px; border-radius: 5px; overflow: hidden; }
.thumb img { width: 100%; height: 100%; object-fit: contain; }
.thumb .photo-empty span { font-size: .7rem; }
.image-preview { width: min(280px, 100%); height: 165px; border-radius: 7px; overflow: hidden; background: #efe4df; margin-bottom: .75rem; }
.image-preview img { width: 100%; height: 100%; object-fit: contain; }
@media (max-width: 760px) {
    .store-header,.hero { display: grid; grid-template-columns: 1fr; }
    .store-header nav { justify-content: flex-start; }
    .hero-photo { min-height: 290px; }
    .hero-art { padding-top: 3.9rem; }
    .bottle { height: 140px; }
    .jar { height: 79px; margin-top: 70px; }
    .split,.admin-layout { grid-template-columns: 1fr; }
    .side { padding: 1rem; border-right: 0; border-bottom: 1px solid var(--line); gap: .65rem; }
    .side nav { display: flex; flex-wrap: wrap; }
    .side-bottom { margin-top: 0; }
    .dashboard { grid-template-columns: 1fr; }
    .task { grid-template-columns: 1fr auto; align-items: center; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
