:root {
    --color-primary: #2a5caa;
    --color-secondary: #1a3e70;
    --color-accent: #ff7a59;
    --color-neutral-100: #f5f7fb;
    --color-neutral-200: #e4e8f2;
    --color-neutral-700: #2d3748;
    --color-neutral-900: #111827;
    --gradient-primary: linear-gradient(135deg, rgba(42, 92, 170, 0.95), rgba(26, 62, 112, 0.85));
    --gradient-accent: linear-gradient(135deg, rgba(255, 122, 89, 0.9), rgba(255, 174, 142, 0.8));
    --shadow-soft: 0 18px 40px rgba(21, 53, 116, 0.12);
    --shadow-medium: 0 24px 60px rgba(17, 24, 39, 0.18);
    --space-2xs: 0.25rem;
    --space-xs: 0.5rem;
    --space-sm: 1rem;
    --space-md: 1.5rem;
    --space-lg: 2.5rem;
    --space-xl: 4rem;
    --space-2xl: 6rem;
    --radius-sm: 12px;
    --radius-md: 18px;
    --radius-lg: 28px;
    --font-heading: 'Inter', 'Segoe UI', sans-serif;
    --font-body: 'Open Sans', 'Segoe UI', sans-serif;
    --font-display: 'Inter', 'Segoe UI', sans-serif;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    line-height: 1.7;
    color: var(--color-neutral-900);
    background: var(--color-neutral-100);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

img {
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
}

a:hover,
button:hover {
    cursor: pointer;
}

button {
    font-family: inherit;
}

main {
    flex: 1;
}

.responsive-img {
    width: 100%;
    max-width: 100%;
    height: auto;
    object-fit: cover;
}

.container {
    width: min(92%, 1200px);
    margin: 0 auto;
}

.container.wide-container {
    width: min(95%, 1320px);
}

.flex {
    display: flex;
    gap: var(--space-md);
}

.grid {
    display: grid;
    gap: var(--space-lg);
}

.grid.featured-grid {
    gap: var(--space-xl);
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

/* Header */
.site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(245, 247, 251, 0.85);
    backdrop-filter: blur(18px);
    border-bottom: 1px solid rgba(42, 92, 170, 0.08);
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-sm) 0;
}

.logo {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: clamp(1.25rem, 2vw, 1.6rem);
    color: var(--color-primary);
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.logo span {
    color: var(--color-accent);
}

.site-nav {
    display: flex;
    align-items: center;
    gap: var(--space-lg);
}

.nav-list {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    list-style: none;
}

.nav-list a {
    font-weight: 600;
    font-size: 0.98rem;
    color: var(--color-neutral-900);
    padding: var(--space-xs) var(--space-sm);
    border-radius: var(--radius-sm);
    transition: all 0.3s ease;
}

.nav-list a:hover,
.nav-list a:focus {
    color: var(--color-primary);
    background: rgba(42, 92, 170, 0.08);
}

.nav-list a.active {
    color: #fff;
    background: var(--color-primary);
    box-shadow: var(--shadow-soft);
}

.nav-toggle {
    display: none;
    background: rgba(42, 92, 170, 0.09);
    border: none;
    padding: var(--space-xs);
    border-radius: var(--radius-sm);
    width: 48px;
    height: 48px;
    align-items: center;
    justify-content: center;
    transition: background 0.3s ease;
}

.nav-toggle span,
.nav-toggle span::before,
.nav-toggle span::after {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--color-neutral-900);
    border-radius: 999px;
    transition: transform 0.3s ease, opacity 0.3s ease, background 0.3s ease;
}

.nav-toggle span::before,
.nav-toggle span::after {
    content: '';
    position: relative;
}

.nav-toggle span::before {
    top: -6px;
}

.nav-toggle span::after {
    top: 6px;
}

.nav-toggle[aria-expanded="true"] span {
    background: transparent;
}

.nav-toggle[aria-expanded="true"] span::before {
    transform: translateY(6px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span::after {
    transform: translateY(-6px) rotate(-45deg);
}

/* Heroes */
.page-hero {
    padding: var(--space-xl) 0;
    background: #fff;
    position: relative;
    overflow: hidden;
}

.page-hero::after {
    content: '';
    position: absolute;
    top: -10%;
    right: -15%;
    width: 320px;
    height: 320px;
    background: rgba(42, 92, 170, 0.08);
    filter: blur(60px);
    border-radius: 50%;
    z-index: 0;
}

.page-hero .container {
    position: relative;
    z-index: 1;
}

.page-hero.homepage-hero {
    background: radial-gradient(circle at top left, rgba(42, 92, 170, 0.25), transparent 55%), radial-gradient(circle at bottom right, rgba(255, 122, 89, 0.15), transparent 45%), #f7f9ff;
    min-height: 90vh;
    display: grid;
    align-items: center;
    padding: var(--space-2xl) 0 var(--space-xl);
}

.page-hero.homepage-hero::after {
    display: none;
}

.page-hero.homepage-hero .hero-card {
    background: rgba(255, 255, 255, 0.72);
    backdrop-filter: blur(16px);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    box-shadow: var(--shadow-medium);
    max-width: 620px;
}

.page-hero.homepage-hero h1 {
    font-family: var(--font-display);
    line-height: 1.1;
    font-size: clamp(2.5rem, 4vw, 3.5rem);
    color: var(--color-neutral-900);
}

.page-hero.homepage-hero p {
    margin: var(--space-md) 0 var(--space-lg);
    font-size: clamp(1rem, 1.2vw, 1.15rem);
    color: rgba(17, 24, 39, 0.84);
}

.homepage-visual {
    position: relative;
    display: grid;
    gap: var(--space-md);
}

.homepage-visual img {
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-soft);
}

.homepage-visual::after {
    content: '';
    position: absolute;
    inset: 12% 25% auto auto;
    width: 120px;
    height: 120px;
    background: var(--gradient-accent);
    border-radius: 50%;
    opacity: 0.55;
    filter: blur(12px);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: clamp(0.85rem, 1vw, 1rem) clamp(1.6rem, 1.8vw, 2rem);
    font-weight: 700;
    letter-spacing: 0.02em;
    border-radius: var(--radius-md);
    border: none;
    transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
    text-decoration: none;
    min-width: 160px;
    font-size: 1rem;
    line-height: 1;
}

.btn.btn-primary {
    background: var(--gradient-primary);
    color: #fff;
    box-shadow: var(--shadow-soft);
}

.btn.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 24px 56px rgba(42, 92, 170, 0.28);
}

.btn.btn-secondary {
    background: rgba(255, 255, 255, 0.85);
    color: var(--color-primary);
    border: 1px solid rgba(42, 92, 170, 0.16);
}

.btn.btn-secondary:hover {
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.95);
}

.btn.btn-ghost {
    background: transparent;
    color: var(--color-primary);
    border: 1px solid rgba(42, 92, 170, 0.28);
}

.btn.btn-ghost:hover {
    background: rgba(42, 92, 170, 0.08);
}

.tag {
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
    padding: var(--space-2xs) var(--space-sm);
    background: rgba(42, 92, 170, 0.12);
    color: var(--color-primary);
    border-radius: 999px;
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

/* Sections */
.page-section {
    padding: var(--space-2xl) 0;
    background: #fff;
}

.page-section.alt-section {
    background: var(--color-neutral-100);
}

.section-header {
    max-width: 720px;
    margin-bottom: var(--space-xl);
}

.section-header.centered {
    margin-left: auto;
    margin-right: auto;
    text-align: center;
}

.section-header .tag {
    margin-bottom: var(--space-sm);
}

.section-header h2 {
    font-family: var(--font-heading);
    font-size: clamp(2rem, 3vw, 2.6rem);
    line-height: 1.2;
    color: var(--color-neutral-900);
    margin-bottom: var(--space-sm);
}

.section-header p {
    color: rgba(17, 24, 39, 0.75);
    font-size: clamp(1rem, 1.1vw, 1.1rem);
}

/* Cards */
.card {
    background: #fff;
    border-radius: var(--radius-lg);
    padding: var(--space-lg);
    box-shadow: var(--shadow-soft);
    position: relative;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.card::before {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: inherit;
    border: 1px solid rgba(42, 92, 170, 0.06);
    pointer-events: none;
}

.course-card h3 {
    font-size: 1.35rem;
    margin-bottom: var(--space-sm);
    color: var(--color-neutral-900);
}

.course-card p {
    margin-bottom: var(--space-md);
    color: rgba(17, 24, 39, 0.75);
}

.course-meta {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-xs) var(--space-sm);
    margin-bottom: var(--space-md);
    font-size: 0.9rem;
    color: rgba(17, 24, 39, 0.65);
}

.course-meta span {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2xs);
    padding: var(--space-2xs) var(--space-xs);
    border-radius: 999px;
    background: rgba(42, 92, 170, 0.08);
}

/* Stats */
.stats-grid {
    display: grid;
    gap: var(--space-lg);
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.stat-card {
    background: rgba(255, 255, 255, 0.95);
    border-radius: var(--radius-lg);
    padding: var(--space-lg);
    text-align: center;
    box-shadow: var(--shadow-soft);
    transition: transform 0.25s ease;
}

.stat-card:hover {
    transform: translateY(-4px);
}

.stat-card h3 {
    font-size: clamp(2.2rem, 3vw, 2.8rem);
    color: var(--color-primary);
    font-family: var(--font-display);
    margin-bottom: var(--space-xs);
}

.stat-card p {
    font-weight: 600;
    color: rgba(17, 24, 39, 0.7);
}

/* List styles */
.check-list {
    display: grid;
    gap: var(--space-sm);
    margin-top: var(--space-md);
}

.check-list li {
    list-style: none;
    padding-left: 32px;
    position: relative;
    font-weight: 600;
    color: rgba(17, 24, 39, 0.8);
}

.check-list li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 8px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--gradient-primary);
    box-shadow: 0 6px 18px rgba(42, 92, 170, 0.25);
}

/* Tables */
.table {
    width: 100%;
    border-collapse: collapse;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    background: #fff;
}

.table thead {
    background: rgba(42, 92, 170, 0.1);
}

.table th,
.table td {
    padding: var(--space-sm);
    text-align: left;
    border-bottom: 1px solid rgba(17, 24, 39, 0.05);
    font-size: 0.98rem;
}

.table tbody tr:nth-child(every) {
    background: #fff;
}

.table tbody tr:hover {
    background: rgba(42, 92, 170, 0.05);
}

/* Forms */
.form-card {
    background: rgba(255, 255, 255, 0.92);
    padding: var(--space-xl);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-medium);
    backdrop-filter: blur(16px);
}

.form {
    display: grid;
    gap: var(--space-md);
}

.form-group {
    display: grid;
    gap: var(--space-xs);
}

.form-group label {
    font-weight: 600;
    color: var(--color-neutral-900);
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: var(--space-sm) var(--space-md);
    border: 1px solid rgba(17, 24, 39, 0.12);
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.92);
    font-size: 1rem;
    transition: border 0.25s ease, box-shadow 0.25s ease;
    min-height: 48px;
}

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

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: rgba(42, 92, 170, 0.45);
    box-shadow: 0 0 0 4px rgba(42, 92, 170, 0.12);
    outline: none;
}

.form-grid {
    display: grid;
    gap: var(--space-md);
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.notice {
    background: rgba(42, 92, 170, 0.08);
    padding: var(--space-sm) var(--space-md);
    border-radius: var(--radius-md);
    color: rgba(17, 24, 39, 0.75);
    font-size: 0.95rem;
}

/* Layout helpers */
.split {
    display: grid;
    gap: var(--space-xl);
}

.split.two-column {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.highlight-box {
    background: rgba(42, 92, 170, 0.1);
    border-radius: var(--radius-lg);
    padding: var(--space-lg);
    box-shadow: var(--shadow-soft);
}

.highlight-box h3 {
    margin-bottom: var(--space-sm);
    color: var(--color-primary);
}

.method-step {
    display: flex;
    gap: var(--space-md);
    padding: var(--space-lg);
    border-radius: var(--radius-lg);
    background: rgba(255, 255, 255, 0.92);
    box-shadow: var(--shadow-soft);
    position: relative;
}

.method-step::after {
    content: attr(data-step);
    position: absolute;
    top: -18px;
    left: 24px;
    width: 48px;
    height: 48px;
    border-radius: 16px;
    background: var(--gradient-primary);
    color: #fff;
    font-weight: 700;
    display: grid;
    place-items: center;
    box-shadow: var(--shadow-soft);
}

/* FAQ */
.faq-accordion {
    display: grid;
    gap: var(--space-md);
}

.faq-item {
    background: #fff;
    border-radius: var(--radius-lg);
    padding: var(--space-lg);
    box-shadow: var(--shadow-soft);
}

.faq-item h3 {
    font-size: 1.2rem;
    margin-bottom: var(--space-sm);
}

.faq-item p {
    color: rgba(17, 24, 39, 0.76);
}

/* Timeline */
.timeline {
    position: relative;
    padding-left: 32px;
}

.timeline::before {
    content: '';
    position: absolute;
    top: 0;
    left: 10px;
    width: 2px;
    height: 100%;
    background: rgba(42, 92, 170, 0.25);
}

.timeline-step {
    position: relative;
    margin-bottom: var(--space-lg);
    padding-left: var(--space-md);
}

.timeline-step::before {
    content: '';
    position: absolute;
    left: -32px;
    top: 6px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--color-primary);
    box-shadow: 0 0 0 6px rgba(42, 92, 170, 0.12);
}

/* Legal pages */
.legal-section {
    margin-bottom: var(--space-xl);
}

.legal-section h2 {
    font-size: 1.8rem;
    margin-bottom: var(--space-sm);
    color: var(--color-primary);
}

.legal-section p,
.legal-section ul {
    color: rgba(17, 24, 39, 0.78);
    margin-bottom: var(--space-sm);
}

.legal-section ul {
    padding-left: 1.2rem;
}

.legal-section li {
    margin-bottom: var(--space-2xs);
}

/* Cookie banner */
.cookie-banner {
    position: fixed;
    bottom: var(--space-sm);
    right: var(--space-sm);
    width: min(420px, calc(100% - 40px));
    background: rgba(17, 24, 39, 0.92);
    color: #fff;
    padding: var(--space-lg);
    border-radius: var(--radius-lg);
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
    display: grid;
    gap: var(--space-sm);
    z-index: 2000;
    backdrop-filter: blur(20px);
}

.cookie-actions {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-sm);
}

.cookie-actions button {
    flex: 1;
    min-width: 140px;
}

.cookie-actions .btn {
    padding: var(--space-sm) var(--space-md);
}

.cookie-banner a {
    color: var(--color-accent);
    text-decoration: underline;
}

/* Footer */
.site-footer {
    background: var(--color-neutral-900);
    color: rgba(255, 255, 255, 0.8);
    padding: var(--space-2xl) 0 var(--space-xl);
    position: relative;
}

.site-footer::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(42, 92, 170, 0.12), transparent 70%);
    pointer-events: none;
}

.footer-grid {
    display: grid;
    gap: var(--space-xl);
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    position: relative;
    z-index: 1;
}

.footer-brand h3 {
    font-family: var(--font-display);
    font-size: 1.6rem;
    margin-bottom: var(--space-sm);
    color: #fff;
    letter-spacing: 0.04em;
}

.footer-brand p {
    max-width: 280px;
    color: rgba(255, 255, 255, 0.72);
}

.footer-links ul {
    list-style: none;
    display: grid;
    gap: var(--space-xs);
}

.footer-links a {
    color: rgba(255, 255, 255, 0.72);
    font-weight: 600;
    transition: color 0.25s ease;
}

.footer-links a:hover {
    color: var(--color-accent);
}

.footer-contacts {
    display: grid;
    gap: var(--space-sm);
}

.footer-contacts a {
    color: rgba(255, 255, 255, 0.9);
    font-weight: 600;
    transition: color 0.25s ease;
}

.footer-contacts a:hover {
    color: var(--color-accent);
}

.footer-hours {
    background: rgba(17, 24, 39, 0.35);
    padding: var(--space-md);
    border-radius: var(--radius-md);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-bottom {
    margin-top: var(--space-xl);
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding-top: var(--space-lg);
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-sm);
    justify-content: space-between;
    color: rgba(255, 255, 255, 0.6);
}

/* Thank you */
.thank-you-card {
    max-width: 620px;
    margin: 0 auto;
    text-align: center;
    background: rgba(255, 255, 255, 0.96);
    padding: var(--space-xl);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-medium);
}

/* Responsive */
@media (max-width: 1024px) {
    .page-hero.homepage-hero {
        grid-template-columns: 1fr;
        gap: var(--space-xl);
    }

    .homepage-visual::after {
        display: none;
    }

    .nav-toggle {
        display: inline-flex;
    }

    .site-nav {
        position: absolute;
        top: 100%;
        right: 0;
        background: rgba(245, 247, 251, 0.95);
        flex-direction: column;
        width: min(320px, 82vw);
        border-radius: var(--radius-lg);
        box-shadow: var(--shadow-soft);
        padding: var(--space-md);
        margin-top: var(--space-xs);
        max-height: 0;
        overflow: hidden;
        opacity: 0;
        transform: translateY(-12px);
        transition: max-height 0.35s ease, opacity 0.3s ease, transform 0.3s ease;
    }

    .site-nav.open {
        max-height: 420px;
        opacity: 1;
        transform: translateY(0);
    }

    .nav-list {
        flex-direction: column;
        width: 100%;
        align-items: flex-start;
    }

    .nav-list a {
        width: 100%;
    }

    .site-footer {
        padding-bottom: var(--space-lg);
    }
}

@media (max-width: 768px) {
    .page-hero {
        padding: var(--space-xl) 0;
    }

    .form-card {
        padding: var(--space-lg);
    }

    .card,
    .faq-item,
    .method-step,
    .highlight-box {
        padding: var(--space-lg);
    }

    .cookie-banner {
        left: var(--space-sm);
        right: var(--space-sm);
        width: auto;
    }
}

@media (max-width: 480px) {
    .btn {
        width: 100%;
    }

    .cookie-actions {
        flex-direction: column;
    }
}