@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;600;700;800&family=Open+Sans:wght@400;600&display=swap');

:root {
    /* Палитра: Глубокий синий + Яркий фиолетовый/Голубой */
    --bg-color: #f8faff;
    --text-main: #1e293b;
    --text-muted: #64748b;
    --primary-gradient: linear-gradient(135deg, #4f46e5 0%, #3b82f6 100%);
    --hover-gradient: linear-gradient(135deg, #4338ca 0%, #2563eb 100%);
    --glass-bg: rgba(255, 255, 255, 0.85);
    --glass-border: rgba(255, 255, 255, 0.5);
    --shadow-soft: 0 10px 40px -10px rgba(0,0,0,0.08);
    --shadow-hover: 0 20px 40px -10px rgba(0,0,0,0.15);
}

* { box-sizing: border-box; }

body {
    font-family: 'Open Sans', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-main);
    margin: 0;
    padding: 0;
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

h1, h2, h3, h4, .logo, .btn {
    font-family: 'Montserrat', sans-serif;
}

/* === ШАПКА (GLASSMORPHISM) === */
header {
    position: sticky;
    top: 20px; /* Отступ сверху, чтобы шапка "парила" */
    margin: 0 auto;
    width: 90%;
    max-width: 1200px;
    height: 70px;

    background: var(--glass-bg);
    backdrop-filter: blur(12px); /* Эффект размытия фона */
    -webkit-backdrop-filter: blur(12px);

    border: 1px solid var(--glass-border);
    border-radius: 16px; /* Сильное скругление */
    box-shadow: 0 4px 20px rgba(0,0,0,0.05);

    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 30px;
    z-index: 1000;
}

.logo a {
    text-decoration: none;
    font-weight: 800;
    font-size: 1.2rem;
    color: #0f172a;
    display: flex;
    align-items: center;
    gap: 10px;
    text-transform: uppercase;
    letter-spacing: -0.5px;
}

nav {
    display: flex;
    gap: 25px;
    align-items: center;
}

nav a.link {
    text-decoration: none;
    color: var(--text-main);
    font-weight: 600;
    font-size: 0.95rem;
    transition: color 0.3s;
}

nav a.link:hover {
    color: #3b82f6;
}

/* === КНОПКИ (Стильные градиенты) === */
.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: 50px; /* Овальные кнопки */
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
}

.btn:active { transform: scale(0.98); }

.btn-primary {
    background: var(--primary-gradient);
    color: white;
}
.btn-primary:hover {
    background: var(--hover-gradient);
    box-shadow: 0 6px 20px rgba(59, 130, 246, 0.5);
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    border: 2px solid #e2e8f0;
    color: var(--text-main);
    box-shadow: none;
}
.btn-outline:hover {
    border-color: #3b82f6;
    color: #3b82f6;
    background: white;
}

/* === HERO SECTION (ГЛАВНЫЙ ЭКРАН) === */
/* Чтобы шапка "парила" над фоном, Hero должен залезать под неё */
.hero-wrapper {
    margin-top: -90px; /* Компенсируем отступ шапки */
    padding-top: 150px; /* Внутренний отступ, чтобы контент не перекрывался */
    padding-bottom: 80px;
    background-color: #0f172a; /* Темный фон на случай если картинки нет */
    background-image:
        linear-gradient(180deg, rgba(15, 23, 42, 0.8) 0%, rgba(15, 23, 42, 1) 100%),
        url('/static/bg.jpg');
    background-size: cover;
    background-position: center;
    color: white;
    text-align: center;
    border-bottom-left-radius: 40px; /* Скругление низа секции */
    border-bottom-right-radius: 40px;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 20px;
    background: linear-gradient(to right, #ffffff, #94a3b8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: #cbd5e1;
    max-width: 700px;
    margin: 0 auto 40px;
}

/* === КОНТЕЙНЕР === */
.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 0;
    flex: 1;
}

/* === КАРТОЧКИ (СОВРЕМЕННЫЙ СТИЛЬ) === */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: -50px; /* Наезжаем на Hero секцию */
}

.feature-card {
    background: white;
    padding: 40px 30px;
    border-radius: 20px;
    box-shadow: var(--shadow-soft);
    transition: all 0.3s ease;
    border: 1px solid rgba(0,0,0,0.03);
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-hover);
}

.icon-box {
    width: 60px;
    height: 60px;
    background: #eff6ff;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    margin-bottom: 20px;
    color: #3b82f6;
}

.feature-card h3 { font-size: 1.3rem; margin: 0 0 10px; font-weight: 700; }
.feature-card p { color: var(--text-muted); font-size: 0.95rem; margin: 0; }

/* === ПОДВАЛ === */
footer {
    background: white;
    padding: 40px 0;
    text-align: center;
    border-top: 1px solid #f1f5f9;
}