/* DirectEU — Минималистичный корпоративный дизайн */
:root {
    --primary: #007bff;
    --cta: #28a745;
    --muted: #6c757d;
    --bg: #f8f9fa;
    --bg-dark: #e9ecef;
    --card-bg: #ffffff;
    --text: #212529;
    --text-muted: #6c757d;
    --border: #dee2e6;
    --shadow: 0 2px 12px rgba(0,0,0,0.08);
    --radius: 8px;
    --radius-lg: 12px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
}

.container {
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ===== Header ===== */
header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255,255,255,0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
    padding: 16px 0;
}

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

.logo {
    text-decoration: none;
    color: var(--text);
}

.logo strong {
    font-size: 1.5rem;
    color: var(--primary);
}

.logo span {
    display: block;
    font-size: 0.75rem;
    font-weight: normal;
    color: var(--text-muted);
    margin-top: 2px;
}

nav {
    display: flex;
    gap: 24px;
}

nav a {
    color: var(--text);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s;
}

nav a:hover {
    color: var(--primary);
}

.nav-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
}

/* ===== Buttons ===== */
.btn {
    display: inline-block;
    padding: 12px 24px;
    font-size: 1rem;
    font-weight: 500;
    border-radius: var(--radius);
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s;
    border: none;
}

.btn-cta {
    background: var(--cta);
    color: white !important;
}

.btn-cta:hover {
    background: #218838;
    transform: translateY(-1px);
}

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

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

/* ===== Hero ===== */
.hero {
    position: relative;
    padding: 80px 0 100px;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 50%, #dee2e6 100%);
    animation: bgFlow 20s ease-in-out infinite;
}

@keyframes bgFlow {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.95; }
}

.hero-inner {
    position: relative;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: center;
}

.hero-content h1 {
    font-size: clamp(1.5rem, 2.5vw, 2rem);
    font-weight: 600;
    margin: 0 0 16px;
    line-height: 1.3;
}

.hero-content p {
    color: var(--text-muted);
    margin: 0 0 24px;
    font-size: 1rem;
}

.hero-map {
    display: flex;
    justify-content: center;
    align-items: center;
}

.hero-map img {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
}

/* ===== Sections common ===== */
section {
    padding: 80px 0;
}

section h2 {
    font-size: 2rem;
    font-weight: 600;
    margin: 0 0 40px;
    text-align: center;
}

/* ===== Benefits ===== */
.benefits {
    background: var(--card-bg);
}

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

.card {
    background: var(--bg);
    padding: 28px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    transition: transform 0.2s, box-shadow 0.2s;
}

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

.card i {
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 16px;
}

.card h3 {
    font-size: 1.1rem;
    margin: 0 0 8px;
}

.card p {
    margin: 0;
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* Addon services - визуально отдельные карточки */
.addon-services {
    margin-top: 48px;
    padding-top: 32px;
    border-top: 1px dashed var(--border);
}

.addon-services h3 {
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: 20px;
}

.addon-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.addon-card {
    background: var(--bg-dark) !important;
    border-style: dashed !important;
    border-color: var(--muted) !important;
}

.addon-card:hover {
    border-color: var(--primary) !important;
}

/* Comparison table */
.comparison-section {
    margin-top: 48px;
}

.comparison-section h3 {
    font-size: 1.25rem;
    margin-bottom: 20px;
}

.comparison-table-wrap {
    overflow-x: auto;
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.comparison-table {
    width: 100%;
    border-collapse: collapse;
}

.comparison-table th,
.comparison-table td {
    padding: 14px 16px;
    text-align: center;
    border-bottom: 1px solid var(--border);
}

.comparison-table th {
    background: var(--bg-dark);
    font-weight: 600;
}

.comparison-table td:first-child {
    text-align: left;
}

.text-success { color: var(--cta); }
.text-muted { color: var(--muted); }

/* ===== How it works ===== */
.how-it-works {
    background: var(--bg);
}

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

.step {
    position: relative;
    padding: 24px;
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    border-left: 4px solid var(--primary);
}

.step-num {
    position: absolute;
    top: -12px;
    left: 24px;
    width: 32px;
    height: 32px;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
}

.step h3 {
    font-size: 1.1rem;
    margin: 16px 0 8px;
}

.step p {
    margin: 0;
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* Accordion */
.accordion-wrap h3 {
    font-size: 1.25rem;
    margin-bottom: 20px;
}

.accordion-item {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    margin-bottom: 8px;
    overflow: hidden;
}

.accordion-header {
    width: 100%;
    padding: 16px 20px;
    background: var(--card-bg);
    border: none;
    text-align: left;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background 0.2s;
}

.accordion-header:hover {
    background: var(--bg-dark);
}

.accordion-header {
    list-style: none;
}

.accordion-header::-webkit-details-marker {
    display: none;
}

.accordion-header::after {
    content: '\f078';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    transition: transform 0.3s;
}

details.accordion-item[open] .accordion-header::after {
    transform: rotate(180deg);
}

.accordion-body {
    padding: 0;
}

.accordion-body p {
    margin: 0;
    padding: 16px 20px;
    background: var(--bg);
    font-size: 0.95rem;
    color: var(--text-muted);
}

/* ===== Pricing ===== */
.pricing {
    background: var(--card-bg);
}

.pricing-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 24px;
    margin-bottom: 40px;
}

.pricing-card {
    padding: 32px;
    background: var(--bg);
    border-radius: var(--radius-lg);
    border: 2px solid var(--border);
    text-align: center;
    transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s;
}

.pricing-card:hover {
    transform: translateY(-4px);
}

.pricing-card .btn {
    transition: transform 0.2s, box-shadow 0.2s, background 0.2s, border-color 0.2s;
}

.pricing-card .btn:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(0,123,255,0.25);
}

.pricing-card .btn-cta:hover {
    box-shadow: 0 4px 12px rgba(40,167,69,0.35);
}

.pricing-card .btn-outline:hover {
    box-shadow: 0 4px 12px rgba(0,123,255,0.2);
}

.pricing-card.featured {
    border-color: var(--primary);
    box-shadow: 0 8px 24px rgba(0,123,255,0.15);
}

.pricing-card h3 {
    font-size: 1.25rem;
    margin: 0 0 12px;
}

.pricing-card .price {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 8px;
}

.pricing-card .price small {
    font-size: 0.85rem;
    font-weight: normal;
    color: var(--text-muted);
}

.pricing-card p {
    margin: 0 0 20px;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.pricing-options {
    background: var(--bg);
    padding: 28px;
    border-radius: var(--radius-lg);
}

.pricing-options h3 {
    font-size: 1.1rem;
    margin-bottom: 16px;
}

.pricing-options ul {
    margin: 0;
    padding-left: 20px;
}

.pricing-options li {
    margin-bottom: 8px;
}

/* ===== Cases ===== */
.cases {
    background: var(--bg);
}

.cases-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
}

.case-card {
    padding: 24px;
    background: var(--card-bg);
    border-radius: var(--radius);
    border: 1px solid var(--border);
}

.case-card h4 {
    font-size: 1rem;
    margin: 0 0 8px;
    color: var(--primary);
}

.case-card p {
    margin: 0;
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* ===== About ===== */
.about {
    background: var(--card-bg);
}

.about-text {
    max-width: 640px;
    margin: 0 auto;
    text-align: center;
    font-size: 1.1rem;
    color: var(--text-muted);
}

/* ===== Contacts ===== */
.contacts {
    background: var(--bg);
}

.contacts-inner {
    max-width: 480px;
    margin: 0 auto;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.contact-form input,
.contact-form textarea {
    padding: 12px 16px;
    font-size: 1rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-family: inherit;
}

.contact-form textarea {
    min-height: 120px;
    resize: vertical;
}

.form-msg {
    font-size: 0.9rem;
    min-height: 1.5em;
}


/* ===== Footer ===== */
footer {
    padding: 24px 0;
    background: var(--bg-dark);
    border-top: 1px solid var(--border);
    text-align: center;
}

footer p {
    margin: 0;
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* ===== Modal ===== */
.modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal.active {
    display: flex;
}

.modal-content {
    position: relative;
    background: white;
    padding: 32px;
    border-radius: var(--radius-lg);
    max-width: 440px;
    width: 100%;
    box-shadow: 0 20px 60px rgba(0,0,0,0.2);
}

.modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-muted);
}

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

.modal-content h4 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary);
    margin: 0 0 16px;
}

.calc-form label {
    display: block;
    margin-bottom: 8px;
    font-size: 0.95rem;
}

.calc-form input[type="range"] {
    width: 100%;
    margin: 8px 0 20px;
}

.checkbox-label {
    display: flex !important;
    align-items: center;
    gap: 8px;
}

.checkbox-label input {
    width: auto;
}

.calc-form select {
    width: 100%;
    padding: 10px 12px;
    font-size: 1rem;
    margin-bottom: 20px;
    border-radius: var(--radius);
    border: 1px solid var(--border);
}

.calc-result {
    margin-bottom: 20px;
    font-size: 1.25rem;
}

.calc-result span {
    color: var(--primary);
    font-weight: 700;
}

.calc-comment {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 16px;
    padding: 12px;
    background: var(--bg);
    border-radius: var(--radius);
    border-left: 3px solid var(--primary);
}

.calc-block {
    margin-bottom: 16px;
}

.order-summary {
    font-size: 0.95rem;
    color: var(--text-muted);
    margin-bottom: 20px;
    padding: 12px;
    background: var(--bg);
    border-radius: var(--radius);
}

.order-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.order-form input {
    padding: 12px 16px;
    font-size: 1rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

/* ===== Auth overlay ===== */
.auth-overlay {
    position: fixed;
    inset: 0;
    background: linear-gradient(135deg, #1e3a5f 0%, #0d2137 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.auth-box {
    background: white;
    padding: 40px;
    border-radius: var(--radius-lg);
    text-align: center;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}

.auth-box h2 {
    margin: 0 0 8px;
    font-size: 1.5rem;
}

.auth-box p {
    margin: 0 0 20px;
    color: var(--text-muted);
}

.auth-box input {
    display: block;
    width: 140px;
    margin: 0 auto 20px;
    padding: 12px 16px;
    font-size: 1.5rem;
    text-align: center;
    letter-spacing: 0.3em;
    border: 2px solid var(--border);
    border-radius: var(--radius);
}

.auth-box button {
    padding: 12px 32px;
    background: var(--cta);
    color: white;
    border: none;
    border-radius: var(--radius);
    font-size: 1rem;
    cursor: pointer;
}

.auth-error {
    display: none;
    color: #dc3545;
    margin-top: 12px;
    font-size: 0.9rem;
}

.auth-error.visible {
    display: block;
}

/* ===== Responsive ===== */
@media (max-width: 992px) {
    .hero-inner {
        grid-template-columns: 1fr;
    }
    .hero-map {
        order: -1;
    }
}

@media (max-width: 768px) {
    .addon-cards {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    nav {
        display: none;
    }
    nav.open {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: white;
        padding: 20px;
        border-bottom: 1px solid var(--border);
    }
    .nav-toggle {
        display: block;
    }
    section {
        padding: 48px 0;
    }
    .comparison-table th,
    .comparison-table td {
        padding: 10px 8px;
        font-size: 0.85rem;
    }
}

@media (max-width: 480px) {
    .features-grid {
        grid-template-columns: 1fr;
    }
    .pricing-cards {
        grid-template-columns: 1fr;
    }
    .modal-content {
        padding: 24px 20px;
        max-height: 90vh;
        overflow-y: auto;
    }
    .hero {
        padding: 48px 0 64px;
    }
    header .container {
        flex-wrap: wrap;
    }
    .logo span {
        font-size: 0.65rem;
    }
}

/* Touch-friendly */
@media (hover: none) {
    .pricing-card .btn:hover {
        transform: none;
    }
}
