/* --- Global Styles & Variables --- */
:root {
    --primary-green: #2E7D32;
    --dark-green: #256528;
    --light-green: #EAF3EA;
    --primary-grey: #222222;
    --secondary-grey: #555;
    --background-grey: #F5F7FA;
    --light-grey: #e0e0e0;
    --white: #FFFFFF;
    --font-heading: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    --transition-speed: 0.4s;
    --border-radius: 8px;
    --shadow-sm: 0 4px 15px rgba(0,0,0,0.06);
    --shadow-md: 0 10px 30px rgba(0,0,0,0.1);
}

html { scroll-behavior: smooth; scroll-padding-top: 80px; }

body {
    font-family: var(--font-body);
    color: var(--primary-grey);
    line-height: 1.7;
    margin: 0;
    background: var(--white);
    -webkit-font-smoothing: antialiased;
    font-size: 16px;
}

:focus-visible { outline: 2px solid var(--primary-green); outline-offset: 2px; }

.container { max-width: 1140px; margin: 0 auto; padding: 0 20px; }

h1, h2, h3, h4 { font-family: var(--font-heading); font-weight: 700; margin: 0 0 15px 0; }
h1 { font-size: clamp(2.5rem, 5vw, 3.8rem); line-height: 1.2; }
h2 { font-size: clamp(2rem, 4vw, 2.8rem); text-align: center; margin-bottom: 20px; }
h3 { font-size: 1.4rem; }
p.section-subtitle { text-align: center; max-width: 600px; margin: 0 auto 60px; font-size: 1.1rem; color: var(--secondary-grey); }
.eyebrow-heading { display: block; font-weight: 700; color: var(--primary-green); margin-bottom: 10px; text-transform: uppercase; letter-spacing: 1px; font-size: 0.9rem; }
.link-arrow { text-decoration: none; color: var(--primary-green); font-weight: 700; display: inline-block; transition: transform var(--transition-speed) ease; }
.link-arrow::after { content: ' →'; transition: margin-left 0.3s ease; }
.link-arrow:hover::after { margin-left: 5px; }

/* --- Buttons & General UI --- */
.btn { padding: 12px 28px; text-decoration: none; border-radius: var(--border-radius); font-weight: 700; transition: all 0.3s ease; display: inline-block; border: 2px solid transparent; cursor: pointer; text-align: center; }
.btn-primary { background: var(--primary-green); color: var(--white); }
.btn-primary:hover { background: var(--dark-green); transform: translateY(-3px); box-shadow: 0 4px 15px rgba(46, 125, 50, 0.3); }
.btn-secondary { border-color: var(--white); color: var(--white); background: transparent; }
.btn-secondary:hover { background: var(--white); color: var(--primary-grey); }
.btn-full { width: 100%; box-sizing: border-box; }

/* --- Header --- */
.header { background: transparent; position: fixed; top: 0; left: 0; width: 100%; z-index: 1000; height: 90px; transition: background-color var(--transition-speed) ease, box-shadow var(--transition-speed) ease, height var(--transition-speed) ease; }
.header.scrolled { background: rgba(255, 255, 255, 0.9); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); box-shadow: var(--shadow-sm); height: 70px; }
body.subpage-body .header { background: rgba(255, 255, 255, 0.9); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); box-shadow: var(--shadow-sm); height: 70px; }
.header .container { display: flex; justify-content: space-between; align-items: center; height: 100%; }
.logo { height: 32px; transition: height var(--transition-speed) ease; }
.header.scrolled .logo, body.subpage-body .header .logo { height: 25px; }
.logo img { height: 100%; width: auto; }
.logo-color { display: none; }
.header.scrolled .logo-white, body.subpage-body .header .logo-white { display: none; }
.header.scrolled .logo-color, body.subpage-body .header .logo-color { display: block; }
.main-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 15px; }
.main-nav a { text-decoration: none; color: var(--white); padding: 10px 15px; font-weight: 500; position: relative; transition: color var(--transition-speed) ease; white-space: nowrap; }
.header.scrolled .main-nav a, body.subpage-body .header .main-nav a { color: var(--primary-grey); }
.main-nav a::after { content: ''; position: absolute; bottom: 0; left: 50%; transform: translateX(-50%) scaleX(0); transform-origin: center; width: 80%; height: 2px; background: var(--primary-green); transition: transform var(--transition-speed) ease; }
.main-nav a:hover::after { transform: translateX(-50%) scaleX(1); }
.header-btn { display: block; }
.mobile-nav-toggle { display: none; background: transparent; border: none; cursor: pointer; z-index: 1001; padding: 10px; }
.hamburger-line { display: block; width: 25px; height: 2px; margin: 5px 0; transition: all var(--transition-speed) ease; background: var(--white); }
.header.scrolled .hamburger-line, body.subpage-body .header .hamburger-line { background: var(--primary-grey); }
.mobile-nav-toggle.active .hamburger-line:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.mobile-nav-toggle.active .hamburger-line:nth-child(2) { opacity: 0; }
.mobile-nav-toggle.active .hamburger-line:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* --- Generic Sections & Page Hero --- */
.page-hero { padding: 120px 0 60px; }
.page-hero h1, .page-hero .subtitle { text-align: center; max-width: 800px; margin-left: auto; margin-right: auto; }
.content-section { padding: 120px 0; }
.content-section-dark { padding: 80px 0; background: var(--primary-green); color: var(--white); }
.content-section-dark h2, .content-section-dark p { color: var(--white); text-align: center; }
.content-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 5rem; align-items: start; }
.feature-box { background: var(--background-grey); padding: 30px; border-radius: var(--border-radius); }
.feature-box ul { list-style: none; padding-left: 0; }
.feature-box li { padding-left: 25px; position: relative; margin-bottom: 10px; }
.feature-box li::before { content: '✓'; color: var(--primary-green); position: absolute; left: 0; font-weight: 700; }
.icon-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; margin-top: 60px; text-align: center; }
.icon-grid img { height: 50px; margin-bottom: 20px; }

/* --- Hero Section --- */
.hero-section-v2 { height: 100vh; display: flex; align-items: center; color: var(--white); text-align: center; position: relative; }
.hero-video-bg { position: absolute; top: 0; left: 0; width: 100%; height: 100%; overflow: hidden; z-index: -2; }
.hero-video-bg img { width: 100%; height: 100%; object-fit: cover; }
.hero-section-v2::after { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: linear-gradient(to top, rgba(0,0,0,0.7), rgba(0,0,0,0.1)); z-index: -1; }
.hero-content { position: relative; }
.hero-content .subtitle { font-size: 1.2rem; max-width: 700px; margin: 20px auto 40px; line-height: 1.8; }
.cta-buttons { display: flex; justify-content: center; gap: 20px; flex-wrap: wrap; }

/* --- Solutions Section & Target Groups --- */
.solutions-section { padding: 80px 0; background: var(--background-grey); }
.solutions-container { display: flex; gap: 30px; width: 100%; }
.solution-box { background: var(--white); padding: 40px; border-radius: var(--border-radius); flex: 1; text-align: center; box-shadow: var(--shadow-sm); transition: all var(--transition-speed) ease; display: flex; flex-direction: column; }
.solution-box:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); }
.solution-box img { height: 50px; margin-bottom: 20px; }
.solution-box .link-arrow { margin-top: auto; }

/* --- Trial Section --- */
.trial-offer-section { background: var(--primary-green); color: var(--white); padding: 60px 0; text-align: center; }
.trial-offer-section h2 { color: var(--white); }
.trial-offer-section p { max-width: 600px; margin-left: auto; margin-right: auto; margin-bottom: 30px; }
.trial-offer-section .btn-primary { background: var(--white); color: var(--primary-green); }

/* --- How it Works & Value Proposition --- */
.how-it-works-section { padding: 120px 0; }
.process-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; margin-top: 60px; }
.step { text-align: center; position: relative; }
.step-icon-wrapper { display: inline-flex; justify-content: center; align-items: center; width: 80px; height: 80px; background: var(--light-green); border-radius: 50%; margin-bottom: 20px; }
.step-number { font-size: 2rem; font-weight: 700; color: var(--primary-green); }
.step:not(:last-child)::after { content: ''; position: absolute; top: 40px; right: calc(-50% + 20px); width: calc(100% - 40px); height: 2px; background: var(--light-grey); }

/* --- Packages Section --- */
.packages-section { padding: 120px 0; background: var(--background-grey); }
.sizes-container { display: grid; grid-template-columns: 1fr 1fr; gap: 30px; max-width: 800px; margin: 60px auto 0; align-items: stretch; }
.size-item { display: flex; flex-direction: column; text-align: left; padding: 40px; background: var(--white); border-radius: var(--border-radius); box-shadow: var(--shadow-sm); transition: all var(--transition-speed) ease; position: relative; }
.size-item.active { border: 2px solid var(--primary-green); transform: translateY(-10px); box-shadow: var(--shadow-md); }
.size-item h3 { color: var(--primary-grey); }
.size-item .text-green { color: var(--primary-green); }
.bestseller-badge { position: absolute; top: -15px; left: 50%; transform: translateX(-50%); background-color: var(--primary-green); color: var(--white); padding: 5px 15px; border-radius: 20px; font-size: 0.8rem; font-weight: 700; }
.size-item .btn { margin-top: auto; width: 100%; }
.size-item .btn-secondary { color: var(--primary-green); border-color: var(--primary-green); }
.package-features { list-style: none; padding: 0; margin: 20px 0; flex-grow: 1; }
.package-features li { padding-left: 25px; position: relative; margin-bottom: 10px; }
.package-features li::before { content: '✓'; color: var(--primary-green); position: absolute; left: 0; font-weight: 700; }
.points-table { width: 100%; border-collapse: collapse; }
.points-table td { padding: 10px 0; border-bottom: 1px solid var(--light-grey); }
.points-table tr:last-child td { border-bottom: none; }
.points-table td:last-child { text-align: right; }

/* --- Calculator Section --- */
.calculator-section { padding: 120px 0; }
.calculator { max-width: 800px; margin: 0 auto; background: var(--white); padding: 50px; border-radius: var(--border-radius); box-shadow: var(--shadow-md); display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
.calc-step { margin-bottom: 20px; }
.calc-step label { display: block; margin-bottom: 8px; font-weight: 700; font-size: 0.9rem; }
.calc-step input, .calc-step select { width: 100%; padding: 12px; border: 1px solid var(--light-grey); border-radius: var(--border-radius); font-size: 1rem; box-sizing: border-box; }
.calc-result { grid-column: 1 / -1; text-align: center; margin-top: 20px; padding-top: 30px; border-top: 1px solid var(--light-grey); }
.price-display { font-size: 3.5rem; color: var(--primary-green); font-weight: 700; }
.price-loader { width: 40px; height: 40px; border: 4px solid var(--light-grey); border-top-color: var(--primary-green); border-radius: 50%; animation: spin 1s linear infinite; margin: 10px auto; display: none; }
@keyframes spin { to { transform: rotate(360deg); } }

/* --- About & Local Advantage --- */
.service-section-v2, .about-section { padding: 120px 0; }
.service-section-v2 .container, .about-section .container { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 5rem; }
.service-image-v2 img, .about-image img { width: 100%; border-radius: var(--border-radius); box-shadow: var(--shadow-md); }
.service-text-v2 h2, .about-text h2 { text-align: left; }
.service-text-v2 ul { list-style: none; padding-left: 0; }
.service-text-v2 li { padding-left: 25px; position: relative; margin-bottom: 10px; }
.service-text-v2 li::before { content: '✓'; color: var(--primary-green); position: absolute; left: 0; font-weight: 700; }

/* --- FAQ Section --- */
.faq-section { padding: 120px 0; }
.faq-accordion { max-width: 800px; margin: 40px auto 0; border-top: 1px solid var(--light-grey); }
.faq-item { border-bottom: 1px solid var(--light-grey); }
.faq-question { width: 100%; background: none; border: none; text-align: left; padding: 25px 0; font-size: 1.3rem; font-weight: 500; cursor: pointer; display: flex; justify-content: space-between; align-items: center; }
.faq-question::after { content: '+'; font-size: 2rem; color: var(--primary-green); transition: transform 0.3s ease; }
.faq-question.active::after { transform: rotate(45deg); }
.faq-answer { max-height: 0; overflow: hidden; transition: max-height 0.5s ease; }
.faq-answer p { padding: 0 0 25px 0; margin: 0; }

/* --- Contact & Footer --- */
.contact-section { position: relative; padding: 120px 0; color: var(--white); background: url('../img/contact-bg.jpg') no-repeat center center/cover; background-attachment: fixed; }
.contact-bg-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: linear-gradient(135deg, rgba(46, 125, 50, 0.9), rgba(34, 34, 34, 0.95)); z-index: 1; }
.contact-container { position: relative; z-index: 2; display: grid; grid-template-columns: 1fr 1.2fr; gap: 5rem; align-items: center; }
.contact-text h2, .contact-text .eyebrow-heading { text-align: left; color: var(--white); }
.contact-details { margin-top: 30px; }
.contact-details a { color: var(--white); text-decoration: none; }
.contact-form-wrapper { background: rgba(255, 255, 255, 0.05); padding: 40px; border-radius: var(--border-radius); border: 1px solid rgba(255, 255, 255, 0.2); backdrop-filter: blur(10px); }
.form-group input, .form-group textarea { width: 100%; background: rgba(0, 0, 0, 0.2); border: 1px solid rgba(255, 255, 255, 0.3); padding: 15px; border-radius: var(--border-radius); color: var(--white); font-size: 1rem; box-sizing: border-box; margin-bottom: 20px; }
.form-group input::placeholder, .form-group textarea::placeholder { color: rgba(255, 255, 255, 0.7); }
#form-status p { padding: 15px; margin-top: 20px; border-radius: var(--border-radius); text-align: center; color: var(--white); font-weight: 700; }
#form-status .success { background-color: var(--primary-green); }
#form-status .error { background-color: #e74c3c; }
#form-status .info { background-color: #3498db; }

.footer { background: var(--primary-grey); color: #a9a9a9; padding: 80px 0 0; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1.5fr; gap: 40px; }
.footer-col a { color: #a9a9a9; text-decoration: none; transition: color 0.3s ease; }
.footer-col a:hover { color: var(--white); }
.footer-col ul { list-style: none; padding: 0; line-height: 2; }
.footer-logo { max-width: 150px; margin-bottom: 20px; }
.social-icons { display: flex; gap: 15px; margin-top: 20px; }
.social-icons img { height: 24px; opacity: 0.7; transition: opacity 0.3s ease; }
.social-icons a:hover img { opacity: 1; }
.footer-bottom { border-top: 1px solid #444; text-align: center; padding: 25px 0; margin-top: 40px; }

/* --- WhatsApp FAB --- */
.whatsapp-fab { position: fixed; bottom: 20px; right: 20px; width: 60px; height: 60px; background: #25D366; border-radius: 50%; display: flex; justify-content: center; align-items: center; box-shadow: var(--shadow-md); z-index: 999; transition: transform 0.3s ease; }
.whatsapp-fab:hover { transform: scale(1.1); }
.whatsapp-fab img { width: 35px; }

/* --- Blog & Article Specific Styles --- */
.blog-section { padding: 120px 0; }
.blog-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 40px; }
.blog-card { background: var(--white); border-radius: var(--border-radius); box-shadow: var(--shadow-sm); overflow: hidden; transition: all 0.3s ease; display: flex; flex-direction: column; }
.blog-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); }
.blog-card-link { text-decoration: none; color: inherit; display: flex; flex-direction: column; height: 100%; }
.blog-card-image { width: 100%; height: 220px; object-fit: cover; }
.blog-card-content { padding: 25px; display: flex; flex-direction: column; flex-grow: 1; }
.blog-card-category { display: inline-block; background-color: var(--light-green); color: var(--primary-green); padding: 5px 10px; border-radius: 5px; font-size: 0.8rem; font-weight: 700; margin-bottom: 15px; align-self: flex-start; }
.blog-card-title { font-size: 1.3rem; margin-bottom: 10px; }
.blog-card-excerpt { color: var(--secondary-grey); flex-grow: 1; margin-bottom: 20px; }
.blog-card-meta { display: flex; justify-content: space-between; align-items: center; font-size: 0.9rem; color: var(--secondary-grey); border-top: 1px solid var(--light-grey); padding-top: 15px; }
.article-hero { position: relative; text-align: center; color: var(--white); padding: 140px 0 80px; background-size: cover; background-position: center; }
.article-hero-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.5); }
.article-hero .container { position: relative; }
.article-hero h1 { color: var(--white); max-width: 800px; margin-left: auto; margin-right: auto; }
.article-meta { opacity: 0.8; margin-top: 10px; }
.article-body { padding: 120px 0; }
.article-container { max-width: 800px; }
.article-container p.lead { font-size: 1.2rem; font-weight: 500; margin-bottom: 2rem; }
.article-container ul, .article-container ol { margin: 2rem 0; padding-left: 20px; }
.article-container li { margin-bottom: 1rem; }
.article-cta { margin-top: 80px; background: var(--background-grey); padding: 40px; border-radius: var(--border-radius); text-align: center; }


/* --- Partner Page Styles --- */
.partner-grid {
    display: grid;
    grid-template-columns: 1fr 1fr; /* Две колонки на десктопе */
    gap: 30px;
    margin-top: 60px;
    text-align: left;
}

.partner-card {
    background: var(--background-grey);
    padding: 30px;
    border-radius: var(--border-radius);
}

.partner-card-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
    font-size: 1.2rem;
}

.partner-icon {
    height: 40px;
    width: 40px;
}


/* --- Responsive Media Queries --- */
@media (max-width: 992px) {
    .service-section-v2 .container, 
    .about-section .container, 
    .contact-container, 
    .testimonial-grid, 
    .content-grid, 
    .process-steps,
    .calculator { 
        grid-template-columns: 1fr; 
    }
    .process-steps .step:not(:last-child)::after { display: none; }
    .about-image { order: -1; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
    body { padding-top: 70px; }
    .header { height: 70px; }
    .main-nav { display: none; position: absolute; top: 70px; left: 0; width: 100%; background: var(--white); flex-direction: column; padding: 20px 0; box-shadow: var(--shadow-sm); }
    .main-nav.active { display: flex; }
    .main-nav ul { flex-direction: column; width: 100%; }
    .main-nav a, .header.scrolled .main-nav a, body.subpage-body .header .main-nav a { color: var(--primary-grey); width: 100%; text-align: center; padding: 15px; }
    .main-nav a:hover::after { width: 50px; }
    .mobile-nav-toggle { display: block; }
    .header-btn { display: none; }
    h1 { font-size: 2.2rem; } 
    h2 { font-size: 1.8rem; }
    .solutions-container { flex-direction: column; }
    .sizes-container { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; }
    .icon-grid { grid-template-columns: 1fr; }
    /* НОВОЕ ПРАВИЛО ДЛЯ ПАРТНЕРСКОЙ СТРАНИЦЫ */
    .partner-grid {
        grid-template-columns: 1fr; /* Одна колонка на мобильных */
    }
}