/* ===== ГЛОБАЛЬНЫЕ СБРОСЫ И БАЗОВЫЕ СТИЛИ ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* ===== CSS ПЕРЕМЕННЫЕ ===== */
:root {
    /* Цветовая палитра */
    --primary-color: #3B5C76;
    --secondary-color: #15212B;
    --accent-color: #1b3242;
    --red-accent: #ff3333;
    --white: #ffffff;
    --text-color: #000;
    --gray-text: #555;
    --light-gray: #f5f5f5;
    --gray: #888;
    --dark-gray: #555;

    /* Специфичные цвета блоков */
    --cooperation-bg: #ffffff;
    --cooperation-orange: #e44e3b;
    --cooperation-orange-light: #f9d8d4;
    --cooperation-orange-lighter: #f8e9e7;

    /* Размеры и отступы */
    --content-width: 1400px;
    --card-width: 350px;

    /* Тени */
    --card-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    --card-shadow-hover: 0 10px 25px rgba(0, 0, 0, 0.15);
    --modal-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    --table-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
    --coordination-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    --coordination-shadow-hover: 0 20px 50px rgba(0, 0, 0, 0.15);

    /* Границы */
    --table-border: #e0e0e0;
    --input-border: #ddd;
    --input-focus: #ff3333;

    /* Фоны */
    --table-bg-even: #f8f8f8;
    --table-bg-odd: #ffffff;

    /* Анимации */
    --transition: all 0.3s ease;
    --transition-slow: all 0.5s ease;
}

/* ===== БАЗОВЫЕ СТИЛИ ===== */
body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
}

/* ===== ТИПОГРАФИЯ ===== */
.red-text {
    color: var(--red-accent);
}

.accent-text {
    color: var(--cooperation-orange);
}

/* ===== КОМПОНЕНТЫ ===== */

/* Кнопки */
.btn {
    padding: 15px 20px;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight:  Normal;
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
    color: var(--white);
    position: relative;
    overflow: hidden;
    
}

/* Эффект блеска для всех кнопок */
.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.4),
        transparent
    );
    transition: left 0.7s ease;
}

.btn:hover::before {
    left: 100%;
}

/* Эффект нажатия */
.btn:active {
    transform: translateY(2px) scale(0.98);
    transition: transform 0.1s ease;
}

.btn-filled {
    background-color: var(--red-accent);
    font-weight: bold;
    
}
.btn-outline {
    background-color: var(--red-accent);
    border: 3px solid #cc0000;
    color: var(--white);
    font-weight: bold;
}

.btn-filled:hover {
    background-color: #cc0000; 
    transform: translateY(-2px);
}

.btn-outline:hover {
    background-color: #cc0000; 
    border-color: #cc0000;
    transform: translateY(-2px);
}


.btn-margin {
    margin-bottom: 25px;
}

/* Модальные окна */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    overflow: auto;
}

.modal-content {
    background-color: var(--white);
    padding: 25px;
    border-radius: 8px;
    width: 90%;
    max-width: 500px;
    position: relative;
    box-shadow: var(--modal-shadow);
    margin: 150px auto;
}

.close-button {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 24px;
    cursor: pointer;
    color: var(--gray-text);
    transition: color var(--transition);
}

.close-button:hover {
    color: var(--red-accent);
}

/* Формы */
.form-group {
    margin-bottom: 18px;
}

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

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--input-border);
    border-radius: 4px;
    font-size: 15px;
    transition: border var(--transition);
}

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

.form-group textarea {
    height: 90px;
    resize: vertical;
}

.submit-button {
    background-color: var(--red-accent);
    color: var(--white);
    border: none;
    padding: 12px 20px;
    width: 100%;
    cursor: pointer;
    font-size: 15px;
    transition: background-color var(--transition);
    border-radius: 4px;
    font-weight: bold;
    text-transform: uppercase;
}

.submit-button:hover {
    background-color: #e62e2e;
}

/* ===== ЛАЙАУТ И СЕТКА ===== */
.content-container {
    max-width: var(--content-width);
    margin: 0 auto;
    padding: 0 20px;
}

/* Секции */
.cooperation-section {
    width: 100%;
    padding: 80px 0;
    background-color: var(--cooperation-bg);
}

.tariffs-section {
    width: 100%;
    padding: 60px 0;
    background-color: var(--white);
}

/* Новые стили для блока ремонта */
.repair-block {
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    position: relative;
    padding: 80px 0;
    margin: 60px 0;
}

.repair-block::before,
.repair-block::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(0,0,0,0.1) 20%, 
        rgba(0,0,0,0.2) 50%, 
        rgba(0,0,0,0.1) 80%, 
        transparent 100%);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.repair-block::before {
    top: 0;
}

.repair-block::after {
    bottom: 0;
}

.repair-block .content-wrapper {
    max-width: var(--content-width);
    margin: 0 auto;
    padding: 0 20px;
    position: relative;
    z-index: 1;
}

/* ===== АНИМАЦИИ ===== */

/* Базовые анимации */
@keyframes slideFromTop {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideFromBottom {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideFromLeft {
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

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

@keyframes fadeInDown {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

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

/* Специфичные анимации блоков */
@keyframes slideInFromBottom {
    0% {
        opacity: 0;
        transform: translateY(50px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes borderAppear {
    0% {
        opacity: 0;
        transform: scale(0.8);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes titleAppear {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes iconAppear {
    to {
        opacity: 1;
        transform: scale(1) rotate(0);
    }
}

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

@keyframes subtitleAppear {
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes listItemAppear {
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes buttonAppear {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes backgroundSlideFromRight {
    from {
        background-position: calc(100% + 500px) center;
        opacity: 0;
    }
    to {
        background-position: calc(100% - 70px) center;
        opacity: 1;
    }
}

@keyframes slideUpWithImage {
    0% {
        opacity: 0;
        transform: translateY(100px) scale(0.9);
    }
    50% {
        opacity: 0.5;
        transform: translateY(30px) scale(0.95);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes slideUpSimple {
    0% {
        opacity: 0;
        transform: translateY(80px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes imageFadeIn {
    0% {
        opacity: 0;
        transform: scale(1.1);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

/* ===== АНИМАЦИИ ПРИ СКРОЛЛЕ ===== */

/* Базовые стили для анимаций при скролле */
.scroll-animation-element {
    opacity: 0;
    animation-fill-mode: both;
}

.scroll-animation-element.animate-on-scroll {
    opacity: 1;
}

/* Отключаем автоматические анимации для блоков со скроллом */
.advantages-block .advantages-title,
.advantages-block .advantages-subtitle,
.advantages-block .advantages-border,
.advantages-block .advantage-item,
.auctions-block .block-title,
.auctions-block .auction-card,
.landing-block .red-frame,
.landing-block .title-container h1,
.landing-block .search-icon,
.landing-block .right-section h4,
.landing-block .benefits-list li,
.landing-block .cta-button,
.cooperation-section .section-title,
.cooperation-section .service-card,
.tariffs-section h1,
.tariffs-section .tariffs-table,
.repair-block .red-border-container,
.repair-block .title,
.repair-block .subtitle,
/* .repair-block .icon-container, */
.repair-block .services-columns,
.repair-block .special-offer,
.faq-section .faq-icon,
.faq-section .faq-title,
.faq-section .faq-subtitle,
.faq-section .phone-button,
.faq-section .messengers-icons,
.faq-section .faq-item {
    animation: none !important;
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease-out;
}

/* ИСКЛЮЧАЕМ РАМКИ ТАРИФОВ ИЗ СИСТЕМЫ АНИМАЦИЙ */
.tariffs-section .tariff-frame {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
}

/* Активация анимаций при скролле */
.scroll-animation-block.animated .scroll-animation-element {
    opacity: 1;
    transform: translateY(0);
}

/* Специфичные трансформации для разных типов анимаций */
.scroll-animation-element.slideFromTop {
    transform: translateY(-50px);
}

.scroll-animation-element.slideFromBottom {
    transform: translateY(50px);
}

.scroll-animation-element.fadeInUp {
    transform: translateY(30px);
}

.scroll-animation-element.slideInFromBottom {
    transform: translateY(50px);
}

.scroll-animation-element.borderAppear {
    transform: scale(0.8);
    opacity: 0;
}

.scroll-animation-element.titleAppear {
    transform: translateY(-50px);
}

.scroll-animation-element.iconAppear {
    transform: scale(0.5) rotate(-180deg);
    opacity: 0;
}

.scroll-animation-element.frameAppear {
    transform: scale(0);
    opacity: 0;
}

.scroll-animation-element.subtitleAppear {
    transform: translateX(-50px);
    opacity: 0;
}

.scroll-animation-element.listItemAppear {
    transform: translateX(50px);
    opacity: 0;
}

.scroll-animation-element.buttonAppear {
    transform: translateY(30px);
    opacity: 0;
}

.scroll-animation-element.depthAppear {
    transform: translateZ(-100px);
    opacity: 0;
}

.scroll-animation-element.depthIconAppear {
    transform: scale(0.5);
    opacity: 0;
}

.scroll-animation-element.slideUpWithImage {
    transform: translateY(100px) scale(0.9);
    opacity: 0;
}

/* Анимация для фона блока ремонта */
.repair-block {
    background-position: calc(100% - 70px) center;
    opacity: 1;
}

.scroll-animation-block:not(.animated) .repair-block {
    background-position: calc(100% + 500px) center;
    opacity: 0;
}

.scroll-animation-block.animated .repair-block {
    animation: backgroundSlideFromRight 1.5s ease-out forwards;
}

/* ===== АДАПТИВНОСТЬ ===== */

@media (max-width: 1200px) {
    .content-container {
        padding: 0 15px;
    }
}

@media (max-width: 992px) {
    :root {
        --card-width: 100%;
    }
}

@media (max-width: 768px) {
    :root {
        --content-width: 100%;
    }
    
    .image-card {
        animation: slideUpSimple 0.8s ease-out forwards;
        transform: translateY(60px);
    }
}

@media (max-width: 576px) {
    :root {
        --card-shadow-hover: 0 8px 20px rgba(0, 0, 0, 0.12);
    }
    
    .content-container {
        padding: 0 10px;
    }
}

@media (max-width: 768px) {
    :root {
        --content-width: 100%;
    }
    
    .image-card {
        animation: slideUpSimple 0.8s ease-out forwards;
        transform: translateY(60px);
    }
    
    /* Адаптивность для блока ремонта */
    .repair-block {
        width: 100%;
        margin-left: 0;
        padding: 60px 0;
        margin: 40px 0;
    }
    
    .repair-block .content-wrapper {
        padding: 0 15px;
    }
}

@media (max-width: 576px) {
    :root {
        --card-shadow-hover: 0 8px 20px rgba(0, 0, 0, 0.12);
    }
    
    .content-container {
        padding: 0 10px;
    }
    
    /* Адаптивность для блока ремонта на маленьких экранах */
    .repair-block {
        padding: 40px 0;
        margin: 30px 0;
    }
}