/* ===== RESET & VARIABLES ===== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --navy: #0B1B33;
    --navy-light: #1A2F4E;
    --accent: #1B6BFF;
    --accent-hover: #0A4FD6;
    --accent-glow: rgba(27, 107, 255, 0.25);
    --green: #0FA958;
    --green-bg: #E6F7EE;
    --green-border: #C5E8D5;
    --green-text: #0A7A3E;
    --white: #FFFFFF;
    --gray-50: #F7F9FC;
    --gray-100: #EEF2F7;
    --gray-300: #C5D0DE;
    --gray-500: #6B7A8F;
    --gray-700: #3A4A5E;
    --text: #1A2A3A;
    --text-light: #5A6A7E;
    --radius: 14px;
    --radius-sm: 10px;
    --shadow: 0 4px 24px rgba(11, 27, 51, 0.08);
    --shadow-lg: 0 12px 40px rgba(11, 27, 51, 0.12);
    --font: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font);
    color: var(--text);
    background: var(--white);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

.container {
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 20px;
}

.section {
    padding: 64px 0;
}

.section--gray {
    background: var(--gray-50);
}

h1 { font-size: clamp(28px, 5vw, 44px); font-weight: 800; line-height: 1.2; letter-spacing: -0.02em; }
h2 { font-size: clamp(24px, 3.5vw, 34px); font-weight: 700; line-height: 1.25; margin-bottom: 12px; letter-spacing: -0.01em; }
h3 { font-size: 18px; font-weight: 700; line-height: 1.3; margin-bottom: 6px; }
.subtitle { font-size: clamp(15px, 2vw, 18px); color: var(--text-light); max-width: 640px; }
.section-header { margin: 0 auto 40px; text-align: center; }
.section-header h2 { margin-bottom: 8px; }
.section-header .subtitle { margin: 0 auto; }

/* ===== BUTTONS ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 16px 36px;
    border-radius: 60px;
    font-size: 17px;
    font-weight: 700;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    line-height: 1;
    white-space: nowrap;
}

.btn--primary {
    background: var(--accent);
    color: var(--white);
    box-shadow: 0 4px 16px var(--accent-glow);
}

.btn--primary:hover {
    background: var(--accent-hover);
    transform: translateY(-1px);
    box-shadow: 0 6px 24px var(--accent-glow);
}

.btn--primary:active {
    transform: translateY(0);
}

.btn--block {
    width: 100%;
}

.btn--sm {
    padding: 12px 24px;
    font-size: 15px;
}

/* ===== BADGES ===== */
.badges {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 20px;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    background: var(--gray-100);
    border-radius: 40px;
    font-size: 13px;
    font-weight: 600;
    color: var(--gray-700);
}

.badge--green {
    background: var(--green-bg);
    color: var(--green-text);
}

/* ===== HEADER ===== */
.header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--gray-100);
}

.header__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}

.logo {
    font-size: 20px;
    font-weight: 800;
    color: var(--navy);
    text-decoration: none;
    letter-spacing: -0.02em;
}

.logo span {
    color: var(--accent);
}

.header__nav {
    display: flex;
    align-items: center;
    gap: 24px;
}

.header__link {
    font-size: 14px;
    font-weight: 600;
    color: var(--gray-700);
    text-decoration: none;
    transition: color 0.2s ease;
}

.header__link:hover {
    color: var(--accent);
}

.header__phone {
    font-weight: 700;
    color: var(--navy);
    text-decoration: none;
    font-size: 16px;
}

/* ===== HERO ===== */
.hero {
    padding: 64px 0 72px;
    background: linear-gradient(165deg, var(--gray-50) 0%, #E8EEF8 60%, var(--white) 100%);
    position: relative;
    overflow: hidden;
}

.hero::after {
    content: '';
    position: absolute;
    top: -30%;
    right: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(27, 107, 255, 0.06) 0%, transparent 70%);
    pointer-events: none;
}

.hero__grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 460px);
    grid-template-areas:
        'content calc'
        'disclaimer calc';
    column-gap: 56px;
}

.hero__content {
    grid-area: content;
    align-self: end;
}

.hero h1 {
    margin-bottom: 16px;
}

.hero h1 .highlight {
    color: var(--accent);
    white-space: nowrap;
}

.hero .subtitle {
    margin-bottom: 0;
}

.hero__disclaimer {
    grid-area: disclaimer;
    align-self: start;
    margin-top: 24px;
    font-size: 12px;
    color: var(--gray-500);
    line-height: 1.5;
}

/* ===== CALCULATOR ===== */
.calc-inline {
    background: var(--white);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: var(--shadow-lg);
    grid-area: calc;
    align-self: center;
}

.calc-tabs {
    display: flex;
    gap: 6px;
    background: var(--gray-100);
    padding: 4px;
    border-radius: var(--radius-sm);
    margin-bottom: 20px;
}

.calc-tab {
    flex: 1;
    border: none;
    background: transparent;
    padding: 10px 8px;
    font-size: 13px;
    font-weight: 700;
    color: var(--gray-700);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.calc-tab.is-active {
    background: var(--white);
    color: var(--navy);
    box-shadow: 0 2px 8px rgba(11, 27, 51, 0.08);
}

.calc-inline__row {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}

.calc-field {
    flex: 1;
    min-width: 150px;
}

.calc-field label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--gray-700);
    margin-bottom: 6px;
}

.calc-field .value {
    font-size: 22px;
    font-weight: 800;
    color: var(--navy);
    margin-bottom: 8px;
}

.calc-field input[type="range"] {
    width: 100%;
    height: 6px;
    -webkit-appearance: none;
    background: var(--gray-100);
    border-radius: 3px;
    outline: none;
}

.calc-field input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 22px;
    height: 22px;
    background: var(--accent);
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 2px 8px var(--accent-glow);
}

.calc-field input[type="range"]::-moz-range-thumb {
    width: 22px;
    height: 22px;
    background: var(--accent);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 2px 8px var(--accent-glow);
}

.calc-checkbox {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    background: var(--green-bg);
    border-radius: var(--radius-sm);
    margin-bottom: 16px;
    cursor: pointer;
    border: 1px solid var(--green-border);
}

.calc-checkbox input[type="checkbox"] {
    width: 20px;
    height: 20px;
    accent-color: var(--green);
    cursor: pointer;
    flex-shrink: 0;
}

.calc-checkbox span {
    font-size: 14px;
    font-weight: 600;
    color: var(--green-text);
}

.calc-breakdown {
    border-top: 1px solid var(--gray-100);
    padding-top: 12px;
    margin-bottom: 12px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.calc-breakdown__row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    color: var(--text-light);
}

.calc-breakdown__row strong {
    color: var(--navy);
    font-weight: 600;
}

.calc-result {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: 12px 0 16px;
    border-top: 1px dashed var(--gray-300);
    flex-wrap: wrap;
    gap: 8px;
}

.calc-result .label {
    font-size: 15px;
    font-weight: 600;
    color: var(--navy);
}

.calc-result .amount {
    font-size: 24px;
    font-weight: 800;
    color: var(--navy);
}

.calc-result .amount small {
    font-size: 13px;
    font-weight: 600;
    color: var(--green-text);
    background: var(--green-bg);
    padding: 2px 8px;
    border-radius: 4px;
    margin-left: 6px;
}

/* ===== SVO BLOCK ===== */
.svo-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.svo-card {
    background: var(--white);
    border-radius: var(--radius);
    padding: 28px 24px;
    box-shadow: var(--shadow);
    border-top: 4px solid var(--green);
    transition: transform 0.2s, box-shadow 0.2s;
    text-align: center;
}

.svo-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.svo-card__icon {
    width: 48px;
    height: 48px;
    background: var(--green-bg);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    margin: 0 auto 16px;
}

.svo-card p {
    font-size: 14px;
    color: var(--text-light);
    line-height: 1.5;
}

.svo-note {
    margin-top: 24px;
    padding: 16px 20px;
    background: #FFF9E6;
    border-radius: var(--radius-sm);
    border-left: 4px solid #F5A623;
    font-size: 14px;
    color: #7A5B00;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* ===== STEPS ===== */
.steps {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.step {
    text-align: center;
    padding: 32px 20px;
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.step__num {
    width: 44px;
    height: 44px;
    background: var(--accent);
    color: var(--white);
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: 800;
    margin-bottom: 16px;
}

.step h3 {
    font-size: 16px;
    margin-bottom: 6px;
}

.step p {
    font-size: 14px;
    color: var(--text-light);
}

/* ===== FEATURES ===== */
.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.feature {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px;
    background: var(--white);
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow);
}

.feature__icon {
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    background: var(--gray-100);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.feature h3 {
    font-size: 15px;
    margin-bottom: 2px;
}

.feature p {
    font-size: 13px;
    color: var(--text-light);
    line-height: 1.5;
}

/* ===== FAQ ===== */
.faq-list {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    border-bottom: 1px solid var(--gray-100);
    padding: 20px 0;
}

.faq-item:first-child {
    border-top: 1px solid var(--gray-100);
}

.faq-question {
    font-size: 16px;
    font-weight: 700;
    color: var(--navy);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    list-style: none;
}

.faq-question::-webkit-details-marker {
    display: none;
}

.faq-question::after {
    content: '+';
    font-size: 24px;
    font-weight: 300;
    color: var(--accent);
    transition: transform 0.2s;
    flex-shrink: 0;
}

details[open] .faq-question::after {
    content: '−';
}

.faq-answer {
    padding-top: 12px;
    font-size: 15px;
    color: var(--text-light);
    line-height: 1.7;
}

/* ===== FINAL CTA ===== */
.final-cta {
    background: linear-gradient(135deg, var(--navy) 0%, var(--navy-light) 100%);
    color: var(--white);
    text-align: center;
    padding: 72px 0;
}

.final-cta h2 {
    color: var(--white);
    margin-bottom: 12px;
}

.final-cta .subtitle {
    color: rgba(255, 255, 255, 0.7);
    margin: 0 auto 32px;
}

.final-cta__note {
    margin-top: 16px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.5);
}

.final-cta .btn--primary {
    background: var(--white);
    color: var(--navy);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.final-cta .btn--primary:hover {
    background: var(--gray-50);
    box-shadow: 0 6px 28px rgba(0, 0, 0, 0.3);
}

/* ===== FOOTER ===== */
.footer {
    background: var(--navy);
    color: rgba(255, 255, 255, 0.6);
    padding: 48px 0 32px;
    font-size: 13px;
    line-height: 1.7;
}

.footer a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: underline;
}

.footer__requisites {
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer__warning {
    background: rgba(255, 255, 255, 0.06);
    padding: 16px 20px;
    border-radius: var(--radius-sm);
    margin-bottom: 20px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.7);
}

.footer__links {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 24px;
}

.footer__copy {
    margin-top: 16px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.4);
}

/* ===== MODAL ===== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(11, 27, 51, 0.65);
    backdrop-filter: blur(4px);
    display: flex;
    justify-content: center;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
    padding: 20px;
}

.modal-overlay.is-active {
    opacity: 1;
    pointer-events: auto;
}

.modal-window {
    background: var(--white);
    border-radius: var(--radius);
    padding: 32px;
    max-width: 440px;
    width: 100%;
    margin: auto;
    box-shadow: var(--shadow-lg);
    position: relative;
    transform: translateY(20px);
    transition: transform 0.25s ease;
}

.modal-overlay.is-active .modal-window {
    transform: translateY(0);
}

#docModal {
    z-index: 1100;
}

.modal-window--doc {
    max-width: 680px;
    max-height: calc(100vh - 40px);
    max-height: calc(100dvh - 40px);
    display: flex;
    flex-direction: column;
}

.doc-body {
    overflow-y: auto;
    font-size: 14px;
    line-height: 1.6;
    color: var(--text);
    padding: 12px 4px 16px 0;
    margin-bottom: 16px;
}

.doc-body h4 {
    font-size: 15px;
    font-weight: 700;
    margin: 14px 0 6px;
    color: var(--navy);
}

.doc-body p {
    margin-bottom: 10px;
    color: var(--text-light);
}

.doc-body ul {
    padding-left: 20px;
    margin-bottom: 12px;
    color: var(--text-light);
}

.doc-footer {
    display: flex;
    justify-content: flex-end;
    border-top: 1px solid var(--gray-100);
    padding-top: 16px;
}

.modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: none;
    border: none;
    font-size: 24px;
    color: var(--gray-500);
    cursor: pointer;
    line-height: 1;
}

.modal-header h3 {
    font-size: 22px;
    color: var(--navy);
    margin-bottom: 6px;
}

.modal-header p {
    font-size: 14px;
    color: var(--text-light);
    margin-bottom: 16px;
}

.modal-summary {
    background: var(--gray-50);
    border: 1px solid var(--gray-100);
    border-radius: var(--radius-sm);
    padding: 12px 14px;
    margin-bottom: 20px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 13px;
}

.modal-summary__row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-light);
}

.modal-summary__row strong {
    color: var(--navy);
}

.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--gray-700);
    margin-bottom: 6px;
}

.form-input {
    width: 100%;
    height: 48px;
    padding: 0 16px;
    border: 1px solid var(--gray-300);
    border-radius: var(--radius-sm);
    font-size: 15px;
    color: var(--text);
    outline: none;
    transition: border-color 0.2s;
}

.form-input:focus {
    border-color: var(--accent);
}

.form-input.is-invalid {
    border-color: #E53935;
    background-color: #FFF5F5;
}

.form-input.is-invalid:focus {
    border-color: #D32F2F;
}

.form-error {
    display: none;
    font-size: 12px;
    font-weight: 500;
    color: #E53935;
    margin-top: 5px;
    line-height: 1.3;
}

.form-error.is-visible {
    display: block;
}

.form-global-error {
    display: none;
    padding: 10px 14px;
    background: #FFEBEE;
    border: 1px solid #FFCDD2;
    border-radius: var(--radius-sm);
    color: #C62828;
    font-size: 13px;
    margin-bottom: 16px;
    line-height: 1.4;
}

.form-global-error.is-visible {
    display: block;
}

.file-upload.is-invalid .file-upload__label {
    border-color: #E53935;
    background-color: #FFF5F5;
}

.form-checkbox.is-invalid {
    color: #D32F2F;
}

/* Modal Success State */
.modal-success {
    text-align: center;
    padding: 16px 8px;
}

.modal-success__icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--green-bg);
    color: var(--green);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    font-weight: 800;
    margin: 0 auto 16px;
}

.modal-success h3 {
    font-size: 22px;
    color: var(--navy);
    margin-bottom: 8px;
}

.modal-success p {
    font-size: 14px;
    color: var(--text-light);
    line-height: 1.5;
    margin-bottom: 24px;
}

.file-upload {
    position: relative;
}

.file-upload__input {
    position: absolute;
    width: 0.1px;
    height: 0.1px;
    opacity: 0;
    overflow: hidden;
    z-index: -1;
}

.file-upload__label {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    border: 1px dashed var(--gray-300);
    border-radius: var(--radius-sm);
    background: var(--gray-50);
    cursor: pointer;
    font-size: 13px;
    color: var(--navy);
    transition: all 0.2s ease;
}

.file-upload__label:hover {
    border-color: var(--accent);
    background: #F0F4FC;
}

.file-upload__icon {
    font-size: 18px;
    flex-shrink: 0;
}

.file-upload__text {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.form-hint {
    display: block;
    font-size: 11px;
    color: var(--gray-500);
    margin-top: 4px;
}

.required-star {
    color: #E53935;
}

.form-checkbox {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 12px;
    color: var(--text-light);
    margin-bottom: 8px;
    cursor: pointer;
}

.form-checkbox input {
    margin-top: 3px;
    accent-color: var(--accent);
}

/* ===== UTILITIES & RESPONSIVE ===== */
.text-center { text-align: center; }
.mt-32 { margin-top: 32px; }

@media (max-width: 1023px) {
    .svo-grid, .steps { grid-template-columns: repeat(2, 1fr); }
    .features-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 899px) {
    .hero__grid {
        grid-template-columns: minmax(0, 1fr);
        grid-template-areas: 'content' 'calc' 'disclaimer';
        row-gap: 28px;
    }
    .hero__content, .calc-inline, .hero__disclaimer {
        align-self: stretch;
        margin-top: 0;
    }
    .calc-inline { max-width: 560px; }
}

@media (max-width: 768px) {
    .header__nav { display: none; }
    .section { padding: 44px 0; }
    .section-header { margin-bottom: 28px; }
    .hero { padding: 32px 0 44px; }
    .header__inner { height: 56px; }
    .logo { font-size: 18px; }
    .header__phone { font-size: 14px; }
    .calc-inline { padding: 18px; }
    .calc-inline__row { gap: 14px; }
    .calc-field .value { font-size: 18px; }
    .calc-result .amount { font-size: 20px; }
    .badges { gap: 6px; }
    .badge { font-size: 12px; padding: 5px 12px; }
    .btn { padding: 14px 28px; font-size: 16px; }
    .step { padding: 24px 14px; }
    .footer__links { flex-direction: column; gap: 10px; }
}

@media (max-width: 600px) {
    .svo-grid, .features-grid { grid-template-columns: 1fr; }
    .svo-card { text-align: left; }
    .svo-card__icon { margin-left: 0; }
    .modal-overlay { padding: 12px; }
    .modal-window { padding: 24px 20px; }
}

@media (max-width: 400px) {
    .hero h1 { font-size: 26px; }
    .calc-inline__row { flex-direction: column; gap: 12px; }
}