:root {
  --brand-primary: #173d36;
  --brand-on-primary: #ffffff;
  --brand-accent: #ef8354;
  --brand-ink: #17201e;
  --brand-paper: #f7f5ef;
  --brand-surface: #ffffff;
  --brand-muted: #64716d;
  --brand-border: #dce2df;
  --brand-danger: #9f2d2d;
  --brand-radius: 18px;
  --brand-shadow: 0 20px 55px rgb(23 61 54 / 11%);
  --content-width: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--brand-ink); background: var(--brand-paper); font: 16px/1.55 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
body.cart-open { overflow: hidden; }
button, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; }
button:focus-visible, a:focus-visible, input:focus-visible { outline: 3px solid #0b4f45; outline-offset: 3px; box-shadow: 0 0 0 6px #fff; }
.skip-link { position: fixed; z-index: 100; top: 12px; left: 12px; transform: translateY(-160%); padding: .65rem 1rem; background: white; border-radius: 8px; }
.skip-link:focus { transform: translateY(0); }
.test-ribbon { padding: .42rem 1rem; color: #fff; background: #7c2d12; text-align: center; font-size: .78rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.test-ribbon[hidden] { display: none; }
.site-header { min-height: 76px; display: flex; align-items: center; justify-content: space-between; gap: 1rem; max-width: var(--content-width); margin: auto; padding: 1rem 24px; }
.brand { min-width: 0; display: inline-flex; align-items: center; gap: .7rem; text-decoration: none; font-size: 1.08rem; font-weight: 800; }
.brand > span:last-child { min-width: 0; overflow-wrap: anywhere; }
.brand-mark, .brand-logo { width: 42px; height: 42px; border-radius: 13px; }
.brand-mark { display: grid; place-items: center; color: #fff; background: var(--brand-primary); }
.brand-logo { object-fit: contain; background: #fff; }
.cart-button, .icon-button, .add-button, .checkout-button { border: 0; cursor: pointer; }
.cart-button { display: inline-flex; align-items: center; gap: .55rem; padding: .65rem .85rem .65rem 1rem; border: 1px solid var(--brand-border); border-radius: 999px; color: var(--brand-ink); background: var(--brand-surface); font-weight: 700; }
.cart-count { min-width: 26px; padding: .1rem .42rem; border-radius: 999px; color: #fff; background: var(--brand-primary); text-align: center; font-size: .85rem; }
.hero { max-width: var(--content-width); min-height: 430px; display: grid; align-content: center; margin: 0 auto; padding: 70px clamp(24px, 7vw, 90px); border-radius: clamp(0px, 2.5vw, 30px); color: var(--brand-on-primary); background: radial-gradient(circle at 82% 20%, rgb(255 255 255 / 18%), transparent 30%), linear-gradient(135deg, var(--brand-primary), #245f54); box-shadow: var(--brand-shadow); }
.hero h1 { max-width: 770px; margin: .2rem 0 .8rem; font-size: clamp(2.45rem, 7vw, 5.4rem); line-height: .98; letter-spacing: -.055em; }
.hero-copy { max-width: 620px; margin: 0 0 1.7rem; color: rgb(255 255 255 / 82%); font-size: clamp(1rem, 2vw, 1.2rem); }
.eyebrow { margin: 0 0 .35rem; font-size: .75rem; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }
.primary-link { width: fit-content; padding: .85rem 1.1rem; border-radius: 10px; color: var(--brand-primary); background: #fff; text-decoration: none; font-weight: 800; }
.catalogue { max-width: var(--content-width); margin: 0 auto; padding: 90px 24px; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 2rem; margin-bottom: 2rem; }
.section-heading h2, .cart-header h2 { margin: 0; font-size: clamp(1.7rem, 4vw, 2.65rem); letter-spacing: -.035em; }
.section-heading > .muted { max-width: 420px; }
.muted { color: var(--brand-muted); }
.notice { padding: 1.2rem; border: 1px solid var(--brand-border); border-radius: 12px; background: rgb(255 255 255 / 55%); }
.notice[hidden] { display: none; }
.notice.error { color: var(--brand-danger); border-color: #e6b6b6; background: #fff4f4; }
.product-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.product-card { min-width: 0; overflow: hidden; border: 1px solid var(--brand-border); border-radius: var(--brand-radius); background: var(--brand-surface); box-shadow: 0 8px 25px rgb(23 32 30 / 5%); }
.product-image-wrap { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: #e9eeeb; }
.product-image { position: relative; z-index: 1; width: 100%; height: 100%; display: block; object-fit: cover; transition: transform .35s ease; }
.product-card:hover .product-image { transform: scale(1.025); }
.image-fallback { position: absolute; inset: 0; display: grid; place-items: center; padding: 1rem; color: var(--brand-muted); font-size: .85rem; font-weight: 700; text-align: center; }
.product-content { padding: 1.25rem; }
.product-meta { min-height: 25px; display: flex; align-items: center; justify-content: space-between; gap: .5rem; color: var(--brand-muted); font-size: .75rem; text-transform: uppercase; letter-spacing: .06em; }
.stock-badge { padding: .2rem .5rem; border-radius: 999px; color: #246047; background: #e4f3e8; font-weight: 800; }
.stock-badge.low { color: #81500d; background: #fff1cf; }
.stock-badge.out { color: #8e2929; background: #fde5e5; }
.product-name { margin: .65rem 0 .4rem; font-size: 1.25rem; letter-spacing: -.02em; }
.product-description { min-height: 3.1em; display: -webkit-box; overflow: hidden; margin: 0 0 1.25rem; color: var(--brand-muted); -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.product-buy-row { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.product-price { font-size: 1.12rem; }
.add-button, .checkout-button { padding: .72rem 1rem; border-radius: 10px; color: var(--brand-on-primary); background: var(--brand-primary); font-weight: 800; }
.add-button:hover, .checkout-button:hover { filter: brightness(1.1); }
.add-button:disabled, .checkout-button:disabled { cursor: not-allowed; opacity: .5; filter: none; }
.cart-overlay { position: fixed; z-index: 40; inset: 0; background: rgb(13 25 22 / 45%); backdrop-filter: blur(2px); }
.cart-panel { position: fixed; z-index: 50; top: 0; right: 0; width: min(460px, 100%); height: 100dvh; display: flex; flex-direction: column; padding: 24px; background: var(--brand-surface); box-shadow: -20px 0 60px rgb(0 0 0 / 18%); transform: translateX(105%); visibility: hidden; transition: transform .25s ease, visibility .25s; }
.cart-panel.open { transform: translateX(0); visibility: visible; }
.cart-header { display: flex; justify-content: space-between; gap: 1rem; padding-bottom: 1rem; border-bottom: 1px solid var(--brand-border); }
.icon-button { width: 42px; height: 42px; border-radius: 50%; color: var(--brand-ink); background: #eef1ef; font-size: 1.6rem; line-height: 1; }
.inline-message { min-height: 1.5rem; margin-top: .6rem; color: var(--brand-danger); font-size: .88rem; }
.cart-items { flex: 1; overflow-y: auto; }
.empty-cart { padding: 3rem 1rem; color: var(--brand-muted); text-align: center; }
.cart-item { display: grid; grid-template-columns: 64px 1fr auto; gap: .8rem; padding: 1rem 0; border-bottom: 1px solid var(--brand-border); }
.cart-thumb { width: 64px; height: 64px; border-radius: 10px; object-fit: cover; background: #e9eeeb; }
.cart-item h3 { margin: 0; font-size: .98rem; }
.cart-item h3, .cart-item p, .site-footer { overflow-wrap: anywhere; }
.cart-item p { margin: .15rem 0; color: var(--brand-muted); font-size: .82rem; }
.quantity-row { display: flex; align-items: center; gap: .4rem; margin-top: .5rem; }
.quantity-row input { width: 62px; padding: .32rem; border: 1px solid var(--brand-border); border-radius: 7px; }
.text-button { padding: .25rem; border: 0; color: var(--brand-danger); background: transparent; cursor: pointer; font-size: .82rem; text-decoration: underline; }
.cart-price { white-space: nowrap; font-weight: 800; }
.cart-summary { padding-top: 1rem; border-top: 1px solid var(--brand-border); }
.summary-row { display: flex; justify-content: space-between; gap: 1rem; margin-bottom: .5rem; }
.fine-print, .secure-note { color: var(--brand-muted); font-size: .76rem; }
.checkout-button { width: 100%; margin-top: .6rem; padding: .9rem; }
.secure-note { text-align: center; }
.site-footer { max-width: var(--content-width); display: flex; justify-content: space-between; gap: 2rem; margin: 0 auto; padding: 30px 24px 50px; border-top: 1px solid var(--brand-border); }
.site-footer p { margin: .3rem 0 0; }
.site-footer nav { display: flex; gap: 1.2rem; }
.info-page { max-width: 760px; min-height: 70vh; margin: 0 auto; padding: 70px 24px; }
.info-card { padding: clamp(24px, 6vw, 54px); border: 1px solid var(--brand-border); border-radius: var(--brand-radius); background: #fff; box-shadow: var(--brand-shadow); }
.info-card h1 { margin: .3rem 0 1rem; font-size: clamp(2rem, 6vw, 3.5rem); line-height: 1; letter-spacing: -.045em; }
.warning-box { margin: 1.5rem 0; padding: 1rem; border-left: 5px solid #b45309; background: #fff7ed; }
.status-dot { width: 11px; height: 11px; display: inline-block; margin-right: .4rem; border-radius: 50%; background: #d97706; }
.status-dot.success { background: #16834d; }

@media (max-width: 850px) {
  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero { min-height: 370px; }
}
@media (max-width: 570px) {
  .site-header { min-height: 68px; padding-inline: 16px; }
  .hero { min-height: 360px; padding: 55px 22px; }
  .catalogue { padding: 65px 16px; }
  .section-heading, .site-footer { align-items: flex-start; flex-direction: column; }
  .product-grid { grid-template-columns: 1fr; }
  .cart-panel { padding: 18px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}
