/* Core Design System Variables */
:root {
    --primary: #1e3f20;       /* Deep Forest Green */
    --primary-light: #2d5d30;
    --primary-dark: #122613;
    --accent: #d4a373;        /* Warm Gold/Beige */
    --accent-hover: #c59363;
    --bg-light: #fefae0;      /* Warm Ivory */
    --bg-dark: #1b261b;       /* Dark Greenish-black for dark blocks */
    --text-dark: #283618;     /* Organic dark text */
    --text-light: #fefae0;
    --text-muted: #606c38;
    --white: #ffffff;
    --gray-light: #e9ecef;
    --border-color: rgba(96, 108, 56, 0.15);
    --shadow: 0 10px 30px rgba(40, 54, 24, 0.08);
    --shadow-hover: 0 15px 35px rgba(40, 54, 24, 0.15);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --font-heading: 'Outfit', 'Inter', sans-serif;
    --font-body: 'Inter', sans-serif;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: #faf9f6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

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

/* Typography */
h1, h2, h3, h4 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
    color: var(--primary-dark);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-heading);
    font-weight: 600;
    text-decoration: none;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition);
    white-space: nowrap;
}

.btn-sm {
    padding: 10px 18px;
    font-size: 14px;
}

.btn-md {
    padding: 14px 24px;
    font-size: 16px;
}

.btn-lg {
    padding: 18px 36px;
    font-size: 18px;
}

.btn-primary {
    background-color: var(--primary);
    color: var(--white);
    box-shadow: 0 4px 15px rgba(30, 63, 32, 0.2);
}

.btn-primary:hover {
    background-color: var(--primary-light);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(30, 63, 32, 0.3);
}

.btn-outline {
    background-color: transparent;
    border: 2px solid var(--primary);
    color: var(--primary);
}

.btn-outline:hover {
    background-color: var(--primary);
    color: var(--white);
}

.btn-block {
    display: flex;
    width: 100%;
}

/* Header */
.header {
    background-color: rgba(250, 249, 246, 0.85);
    backdrop-filter: blur(12px);
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 100;
    border-bottom: 1px solid var(--border-color);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.02);
}

.header-container {
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    font-family: var(--font-heading);
    font-size: 22px;
    font-weight: 800;
    letter-spacing: -0.5px;
    color: var(--primary-dark);
    white-space: nowrap;
}

.logo-accent {
    color: var(--accent);
}

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

.nav-link {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 500;
    transition: var(--transition);
    white-space: nowrap;
}

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

.contacts {
    display: flex;
    align-items: center;
    gap: 20px;
}

.phone-link {
    text-decoration: none;
    color: var(--primary-dark);
    font-weight: 700;
    font-size: 18px;
    white-space: nowrap;
}

/* Hero Section */
.hero {
    padding-top: 160px;
    padding-bottom: 80px;
    background: radial-gradient(circle at 80% 20%, rgba(212, 163, 115, 0.08) 0%, transparent 50%);
}

.hero-container {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 48px;
    align-items: center;
}

.badge {
    display: inline-block;
    background-color: rgba(214, 163, 115, 0.12);
    border: 1px solid rgba(214, 163, 115, 0.3);
    color: #b5835a;
    padding: 6px 14px;
    border-radius: 50px;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 24px;
}

.hero-title {
    font-size: 48px;
    line-height: 1.15;
    margin-bottom: 24px;
}

.hero-desc {
    font-size: 18px;
    color: #4a5738;
    margin-bottom: 36px;
    max-width: 540px;
}

.hero-actions {
    margin-bottom: 40px;
}

.hero-features {
    display: flex;
    gap: 24px;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.feature-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    background-color: rgba(30, 63, 32, 0.1);
    color: var(--primary);
    border-radius: 50%;
    font-size: 12px;
    font-weight: bold;
}

.feature-text {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-dark);
}

.hero-image-wrapper {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
}

.hero-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: var(--transition);
}

.hero-image-wrapper:hover .hero-img {
    transform: scale(1.03);
}

/* Services Section */
.services {
    padding: 100px 0;
    background-color: var(--white);
    border-top: 1px solid var(--border-color);
}

.section-header {
    text-align: center;
    max-width: 600px;
    margin: 0 auto 60px;
}

.section-title {
    font-size: 36px;
    margin-bottom: 16px;
}

.section-subtitle {
    font-size: 16px;
    color: var(--text-muted);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.service-card {
    background-color: var(--bg-light);
    border: 1px solid var(--border-color);
    padding: 24px 20px;
    border-radius: 16px;
    transition: var(--transition);
    overflow: hidden;
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-hover);
    background-color: var(--white);
}

.service-img {
    width: 100%;
    height: 160px;
    object-fit: cover;
    border-radius: 12px;
    margin-bottom: 20px;
    display: block;
    transition: var(--transition);
}

.service-card:hover .service-img {
    transform: scale(1.03);
}

.service-card h3 {
    font-size: 20px;
    margin-bottom: 12px;
}

.service-card p {
    font-size: 14px;
    color: #4a5738;
}

/* Advantages Section */
.advantages {
    padding: 100px 0;
    background-color: #faf9f6;
    border-top: 1px solid var(--border-color);
}

.advantages-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.adv-card {
    background-color: var(--white);
    padding: 40px 30px;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    position: relative;
    transition: var(--transition);
}

.adv-card:hover {
    box-shadow: var(--shadow);
    transform: translateY(-4px);
}

.adv-number {
    font-family: var(--font-heading);
    font-size: 56px;
    font-weight: 800;
    color: rgba(212, 163, 115, 0.15);
    position: absolute;
    top: 20px;
    right: 30px;
    line-height: 1;
}

.adv-card h4 {
    font-size: 18px;
    margin-bottom: 12px;
    margin-top: 12px;
}

.adv-card p {
    font-size: 14px;
    color: var(--text-muted);
}

/* CTA Section */
.cta {
    background-color: var(--bg-dark);
    padding: 80px 0;
    color: var(--white);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

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

.cta-content h2 {
    color: var(--white);
    font-size: 32px;
    margin-bottom: 12px;
}

.cta-content p {
    color: rgba(254, 250, 224, 0.7);
    font-size: 16px;
}

/* Modal and Quiz System */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(27, 38, 27, 0.75);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(8px);
}

.modal-content {
    background-color: var(--white);
    width: 100%;
    max-width: 600px;
    border-radius: 20px;
    padding: 40px;
    position: relative;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
    border: 1px solid var(--border-color);
}

.close-modal {
    position: absolute;
    top: 20px;
    right: 24px;
    font-size: 28px;
    font-weight: bold;
    color: var(--text-muted);
    cursor: pointer;
    transition: var(--transition);
}

.close-modal:hover {
    color: var(--primary-dark);
}

/* Quiz Styles */
.quiz-header {
    margin-bottom: 30px;
}

.quiz-progress-bar {
    width: 100%;
    height: 6px;
    background-color: var(--gray-light);
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 12px;
}

.quiz-progress {
    width: 25%;
    height: 100%;
    background-color: var(--primary);
    transition: width 0.3s ease;
}

.quiz-step-indicator {
    font-size: 14px;
    font-weight: 600;
    color: var(--accent);
}

.quiz-step {
    display: none;
}

.quiz-step.active {
    display: block;
    animation: fadeIn 0.4s ease;
}

.quiz-question {
    font-size: 22px;
    margin-bottom: 24px;
}

.quiz-subtext {
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: 24px;
}

.quiz-options-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    margin-bottom: 30px;
}

.quiz-option-card {
    display: flex;
    align-items: center;
    padding: 18px 24px;
    border: 2px solid var(--gray-light);
    border-radius: 10px;
    cursor: pointer;
    transition: var(--transition);
}

.quiz-option-card input[type="radio"] {
    margin-right: 16px;
    width: 18px;
    height: 18px;
    accent-color: var(--primary);
}

.option-title {
    font-size: 16px;
    font-weight: 500;
}

.quiz-option-card:hover {
    border-color: var(--accent);
    background-color: rgba(212, 163, 115, 0.05);
}

.quiz-option-card input[type="radio"]:checked + .option-title {
    color: var(--primary-dark);
}

.quiz-option-card:has(input[type="radio"]:checked) {
    border-color: var(--primary);
    background-color: rgba(30, 63, 32, 0.05);
}

.quiz-actions {
    display: flex;
    justify-content: space-between;
    border-top: 1px solid var(--gray-light);
    padding-top: 20px;
}

/* Lead Form in Quiz */
.lead-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 24px;
}

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

.form-group label {
    font-size: 14px;
    font-weight: 600;
}

.form-group input {
    padding: 14px;
    border: 2px solid var(--gray-light);
    border-radius: 8px;
    font-size: 16px;
    transition: var(--transition);
}

.form-group input:focus {
    outline: none;
    border-color: var(--primary);
}

.messenger-select {
    margin-bottom: 20px;
}

.messenger-title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 10px;
}

.messenger-options {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.messenger-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--gray-light);
    padding: 12px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.messenger-btn input {
    display: none;
}

.messenger-btn:hover {
    border-color: var(--accent);
}

.messenger-btn:has(input:checked) {
    background-color: var(--primary);
    border-color: var(--primary);
    color: var(--white);
}

/* Success State */
.quiz-success {
    text-align: center;
    animation: scaleUp 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.success-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 80px;
    height: 80px;
    background-color: rgba(30, 63, 32, 0.1);
    color: var(--primary);
    font-size: 40px;
    border-radius: 50%;
    margin-bottom: 24px;
}

.quiz-success h3 {
    font-size: 26px;
    margin-bottom: 12px;
}

.quiz-success p {
    font-size: 15px;
    color: var(--text-muted);
    margin-bottom: 30px;
    max-width: 400px;
    margin-left: auto;
    margin-right: auto;
}

/* Footer */
.footer {
    background-color: var(--bg-dark);
    padding: 60px 0;
    color: rgba(254, 250, 224, 0.7);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.footer-container {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 48px;
}

.footer-left .logo {
    color: var(--white);
    margin-bottom: 16px;
}

.footer-copy {
    font-size: 14px;
    margin-bottom: 8px;
}

.footer-legal {
    font-size: 12px;
    color: rgba(254, 250, 224, 0.4);
}

.footer-right {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
}

.footer-phone {
    font-size: 14px;
    margin-bottom: 4px;
}

.footer-phone-num {
    text-decoration: none;
    color: var(--white);
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 16px;
    transition: var(--transition);
}

.footer-phone-num:hover {
    color: var(--accent);
}

.footer-address {
    font-size: 14px;
    margin-bottom: 16px;
}

.privacy-link {
    color: rgba(254, 250, 224, 0.4);
    font-size: 12px;
    text-decoration: underline;
}

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

/* Keyframes */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes scaleUp {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

/* Responsive CSS */
@media (max-width: 1024px) {
    .logo {
        font-size: 18px;
    }
    .nav {
        gap: 16px;
    }
    .nav-link {
        font-size: 14px;
    }
    .phone-link {
        font-size: 15px;
    }
    .contacts {
        gap: 10px;
    }
}

@media (max-width: 991px) {
    .hero-container {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .hero-content, .hero-image-wrapper {
        min-width: 0;
        width: 100%;
    }
    
    .hero-image-wrapper {
        max-width: 500px;
        margin: 0 auto;
    }

    .cta-container {
        flex-direction: column;
        text-align: center;
        gap: 24px;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 16px;
    }

    .header-container {
        height: 60px;
        padding: 0 16px;
    }

    .logo {
        font-size: 16px;
    }

    .nav {
        display: none;
    }

    .header .open-quiz-btn {
        display: none; /* Hide header button on mobile to save space */
    }

    .contacts {
        gap: 0;
    }

    .phone-link {
        font-size: 14px;
    }

    .badge {
        font-size: 12px;
        padding: 4px 10px;
        margin-bottom: 16px;
        white-space: nowrap;
        display: inline-block;
        max-width: 100%;
        text-overflow: ellipsis;
        overflow: hidden;
    }

    .hero {
        padding-top: 100px;
        padding-bottom: 50px;
    }

    .hero-title {
        font-size: 24px;
        line-height: 1.25;
        margin-bottom: 16px;
        word-break: keep-all;
        overflow-wrap: break-word;
        hyphens: none;
    }

    .hero-desc {
        font-size: 15px;
        margin-bottom: 24px;
    }

    .hero-features {
        flex-direction: column;
        gap: 12px;
    }

    .services, .advantages {
        padding: 60px 0;
    }

    .section-title {
        font-size: 28px;
        margin-bottom: 12px;
    }

    .cta-content h2 {
        font-size: 24px;
    }

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

    .footer-right {
        align-items: flex-start;
        text-align: left;
    }

    /* Mobile modal / quiz fixes */
    .modal-content {
        padding: 24px 16px;
        width: 92%;
        border-radius: 16px;
    }

    .quiz-question {
        font-size: 18px;
        margin-bottom: 16px;
    }

    .quiz-option-card {
        padding: 14px 16px;
    }

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

    .messenger-options {
        grid-template-columns: 1fr; /* Stack messenger options on mobile */
        gap: 8px;
    }

    .messenger-btn {
        padding: 10px;
        font-size: 13px;
    }
}

/* Swiper Hero Slider Custom Styles */
.hero-slider {
    width: 100%;
    height: 520px;
    border-radius: 20px;
    overflow: hidden;
    position: relative;
}

.hero-slider .swiper-slide {
    position: relative;
    width: 100%;
    height: 100%;
}

.slide-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0.4) 60%, rgba(0, 0, 0, 0) 100%);
    color: var(--white);
    padding: 24px 20px 32px 20px;
    font-size: 16px;
    font-weight: 500;
    text-align: center;
    z-index: 10;
    pointer-events: none;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.6);
}

.hero-slider .hero-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.hero-slider .swiper-button-next,
.hero-slider .swiper-button-prev {
    color: var(--white);
    background: rgba(30, 63, 32, 0.6);
    width: 44px;
    height: 44px;
    border-radius: 50%;
    backdrop-filter: blur(4px);
    transition: var(--transition);
}

.hero-slider .swiper-button-next:after,
.hero-slider .swiper-button-prev:after {
    font-size: 18px;
    font-weight: bold;
}

.hero-slider .swiper-button-next:hover,
.hero-slider .swiper-button-prev:hover {
    background: rgba(30, 63, 32, 0.9);
    transform: scale(1.05);
}

.hero-slider .swiper-pagination-bullet {
    background: var(--white);
    opacity: 0.5;
}

.hero-slider .swiper-pagination-bullet-active {
    background: var(--accent);
    opacity: 1;
    width: 12px;
    border-radius: 4px;
}

@media (max-width: 991px) {
    .hero-slider {
        height: 400px;
        max-width: 600px;
        margin: 0 auto;
    }
    .slide-caption {
        font-size: 14px;
        padding: 16px 16px 28px 16px;
    }
    .advantages-grid, .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .hero-slider {
        height: 280px;
    }
    .slide-caption {
        font-size: 13px;
        padding: 12px 12px 24px 12px;
    }
    .hero-slider .swiper-button-next,
    .hero-slider .swiper-button-prev {
        width: 32px;
        height: 32px;
    }
    .hero-slider .swiper-button-next:after,
    .hero-slider .swiper-button-prev:after {
        font-size: 12px;
    }
    .advantages-grid, .services-grid {
        grid-template-columns: 1fr;
    }
}

