:root {
  color-scheme: light;
  --navy: #263b68;
  --deep: #182746;
  --amber: #ffad22;
  --ink: #101925;
  --muted: #596578;
  --line: #dce1e9;
  --paper: #f5f6f8;
  --white: #fff;
  --vape-photo: #d1e9fe;
  --areca-photo: #ffd821;
  font-family: 'Noto Sans TC', 'Microsoft JhengHei', 'PingFang TC', system-ui, sans-serif;
  font-synthesis: none;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--paper); color: var(--ink); min-height: 100vh; display: flex; flex-direction: column; }
main { flex: 1; outline: none; }
button, input, select, textarea { font: inherit; }
a { color: inherit; text-decoration: none; }
button { cursor: pointer; }
button:disabled { opacity: .55; cursor: not-allowed; }
:focus-visible { outline: 3px solid #bd6b00; outline-offset: 3px; }
h1, h2, h3, p { margin-top: 0; }
h1 { font-size: clamp(29px, 3.5vw, 46px); line-height: 1.13; margin-bottom: 22px; }
h2 { font-size: clamp(20px, 2vw, 27px); margin-bottom: 18px; }
h3 { font-size: 16px; margin-bottom: 11px; }
.wrap { width: min(1468px, calc(100% - 64px)); margin-inline: auto; }
.page { width: min(1240px, calc(100% - 64px)); padding-block: 36px 58px; }
.page-heading { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: 12px; margin-bottom: 22px; }
.page-heading h1 { margin: 0; }
.muted { color: var(--muted); }
.loading { padding-block: 70px; }
.skip { position: absolute; left: 12px; top: -80px; z-index: 10; background: var(--white); color: var(--ink); padding: 10px 16px; border-radius: 6px; }
.skip:focus { top: 12px; }

.mast { background: linear-gradient(102deg, #2a3e6c, #243659); color: #fff; }
.mast-inner { min-height: 72px; display: grid; grid-template-columns: 1fr minmax(210px, 475px) 1fr; align-items: center; gap: 24px; padding-inline: clamp(0px, 2vw, 26px); }
.brand { display: inline-flex; align-items: center; gap: 14px; width: max-content; font-size: 32px; font-weight: 860; letter-spacing: .035em; white-space: nowrap; }
.brand-leaf { display: inline-block; position: relative; width: 27px; height: 34px; background: var(--amber); border-radius: 100% 0 95% 0; transform: rotate(12deg); }
.brand-leaf::after { content: ''; position: absolute; left: -4px; right: -4px; top: 16px; height: 3px; background: #2a3e6c; transform: rotate(-48deg); }
.brand > :last-child { border-left: 2px solid var(--amber); padding-left: 14px; line-height: 1.12; }
.search { display: flex; background: #40557f; border-radius: 10px; min-width: 0; }
.search input { min-width: 0; width: 100%; border: 0; background: transparent; color: #fff; padding: 11px 15px; border-radius: 8px; }
.search input::placeholder { color: #eef2fb; opacity: .94; }
.search button { flex: 0 0 50px; border: 0; border-radius: 0 8px 8px 0; background: none; color: #fff; }
.glass { width: 15px; height: 15px; border: 2px solid currentColor; border-radius: 50%; display: inline-block; position: relative; }
.glass::after { content: ''; position: absolute; width: 7px; height: 2px; background: currentColor; right: -5px; bottom: -3px; rotate: 45deg; border-radius: 1px; }
.mast-actions { display: flex; align-items: center; gap: 19px; justify-self: end; font-size: 14px; white-space: nowrap; }
.mast-actions a:hover { color: var(--amber); }
.cart-link { display: flex; gap: 9px; align-items: center; min-height: 42px; }
.basket { display: inline-block; position: relative; width: 23px; height: 15px; border: 2px solid currentColor; border-top-width: 1.5px; border-radius: 1px 1px 4px 4px; transform: skew(-10deg); }
.basket::before { content: ''; position: absolute; width: 5px; height: 2px; left: -7px; top: -4px; background: currentColor; }
.basket::after { content: ''; position: absolute; width: 4px; height: 4px; border-radius: 50%; left: 2px; bottom: -7px; background: currentColor; box-shadow: 11px 0 currentColor; }
#cart-count { font-size: 12px; min-width: 21px; height: 21px; display: grid; place-items: center; padding-inline: 4px; border-radius: 50px; background: var(--amber); color: var(--ink); font-weight: 750; }
.nav { background: var(--deep); color: #fff; }
.nav-inner { display: flex; gap: clamp(14px, 5vw, 70px); align-items: center; padding-inline: clamp(0px, 2vw, 26px); }
.nav a { white-space: nowrap; font-weight: 650; position: relative; padding-block: 13px; line-height: 1.25; }
.nav a:hover, .nav a[aria-current], .nav .nav-categories { color: var(--amber); }
.nav a[aria-current]::after { content: ''; display: block; position: absolute; inset: auto 0 0; height: 3px; border-radius: 3px 3px 0 0; background: currentColor; }
.admin-label { font-weight: 650; justify-self: end; grid-column: 3; white-space: nowrap; }

.home { padding-top: 13px; padding-bottom: 22px; }
.hero { position: relative; border-radius: 13px; overflow: hidden; background: #10243c; isolation: isolate; color: #fff; }
.hero-panel { position: relative; min-height: clamp(322px, 28vw, 445px); display: flex; align-items: center; }
.hero-picture { position: absolute; inset: 0 0 0 32%; z-index: -1; animation: picture-in .45s ease-out both; }
.hero-picture::after { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, #10243c 0%, #10243c00 22%); }
.hero-picture img { display: block; width: 100%; height: 100%; object-fit: contain; }
.hero-vape { background: var(--vape-photo); }
.hero-areca { background: var(--areca-photo); }
.hero-copy { padding: 24px 0 56px max(5.5%, 30px); animation: copy-in .46s ease-out both; }
.hero-copy h1 { font-size: clamp(54px, 7.2vw, 110px); letter-spacing: .018em; font-weight: 880; margin-bottom: 9px; line-height: 1.05; }
.hero-copy p { font-size: clamp(24px, 3.2vw, 44px); font-weight: 760; margin-bottom: 24px; letter-spacing: .055em; line-height: 1.18; }
.hero-copy .button { font-size: clamp(15px, 1.6vw, 22px); padding-inline: clamp(14px, 2vw, 26px); }
.hero-copy .button span { font-size: 1.2em; }
@keyframes picture-in { from { opacity: .5; } to { opacity: 1; } }
@keyframes copy-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
.slides { display: flex; gap: 6px; position: absolute; bottom: 12px; left: max(5%, 24px); }
.slides button { display: grid; place-items: center; padding: 0; width: 38px; height: 29px; border: 0; background: transparent; }
.slides button::before { content: ''; width: 32px; height: 5px; background: #bac4d3; border-radius: 6px; }
.slides button[aria-pressed=true]::before { background: var(--amber); }
.categories { margin-inline: min(1.7vw, 24px); padding-top: 23px; }
.section-title { font-size: clamp(27px, 3.5vw, 46px); letter-spacing: .025em; line-height: 1.05; margin-bottom: 15px; }
.section-title::after { content: ''; display: block; background: var(--amber); width: 81px; height: 6px; border-radius: 6px; margin-top: 9px; }
.category { position: relative; display: flex; align-items: center; min-height: clamp(105px, 12vw, 172px); padding: 20px 4.6%; margin-bottom: 12px; overflow: hidden; isolation: isolate; border-radius: 11px; color: #fff; font-size: clamp(26px, 3.3vw, 45px); font-weight: 820; letter-spacing: .03em; background: #263a50; }
.category-picture { position: absolute; inset: 0 0 0 30%; z-index: -1; display: flex; justify-content: center; align-items: center; overflow: hidden; background: var(--photo); }
.category-picture::after { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, var(--category-bg), transparent 33%); }
.category-picture img { width: auto; height: 134%; transform: translateY(-1%); transition: scale .32s ease; }
.category:hover img { scale: 1.035; }
.category-vape { --photo: var(--vape-photo); --category-bg: #263a50; }
.category-areca { --photo: var(--areca-photo); --category-bg: #39402f; background: var(--category-bg); }
.category-areca img { height: 205%; transform: translateY(-8%); }
.category span span { display: inline-block; margin-left: 12px; font-weight: 500; transition: transform .2s; }
.category:hover span span { transform: translateX(5px); }
.caption { text-align: right; color: var(--muted); font-size: 13px; margin: 0; }

.button { display: inline-flex; align-items: center; justify-content: center; gap: 10px; border: 1px solid transparent; border-radius: 8px; padding: 10px 17px; min-height: 43px; font-weight: 750; line-height: 1.3; transition: background-color .18s, transform .18s; }
.primary { background: var(--amber); color: #171910; }
.primary:hover:not(:disabled) { background: #ffc052; transform: translateY(-1px); }
.button:active:not(:disabled) { transform: translateY(1px); }
.full { width: 100%; }
.text-link, .text-button { color: #254975; font-weight: 650; text-decoration: underline; text-underline-offset: 4px; }
.text-button { border: 0; background: transparent; padding: 7px 0; }
.tabs { display: flex; flex-wrap: wrap; gap: 7px; }
.tabs a, .tabs button { color: var(--navy); border: 1px solid var(--line); background: var(--white); border-radius: 50px; padding: 8px 14px; font-size: 14px; font-weight: 700; }
.tabs a:hover, .tabs button:hover { border-color: var(--navy); }
.tabs .selected, .tabs [aria-pressed=true] { color: #fff; background: var(--navy); border-color: var(--navy); }
.panel { background: var(--white); border: 1px solid var(--line); border-radius: 12px; }
.empty { padding: 34px 26px; text-align: center; align-self: start; }
.empty p { color: var(--muted); }
.narrow { width: min(100%, 475px); margin-inline: auto; padding: clamp(18px, 4vw, 34px); }
.account-panel h1 { font-size: 32px; }
.mode-link { margin-top: 12px; }
.demo-note { background: #fff1d5; border: 1px solid #f0cc89; border-radius: 8px; padding: 10px 14px; }

.product-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.product { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: var(--white); display: flex; flex-direction: column; }
.product-art { background: var(--vape-photo); aspect-ratio: 5 / 3; }
.product-art.areca { background: var(--areca-photo); }
.product-art img { display: block; width: 100%; height: 100%; object-fit: contain; }
.product-info { padding: 17px; flex: 1; display: flex; flex-direction: column; }
.product-info h2 { font-size: 21px; margin-bottom: 7px; }
.eyebrow { color: #304e78; font-size: 13px; font-weight: 800; margin-bottom: 5px; }
.description { font-size: 14px; overflow-wrap: anywhere; }
.product-bottom { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px; margin-top: auto; }
.product-bottom strong { font-size: 19px; }
.product-bottom .button { font-size: 14px; }

.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .91fr); gap: clamp(16px, 3vw, 38px); align-items: start; }
.checkout { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.checkout-fields { background: var(--white); border: 1px solid var(--line); border-radius: 12px; padding: clamp(17px, 3vw, 30px); }
.field { display: grid; gap: 6px; margin-bottom: 15px; font-size: 14px; min-width: 0; }
.field > span { font-weight: 630; }
.field b { color: #a33523; }
.field small { color: var(--muted); font-weight: 400; margin-left: 3px; }
.field input, .field select, .field textarea { width: 100%; padding: 10px 13px; border: 1px solid #bfc7d3; border-radius: 11px; color: var(--ink); background: #fff; min-height: 43px; }
.field textarea { resize: vertical; }
.field input::placeholder, .field textarea::placeholder { color: #667386; opacity: 1; }
.extra-heading { margin-top: 25px; }
.cart-panel { padding: 4px 18px; }
.cart-row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 14px; padding-block: 15px; border-bottom: 1px solid var(--line); }
.cart-row:last-child { border-bottom: 0; }
.cart-name { min-width: 0; overflow-wrap: anywhere; }
.cart-name span { font-size: 13px; color: var(--muted); display: block; margin-top: 4px; }
.quantity { display: flex; align-items: center; gap: 8px; }
.quantity button { width: 32px; min-height: 35px; border: 1px solid var(--line); border-radius: 6px; background: #f7f9fc; color: var(--ink); }
.quantity output { min-width: 16px; text-align: center; }
.summary { padding: clamp(16px, 2.5vw, 29px); background: #edf0f5; }
.summary h2 { text-align: center; }
.receipt { border: 1px solid #e0e4ec; background: #fff; padding: 7px 14px; border-radius: 7px; margin-bottom: 17px; }
.receipt-row, .receipt-head { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; padding: 12px 3px; border-bottom: 1px solid var(--line); font-size: 14px; overflow-wrap: anywhere; }
.receipt-row > :last-child, .receipt-head > :last-child { white-space: nowrap; }
.receipt-head { font-weight: 750; }
.receipt-row small { color: var(--muted); }
.receipt-row.total { border-bottom: 0; font-size: 17px; }
.receipt-row.total strong { color: #895500; }
.pay { border-bottom: 1px solid var(--line); padding-bottom: 14px; }
.pay p { padding: 10px 12px; border-radius: 6px; background: #fff; color: var(--muted); margin: 8px 0 0; font-size: 14px; }
.privacy { font-size: 13px; margin-block: 13px; }
.checkout .full { border-radius: 40px; }
.form-error:empty { display: none; }
.form-error, .error { color: #a32e1e; font-size: 14px; margin-block: 9px; }
.success { background: #e7f5e8; border: 1px solid #b1d4b6; border-radius: 10px; padding: 14px; margin-bottom: 15px; overflow-wrap: anywhere; }

.order { margin-bottom: 11px; }
.order summary { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 10px; cursor: pointer; padding: 15px 43px 15px 20px; list-style: none; }
.order summary::-webkit-details-marker { display: none; }
.order summary::after { content: '+'; position: absolute; top: 50%; right: 20px; transform: translateY(-50%); color: var(--navy); font-weight: 800; }
.order[open] summary::after { content: '−'; }
.order summary strong { overflow-wrap: anywhere; }
.order summary small { display: block; font-size: 12px; color: var(--muted); margin-top: 4px; }
.order-body { border-top: 1px solid var(--line); padding: 18px 20px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 15px 23px; }
.status { background: #edf1f7; color: #263e64; border-radius: 40px; padding: 4px 8px; white-space: nowrap; font-size: 12px; font-weight: 700; }
.status.received { background: #fbefd6; color: #734709; }
.status.completed { background: #e4f1e7; color: #235a34; }
.status.cancelled { background: #faebe7; color: #922e26; }
.order dl { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 6px 10px; margin: 0; font-size: 14px; }
.order dt { color: var(--muted); }
.order dd { margin: 0; overflow-wrap: anywhere; }
.order-item { display: flex; justify-content: space-between; gap: 10px; border-bottom: 1px solid var(--line); padding-block: 7px; font-size: 14px; }
.order-item > :last-child { white-space: nowrap; }
.order-body p { margin-top: 12px; font-size: 14px; }
.status-form { grid-column: 1 / -1; justify-self: start; }
.status-form .field { display: inline-grid; min-width: 135px; margin: 0 8px 0 0; }
.admin-tabs { margin-bottom: 22px; }
.page > h2 small { color: var(--muted); font-size: 13px; font-weight: 550; }
.product-edit summary { grid-template-columns: minmax(0, 1fr) auto; }
.product-edit .field { margin: 0; }
.product-edit .button { justify-self: start; grid-column: 1 / -1; }
.checkbox { align-self: center; }
.faq { max-width: 830px; }
.faq details { padding: 15px; margin-bottom: 9px; }
.faq summary { cursor: pointer; font-weight: 700; }
.faq details p { margin: 12px 0 0; color: var(--muted); }

footer { background: var(--deep); color: #f0f2f7; }
.foot-inner { display: flex; justify-content: space-between; gap: 10px; padding-block: 16px; align-items: center; font-size: 13px; }
.foot-inner > div { display: flex; gap: 14px; flex-wrap: wrap; justify-content: flex-end; }
.foot-brand { font-weight: 800; white-space: nowrap; }
.demo-line { color: #d3dcf0; }
.foot-inner a { text-decoration: underline; text-underline-offset: 3px; }
#toast { position: fixed; z-index: 5; right: 20px; bottom: 20px; border-radius: 9px; padding: 12px 16px; color: #fff; background: var(--deep); box-shadow: 0 8px 25px #12203829; opacity: 0; transform: translateY(8px); pointer-events: none; max-width: calc(100% - 40px); transition: opacity .2s, transform .2s; }
#toast.visible { opacity: 1; transform: translateY(0); }

@media (max-width: 960px) {
  .wrap, .page { width: calc(100% - 36px); }
  .mast-inner { grid-template-columns: 1fr minmax(160px, 1.65fr) auto; }
  .nav-inner { gap: clamp(13px, 6vw, 52px); }
  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 620px) {
  .wrap, .page { width: calc(100% - 24px); }
  .page { padding-block: 24px 40px; }
  .mast-inner { grid-template-columns: 1fr auto; gap: 4px 10px; padding: 9px 1px 8px; }
  .brand { font-size: 25px; gap: 9px; }
  .brand-leaf { width: 20px; height: 25px; }
  .brand-leaf::after { top: 12px; }
  .brand > :last-child { padding-left: 9px; }
  .search { grid-column: 1 / -1; grid-row: 2; }
  .search input { padding-block: 9px; }
  .mast-actions { grid-column: 2; grid-row: 1; gap: 14px; }
  .admin-label { grid-column: 2; }
  .nav-inner { justify-content: space-between; gap: 5px; padding-inline: 2px; }
  .nav a { font-size: 13px; padding-block: 12px; }
  .hero-panel { min-height: 355px; align-items: flex-start; }
  .hero-picture { inset: 38% 0 0; }
  .hero-picture::after { background: linear-gradient(180deg, #10243c, #10243c00 21%); }
  .hero-copy { padding: 19px 0 0 18px; }
  .hero-copy h1 { font-size: clamp(38px, 10vw, 53px); margin-bottom: 4px; }
  .hero-copy p { font-size: 19px; margin-bottom: 10px; }
  .hero-copy .button { min-height: 35px; padding: 6px 9px; font-size: 13px; }
  .slides { left: auto; right: 8px; bottom: 7px; padding-inline: 3px; border-radius: 5px; background: #10243cdd; }
  .slides button { width: 28px; }
  .slides button::before { width: 22px; }
  .categories { margin-inline: 0; padding-top: 20px; }
  .category { min-height: 105px; margin-bottom: 9px; }
  .category-picture { inset-inline-start: 31%; justify-content: flex-end; }
  .category-picture::after { background: linear-gradient(90deg, var(--category-bg), transparent 26%); }
  .category span span { margin-left: 3px; }
  .product-grid { gap: 10px; }
  .product-info { padding: 11px; }
  .product-info h2 { font-size: 17px; }
  .product-bottom { align-items: stretch; flex-direction: column; }
  .product-bottom .button { font-size: 13px; padding-inline: 6px; }
  .split, .checkout { grid-template-columns: minmax(0, 1fr); }
  .order-body { grid-template-columns: minmax(0, 1fr); padding: 14px; }
  .order summary { padding: 12px 26px 12px 10px; gap: 6px; font-size: 13px; }
  .order summary::after { right: 10px; }
  .cart-panel { padding-inline: 11px; }
  .cart-row { gap: 8px; }
  .foot-inner { align-items: flex-start; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
