:root {
    --bg: #09111d;
    --bg-soft: rgba(8, 16, 28, 0.76);
    --panel: rgba(16, 26, 43, 0.88);
    --panel-2: rgba(20, 33, 54, 0.92);
    --text: #e8eef7;
    --muted: #b7c3d6;
    --line: rgba(255, 255, 255, 0.10);
    --accent: #66c0ff;
    --accent-2: #1e88e5;
    --gold: #ffd36b;
    --success: #1f8f55;
    --danger: #962d34;
    --shadow: 0 16px 45px rgba(0, 0, 0, 0.35);
    --radius: 18px;
    --radius-sm: 12px;
    --max-width: 1200px;
    --font: Arial, Helvetica, sans-serif;
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
    min-height: 100%;
}

body {
    font-family: var(--font);
    color: var(--text);
    background:
        linear-gradient(rgba(6, 11, 19, 0.58), rgba(6, 11, 19, 0.85)),
        url("img/background.jpg") center top / cover no-repeat fixed;
}

body.modal-open {
    overflow: hidden;
}

a {
    color: var(--accent);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

img {
    max-width: 100%;
    border: 0;
}

.page-overlay {
    position: fixed;
    inset: 0;
    background:
        radial-gradient(circle at top right, rgba(102, 192, 255, 0.12), transparent 30%),
        radial-gradient(circle at left center, rgba(255, 211, 107, 0.08), transparent 30%);
    pointer-events: none;
}

.site-shell {
    position: relative;
    z-index: 1;
    width: min(calc(100% - 32px), var(--max-width));
    margin: 0 auto;
    padding: 28px 0 50px;
}

.hero {
    margin-bottom: 24px;
}

.hero-card {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 28px;
    align-items: center;
    background: var(--bg-soft);
    border: 1px solid var(--line);
    border-radius: 24px;
    padding: 26px;
    box-shadow: var(--shadow);
    backdrop-filter: blur(10px);
}

.hero-logo {
    text-align: center;
}

.hero-logo img {
    width: min(100%, 240px);
    height: auto;
    filter: drop-shadow(0 0 18px rgba(0, 0, 0, 0.45));
}

.eyebrow {
    margin: 0 0 8px;
    color: var(--gold);
    text-transform: uppercase;
    letter-spacing: 0.14em;
    font-size: 0.78rem;
    font-weight: 700;
}

.hero-content h1 {
    margin: 0 0 12px;
    font-size: clamp(2rem, 4vw, 3.5rem);
    line-height: 1;
}

.hero-text {
    margin: 0 0 18px;
    color: var(--muted);
    font-size: 1.02rem;
    line-height: 1.6;
    max-width: 65ch;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 18px;
}

.btn {
    appearance: none;
    border: 0;
    border-radius: 999px;
    padding: 12px 18px;
    font-size: 0.98rem;
    font-weight: 700;
    cursor: pointer;
    transition: 0.2s ease;
    text-align: center;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn:hover {
    transform: translateY(-1px);
    text-decoration: none;
}

.btn-primary {
    background: linear-gradient(180deg, var(--accent), var(--accent-2));
    color: #fff;
    box-shadow: 0 10px 24px rgba(30, 136, 229, 0.28);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text);
    border: 1px solid var(--line);
}

.realm-box {
    display: inline-flex;
    flex-direction: column;
    gap: 4px;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--line);
}

.realm-label {
    color: var(--muted);
    font-size: 0.82rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.content-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 18px;
}

.card {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 22px;
    box-shadow: var(--shadow);
    backdrop-filter: blur(8px);
}

.card h2 {
    margin: 0 0 14px;
    font-size: 1.3rem;
}

.card p,
.card li {
    color: var(--muted);
    line-height: 1.65;
}

.card-feature {
    grid-column: span 6;
}

.card-wide {
    grid-column: span 12;
}

.feature-list,
.steps {
    margin: 0;
    padding-left: 20px;
}

.link-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.quick-link {
    display: block;
    padding: 14px 16px;
    border-radius: 14px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.05);
    color: var(--text);
    font-weight: 700;
}

.quick-link:hover {
    background: rgba(255, 255, 255, 0.08);
    text-decoration: none;
}

.vote-card {
    text-align: center;
}

.footer {
    text-align: center;
    color: var(--muted);
    font-size: 0.9rem;
    margin-top: 24px;
}

.notice {
    padding: 14px 16px;
    border-radius: 14px;
    margin-bottom: 12px;
    font-size: 0.95rem;
    line-height: 1.5;
}

.notice-success {
    background: rgba(31, 143, 85, 0.18);
    border: 1px solid rgba(31, 143, 85, 0.45);
    color: #d9ffe9;
}

.notice-error {
    background: rgba(150, 45, 52, 0.20);
    border: 1px solid rgba(150, 45, 52, 0.45);
    color: #ffe2e5;
}

.highlight-name {
    color: var(--gold);
    font-weight: 700;
}

.modal {
    position: fixed;
    inset: 0;
    display: none;
    z-index: 1000;
}

.modal.is-open {
    display: block;
}

.modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(3, 6, 11, 0.74);
    backdrop-filter: blur(6px);
}

.modal-dialog {
    position: relative;
    width: min(calc(100% - 24px), 760px);
    margin: 4vh auto;
    background: var(--panel-2);
    border: 1px solid var(--line);
    border-radius: 24px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
    overflow: hidden;
}

.modal-header,
.modal-body {
    padding: 22px;
}

.modal-header {
    border-bottom: 1px solid var(--line);
}

.modal-header h2 {
    margin: 0 0 8px;
}

.modal-header p {
    margin: 0;
    color: var(--muted);
}

.modal-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 42px;
    height: 42px;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.08);
    color: var(--text);
    font-size: 1.5rem;
    cursor: pointer;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.form-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-field label {
    font-size: 0.95rem;
    font-weight: 700;
}

.form-field input,
.form-field select {
    width: 100%;
    min-height: 48px;
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,0.12);
    padding: 12px 14px;
    background: rgba(255,255,255,0.08);
    color: var(--text);
    font-size: 1rem;
    outline: none;
}

.form-field input:focus,
.form-field select:focus {
    border-color: rgba(102, 192, 255, 0.75);
    box-shadow: 0 0 0 4px rgba(102, 192, 255, 0.12);
}

.form-actions {
    margin-top: 20px;
    display: flex;
    justify-content: flex-end;
}

.captcha-code {
    color: var(--gold);
    font-weight: 700;
}

@media (max-width: 900px) {
    .hero-card {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-actions {
        justify-content: center;
    }

    .realm-box {
        margin: 0 auto;
    }

    .card-feature {
        grid-column: span 12;
    }
}

@media (max-width: 680px) {
    .site-shell {
        width: min(calc(100% - 18px), var(--max-width));
        padding-top: 14px;
    }

    .hero-card,
    .card,
    .modal-header,
    .modal-body {
        padding: 18px;
    }

    .link-grid,
    .form-grid {
        grid-template-columns: 1fr;
    }

    .btn {
        width: 100%;
    }

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

    .modal-dialog {
        width: calc(100% - 12px);
        margin: 2vh auto;
    }
}