/* Базовые настройки и шрифты */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    color: #333;
    background-color: #fafafa;
    line-height: 1.6;
}

.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 20px;
}

/* === ГЛАВНЫЙ ЭКРАН (ГРАДИЕНТ) === */
.hero {
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    
    /* Тот самый крутой анимированный градиент! */
    background: linear-gradient(-45deg, #ff9a9e, #fecfef, #a1c4fd, #c2e9fb);
    background-size: 400% 400%;
    animation: gradientBG 12s ease infinite;

    /* ЕСЛИ ЗАХОЧЕШЬ ПОСТАВИТЬ СВОЮ КАРТИНКУ ВМЕСТО ГРАДИЕНТА,
       удали 3 строчки выше и раскомментируй код ниже: */
    
    /* background-image: url('твоя-картинка.jpg');
    background-size: cover;
    background-position: center; 
    */
}

/* Анимация для градиента */
@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.main-title {
    color: white;
    font-size: 4rem;
    font-weight: 900;
    margin-bottom: 30px;
    text-shadow: 0 4px 15px rgba(0,0,0,0.1);
    letter-spacing: -1px;
}

/* === КНОПКИ === */
.btn {
    padding: 18px 45px;
    font-size: 1.2rem;
    font-weight: 700;
    border: none;
    border-radius: 50px; /* Сильное закругление */
    cursor: pointer;
    transition: all 0.3s ease; /* Плавность не колхозная */
    box-shadow: 0 10px 20px rgba(37, 99, 235, 0.2);
}

.blue-btn {
    background-color: #2563eb;
    color: white;
}

.blue-btn:hover {
    background-color: #1d4ed8;
    transform: translateY(-3px); /* Кнопка чуть приподнимается */
    box-shadow: 0 15px 25px rgba(37, 99, 235, 0.3);
}

.blue-btn:active {
    transform: translateY(1px); /* Эффект нажатия */
}

/* === СЕКЦИИ === */
.section {
    padding: 100px 0;
    text-align: center;
}

.bg-light {
    background-color: #f1f5f9;
}

h2 {
    font-size: 2.5rem;
    margin-bottom: 20px;
    color: #1e293b;
}

.about-text {
    font-size: 1.2rem;
    color: #475569;
    max-width: 700px;
    margin: 0 auto;
}

/* === РАБОТЫ === */
.works-grid {
    display: flex;
    flex-direction: column;
    gap: 40px;
    margin-top: 50px;
}

.work-card {
    background: white;
    border-radius: 20px;
    padding: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    transition: transform 0.3s ease;
}

.work-card:hover {
    transform: translateY(-5px);
}

.work-image {
    width: 100%;
    max-width: 600px;
    border-radius: 15px;
    margin-bottom: 20px;
    object-fit: cover;
}

.work-title {
    font-size: 1.8rem;
    color: #2563eb;
    cursor: pointer;
    display: inline-block;
    transition: color 0.2s;
}

.work-title:hover {
    color: #1e40af;
    text-decoration: underline;
}

.work-desc {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease-out; /* Плавное открытие описания */
    margin-top: 10px;
    color: #64748b;
    font-size: 1.1rem;
}

.work-desc.show {
    max-height: 500px; /* Достаточно места для текста */
}

/* === ПОДВАЛ И МОДАЛКА === */
.footer {
    padding: 60px 0;
    text-align: center;
    background-color: #fff;
}

.modal-overlay {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 1;
    transition: opacity 0.3s ease;
}

.modal-overlay.hidden {
    opacity: 0;
    pointer-events: none; /* Чтобы нельзя было кликать, когда скрыто */
}

.modal-content {
    background: white;
    padding: 40px;
    border-radius: 25px;
    text-align: center;
    position: relative;
    transform: scale(1);
    transition: transform 0.3s ease;
    box-shadow: 0 25px 50px rgba(0,0,0,0.2);
}

.modal-overlay.hidden .modal-content {
    transform: scale(0.9);
}

.close-modal {
    position: absolute;
    top: 15px; right: 20px;
    font-size: 1.5rem;
    background: none; border: none; cursor: pointer;
    color: #94a3b8;
}

.contact-links {
    margin-top: 30px;
    display: flex;
    gap: 20px;
    justify-content: center;
}

.contact-btn {
    text-decoration: none;
    padding: 12px 30px;
    border-radius: 12px;
    color: white;
    font-weight: 700;
    transition: transform 0.2s;
}

.contact-btn:hover { transform: scale(1.05); }
.email-btn { background: #ea4335; }
.tg-btn { background: #0088cc; }

/* Адаптация под телефоны */
@media (max-width: 768px) {
    .main-title { font-size: 2.5rem; }
    .contact-links { flex-direction: column; }
}