/* ==========================================================================
   LINYANG ENERGY STORAGE - PREMIUM STYLESHEET
   ========================================================================== */

/* --- Design Tokens & CSS Variables --- */
:root {
    --font-heading: 'Manrope', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --font-body: 'Manrope', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

    /* Color Palette */
    --clr-primary: hsl(164, 85%, 26%);       /* Deep Forest Green */
    --clr-primary-light: hsl(164, 80%, 35%);
    --clr-accent: hsl(158, 82%, 46%);        /* Bright Mint / Electric Green */
    --clr-secondary: hsl(192, 90%, 32%);     /* Deep Ocean Cyan */
    
    --clr-dark-bg: #0b151b;                  /* Rich Space Black for dark sections */
    --clr-dark-card: #15222b;
    --clr-light-bg: hsl(200, 20%, 98%);       /* Ice / Soft Grey background */
    --clr-white: #ffffff;
    
    --txt-dark: hsl(209, 32%, 14%);          /* Near Black */
    --txt-muted: hsl(209, 13%, 45%);         /* Slate Grey */
    --txt-light: hsl(209, 10%, 95%);
    
    /* GRadients */
    --grad-primary: linear-gradient(135deg, var(--clr-primary) 0%, var(--clr-secondary) 100%);
    --grad-accent: linear-gradient(135deg, var(--clr-accent) 0%, var(--clr-primary-light) 100%);
    --grad-dark: linear-gradient(180deg, #0b151b 0%, #152632 100%);
    --grad-overlay: linear-gradient(to right, rgba(11, 21, 27, 0.85) 0%, rgba(11, 21, 27, 0.4) 100%);
    --grad-solar: linear-gradient(135deg, hsl(38, 92%, 58%) 0%, hsl(158, 82%, 40%) 100%);
    --grad-battery: linear-gradient(135deg, hsl(192, 90%, 32%) 0%, hsl(164, 85%, 22%) 100%);
    --grad-cable: linear-gradient(135deg, hsl(262, 70%, 48%) 0%, hsl(222, 70%, 42%) 100%);
    --grad-allinone: linear-gradient(135deg, hsl(205, 85%, 45%) 0%, hsl(170, 70%, 36%) 100%);

    /* UI Tokens */
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    
    --shadow-sm: 0 4px 10px rgba(0, 0, 0, 0.03);
    --shadow-md: 0 10px 30px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 20px 50px rgba(0, 0, 0, 0.12);
    --shadow-glow: 0 15px 35px rgba(22, 163, 115, 0.2);

    /* Exact brand green from the BAT-BOX logo mark (the two squares) */
    --clr-logo-green: #5EA540;
    --shadow-glow-logo: 0 12px 30px rgba(94, 165, 64, 0.45);

    --transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    --header-height: 80px;
    --container-width: 1200px;
}

/* --- Base & Reset Styles --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    background-color: var(--clr-light-bg);
}

body {
    font-family: var(--font-body);
    color: var(--txt-dark);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
    font-family: var(--font-heading);
    font-weight: 800;
    letter-spacing: -0.01em;
    line-height: 1.2;
}

a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition);
}

ul {
    list-style: none;
}

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

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

/* --- Scroll Fade-in-up effect --- */
.fade-in-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 1.2s cubic-bezier(0.16, 1, 0.3, 1),
                transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.fade-in-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.95rem;
    padding: 12px 28px;
    border-radius: 50px;
    border: none;
    cursor: pointer;
    transition: var(--transition);
    white-space: nowrap;
}

.btn-primary {
    background: var(--grad-primary);
    color: var(--clr-white);
    box-shadow: var(--shadow-sm);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-glow);
    background: linear-gradient(135deg, var(--clr-primary-light) 0%, var(--clr-accent) 100%);
}

.btn-outline {
    background: transparent;
    color: var(--clr-white);
    border: 2px solid rgba(255, 255, 255, 0.4);
}

.btn-outline:hover {
    background: var(--clr-white);
    color: var(--txt-dark);
    border-color: var(--clr-white);
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.btn-lg {
    padding: 16px 36px;
    font-size: 1.05rem;
}

.w-full {
    width: 100%;
}

/* --- Header Section (Glassmorphism) --- */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(230, 235, 240, 0.7);
    z-index: 1000;
    transition: var(--transition);
}

.site-header.scrolled {
    height: 70px;
    background: rgba(255, 255, 255, 0.95);
    box-shadow: var(--shadow-sm);
}

.header-container {
    height: 100%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    display: flex;
    flex-direction: column;
}

.logo-img {
    height: 44px;
    width: auto;
    display: block;
    transition: var(--transition);
}

.site-header.scrolled .logo-img {
    height: 38px;
}

.logo-accent {
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.5rem;
    color: var(--clr-primary);
    letter-spacing: 0.05em;
    line-height: 1;
}

.logo-sub {
    font-size: 0.65rem;
    font-weight: 700;
    color: var(--clr-secondary);
    letter-spacing: 0.25em;
    margin-top: 2px;
}

.main-nav {
    display: flex;
    gap: 32px;
}

.nav-link {
    font-weight: 700;
    font-size: 1.02rem;
    color: var(--txt-dark);
    position: relative;
    padding: 6px 0;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--clr-primary);
    transition: var(--transition);
}

.nav-link:hover, .nav-link.active {
    color: var(--clr-primary);
}

.nav-link:hover::after, .nav-link.active::after {
    width: 100%;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 24px;
}

/* --- Language Switcher (UA / RU / EN) --- */
.lang-switch {
    display: flex;
    align-items: center;
    gap: 2px;
    background: var(--clr-light-bg);
    border: 1px solid rgba(220, 225, 230, 0.9);
    border-radius: 50px;
    padding: 3px;
}

.lang-btn {
    font-family: var(--font-heading);
    font-size: 0.85rem;
    font-weight: 800;
    letter-spacing: 0.03em;
    color: var(--txt-dark);
    background: transparent;
    border: none;
    padding: 6px 12px;
    border-radius: 50px;
    cursor: pointer;
    transition: var(--transition);
}

.lang-btn:hover {
    color: var(--clr-primary);
}

.lang-btn.active {
    background: var(--clr-white);
    color: var(--clr-primary);
    box-shadow: var(--shadow-sm);
}

.mobile-nav-footer .lang-switch {
    align-self: flex-start;
}

.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 24px;
    height: 18px;
    background: transparent;
    border: none;
    cursor: pointer;
    z-index: 1001;
}

.mobile-menu-toggle .bar {
    width: 100%;
    height: 2px;
    background-color: var(--txt-dark);
    border-radius: 2px;
    transition: var(--transition);
}

/* --- Mobile Drawer Menu --- */
.mobile-drawer {
    position: fixed;
    top: 0;
    right: -100%;
    width: 300px;
    height: 100vh;
    background: var(--clr-white);
    box-shadow: var(--shadow-lg);
    z-index: 999;
    padding: 100px 32px 32px 32px;
    transition: var(--transition);
}

.mobile-drawer.open {
    right: 0;
}

.mobile-nav {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.mobile-nav-link {
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 1.25rem;
    color: var(--txt-dark);
}

.mobile-nav-footer {
    margin-top: 40px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.mobile-lang {
    font-weight: 600;
    color: var(--clr-primary);
}

/* Toggle Menu Active State */
.mobile-menu-toggle.active .bar:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}
.mobile-menu-toggle.active .bar:nth-child(2) {
    opacity: 0;
}
.mobile-menu-toggle.active .bar:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

/* --- Hero Section --- */
.hero-section {
    position: relative;
    padding-top: calc(var(--header-height) + 60px);
    padding-bottom: 120px;
    min-height: 85vh;
    display: flex;
    align-items: center;
    background-color: var(--clr-dark-bg);
    color: var(--clr-white);
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    transform: scale(1.05);
    animation: zoomOutEffect 20s ease-out forwards;
}

@keyframes zoomOutEffect {
    to { transform: scale(1); }
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--grad-overlay);
    z-index: 1;
}

.hero-container {
    position: relative;
    z-index: 2;
}

.hero-content {
    max-width: 650px;
}

.hero-tag {
    display: inline-block;
    font-family: var(--font-heading);
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 0.15em;
    color: var(--clr-accent);
    margin-bottom: 16px;
    border-left: 3px solid var(--clr-accent);
    padding-left: 12px;
}

.hero-title {
    font-size: clamp(3rem, 6vw, 4.5rem);
    font-weight: 800;
    color: var(--clr-white);
    margin-bottom: 10px;
    line-height: 1.1;
}

.hero-subtitle {
    font-size: clamp(1.4rem, 3vw, 2.2rem);
    font-weight: 300;
    color: var(--clr-accent);
    margin-bottom: 24px;
}

.hero-desc {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.75);
    margin-bottom: 40px;
    max-width: 580px;
    line-height: 1.6;
}

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

.hero-wave {
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    overflow: hidden;
    line-height: 0;
    transform: rotate(180deg);
    z-index: 2;
}

.hero-wave svg {
    position: relative;
    display: block;
    width: calc(100% + 1.3px);
    height: 60px;
}

.hero-wave .shape-fill {
    fill: var(--clr-light-bg);
}

/* --- Intro Section --- */
.intro-section {
    padding: 80px 24px;
}

.intro-grid {
    display: grid;
    grid-template-columns: 1fr 1.1fr;
    gap: 64px;
    align-items: center;
}

.intro-text h3 {
    font-size: 2.2rem;
    color: var(--clr-primary);
    margin-bottom: 20px;
}

.intro-text p {
    font-size: 1.1rem;
    color: var(--txt-muted);
}

.intro-visual {
    position: relative;
}

.visual-glow-card {
    height: 340px;
    background-size: cover;
    background-position: center;
    background: var(--clr-light-bg);
    border-radius: var(--radius-md);
    position: relative;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: flex-end;
    padding: 32px;
}

.glow-card-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    z-index: 0;
}

.glow-card-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(11, 21, 27, 0.8) 0%, rgba(11, 21, 27, 0.1) 100%);
    z-index: 1;
}

.glow-card-content {
    position: relative;
    z-index: 2;
    color: var(--clr-white);
}

.glow-card-content-shadow .glow-label,
.glow-card-content-shadow h4 {
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
}

.glow-card-overlay-light {
    background: linear-gradient(to top, rgba(11, 21, 27, 0.34) 0%, rgba(11, 21, 27, 0.22) 35%, rgba(11, 21, 27, 0) 75%);
}

.visual-glow-card-top {
    align-items: flex-start;
}

.visual-glow-card-top .glow-card-overlay-light {
    background: linear-gradient(to bottom, rgba(11, 21, 27, 0.34) 0%, rgba(11, 21, 27, 0.22) 35%, rgba(11, 21, 27, 0) 75%);
}

.glow-label {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--clr-accent);
    letter-spacing: 0.1em;
    display: block;
    margin-bottom: 4px;
}

.glow-card-content h4 {
    font-size: 1.5rem;
}

/* --- Universal Section Headers --- */
.section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 56px auto;
}

.section-tag {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--clr-primary-light);
    display: inline-block;
    margin-bottom: 12px;
}

.section-title {
    font-size: 2.5rem;
    color: var(--txt-dark);
    margin-bottom: 16px;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--txt-muted);
}

/* --- Solutions Section (Tabs) --- */
.solutions-section {
    padding: 100px 0;
    background-color: var(--clr-white);
}

.tabs-nav-container {
    display: flex;
    justify-content: center;
    margin-bottom: 48px;
}

.tabs-nav {
    display: flex;
    background: var(--clr-light-bg);
    padding: 6px;
    border-radius: 50px;
    gap: 8px;
    border: 1px solid rgba(220, 225, 230, 0.8);
}

.tab-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: none;
    background: transparent;
    padding: 12px 28px;
    border-radius: 50px;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    color: var(--txt-muted);
    transition: var(--transition);
}

.tab-btn.active {
    background: var(--clr-white);
    color: var(--clr-primary);
    box-shadow: var(--shadow-sm);
}

.tab-icon {
    width: 18px;
    height: 18px;
}

/* --- Category Visual Navigation (image-style buttons, catalog.html) --- */
.category-nav {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 56px;
}

/* When the category count leaves a single card alone in the last row
   (e.g. 7 categories = 3+3+1), stretch it to full width instead of
   leaving empty grid cells beside it */
.category-nav .tab-btn.category-card:last-child:nth-child(3n + 1) {
    grid-column: 1 / -1;
}

.tab-btn.category-card {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    padding: 9px 2px;
    border: 1px solid var(--clr-logo-green);
    border-radius: var(--radius-md);
    cursor: pointer;
    font-family: var(--font-heading);
    overflow: hidden;
    color: var(--clr-white);
    opacity: 1;
    transform: scale(1);
    transition: var(--transition);
    width: 100%;
    max-width: 290px;
    margin: 0 auto;
}

.tab-btn.category-card::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(11, 21, 27, 0);
    transition: var(--transition);
    pointer-events: none;
}

.tab-btn.category-card:hover {
    transform: scale(1.02);
}

.tab-btn.category-card.active {
    opacity: 1;
    transform: scale(1.02);
    color: var(--clr-white);
    border-color: var(--clr-logo-green);
}

.tab-btn.category-card.active::after {
    background: rgba(11, 21, 27, 0);
}

.category-card-icon,
.category-card-label {
    position: relative;
    z-index: 1;
}

.category-card-icon {
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.18);
    border-radius: 50%;
}

.category-card-icon svg {
    width: 26px;
    height: 26px;
}

/* Category card variant with a real product photo instead of an SVG icon */
.category-card-icon-photo {
    width: 272px;
    max-width: 100%;
    aspect-ratio: 136 / 176;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.94);
    border-radius: var(--radius-md);
    overflow: hidden;
    padding: 16px;
    position: relative;
    z-index: 1;
}

.category-card-icon-photo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.category-card-label {
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.2rem;
    text-align: center;
    line-height: 1.3;
    color: #000000;
}

/* --- Usage scenarios map (catalog.html, below category nav) --- */
.usage-scenarios {
    margin-bottom: 64px;
}

.usage-scenarios-heading {
    max-width: 720px;
    margin: 0 auto 32px;
    text-align: center;
}

.usage-scenarios-heading h2 {
    font-family: var(--font-heading);
    font-size: 1.9rem;
    font-weight: 700;
    margin: 12px 0;
}

.usage-scenarios-img {
    display: block;
    width: 100vw;
    max-width: 100vw;
    height: 200px;
    object-fit: contain;
    object-position: center;
    background: var(--clr-light-bg);
    margin: 0 calc(50% - 50vw);
    border-radius: 0;
    box-shadow: var(--shadow-lg);
}

@media (max-width: 700px) {
    .usage-scenarios-img {
        height: 150px;
    }
}

@media (max-width: 700px) {
    .category-nav {
        grid-template-columns: repeat(2, 1fr);
    }
    .category-nav .tab-btn.category-card:last-child:nth-child(2n + 1) {
        grid-column: 1 / -1;
    }
}

@media (max-width: 420px) {
    .category-nav {
        grid-template-columns: 1fr;
    }
}

.tab-pane {
    display: none;
    animation: fadeInTab 0.5s ease-out forwards;
}

.tab-pane.active {
    display: block;
}

@keyframes fadeInTab {
    from { opacity: 0; transform: translateY(15px); }
    to { opacity: 1; transform: translateY(0); }
}

.solutions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 32px;
}

.category-group-intro {
    background: var(--clr-light-bg);
    border: 1px solid var(--clr-logo-green);
    border-radius: var(--radius-md);
    padding: 32px 40px;
    margin-bottom: 32px;
}

.category-group-intro h2 {
    font-size: 1.5rem;
    color: var(--txt-dark);
    margin-bottom: 12px;
}

.category-group-intro p {
    color: var(--txt-muted);
    font-size: 0.98rem;
    margin-bottom: 20px;
}

.category-group-intro-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 10px 24px;
    margin-bottom: 0 !important;
}

.brand-logos-strip {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 24px;
    margin-bottom: 20px;
    padding: 16px;
    background: var(--clr-light-bg);
    border-radius: var(--radius-md);
}

.brand-logos-strip img {
    height: 28px;
    width: auto;
    max-width: 110px;
    object-fit: contain;
    opacity: 0.85;
    transition: var(--transition);
}

.brand-logos-strip img:hover {
    opacity: 1;
}

.solution-card {
    background: var(--clr-light-bg);
    padding: 28px;
    border-radius: var(--radius-md);
    border: 1px solid rgba(230, 235, 240, 0.8);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.solution-card:hover {
    background: var(--clr-white);
    transform: translateY(-8px);
    box-shadow: var(--shadow-md);
    border-color: rgba(22, 163, 115, 0.25);
}

.solution-card-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
}

.solution-icon-wrapper {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-sm);
    background: rgba(22, 163, 115, 0.1);
    color: var(--clr-primary);
    display: flex;
    align-items: center;
    justify-content: center;
}

.solution-card h3 {
    font-size: 1.4rem;
    color: var(--txt-dark);
}

.solution-card p {
    color: var(--txt-muted);
    margin-bottom: 24px;
    font-size: 0.98rem;
    flex-grow: 1;
}

.solution-features {
    margin-bottom: 28px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.solution-features li {
    font-size: 0.9rem;
    position: relative;
    padding-left: 20px;
    color: var(--txt-dark);
    font-weight: 500;
}

.solution-features li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--clr-primary-light);
    font-weight: 700;
}

.solution-link {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--clr-primary);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.solution-link:hover .arrow {
    transform: translateX(4px);
}

.solution-link .arrow {
    transition: var(--transition);
}

/* --- Catalog extras: spec note, MOQ badge, model pills, voltage filter --- */
.spec-note {
    margin-top: 32px;
    padding: 16px 20px;
    background: rgba(22, 163, 115, 0.06);
    border-left: 3px solid var(--clr-primary-light);
    border-radius: var(--radius-sm);
    color: var(--txt-muted);
    font-size: 0.9rem;
}

.moq-badge {
    display: inline-block;
    background: rgba(192, 90, 32, 0.1);
    color: hsl(28, 80%, 40%);
    padding: 8px 18px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 0.9rem;
}

.model-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.model-pill {
    background: rgba(22, 163, 115, 0.08);
    color: var(--clr-primary);
    padding: 8px 18px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 0.9rem;
}

.voltage-filter {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 32px;
}

.filter-btn {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.85rem;
    letter-spacing: 0.05em;
    padding: 8px 22px;
    border-radius: 50px;
    border: 1px solid rgba(220, 225, 230, 0.9);
    background: var(--clr-white);
    color: var(--txt-muted);
    cursor: pointer;
    transition: var(--transition);
}

.filter-btn:hover {
    border-color: var(--clr-primary-light);
    color: var(--clr-primary);
}

.filter-btn.active {
    background: var(--clr-primary);
    border-color: var(--clr-primary);
    color: var(--clr-white);
}

.voltage-tag {
    display: inline-block;
    background: rgba(22, 163, 115, 0.1);
    color: var(--clr-primary);
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.75rem;
    letter-spacing: 0.05em;
    padding: 4px 12px;
    border-radius: var(--radius-sm);
    margin-bottom: 12px;
}

/* --- Advantages Section --- */
.advantages-section {
    padding: 100px 0;
    background: var(--clr-white);
}

.advantages-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
    gap: 32px;
}

.advantage-card {
    background: var(--clr-light-bg);
    padding: 40px;
    border-radius: var(--radius-md);
    border: 1px solid rgba(230, 235, 240, 0.6);
    transition: var(--transition);
}

.advantage-card:hover {
    background: var(--clr-white);
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
    border-color: rgba(22, 163, 115, 0.2);
}

.advantage-icon {
    width: 56px;
    height: 56px;
    border-radius: var(--radius-sm);
    background: rgba(22, 163, 115, 0.08);
    color: var(--clr-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 24px;
}

.advantage-card h3 {
    font-size: 1.35rem;
    color: var(--txt-dark);
    margin-bottom: 16px;
}

.advantage-card p {
    color: var(--txt-muted);
    font-size: 0.95rem;
    line-height: 1.6;
}

.chain-flow {
    margin-top: 20px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--clr-primary);
}

.chain-flow span {
    background: rgba(22, 163, 115, 0.08);
    padding: 4px 10px;
    border-radius: 4px;
}

/* --- Manufacturing Highlight Section --- */
.manufacturing-highlight {
    position: relative;
    padding: 120px 0;
    background-color: var(--clr-dark-bg);
    color: var(--clr-white);
    overflow: hidden;
}

.highlight-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0.65;
}

.highlight-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, rgba(11, 21, 27, 0.9) 0%, rgba(11, 21, 27, 0.5) 100%);
}

.highlight-container {
    position: relative;
    z-index: 2;
}

.highlight-content {
    max-width: 600px;
}

.highlight-tag {
    display: inline-block;
    color: var(--clr-accent);
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 0.1em;
    margin-bottom: 16px;
}

.highlight-content h2 {
    font-size: 2.5rem;
    margin-bottom: 24px;
}

.highlight-content p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 1.05rem;
    margin-bottom: 40px;
    line-height: 1.7;
}

.fact-row {
    display: flex;
    gap: 48px;
}

.fact-item strong {
    display: block;
    font-family: var(--font-heading);
    font-size: 2.2rem;
    color: var(--clr-accent);
    line-height: 1.1;
}

.fact-item span {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
}

/* --- CTA Section --- */
.cta-section {
    padding: 100px 0;
    background: linear-gradient(135deg, hsl(164, 85%, 15%) 0%, hsl(192, 90%, 15%) 100%);
    color: var(--clr-white);
}

.cta-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 64px;
}

.cta-text h2 {
    font-size: 2.5rem;
    margin-bottom: 16px;
}

.cta-text p {
    color: rgba(255, 255, 255, 0.75);
    max-width: 650px;
    font-size: 1.05rem;
}

.cta-actions {
    display: flex;
    flex-direction: column;
    gap: 16px;
    align-items: flex-start;
}

.cta-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
}

.cta-link:hover {
    color: var(--clr-accent);
}

.mail-icon {
    width: 20px;
    height: 20px;
}

/* --- Footer --- */
.site-footer {
    background-color: var(--clr-dark-bg);
    color: rgba(255, 255, 255, 0.5);
    padding: 80px 0 40px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr repeat(3, 1fr);
    gap: 48px;
    margin-bottom: 64px;
}

.footer-brand .footer-logo {
    display: inline-block;
    margin-bottom: 16px;
}

.footer-brand .logo-accent {
    color: var(--clr-white);
}

.footer-desc {
    font-size: 0.9rem;
    line-height: 1.6;
}

.footer-links-col h4 {
    color: var(--clr-white);
    font-size: 1rem;
    margin-bottom: 24px;
    font-weight: 600;
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-links a {
    font-size: 0.9rem;
}

.footer-links a:hover {
    color: var(--clr-accent);
    transform: translateX(4px);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 32px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    font-size: 0.85rem;
}

.footer-legal {
    display: flex;
    gap: 24px;
}

.footer-legal a:hover {
    color: var(--clr-white);
}

/* --- Contact Modal --- */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(11, 21, 27, 0.7);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: var(--transition);
}

.modal-overlay.open {
    opacity: 1;
    pointer-events: auto;
}

.modal-card {
    background: var(--clr-white);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 650px;
    padding: 48px;
    position: relative;
    box-shadow: var(--shadow-lg);
    transform: translateY(20px);
    transition: var(--transition);
}

.modal-overlay.open .modal-card {
    transform: translateY(0);
}

.modal-close {
    position: absolute;
    top: 24px;
    right: 24px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--clr-light-bg);
    border: none;
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.modal-close:hover {
    background: #e2e8f0;
    color: var(--txt-dark);
}

.modal-header {
    margin-bottom: 32px;
}

.modal-header h3 {
    font-size: 1.8rem;
    color: var(--txt-dark);
    margin-bottom: 8px;
}

.modal-header p {
    color: var(--txt-muted);
    font-size: 0.95rem;
}

.modal-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-error {
    color: #c0392b;
    font-size: 0.85rem;
    margin: -8px 0 0;
}

.form-error a {
    color: #c0392b;
    text-decoration: underline;
}

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

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--txt-dark);
}

.form-group input, 
.form-group select, 
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(220, 225, 230, 0.9);
    font-family: var(--font-body);
    font-size: 0.95rem;
    background: var(--clr-light-bg);
    outline: none;
    transition: var(--transition);
}

.form-group input:focus, 
.form-group select:focus, 
.form-group textarea:focus {
    border-color: var(--clr-primary-light);
    background: var(--clr-white);
    box-shadow: 0 0 0 3px rgba(22, 163, 115, 0.15);
}

/* Success Message inside modal */
.modal-success-message {
    display: none;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 24px 0;
}

.modal-success-message.visible {
    display: flex;
}

.success-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: rgba(22, 163, 115, 0.15);
    color: var(--clr-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 24px;
}

.modal-success-message h3 {
    font-size: 1.8rem;
    color: var(--txt-dark);
    margin-bottom: 12px;
}

.modal-success-message p {
    color: var(--txt-muted);
    max-width: 400px;
    margin-bottom: 32px;
}

/* --- Page Header (Catalog / Dealers / Contacts inner pages) --- */
.page-header {
    padding: calc(var(--header-height) + 32px) 0 32px 0;
    background: var(--grad-dark);
    color: var(--clr-white);
    text-align: center;
}

.page-header-scene {
    position: relative;
    overflow: hidden;
}

.page-header-scene .container {
    position: relative;
    z-index: 2;
}

.page-header-scene-media {
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
}

.page-header-scene-wrap {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 340px;
    height: 220px;
    max-width: 26vw;
    overflow: hidden;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
}

.page-header-scene-wrap-left {
    left: 32px;
}

.page-header-scene-wrap-right {
    right: 32px;
}

.page-header-scene-half {
    position: absolute;
    top: 0;
    width: 200%;
    height: 100%;
    object-fit: cover;
    opacity: 1;
}

/* Left wrap: video's own left edge pinned to wrap's left edge -> shows source's left half */
.page-header-scene-left {
    left: 0;
}

/* Right wrap: video's own right edge pinned to wrap's right edge -> shows source's right half */
.page-header-scene-right {
    right: 0;
}

@media (max-width: 900px) {
    .page-header-scene-wrap {
        display: none;
    }
}

.page-header .section-tag {
    color: var(--clr-accent);
}

.page-title {
    font-size: clamp(2.2rem, 4.5vw, 3.2rem);
    color: var(--clr-white);
    margin: 12px 0 16px 0;
}

.page-subtitle {
    color: rgba(255, 255, 255, 0.75);
    font-size: 1.05rem;
    max-width: 640px;
    margin: 0 auto;
}

.solutions-section-top {
    padding-top: 28px;
}

/* --- Catalog Teaser Grid (Home page) --- */
.catalog-teaser-section {
    padding: 100px 0;
    background-color: var(--clr-white);
}

.teaser-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 24px;
    margin-bottom: 48px;
}

.teaser-card {
    display: block;
    background: var(--clr-light-bg);
    border: 1px solid rgba(230, 235, 240, 0.8);
    border-radius: var(--radius-md);
    padding: 28px 24px;
    transition: var(--transition);
}

.teaser-card:hover {
    background: var(--clr-white);
    transform: translateY(-6px);
    box-shadow: var(--shadow-md);
    border-color: rgba(22, 163, 115, 0.25);
}

.teaser-card h3 {
    font-size: 1.15rem;
    color: var(--txt-dark);
    margin-bottom: 8px;
}

.teaser-card p {
    font-size: 0.9rem;
    color: var(--txt-muted);
}

/* --- MOQ Table (Dealers page) --- */
.moq-table {
    max-width: 800px;
    margin: 0 auto 24px auto;
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid rgba(230, 235, 240, 0.8);
}

.moq-row {
    display: grid;
    grid-template-columns: 1fr 1.4fr;
    gap: 16px;
    padding: 18px 24px;
    border-bottom: 1px solid rgba(230, 235, 240, 0.8);
    background: var(--clr-white);
    font-size: 0.95rem;
}

.moq-row:last-child {
    border-bottom: none;
}

.moq-row-head {
    background: var(--clr-light-bg);
    font-family: var(--font-heading);
    font-weight: 700;
    color: var(--clr-primary);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

/* --- Admin: toolbar --- */
.admin-toolbar {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    background: var(--clr-light-bg);
    border: 1px solid rgba(230, 235, 240, 0.8);
    border-radius: var(--radius-md);
    padding: 24px;
    margin-bottom: 40px;
    font-size: 0.9rem;
    color: var(--txt-muted);
}

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

/* --- Admin: form extras --- */
.price-type-row {
    display: flex;
    gap: 24px;
    padding: 8px 0;
}

.radio-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
    font-size: 0.95rem;
    color: var(--txt-dark);
    cursor: pointer;
}

.admin-form-actions {
    display: flex;
    gap: 12px;
    margin-top: 8px;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 0.82rem;
}

/* --- Admin: product list --- */
.admin-product-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 16px;
}

.admin-product-row {
    display: flex;
    align-items: center;
    gap: 16px;
    background: var(--clr-white);
    border: 1px solid rgba(230, 235, 240, 0.8);
    border-radius: var(--radius-md);
    padding: 14px 20px;
}

.admin-product-thumb {
    width: 56px;
    height: 56px;
    border-radius: var(--radius-sm);
    background: var(--clr-light-bg);
    flex-shrink: 0;
    overflow: hidden;
}

.admin-product-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.admin-product-info {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.admin-product-meta {
    font-size: 0.82rem;
    color: var(--txt-muted);
}

.admin-product-actions {
    display: flex;
    gap: 8px;
    flex-shrink: 0;
}

/* --- Catalog: dynamic product card image + price badges --- */
.solution-card-photo {
    width: 100%;
    height: 160px;
    object-fit: cover;
    border-radius: var(--radius-sm);
    margin-bottom: 20px;
    background: var(--clr-light-bg);
}

/* Product cutout photos (transparent/white background studio shots) —
   use "contain" + padding so the whole unit is visible, not cropped */
.solution-card-photo-contain {
    width: 100%;
    height: 170px;
    object-fit: contain;
    object-position: center;
    border-radius: var(--radius-sm);
    margin-bottom: 16px;
    background: var(--clr-light-bg);
    padding: 12px;
    border: 1px solid rgba(230, 235, 240, 0.8);
}

.price-badge {
    display: inline-block;
    background: rgba(22, 163, 115, 0.1);
    color: var(--clr-primary);
    padding: 6px 14px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 0.9rem;
    margin-bottom: 16px;
}

.price-badge.request {
    background: rgba(192, 90, 32, 0.1);
    color: hsl(28, 80%, 40%);
}

/* --- Comparison Table (About page: Europe vs China) --- */
.compare-table {
    max-width: 900px;
    margin: 0 auto 24px auto;
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid rgba(230, 235, 240, 0.8);
}

.compare-row {
    display: grid;
    grid-template-columns: 1fr 1.2fr 1.2fr;
    gap: 16px;
    padding: 18px 24px;
    border-bottom: 1px solid rgba(230, 235, 240, 0.8);
    background: var(--clr-white);
    font-size: 0.92rem;
    align-items: center;
}

.compare-row:last-child {
    border-bottom: none;
}

.compare-row-head {
    background: var(--clr-dark-bg);
    color: var(--clr-white);
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.compare-feature {
    font-weight: 700;
    color: var(--txt-dark);
}

.compare-highlight {
    color: var(--clr-primary);
    font-weight: 700;
}

/* --- Steps Grid (Dealers page) --- */
.steps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 32px;
}

.step-card {
    text-align: center;
    padding: 8px;
}

.step-number {
    width: 48px;
    height: 48px;
    margin: 0 auto 16px auto;
    border-radius: 50%;
    background: var(--grad-primary);
    color: var(--clr-white);
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.step-card h3 {
    font-size: 1.1rem;
    color: var(--txt-dark);
    margin-bottom: 8px;
}

.step-card p {
    font-size: 0.9rem;
    color: var(--txt-muted);
}

/* --- Contacts Page --- */
.contacts-grid {
    display: grid;
    grid-template-columns: 1fr 1.3fr;
    gap: 64px;
    align-items: start;
}

.contacts-info h3 {
    font-size: 1.4rem;
    color: var(--txt-dark);
    margin-bottom: 24px;
}

.info-row {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 16px 0;
    border-bottom: 1px solid rgba(230, 235, 240, 0.8);
}

.info-label {
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--clr-primary-light);
}

.info-value {
    font-size: 1rem;
    color: var(--txt-dark);
}

.info-value a {
    color: var(--clr-primary);
    font-weight: 600;
}

.contacts-form-wrap {
    background: var(--clr-light-bg);
    border: 1px solid rgba(230, 235, 240, 0.8);
    border-radius: var(--radius-lg);
    padding: 40px;
}

/* --- Responsive Media Queries --- */

/* Header nav collapses to the hamburger drawer starting at tablet widths.
   768px was too low: tablets (iPad Air/Pro portrait, 820-834px) still hit
   the full desktop row (logo + 5 nav links + lang switch + price button),
   which needs ~1090px and doesn't fit — the flex row squeezes the logo
   image down (global `img { max-width:100% }` + fixed 44px height) until
   only the icon mark is legible and the wordmark is crushed away. Raising
   this to 1024px covers all tablets in portrait, including 12.9" iPad Pro. */
@media (max-width: 1024px) {
    .main-nav,
    .header-actions .btn,
    .header-actions .lang-switch {
        display: none;
    }

    .mobile-menu-toggle {
        display: flex;
    }
}

@media (max-width: 992px) {
    .cta-container {
        flex-direction: column;
        align-items: flex-start;
        gap: 32px;
    }

    .intro-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }

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

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

@media (max-width: 768px) {

    .hero-section {
        padding-top: calc(var(--header-height) + 20px);
        padding-bottom: 80px;
        min-height: auto;
    }
    
    .hero-actions {
        flex-direction: column;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .modal-card {
        padding: 32px 24px;
    }

    .compare-row {
        grid-template-columns: 1fr;
        gap: 4px;
    }

    .compare-row-head {
        display: none;
    }

    .compare-feature {
        margin-bottom: 4px;
    }

    .moq-row {
        grid-template-columns: 1fr;
        gap: 4px;
    }
}

@media (max-width: 480px) {
    .footer-grid {
        grid-template-columns: 1fr;
    }
}
