* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --blue-50: #e8f1ff;
    --blue-200: #a7c8ff;
    --blue-400: #4ea1ff;
    --blue-500: #2a7fff;
    --blue-600: #0d6efd;
    --blue-700: #0b5ed7;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    line-height: 1.4;
    color: #000;
    background: #fbfaf8;
    font-size: 16px;
}

/* Header */
.header {
    padding: 32px 0;
    text-align: center;
    border-bottom: 1px solid #e5e5e5;
    position: relative;
    background: #fff;
}

.header-left {
    position: absolute;
    left: 24px;
    top: 50%;
    transform: translateY(-50%);
    display: inline-flex;
    align-items: center;
    gap: 16px;
}

.phone {
    color: #000;
    text-decoration: none;
    font-weight: 800;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.phone svg {
    width: 16px;
    height: 16px;
}

.logo {
    font-size: 20px;
    font-weight: 900;
    color: #000;
    text-decoration: none;
    display: block;
    letter-spacing: 0.3px;
    position: relative;
    transition: transform 0.2s ease, text-shadow 0.2s ease, color 0.2s ease;
}

.login-link {
    position: absolute;
    right: 24px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 14px;
    color: #000;
    text-decoration: none;
    padding: 8px 12px;
    border-radius: 8px;
    transition: background-color 0.2s ease, color 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.login-link:hover {
    background: rgba(13,110,253,0.1);
}

.login-link svg {
    width: 16px;
    height: 16px;
}

.logo:hover {
    transform: translateY(-1px);
    text-shadow: 0 6px 18px rgba(13, 110, 253, 0.15);
}

.logo:active {
    transform: translateY(0);
}

/* Main content */
.main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Hero section */
.hero {
    text-align: center;
    padding: 64px 0;
}

.hero h1 {
    font-size: 52px;
    font-weight: 900;
    line-height: 1.2;
    margin-bottom: 32px;
    color: #000;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.download-buttons {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-bottom: 64px;
    margin-top: 24px;
    flex-wrap: wrap;
}

/* Inside popup form/success state, remove extra bottom margin */
.popup-form .download-buttons { margin-bottom: 0; }
.popup-success .download-buttons { margin-bottom: 0; }

.download-btn {
    display: inline-flex;
    align-items: center;
    background: linear-gradient(135deg, var(--blue-600) 0%, var(--blue-700) 100%);
    color: #fff;
    padding: 10px 20px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    transition: background-color 0.2s, transform 0.2s ease, box-shadow 0.2s ease, background-position 0.3s ease;
    background-size: 200% 200%;
    box-shadow: 0 6px 16px rgba(13, 110, 253, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.12);
    position: relative;
    overflow: hidden;
}

.download-btn svg {
    width: 16px;
    height: 16px;
    margin-right: 8px;
    flex: 0 0 auto;
}

.download-btn:hover {
    background-position: right center;
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(13, 110, 253, 0.35);
}

.download-btn:active {
    transform: translateY(0px) scale(0.98);
    box-shadow: 0 4px 12px rgba(13, 110, 253, 0.28);
}

.download-btn:focus-visible {
    outline: 2px solid var(--blue-600);
    outline-offset: 2px;
}

/* Feature sections */
.feature {
    margin-bottom: 80px;
    display: flex;
    align-items: center;
    gap: 48px;
    background: #fff;
    box-shadow: 0px 0px 0px 1px rgba(0, 0, 0, .13);
    border-radius: 56px;
    padding: 48px;
}

.feature:nth-child(even) {
    flex-direction: row-reverse;
}

.feature-content {
    flex: 1;
}

.feature h2 {
    font-size: 24px;
    font-weight: 900;
    margin-bottom: 12px;
    color: #000;
}

.feature p {
    color: #666;
    line-height: 1.5;
    font-size: 16px;
}

.feature-image {
    flex: 1;
    height: 320px;
    background: #f5f5f5;
    border-radius: 12px;
    border: 1px solid rgba(0,0,0,0.12);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #999;
    font-size: 16px;
    position: relative;
    overflow: hidden;
}

.feature-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: none;
    opacity: 0.1;
}

.feature-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}


/* Footer */
.footer {
    background: #fff;
    padding: 48px 24px 32px;
    margin: 64px 0 0;
    border-top: 1px solid #e5e5e5;
    box-shadow: 0px 0px 0px 1px rgba(0, 0, 0, .13);
    border-radius: 0;
}

.footer-content {
    max-width: 1050px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 24px 32px;
}

.footer-section {
    margin-bottom: 32px;
}

.footer-section h3 {
    font-size: 18px;
    font-weight: 900;
    margin-bottom: 8px;
    color: #000;
}

.footer-section p,
.footer-section a {
    color: #666;
    text-decoration: none;
    margin-bottom: 4px;
    display: block;
    font-size: 14px;
    line-height: 1.4;
    transition: color 0.2s ease;
}

.footer-section a:hover {
    color: var(--blue-600);
}

.footer-section a {
    position: relative;
}

.footer-section a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -2px;
    width: 100%;
    height: 1px;
    background: currentColor;
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.25s ease;
}

.footer-section a:hover::after {
    transform: scaleX(1);
}

.footer-bottom {
    text-align: center;
    padding-top: 32px;
    border-top: 1px solid #e5e5e5;
    color: #666;
    font-size: 12px;
}

/* Responsive */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 28px;
    }

    .feature {
        flex-direction: column !important;
        gap: 32px;
        margin-bottom: 64px;
    }

    .feature h2 {
        font-size: 20px;
    }

    .feature p {
        font-size: 14px;
    }

    .download-buttons {
        flex-direction: column;
        align-items: center;
    }

    .download-btn {
        width: 180px;
        justify-content: center;
        text-align: center;
    }

    .footer {
        border-radius: 28px;
        margin: 48px -16px 0;
        padding: 40px 16px 24px;
    }
    .header-left {
        left: 16px;
        gap: 12px;
    }
    .phone {
        font-size: 13px;
    }
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

body.no-scroll {
    overflow: hidden;
    height: 100vh;
}

/* Services grid */
.services {
    margin: 0 0 80px;
}

/* Testimonials */
.testimonials {
    width: 100vw;
    margin: 0;
    background: transparent;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
}

.testimonials-inner {
    max-width: 100%;
    margin: 0 auto;
    padding: 40px 24px 56px;
    position: relative;
}

.testimonials-header {
    text-align: center;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.testimonials-header h2 {
    font-size: 36px;
    font-weight: 900;
    margin-bottom: 16px;
}

.testimonials-slider {
    position: relative;
    overflow: hidden;
}

.testimonials-track {
    display: flex;
    transition: transform 0.5s ease;
}

.testimonials-slider.multi .testimonials-track {
    gap: 16px;
    flex-wrap: nowrap;
}

.testimonials-slider.multi .testimonial {
    flex: 0 0 auto;
    width: calc((100% - 16px * 4) / 5); /* 5 карточек в ряд с учётом 4 промежутков по 16px */
}

.testimonial {
    flex: 0 0 100%;
    padding: 24px 8px;
}

.testimonial-card {
    background: #fff;
    border: 1px solid rgba(0,0,0,.13);
}

.testimonial-quote {
    font-size: 18px;
    line-height: 1.6;
}

.testimonial-author {
    margin-top: 12px;
    color: #cfcfcf;
    font-size: 14px;
}

.testimonials-nav {
    position: absolute;
    background: rgba(0,0,0,.45);
    color: #fff;
    border: 0;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 16px rgba(0,0,0,.25);
    z-index: 2;
}

.testimonials-nav.prev { left: 16px; top: 12.5%; transform: none; }
.testimonials-nav.next { right: 16px; top: 12.5%; transform: none; }

.testimonials-nav:hover { background: rgba(0,0,0,.6); }
/* remove press animation */
.testimonials-nav:active { }
.testimonials-nav[disabled] {
    opacity: .4;
    cursor: default;
}

.testimonials-dots {
    display: flex;
    gap: 6px;
    justify-content: center;
    margin-top: 12px;
}

.testimonials-dots button {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    border: 0;
    background: rgba(255,255,255,.35);
}

.testimonials-dots button.is-active { background: #fff; }

.testimonials-count {
    text-align: center;
    font-size: 12px;
    color: #888;
    margin-top: 6px;
}

/* Popup */
.popup {
    position: fixed;
    inset: 0;
    display: none;
    z-index: 1000;
}

.popup.is-open {
    display: block;
}

.popup-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,.45);
    backdrop-filter: blur(2px);
}

.popup-content {
    position: relative;
    background: #fff;
    width: min(560px, calc(100% - 32px));
    margin: 10vh auto 0;
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 10px 40px rgba(0,0,0,.22);
}

.is-hidden { display: none !important; }

.popup-close {
    position: absolute;
    right: 8px;
    top: 8px;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    border: none;
    background: transparent;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
}

.popup-form .form-row {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin: 12px 0;
}

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

.popup-form .form-row.has-icon {
    position: relative;
}

.popup-form .form-row .input-icon {
    position: absolute;
    left: 12px;
    top: 35px;
    color: #7a7a7a;
}

.popup-form .form-row .input-icon svg {
    width: 16px;
    height: 16px;
}

.popup-form label {
    font-size: 14px;
    color: #333;
}

.popup-form input,
.popup-form textarea {
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 14px;
}

.feature--payment { align-items: flex-start; }
.feature--payment .feature-image {
    background: #fff;
    height: auto;
    padding: 16px;
    border: 0; /* remove outer gray border */
}
.feature--payment .feature-image::before { display: none; content: none; }

.feature--payment .popup-form {
    width: 100%;
    max-width: 520px;
    margin: 0 auto;
    background: transparent;
    box-shadow: none;
    border: 0;
}

.feature--payment .popup-form select {
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 14px;
}

@media (max-width: 768px) {
    .feature--payment .feature-image { height: auto; padding: 12px; }
}

.popup-form .has-icon input {
    padding-left: 34px;
}

.popup-form .form-actions {
    margin-top: 16px;
}

.popup-form .form-status {
    margin-top: 12px;
    font-size: 14px;
}

.popup-form .form-status.success { color: #137333; }
.popup-form .form-status.error { color: #b3261e; }

.popup-form .download-btn {
    position: relative;
    gap: 8px;
}

.popup-form .download-btn .spinner {
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255,255,255,.5);
    border-top-color: #fff;
    border-radius: 50%;
    display: none;
    animation: spin 0.9s linear infinite;
}

.popup-form .download-btn.loading .spinner { display: inline-block; }
.popup-form .download-btn.loading .btn-label { opacity: .8; }

@keyframes spin {
    to { transform: rotate(360deg); }
}

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

.service-card {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0px 0px 0px 1px rgba(0,0,0,.13);
    padding: 24px;
}


.service-title {
    font-weight: 900;
    font-size: 18px;
    margin-bottom: 8px;
}

.service-price {
    color: #000;
    font-size: 16px;
}

.service-actions {
    margin-top: 16px;
}

@media (max-width: 992px) {
    /* 3 карточки в ряд на планшетах/малых ноутбуках */
    .testimonials-slider.multi .testimonial { width: calc((100% - 16px * 2) / 3); }
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    /* 1 карточка в ряд на телефонах */
    .testimonials-slider.multi .testimonial { width: 100%; }
    .services-grid {
        grid-template-columns: 1fr;
    }
    /* Move slider arrows lower on phones */
    .testimonials-nav.prev { top: 82.5%; }
    .testimonials-nav.next { top: 82.5%; }

    /* Footer side paddings on phones and no rounded corners */
    .footer {
        margin: 48px 0 0; /* cancel tablet full-bleed negative margins */
        padding-left: 16px;
        padding-right: 16px;
        border-radius: 0;
    }

    /* Buttons: do not wrap text, let buttons expand width */
    .download-btn {
        width: auto;
        white-space: nowrap;
    }
}

@media (max-width: 768px) and (min-width: 601px) {
    /* 2 карточки в ряд на больших телефонах/малых планшетах */
    .testimonials-slider.multi .testimonial { width: calc((100% - 16px * 1) / 2); }
}

@media (min-width: 993px) and (max-width: 1200px) {
    /* 4 карточки в ряд на экранах чуть уже контейнера */
    .testimonials-slider.multi .testimonial { width: calc((100% - 16px * 3) / 4); }
}


