:root {
    --bg: #14171C;
    --bg-raised: #1C2027;
    --bg-card: #20242C;
    --ink: #E8EAED;
    --ink-soft: #9BA3AF;
    --amber: #F59E0B;
    --amber-dark: #D97706;
    --green: #22C55E;
    --green-dark: #16A34A;
    --line: #2A2F38;
    --line-strong: #3A404C;
    --radius: 14px;
    --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    font-family: var(--sans);
    background: var(--bg);
    color: var(--ink);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    opacity: 0;
    animation: pageFadeIn .5s ease forwards;
}
@keyframes pageFadeIn { from { opacity: 0; } to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) {
    body { animation: none; opacity: 1; }
    html { scroll-behavior: auto; }
}

.container { max-width: 1080px; margin: 0 auto; padding: 0 20px; }
a { color: var(--amber); }
a:hover { color: var(--amber-dark); }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 2px; }
img, picture { max-width: 100%; height: auto; display: block; }

/* ===== Scroll-reveal ===== */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .55s ease, transform .55s ease; }
.reveal.in-view { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } }

/* ===== Header ===== */
.site-header {
    background: rgba(20,23,28,.92);
    backdrop-filter: blur(8px);
    position: sticky; top: 0; z-index: 50;
    border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 66px; }
.logo { display: flex; align-items: center; gap: 9px; font-weight: 800; font-size: 1.05rem; color: var(--ink); }
.logo:hover { color: var(--ink); text-decoration: none; }
.logo .mark { width: 30px; height: 30px; border-radius: 8px; background: linear-gradient(135deg, var(--amber), var(--amber-dark)); flex: none; display: flex; align-items: center; justify-content: center; font-weight: 800; color: #14171C; font-size: .8rem; }
.logo small { color: var(--ink-soft); font-weight: 500; font-size: .72rem; }

.nav-toggle { display: none; flex-direction: column; gap: 4px; background: none; border: 0; cursor: pointer; padding: 8px; }
.nav-toggle span { width: 22px; height: 2px; background: var(--ink); display: block; }

.main-nav > ul { list-style: none; display: flex; gap: 2px; margin: 0; padding: 0; align-items: center; }
.main-nav > ul > li > a { color: var(--ink-soft); padding: 9px 12px; display: inline-block; font-size: .89rem; font-weight: 600; border-radius: 8px; }
.main-nav > ul > li > a:hover { background: var(--bg-raised); color: var(--ink); text-decoration: none; }
.dropdown { position: relative; }
.dropdown-menu { display: none; position: absolute; left: 0; top: 100%; background: var(--bg-card); border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 16px 32px rgba(0,0,0,.4); padding: 6px; min-width: 240px; list-style: none; margin: 8px 0 0; }
.dropdown:hover .dropdown-menu, .dropdown:focus-within .dropdown-menu { display: block; }
.dropdown-menu li a { color: var(--ink); display: block; padding: 9px 10px; border-radius: 6px; font-size: .89rem; }
.dropdown-menu li a:hover { background: var(--bg-raised); text-decoration: none; }

/* ===== Layout ===== */
.main-content { padding: 36px 0 64px; min-height: 55vh; }
h1 { font-weight: 800; font-size: clamp(1.6rem, 3vw, 2.35rem); line-height: 1.22; margin: 6px 0 20px; color: #fff; letter-spacing: -0.01em; }
h2 { font-weight: 800; font-size: 1.35rem; margin: 34px 0 14px; color: #fff; }
h3 { font-size: 1.05rem; margin: 0 0 8px; color: var(--ink); }
p { margin: 0 0 14px; }
.lede { font-size: 1.06rem; color: var(--ink-soft); max-width: 680px; }
.muted { color: var(--ink-soft); font-size: .92rem; }
.article ul:not([class]), .article ol:not([class]) { padding-left: 22px; }
.article li { margin-bottom: 7px; }

.crumbs { margin: 0 0 8px; }
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; font-size: .84rem; color: var(--ink-soft); }
.crumbs li:not(:last-child)::after { content: "/"; margin-left: 6px; color: var(--line-strong); }
.crumbs [aria-current] { color: var(--ink); }

/* ===== Download CTA — зелёные, по требованию ===== */
.dl-cta { margin: 24px 0; }
.btn-dl {
    display: inline-flex; flex-direction: column; gap: 3px;
    padding: 16px 24px; border-radius: 12px;
    background: linear-gradient(135deg, var(--green), var(--green-dark));
    color: #06210F !important; text-decoration: none !important;
    box-shadow: 0 10px 24px rgba(34,197,94,.28);
    transition: transform .15s ease, box-shadow .15s ease;
}
.btn-dl:hover { transform: translateY(-2px); box-shadow: 0 14px 28px rgba(34,197,94,.36); }
.btn-dl span { font-weight: 800; font-size: 1.05rem; }
.btn-dl small { font-weight: 600; font-size: .8rem; opacity: .8; }

/* ===== Hero ===== */
.hero-banner { border-radius: var(--radius); overflow: hidden; margin: 18px 0 8px; border: 1px solid var(--line); box-shadow: 0 20px 40px rgba(0,0,0,.35); }

/* ===== Photo steps ===== */
.photo-steps { display: grid; gap: 20px; margin: 20px 0; }
.photo-step { display: grid; grid-template-columns: 280px 1fr; gap: 20px; background: var(--bg-card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; align-items: center; }
.photo-step .shot { border-radius: 8px; overflow: hidden; border: 1px solid var(--line); }
.photo-step-num { display: inline-flex; align-items: center; justify-content: center; width: 26px; height: 26px; border-radius: 50%; background: var(--amber); color: #14171C; font-weight: 800; font-size: .8rem; margin-right: 8px; }
.photo-step h3 { display: inline; }
.photo-step p:last-child { margin-bottom: 0; }

/* ===== Steps ===== */
ol.steps { counter-reset: step; list-style: none; display: grid; gap: 12px; padding-left: 0 !important; margin: 0; }
ol.steps li { counter-increment: step; position: relative; padding: 13px 16px 13px 48px; background: var(--bg-card); border: 1px solid var(--line); border-radius: 10px; }
ol.steps li::before { content: counter(step); position: absolute; left: 13px; top: 13px; width: 22px; height: 22px; border-radius: 50%; background: var(--amber); color: #14171C; font-weight: 800; font-size: .78rem; display: flex; align-items: center; justify-content: center; }

/* ===== Spec table ===== */
.spec-table { width: 100%; max-width: 620px; border-collapse: collapse; background: var(--bg-card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; font-size: .93rem; margin: 16px 0 20px; }
.spec-table th, .spec-table td { padding: 11px 16px; text-align: left; border-bottom: 1px solid var(--line); }
.spec-table tr:last-child th, .spec-table tr:last-child td { border-bottom: none; }
.spec-table th { color: var(--ink-soft); font-weight: 600; white-space: nowrap; width: 38%; }

/* ===== Notices ===== */
.notice { border-radius: var(--radius); padding: 16px 18px; margin: 18px 0; border-left: 4px solid var(--amber); background: rgba(245,158,11,.08); }
.notice.warn { border-left-color: #EF4444; background: rgba(239,68,68,.08); }
.notice.ok { border-left-color: var(--green); background: rgba(34,197,94,.08); }
.notice p:last-child { margin-bottom: 0; }

/* ===== FAQ ===== */
.faq details { background: var(--bg-card); border: 1px solid var(--line); border-radius: 10px; padding: 14px 16px; margin: 0 0 10px; }
.faq summary { cursor: pointer; font-weight: 700; color: #fff; }
.faq details[open] summary { margin-bottom: 8px; }

/* ===== Cards ===== */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; margin-top: 16px; }
.card-link { display: block; background: var(--bg-card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; color: var(--ink); }
.card-link:hover { border-color: var(--amber); text-decoration: none; }
.card-link b { display: block; margin-bottom: 4px; color: #fff; }
.card-link span { display: block; font-size: .87rem; color: var(--ink-soft); }

/* ===== Footer ===== */
.site-footer { background: #0E1013; color: rgba(255,255,255,.7); padding: 34px 0; margin-top: 48px; font-size: .9rem; border-top: 1px solid var(--line); }
.footer-inner { display: grid; gap: 14px; }
.site-footer a { color: #fff; }
.footer-nav { display: flex; flex-wrap: wrap; gap: 14px; }
.copyright { color: rgba(255,255,255,.42); margin: 0; }

/* ===== Cookie banner ===== */
.cookie-banner { position: fixed; left: 0; right: 0; bottom: 0; z-index: 100; background: #0E1013; color: rgba(255,255,255,.9); padding: 16px 0; box-shadow: 0 -10px 30px rgba(0,0,0,.4); border-top: 1px solid var(--line); }
.cookie-banner[hidden] { display: none; }
.cookie-banner__inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px; }
.cookie-banner p { margin: 0; font-size: .9rem; max-width: 640px; }
.cookie-banner a { color: var(--amber); text-decoration: underline; }
.cookie-banner__actions { display: flex; gap: 10px; flex: none; }
.cookie-banner__actions button { font-family: inherit; font-weight: 700; padding: 10px 18px; border-radius: 8px; cursor: pointer; font-size: .9rem; border: 0; }
.cookie-banner__actions .btn-agree { background: var(--green); color: #06210F; }
.cookie-banner__actions .btn-decline { background: transparent; color: #fff; border: 2px solid var(--line-strong) !important; }

/* ===== Responsive ===== */
@media (max-width: 780px) {
    .nav-toggle { display: flex; }
    .main-nav { display: none; position: absolute; left: 0; right: 0; top: 66px; background: var(--bg-card); border-top: 1px solid var(--line); padding: 8px 16px 16px; }
    .main-nav.open { display: block; }
    .main-nav > ul { flex-direction: column; align-items: stretch; }
    .dropdown-menu { position: static; box-shadow: none; border: none; background: var(--bg-raised); }
    .photo-step { grid-template-columns: 1fr; }
    h1 { font-size: 1.55rem; }
    .cookie-banner__inner { flex-direction: column; align-items: stretch; text-align: left; }
    .cookie-banner__actions button { flex: 1; text-align: center; }
}
