@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

:root {
    --primary: #2563eb;
    --primary-main: #2563eb;
    --primary-dark: #1d4ed8;
    --accent: #f59e0b;
    --text-main: #0f172a;
    --text-muted: #64748b;
    --bg-light: #f8fafc;
    --bg-white: #ffffff;
    --glass: rgba(255, 255, 255, 0.8);
    --border-light: rgba(226, 232, 240, 0.8);
    --radius-lg: 24px;
    --radius-md: 12px;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
    scroll-behavior: smooth;
    scroll-margin-top: 140px;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: var(--bg-light);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Layout */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

section {
    padding: 80px 0;
}

/* Typography */
h1 {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 20px;
}

h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 40px;
    text-align: center;
}

.text-center {
    text-align: center;
}

.mt-60 {
    margin-top: 60px !important;
}

.text-gradient {
    background: linear-gradient(135deg, var(--text-main) 0%, var(--primary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Header */
#header {
    position: fixed;
    top: 60px; /* Новая высота Top Bar */
    left: 0;
    width: 100%;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-light);
    transition: var(--transition);
    padding: 5px 0;
}

header.scrolled {
    background: var(--glass);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-light);
    padding: 5px 0;
    box-shadow: var(--shadow-sm);
}

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

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.logo img {
    height: 70px;
    width: auto;
    object-fit: contain;
    transition: var(--transition);
}

header.scrolled .logo img {
    height: 80px;
}

@media (max-width: 768px) {
    .logo img {
        height: 60px;
    }
}
/* Logo Text Styles Removed (using image logo) */

/* Название зафиксировано */

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
    z-index: 1001;
}

.menu-toggle span {
    width: 30px;
    height: 2px;
    background: var(--text-main);
    transition: var(--transition);
    transform-origin: left;
}

.menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg);
}

.menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg);
}

@media (max-width: 768px) {
    .menu-toggle { display: flex; }
    
    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        height: 100vh;
        background: var(--bg-white);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 40px;
        box-shadow: -10px 0 30px rgba(0,0,0,0.05);
        transition: 0.5s cubic-bezier(0.4, 0, 0.2, 1);
        z-index: 1000;
    }

    .nav-links.active {
        right: 0;
    }
}

.top-bar-actions {
    display: flex;
    gap: 24px;
    align-items: center;
}

.top-action-item {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: var(--text-muted);
    font-size: 0.8125rem;
    font-weight: 500;
    transition: color 0.3s ease;
}

.top-action-item i {
    width: 14px;
    height: 14px;
    color: var(--primary);
}

.top-action-item:hover {
    color: var(--primary);
}

.header-shortcuts {
    display: none; /* Полностью скрываем старый блок из шапки */
}

/* Стили перенесены вниз для чистоты структуры */

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

.phone-link {
    text-decoration: none;
    color: var(--text-main);
    font-weight: 700;
    transition: color 0.3s ease;
    white-space: nowrap; /* Запрещаем разбивку номера на две строки */
}

.phone-link:hover {
    color: var(--primary);
}

.btn-outline {
    border: 2px solid var(--primary);
    color: var(--primary);
    background: transparent;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

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

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 28px;
    border-radius: var(--radius-md);
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition);
    cursor: pointer;
    border: none;
    font-size: 1rem;
}

.btn-primary {
    background-color: var(--primary);
    color: white;
    box-shadow: 0 4px 14px 0 rgba(37, 99, 235, 0.39);
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.23);
}

/* Section Headers & Badges */
.section-header {
    margin-bottom: 60px;
}

.section-badge {
    display: table;
    margin: 0 auto 20px auto;
    padding: 8px 16px;
    background: rgba(37, 99, 235, 0.08);
    color: var(--primary);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    border-radius: 100px;
}

.section-title {
    margin-bottom: 24px !important;
}

.section-desc {
    font-size: 1.125rem;
    color: var(--text-muted);
    line-height: 1.7;
    margin-left: auto;
    margin-right: auto;
}

/* Utilities */
.max-w-2xl {
    max-width: 42rem;
}

.mx-auto {
    margin-left: auto;
    margin-right: auto;
}

/* Кнопки теперь имеют единый стиль ховера выше */

/* Hero Section */
.hero {
    min-height: calc(100vh - 130px);
    display: flex;
    align-items: flex-start;
    padding: 160px 0 60px 0; /* Увеличен отступ, чтобы контент не прятался под шапку */
    position: relative;
    overflow: hidden;
    background: var(--bg-light);
}

.hero-content {
    max-width: 680px;
    position: relative;
    z-index: 10;
}

.hero-subtitle {
    display: inline-flex;
    align-items: center;
    padding: 8px 20px;
    background: rgba(37, 99, 235, 0.08);
    color: var(--primary);
    border-radius: 100px;
    font-weight: 700;
    font-size: 0.75rem;
    margin-bottom: 24px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    border: 1px solid rgba(37, 99, 235, 0.15);
    backdrop-filter: blur(10px);
}

.hero-content h1 {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    line-height: 1.05;
    font-weight: 900;
    letter-spacing: -0.03em;
    margin-bottom: 24px;
    color: var(--text-main);
}

.hero-desc {
    font-size: 1.35rem;
    color: var(--text-muted);
    margin-bottom: 48px;
    max-width: 600px;
    line-height: 1.4;
    font-weight: 400;
}

.hero-actions {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    margin-top: 48px;
}

.hero-actions .btn-primary {
    padding: 18px 36px;
    font-size: 1rem;
    box-shadow: 0 15px 35px rgba(37, 99, 235, 0.25);
}

.hero-actions .btn-secondary {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(0, 0, 0, 0.05);
    padding: 18px 36px;
    font-size: 1rem;
    color: var(--text-main);
}

.hero-actions .btn-secondary:hover {
    background: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
}

.hero-visual {
    position: absolute;
    top: 0;
    right: 0;
    width: 60%;
    height: 100%;
    pointer-events: none;
    clip-path: polygon(15% 0, 100% 0, 100% 100%, 0% 100%);
}

.hero-visual::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, var(--bg-light) 0%, transparent 60%);
    z-index: 2;
}

@media (max-width: 1024px) {
    .hero {
        padding: 120px 0 60px;
        text-align: center;
    }
    .hero-subtitle {
        margin-left: auto;
        margin-right: auto;
    }
    .hero-content {
        margin: 0 auto;
    }
    .hero-desc {
        margin-left: auto;
        margin-right: auto;
    }
    .hero-actions {
        justify-content: center;
    }
    .hero-visual {
        position: relative;
        width: 100%;
        height: 450px;
        margin-top: 50px;
        clip-path: none;
    }
    .hero-visual::before {
        width: 100%;
        height: 100px;
        background: linear-gradient(to bottom, var(--bg-light), transparent);
    }
}

.hero-visual img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

/* Stats/Trust */
.stats {
    display: flex;
    gap: 48px;
    margin-top: 60px;
}

.stat-item {
    display: flex;
    flex-direction: column;
}

.stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-main);
}

/* Main Navigation */
.main-nav {
    margin: 0 40px;
}

.nav-list {
    display: flex;
    gap: 20px; /* Оптимальный зазор для 6 пунктов */
    list-style: none;
    align-items: center;
    white-space: nowrap;
}

.nav-link {
    text-decoration: none;
    color: var(--text-main);
    font-size: 0.9375rem;
    font-weight: 600;
    padding: 8px 0;
    position: relative;
    transition: color 0.3s ease;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s ease;
}

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

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

/* Dropdown removed for flat menu */
.nav-item {
    position: relative;
}

@media (max-width: 1400px) {
    .header-shortcuts {
        gap: 15px;
        margin-right: 15px;
    }
    .main-nav {
        margin: 0 15px;
    }
}

@media (max-width: 1300px) {
    .header-shortcuts {
        display: none; /* Скрываем калькулятор и замерщик пораньше, чтобы спасти меню */
    }
}

@media (max-width: 992px) {
    .main-nav {
        display: block; /* Контейнер должен быть активен для работы мобильного меню */
    }
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* Features */

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 32px;
}

.feature-card {
    background: var(--bg-white);
    padding: 40px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-light);
    transition: var(--transition);
}

.feature-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary);
}

.feature-icon {
    width: 64px;
    height: 64px;
    background: rgba(37, 99, 235, 0.1);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 24px;
    color: var(--primary);
}

.feature-card h3 {
    font-size: 1.5rem;
    margin-bottom: 16px;
}

.feature-card p {
    color: var(--text-muted);
}

/* Floating Elements for "Wow" effect */
.blob {
    position: absolute;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(37, 99, 235, 0.1) 0%, rgba(37, 99, 235, 0) 70%);
    filter: blur(80px);
    z-index: 1;
    pointer-events: none;
}

.blob-1 { top: -100px; left: -100px; }
.blob-2 { bottom: -100px; right: -100px; }

/* Utilities */
.section-badge {
    display: table;
    margin: 0 auto 16px auto;
    padding: 6px 14px;
    background: rgba(37, 99, 235, 0.08);
    color: var(--primary);
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    position: relative;
}

/* Solutions */
.solutions {
    background: var(--bg-light);
}

.solutions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 32px;
    margin-top: 40px;
}

.solution-item {
    background: var(--bg-white);
    padding: 32px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-light);
    transition: var(--transition);
}

.solution-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
}

.solution-header i {
    color: var(--primary);
    width: 24px;
    height: 24px;
}

.solution-item h3 {
    font-size: 1.25rem;
    font-weight: 700;
}

.solution-item p {
    color: var(--text-muted);
}

/* Facades */
.facades-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 60px;
}

.facades-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
}

.facade-card {
    background: var(--glass);
    backdrop-filter: blur(12px);
    padding: 40px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-light);
    text-align: center;
    transition: var(--transition);
}

.facade-card:hover {
    background: var(--bg-white);
    border-color: var(--primary);
    box-shadow: var(--shadow-xl);
}

.facade-icon {
    width: 60px;
    height: 60px;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 24px;
}

.facade-card h3 {
    margin-bottom: 16px;
}

.facade-card p {
    color: var(--text-muted);
}

/* Calculator */
.calculator-section {
    background: var(--bg-white);
    position: relative;
    z-index: 2;
}

.calc-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

@media (max-width: 900px) {
    .calc-container { grid-template-columns: 1fr; }
}

.calc-card {
    background: var(--bg-light);
    padding: 40px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-light);
}

.form-group {
    margin-bottom: 32px;
}

.form-group label {
    display: block;
    margin-bottom: 16px;
    font-weight: 600;
    color: var(--text-main);
}

.options-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px;
}

.option-btn {
    padding: 12px;
    background: var(--bg-white);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.option-btn.active, .option-btn:hover {
    border-color: var(--primary);
    background: rgba(37, 99, 235, 0.05);
    color: var(--primary);
}

.calc-summary {
    margin-top: 40px;
    padding-top: 32px;
    border-top: 1px dashed var(--border-light);
}

.price-box {
    margin-bottom: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.price-value {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--primary);
}

.w-full { width: 100%; }

/* Portfolio */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 40px;
}

@media (max-width: 600px) {
    .portfolio-grid { grid-template-columns: 1fr; }
}

.portfolio-item {
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: var(--bg-white);
    border: 1px solid var(--border-light);
    transition: var(--transition);
}

.portfolio-item:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
}

.portfolio-img {
    height: 300px;
    overflow: hidden;
}

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

.portfolio-item:hover .portfolio-img img {
    transform: scale(1.05);
}

.portfolio-content {
    padding: 32px;
}

.portfolio-content h3 {
    margin-bottom: 12px;
}

.portfolio-content p {
    color: var(--text-muted);
}

/* Footer */
.footer {
    background: var(--text-main);
    color: white;
    padding: 80px 0 40px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1.5fr;
    gap: 80px;
    margin-bottom: 60px;
}

@media (max-width: 768px) {
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
}

.footer-brand p {
    margin-top: 24px;
    color: rgba(255, 255, 255, 0.6);
    max-width: 320px;
}

.footer-logo-img {
    height: 64px;
    filter: brightness(0) invert(1);
}

.footer .logo-main,
.footer .logo-sub {
    color: white;
}

.footer h4 {
    font-size: 1.125rem;
    margin-bottom: 24px;
    color: white;
}

.footer-nav, .footer-contacts {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.footer-nav a, .footer-contacts a, .footer-contacts p {
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 12px;
}

.footer-nav a:hover, .footer-contacts a:hover {
    color: white;
    transform: translateX(4px);
}

.footer-contacts i {
    width: 18px;
    height: 18px;
    color: var(--primary);
}

.footer-bottom {
    padding-top: 40px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
    color: rgba(255, 255, 255, 0.4);
    font-size: 0.875rem;
}

/* Quiz Styles */
.quiz-container {
    position: relative;
    min-height: 480px;
    display: flex;
    flex-direction: column;
}

.quiz-progress {
    margin-bottom: 32px;
}

.progress-track {
    width: 100%;
    height: 8px;
    background: rgba(0,0,0,0.05);
    border-radius: 100px;
    margin-bottom: 12px;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: var(--primary);
    border-radius: 100px;
    transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.progress-text {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-muted);
}

.quiz-step {
    display: none;
    animation: fadeIn 0.4s ease-out;
}

.quiz-step.active {
    display: block;
}

.quiz-step h3 {
    font-size: 1.75rem;
    margin-bottom: 32px;
    font-weight: 700;
}

.quiz-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
    margin-bottom: 40px;
}

.quiz-options.vertical {
    grid-template-columns: 1fr;
}

.quiz-option {
    cursor: pointer;
    position: relative;
}

.quiz-option input {
    position: absolute;
    opacity: 0;
}

.option-content {
    background: var(--bg-white);
    border: 2px solid var(--border-light);
    border-radius: var(--radius-md);
    padding: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    transition: var(--transition);
    text-align: center;
    height: 100%;
}

.quiz-option input:checked + .option-content {
    border-color: var(--primary);
    background: rgba(37, 99, 235, 0.05);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.option-content i {
    width: 32px;
    height: 32px;
    color: var(--primary);
}

.option-content span {
    font-weight: 600;
    font-size: 1rem;
    color: var(--text-main);
}

.quiz-navigation {
    margin-top: auto;
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding-top: 32px;
    border-top: 1px dashed var(--border-light);
}

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

.form-input {
    width: 100%;
    padding: 16px 20px;
    background: var(--bg-white);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    font-size: 1rem;
    outline: none;
    transition: var(--transition);
}

.form-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.form-notice {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-align: center;
    margin-top: 12px;
}

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

/* Validation Styles */
.field-error {
    border-color: #ef4444 !important;
    background-color: #fef2f2 !important;
    animation: shake 0.4s cubic-bezier(.36,.07,.19,.97) both;
}

@keyframes shake {
    10%, 90% { transform: translate3d(-1px, 0, 0); }
    20%, 80% { transform: translate3d(2px, 0, 0); }
    30%, 50%, 70% { transform: translate3d(-4px, 0, 0); }
    40%, 60% { transform: translate3d(4px, 0, 0); }
}

@media (max-width: 600px) {
    .quiz-options { grid-template-columns: 1fr; }
    .quiz-step h3 { font-size: 1.5rem; }
}

/* Mobile adjustments for new logo */
@media (max-width: 1024px) {
    .logo-main, .logo-sub { font-size: 1.15rem; }
    .logo img { height: 36px; }
}

@media (max-width: 768px) {
    .header-cta .phone-link {
        display: none; /* Скрываем телефон в хедере на мобилках, он всё равно есть в футере и кнопке */
    }
}

@media (max-width: 480px) {
    .logo-text {
        display: none; /* На самых маленьких экранах оставляем только иконку для чистоты дизайна */
    }
}

/* Top Bar Styles */
/* Стили top-bar консолидированы в конце файла */

.top-bar-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.top-bar-left, .top-bar-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.location-badge {
    display: flex;
    align-items: center;
    gap: 10px;
    padding-right: 20px;
    border-right: 1px solid var(--border-light);
    font-weight: 700;
}

.location-badge i {
    width: 16px;
    height: 16px;
    color: var(--primary);
}

.top-bar-nav {
    display: flex;
    gap: 32px;
}

.top-bar-nav .nav-item {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: var(--text-main);
    font-weight: 600;
    transition: var(--transition);
}

.top-bar-nav .nav-item i {
    width: 16px;
    height: 16px;
    color: var(--primary);
    opacity: 0.7;
}

.top-bar-nav .nav-item:hover {
    color: var(--primary);
}

.top-bar-contact {
    display: flex;
    flex-direction: column;
    text-align: right;
    line-height: 1.2;
}

.phone-number {
    font-weight: 800;
    color: var(--text-main);
    text-decoration: none;
    font-size: 1rem;
    letter-spacing: -0.01em;
}

.work-time {
    font-size: 0.7rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.social-icons {
    border-left: 1px solid var(--border-light);
    padding-left: 20px;
}

.messenger-link {
    text-decoration: none;
    color: var(--text-main);
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 6px;
}

.messenger-link i {
    color: #2563eb;
}

@media (max-width: 1100px) {
    .top-bar-nav { gap: 16px; }
    .top-bar-nav span { font-size: 0.75rem; }
}

@media (max-width: 991px) {
    .top-bar-nav { display: none; }
}

@media (max-width: 768px) {
    .top-bar { display: none; }
}

/* Modal Window styles */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 2000;
    display: none; /* hidden by default */
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal-overlay.active {
    display: flex;
    opacity: 1;
}

.modal-container {
    background: #fff;
    width: 100%;
    max-width: 900px;
    min-height: 500px;
    border-radius: 16px;
    display: flex;
    position: relative;
    box-shadow: 0 20px 50px rgba(0,0,0,0.2);
    overflow: hidden;
    transform: translateY(20px);
    transition: transform 0.3s ease;
}

.modal-overlay.active .modal-container {
    transform: translateY(0);
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: #fff;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    z-index: 10;
    color: var(--text-main);
    transition: all 0.2s;
}

.modal-close:hover {
    background: #f1f1f1;
    transform: scale(1.05);
}

.modal-left {
    flex: 1;
    position: relative;
    background: #f7a96d; /* matching the photo's orange/peach background */
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    overflow: hidden;
}

.modal-left .modal-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 1;
}

.modal-left-content {
    position: relative;
    z-index: 2;
    padding: 40px;
    text-align: center;
}

.modal-main-title {
    color: #fff;
    font-size: 1.6rem;
    font-weight: 800;
    text-shadow: 0 2px 4px rgba(0,0,0,0.1);
    line-height: 1.3;
}

.modal-stats-badge {
    position: relative;
    z-index: 2;
    background: linear-gradient(135deg, #e64a19, #f26627);
    color: white;
    padding: 15px 30px;
    border-top-right-radius: 20px;
    font-size: 1.1rem;
    font-weight: 500;
    width: fit-content;
    box-shadow: 5px -5px 15px rgba(0,0,0,0.1);
}

.modal-stats-badge p {
    margin: 5px 0;
}

.modal-right {
    flex: 1;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
}

.modal-form-wrapper {
    background: #f9f5f0;
    padding: 40px 30px;
    border-radius: 12px;
    width: 100%;
    max-width: 360px;
    text-align: center;
    border: 1px solid #eee;
}

.modal-form-title {
    font-size: 1.1rem;
    font-weight: 500;
    color: var(--text-main);
    margin-bottom: 25px;
    line-height: 1.4;
}

.modal-form-title span {
    color: #cc4400; /* Darker orange for emphasis */
    font-weight: 700;
}

.modal-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.modal-form .form-group input {
    width: 100%;
    padding: 14px 18px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 1rem;
    background: #fff;
    transition: border-color 0.2s;
    box-sizing: border-box;
}

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

.modal-form .btn-block {
    width: 100%;
    padding: 16px;
    font-size: 1.05rem;
    font-weight: 700;
    border-radius: 6px;
    background: var(--primary); /* keeping client style instead of green */
    color: #fff;
    margin-top: 5px;
}

.modal-form .form-policy {
    font-size: 0.75rem;
    color: #999;
    margin-top: 15px;
    line-height: 1.4;
}

.modal-form .form-policy a {
    color: #999;
    text-decoration: underline;
}

@media (max-width: 768px) {
    .modal-container {
        flex-direction: column;
        max-width: 400px;
    }
    .modal-left {
        min-height: 250px;
    }
    .modal-main-title {
        font-size: 1.3rem;
    }
    .modal-right {
        padding: 20px;
    }
}

/* Workflow Section */
.workflow {
    padding: 100px 0;
    background: var(--bg-white);
}

.workflow-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    margin-top: 60px;
    position: relative;
}

.hero-image-card {
    position: absolute;
    top: 50%;
    right: 0;
    transform: translateY(-50%);
    width: 45%;
    height: 70%;
    background-size: cover;
    background-position: center;
    border-radius: 40px 0 0 40px;
    box-shadow: -20px 40px 100px rgba(0,0,0,0.1);
    z-index: 1;
}

@media (max-width: 992px) {
    .hero-image-card {
        position: relative;
        transform: none;
        width: 100%;
        height: 300px;
        margin-top: 40px;
        border-radius: 20px;
    }
}

.workflow-step {
    position: relative;
    padding: 30px;
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    border: 1px solid rgba(0,0,0,0.05);
    transition: all 0.3s ease;
    z-index: 1;
}

.top-bar-actions {
    display: flex;
    gap: 32px;
    align-items: center;
}

.shortcut-item {
    display: flex;
    flex-direction: row; /* Принудительно в один ряд */
    align-items: center;
    gap: 12px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.shortcut-icon {
    width: 38px;
    height: 38px;
    background: #f0f4f8;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    transition: inherit;
}

.shortcut-item:hover .shortcut-icon {
    background: var(--primary);
    color: white;
}

.shortcut-text {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.shortcut-title {
    font-size: 0.875rem;
    font-weight: 800;
    color: var(--text-main);
}

.shortcut-subtitle {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-weight: 500;
}

.top-bar {
    height: 60px;
    display: flex;
    align-items: center;
    background: #ffffff;
    border-bottom: 1px solid var(--border-light);
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1001;
}

.workflow-step:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-light);
}

.workflow-num {
    position: absolute;
    top: -20px;
    right: 20px;
    font-size: 4rem;
    font-weight: 800;
    color: rgba(0,102,255,0.05);
    line-height: 1;
    z-index: -1;
    transition: color 0.3s ease;
}

.workflow-step:hover .workflow-num {
    color: rgba(0, 102, 255, 0.1);
}

.workflow-icon {
    width: 60px;
    height: 60px;
    background: rgba(0, 102, 255, 0.05);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    margin-bottom: 24px;
    transition: all 0.3s ease;
}

.workflow-step:hover .workflow-icon {
    background: var(--primary);
    color: white;
    transform: rotate(-10deg);
}

.workflow-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--text-main);
}


.workflow-text {
    font-size: 0.9375rem;
    color: var(--text-muted);
    line-height: 1.6;
}

@media (max-width: 1024px) {
    .workflow-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .workflow {
        padding: 60px 0;
    }
    .workflow-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    .workflow-num {
        font-size: 3rem;
    }
}

/* ==========================================================================
   INTERACTIVE QUIZ STYLES
   ========================================================================== */
.quiz-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(10px);
    z-index: 3000;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.quiz-modal.active {
    display: flex;
    animation: fadeIn 0.3s ease;
}

.quiz-content {
    background: white;
    width: 100%;
    max-width: 800px;
    border-radius: 32px;
    padding: 50px 40px 40px;
    position: relative;
    box-shadow: 0 50px 100px rgba(0, 0, 0, 0.1);
}

.quiz-header {
    margin-bottom: 30px;
}

.quiz-progress-wrapper {
    height: 8px;
    background: #f0f3f6;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 12px;
}

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

.quiz-steps-info {
    font-size: 14px;
    color: var(--text-light);
    font-weight: 500;
}

.quiz-question-title {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 30px;
    line-height: 1.2;
    color: var(--text-main);
}

.quiz-options-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-bottom: 30px;
}

.quiz-option-card {
    border: 2px solid #f0f3f6;
    border-radius: 20px;
    padding: 24px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    position: relative;
    background: white;
}

.quiz-option-card:hover {
    border-color: var(--primary-light);
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
}

.option-icon {
    width: 56px;
    height: 56px;
    background: #f8fafc;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    color: var(--primary);
}

.option-icon svg {
    width: 28px;
    height: 28px;
}

.option-title {
    font-weight: 700;
    font-size: 17px;
    margin-bottom: 4px;
    color: var(--text-main);
}

.option-desc {
    font-size: 13px;
    color: var(--text-light);
}

.quiz-bonus-badge {
    position: absolute;
    top: -24px;
    left: 50%;
    transform: translateX(-50%);
    background: white;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
    border-radius: 50px;
    padding: 10px 28px;
    display: flex;
    align-items: center;
    gap: 12px;
    white-space: nowrap;
    z-index: 10;
}

.bonus-icon {
    font-size: 20px;
}

.bonus-text {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-main);
}

.bonus-text span {
    color: var(--primary);
    text-transform: uppercase;
}

.quiz-final-step {
    text-align: center;
}

.final-icon {
    font-size: 64px;
    margin-bottom: 24px;
}

.quiz-form {
    max-width: 420px;
    margin: 40px auto 0;
}

.quiz-form .form-group {
    margin-bottom: 16px;
}

.form-input {
    width: 100%;
    padding: 18px 24px;
    border: 2px solid #f0f3f6;
    border-radius: 16px;
    font-size: 16px;
    transition: all 0.3s ease;
    background: #f8fafc;
}

.form-input:focus {
    border-color: var(--primary);
    outline: none;
    background: white;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.btn-block {
    width: 100%;
    padding: 18px;
    font-size: 17px;
}

.form-privacy {
    font-size: 12px;
    color: var(--text-light);
    margin-top: 20px;
    line-height: 1.5;
}

.quiz-success {
    text-align: center;
    padding: 40px 0;
}

.success-icon {
    font-size: 64px;
    margin-bottom: 24px;
}

@media (max-width: 768px) {
    .quiz-modal {
        padding: 0;
    }
    .quiz-content {
        height: 100vh;
        width: 100vw;
        max-width: none;
        border-radius: 0;
        padding: 60px 20px 30px;
        overflow-y: auto;
    }
    .quiz-question-title {
        font-size: 24px;
    }
    .quiz-options-grid {
        grid-template-columns: 1fr;
    }
    .quiz-option-card {
        flex-direction: row;
        text-align: left;
        padding: 16px;
        gap: 16px;
    }
    .option-icon {
        margin-bottom: 0;
        width: 44px;
        height: 44px;
    }
}

/* ==========================================================================
   CALCULATOR BANNER (LEAD MAGNET)
   ========================================================================== */
.calc-banner {
    background: #f8fafc;
    border-radius: 40px;
    padding: 60px;
    margin-top: 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
    position: relative;
    overflow: hidden;
    border: 1px solid #edf2f7;
}

.calc-banner::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 40%;
    height: 100%;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.05) 0%, rgba(37, 99, 235, 0) 100%);
    pointer-events: none;
}

.calc-banner-content {
    flex: 1;
    max-width: 600px;
    position: relative;
    z-index: 2;
}

.calc-banner-content h2 {
    font-size: 42px;
    margin: 20px 0;
    color: var(--text-main);
}

.calc-banner-content p {
    font-size: 18px;
    color: var(--text-light);
    margin-bottom: 30px;
}

.calc-perks {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 35px;
}

.perk-item {
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 500;
    color: var(--text-main);
}

.perk-item i {
    color: var(--primary);
    width: 20px;
}

.calc-banner-visual {
    flex: 0 0 300px;
    display: flex;
    justify-content: center;
    position: relative;
    z-index: 2;
}

.bonus-card {
    background: white;
    padding: 30px;
    border-radius: 28px;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    animation: floating 3s ease-in-out infinite;
    border: 1px solid #f0f4f8;
}

.bonus-icon {
    font-size: 50px;
    margin-bottom: 15px;
}

.bonus-info strong {
    display: block;
    font-size: 18px;
    color: var(--text-main);
}

.bonus-info span {
    color: var(--primary);
    font-weight: 700;
    font-size: 20px;
}

@keyframes floating {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-15px); }
}

@media (max-width: 991px) {
    .calc-banner {
        flex-direction: column;
        padding: 40px 30px;
        text-align: center;
    }
    .calc-banner-content {
        max-width: 100%;
    }
    .calc-perks {
        align-items: center;
    }
    .calc-banner-content h2 {
        font-size: 32px;
    }
    .calc-banner-visual {
        margin-top: 20px;
    }
}

/* ==========================================================================
   CALLBACK WIDGET (FLOATING BUTTON)
   ========================================================================== */
.callback-widget {
    position: fixed;
    right: 30px;
    bottom: 30px;
    z-index: 999;
}

.callback-btn {
    width: 65px;
    height: 65px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-decoration: none;
    position: relative;
    box-shadow: 0 10px 30px rgba(37, 99, 235, 0.4);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.callback-btn .btn-icon {
    position: relative;
    z-index: 5;
    transition: transform 0.3s ease;
}

.callback-btn i {
    width: 28px;
    height: 28px;
}

.callback-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 15px 40px rgba(37, 99, 235, 0.5);
}

.callback-btn:hover .btn-icon {
    transform: rotate(15deg);
}

/* Лейбл при наведении (только десктоп) */
.btn-label {
    position: absolute;
    right: 80px;
    background: white;
    color: var(--text-main);
    padding: 10px 20px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    opacity: 0;
    visibility: hidden;
    transform: translateX(20px);
    transition: all 0.3s ease;
    white-space: nowrap;
    border: 1px solid #edf2f7;
}

.callback-btn:hover .btn-label {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
}

/* Анимация пульсации */
.pulse-ring, .pulse-ring-2 {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--primary);
    border-radius: 50%;
    opacity: 0.6;
    z-index: 1;
    animation: widget-pulse 2s infinite;
}

.pulse-ring-2 {
    animation-delay: 0.5s;
}

@keyframes widget-pulse {
    0% {
        transform: scale(1);
        opacity: 0.6;
    }
    100% {
        transform: scale(1.8);
        opacity: 0;
    }
}

/* Мобильная версия */
@media (max-width: 768px) {
    .callback-widget {
        right: 20px;
        bottom: 20px;
    }
    .callback-btn {
        width: 55px;
        height: 55px;
    }
    .btn-label {
        display: none; /* Скрываем надпись на мобилках */
    }
}




/* Window Calculator Styles */
.calc-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    width: 100%;
    max-width: 900px;
    border-radius: 32px;
    padding: 40px;
    position: relative;
    box-shadow: 0 50px 100px rgba(0, 0, 0, 0.15);
    animation: slideUp 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.calc-close {
    position: absolute;
    top: 20px;
    right: 25px;
    background: none;
    border: none;
    font-size: 32px;
    color: var(--text-muted);
    cursor: pointer;
    transition: color 0.3s;
}

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

.calc-grid {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 50px;
}

.calc-preview {
    background: #f8fafc;
    border-radius: 24px;
    padding: 30px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 480px;
    border: 1px solid rgba(0,0,0,0.03);
}

.window-view {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    position: relative;
}

.window-dimensions {
    margin-top: 20px;
    display: flex;
    gap: 20px;
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--text-muted);
}

.window-dimensions span {
    background: white;
    padding: 4px 12px;
    border-radius: 20px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.calc-total {
    text-align: center;
    padding-top: 20px;
    border-top: 1px dashed #e2e8f0;
}

.total-label {
    display: block;
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-bottom: 5px;
}

.total-price {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--text-main);
    letter-spacing: -0.02em;
}

.total-note {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.calc-title {
    font-size: 1.75rem;
    font-weight: 800;
    margin-bottom: 30px;
    color: var(--text-main);
}

.control-section {
    margin-bottom: 25px;
}

.section-label {
    display: block;
    font-weight: 700;
    font-size: 0.9375rem;
    margin-bottom: 12px;
    color: var(--text-main);
}

.type-selector {
    display: flex;
    gap: 12px;
}

.type-btn {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    border: 2px solid #f1f5f9;
    background: white;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
}

.type-btn i {
    width: 28px;
    height: 28px;
}

.type-btn.active {
    border-color: var(--primary);
    background: rgba(37, 99, 235, 0.05);
    color: var(--primary);
}

.range-group {
    margin-bottom: 20px;
}

.range-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.range-header label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-muted);
}

.range-header input {
    width: 70px;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 4px 8px;
    font-size: 0.875rem;
    font-weight: 700;
    text-align: right;
}

input[type=range] {
    width: 100%;
    accent-color: var(--primary);
}

.profile-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
}

.profile-option {
    padding: 12px 16px;
    border: 2px solid #f1f5f9;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s;
}

.profile-option .p-name {
    display: block;
    font-weight: 700;
    font-size: 0.9375rem;
    color: var(--text-main);
}

.profile-option .p-desc {
    display: block;
    font-size: 0.75rem;
    color: var(--text-muted);
}

.profile-option.active {
    border-color: var(--primary);
    background: rgba(37, 99, 235, 0.05);
}

.btn-calc-submit {
    width: 100%;
    padding: 18px;
    font-weight: 700;
    margin-top: 10px;
}

@media (max-width: 768px) {
    .calc-card {
        padding: 30px 20px;
        max-height: 90vh;
        overflow-y: auto;
    }
    .calc-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    .calc-preview {
        min-height: auto;
    }
    .total-price {
        font-size: 2rem;
    }
}

/* Advanced Calculator Styles (Okonti Style) */
.type-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    margin-bottom: 25px;
}

.type-name {
    font-weight: 800;
    font-size: 1.125rem;
    color: var(--text-main);
}

.type-switcher {
    display: flex;
    align-items: center;
    gap: 20px;
    background: white;
    padding: 8px 20px;
    border-radius: 40px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

.sw-btn {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 5px;
    transition: transform 0.2s;
}

.sw-btn:hover {
    transform: scale(1.2);
}

.type-icon-main {
    color: var(--primary);
}

.range-group-advanced {
    margin-bottom: 25px;
}

.counter-input {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.c-label {
    font-weight: 700;
    color: var(--text-main);
}

.c-controls {
    display: flex;
    align-items: center;
    background: #f1f5f9;
    border-radius: 12px;
    padding: 4px;
}

.c-btn {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    border: none;
    background: white;
    color: var(--primary);
    font-weight: 800;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    transition: all 0.2s;
}

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

.counter-input input {
    width: 60px;
    background: none;
    border: none;
    text-align: center;
    font-weight: 800;
    font-size: 1rem;
    color: var(--text-main);
}

.profile-carousel {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.p-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4px;
}

.p-radio {
    width: 20px;
    height: 20px;
    border: 2px solid #cbd5e1;
    border-radius: 50%;
    position: relative;
    transition: all 0.3s;
}

.profile-option.active .p-radio {
    border-color: var(--primary);
}

.profile-option.active .p-radio::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 10px;
    height: 10px;
    background: var(--primary);
    border-radius: 50%;
}

/* Calculator Additional Elements Styles */
.option-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #f1f5f9;
}

.option-row:last-child {
    border-bottom: none;
}

.opt-label {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--text-main);
}

.opt-select {
    width: 130px;
    padding: 10px 14px;
    border: 2px solid #f1f5f9;
    border-radius: 12px;
    background: white;
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--text-main);
    cursor: pointer;
    transition: all 0.3s;
    outline: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
}

.opt-select:hover {
    border-color: var(--primary);
    background-color: rgba(37, 99, 235, 0.02);
}

.opt-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}
/* Portfolio Gallery Section (Refined to Slider) */
.portfolio-gallery {
    padding: clamp(60px, 10vw, 100px) 0;
    background: var(--bg-white);
    overflow: hidden;
}

.portfolio-layout {
    display: grid;
    grid-template-columns: 350px 1fr;
    gap: 60px;
    align-items: flex-start;
}

.portfolio-info {
    position: sticky;
    top: 160px;
}

.portfolio-title {
    font-size: 2.5rem;
    line-height: 1.1;
    margin-bottom: 24px;
    text-align: left;
}

.portfolio-description {
    color: var(--text-muted);
    font-size: 1.125rem;
    margin-bottom: 32px;
}

.portfolio-features {
    list-style: none;
    padding: 0;
    margin: 0 0 40px 0;
}

.portfolio-features li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 16px;
    font-weight: 500;
}

.portfolio-features i {
    color: var(--primary);
    flex-shrink: 0;
    margin-top: 4px;
}

.slider-container {
    position: relative;
    width: 100%;
}

.portfolio-slider {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none; /* Firefox */
    padding: 10px 0 40px;
}

.portfolio-slider::-webkit-scrollbar {
    display: none; /* Chrome/Safari */
}

.portfolio-slide {
    flex: 0 0 calc(50% - 10px);
    scroll-snap-align: start;
    border-radius: var(--radius-lg);
    overflow: hidden;
    aspect-ratio: 4 / 3;
    background: var(--bg-light);
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.portfolio-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.portfolio-slide:hover {
    transform: scale(1.02);
    box-shadow: var(--shadow-xl);
}

.slider-nav {
    display: flex;
    gap: 12px;
}

.nav-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 1px solid var(--border-light);
    background: white;
    color: var(--text-main);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}

.nav-btn:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
    transform: translateY(-2px);
}

@media (max-width: 1200px) {
    .portfolio-layout {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    .portfolio-info {
        position: static;
        max-width: 700px;
    }
    .portfolio-slide {
        flex: 0 0 calc(45% - 10px);
    }
}

@media (max-width: 768px) {
    .portfolio-slide {
        flex: 0 0 85%;
    }
    .portfolio-title {
        font-size: 2rem;
    }
}
/* Window Solutions & Balcony Focus */
.window-solutions {
    background: var(--bg-white);
}

.solutions-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* Фиксируем 3 колонки для десктопа */
    gap: 32px;
    margin-top: 50px;
}

@media (max-width: 1024px) {
    .solutions-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .solutions-grid {
        grid-template-columns: 1fr;
    }
}

.solution-card {
    background: var(--bg-light);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 40px;
    position: relative;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.solution-card-image {
    padding: 0 !important;
}

/* Выравнивание по высоте только для простых карточек (Окна, Ворота) */
.solution-card:not(.solution-card-image) {
    height: 100%;
}

.solution-card.featured {
    background: var(--bg-white);
    border-color: var(--primary);
    box-shadow: var(--shadow-xl);
    z-index: 2;
}

.solution-badge {
    position: absolute;
    top: 20px;
    right: 20px;
    padding: 4px 12px;
    background: rgba(0,0,0,0.05);
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text-muted);
}

.solution-badge.primary {
    background: var(--primary);
    color: white;
}

.solution-name {
    font-size: 1.75rem;
    font-weight: 800;
    margin-bottom: 8px;
}

.solution-tagline {
    color: var(--primary);
    font-weight: 600;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 20px;
}

.solution-price {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 30px;
    color: var(--text-main);
}

.solution-content {
    display: flex;
    flex-direction: column;
}

.solution-card:not(.solution-card-image) .solution-content {
    flex-grow: 1;
}

.solution-specs {
    list-style: none;
    padding: 0;
    margin-bottom: 30px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.solution-specs li {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.9375rem;
    color: var(--text-main);
}

.solution-specs i {
    width: 18px;
    height: 18px;
    color: var(--primary);
}

.solution-desc {
    font-size: 0.9375rem;
    color: var(--text-muted);
    margin-bottom: 30px;
    flex-grow: 1;
}

/* Balcony Focus */
.balcony-focus {
    background: var(--bg-light);
    overflow: hidden;
}

.balcony-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.balcony-options {
    display: flex;
    flex-direction: column;
    gap: 24px;
    margin-top: 40px;
}

.balcony-option-item {
    display: flex;
    gap: 20px;
}

.option-icon {
    width: 48px;
    height: 48px;
    background: var(--bg-white);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    box-shadow: var(--shadow-sm);
    flex-shrink: 0;
}

.option-text h4 {
    font-size: 1.125rem;
    margin-bottom: 4px;
}

.option-text p {
    font-size: 0.875rem;
    color: var(--text-muted);
}

.balcony-visual {
    position: relative;
}

.comparison-card {
    background: var(--bg-white);
    padding: 12px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    transform: rotate(2deg);
}

.comparison-img {
    position: relative;
    border-radius: var(--radius-md);
    overflow: hidden;
}

.comparison-img img {
    width: 100%;
    display: block;
}

.comparison-label {
    position: absolute;
    bottom: 20px;
    left: 20px;
    background: var(--primary);
    color: white;
    padding: 6px 16px;
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 700;
}

@media (max-width: 1024px) {
    .balcony-grid {
        grid-template-columns: 1fr;
        gap: 50px;
    }
    .comparison-card {
        transform: none;
    }
}

@media (max-width: 768px) {
    .solutions-grid {
        grid-template-columns: 1fr;
    }
    .solution-card.featured {
        transform: none;
    }
}
.solution-benefit {
    font-size: 0.8125rem;
    color: var(--text-muted);
    margin-bottom: 20px;
    font-weight: 500;
}

.brand-note {
    margin-top: 50px;
    padding: 24px;
    background: var(--bg-light);
    border-radius: var(--radius-md);
    text-align: center;
    border: 1px dashed var(--border-light);
}

.brand-note p {
    font-size: 0.875rem;
    color: var(--text-muted);
}

.brand-note strong {
    color: var(--text-main);
}
.works-showcase {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 40px;
}

.showcase-item {
    position: relative;
    border-radius: var(--radius-md);
    overflow: hidden;
    height: 300px;
    box-shadow: var(--shadow-md);
}

.showcase-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.showcase-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 20px;
    background: linear-gradient(to top, rgba(0,0,0,0.6), transparent);
    color: white;
    font-weight: 600;
    font-size: 0.875rem;
    opacity: 0;
    transition: var(--transition);
}

.showcase-item:hover img {
    transform: scale(1.05);
}

.showcase-item:hover .showcase-overlay {
    opacity: 1;
}

@media (max-width: 768px) {
    .works-showcase {
        grid-template-columns: 1fr;
    }
    .showcase-item {
        height: 250px;
    }
}
/* Unified Sections (PVC, Aluminum, Balcony) */
.aluminum-section, .balcony-section {
    padding: 100px 0;
    background: white;
}

.balcony-section {
    background: #f8fafc;
}

.aluminum-options-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
    margin-bottom: 50px;
}

.solution-card-image {
    position: relative;
    background-size: cover;
    background-position: center;
    border: 1px solid var(--border-color);
    overflow: hidden;
    min-height: 580px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    transition: var(--transition);
}

/* Мягкий градиент-подложка снизу (синхронизирован с беседками) */
.solution-card-image::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 70%; 
    background: linear-gradient(to top, rgba(15, 23, 42, 0.85) 0%, rgba(15, 23, 42, 0.3) 50%, transparent 100%);
    z-index: 1;
}

.solution-card-image .solution-content {
    position: relative;
    z-index: 2;
    padding: 35px 30px;
    margin: 20px;
    margin-top: auto;
    
    /* Унификация размера */
    min-height: 380px; 
    display: flex;
    flex-direction: column;
    
    background: linear-gradient(to top, rgba(15, 23, 42, 0.75) 0%, rgba(15, 23, 42, 0.25) 100%);
    border-radius: var(--radius-md);
    border: 1px solid rgba(255, 255, 255, 0.1);
    text-shadow: 0 2px 15px rgba(0, 0, 0, 0.5);
}

/* Прижимаем кнопку к самому низу внутри темного блока */
.solution-card-image .solution-content .btn {
    margin-top: auto;
}

.solution-card-image .solution-name {
    font-size: 2rem;
    font-weight: 800; /* Жирнее */
    margin-bottom: 2px;
    color: #ffffff;
    letter-spacing: -0.01em;
}

.solution-card-image .solution-tagline {
    text-transform: uppercase;
    letter-spacing: 0.3em; /* Еще больше воздуха */
    font-size: 0.65rem;
    font-weight: 700;
    color: #60a5fa;
    margin-bottom: 12px;
    display: block;
    text-shadow: 0 1px 4px rgba(0,0,0,0.8);
}

.solution-card-image .solution-specs {
    list-style: none;
    padding: 0;
    margin-bottom: 24px;
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.solution-card-image .solution-specs li {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #ffffff; /* Белый для контраста */
    font-weight: 500;
    font-size: 0.813rem;
}

.solution-card-image .solution-specs i {
    color: #60a5fa;
    width: 14px;
    height: 14px;
    filter: drop-shadow(0 0 5px rgba(96, 165, 250, 0.5));
}

.solution-card-image .solution-desc {
    display: none; 
}

/* Кнопка в стиле минимализма */
.solution-card-image .btn-primary {
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(8px);
    color: white;
    font-weight: 600;
    padding: 12px 24px;
    font-size: 0.875rem;
    transition: var(--transition);
}

/* Премиальные ярлыки в углу */
.solution-card-image .solution-badge {
    top: 20px;
    right: 20px;
    background: rgba(15, 23, 42, 0.6); /* Темное стекло для контраста с небом */
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #ffffff;
    font-size: 0.625rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    padding: 7px 16px;
    border-radius: 100px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    white-space: nowrap;
    text-shadow: none; /* Убираем тень текста здесь для чистоты */
}

.solution-card-image .btn-primary:hover {
    background: var(--primary-main);
    border-color: var(--primary-main);
    transform: none;
}

.solution-card-image:hover {
    transform: scale(1.01); /* Легкий зум вместо прыжка */
}

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

.balcony-steps-section {
    padding: 80px 0;
    background: #f8fafc;
}

.steps-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    margin-top: 50px;
    margin-bottom: 60px;
}

.step-card {
    background: #ffffff;
    padding: 40px 30px;
    border-radius: 24px;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.03);
    border: 1px solid rgba(15, 23, 42, 0.05);
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.step-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 30px 60px rgba(15, 23, 42, 0.08);
    border-color: rgba(37, 99, 235, 0.2);
}

.step-icon-box {
    width: 64px;
    height: 64px;
    background: rgba(37, 99, 235, 0.05);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 28px;
    color: var(--primary);
    transition: all 0.3s ease;
}

.step-card:hover .step-icon-box {
    background: var(--primary);
    color: white;
    transform: scale(1.1) rotate(-5deg);
}

.step-icon-box i {
    width: 28px;
    height: 28px;
}

.step-card::before {
    content: attr(data-step);
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 5rem;
    font-weight: 900;
    line-height: 1;
    color: rgba(15, 23, 42, 0.03);
    z-index: -1;
    transition: all 0.4s ease;
}

.step-card:hover::before {
    color: rgba(37, 99, 235, 0.06);
    transform: scale(1.2);
}

.step-card h4 {
    margin-bottom: 12px;
    color: var(--text-main);
    font-size: 1.35rem;
    font-weight: 800;
    letter-spacing: -0.01em;
}

.step-card p {
    font-size: 0.875rem;
    color: var(--text-muted);
    line-height: 1.6;
}

.balcony-secondary-gallery {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

@media (max-width: 1024px) {
    .steps-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .balcony-immersive {
        padding: 80px 0;
    }
    .steps-grid {
        grid-template-columns: 1fr;
    }
    .balcony-secondary-gallery {
        grid-template-columns: 1fr;
    }
}

/* Trust & Engineering Section - Premium Redesign */
.trust-section {
    background: #f8fafc;
    padding: 120px 0;
}

.trust-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 32px;
}

.trust-item {
    background: #ffffff;
    padding: 48px 32px;
    border-radius: 24px;
    text-align: center;
    border: 1px solid rgba(0, 0, 0, 0.04);
    box-shadow: 0 4px 20px -10px rgba(0, 0, 0, 0.08);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.trust-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--primary), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.trust-item:hover {
    transform: translateY(-12px);
    box-shadow: 0 30px 50px -12px rgba(0, 0, 0, 0.12);
    border-color: rgba(37, 99, 235, 0.1);
}

.trust-item:hover::before {
    opacity: 1;
}

.trust-icon-box {
    width: 80px;
    height: 80px;
    background: rgba(37, 99, 235, 0.05);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 28px;
    color: var(--primary);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.trust-icon-box i {
    width: 36px;
    height: 36px;
}

.trust-item:hover .trust-icon-box {
    background: var(--primary);
    color: #ffffff;
    transform: scale(1.1) rotate(8deg);
    box-shadow: 0 12px 20px -5px rgba(37, 99, 235, 0.3);
}

.trust-name {
    font-size: 1.35rem;
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--text-main);
}

.trust-text {
    font-size: 0.95rem;
    color: var(--text-muted);
    line-height: 1.6;
}

@media (max-width: 1024px) {
    .trust-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 24px;
    }
    .hero-gazebos {
        padding: 140px 0 80px;
        text-align: center;
    }
    .hero-gazebos .hero-desc {
        margin-left: auto;
        margin-right: auto;
    }
    .hero-gazebos .hero-actions {
        justify-content: center;
    }
}

@media (max-width: 640px) {
    .trust-grid {
        grid-template-columns: 1fr;
    }
    .trust-item {
        padding: 40px 24px;
    }
}

/* Hero Gazebos Specific - Premium Dark Mode */
.hero-gazebos {
    position: relative;
    background: linear-gradient(rgba(15, 23, 42, 0.8), rgba(15, 23, 42, 0.4)), url('assets/besedka/share-photo-13808447460.jpeg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed; /* Parallax effect for premium feel */
    padding: 180px 0 140px;
    color: #ffffff;
    margin-top: -80px;
    display: flex;
    align-items: center;
}

.hero-gazebos .hero-subtitle {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    border-color: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(12px);
}

.hero-gazebos h1 {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    line-height: 1.05;
    font-weight: 900;
    letter-spacing: -0.03em;
    color: #ffffff;
    margin-bottom: 24px;
}

.hero-gazebos .hero-desc {
    color: rgba(255, 255, 255, 0.85);
    font-size: 1.35rem;
    max-width: 650px;
    line-height: 1.5;
}

.hero-gazebos .btn-secondary {
    background: rgba(255, 255, 255, 0.15);
    color: #ffffff;
    border-color: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(12px);
}

.hero-gazebos .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.25);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.showcase-placeholder {
    width: 100%;
    aspect-ratio: 16/10;
    background: var(--bg-soft);
    border: 2px dashed var(--border-color);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    font-size: 0.875rem;
    transition: var(--transition);
    text-align: center;
    padding: 20px;
}

.showcase-item:hover .showcase-placeholder {
    border-color: var(--primary-main);
    color: var(--primary-main);
    background: #ffffff;
    box-shadow: var(--shadow-md);
}
/* --- Premium Cinematic Ribbon Portfolio --- */
.portfolio-gallery-full {
    padding: 100px 0;
    background: var(--bg-white);
    overflow: hidden;
}

.slider-container-full {
    width: 100%;
    overflow: hidden;
    position: relative;
    padding: 40px 0;
}

.portfolio-track-infinite {
    display: flex;
    gap: 30px;
    width: max-content;
    animation: portfolioScroll 60s linear infinite;
    will-change: transform;
}

.portfolio-track-infinite:hover {
    animation-play-state: paused;
}

.portfolio-slide-large {
    flex: 0 0 600px;
    height: 450px;
    border-radius: 24px;
    overflow: hidden;
    cursor: pointer;
    box-shadow: 0 20px 40px rgba(0,0,0,0.08);
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

@media (max-width: 768px) {
    .portfolio-slide-large {
        flex: 0 0 300px;
        height: 250px;
    }
}

.portfolio-slide-large img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s ease;
}

.portfolio-slide-large:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 30px 60px rgba(0,0,0,0.15);
}

.portfolio-slide-large:hover img {
    transform: scale(1.1);
}

@keyframes portfolioScroll {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(calc(-630px * 14)); /* 14 unique slides * (600px width + 30px gap) */
    }
}

/* Lightbox Styling */
.lightbox {
    display: none;
    position: fixed;
    z-index: 9999;
    padding: 60px 20px;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(10px);
    overflow: auto;
    text-align: center;
}

.lightbox-content {
    margin: auto;
    display: block;
    max-width: 90%;
    max-height: 80vh;
    border-radius: 12px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
    transform: scale(0.9);
    animation: zoomIn 0.4s cubic-bezier(0.165, 0.84, 0.44, 1) forwards;
}

@keyframes zoomIn {
    to { transform: scale(1); }
}

.lightbox-close {
    position: absolute;
    top: 30px;
    right: 40px;
    color: #fff;
    font-size: 40px;
    font-weight: 300;
    cursor: pointer;
    transition: 0.3s;
}

.lightbox-close:hover {
    color: var(--primary-light);
    transform: rotate(90deg);
}

#lightbox-caption {
    margin: 20px auto;
    color: #fff;
    font-size: 1.1rem;
    max-width: 700px;
}

/* --- Premium Callback Widget & Pulse Animation --- */
.callback-widget {
    position: fixed;
    bottom: 40px;
    right: 40px;
    z-index: 1000;
}

@media (max-width: 768px) {
    .callback-widget {
        bottom: 20px;
        right: 20px;
    }
}

.widget-btn {
    width: 65px;
    height: 65px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff !important;
    box-shadow: 0 10px 25px rgba(37, 99, 235, 0.4);
    position: relative;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    animation: floatingWidget 3s ease-in-out infinite;
}

/* ==========================================================================
   MOBILE OPTIMIZATION - STEP 1 (Header & Global Fixes)
   ========================================================================== */

@media (max-width: 768px) {
    /* 1. Устранение горизонтального скролла */
    html, body {
        overflow-x: hidden;
        width: 100%;
        position: relative;
    }

    /* 2. Скрытие Top Bar */
    .top-bar {
        display: none !important;
    }

    /* 3. Прижатие шапки к верху */
    #header {
        top: 0 !important;
        padding: 10px 0 !important;
    }

    /* 4. Компактный логотип */
    .logo img {
        height: 40px !important;
    }
    .logo-main, .logo-sub {
        font-size: 1rem !important;
    }
    .logo-text {
        gap: 2px;
    }

    /* 5. Адаптивная кнопка звонка (только иконка) */
    .header-cta {
        gap: 10px !important;
    }
    
    .header-cta .btn-primary {
        width: 44px;
        height: 44px;
        padding: 0 !important;
        border-radius: 50% !important;
        font-size: 0 !important; /* Скрываем текст "Заказать звонок" */
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .header-cta .btn-primary i {
        width: 20px !important;
        height: 20px !important;
        margin: 0 !important;
    }

    /* 6. Меню-бургер */
    .menu-toggle {
        padding: 5px;
    }
}

/* ==========================================================================
   MOBILE OPTIMIZATION - STEP 2 (Typography, Spacing & Menu Fix)
   ========================================================================== */

/* Скрываем мобильный телефон на десктопе */
.header-phone-mobile {
    display: none;
}

@media (max-width: 768px) {
    /* 1. Настройка мобильного телефона в шапке */
    .header-phone-mobile {
        display: flex !important;
        align-items: center;
        gap: 6px;
        color: var(--text-main);
        text-decoration: none;
        font-weight: 800;
        font-size: 0.9375rem;
        white-space: nowrap;
    }
    .header-phone-mobile i {
        width: 16px;
        height: 16px;
        color: var(--primary);
    }

    /* 2. Скрытие кнопки кнопки "Заказать звонок" на мобильных */
    .header-cta .btn-primary {
        display: none !important;
    }

    /* 3. Исправление видимости мобильного меню */
    .nav-links {
        display: flex !important;
        visibility: visible !important;
        padding-top: 50px !important; /* Даем место для логотипа сверху */
        justify-content: flex-start !important; /* Начинаем сверху, а не по центру */
    }

    .nav-links li {
        width: 100%;
        text-align: center;
    }

    /* Дополнительные действия в меню */
    .nav-mobile-actions {
        display: flex !important;
        flex-direction: column;
        gap: 15px;
        width: 100%;
        padding: 40px 30px;
        margin-top: 20px;
        border-top: 1px solid rgba(0,0,0,0.06);
    }

    .nav-mobile-actions .shortcut-item {
        background: #f8fafc;
        padding: 15px;
        border-radius: 16px;
        width: 100%;
        justify-content: flex-start;
    }

    .nav-mobile-actions .shortcut-title {
        font-size: 1rem !important;
    }

    .nav-mobile-actions .shortcut-subtitle {
        display: block !important;
    }

    /* 4. Адаптивная типографика */
    h1, .hero-content h1 {
        font-size: 2.2rem !important;
        line-height: 1.2 !important;
    }
    h2, .section-title {
        font-size: 1.75rem !important;
        margin-bottom: 20px !important;
    }
    .hero-desc {
        font-size: 1.1rem !important;
        margin-bottom: 30px !important;
    }

    /* --- Сетки и карточки (Этап 3) --- */
    .solutions-grid {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }

    .solution-card-image {
        height: 380px !important;
    }

    .solution-content {
        padding: 25px !important;
    }

    .solution-name {
        font-size: 1.6rem !important;
    }

    .section-header {
        margin-bottom: 35px !important;
    }

    .section-title {
        margin-bottom: 15px !important;
    }

    .workflow-step {
        padding: 25px !important;
    }

    /* Оптимизация калькулятора-баннера */
    .calc-banner {
        border-radius: 24px !important;
        padding: 30px 20px !important;
    }

    .calc-banner-content h2 {
        font-size: 28px !important;
        line-height: 1.2 !important;
    }

    /* 5. Настройка отступов секций */
    section {
        padding: 40px 0 !important;
    }
    .section-header {
        margin-bottom: 30px !important;
    }

    /* 6. Исправление Hero визуализации */
    .hero {
        padding-top: 100px !important;
        min-height: auto !important;
    }
    .hero-visual {
        height: 300px !important;
        margin-top: 30px !important;
    }
}

/* Скрываем мобильные действия на десктопе */
.nav-mobile-actions,
.header-phone-mobile {
    display: none;
}

.widget-btn i {
    width: 28px;
    height: 28px;
    transition: transform 0.4s ease;
}

.widget-btn:hover {
    transform: scale(1.1) rotate(15deg);
    box-shadow: 0 15px 35px rgba(37, 99, 235, 0.6);
}

.widget-pulse {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    border-radius: 50%;
    z-index: -1;
}

.widget-pulse::before,
.widget-pulse::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 50%;
    border: 1px solid var(--primary);
    opacity: 0;
    animation: ripplePulse 3.5s linear infinite;
}

.widget-pulse::after {
    animation-delay: 1.75s;
}

@keyframes ripplePulse {
    0% {
        transform: scale(1);
        opacity: 0.4;
    }
    100% {
        transform: scale(2.2);
        opacity: 0;
    }
}

@keyframes floatingWidget {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

/* --- Custom Footer (From Reference) --- */
.footer-custom {
    padding: 80px 0 40px;
    background-color: #0c1222; /* Фиксированный глубокий темный цвет */
    color: #fff;
    border-top: 1px solid rgba(255,255,255,0.05);
}

.footer-content-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1.2fr;
    gap: 60px;
    margin-bottom: 60px;
}

.footer-col-brand .footer-description {
    margin-top: 25px;
    font-size: 0.95rem;
    line-height: 1.6;
    color: rgba(255,255,255,0.7);
    max-width: 320px;
}

.footer-col-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 25px;
    color: #fff;
    text-transform: none;
}

.footer-col-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-col-links li {
    margin-bottom: 15px;
}

.footer-col-links a, 
.contact-link,
.contact-info {
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.3s ease;
}

.footer-col-links a:hover,
.contact-link:hover {
    color: #fff;
}

.footer-col-links i {
    width: 18px;
    height: 18px;
    color: var(--primary);
    opacity: 0.8;
}

.footer-copyright-line {
    padding-top: 30px;
    border-top: 1px solid rgba(255,255,255,0.08);
    text-align: center;
}

.footer-copyright-line p {
    font-size: 0.85rem;
    color: rgba(255,255,255,0.5);
}

@media (max-width: 992px) {
    .footer-content-grid {
        grid-template-columns: 1fr 1fr;
    }
    .footer-col-brand {
        grid-column: span 2;
        margin-bottom: 30px;
    }
}

@media (max-width: 600px) {
    .footer-content-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    .footer-col-brand {
        grid-column: span 1;
    }
}
