html {
    scroll-behavior: smooth;
    scroll-padding-top: 100px; /* Высота навигации + отступ */
}

/* Базовые стили */
body {
    padding-top: 80px;
    background: #fff;
    position: relative;
    overflow-x: hidden;
    font-size: 1.2rem;
}

a{
     color: #d12324;
}
a:hover{
    color: #9c1a1a;
}

section {
    padding: 5rem 0;
    position: relative;
    background: none !important; /* Убрать наследование фона */
}

/* Добавить отступ для якорных ссылок */
section::before {
    content: '';
    display: block;
    height: 80px; /* Высота навигации */
    margin-top: -80px; /* Отрицательный отступ */
    visibility: hidden;
    pointer-events: none;
}

/* Параллакс-фон */
.parallax-bg {
    position: fixed;
    top: -5000px;
    left: 0;
    width: 100%;
    height: 2000%;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='800' height='800' viewBox='0 0 800 800'%3E%3Crect fill='%23FFFFFF' width='800' height='800'/%3E%3Cg fill='none' stroke='%23F4E8E8' stroke-width='1'%3E%3Cpath d='M769 229L1037 260.9M927 880L731 737 520 660 309 538 40 599 295 764 126.5 879.5 40 599-197 493 102 382-31 229 126.5 79.5-69-63'/%3E%3Cpath d='M-31 229L237 261 390 382 603 493 308.5 537.5 101.5 381.5M370 905L295 764'/%3E%3Cpath d='M520 660L578 842 731 737 840 599 603 493 520 660 295 764 309 538 390 382 539 269 769 229 577.5 41.5 370 105 295 -36 126.5 79.5 237 261 102 382 40 599 -69 737 127 880'/%3E%3Cpath d='M520-140L578.5 42.5 731-63M603 493L539 269 237 261 370 105M902 382L539 269M390 382L102 382'/%3E%3Cpath d='M-222 42L126.5 79.5 370 105 539 269 577.5 41.5 927 80 769 229 902 382 603 493 731 737M295-36L577.5 41.5M578 842L295 764M40-201L127 80M102 382L-261 269'/%3E%3C/g%3E%3Cg fill='%23F3D4D4'%3E%3Ccircle cx='769' cy='229' r='5'/%3E%3Ccircle cx='539' cy='269' r='5'/%3E%3Ccircle cx='603' cy='493' r='5'/%3E%3Ccircle cx='731' cy='737' r='5'/%3E%3Ccircle cx='520' cy='660' r='5'/%3E%3Ccircle cx='309' cy='538' r='5'/%3E%3Ccircle cx='295' cy='764' r='5'/%3E%3Ccircle cx='40' cy='599' r='5'/%3E%3Ccircle cx='102' cy='382' r='5'/%3E%3Ccircle cx='127' cy='80' r='5'/%3E%3Ccircle cx='370' cy='105' r='5'/%3E%3Ccircle cx='578' cy='42' r='5'/%3E%3Ccircle cx='237' cy='261' r='5'/%3E%3Ccircle cx='390' cy='382' r='5'/%3E%3C/g%3E%3C/svg%3E");
    background-size: 500px;
    z-index: -1;
    opacity: 0.9;
    will-change: transform;
}

/* Элементы с непрозрачным фоном */
.nobg {
    background-color: white !important;
    position: relative;
    z-index: 1;
}

/* Карточки и секции */
.card,
.shadow {
    background-color: rgba(255, 255, 255, 0.9) !important;
    backdrop-filter: blur(2px);
    transition: transform 0.3s;
    border: none;
    border-radius: 0.5rem;
}

.card:hover {
    transform: translateY(-5px);
}

.btn {
    padding: 0.75rem 1.5rem;
    transition: all 0.3s;
}

.btn-primary {
    background-color: #d12324;
    border-color: #7e1515;
}
.btn-primary:hover {
    background-color: #ab1d1e;
    border-color: #5f1010;
}

.btn-primary:focus{
    background-color: #ab1d1e;
    border-color: #5f1010;
    box-shadow: 0 0 0 0.25rem rgb(255 200 200);
}

/* Навигация */
.navbar {
    background-color: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(5px);
    padding: 1rem 0;
    transition: all 0.3s;
    font-size: 1.2rem;
}

/* Стили для цен */
.card-title {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
}

.list-unstyled li {
    padding: 0.5rem 0;
    border-bottom: 1px solid #eee;
}

.alert-info {
    background: aliceblue;
    border-color: #33717e;
    color: #0c5460;
}

.border-primary {
    border: 2px solid #33717e !important;
}

/* Форма */
.form-check-label a {
    text-decoration: underline;
}

.form-check-input:checked {
    background-color: red;
    border-color: darkred;
}

.form-check-input:focus {
    border-color: darkred;
    box-shadow: 0 0 0 0.25rem rgb(255 200 200);
}

.required::after {
    content: "*";
    color: red;
    margin-left: 3px;
}

.form-control:focus {
    box-shadow: none;
    border-color: #86b7fe;
}

/* Стили для поля с маской */
input[data-inputmask] {
    font-family: monospace;
    letter-spacing: 1.1px;
}

.inputmask-placeholder {
    color: #6c757d !important;
    opacity: 0.6 !important;
}

.has-error .form-control {
    border-color: #dc3545;
    box-shadow: 0 0 0 0.25rem rgba(220,53,69,.25);
}

/* Адаптация */
/* Мобильное меню */
@media (max-width: 991px) {
    .mobile-menu-items {
        flex-direction: column;
        align-items: flex-start!important;
        padding: 1rem 0;
    }

    .navbar-nav {
        margin-bottom: 1rem!important;
    }
    .btn {
        min-width: 12rem;
    }
}

@media (max-width: 768px) {
    body {
        padding-top: 60px;
    }

    .display-4 {
        font-size: 2.5rem;
    }

    .parallax-bg {
        background-size: 400px;
    }

    .display-5 {
        font-size: 2rem;
    }

    .card-body {
        padding: 1.5rem;
    }
}

@media (max-width: 576px) {
    .navbar-brand img {
        height: 30px !important;
    }

    .btn {
        padding: 0.5rem 1rem;
        min-width: 10rem;
    }
}

/* Фикс для резкой смены позиции */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
}

/* Анимация для якорных переходов */
:target {
    animation: highlight 1.5s ease-out;
}

@keyframes highlight {
    0% { background-color: rgba(255,255,210,0.9); }
    100% { background-color: transparent; }
}

.exam_02 {
    padding: 10px 15px;
    border: 2px dashed #33717e;
    border-radius: 10px;
    background: rgba(240,248,288,0.9);
    font-size: 1.4rem;
}
.rj45{
    background-image: url("../img/rj45.jpg");
    background-repeat: no-repeat;
    background-size:contain;
}
.wifi{
    background-image: url("../img/wifi.jpg");
    background-repeat: no-repeat;
    background-size:contain;
    background-position: right bottom;
}
.white-bg{
    background-color: rgba(255,255,255,0.7);
    padding: 10px;
    border-radius: 10px;
}

/* Стили для подвала */
footer {
    font-size: 0.9rem;
}

footer h5 {
    font-size: 1.1rem;
    color: #fff;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    padding-bottom: 0.5rem;
    margin-bottom: 1.5rem;
}

footer .small {
    font-size: 0.85rem;
    opacity: 0.9;
}

footer a:hover {
    opacity: 0.8;
}

/* Адаптация */
@media (max-width: 768px) {
    footer .col-md-6 {
        margin-bottom: 2rem;
    }

    footer .text-md-end {
        text-align: left !important;
    }
}

/* Стили для попапа */
.consent-scroll {
    max-height: 60vh;
    overflow-y: auto;
    padding-right: 1rem;
}

.consent-text {
    font-size: 0.9rem;
    line-height: 1.6;
}

.consent-text ol,
.consent-text ul {
    padding-left: 1.5rem;
    margin: 1rem 0;
}

.consent-text li {
    margin-bottom: 0.5rem;
}

.modal-header {
    background: #f8f9fa;
    border-bottom: 2px solid #e9ecef;
}

.modal-title {
    color: #2c3e50;
    font-weight: 600;
}

/* Адаптация для мобильных */
@media (max-width: 768px) {
    .consent-scroll {
        max-height: 70vh;
    }

    .modal-dialog {
        margin: 0.5rem;
    }
}

/* Стили для политики */
.policy-scroll {
    max-height: 70vh;
    overflow-y: auto;
    padding-right: 1rem;
}

.policy-text {
    font-size: 0.85rem;
    line-height: 1.7;
}

.policy-text h6 {
    color: #2c3e50;
    font-size: 0.95rem;
    margin-top: 1.5rem;
}

.policy-text .fw-semibold {
    color: #495057;
}

/* Нумерованные списки */
.policy-text ol {
    counter-reset: section;
    list-style: none;
    padding-left: 1.5rem;
}

.policy-text ol > li {
    counter-increment: section;
    margin-bottom: 0.8rem;
}

.policy-text ol > li::before {
    content: counters(section, ".") ". ";
    font-weight: 600;
    margin-right: 0.5rem;
}

/* Адаптация */
@media (max-width: 992px) {
    .modal-xl {
        max-width: 95%;
    }

    .policy-scroll {
        max-height: 60vh;
    }
}

#responseModal .modal-content {
    border: none;
    box-shadow: 0 0 20px rgba(0,0,0,0.2);
}

#responseModal .bi {
    animation: scaleIn 0.3s ease-out;
}

@keyframes scaleIn {
    from { transform: scale(0.8); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}