:root {
    --bg: #f5f7fb;
    --bg-soft: #ffffff;
    --bg-alt: #eef2f7;
    --card: rgba(255, 255, 255, 0.96);
    --border: rgba(19, 26, 38, 0.08);
    --text: #151922;
    --muted: #5f6877;
    --primary: #c4121a;
    --primary-hover: #e01822;
    --accent: #8f1016;
    --shadow: 0 20px 60px rgba(18, 24, 38, 0.08);
    --shadow-soft: 0 12px 32px rgba(18, 24, 38, 0.06);
    --radius: 22px;
    --container: 1200px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
    background:
        radial-gradient(circle at top left, rgba(196, 18, 26, 0.08), transparent 24%),
        radial-gradient(circle at top right, rgba(196, 18, 26, 0.06), transparent 22%),
        linear-gradient(180deg, #fafbfd 0%, #f3f6fb 100%);
    color: var(--text);
}

img {
    max-width: 100%;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
}

.container {
    width: min(var(--container), calc(100% - 2rem));
    margin: 0 auto;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--border);
    box-shadow: 0 8px 24px rgba(18, 24, 38, 0.04);
}

.nav-wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    min-height: 80px;
}

.brand {
    position: relative;
    z-index: 1101;
}

.brand-title {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--text);
    letter-spacing: 0.04em;
}

.nav-toggle {
    display: none;
    width: 52px;
    height: 52px;
    border: 1px solid var(--border);
    border-radius: 14px;
    background: #fff;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
    box-shadow: var(--shadow-soft);
}

.nav-toggle span {
    width: 20px;
    height: 2px;
    border-radius: 999px;
    background: var(--text);
    transition: 0.2s ease;
}

.nav-toggle.is-open span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.nav-toggle.is-open span:nth-child(2) {
    opacity: 0;
}

.nav-toggle.is-open span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    flex-wrap: wrap;
}

.main-nav > a,
.dropdown-toggle {
    padding: 0.8rem 1rem;
    border-radius: 12px;
    color: var(--text);
    background: transparent;
    border: 0;
    cursor: pointer;
    font: inherit;
    font-weight: 600;
}

.main-nav > a:hover,
.dropdown-toggle:hover,
.main-nav > a.active,
.dropdown.active .dropdown-toggle {
    background: rgba(196, 18, 26, 0.08);
    color: var(--primary);
}

.dropdown {
    position: relative;
}

.dropdown-menu {
    position: absolute;
    top: calc(100% + 0.5rem);
    left: 0;
    min-width: 220px;
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: 16px;
    box-shadow: var(--shadow);
    padding: 0.5rem;
    display: none;
}

.dropdown.open .dropdown-menu {
    display: block;
}

.dropdown-menu a {
    display: block;
    padding: 0.8rem 0.9rem;
    border-radius: 12px;
    color: var(--text);
}

.dropdown-menu a:hover {
    background: rgba(196, 18, 26, 0.08);
    color: var(--primary);
}

.site-main {
    min-height: calc(100vh - 160px);
}

.hero,
.section,
.page-header {
    padding: 4rem 0;
}

.hero {
    padding-top: 2.5rem;
}

.hero-banner {
    margin-bottom: 2rem;
    overflow: hidden;
    border-radius: 28px;
    border: 1px solid rgba(196, 18, 26, 0.14);
    box-shadow: var(--shadow);
    background: #fff;
}

.card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 2rem;
    box-shadow: var(--shadow-soft);
}

.hero-content {
    background: linear-gradient(135deg, rgba(255,255,255,0.98), rgba(250,251,253,0.98));
}

.eyebrow {
    margin: 0 0 0.75rem;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.18em;
    font-size: 0.8rem;
    font-weight: 700;
}

h1, h2, h3, h4 {
    margin-top: 0;
}

h1 {
    font-size: clamp(2.2rem, 5vw, 4.5rem);
    line-height: 1.05;
    margin-bottom: 1rem;
    color: #10141c;
}

h2 {
    font-size: 1.45rem;
    margin-bottom: 0.8rem;
    color: #141923;
}

h3, h4 {
    color: #141923;
}

.lead {
    color: var(--muted);
    font-size: 1.08rem;
    line-height: 1.8;
}

.grid {
    display: grid;
    gap: 1.5rem;
}

.grid-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.stats-grid {
    margin-top: 2rem;
}

.stat-card,
.team-card,
.event-card,
.server-card,
.timeline-item {
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.stat-card:hover,
.team-card:hover,
.event-card:hover,
.server-card:hover,
.timeline-item:hover,
.card:hover {
    transform: translateY(-3px);
    box-shadow: 0 18px 46px rgba(18, 24, 38, 0.10);
    border-color: rgba(196, 18, 26, 0.16);
}

.team-structure-section {
    display: grid;
    gap: 4rem;
}

.team-department-block {
    display: grid;
    gap: 1.75rem;
}

.team-department-head {
    display: grid;
    gap: 0.5rem;
    margin-bottom: 0.25rem;
}

.team-grid {
    align-items: start;
    gap: 1.75rem;
}

.company-card {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 1.5rem;
    max-width: 320px;
}

.team-avatar-wrap {
    display: flex;
    justify-content: center;
    margin-bottom: 0.25rem;
}

.team-avatar-image {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid rgba(196, 18, 26, 0.10);
    box-shadow: 0 12px 28px rgba(18, 24, 38, 0.10);
    background: #ffffff;
}

.team-card-content {
    display: grid;
    gap: 0.55rem;
    text-align: left;
}

.team-card-content h3 {
    margin: 0;
    font-size: 1.7rem;
}

.team-entry {
    margin: 0;
    color: var(--muted);
    font-size: 0.96rem;
}

.role,
.muted,
.event-date,
.timeline-year {
    color: var(--muted);
}

.rule-list,
.list-clean {
    margin: 0;
    padding-left: 1.2rem;
    line-height: 1.8;
}

.list-clean li + li,
.rule-list li + li {
    margin-top: 0.45rem;
}

.timeline {
    display: grid;
    gap: 1.25rem;
}

.meta-row {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 1rem;
    color: var(--muted);
}

.status {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    width: fit-content;
    padding: 0.45rem 0.8rem;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.status.online {
    background: rgba(0, 180, 90, 0.12);
    color: #127a49;
}

.status.offline {
    background: rgba(196, 18, 26, 0.10);
    color: #b4232b;
}

.page-header {
    background: linear-gradient(180deg, rgba(255,255,255,0.7), rgba(245,247,251,0));
}

.legal-page {
    max-width: 900px;
}

.legal-card {
    display: grid;
    gap: 2rem;
}

.legal-block h2 {
    margin-bottom: 0.8rem;
}

.legal-block p {
    margin: 0.35rem 0;
    color: var(--muted);
    line-height: 1.8;
}

.button-row {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 1.5rem;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.95rem 1.4rem;
    border-radius: 14px;
    font-weight: 700;
    transition: 0.2s ease;
}

.btn-primary {
    background: var(--primary);
    color: white;
    box-shadow: 0 10px 24px rgba(196, 18, 26, 0.22);
}

.btn-primary:hover {
    background: var(--primary-hover);
}

.btn-secondary {
    background: #ffffff;
    border: 1px solid var(--border);
    color: var(--text);
}

.btn-secondary:hover {
    background: #f7f9fc;
    border-color: rgba(196, 18, 26, 0.16);
}

.avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    color: white;
    font-weight: 800;
    margin-bottom: 1rem;
    box-shadow: 0 10px 24px rgba(196, 18, 26, 0.18);
}

.site-footer {
    padding: 3rem 0;
    border-top: 1px solid rgba(255,255,255,0.08);
    background: linear-gradient(180deg, #141821 0%, #0f131a 100%);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr 1fr;
    gap: 2rem;
}

.site-footer h3,
.site-footer h4 {
    margin-bottom: 0.8rem;
    color: #ffffff;
}

.site-footer p,
.site-footer li,
.site-footer a {
    color: rgba(255,255,255,0.72);
    line-height: 1.8;
}

.site-footer ul {
    list-style: none;
    padding: 0;
    margin: 0 0 1.25rem 0;
}

@media (max-width: 900px) {
    .grid-2,
    .grid-3,
    .footer-grid {
        grid-template-columns: 1fr;
    }

    .nav-wrap {
        flex-wrap: wrap;
        align-items: center;
        min-height: auto;
        padding: 0.9rem 0;
    }

    .nav-toggle {
        display: inline-flex;
        margin-left: auto;
    }

    .main-nav {
        display: none;
        width: 100%;
        flex-direction: column;
        align-items: stretch;
        gap: 0.5rem;
        padding-top: 1rem;
    }

    .main-nav.is-open {
        display: flex;
    }

    .main-nav > a,
    .dropdown-toggle {
        width: 100%;
        text-align: left;
        background: #ffffff;
        border: 1px solid var(--border);
        box-shadow: var(--shadow-soft);
    }

    .dropdown {
        width: 100%;
    }

    .dropdown-menu {
        position: static;
        margin-top: 0.5rem;
        width: 100%;
        box-shadow: none;
    }

    .company-card {
        max-width: 100%;
    }

    .team-avatar-image {
        width: 120px;
        height: 120px;
    }
}