/* mobipauk — стили */
:root {
  --bg: #F6F2EE;
  --ink: #141414;
  --muted: #5E5A57;
  --muted-light: #B4B4BC;
  --line: #E4DDD6;
  --card: #FFFFFF;
  --soft: #F3ECE6;
  --body-dark: #2A2A30;
  --accent: #D7263D;
  --accent-dark: #B81F33;
  --accent-light: #FF7A84;
  --accent-tint: #FBE4E6;
  --on-accent: #FFFFFF;
  --r-lg: 32px;
  --r-md: 24px;
  --r-sm: 14px;
  --font: Inter, system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  --display: Unbounded, Inter, system-ui, sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--font); font-size: 16px; line-height: 1.45; }
a { color: var(--ink); }
a:hover { color: #3A3A40; }
img { max-width: 100%; display: block; }
button { font: inherit; color: inherit; cursor: pointer; }
input { font: inherit; }
svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }
:focus-visible { outline: 3px solid #6E7BFF; outline-offset: 2px; }
[hidden] { display: none !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- раскладка ---------- */
.wrap { max-width: 1280px; margin: 0 auto; padding-left: 24px; padding-right: 24px; }
.narrow { max-width: 760px; }
main { min-height: 60vh; padding-bottom: 56px; outline: none; }
main > .wrap { margin-top: 32px; }
main > .wrap.crumbs { margin-top: 8px; }
.row { display: flex; align-items: center; }
.wrap-row { flex-wrap: wrap; }
.between { justify-content: space-between; }
.baseline { align-items: baseline; }
.gap8 { gap: 8px; } .gap12 { gap: 12px; } .gap16 { gap: 16px; }
.grow { flex: 1 1 200px; }
.stack4, .stack8, .stack12 { display: flex; flex-direction: column; }
.stack4 { gap: 4px; } .stack8 { gap: 8px; } .stack12 { gap: 12px; }
.muted { color: var(--muted); }
.muted-light { color: var(--muted-light); }
.sm { font-size: 13px; }
.fw4 { font-weight: 400; } .fw6 { font-weight: 600; }
.center { text-align: center; }
.maxw { max-width: 760px; }
.h1, .product h1, .hero h1 { font-family: var(--display); font-weight: 800; letter-spacing: -0.02em; }
.h1 { font-size: clamp(30px, 4vw, 42px); margin: 0 0 20px; line-height: 1.05; }
.h2, h2 { font-family: var(--display); font-weight: 700; font-size: clamp(24px, 3vw, 34px); letter-spacing: -0.02em; margin: 0; }
.h2 { margin-bottom: 20px; }
.h3 { font-family: var(--display); font-weight: 700; font-size: 20px; margin: 0; }
.lead { margin: 0; font-size: 17px; color: var(--muted); }
.label { font-size: 15px; font-weight: 600; }
.panel { background: var(--card); border-radius: var(--r-md); padding: 24px; }
.panel.dark { background: var(--ink); color: #F3F3EF; }
.empty { background: var(--card); border-radius: var(--r-md); padding: 40px 24px; text-align: center; color: var(--muted); grid-column: 1 / -1; }

/* ---------- кнопки ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 22px; border-radius: 999px; border: 0; font-weight: 700; font-size: 15px; text-decoration: none; white-space: nowrap; }
.btn-lg { min-height: 56px; padding: 0 28px; font-size: 16px; }
.btn-sm { min-height: 44px; padding: 0 16px; font-size: 14px; font-weight: 600; }
.btn-dark { background: var(--ink); color: #F3F3EF; }
.btn-dark:hover { background: #2A2A30; color: #F3F3EF; }
.btn-accent { background: var(--accent); color: var(--on-accent); }
.btn-accent:hover { background: var(--accent-dark); color: var(--on-accent); }
.btn-ghost-light { border: 1.5px solid #4A4A52; color: #F3F3EF; background: transparent; }
.btn-ghost-light:hover { border-color: #F3F3EF; color: #F3F3EF; }
.btn-dashed { border: 1.5px dashed #A9A9B2; background: transparent; margin-top: 20px; }
.full { width: 100%; }
.icon-btn { width: 44px; height: 44px; border-radius: 999px; border: 1.5px solid var(--line); background: var(--card); display: inline-flex; align-items: center; justify-content: center; padding: 0; }
.icon-btn.on { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.icon-btn.plain { border: 0; background: transparent; }
.round-btn { width: 44px; height: 44px; border-radius: 999px; border: 0; background: var(--ink); color: #F3F3EF; font-size: 18px; font-weight: 700; }
.round-btn.on { background: var(--accent); color: var(--on-accent); }
.link-btn { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; border: 0; background: none; padding: 0; font-weight: 600; font-size: 15px; align-self: flex-start; }
.pill-accent { align-self: flex-start; background: var(--accent); color: var(--on-accent); font-size: 13px; font-weight: 700; padding: 6px 14px; border-radius: 999px; }
.accent-text { color: var(--accent-light); }

/* ---------- шапка ---------- */
.topbar { background: var(--ink); color: #F3F3EF; font-size: 13px; padding: 10px 24px; display: flex; justify-content: center; gap: 14px; flex-wrap: wrap; text-align: center; }
.topbar .sep { color: #8A8A92; }
.header { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; padding-top: 18px; padding-bottom: 18px; }
.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.logo svg { width: 36px; height: 36px; }
.logo span, .logo-text { font-family: var(--display); font-weight: 800; font-size: 24px; letter-spacing: -0.02em; }
.logo i, .logo-text i { font-style: normal; color: var(--accent); }
.nav { display: flex; gap: 6px 18px; flex-wrap: wrap; font-size: 15px; font-weight: 500; }
.nav a, .nav-brands a { text-decoration: none; padding: 10px 0; display: inline-flex; align-items: center; gap: 6px; }
.nav-brands { display: contents; }
.nav a.active { text-decoration: underline; text-underline-offset: 6px; text-decoration-thickness: 2px; }
.mini-badge { background: var(--ink); color: #F3F3EF; font-size: 11px; font-weight: 700; border-radius: 999px; min-width: 18px; height: 18px; display: inline-flex; align-items: center; justify-content: center; padding: 0 5px; }
.header-right { flex: 1 1 260px; display: flex; justify-content: flex-end; align-items: center; gap: 12px; }
.search { flex: 0 1 320px; display: flex; align-items: center; gap: 8px; background: var(--card); border: 1px solid var(--line); border-radius: 999px; padding: 0 16px; height: 46px; }
.search svg { color: var(--muted); width: 18px; height: 18px; }
.search input { border: 0; outline: none; background: transparent; font-size: 15px; width: 100%; min-width: 0; color: var(--ink); }
.cart-btn { position: relative; width: 46px; height: 46px; border-radius: 999px; background: var(--ink); color: #F3F3EF; display: flex; align-items: center; justify-content: center; flex: none; }
.cart-btn:hover { color: #F3F3EF; background: #2A2A30; }
.cart-badge { position: absolute; top: -4px; right: -4px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 999px; background: var(--accent); color: var(--on-accent); font-size: 12px; font-weight: 700; display: flex; align-items: center; justify-content: center; }

/* ---------- силуэты телефонов ---------- */
.ph { background: var(--body-dark); box-sizing: border-box; position: relative; flex: none; }
.ph-screen { width: 100%; height: 100%; }
.ph-sm { width: 34px; height: 68px; border-radius: 9px; padding: 3px; } .ph-sm .ph-screen { border-radius: 7px; }
.ph-md { width: 96px; height: 196px; border-radius: 22px; padding: 6px; } .ph-md .ph-screen { border-radius: 17px; }
.ph-lg { width: 220px; height: 450px; border-radius: 46px; padding: 10px; } .ph-lg .ph-screen { border-radius: 37px; }
.ph-lg::after { content: ''; position: absolute; top: 24px; left: 50%; width: 64px; height: 18px; margin-left: -32px; border-radius: 999px; background: var(--ink); }
.ph-img { object-fit: contain; }
.ph-img-sm { width: 64px; height: 80px; } .ph-img-md { width: 100%; height: 100%; } .ph-img-lg { width: 100%; height: 100%; max-height: 520px; }

/* ---------- главная ---------- */
.hero { display: flex; flex-wrap: wrap; gap: 40px; align-items: center; padding-top: 8px; padding-bottom: 8px; }
.hero-text { flex: 1 1 520px; min-width: 0; display: flex; flex-direction: column; gap: 26px; }
.hero-kicker { display: flex; align-items: center; gap: 10px; font-size: 17px; color: var(--muted); }
.pulse-dot { width: 10px; height: 10px; border-radius: 999px; background: var(--accent); animation: pulseDot 1.8s ease-in-out infinite; flex: none; }
.hero h1 { margin: 0; font-family: var(--display); font-weight: 800; font-size: clamp(40px, 6vw, 82px); line-height: 1; letter-spacing: -0.04em; }
.hero h1 span { display: block; animation: rise .8s cubic-bezier(.2,.8,.2,1) both; }
.hero h1 span:nth-child(2) { animation-delay: .14s; color: var(--accent); }
.hero p { margin: 0; font-size: 19px; line-height: 1.55; color: var(--muted); max-width: 540px; animation: rise .8s .28s cubic-bezier(.2,.8,.2,1) both; }
.hero .row { animation: rise .8s .38s cubic-bezier(.2,.8,.2,1) both; }
.btn-outline { border: 1.5px solid var(--ink); background: transparent; color: var(--ink); }
.btn-outline:hover { background: var(--ink); color: #FFFFFF; }
.hero-art { flex: 1 1 440px; min-width: 0; position: relative; height: 540px; }
.hero-circle { position: absolute; left: 50%; bottom: 0; width: 440px; height: 440px; margin-left: -200px; border-radius: 999px; background: var(--accent); animation: grow 1s cubic-bezier(.2,.8,.2,1) both; }
.hero-phones { position: absolute; left: 50%; bottom: 0; transform: translateX(-40%); display: flex; align-items: flex-end; gap: 18px; }
.hero-phones .ph { box-shadow: 0 0 0 6px #FFFFFF; animation: rise .9s cubic-bezier(.2,.8,.2,1) both; }
.ph-hero { width: 124px; height: 258px; border-radius: 28px; padding: 7px; } .ph-hero .ph-screen { border-radius: 22px; }
.ph-hero-main { width: 172px; height: 356px; border-radius: 38px; padding: 9px; animation-delay: .1s !important; } .ph-hero-main .ph-screen { border-radius: 30px; }
.ph-hero-main::after { content: ''; position: absolute; top: 20px; left: 50%; width: 52px; height: 14px; margin-left: -26px; border-radius: 999px; background: var(--ink); }
.tilt-l { rotate: -9deg; translate: 0 -6px; animation-delay: .2s !important; } .tilt-r { rotate: 9deg; translate: 0 -6px; animation-delay: .3s !important; }
.float-card { position: absolute; background: #FFFFFF; border-radius: 22px; padding: 16px 20px; box-shadow: 0 16px 40px rgba(20,20,20,.10); display: flex; flex-direction: column; gap: 2px; animation: floatY 3.2s ease-in-out infinite alternate; z-index: 2; }
.float-card b { font-family: var(--display); font-weight: 800; font-size: 26px; color: var(--accent); }
.float-card span { font-size: 14px; font-weight: 600; }
.fc-1 { left: 0; top: 110px; }
.fc-2 { right: 0; bottom: 64px; background: var(--ink); color: #FFFFFF; flex-direction: row; align-items: center; gap: 10px; font-weight: 700; font-size: 16px; animation-duration: 3.8s; animation-delay: .8s; }
.stamp { position: absolute; left: 20px; bottom: 8px; width: 140px; height: 140px; border-radius: 999px; background: #FFFFFF; box-shadow: 0 16px 40px rgba(20,20,20,.12); display: flex; align-items: center; justify-content: center; z-index: 2; }
.stamp-text { width: 140px; height: 140px; animation: spin 16s linear infinite; }
.stamp-arrow { position: absolute; width: 28px; height: 28px; color: var(--accent); stroke-width: 2.4; }
.marquee { background: var(--accent); color: #FFFFFF; overflow: hidden; white-space: nowrap; padding: 16px 0; margin-top: 32px; }
.marquee-track { display: inline-flex; gap: 44px; font-family: var(--display); font-weight: 800; font-size: 21px; padding-left: 24px; animation: marquee 24s linear infinite; }
.section-label { font-size: 15px; font-weight: 600; color: var(--accent); }
@keyframes rise { from { opacity: 0; translate: 0 36px; } to { opacity: 1; translate: 0 0; } }
@keyframes grow { from { opacity: 0; scale: .7; } to { opacity: 1; scale: 1; } }
@keyframes floatY { from { translate: 0 0; } to { translate: 0 -14px; } }
@keyframes spin { to { rotate: 360deg; } }
@keyframes marquee { to { transform: translateX(-50%); } }
@keyframes pulseDot { 0%, 100% { scale: 1; opacity: 1; } 50% { scale: 1.6; opacity: .35; } }
/* появление при прокрутке */
.reveal { opacity: 0; }
.reveal.in { opacity: 1; animation: cardIn .75s cubic-bezier(.2,.8,.2,1) both; animation-delay: calc(var(--i, 0) * 110ms); }
.reveal.instant { animation: none; }
@keyframes cardIn { from { opacity: 0; translate: 0 70px; scale: .94; } 60% { opacity: 1; } to { opacity: 1; translate: 0 0; scale: 1; } }
.chips-row { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 28px; }
.chip-btn { display: inline-flex; align-items: center; }
.sub-row { margin-top: -16px; padding: 12px; background: var(--card); border-radius: 22px; gap: 8px; animation: rise .35s ease both; }
.sub-row .chip-btn { height: 40px; padding: 0 16px; font-size: 14px; background: var(--bg); border-color: transparent; }
.sub-row .chip-btn.on { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.acc-big .acc-icon { width: 92px; height: 92px; stroke-width: 1.2; transition: transform .3s ease; }
.card:hover .acc-big .acc-icon { transform: scale(1.08) rotate(-4deg); }
.acc-big .acc-img { width: 100%; height: 100%; object-fit: contain; }
.chip-btn { height: 44px; padding: 0 20px; border-radius: 999px; border: 1.5px solid var(--line); background: var(--card); font-size: 15px; font-weight: 600; }
.chip-btn.on { background: var(--ink); color: #F3F3EF; border-color: var(--ink); }
.section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 24px; }
.seg { display: inline-flex; background: var(--card); border: 1.5px solid var(--line); border-radius: 999px; padding: 4px; gap: 4px; }
.seg button { border: 0; background: transparent; height: 40px; padding: 0 18px; border-radius: 999px; font-size: 14px; font-weight: 600; }
.seg button.on { background: var(--ink); color: #F3F3EF; }
.seg { align-self: flex-start; }
.seg-full { display: flex; align-self: stretch; } .seg-full button { flex: 1; }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 20px; }
.card { background: var(--card); border-radius: var(--r-md); padding: 16px; display: flex; flex-direction: column; gap: 14px; }
.card-link { text-decoration: none; display: flex; flex-direction: column; gap: 14px; flex: 1; }
.card-media { background: var(--soft); border-radius: 18px; height: 240px; display: flex; align-items: center; justify-content: center; position: relative; overflow: hidden; }
.badge { position: absolute; top: 12px; left: 12px; background: var(--accent); color: #F3F3EF; font-size: 12px; font-weight: 600; padding: 5px 10px; border-radius: 999px; z-index: 1; }
.card-body { display: flex; flex-direction: column; gap: 4px; padding: 0 4px; }
.card-body h3 { margin: 0; font-size: 18px; line-height: 1.25; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 6px; }
.chip { background: var(--soft); font-size: 12px; font-weight: 600; padding: 5px 10px; border-radius: 999px; }
.dots { display: flex; gap: 6px; padding: 0 4px; margin-top: auto; }
.dot { width: 16px; height: 16px; border-radius: 999px; box-shadow: inset 0 0 0 1px rgba(0,0,0,.18); }
.card-foot { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 0 4px; flex-wrap: wrap; }
.price { font-family: var(--display); font-weight: 800; font-size: 17px; color: var(--accent); }
.price-sm { font-family: var(--display); font-weight: 700; font-size: 15px; }
.price-xl { font-family: var(--display); font-weight: 800; font-size: clamp(24px, 3vw, 32px); }
.price-xl.light { color: #F3F3EF; }

.promos { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 360px), 1fr)); gap: 20px; }
main > .promos { margin-top: 56px; }
.promo { border-radius: var(--r-lg); padding: 36px; display: flex; flex-direction: column; gap: 12px; min-height: 230px; text-decoration: none; }
.promo svg { width: 40px; height: 40px; stroke-width: 1.8; }
.promo strong { font-family: var(--display); font-weight: 800; font-size: 26px; line-height: 1.1; }
.promo span { font-size: 16px; }
.promo em { margin-top: auto; font-style: normal; font-weight: 700; }
.promo-accent { background: var(--accent); color: var(--on-accent); position: relative; overflow: hidden; }
.promo-accent:hover { color: var(--on-accent); }
.promo-accent::after { content: ''; position: absolute; right: -70px; top: -70px; width: 240px; height: 240px; border-radius: 999px; border: 2px solid rgba(255,255,255,.25); }
.promo-dark { background: var(--ink); color: #F3F3EF; }
.promo-dark:hover { color: #F3F3EF; }
.promo-dark span { color: #CFC8C2; } .promo-dark em { color: var(--accent-light); }
.how { padding: clamp(24px, 4vw, 48px); border-radius: var(--r-lg); display: flex; flex-direction: column; gap: 28px; }
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 24px; }
.step { display: flex; flex-direction: column; gap: 10px; }
.step strong { font-size: 18px; }
.num { width: 44px; height: 44px; border-radius: 999px; background: var(--accent); color: var(--on-accent); font-family: var(--display); font-weight: 800; font-size: 18px; display: inline-flex; align-items: center; justify-content: center; flex: none; }

/* ---------- карточка товара ---------- */
.crumbs { display: flex; gap: 8px; flex-wrap: wrap; font-size: 14px; color: var(--muted); padding-top: 4px; }
.crumbs a { color: var(--muted); }
.product { display: flex; flex-wrap: wrap; gap: 40px; }
main > .product { margin-top: 16px; }
.product-media { flex: 1 1 440px; min-width: 0; }
.media-box { background: var(--card); border-radius: var(--r-lg); min-height: 560px; display: flex; align-items: center; justify-content: center; position: relative; padding: 24px; position: sticky; top: 16px; }
.media-box .badge { top: 20px; left: 20px; font-size: 13px; }
.product-info { flex: 1 1 400px; min-width: 0; display: flex; flex-direction: column; gap: 26px; }
.product h1 { margin: 0; font-size: clamp(32px, 4vw, 44px); line-height: 1.05; }
.opt { min-height: 46px; padding: 0 18px; border-radius: var(--r-sm); border: 1.5px solid var(--line); background: var(--card); font-size: 15px; font-weight: 600; }
.opt.on { background: var(--ink); color: #F3F3EF; border-color: var(--ink); }
.swatch { width: 44px; height: 44px; border-radius: 999px; border: 0; box-shadow: inset 0 0 0 1px rgba(0,0,0,.18); }
.swatch.on { box-shadow: 0 0 0 3px var(--bg), 0 0 0 5px var(--ink); }
.qty { display: inline-flex; align-items: center; gap: 4px; background: var(--card); border-radius: 999px; padding: 4px; align-self: flex-start; }
.qty button { width: 44px; height: 44px; border-radius: 999px; border: 0; background: var(--soft); font-size: 20px; font-weight: 600; }
.qty span { min-width: 40px; text-align: center; font-weight: 700; }
.qty-sm { flex-direction: column; gap: 2px; background: var(--soft); padding: 2px; }
.qty-sm button { width: 34px; height: 34px; background: var(--card); font-size: 16px; }
.buy { display: flex; flex-direction: column; gap: 16px; }
.installment { display: flex; flex-direction: column; gap: 16px; }
.term { min-height: 44px; padding: 0 18px; border-radius: 999px; border: 1.5px solid #4A4A52; background: transparent; color: #F3F3EF; font-weight: 600; }
.term.on { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.line-top { border-top: 1px solid #2E2E34; padding-top: 16px; }
.specs { margin: 0; border-top: 1px solid var(--line); }
.specs div { display: flex; justify-content: space-between; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.specs dt { color: var(--muted); } .specs dd { margin: 0; text-align: right; }

/* ---------- аксессуары ---------- */
.acc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 16px; }
.acc-row { display: flex; gap: 12px; overflow-x: auto; padding-bottom: 6px; scroll-snap-type: x mandatory; }
.acc-row .acc { flex: 0 0 170px; scroll-snap-align: start; }
.acc { background: var(--card); border-radius: 20px; padding: 14px; display: flex; flex-direction: column; gap: 10px; }
.acc-media { background: var(--soft); border-radius: var(--r-sm); height: 120px; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.acc-icon { width: 52px; height: 52px; stroke-width: 1.4; }
.acc-img { width: 100%; height: 100%; object-fit: contain; }

/* ---------- корзина ---------- */
.cart { display: flex; flex-direction: column; gap: 20px; }
.cart .h1 { margin-bottom: 0; }
.cart-list { display: flex; flex-direction: column; gap: 10px; }
.cart-item { background: var(--card); border-radius: 20px; padding: 12px; display: flex; gap: 12px; align-items: center; }
.cart-media { flex: none; width: 72px; height: 88px; border-radius: var(--r-sm); background: var(--soft); display: flex; align-items: center; justify-content: center; overflow: hidden; }
.cart-media .acc-icon { width: 34px; height: 34px; }
.form { display: flex; flex-direction: column; gap: 16px; }
.field { display: flex; flex-direction: column; gap: 6px; font-size: 14px; font-weight: 600; }
.field input { height: 50px; border-radius: var(--r-sm); border: 1px solid var(--line); background: #F7F7F4; padding: 0 14px; font-size: 16px; font-weight: 400; color: var(--ink); width: 100%; }
.field input:focus { border-color: var(--ink); outline: none; }
.error { color: #B3261E; font-weight: 600; margin: 0; min-height: 1px; }
.total-bar { background: var(--ink); border-radius: var(--r-md); padding: 24px; display: flex; flex-direction: column; gap: 16px; }

/* ---------- сравнение ---------- */
.check { display: inline-flex; align-items: center; gap: 10px; font-weight: 600; min-height: 44px; cursor: pointer; }
.check input { width: 20px; height: 20px; accent-color: var(--ink); }
.cmp-scroll { overflow-x: auto; border-radius: var(--r-lg); }
.cmp { display: grid; column-gap: 16px; min-width: max-content; }
.cmp-head { display: flex; flex-direction: column; gap: 10px; padding-bottom: 20px; position: relative; min-width: 200px; }
.cmp-media { background: var(--soft); border-radius: 20px; height: 220px; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.cmp-name { font-weight: 700; font-size: 18px; text-decoration: none; }
.cmp-x { position: absolute; top: 8px; right: 8px; background: var(--card) !important; z-index: 1; }
.cmp-row { grid-column: 1 / -1; display: grid; column-gap: 16px; border-top: 1px solid #E4E4DE; padding: 14px 0; font-size: 15px; }

/* ---------- обмен ---------- */
.steps-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; margin: 28px 0; }
.mini-step { background: var(--card); border-radius: 20px; padding: 16px 20px; display: flex; gap: 14px; align-items: center; font-size: 15px; }
.mini-step .num { width: 40px; height: 40px; font-size: 16px; }
.trade { display: flex; flex-wrap: wrap; gap: 28px; align-items: flex-start; }
.trade-form { flex: 999 1 520px; min-width: 0; border-radius: var(--r-lg); padding: clamp(20px, 3vw, 32px); gap: 22px; }
.state-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.opt.state { text-align: left; padding: 12px 14px; display: flex; flex-direction: column; gap: 3px; }
.opt.state span { font-size: 13px; font-weight: 400; opacity: .75; }
.f1 { flex: 1 1 160px; } .f2 { flex: 2 1 260px; }
.chat-box { flex: 1 1 340px; min-width: 0; border-radius: var(--r-lg); display: flex; flex-direction: column; gap: 16px; position: sticky; top: 16px; }
.chat { background: #1F2C24; border-radius: 20px; padding: 18px; display: flex; flex-direction: column; gap: 12px; }
.bubble { max-width: 92%; padding: 12px 16px; font-size: 14px; line-height: 1.55; white-space: pre-line; color: var(--ink); }
.bubble.me { align-self: flex-end; background: #DCF8C6; border-radius: 16px 16px 4px 16px; }
.bubble.them { align-self: flex-start; background: #FFFFFF; border-radius: 16px 16px 16px 4px; }
.chat-box .error { color: #FF8A80; }

/* ---------- подвал, плавающее ---------- */
.footer { background: var(--ink); color: #C9C9D0; margin-top: 24px; }
.footer-in { display: flex; flex-wrap: wrap; gap: 32px; justify-content: space-between; padding-top: 48px; padding-bottom: 96px; }
.footer strong, .footer .logo-text { color: #F3F3EF; }
.footer a { color: #C9C9D0; } .footer a:hover { color: #F3F3EF; }
.f-brand { flex: 1 1 260px; }
.cartbar { position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 20; max-width: 560px; margin: 0 auto; height: 60px; border-radius: 999px; background: var(--ink); color: #F3F3EF; text-decoration: none; display: flex; align-items: center; justify-content: space-between; padding: 0 8px 0 24px; box-shadow: 0 10px 30px rgba(20,20,20,.25); font-size: 15px; font-weight: 600; }
.cartbar:hover { color: #F3F3EF; }
.cartbar-btn { background: var(--accent); color: var(--on-accent); font-weight: 700; height: 44px; padding: 0 18px; border-radius: 999px; display: flex; align-items: center; }
.toast { position: fixed; left: 50%; top: 20px; transform: translate(-50%, -160%); opacity: 0; background: var(--ink); color: #F3F3EF; padding: 12px 20px; border-radius: 999px; font-weight: 600; font-size: 15px; z-index: 30; transition: transform .25s ease, opacity .25s ease; pointer-events: none; max-width: calc(100% - 32px); }
.toast.show { transform: translate(-50%, 0); opacity: 1; }

/* ---------- телефон ---------- */
@media (max-width: 720px) {
  .wrap { padding-left: 16px; padding-right: 16px; }
  .header { gap: 12px; }
  .nav { order: 3; width: 100%; overflow-x: auto; flex-wrap: nowrap; gap: 16px; }
  .nav a { white-space: nowrap; }
  .header-right { flex: 1 1 auto; }
  .search { flex: 1 1 auto; }
  .hero { padding-top: 24px; gap: 8px; }
  .hero-kicker { font-size: 14px; }
  .hero p { font-size: 16px; }
  .hero-art { height: 380px; flex-basis: 100%; }
  .hero-circle { width: 320px; height: 320px; margin-left: -160px; }
  .hero-phones { transform: translateX(-50%); gap: 10px; }
  .ph-hero { width: 82px; height: 172px; border-radius: 20px; padding: 5px; } .ph-hero .ph-screen { border-radius: 15px; }
  .ph-hero-main { width: 118px; height: 246px; border-radius: 28px; padding: 7px; } .ph-hero-main .ph-screen { border-radius: 21px; }
  .hero-phones .ph { box-shadow: 0 0 0 4px #FFFFFF; }
  .fc-1 { top: 16px; padding: 12px 16px; } .float-card b { font-size: 20px; }
  .fc-2 { display: none; }
  .stamp { left: auto; right: 4px; top: 6px; bottom: auto; width: 110px; height: 110px; } .stamp-text { width: 110px; height: 110px; }
  .marquee-track { font-size: 16px; gap: 28px; }
  .chips-row { flex-wrap: nowrap; overflow-x: auto; margin-left: -16px; margin-right: -16px; padding-left: 16px; padding-right: 16px; scrollbar-width: none; margin-bottom: 20px; }
  .chips-row::-webkit-scrollbar { display: none; }
  .chip-btn { flex: none; }
  .sub-row { margin: -8px 0 20px; padding: 10px 12px; border-radius: 18px; }
  .acc-big .acc-icon { width: 64px; height: 64px; }
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .card { padding: 10px; border-radius: 20px; gap: 10px; }
  .card-media { height: 160px; }
  .card .ph-md { width: 62px; height: 126px; border-radius: 15px; padding: 4px; } .card .ph-md .ph-screen { border-radius: 11px; }
  .card-body h3 { font-size: 15px; }
  .card-body > .muted { font-size: 13px; }
  .card-foot .btn-sm { padding: 0 12px; font-size: 13px; }
  .card-foot { gap: 8px; }
  .price { font-size: 14px; }
  .media-box { min-height: 380px; position: relative; top: 0; }
  .acc-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .acc-media { height: 96px; }
  .ph-lg { width: 160px; height: 330px; border-radius: 34px; padding: 8px; } .ph-lg .ph-screen { border-radius: 27px; }
  .chat-box { position: static; }
  .state-grid { grid-template-columns: 1fr; }
  .promo { padding: 28px; min-height: 0; }
}

/* ---------- анимации ---------- */
.btn, .chip-btn, .opt, .icon-btn, .round-btn, .term, .seg button, .swatch, .qty button, .cart-btn, .link-btn, .a-tab {
  transition: transform .16s ease, background-color .2s ease, color .2s ease, border-color .2s ease, box-shadow .2s ease;
}
.btn:hover, .chip-btn:hover, .opt:hover, .term:hover { transform: translateY(-1px); }
.btn:active, .chip-btn:active, .opt:active, .icon-btn:active, .round-btn:active, .term:active,
.seg button:active, .swatch:active, .qty button:active, .cart-btn:active, .link-btn:active, .a-tab:active { transform: scale(.94); }
.btn.done { background: var(--accent); color: var(--on-accent); animation: pop .35s ease; }
.card { transition: transform .22s ease, box-shadow .22s ease; }
.card:hover { transform: translateY(-4px); box-shadow: 0 14px 30px rgba(20,20,20,.08); }
.card-media .ph, .card-media .ph-img { transition: transform .3s ease; }
.card:hover .card-media .ph { transform: scale(1.05) rotate(-2deg); }
.card:hover .card-media img, .card:hover .acc-big img { transform: scale(1.06); }
.card-media img, .acc-big img { transition: transform .4s ease; }
.promo { transition: transform .22s ease; } .promo:hover { transform: translateY(-3px); }
.cart-btn.bump, .cartbar.bump { animation: bump .45s ease; }
.cart-btn.bump .cart-badge { animation: pop .45s ease; }
.page-in > * { animation: fadeUp .35s ease both; }
.page-in > *:nth-child(2) { animation-delay: .05s; } .page-in > *:nth-child(3) { animation-delay: .1s; } .page-in > *:nth-child(4) { animation-delay: .15s; }
.cartbar:not([hidden]) { animation: slideUp .3s ease; }
@keyframes pop { 0% { transform: scale(1); } 40% { transform: scale(1.12); } 100% { transform: scale(1); } }
@keyframes bump { 0% { transform: scale(1); } 30% { transform: scale(1.18) rotate(-8deg); } 60% { transform: scale(.95) rotate(4deg); } 100% { transform: scale(1); } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes slideUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } .reveal { opacity: 1; } }

/* ---------- подсветка в сравнении ---------- */
.cmp-cell { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; padding: 6px 10px; margin: -6px 0; border-radius: 12px; }
.cmp-cell.win { background: #E6F4EA; color: #14532D; font-weight: 600; }
.cmp-cell.lose { background: #FDECEA; color: #8C1D18; }
.cmp-tag { display: inline-block; font-size: 12px; font-weight: 700; padding: 3px 8px; border-radius: 999px; white-space: nowrap; }
.cmp-tag.win { background: #1B7A3A; color: #FFFFFF; }
.cmp-tag.lose { background: #B3261E; color: #FFFFFF; }
.cmp-legend { margin: -8px 0 16px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }

/* ---------- фото товаров: заполняют плитку целиком, без полос по краям ---------- */
.card-media img, .acc-big .acc-img, .cmp-media img, .cart-media img, .acc-media .acc-img {
  width: 100%; height: 100%; max-height: none; object-fit: cover; object-position: center; display: block;
}
.card-media:has(img), .acc-media:has(img), .cmp-media:has(img), .cart-media:has(img) { background: #E9E7E2; }
.media-box:has(img) { padding: 0; overflow: hidden; }
.media-box img.ph-img-lg { width: 100%; height: 100%; min-height: 560px; max-height: none; object-fit: cover; border-radius: inherit; }
@media (max-width: 720px) { .media-box img.ph-img-lg { min-height: 380px; } }

/* ---------- наличие и описание ---------- */
.badge.out { background: var(--ink); }
.card.sold-out .card-media img, .card.sold-out .card-media .ph, .card.sold-out .acc-icon { opacity: .45; filter: grayscale(.6); }
.opt.off { color: var(--muted); border-style: dashed; }
.opt.off small { font-size: 11px; font-weight: 700; color: var(--accent); margin-left: 4px; }
.opt.on.off { color: #FFFFFF; } .opt.on.off small { color: var(--accent-light); }
.stock-note { display: inline-block; margin-left: 8px; font-size: 12px; font-weight: 700; padding: 3px 9px; border-radius: 999px; vertical-align: 1px; }
.stock-note.ok { background: #E6F4EA; color: #14532D; }
.stock-note.low { background: #FFF1D6; color: #7A4B00; }
.stock-note.out { background: var(--accent-tint); color: #8C1D18; }
.desc { display: flex; flex-direction: column; gap: 8px; }
.desc p { margin: 0; font-size: 16px; line-height: 1.6; color: var(--ink); white-space: pre-line; }
.desc-clamp { color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; margin-top: 4px; }

/* ---------- заказ оформлен ---------- */
.done-box { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 18px; padding: clamp(28px, 5vw, 56px); border-radius: var(--r-lg); }
.done-box .h1 { margin: 0; }
.done-box .lead { max-width: 520px; }
.done-check { width: 88px; height: 88px; border-radius: 999px; background: var(--accent); display: flex; align-items: center; justify-content: center; animation: grow .6s cubic-bezier(.2,.8,.2,1) both; }
.done-check svg { width: 48px; height: 48px; color: #FFFFFF; stroke-width: 3; stroke-dasharray: 30; stroke-dashoffset: 30; animation: drawCheck .5s .35s ease forwards; }
@keyframes drawCheck { to { stroke-dashoffset: 0; } }
.done-actions { justify-content: center; }
.done-box .link-btn { align-self: center; }

/* Сравнение на телефоне: колонки моделей равной ширины, подпись характеристики над значениями */
@media (max-width: 480px) {
  .cmp-scroll { overflow-x: visible; }
  .cmp, .cmp-row { grid-template-columns: repeat(var(--n), minmax(0, 1fr)) !important; column-gap: 8px; min-width: 0; }
  .cmp > div:first-child { display: none; }
  .cmp-head { min-width: 0; gap: 6px; }
  .cmp-media { height: 130px; border-radius: 14px; }
  .cmp-name { font-size: 15px; overflow-wrap: anywhere; }
  .cmp-head .btn { min-height: 40px; padding: 0 8px; font-size: 13px; }
  .cmp-row { padding: 10px 0; font-size: 14px; }
  .cmp-row > .muted { grid-column: 1 / -1; font-size: 12px; margin-bottom: 4px; }
  .cmp-cell { padding: 6px 8px; min-width: 0; overflow-wrap: anywhere; }
  .cmp-tag { font-size: 11px; padding: 2px 6px; }
  #app, main { padding-bottom: 96px; }
}

/* ---------- реальные фото: значок, карусель, полноэкранный просмотр ---------- */
.photo-badge { position: absolute; left: 10px; bottom: 10px; z-index: 1; background: rgba(20,20,20,.78); color: #F3F3EF; font-size: 12px; font-weight: 600; padding: 5px 10px; border-radius: 999px; backdrop-filter: blur(4px); white-space: nowrap; }
.gal { position: sticky; top: 16px; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.gal-main { position: relative; border-radius: var(--r-lg); overflow: hidden; background: #E9E7E2; }
.gal-main .badge { top: 16px; left: 16px; font-size: 13px; }
.gal-track { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain; }
.gal-track::-webkit-scrollbar { display: none; }
.gal-slide { flex: 0 0 100%; scroll-snap-align: center; border: 0; padding: 0; background: none; cursor: zoom-in; aspect-ratio: 4 / 5; max-height: 640px; }
.gal-slide img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gal-arrow { position: absolute; top: 50%; transform: translateY(-50%); width: 44px; height: 44px; border-radius: 999px; border: 0; background: rgba(255,255,255,.9); color: var(--ink); font-size: 28px; line-height: 1; box-shadow: 0 4px 14px rgba(20,20,20,.18); z-index: 2; }
.gal-arrow.prev { left: 12px; } .gal-arrow.next { right: 12px; }
.gal-count { position: absolute; right: 12px; bottom: 12px; background: rgba(20,20,20,.78); color: #F3F3EF; font-size: 13px; font-weight: 600; padding: 4px 10px; border-radius: 999px; pointer-events: none; }
.gal-thumbs { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding: 2px; }
.gal-thumbs::-webkit-scrollbar { display: none; }
.gal-thumb { flex: none; width: 64px; height: 64px; padding: 0; border: 2px solid transparent; border-radius: 12px; overflow: hidden; background: #E9E7E2; opacity: .7; }
.gal-thumb.on { border-color: var(--ink); opacity: 1; }
.gal-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
@media (hover: none) { .gal-main .gal-arrow { display: none; } } /* на телефоне листаем пальцем */
@media (max-width: 720px) { .gal { position: relative; top: 0; } }

.lb { position: fixed; inset: 0; z-index: 100; background: rgba(10,10,10,.96); display: flex; align-items: center; }
.lb-track { display: flex; width: 100%; height: 100%; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; touch-action: pan-x; }
.lb-track::-webkit-scrollbar { display: none; }
.lb-slide { flex: 0 0 100%; scroll-snap-align: center; display: flex; align-items: center; justify-content: center; padding: 56px 8px; }
.lb-slide img { max-width: 100%; max-height: 100%; object-fit: contain; }
.lb-x { position: absolute; top: calc(8px + env(safe-area-inset-top)); right: 8px; z-index: 3; width: 48px; height: 48px; border-radius: 999px; border: 0; background: rgba(255,255,255,.16); color: #fff; font-size: 22px; }
.lb-count { position: absolute; top: calc(20px + env(safe-area-inset-top)); left: 16px; z-index: 3; color: #fff; font-weight: 600; font-size: 15px; }
.lb .gal-arrow { background: rgba(255,255,255,.16); color: #fff; box-shadow: none; }
@media (hover: none) { .lb .gal-arrow { display: none; } }
