/* ============================================================
   Технофорум-Полимер — дизайн-система
   Фирменный зелёный, Inter, карточки с мягкими тенями
   ============================================================ */

:root {
    --green-900: #0b3d2e;
    --green-800: #0f4a37;
    --green-700: #14593f;
    --green-600: #1a6b4c;
    --green-500: #22855e;
    --green-200: #bcd9cd;
    --green-100: #e2f0ea;
    --green-50: #f2f8f5;

    --ink: #17221d;
    --muted: #5c6b64;
    --line: #e3e9e6;
    --bg: #ffffff;
    --bg-soft: #f5f8f6;

    --card-photo-bg: #ffffff;

    --shadow-sm: 0 1px 2px rgba(16, 24, 20, .06), 0 2px 8px rgba(16, 24, 20, .05);
    --shadow-md: 0 2px 4px rgba(16, 24, 20, .06), 0 12px 28px rgba(16, 24, 20, .10);
    --shadow-lg: 0 8px 16px rgba(16, 24, 20, .10), 0 24px 48px rgba(16, 24, 20, .14);

    --radius-sm: 10px;
    --radius: 16px;
    --radius-lg: 24px;

    --container: 1200px;
    --header-h: 72px;
    --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
    margin: 0;
    font-family: var(--font);
    font-size: 16px;
    line-height: 1.6;
    color: var(--ink);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: var(--green-700);
    text-decoration: none;
}

a:hover {
    color: var(--green-500);
}

ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

h1,
h2,
h3,
h4 {
    line-height: 1.2;
    margin: 0 0 .5em;
    font-weight: 700;
    letter-spacing: -.01em;
}

.container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 24px;
}

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 13px 26px;
    border-radius: 999px;
    font-weight: 600;
    font-size: 15px;
    border: 1px solid transparent;
    cursor: pointer;
    transition: transform .15s ease, box-shadow .15s ease, background .15s ease, color .15s ease;
    white-space: nowrap;
}

.btn:active {
    transform: translateY(1px);
}

.btn-primary {
    background: var(--green-700);
    color: #fff;
    box-shadow: 0 6px 16px rgba(20, 89, 63, .28);
}

.btn-primary:hover {
    background: var(--green-600);
    color: #fff;
    box-shadow: 0 10px 22px rgba(20, 89, 63, .34);
}

.btn-ghost {
    background: #fff;
    color: var(--green-700);
    border-color: var(--green-200);
}

.btn-ghost:hover {
    background: var(--green-50);
    color: var(--green-700);
}

/* ---------- Header ---------- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, .92);
    backdrop-filter: saturate(1.4) blur(10px);
    border-bottom: 1px solid transparent;
    transition: box-shadow .2s ease, border-color .2s ease;
}

.site-header.is-scrolled {
    border-color: var(--line);
    box-shadow: var(--shadow-sm);
}

.header-inner {
    display: flex;
    align-items: center;
    gap: 28px;
    height: var(--header-h);
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.brand-logo {
    height: 40px;
    width: auto;
    flex-shrink: 0;
}

.brand-text-wrap {
    display: flex;
    flex-direction: column;
    justify-content: center;
    line-height: 1.2;
}

.brand-text {
    font-size: 17px;
    font-weight: 600;
    color: var(--ink);
    white-space: nowrap;
}

.brand-text b {
    color: var(--green-700);
    font-weight: 800;
}

.brand-subtitle {
    display: block;
    font-size: 11.5px;
    font-weight: 500;
    color: var(--muted);
    line-height: 1.3;
    margin-top: 1px;
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-left: auto;
}

.nav-link {
    padding: 8px 13px;
    border-radius: 999px;
    font-size: 15px;
    font-weight: 500;
    color: var(--ink);
    transition: background .15s ease, color .15s ease;
}

.nav-link:hover {
    background: var(--green-50);
    color: var(--green-700);
}

.nav-link.is-active {
    background: var(--green-100);
    color: var(--green-800);
    font-weight: 600;
}

.header-contacts {
    display: flex;
    flex-direction: column;
    line-height: 1.3;
}

.header-phone {
    font-weight: 700;
    font-size: 15px;
    color: var(--ink);
}

.header-phone:hover {
    color: var(--green-600);
}

.header-phone-alt {
    font-size: 13px;
    font-weight: 500;
    color: var(--muted);
}

.header-address {
    font-size: 12.5px;
    font-weight: 500;
    color: var(--muted);
    line-height: 1.3;
    display: block;
}

.burger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: 0;
    padding: 10px;
    cursor: pointer;
}

.burger span {
    display: block;
    width: 24px;
    height: 2px;
    border-radius: 2px;
    background: var(--ink);
    transition: transform .2s ease, opacity .2s ease;
}

.burger[aria-expanded="true"] span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.burger[aria-expanded="true"] span:nth-child(2) {
    opacity: 0;
}

.burger[aria-expanded="true"] span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* ---------- Hero ---------- */
.hero {
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(1200px 500px at 85% -10%, var(--green-100) 0%, transparent 60%),
        linear-gradient(180deg, #fbfdfc 0%, #f3f8f5 100%);
    border-bottom: 1px solid var(--line);
}

.hero-inner {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
    align-items: center;
    gap: 40px;
    padding-top: 72px;
    padding-bottom: 72px;
    min-height: 560px;
}

.hero-kicker {
    display: inline-block;
    margin: 0 0 18px;
    padding: 7px 14px;
    border-radius: 999px;
    background: var(--green-100);
    color: var(--green-800);
    font-size: 13px;
    font-weight: 600;
    letter-spacing: .02em;
}

.hero-title {
    font-size: clamp(30px, 4.2vw, 48px);
    font-weight: 800;
    letter-spacing: -.02em;
    color: var(--green-900);
    margin-bottom: 18px;
}

.hero-lead {
    font-size: 17px;
    color: var(--muted);
    max-width: 52ch;
    margin: 0 0 28px;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.hero-gallery {
    position: relative;
    height: 420px;
}

.hero-img {
    position: absolute;
    filter: drop-shadow(0 24px 40px rgba(16, 24, 20, .18));
    transition: transform .4s ease;
}

.hero-img-a {
    width: 78%;
    right: 0;
    top: 6%;
    z-index: 2;
}

.hero-img-b {
    width: 62%;
    left: 0;
    bottom: 0;
    z-index: 1;
    opacity: .95;
}

.hero-gallery:hover .hero-img-a {
    transform: translateY(-6px);
}

.hero-gallery:hover .hero-img-b {
    transform: translateY(4px);
}

/* ---------- Sections (общее) ---------- */
.section {
    padding: 84px 0;
}

.section-eyebrow {
    margin: 0 0 10px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--green-600);
}

.section-title {
    font-size: clamp(26px, 3vw, 36px);
    font-weight: 800;
    color: var(--green-900);
    letter-spacing: -.015em;
    margin-bottom: 18px;
}

.section-intro {
    color: var(--muted);
    max-width: 75ch;
    font-size: 16px;
}

.section-subtitle {
    font-size: 18px;
    font-weight: 600;
    color: var(--ink);
    margin: -6px 0 18px;
}

.subheading {
    font-size: 20px;
    font-weight: 700;
    color: var(--green-800);
    margin: 34px 0 18px;
}

.prose p {
    margin: 0 0 14px;
}

.prose strong {
    color: var(--green-800);
}

/* чередование фонов */
.section-company {
    background: var(--bg);
}

.section-certs {
    background: var(--bg-soft);
}

.section-novinki {
    background: var(--bg);
}

.section-emkosti {
    background: var(--bg-soft);
}

.section-banki {
    background: var(--bg);
}

.section-probki {
    background: var(--bg-soft);
}

.section-prochee {
    background: var(--bg);
}

.section-price {
    background: var(--bg-soft);
}

.section-feedback {
    background: var(--bg);
}

.section-contacts {
    background: var(--bg-soft);
    border-top: 1px solid var(--line);
}

/* ---------- О нас ---------- */
.company-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr);
    gap: 56px;
    align-items: center;
}

.company-facts {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-top: 30px;
}

.company-facts li {
    background: var(--green-50);
    border: 1px solid var(--green-100);
    border-radius: var(--radius);
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.fact-num {
    font-size: 24px;
    font-weight: 800;
    color: var(--green-700);
}

.fact-label {
    font-size: 13px;
    color: var(--muted);
    line-height: 1.35;
}

.company-photo {
    margin: 0;
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: var(--card-photo-bg);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--line);
}

.company-photo img {
    width: 100%;
    object-fit: cover;
}

/* ---------- Сертификаты ---------- */
.certs-track {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding: 6px 2px 18px;
    scrollbar-width: thin;
    scrollbar-color: var(--green-200) transparent;
}

.certs-track::-webkit-scrollbar {
    height: 8px;
}

.certs-track::-webkit-scrollbar-thumb {
    background: var(--green-200);
    border-radius: 8px;
}

.cert-item {
    flex: 0 0 auto;
    width: 300px;
    margin: 0;
    scroll-snap-align: start;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: transform .2s ease, box-shadow .2s ease;
}

.cert-item:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.cert-item img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
}

.certs-nav {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 8px;
}

.certs-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid var(--green-200);
    background: #fff;
    color: var(--green-700);
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    transition: background .15s ease, transform .15s ease;
}

.certs-btn:hover {
    background: var(--green-50);
    transform: scale(1.05);
}

/* ---------- Продукция ---------- */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(215px, 1fr));
    gap: 22px;
    margin-top: 30px;
}

.product-grid-wide {
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
}

.product-card {
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: var(--green-200);
}

.product-media {
    position: relative;
    display: block;
    width: 100%;
    aspect-ratio: 1 / 1;
    padding: 0;
    border: 0;
    background: var(--card-photo-bg);
    cursor: zoom-in;
    overflow: hidden;
}

.product-media::after {
    content: "⌕";
    position: absolute;
    right: 10px;
    bottom: 8px;
    font-size: 15px;
    color: var(--green-700);
    background: rgba(255, 255, 255, .85);
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    opacity: 0;
    transform: translateY(4px);
    transition: opacity .2s ease, transform .2s ease;
    pointer-events: none;
}

.product-card:hover .product-media::after {
    opacity: 1;
    transform: translateY(0);
}

.product-media img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 18px;
    transition: transform .25s ease;
}

.product-card:hover .product-media img {
    transform: scale(1.05);
}

.product-info {
    padding: 16px 18px 18px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    flex: 1;
}

.product-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--ink);
    margin: 0;
    line-height: 1.35;
}

.product-specs {
    display: flex;
    flex-direction: column;
    gap: 3px;
    font-size: 13px;
    color: var(--muted);
}

.product-specs li {
    display: flex;
    gap: 6px;
}

.product-specs li::before {
    content: "·";
    color: var(--green-500);
    font-weight: 700;
}

/* ---------- Цены ---------- */
.price-heading {
    font-size: 17px;
    font-weight: 600;
    color: var(--ink);
    margin-bottom: 28px;
}

.price-block {
    margin-bottom: 36px;
}

.price-block:last-child {
    margin-bottom: 0;
}

.price-block-title {
    font-size: 19px;
    font-weight: 700;
    color: var(--green-800);
    margin-bottom: 14px;
}

.table-wrap {
    overflow-x: auto;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.price-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14.5px;
    min-width: 640px;
}

.price-table th,
.price-table td {
    text-align: left;
    padding: 12px 18px;
}

.price-table thead th {
    background: var(--green-700);
    color: #fff;
    font-weight: 600;
    font-size: 13.5px;
    letter-spacing: .02em;
    white-space: nowrap;
}

.price-table tbody tr {
    border-top: 1px solid var(--line);
}

.price-table tbody tr:nth-child(even) {
    background: var(--green-50);
}

.price-table tbody tr:hover {
    background: var(--green-100);
}

.price-table td:first-child {
    font-weight: 600;
    color: var(--ink);
}

.price-table td:last-child {
    font-weight: 700;
    color: var(--green-800);
    white-space: nowrap;
}

/* ---------- Обратная связь ---------- */
.feedback-grid {
    display: grid;
    grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr);
    gap: 56px;
    align-items: center;
}

.feedback-photo {
    margin: 0;
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: var(--card-photo-bg);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-md);
}

.feedback-photo img {
    width: 100%;
    object-fit: cover;
}

.feedback-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
    margin-top: 6px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
}

.field {
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.field-label {
    font-size: 14px;
    font-weight: 600;
    color: var(--ink);
}

.field-label i {
    color: #c0392b;
    font-style: normal;
}

.field input,
.field textarea {
    font: inherit;
    color: var(--ink);
    background: #fff;
    border: 1.5px solid var(--line);
    border-radius: var(--radius-sm);
    padding: 12px 14px;
    transition: border-color .15s ease, box-shadow .15s ease;
    resize: vertical;
}

.field input:focus,
.field textarea:focus {
    outline: none;
    border-color: var(--green-500);
    box-shadow: 0 0 0 4px rgba(34, 133, 94, .14);
}

.field input::placeholder,
.field textarea::placeholder {
    color: #9aa8a1;
}

.form-actions {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.form-note {
    font-size: 13px;
    color: var(--muted);
    margin: 0;
}

.form-success {
    margin: 0;
    color: var(--green-700);
    font-weight: 600;
}

/* ---------- Контакты ---------- */
.contacts-grid {
    display: grid;
    grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
    gap: 40px;
    align-items: stretch;
}

.contacts-info {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    padding: 32px;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    gap: 22px;
}

.contacts-company {
    font-size: 19px;
    font-weight: 800;
    color: var(--green-900);
    margin: 0;
}

.contacts-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.contact-item {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.contact-label {
    font-size: 12.5px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--muted);
}

.contact-value {
    font-size: 16px;
    color: var(--ink);
}

.contact-value a {
    font-weight: 600;
}

.contacts-map {
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--line);
    box-shadow: var(--shadow-sm);
    min-height: 380px;
}

.contacts-map iframe {
    width: 100%;
    height: 100%;
    min-height: 380px;
    border: 0;
    display: block;
}

/* ---------- Footer ---------- */
.site-footer {
    background: #dcdcdc;
    color: #333;
    padding: 56px 0 0;
    margin-top: 0;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.3fr 1fr 1fr 1.2fr;
    gap: 40px;
    padding-bottom: 40px;
}

.footer-logo {
    height: 44px;
    width: auto;
    margin-bottom: 14px;
    filter: opacity(.92);
}

.footer-motto {
    font-size: 14px;
    color: #555;
    margin: 0;
}

.footer-col-title {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: #333;
    margin-bottom: 14px;
}

.footer-links li,
.footer-contacts li {
    margin-bottom: 9px;
    font-size: 14.5px;
}

.footer-links a,
.footer-contacts a {
    color: var(--green-700);
    transition: color .15s ease;
}

.footer-links a:hover,
.footer-contacts a:hover {
    color: var(--green-600);
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    border-top: 1px solid rgba(0, 0, 0, .1);
    padding: 18px 24px 22px;
    font-size: 13.5px;
    color: #666;
}

.footer-top {
    color: var(--green-700);
    font-weight: 600;
}

.footer-top:hover {
    color: var(--green-600);
}

/* ---------- Lightbox ---------- */
.lightbox {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.lightbox.is-open {
    display: flex;
}

.lightbox-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(10, 20, 15, .72);
    backdrop-filter: blur(4px);
}

.lightbox-figure {
    position: relative;
    margin: 0;
    max-width: 920px;
    width: 100%;
    background: #fff;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    animation: lb-in .22s ease;
}

@keyframes lb-in {
    from {
        opacity: 0;
        transform: translateY(14px) scale(.98);
    }

    to {
        opacity: 1;
        transform: none;
    }
}

.lightbox-body {
    display: flex;
    flex-direction: column;
    width: 100%;
    background: var(--card-photo-bg);
}

.lightbox-img {
    width: 100%;
    max-height: 70vh;
    object-fit: contain;
    background: var(--card-photo-bg);
    padding: 24px;
    margin: 0 auto;
}

.lightbox-caption {
    padding: 24px 28px 28px;
    display: flex;
    flex-direction: column;
    gap: 14px;
    border-top: 1px solid var(--line);
    background: #fff;
}

.lightbox-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--green-900);
    margin: 0;
}

.lightbox-specs {
    display: flex;
    flex-direction: column;
    gap: 3px;
    font-size: 13px;
    color: var(--muted);
    margin-top: 8px;
}

.lightbox-specs li {
    display: flex;
    gap: 6px;
    padding: 0;
    background: transparent;
    border: none;
    border-radius: 0;
}

.lightbox-specs li::before {
    content: "·";
    color: var(--green-500);
    font-weight: 700;
    flex-shrink: 0;
}

.lightbox-close,
.lightbox-nav {
    position: absolute;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: 0;
    background: rgba(255, 255, 255, .92);
    color: var(--ink);
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
    display: grid;
    place-items: center;
    box-shadow: var(--shadow-sm);
    transition: background .15s ease, transform .15s ease;
    z-index: 2;
}

.lightbox-close:hover,
.lightbox-nav:hover {
    background: #fff;
    transform: scale(1.06);
}

.lightbox-close {
    top: 14px;
    right: 14px;
}

.lightbox-prev {
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
}

.lightbox-next {
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
}

.lightbox-prev:hover {
    transform: translateY(-50%) scale(1.06);
}

.lightbox-next:hover {
    transform: translateY(-50%) scale(1.06);
}

/* ---------- 404 ---------- */
.section-404 {
    padding: 120px 0;
    text-align: center;
    background: var(--bg-soft);
}

.section-404 .hero-actions {
    justify-content: center;
    margin-top: 26px;
}

/* ---------- Reveal on scroll (parallax) ---------- */
.reveal {
    opacity: 0;
    transform: translateY(36px);
    transition: opacity .7s cubic-bezier(.22,.61,.36,1), transform .7s cubic-bezier(.22,.61,.36,1);
}

.reveal.in-view {
    opacity: 1;
    transform: translateY(0);
}

/* Разные направления появления для разнообразия */
.reveal-from-left {
    transform: translateX(-40px) translateY(10px);
}

.reveal-from-left.in-view {
    transform: translateX(0) translateY(0);
}

.reveal-from-right {
    transform: translateX(40px) translateY(10px);
}

.reveal-from-right.in-view {
    transform: translateX(0) translateY(0);
}

.reveal-scale {
    transform: scale(.94) translateY(18px);
}

.reveal-scale.in-view {
    transform: scale(1) translateY(0);
}

/* Задержки для каскадного эффекта */
.reveal-delay-1 { transition-delay: .08s; }
.reveal-delay-2 { transition-delay: .16s; }
.reveal-delay-3 { transition-delay: .24s; }
.reveal-delay-4 { transition-delay: .32s; }

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
}

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
    .header-contacts {
        display: none;
    }

    .main-nav {
        gap: 0;
    }

    .nav-link {
        padding: 8px 10px;
        font-size: 14px;
    }
}

@media (max-width: 900px) {
    :root {
        --header-h: 64px;
    }

    .section {
        padding: 60px 0;
    }

    .burger {
        display: flex;
    }

    .main-nav {
        position: fixed;
        top: var(--header-h);
        left: 0;
        right: 0;
        flex-direction: column;
        align-items: stretch;
        gap: 2px;
        background: #fff;
        border-bottom: 1px solid var(--line);
        box-shadow: var(--shadow-md);
        padding: 10px 16px 16px;
        margin: 0;
        transform: translateY(-12px);
        opacity: 0;
        visibility: hidden;
        transition: transform .2s ease, opacity .2s ease, visibility .2s;
    }

    .main-nav.is-open {
        transform: none;
        opacity: 1;
        visibility: visible;
    }

    .nav-link {
        padding: 12px 14px;
        border-radius: var(--radius-sm);
        font-size: 16px;
    }

    .header-contacts {
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: 10px;
        position: fixed;
        top: var(--header-h);
        left: 0;
        right: 0;
        background: #fff;
        border-bottom: 1px solid var(--line);
        box-shadow: var(--shadow-md);
        padding: 10px 24px 14px;
        transform: translateY(-12px);
        opacity: 0;
        visibility: hidden;
        transition: transform .2s ease .05s, opacity .2s ease .05s, visibility .2s .05s;
    }

    .main-nav.is-open+.header-contacts,
    .header-contacts.is-open {
        transform: none;
        opacity: 1;
        visibility: visible;
    }

    .hero-inner {
        grid-template-columns: 1fr;
        gap: 30px;
        padding-top: 48px;
        padding-bottom: 56px;
        min-height: 0;
    }

    .hero-title {
        font-size: 32px;
    }

    .hero-lead {
        font-size: 16px;
    }

    .hero-gallery {
        height: 300px;
        max-width: 560px;
    }

    .company-grid {
        grid-template-columns: 1fr;
        gap: 36px;
    }

    .company-photo {
        max-width: 520px;
    }

    .company-facts {
        grid-template-columns: 1fr 1fr;
    }

    .cert-item {
        width: 240px;
    }

    .product-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
        gap: 14px;
    }

    .product-media img {
        padding: 12px;
    }

    .product-info {
        padding: 12px 14px 14px;
    }

    .product-title {
        font-size: 14px;
    }

    .product-specs {
        font-size: 12px;
    }

    .feedback-grid {
        grid-template-columns: 1fr;
        gap: 36px;
    }

    .feedback-photo {
        max-width: 420px;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .contacts-grid {
        grid-template-columns: 1fr;
    }

    .contacts-map {
        min-height: 300px;
    }

    .contacts-map iframe {
        min-height: 300px;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 30px;
    }

    .footer-brand {
        grid-column: 1 / -1;
    }

    .lightbox-figure {
        max-width: 480px;
    }

    .lightbox-img {
        padding: 16px;
    }

    .lightbox-caption {
        padding: 18px 20px 20px;
        gap: 10px;
    }

    .lightbox-title {
        font-size: 17px;
    }

    .lightbox-specs {
        font-size: 13px;
    }

    .lightbox-prev,
    .lightbox-next {
        display: none;
    }
}

@media (max-width: 520px) {
    .brand-text {
        display: none;
    }

    .brand-subtitle {
        display: none;
    }

    .brand-logo {
        height: 34px;
    }

    .header-address {
        display: none;
    }

    .hero-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .btn {
        width: 100%;
    }

    .company-facts {
        grid-template-columns: 1fr;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }

    .footer-bottom {
        justify-content: center;
        text-align: center;
    }
}