:root {
  color-scheme: light;
  --ink: #123543;
  --muted: #44626c;
  --blue: #006f90;
  --blue-dark: #005873;
  --cyan: #00a9d1;
  --green: #8bc658;
  --green-soft: #dcedc5;
  --blue-soft: #e6f4f8;
  --paper: #f5fafb;
  --line: #d4e4e9;
  --heading: system-ui, 'Trebuchet MS', sans-serif;
  --body: system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 1rem/1.5 var(--body); }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { font-family: var(--heading); line-height: 1.08; letter-spacing: -.025em; }
a { color: inherit; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: default; opacity: .53; }
img { display: block; max-width: 100%; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; }
.wrap { width: min(1240px, calc(100% - 88px)); margin-inline: auto; }
.sr-only, .skip:not(:focus) { position: absolute; clip-path: inset(50%); width: 1px; height: 1px; overflow: hidden; white-space: nowrap; }
.skip:focus { position: absolute; z-index: 4; left: 1rem; top: .5rem; padding: 1rem; background: white; }
.topline { padding: .56rem 1rem; background: var(--ink); text-align: center; color: white; font-size: .875rem; font-weight: 600; }
.topline span { color: var(--green); margin-inline: .5rem; }
.site-header { background: white; border-bottom: 1px solid var(--line); }
.header-inner { min-height: 82px; display: flex; align-items: center; justify-content: space-between; gap: 1.25rem; }
.logo { display: inline-flex; flex-direction: column; align-items: flex-start; gap: .1rem; text-decoration: none; flex: none; }
.logo-frame { display: block; position: relative; overflow: hidden; width: clamp(11rem, 21vw, 15.5rem); aspect-ratio: 4; background: white; }
.logo-frame img { position: absolute; top: 50%; left: 54.2%; width: 129%; height: auto; max-width: none; transform: translate(-50%, -50%); }
.logo small { margin-left: .35rem; font-size: .75rem; font-weight: 700; color: var(--blue-dark); }
.bolt { display: inline-block; width: .85rem; height: 1.18rem; background: currentColor; clip-path: polygon(53% 0, 100% 0, 68% 39%, 97% 39%, 31% 100%, 41% 58%, 0 58%); }
.site-nav { display: flex; flex-wrap: wrap; min-width: 0; align-items: center; gap: .75rem clamp(.8rem, 2vw, 1.65rem); padding-block: .65rem; font-weight: 700; }
.site-nav a { position: relative; text-decoration: none; overflow-wrap: anywhere; }
.cart-button { flex-shrink: 0; }
.site-nav a:hover, .site-nav [aria-current] { color: var(--blue-dark); }
.site-nav [aria-current]::after { content: ''; position: absolute; left: 0; right: 0; bottom: -.55rem; height: 3px; background: var(--cyan); }
.button { display: inline-flex; gap: .6rem; align-items: center; justify-content: center; min-height: 44px; padding: .62rem 1rem; border: 1px solid transparent; border-radius: .68rem; font-weight: 700; color: inherit; text-decoration: none; line-height: 1.25; }
.button:hover:not(:disabled) { filter: brightness(.94); }
.button-primary { background: var(--blue); color: white; }
.button-outline { background: white; border-color: var(--line); }
.button-outline:hover:not(:disabled) { border-color: #6aa8b9; }
.wide { width: 100%; }
.count { display: grid; min-width: 1.55rem; height: 1.55rem; place-items: center; border-radius: 100px; background: var(--green); font-size: .85rem; padding-inline: .2rem; }
.bag-icon { width: .95rem; height: .87rem; border: 1.7px solid currentColor; border-radius: .17rem; position: relative; margin-top: .17rem; }
.bag-icon::before { content: ''; border: 1.6px solid currentColor; border-bottom: 0; position: absolute; width: .42rem; height: .34rem; top: -.38rem; left: .15rem; border-radius: 1rem 1rem 0 0; }

.hero { display: grid; grid-template-columns: minmax(0, .88fr) minmax(0, 1.12fr); isolation: isolate; margin-top: 2rem; min-height: 430px; overflow: hidden; border: 1px solid #d5e8e4; border-radius: 1.65rem; background: #eaf5f2; color: var(--ink); }
.hero-copy { display: flex; align-items: flex-start; justify-content: center; flex-direction: column; padding: 3rem clamp(1.7rem, 4vw, 3.75rem); }
.eyebrow { display: flex; align-items: center; gap: .48rem; font-size: .875rem; font-weight: 800; text-transform: uppercase; letter-spacing: .14em; }
.hero h1 { font-size: clamp(2.85rem, 5vw, 4.7rem); font-weight: 800; line-height: .96; letter-spacing: -.056em; margin: .55rem 0 1.1rem; text-wrap: balance; }
.hero h1 em { display: block; font-style: normal; color: var(--blue-dark); }
.hero-description { max-width: 39ch; font-size: 1.13rem; margin-bottom: 1.55rem; color: var(--muted); }

.catalog { padding: 3.1rem 0 4.5rem; scroll-margin-top: 1.2rem; }
.section-kicker { color: var(--blue-dark); margin-bottom: .48rem; }
.catalog h2, .admin-main h1 { font-size: clamp(2.3rem, 4.3vw, 3.65rem); font-weight: 800; }
.catalog-tools { display: flex; justify-content: space-between; align-items: center; gap: .9rem; margin: 1rem 0 1.35rem; }
.filters, .admin-tabs { display: flex; flex-wrap: wrap; gap: .5rem; }
.filter { text-decoration: none; display: inline-flex; align-items: center; background: white; color: var(--ink); border: 1px solid var(--line); border-radius: 2rem; min-height: 43px; padding: .5rem .96rem; font-weight: 700; }
.filter[aria-current="page"] { background: var(--blue); border-color: var(--blue); color: white; }
.filter:hover:not([aria-current="page"]) { border-color: var(--blue); }
.catalog-status { color: var(--muted); font-size: .92rem; }
.product-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.1rem; }
.product { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 1.15rem; background: white; overflow: hidden; box-shadow: 0 .45rem 1.35rem #12354308; }
.product-visual { position: relative; display: block; overflow: hidden; width: 100%; border: 0; background: #f0f8f7; padding: .8rem; aspect-ratio: 1.18; }
.product-visual img, .cart-image img, .table-image img { width: 100%; height: 100%; object-fit: cover; }
.product-visual img { object-fit: contain; transition: transform .24s; }
.product-visual:hover img { transform: scale(1.035); }
.product-visual:focus-visible { outline-offset: -4px; }
.age-tag { position: absolute; top: .7rem; left: .7rem; border-radius: 2rem; padding: .35rem .7rem; color: var(--ink); background: white; font-size: .875rem; font-weight: 700; }
.inline-tag { position: static; align-self: flex-start; background: var(--green-soft); }
.product-content { display: flex; flex-direction: column; flex: 1; padding: 1.05rem 1.15rem 1.15rem; }
.product-category { color: var(--blue-dark); font-size: .87rem; font-weight: 800; margin-bottom: .23rem; }
.product h3 { font-size: 1.6rem; overflow-wrap: anywhere; }
.plain { text-decoration: none; padding: 0; border: 0; color: inherit; background: none; font: inherit; text-align: left; }
.plain:hover { color: var(--blue); }
.product-bottom { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem; margin-top: auto; padding-top: .85rem; }
.price { flex: none; font: 750 1.3rem var(--heading); }
.image-fallback { display: grid; place-items: center; width: 100%; height: 100%; min-height: 42px; background: linear-gradient(150deg, #eff9f7, #e1efed); color: var(--muted); font-weight: 700; }
.footer { background: white; border-top: 1px solid var(--line); }
.footer-inner { display: flex; justify-content: space-between; gap: 1rem; align-items: center; padding: 2rem 0; }
.footer p, .footer a:not(.logo) { color: var(--muted); font-size: .9rem; }

.detail-copy { display: flex; flex-direction: column; align-items: flex-start; gap: .65rem; min-width: 0; padding: clamp(1rem, 2vw, 2rem) 0; }
.stock-info { font-weight: 700; color: #2e5e3a; }
.cart-list { margin: .3rem 0 .8rem; padding: 0; list-style: none; }
.cart-line { display: flex; align-items: center; justify-content: space-between; gap: .65rem; border-bottom: 1px solid var(--line); padding: .8rem 0; }
.cart-image { width: 66px; height: 66px; flex: none; border-radius: .5rem; overflow: hidden; }
.cart-product { display: grid; margin-right: auto; overflow-wrap: anywhere; }
.cart-product span { color: var(--muted); font-size: .9rem; }
.totals dl { margin: .4rem 0 .9rem; }
.totals dl div { display: flex; justify-content: space-between; gap: 1rem; padding: .28rem 0; }
.totals dd { margin: 0; }
.totals .grand-total { border-top: 1px solid var(--line); margin-top: .35rem; padding-top: .6rem; font-weight: 800; }
form { display: grid; gap: .8rem; }
form label { display: grid; gap: .25rem; font-weight: 700; }
input, select, textarea { min-width: 0; width: 100%; min-height: 44px; padding: .55rem .68rem; border: 1px solid #87a9b5; border-radius: .58rem; background: white; color: var(--ink); }
select { appearance: none; padding-right: 2rem; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 15px) 50%, calc(100% - 10px) 50%; background-size: 5px 5px; background-repeat: no-repeat; }
textarea { resize: vertical; }
.form-pair { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; }
.muted { color: var(--muted); }
.error, .cart-product .error { color: #a71c38; }

.admin-main { padding-top: 2.8rem; padding-bottom: 4rem; }
.header-actions { display: flex; gap: .5rem; }
.surface { background: white; border: 1px solid var(--line); border-radius: 1rem; }
.admin-login { margin: 2rem auto; max-width: 440px; padding: 1.7rem; }
.admin-login h1 { margin-bottom: 1.1rem; }
.admin-login > .error { margin-bottom: .8rem; }
.login-code-actions { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .8rem; }
.admin-login [name="code"] { letter-spacing: .22em; font-variant-numeric: tabular-nums; }
.metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: .85rem; margin: 1.55rem 0 1.7rem; }
.metric { display: grid; gap: .35rem; padding: 1.15rem; color: var(--muted); }
.metric strong { color: var(--ink); font: 800 clamp(1.65rem, 4vw, 2.6rem) var(--heading); }
.admin-tabs { margin: 0 0 .85rem; }
.surface-title { display: flex; justify-content: space-between; gap: .75rem; align-items: center; padding: 1.1rem; }
.table-wrap { overflow: auto; }
table { width: 100%; min-width: 540px; text-align: left; border-collapse: collapse; }
table th, table td { padding: .72rem 1.1rem; border-top: 1px solid var(--line); white-space: nowrap; }
table thead { background: var(--paper); color: var(--muted); }
.table-product { display: flex; align-items: center; gap: .75rem; }
.table-image { width: 48px; height: 48px; border-radius: .38rem; overflow: hidden; }
.table-product span { display: block; color: var(--muted); font-size: .875rem; font-weight: 500; }
.pill { display: inline-block; border-radius: 2rem; background: var(--blue-soft); padding: .26rem .65rem; font-weight: 700; font-size: .87rem; white-space: nowrap; }
.pill.positive { background: var(--green-soft); color: #28582d; }
.order { border-top: 1px solid var(--line); }
.order summary { cursor: pointer; display: grid; grid-template-columns: minmax(140px, 1fr) 1.5fr max-content max-content; gap: 1rem; align-items: center; padding: .9rem 1.1rem; }
.order summary span:first-child { display: grid; }
.order summary small { color: var(--muted); }
.order summary .order-customer { overflow-wrap: anywhere; }
.order[open] summary { background: var(--paper); }
.order-body { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; padding: 1.2rem; overflow-wrap: anywhere; }
.order-body h3 { margin-bottom: .4rem; }
.order-body ul { margin: 0 0 .4rem; padding-left: 1.1rem; }
.order-actions { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: .55rem; }
.panel-empty { padding: 1rem 1.1rem 1.5rem; color: var(--muted); }
.checkbox { display: flex; align-items: center; gap: .6rem; }
.checkbox input { min-height: auto; width: 1.1rem; height: 1.1rem; accent-color: var(--blue); }

@media (max-width: 950px) {
  .wrap { width: calc(100% - 52px); }
  .hero { min-height: 360px; }
  .hero-copy { padding: 2rem; }
  .hero h1 { font-size: clamp(3rem, 6.4vw, 5rem); }
}

@media (max-width: 720px) {
  .wrap { width: calc(100% - 32px); }
  .header-inner { min-height: 70px; flex-wrap: wrap; padding: .8rem 0; gap: .85rem; }
  .site-nav { order: 3; width: 100%; gap: .75rem 1rem; font-size: .9rem; padding-bottom: .25rem; }
  .site-nav [aria-current]::after { bottom: -.3rem; }
  .hero { grid-template-columns: 1fr; margin-top: 1.2rem; border-radius: 1.25rem; }
  .hero-copy { padding: 1.5rem 1.25rem; }
  .hero h1 { font-size: clamp(2.85rem, 9.5vw, 4.4rem); }
  .catalog { padding: 2.2rem 0 2.8rem; }
  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem; }
  .catalog-tools { flex-wrap: wrap; }
  .product-content { padding: .72rem; }
  .product h3 { font-size: 1.3rem; }
  .order summary { grid-template-columns: 1fr auto; gap: .35rem 1rem; }
  .order-customer { grid-column: 1; grid-row: 2; }
}

@media (max-width: 420px) {
  .topline { font-size: .78rem; }
  .header-actions .button { font-size: .82rem; padding-inline: .55rem; }
  .logo-frame { width: clamp(8.75rem, 45vw, 11rem); }
  .cart-button { padding-inline: .65rem; }
  .product-bottom { flex-wrap: wrap; }
  .product-bottom button { width: 100%; }
  .product-visual { aspect-ratio: 1; }
  .age-tag { font-size: .78rem; }
  .footer-inner { flex-wrap: wrap; }
  .detail-copy { padding-top: .35rem; }
  .metrics { grid-template-columns: 1fr; }
  .order-body { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0s !important; }
}

.inner-page { padding-block: 2rem 3.25rem; min-height: 55vh; }
.inner-page h1 { font-size: clamp(2.15rem, 5vw, 3.55rem); margin-bottom: 1.1rem; }
.back-link { margin-bottom: 1rem; font-weight: 700; }
.back-link a { color: var(--blue-dark); }
.detail { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, .85fr); gap: clamp(1.4rem, 4vw, 4rem); align-items: start; }
.detail h1 { margin-bottom: .15rem; max-width: 17ch; }
.catalog-form { display: flex; flex-wrap: wrap; align-items: center; gap: .45rem; }
.catalog-form input, .catalog-form select { width: auto; }
.panel { padding: clamp(1rem, 3vw, 1.6rem); }
.panel h2 { margin-bottom: .45rem; }
.compact { max-width: 640px; }
.compact > p + p, .compact > p + a { margin-top: .75rem; }
.basket-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(230px, .39fr); gap: 1rem; align-items: start; }
.cart-line:last-child { border-bottom: 0; }
.basket-controls { display: flex; flex-wrap: wrap; gap: .35rem; align-items: center; }
.basket-controls input { width: 4.3rem; }
.notice { padding: .6rem .8rem; border-radius: .55rem; background: var(--blue-soft); color: var(--ink); margin-bottom: .8rem; }
.inner-page > .error, .admin-main > .error { margin-bottom: .75rem; }

@media (max-width: 950px) {
  .catalog-tools { flex-wrap: wrap; }
  .basket-layout { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
  .detail { grid-template-columns: 1fr; gap: 1.45rem; }
  .cart-line { flex-wrap: wrap; justify-content: flex-start; }
  .cart-product { flex: 1; min-width: 130px; }
  .basket-controls { flex-basis: 100%; }
}

@media (max-width: 420px) {
  .product-bottom form { width: 100%; }
  .catalog-form input, .catalog-form select { width: 100%; }
}

.hero-visual { position: relative; display: grid; place-items: center; padding: 1.25rem 2rem; background: radial-gradient(ellipse at 54% 46%, #f9fefc, #e9f8f6 55%, #cbe8e8); min-width: 0; }
.hero-visual img { width: min(90%, 510px); height: auto; max-height: 395px; object-fit: contain; }
.hero-pattern { min-height: 220px; }
.product .product-bottom a { min-height: 38px; padding: .5rem .76rem; font-size: .9rem; }
@media (min-width: 1000px) {
  .product-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}


.hero-button { min-height: 48px; }
.hero-product-name { position: absolute; right: 1rem; bottom: .85rem; background: white; color: var(--blue-dark); border: 1px solid var(--line); border-radius: 2rem; padding: .35rem .85rem; font-weight: 700; }
.catalog-heading { display: flex; align-items: baseline; justify-content: space-between; gap: .75rem; padding-bottom: .8rem; border-bottom: 1px solid var(--line); }
.catalog-empty { padding: 1rem 0; color: var(--muted); }
.product-page .back-link { margin-bottom: 1.25rem; }
.product-gallery { min-width: 0; scroll-margin-top: 1rem; }
.gallery-stage { position: relative; display: grid; place-items: center; width: 100%; min-height: 230px; aspect-ratio: 1.15; padding: clamp(.85rem, 3vw, 2.15rem); background: #eef7f7; border: 1px solid var(--line); border-radius: 1.25rem; overflow: hidden; }
a.gallery-stage { cursor: zoom-in; }
.gallery-stage img { display: block; width: 100%; height: 100%; object-fit: contain; }
.gallery-stage .image-fallback { border-radius: .75rem; }
.gallery-zoom { position: absolute; right: .85rem; bottom: .85rem; min-height: 44px; display: inline-flex; gap: .7rem; align-items: center; padding: .55rem .85rem; border: 1px solid var(--line); border-radius: 2rem; background: white; color: var(--ink); font-size: .9rem; font-weight: 700; }
.zoom-icon { position: relative; width: .89rem; height: .89rem; border: 2px solid currentColor; border-radius: 50%; }
.zoom-icon::after { content: ''; position: absolute; right: -.34rem; bottom: -.18rem; width: .38rem; height: 2px; background: currentColor; transform: rotate(45deg); }
.gallery-thumbs { display: flex; flex-wrap: wrap; gap: .55rem; margin-top: .85rem; }
.gallery-thumbnail { display: grid; place-items: center; width: clamp(54px, 8vw, 82px); aspect-ratio: 1; padding: .3rem; overflow: hidden; border: 1px solid var(--line); border-radius: .75rem; background: white; }
.gallery-thumbnail img { width: 100%; height: 100%; object-fit: contain; border-radius: .38rem; }
.gallery-thumbnail[aria-current] { outline: 2px solid var(--blue); outline-offset: -2px; }
.gallery-thumbnail:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; }
.detail-offer { display: grid; align-items: start; justify-items: start; gap: .55rem; width: 100%; padding: 1rem 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin: .55rem 0; }
.detail-offer .price { font-size: 1.8rem; }
.detail-description { display: grid; gap: .75rem; max-width: 65ch; }
.detail-description h2 { font-size: 1.4rem; }
.detail-description a { color: var(--blue-dark); font-weight: 700; }
.photo-viewer-bar { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; flex-wrap: wrap; margin-bottom: 1rem; }
.photo-viewer-bar h1 { margin-bottom: 0; }
.photo-viewer-actions { display: flex; gap: .55rem; flex-wrap: wrap; }
.photo-viewer-frame { min-height: 200px; border-radius: 1.2rem; background: #eaf5f5; border: 1px solid var(--line); overflow: auto; }
.photo-viewer-frame img { width: auto; height: auto; max-width: 100%; max-height: 73vh; object-fit: contain; margin: auto; }
.photo-viewer-frame.is-original { max-height: 73vh; }
.photo-viewer-frame.is-original img { max-width: none; max-height: none; margin: 0; }
.photo-pagination { justify-content: center; margin-top: .9rem; }
.photo-editor { display: grid; gap: .65rem; min-width: 0; padding: .85rem; border: 1px solid var(--line); border-radius: .7rem; }
.photo-editor legend { padding: 0 .33rem; font-weight: 700; }
.photo-editor-row { display: grid; grid-template-columns: auto minmax(0, 1fr) 4.5rem; gap: .55rem; align-items: end; }
.photo-editor-row .gallery-thumbnail { width: 3.25rem; align-self: end; font-size: .65rem; text-align: center; }
.photo-editor-row input { min-width: 0; }
.photo-editor-row .photo-remove { grid-column: 2 / -1; }
.category-forms { display: grid; gap: .9rem; margin-top: 1rem; }
.category-forms h2 { overflow-wrap: anywhere; }
.category-actions { display: flex; flex-wrap: wrap; gap: .6rem; }

@media (max-width: 720px) {
  .hero-visual { min-height: 225px; padding: .65rem 1rem 2.75rem; }
  .hero-visual img { max-height: 255px; }
  .product-visual { padding: .4rem; }
  .photo-viewer-bar { gap: .65rem; }
}


.footer-links { display: flex; justify-content: flex-end; align-items: center; flex-wrap: wrap; gap: .55rem 1.15rem; }
.cookie-banner { position: fixed; z-index: 20; left: 50%; bottom: 1rem; width: min(680px, calc(100% - 1.5rem)); padding: clamp(1rem, 3vw, 1.45rem); transform: translateX(-50%); background: white; border: 1px solid var(--line); border-radius: 1.15rem; box-shadow: 0 1rem 3rem #12354330; }
.cookie-banner h2 { font-size: 1.25rem; }
.cookie-banner p { margin: .55rem 0 .85rem; color: var(--muted); }
.cookie-actions { display: flex; gap: .5rem; flex-wrap: wrap; }
.cookie-actions .button { border-color: var(--blue); color: var(--blue-dark); }
body:has(.cookie-banner) { padding-bottom: 12rem; }
.legal-content { display: grid; gap: 1.45rem; max-width: 76ch; }
.legal-content h1 { margin-bottom: 0; }
.legal-content section { display: grid; gap: .55rem; }
.legal-content h2 { font-size: 1.35rem; }
.legal-content a { color: var(--blue-dark); }
.legal-content ul { margin-block: 0; padding-inline-start: 1.4rem; }
.legal-content li + li { margin-top: .35rem; }
.legal-highlight { border-left: .25rem solid var(--blue); background: var(--blue-soft); padding: .8rem 1rem; }
.checkout-consent { display: flex; align-items: flex-start; gap: .6rem; }
.checkout-consent input { flex: 0 0 1.15rem; width: 1.15rem; min-height: 1.15rem; margin-top: .22rem; accent-color: var(--blue); }
.checkout-consent a { color: var(--blue-dark); }
@media (max-width: 550px) {
  .footer-links { justify-content: flex-start; }
  body:has(.cookie-banner) { padding-bottom: 15rem; }
}
