/* Catalog template (P-1013-C). Layout after the Creatium reference: cream product cards with a black frame,
   condensed uppercase titles, coral accent; one column, max 480 px. Colours come from content.php (:root vars). */
@font-face{font-family:'Roboto';font-style:normal;font-weight:300 700;font-display:swap;src:url(../fonts/roboto-cyrillic.woff2) format('woff2');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}
@font-face{font-family:'Roboto';font-style:normal;font-weight:300 700;font-display:swap;src:url(../fonts/roboto-latin.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}
@font-face{font-family:'Oswald';font-style:normal;font-weight:500;font-display:swap;src:url(../fonts/oswald-500-cyrillic.woff2) format('woff2');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}
@font-face{font-family:'Oswald';font-style:normal;font-weight:500;font-display:swap;src:url(../fonts/oswald-500-latin.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}
*{box-sizing:border-box}
html{scroll-behavior:smooth;scroll-padding-top:70px}
/* Readable on phones (Сергей 13.10, P-1013-I): body text ≥ 16 px regular, secondary ≥ 14 px, line height 1.4-1.5, WCAG AA contrast,
   tap targets ≥ 44 px, inputs ≥ 16 px (no iOS zoom). Coral #EB6856 with white text is 3.16:1, AA only for large text, so
   filled buttons carry bold ≥ 19 px labels; small coral text uses --accent-text (accent_dark darkened, ≥ 4.5:1 on white). */
:root{--accent-text:var(--accent-dark)}
@supports (color:color-mix(in srgb,red 50%,#000)){:root{--accent-text:color-mix(in srgb,var(--accent-dark) 80%,#000)}}
body{margin:0 auto;max-width:480px;background:#fff;color:var(--text);font:400 16px/1.5 'Roboto',Arial,sans-serif;-webkit-text-size-adjust:100%}
img{display:block;max-width:100%;height:auto}
button{font:inherit;cursor:pointer}
[hidden]{display:none!important}

/* sticky cart button */
.topbar{position:sticky;top:0;z-index:110;display:flex;justify-content:center;padding:10px 0;background:rgba(255,255,255,.94);backdrop-filter:blur(6px);-webkit-backdrop-filter:blur(6px);border-bottom:1px solid #eee}
.cart-btn{display:flex;align-items:center;gap:8px;min-height:46px;border:0;border-radius:999px;background:var(--accent);color:#fff;padding:8px 18px 8px 16px;font-size:19px;font-weight:700;line-height:1.2;box-shadow:0 3px 10px rgba(235,104,86,.35);transition:transform .15s}
.cart-btn:active{transform:scale(.96)}
.cart-btn svg{width:20px;height:20px;fill:#fff}
.cart-count{min-width:26px;height:26px;padding:0 7px;border-radius:13px;background:#fff;color:#222;font-weight:700;font-size:16px;line-height:26px;text-align:center}
.cart-btn.bump{animation:bump .6s ease}
.cart-btn.bump .cart-count{animation:pop .6s ease}
@keyframes bump{0%{transform:scale(1)}25%{transform:scale(1.08)}50%{transform:scale(.97)}100%{transform:scale(1)}}
@keyframes pop{0%{transform:scale(1)}30%{transform:scale(1.6);background:#ffe9e5}60%{transform:scale(.9)}100%{transform:scale(1)}}
.fly{position:fixed;z-index:120;width:56px;height:56px;border-radius:50%;object-fit:cover;border:2px solid #fff;box-shadow:0 4px 14px rgba(0,0,0,.25);pointer-events:none;transition:transform .7s cubic-bezier(.5,-.3,.7,1),opacity .7s}

/* first screen */
.hero{padding:22px 16px 26px;text-align:center;background:linear-gradient(180deg,#f4f4f4 0%,var(--cream) 100%)}
.hero-kicker{margin:0;font-size:14px;letter-spacing:2px;text-transform:uppercase;color:#595959}
.hero h1{margin:4px 0 6px;font:500 46px/1.05 'Oswald',Arial,sans-serif;text-transform:uppercase;color:var(--accent-dark)}
.hero-sub{margin:0 auto 18px;max-width:330px;font-size:19px;line-height:1.35;color:#444}
.hero-photos{position:relative;height:230px;margin:0 auto;max-width:360px}
.hero-ph{position:absolute;display:block;width:150px;height:150px;border-radius:18px;overflow:hidden;border:4px solid #fff;box-shadow:0 8px 22px rgba(0,0,0,.18)}
.hero-ph img{width:100%;height:100%;object-fit:cover}
.hero-ph0{left:50%;top:0;width:190px;height:190px;margin-left:-95px;z-index:2}
.hero-ph1{left:0;top:62px;transform:rotate(-6deg)}
.hero-ph2{right:0;top:62px;transform:rotate(6deg)}
/* The discount is a tilted round sticker, not a button (Сергей 13.10). The payment/delivery info row is gone from the first
   screen (P-1013-I п.8): it lives in the footer and the cart. */
.hero-sticker{position:absolute;right:-4px;top:-6px;z-index:3;display:flex;flex-direction:column;align-items:center;justify-content:center;width:84px;height:84px;border-radius:50%;background:#fff;border:2px dashed var(--accent);outline:3px solid #fff;color:var(--accent-text);font-size:14px;font-weight:500;line-height:1.1;transform:rotate(12deg);cursor:default;pointer-events:none}
.hero-sticker b{font:500 21px/1.05 'Oswald',Arial,sans-serif}

.section-title{margin:26px 0 14px;text-align:center;font-size:32px;font-weight:700;color:#333}

/* product cards */
.cards{padding:0 2px}
.card{margin:0 0 22px;border:2px solid #111;border-radius:8px;background:var(--cream);overflow:hidden}
/* ?p=<sku> from a catalog ad (P-1019-D): the opened card glows for ~2 s */
.card{transition:box-shadow .4s}.card.card-hit{box-shadow:0 0 0 4px var(--accent),0 6px 22px rgba(0,0,0,.18)}
.card-title{position:relative;z-index:1;margin:0;padding:12px 14px;background:#fff;box-shadow:0 4px 8px rgba(0,0,0,.18);text-align:center;font:500 22px/1.2 'Oswald',Arial,sans-serif;letter-spacing:.4px;text-transform:uppercase;color:#000}
.gallery{display:flex;overflow-x:auto;scroll-snap-type:x mandatory;scrollbar-width:none;background:#fff}
.gallery::-webkit-scrollbar{display:none}
.gallery img{flex:0 0 100%;width:100%;aspect-ratio:1/1;object-fit:cover;scroll-snap-align:center}
.dots{display:flex;justify-content:center;gap:0;padding:2px 0 0}
.card-body{padding:10px 12px 18px}
.lead{margin:6px 0 12px;font-size:17px}
.bullets{margin:0 0 10px;padding:0;list-style:none}
.bullets li{position:relative;margin:0 0 6px;padding-left:24px;font-size:17px}
.bullets li:before{content:'';position:absolute;left:3px;top:5px;width:6px;height:11px;border:solid var(--accent);border-width:0 3px 3px 0;transform:rotate(45deg)}
.specs{margin:0 0 12px}
.specs span{display:block;margin:0 0 4px;font-size:16px}
.specs b{font-weight:700}
.acc{margin:0 0 12px;border-radius:6px;background:#fff;box-shadow:0 3px 10px rgba(0,0,0,.12)}
.acc summary{position:relative;list-style:none;min-height:50px;padding:15px 44px 15px 16px;text-align:center;font-weight:500;font-size:16px;line-height:1.25;letter-spacing:2px;text-transform:uppercase;color:#111;cursor:pointer}
.acc summary::-webkit-details-marker{display:none}
.acc summary:after{content:'';position:absolute;right:20px;top:50%;width:8px;height:8px;margin-top:-6px;border:solid #222;border-width:0 2px 2px 0;transform:rotate(45deg);transition:transform .2s}
.acc[open] summary:after{transform:rotate(-135deg);margin-top:-2px}
.acc-body{padding:0 16px 16px;font-size:16px;line-height:1.5}
.price{padding:4px 0 12px;margin:0 6px 16px;text-align:center;border-bottom:1px dotted #000}
.price .old{display:block;font-size:16px;color:#595959}
.price .new{display:block;font-size:26px;color:#000}
.price .new b{font-weight:700}
.add-btn{display:block;margin:0 auto;min-width:230px;min-height:52px;padding:12px 22px;border:2px solid var(--accent);border-radius:10px;background:#fff;color:var(--accent);font-size:19px;font-weight:700;line-height:1.3;transition:background .15s,color .15s,transform .1s}
.add-btn:active{transform:scale(.97)}
.add-btn.done{background:var(--accent);color:#fff}

/* how to order */
.steps{margin-top:6px;padding:30px 20px 34px;background:var(--dark);color:#eee;text-align:center}
.steps h2{margin:0 0 16px;font:500 28px/1.2 'Oswald',Arial,sans-serif;text-transform:uppercase;color:#fff}
.step{margin:0 0 12px}
.step b{display:block;font:500 46px/1 'Oswald',Arial,sans-serif;color:#fff}
.step span{font-size:17px;line-height:1.45}
.foot{padding:18px 16px 26px;background:var(--dark);border-top:1px solid #3a3a3a;text-align:center;font-size:14px;line-height:1.5;color:#b3b3b3}
.foot a{display:inline-block;margin-bottom:6px;padding:12px 4px;color:var(--accent)}
.foot>span{display:block}

/* pop-ups */
.modal{position:fixed;inset:0;z-index:100;display:flex;align-items:center;justify-content:center;padding:76px 16px 16px;background:rgba(0,0,0,.5);animation:fade .2s}
.box{width:100%;max-width:440px;max-height:calc(100vh - 92px);overflow:auto;border-radius:8px;background:#fff;box-shadow:0 10px 40px rgba(0,0,0,.3);animation:rise .25s ease}
@keyframes fade{from{opacity:0}to{opacity:1}}
@keyframes rise{from{transform:translateY(16px);opacity:.4}to{transform:none;opacity:1}}
.box-head{display:flex;align-items:flex-start;gap:12px;padding:16px 16px 14px;border-bottom:1px solid #eee}
.box-head b{flex:1;font-weight:700;font-size:17px;line-height:1.4}
.box-form .box-head b{text-align:center}
.x{flex:0 0 44px;width:44px;height:44px;margin:-10px -10px -10px 0;border:0;background:none;font-size:32px;line-height:44px;color:#666;padding:0}
.box-added{position:relative;padding:26px 18px 22px;text-align:center}
/* cross top right in «Додано в кошик» (Сергей 13.10, P-1013-I п.4): closes like «Продовжити покупки», tap area 44 × 44 */
.x-corner{position:absolute;top:6px;right:6px;margin:0;color:#555;font-size:34px;border-radius:50%}
.x-corner:active{background:#f0f0f0}
.check{width:64px;height:64px;margin:0 auto 10px}
.check circle{fill:none;stroke:#4caf50;stroke-width:2;opacity:.3}
.check path{fill:none;stroke:#4caf50;stroke-width:4;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:40;stroke-dashoffset:40;animation:draw .45s .1s ease forwards}
@keyframes draw{to{stroke-dashoffset:0}}
.added-t{margin:0;font-size:22px;font-weight:700;color:#333}
.added-name{margin:6px 0 18px;font-size:16px;color:#555}
.btn-row{display:flex;flex-direction:column;gap:10px}
.btn-row .btn-accent{order:-1}
.btn-grey,.btn-accent{min-height:52px;border:0;border-radius:8px;padding:12px 10px;font-size:19px;font-weight:700;line-height:1.3}
.btn-grey{background:#e9e9e9;color:#444}
.btn-accent{background:var(--accent);color:#fff}
.btn-accent:active{background:var(--accent-dark)}
.btn-wide{display:block;width:100%;margin-top:6px;padding:14px;font-size:19px}
.cart-list{padding:4px 16px}
.cart-empty{padding:26px 0;text-align:center;color:#595959}
.row{display:grid;grid-template-columns:64px 1fr auto;gap:10px;align-items:center;padding:12px 0;border-bottom:1px solid #f0f0f0}
.row img{width:64px;height:64px;border-radius:6px;object-fit:cover}
.row-t{font-size:16px;line-height:1.4}
.row-p{margin-top:4px;font-size:15px;color:#555}
.row-p b{color:#000}
.qty{display:flex;align-items:center;margin-top:8px;width:max-content;border:1px solid #ddd;border-radius:8px}
.qty button{width:44px;height:44px;border:0;background:none;font-size:24px;line-height:1;color:var(--accent-text)}
.qty span{min-width:28px;text-align:center;font-size:17px;font-weight:700}
.rm{align-self:start;width:44px;height:44px;margin:-8px -10px 0 0;border:0;background:none;font-size:28px;line-height:1;color:#767676;padding:0}
.cart-foot{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:12px;padding:14px 16px 18px}
.cart-foot span{font-size:17px}
.cart-foot b{font-size:21px;font-weight:700;color:#000}
.cart-foot .btn-accent{flex:1 1 100%;padding:14px;font-size:19px}
#orderForm{padding:14px 16px 18px}
#orderForm label{display:block;margin-bottom:14px;font-size:16px;color:#333}
#orderForm label i{font-style:normal;color:#666;font-size:14px}
#orderForm label em{font-style:normal;color:#c62828}
#orderForm input{display:block;width:100%;min-height:50px;margin-top:6px;padding:12px 12px;border:1px solid #949494;border-radius:6px;font:400 17px/1.3 'Roboto',Arial,sans-serif;color:#222}
#orderForm input:focus{outline:0;border-color:var(--accent);box-shadow:0 0 0 3px rgba(235,104,86,.18)}
#orderForm input.err{border-color:#c62828;animation:shake .35s}
@keyframes shake{25%{transform:translateX(-5px)}75%{transform:translateX(5px)}}
.field-error,.form-error{margin:-6px 0 12px;font-size:15px;line-height:1.4;color:#c62828}
.order-sum{margin:2px 0 10px;font-size:16px;color:#444}
.hp{position:absolute;left:-9999px;width:1px;height:1px;opacity:0}
body.locked{overflow:hidden}
/* order accepted (P-1013-C.1) */
.box-done{padding:26px 20px 22px;text-align:center}
.check-big{width:84px;height:84px;margin:0 auto 12px;animation:popin .45s cubic-bezier(.2,1.6,.4,1)}
.check-big circle{opacity:1;stroke-width:2.5;stroke-dasharray:151;stroke-dashoffset:151;animation:ring .5s ease forwards}
.check-big path{animation-delay:.4s}
@keyframes ring{to{stroke-dashoffset:0}}
@keyframes popin{from{transform:scale(.6);opacity:0}to{transform:none;opacity:1}}
.done-t{margin:0 0 14px;font:500 26px/1.2 'Oswald',Arial,sans-serif;text-transform:uppercase;color:var(--accent-dark)}
.done-l{margin:0 0 6px;font-size:16px;color:#555}
.done-list{margin:0 0 8px;padding:10px 14px;list-style:none;border-radius:8px;background:var(--cream);text-align:left}
.done-list li{display:flex;justify-content:space-between;gap:10px;padding:5px 0;font-size:16px;line-height:1.4}
.done-list li b{white-space:nowrap}
.done-total{margin:0 0 14px;font-size:18px}
.done-total b{font-size:20px;font-weight:700;color:#000}
.done-text{margin:0 0 18px;font-size:16px;line-height:1.5;color:#444}
/* gallery: up to 5 photos, swipe / arrows / dots, counter (P-1013-E) */
.gal{position:relative;background:#fff}
/* Instagram-like swipe (Сергей 13.10, P-1013-I п.5): native horizontal scroll, so the photo follows the finger in real time with the
   browser's own inertia and direction lock (a vertical gesture scrolls the page). touch-action pan-y here used to block the
   horizontal pan completely. snap-stop always = one photo per swipe, however fast; overscroll contain = no back-swipe/bounce. */
.gallery{cursor:grab;touch-action:pan-x pan-y pinch-zoom;overscroll-behavior-x:contain;-webkit-overflow-scrolling:touch}
.gallery.drag{cursor:grabbing;scroll-snap-type:none}
.gallery img{user-select:none;-webkit-user-drag:none;scroll-snap-stop:always}
.gal-nav{position:absolute;top:50%;width:44px;height:44px;margin-top:-22px;border:0;border-radius:50%;background:rgba(255,255,255,.88);box-shadow:0 2px 8px rgba(0,0,0,.25)}
.gal-nav:after{content:'';position:absolute;top:50%;left:50%;width:10px;height:10px;border:solid #222;border-width:0 2.5px 2.5px 0}
.gal-prev{left:8px}.gal-prev:after{transform:translate(-30%,-50%) rotate(135deg)}
.gal-next{right:8px}.gal-next:after{transform:translate(-70%,-50%) rotate(-45deg)}
.gal-count{position:absolute;right:10px;bottom:10px;padding:3px 10px;border-radius:12px;background:rgba(0,0,0,.65);color:#fff;font-size:14px;line-height:1.4}
/* dots: the visible dot stays 11 px, the tap area is 32 × 44 px */
.dots button{position:relative;width:32px;height:44px;padding:0;border:0;background:none}
.dots button:before{content:'';position:absolute;left:50%;top:50%;width:11px;height:11px;margin:-6px 0 0 -6px;border-radius:50%;border:1px solid #949494;background:#fff}
.dots button.on:before{border-color:var(--accent);background:var(--accent)}
/* back to top (P-1013-E) */
.to-top-foot{display:block;min-height:46px;margin:0 auto 18px;padding:11px 26px;border:2px solid var(--accent);border-radius:999px;background:none;color:#fff;font-size:16px}
.to-top-foot:before{content:'';display:inline-block;width:9px;height:9px;margin:0 10px -1px 0;border:solid #fff;border-width:2.5px 0 0 2.5px;transform:rotate(45deg)}
.to-top{position:fixed;right:max(14px,calc(50vw - 226px));bottom:18px;z-index:90;width:48px;height:48px;border:0;border-radius:50%;background:var(--accent);box-shadow:0 4px 14px rgba(0,0,0,.28);opacity:.92;transition:opacity .2s,transform .2s}
.to-top:after{content:'';position:absolute;left:50%;top:50%;width:12px;height:12px;margin:-3px 0 0 -6px;border:solid #fff;border-width:3px 0 0 3px;transform:rotate(45deg)}
.to-top:active{transform:scale(.92)}
body.locked .to-top{display:none}
.foot{padding-bottom:84px}   /* room for the floating «вгору» (P-1013-E) */
/* доставка й оплата в сірому футері (стандарт п.10, Сергій 13.10: не формат карток товарів) */
.foot-perks{margin:0 0 20px;padding:0;list-style:none;border-bottom:1px solid #3a3a3a;text-align:left}
/* two rows, each across the whole width (Сергей 13.10, P-1013-I: «не в один ряд, а в 2 ряди, а то сильно дрібно») */
.foot-perks li{display:flex;align-items:center;gap:14px;padding:14px 4px;font-size:16px;line-height:1.4;color:#bdbdbd}
.foot-perks li+li{border-top:1px solid #3a3a3a}
.foot-perks i{flex:0 0 36px;display:flex;color:var(--accent)}
.foot-perks svg{width:36px;height:36px}
.foot-perks b{display:block;margin-bottom:2px;font-size:18px;font-weight:700;color:#f2f2f2}
.cart-perks{flex:1 1 100%;display:flex;flex-wrap:wrap;justify-content:center;gap:6px 14px;margin:-4px 0 0;font-size:14px;line-height:1.4;color:#444}
.cart-perks span{display:inline-flex;align-items:center;gap:5px}
.cart-perks i{display:inline-flex;width:18px;height:18px;color:var(--accent)}
.cart-perks svg{width:18px;height:18px}
/* відео-огляд під фото: акордеон як «Як це працює» (стандарт п.5, Сергей 13.10, P-1013-I) */
.acc-video{margin:4px 0 14px}
/* gap dots → «Відео-огляд» = gap photo → dots (17.5 px, Сергей 13.10): the dots' 44 px tap area already adds the space */
.dots + .card-body > .acc-video:first-child{margin-top:-8px}
.acc-video summary:before{content:'';display:inline-block;width:0;height:0;margin:0 10px 1px 0;border:solid transparent;border-width:7px 0 7px 11px;border-left-color:var(--accent);vertical-align:middle}
.acc-video .acc-body{padding:0 0 12px}
.vid{position:relative;aspect-ratio:1/1;background:#000}
.vid video{display:block;width:100%;height:100%;object-fit:cover}
.vid .snd{position:absolute;left:10px;bottom:10px;width:44px;height:44px;border:0;border-radius:50%;background:rgba(0,0,0,.6)}
.vid .snd:before{content:'';position:absolute;left:13px;top:15px;width:7px;height:14px;background:#fff;clip-path:polygon(0 30%,45% 30%,100% 0,100% 100%,45% 70%,0 70%)}
.vid .snd:after{content:'';position:absolute;left:23px;top:21px;width:10px;height:2px;background:#fff;transform:rotate(45deg)}
.acc-video.on .snd:after{width:6px;height:10px;top:17px;left:24px;border:solid #fff;border-width:0 2px 0 0;border-radius:0 8px 8px 0;background:none;transform:none}
