/* Verdant Bay RP website. Same design tokens as the fm_* in-game UIs (fm_loadscreen, fm_banking). */
:root {
    --accent: #3ddc97;
    --accent-2: #8ff5c8;
    --accent-deep: #138a5c;
    --accent-ink: #062014;
    --bg: #05080b;
    --bg-2: #080c10;
    --surface: #0c1116;
    --surface-2: #111820;
    --line: rgba(255, 255, 255, 0.08);
    --line-2: rgba(255, 255, 255, 0.14);
    --text: #e8ebf0;
    --text-2: #b9c1cd;
    --muted: #8a93a3;
    --danger: #ff6b6b;
    --warn: #ffc857;
    --radius: 14px;
    --radius-lg: 20px;
    --max: 1180px;
    --gutter: clamp(16px, 4vw, 32px);
    --display: 'Montserrat', 'Inter', system-ui, sans-serif;
    --body: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
    --mono: 'JetBrains Mono', ui-monospace, Consolas, monospace;
    color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
    margin: 0; min-height: 100vh; display: flex; flex-direction: column;
    background: var(--bg); color: var(--text);
    font: 400 16px/1.6 var(--body);
    -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
main { flex: 1; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
::selection { background: var(--accent); color: var(--accent-ink); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.muted { color: var(--muted); }
.mono { font-family: var(--mono); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ------------------------------------------------------------------ nav */
.nav {
    position: fixed; inset: 0 0 auto; z-index: 50;
    transition: background .3s, border-color .3s, backdrop-filter .3s;
    border-bottom: 1px solid transparent;
}
.nav.solid, .nav.open {
    background: rgba(5, 8, 11, 0.95); border-color: var(--line);
}
.nav-inner { height: 72px; display: flex; align-items: center; gap: 28px; }
.brand-link { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.brand-link img { width: 40px; height: 40px; filter: drop-shadow(0 4px 14px rgba(61, 220, 151, .25)); }
.brand-link span { font: 900 17px/1 var(--display); letter-spacing: .02em; text-transform: uppercase; }
.brand-link span b { color: var(--accent); font-weight: 900; }
.nav-links { display: flex; gap: 4px; margin-left: auto; }
.nav-links a {
    padding: 8px 14px; border-radius: 999px; font-size: 14.5px; font-weight: 500; color: var(--text-2);
    transition: color .2s, background .2s;
}
.nav-links a:hover { color: var(--text); background: rgba(255, 255, 255, .05); }
.nav-links a[aria-current="page"] { color: var(--accent); background: rgba(61, 220, 151, .1); }
.nav-cta { display: flex; gap: 10px; }
.nav-toggle {
    display: none; margin-left: auto; width: 44px; height: 44px; border-radius: 12px;
    border: 1px solid var(--line-2); background: transparent; cursor: pointer; place-items: center;
}
.nav-toggle svg { width: 22px; height: 22px; }

@media (max-width: 920px) {
    .nav-toggle { display: grid; }
    .nav-links, .nav-cta { display: none; }
    .nav.open .nav-inner { flex-wrap: wrap; height: auto; padding-top: 14px; padding-bottom: 18px; row-gap: 12px; }
    .nav.open .brand-link { height: 44px; }
    .nav.open .nav-links { display: flex; flex-direction: column; width: 100%; order: 3; margin: 0; }
    .nav.open .nav-links a { padding: 12px 14px; font-size: 16px; border-radius: 12px; }
    .nav.open .nav-cta { display: flex; width: 100%; order: 4; }
    .nav.open .nav-cta .btn { flex: 1; }
}

/* ------------------------------------------------------------------ buttons */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 9px;
    height: 44px; padding: 0 20px; border-radius: 999px; border: 1px solid transparent;
    font-weight: 600; font-size: 15px; white-space: nowrap; cursor: pointer;
    transition: transform .15s, background .2s, border-color .2s, box-shadow .2s, color .2s;
}
.btn svg { width: 18px; height: 18px; flex-shrink: 0; }
.btn:active { transform: translateY(1px); }
.btn-primary {
    background: linear-gradient(135deg, var(--accent-2), var(--accent) 45%, #2fc184);
    color: var(--accent-ink); box-shadow: 0 8px 28px -8px rgba(61, 220, 151, .55), inset 0 1px 0 rgba(255, 255, 255, .35);
}
.btn-primary:hover { box-shadow: 0 10px 34px -6px rgba(61, 220, 151, .7), inset 0 1px 0 rgba(255, 255, 255, .35); }
.btn-ghost { border-color: var(--line-2); background: rgba(255, 255, 255, .03); }
.btn-ghost:hover { border-color: rgba(61, 220, 151, .5); background: rgba(61, 220, 151, .06); }
.btn-discord { background: #5865f2; color: #fff; }
.btn-discord:hover { background: #4752c4; }
.btn-sm { height: 38px; padding: 0 16px; font-size: 14px; }
.btn-lg { height: 54px; padding: 0 28px; font-size: 16px; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }

/* ------------------------------------------------------------------ hero */
.hero { position: relative; min-height: 100svh; display: flex; align-items: center; overflow: hidden; isolation: isolate; }
.hero-bg { position: absolute; inset: 0; z-index: -2; }
.hero-bg .slide {
    position: absolute; inset: -6%; background-size: cover; background-position: center;
    opacity: 0; transition: opacity 2s ease; transform: scale(1.06); backface-visibility: hidden;
}
.hero-bg .slide.on { opacity: 1; animation: pan 26s ease-in-out infinite alternate; }
.hero.paused .hero-bg .slide, .hero.paused .hero-logo, .hero.paused .pill .dot { animation-play-state: paused; }
@keyframes pan { from { transform: scale(1.06) translate3d(-1.5%, .5%, 0); } to { transform: scale(1.12) translate3d(1.5%, -1%, 0); } }
.hero::before {
    content: ''; position: absolute; inset: 0; z-index: -1;
    background:
        linear-gradient(90deg, rgba(5, 8, 11, .95) 0%, rgba(5, 8, 11, .7) 42%, rgba(5, 8, 11, .2) 75%, rgba(5, 8, 11, .5) 100%),
        linear-gradient(0deg, var(--bg) 0%, rgba(5, 8, 11, 0) 30%),
        radial-gradient(ellipse at 15% 35%, rgba(61, 220, 151, .18), transparent 55%);
}
.hero-inner { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, .75fr); gap: 56px; align-items: center; padding-top: 120px; padding-bottom: 96px; }
.hero-logo { width: clamp(110px, 16vw, 168px); filter: drop-shadow(0 18px 40px rgba(61, 220, 151, .3)); animation: float 7s ease-in-out infinite; }
@keyframes float { 50% { transform: translateY(-8px); } }
.wordmark {
    margin: 26px 0 0; font: 900 clamp(48px, 8.5vw, 104px)/.92 var(--display); letter-spacing: -.02em; text-transform: uppercase;
    background: linear-gradient(100deg, #fff 0%, #e8fff4 35%, var(--accent-2) 62%, var(--accent) 100%);
    -webkit-background-clip: text; background-clip: text; color: transparent;
}
.eyebrow {
    display: flex; align-items: center; gap: 14px; margin-top: 12px;
    font: 700 14px/1 var(--display); letter-spacing: 1em; text-transform: uppercase; color: var(--accent);
}
.eyebrow::before { content: ''; width: 48px; height: 2px; background: linear-gradient(90deg, transparent, var(--accent)); }
.hero-sub { margin: 26px 0 0; max-width: 560px; font-size: clamp(16px, 1.6vw, 18.5px); color: var(--text-2); }
.hero-actions { margin-top: 34px; display: flex; flex-wrap: wrap; gap: 12px; }
.fade-up { animation: rise 1s cubic-bezier(.2, .8, .2, 1) both; }
.fade-up.d1 { animation-delay: .1s; } .fade-up.d2 { animation-delay: .2s; } .fade-up.d3 { animation-delay: .3s; }
@keyframes rise { from { opacity: 0; transform: translateY(22px); } }

/* live status card */
.status-card {
    background: rgba(12, 16, 20, .66); border: 1px solid var(--line); border-radius: var(--radius-lg);
    padding: 24px; background: rgba(10, 14, 18, 0.9);
    box-shadow: 0 30px 60px -30px rgba(0, 0, 0, .8);
}
.status-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.status-head h2 { margin: 0; font: 700 12px/1 var(--display); letter-spacing: .22em; text-transform: uppercase; color: var(--muted); }
.pill {
    display: inline-flex; align-items: center; gap: 8px; padding: 5px 11px; border-radius: 999px;
    font-size: 12.5px; font-weight: 600; background: rgba(255, 255, 255, .06); color: var(--muted);
}
.pill .dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.pill.online { color: var(--accent); background: rgba(61, 220, 151, .12); }
.pill.online .dot { box-shadow: 0 0 0 0 rgba(61, 220, 151, .6); animation: pulse 2s infinite; }
.pill.offline { color: var(--danger); background: rgba(255, 107, 107, .1); }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(61, 220, 151, .55); } 70% { box-shadow: 0 0 0 9px rgba(61, 220, 151, 0); } 100% { box-shadow: 0 0 0 0 rgba(61, 220, 151, 0); } }
.players { margin-top: 20px; display: flex; align-items: baseline; gap: 8px; }
.players strong { font: 800 52px/1 var(--display); font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.players span { color: var(--muted); font-size: 18px; font-weight: 500; }
.bar { margin-top: 14px; height: 6px; border-radius: 99px; background: rgba(255, 255, 255, .07); overflow: hidden; }
.bar i { display: block; height: 100%; width: 0; border-radius: inherit; background: linear-gradient(90deg, var(--accent-deep), var(--accent)); transition: width 1s cubic-bezier(.2, .8, .2, 1); }
.status-meta { margin-top: 12px; font-size: 13.5px; color: var(--muted); display: flex; justify-content: space-between; gap: 10px; }
.connect-box {
    margin-top: 20px; display: flex; align-items: center; gap: 8px;
    border: 1px dashed var(--line-2); border-radius: 12px; padding: 8px 8px 8px 14px;
}
.connect-box code { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font: 500 13.5px var(--mono); color: var(--text-2); }
.connect-box code::before { content: 'connect '; color: var(--muted); }
.icon-btn {
    width: 34px; height: 34px; border-radius: 9px; border: 1px solid var(--line-2); background: rgba(255, 255, 255, .03);
    display: grid; place-items: center; cursor: pointer; flex-shrink: 0; transition: border-color .2s, color .2s;
}
.icon-btn:hover { border-color: var(--accent); color: var(--accent); }
.icon-btn svg { width: 16px; height: 16px; }
.status-card .btn { width: 100%; margin-top: 12px; }
.discord-count { margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--line); font-size: 13.5px; color: var(--muted); display: flex; align-items: center; gap: 10px; }
.discord-count svg { width: 18px; height: 18px; color: #8b95ff; }
.discord-count b { color: var(--text); }

.scroll-hint { position: absolute; left: 50%; bottom: 26px; transform: translateX(-50%); color: var(--muted); animation: bob 2.4s ease-in-out infinite; }
.scroll-hint svg { width: 22px; height: 22px; }
@keyframes bob { 50% { transform: translate(-50%, 6px); } }

@media (max-width: 920px) {
    .hero-inner { grid-template-columns: 1fr; gap: 40px; padding-top: 110px; padding-bottom: 72px; }
    .scroll-hint { display: none; }
    .eyebrow { letter-spacing: .6em; }
}

/* ------------------------------------------------------------------ page header (inner pages) */
.page-head { position: relative; padding: 150px 0 64px; overflow: hidden; isolation: isolate; border-bottom: 1px solid var(--line); }
.page-head::before {
    content: ''; position: absolute; inset: 0; z-index: -2;
    background: url('../img/moon.jpg') center 40% / cover no-repeat; opacity: .45;
}
.page-head::after {
    content: ''; position: absolute; inset: 0; z-index: -1;
    background: linear-gradient(0deg, var(--bg) 0%, rgba(5, 8, 11, .55) 70%, rgba(5, 8, 11, .75) 100%),
                radial-gradient(ellipse at 20% 0%, rgba(61, 220, 151, .16), transparent 60%);
}
.page-head.alt::before { background-image: url('../img/vinewood.jpg'); background-position: center 70%; }
.kicker { font: 700 12.5px/1 var(--display); letter-spacing: .28em; text-transform: uppercase; color: var(--accent); }
.page-head h1 { margin: 14px 0 0; font: 900 clamp(38px, 6vw, 64px)/1 var(--display); letter-spacing: -.02em; text-transform: uppercase; }
.page-head p { margin: 18px 0 0; max-width: 620px; color: var(--text-2); font-size: 17px; }

/* ------------------------------------------------------------------ sections */
.section { padding: clamp(64px, 9vw, 112px) 0; }
.section + .section { padding-top: 0; }
.section-head { max-width: 680px; margin-bottom: 44px; }
.section-head h2 { margin: 12px 0 0; font: 800 clamp(28px, 4vw, 42px)/1.1 var(--display); letter-spacing: -.015em; }
.section-head p { margin: 14px 0 0; color: var(--text-2); font-size: 17px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }

.card {
    position: relative; background: linear-gradient(180deg, var(--surface-2), var(--surface));
    border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 26px;
}
.grid { display: grid; gap: 18px; }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 1000px) { .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .grid-4, .grid-3, .grid-2 { grid-template-columns: 1fr; } }

/* features */
.feature { transition: border-color .25s, transform .25s; overflow: hidden; }
.feature:hover { border-color: rgba(61, 220, 151, .35); transform: translateY(-3px); }
.feature::after {
    content: ''; position: absolute; inset: auto -40% -60% auto; width: 220px; height: 220px; border-radius: 50%;
    background: radial-gradient(circle, rgba(61, 220, 151, .12), transparent 70%); pointer-events: none; opacity: 0; transition: opacity .3s;
}
.feature:hover::after { opacity: 1; }
.ico {
    width: 46px; height: 46px; border-radius: 13px; display: grid; place-items: center;
    background: rgba(61, 220, 151, .1); color: var(--accent); border: 1px solid rgba(61, 220, 151, .2);
}
.ico svg { width: 22px; height: 22px; }
.feature h3 { margin: 18px 0 0; font-size: 18px; font-weight: 700; }
.feature p { margin: 8px 0 0; color: var(--text-2); font-size: 15px; }
.tags { margin-top: 16px; display: flex; flex-wrap: wrap; gap: 6px; }
.tag { font: 500 12px/1 var(--mono); padding: 5px 8px; border-radius: 6px; background: rgba(255, 255, 255, .05); color: var(--muted); }

/* split banner */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 0; border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; background: var(--surface); }
.split-media { min-height: 360px; background: url('../img/vinewood.jpg') center / cover; position: relative; }
.split-media::after { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, transparent 50%, var(--surface)); }
.split-body { padding: clamp(28px, 5vw, 56px); }
.split-body h2 { margin: 12px 0 0; font: 800 clamp(26px, 3.4vw, 36px)/1.15 var(--display); }
.split-body p { color: var(--text-2); }
@media (max-width: 820px) { .split { grid-template-columns: 1fr; } .split-media { min-height: 220px; } .split-media::after { background: linear-gradient(0deg, var(--surface), transparent 60%); } }

/* stats */
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; }
.stat { background: var(--bg-2); padding: 28px 24px; }
.stat strong { display: block; font: 800 clamp(30px, 3.6vw, 42px)/1 var(--display); color: var(--accent); letter-spacing: -.02em; }
.stat span { display: block; margin-top: 10px; color: var(--text-2); font-size: 14.5px; }
@media (max-width: 760px) { .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* steps */
.steps { counter-reset: step; }
.step { padding-top: 64px; }
.step::before {
    counter-increment: step; content: '0' counter(step);
    position: absolute; top: 24px; left: 26px; font: 800 14px/1 var(--mono); color: var(--accent);
    padding: 7px 10px; border-radius: 8px; background: rgba(61, 220, 151, .1);
}
.step h3 { margin: 0; font-size: 18px; }
.step p { margin: 8px 0 0; color: var(--text-2); font-size: 15px; }
.step .btn { margin-top: 18px; }

/* keys */
.keys { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; }
.key { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line); }
.key kbd {
    min-width: 44px; padding: 6px 9px; text-align: center; border-radius: 8px; font: 600 13px/1.2 var(--mono);
    background: var(--surface-2); border: 1px solid var(--line-2); border-bottom-width: 3px; color: var(--text);
}
.key span { font-size: 14.5px; color: var(--text-2); }

/* faq */
.faq { display: grid; gap: 10px; max-width: 820px; margin: 0 auto; }
.faq details { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); transition: border-color .2s; }
.faq details[open] { border-color: rgba(61, 220, 151, .3); }
.faq summary { list-style: none; cursor: pointer; padding: 18px 22px; font-weight: 600; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary svg { width: 18px; height: 18px; color: var(--muted); transition: transform .25s; flex-shrink: 0; }
.faq details[open] summary svg { transform: rotate(45deg); color: var(--accent); }
.faq details p { margin: 0; padding: 0 22px 20px; color: var(--text-2); }

/* cta */
.cta {
    position: relative; overflow: hidden; text-align: center; border-radius: var(--radius-lg);
    padding: clamp(40px, 7vw, 80px) var(--gutter); border: 1px solid rgba(61, 220, 151, .25);
    background: radial-gradient(ellipse at 50% 120%, rgba(61, 220, 151, .25), transparent 60%), var(--surface);
}
.cta h2 { margin: 0; font: 900 clamp(30px, 5vw, 52px)/1.05 var(--display); text-transform: uppercase; letter-spacing: -.015em; }
.cta p { margin: 16px auto 0; max-width: 560px; color: var(--text-2); }
.cta .hero-actions { justify-content: center; }

/* ------------------------------------------------------------------ staff */
.staff-group + .staff-group { margin-top: 56px; }
.group-title { display: flex; align-items: baseline; gap: 14px; margin-bottom: 20px; flex-wrap: wrap; }
.group-title h2 { margin: 0; font: 800 24px/1.2 var(--display); }
.group-title span { color: var(--muted); font-size: 15px; }
.person { display: flex; gap: 18px; align-items: flex-start; }
.avatar {
    width: 64px; height: 64px; border-radius: 18px; flex-shrink: 0; display: grid; place-items: center; overflow: hidden;
    background: linear-gradient(135deg, var(--accent-deep), #0c3b2a); color: #d6ffee; font: 800 22px/1 var(--display);
    box-shadow: inset 0 0 0 1px rgba(143, 245, 200, .25);
}
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.person h3 { margin: 0; font-size: 18px; }
.role-badge {
    display: inline-block; margin-top: 6px; padding: 4px 9px; border-radius: 6px;
    font: 700 11px/1 var(--display); letter-spacing: .12em; text-transform: uppercase;
    background: rgba(61, 220, 151, .12); color: var(--accent);
}
.role-badge.admin { background: rgba(255, 200, 87, .12); color: var(--warn); }
.role-badge.moderator { background: rgba(139, 149, 255, .14); color: #a9b1ff; }
.role-badge.support { background: rgba(255, 255, 255, .08); color: var(--text-2); }
.person p { margin: 10px 0 0; color: var(--text-2); font-size: 15px; }
.person .sub { margin-top: 4px; font-size: 14px; color: var(--muted); }
.open-slot { border-style: dashed; display: flex; flex-direction: column; justify-content: center; align-items: flex-start; gap: 10px; min-height: 140px; background: transparent; }
.open-slot h3 { margin: 0; font-size: 17px; }
.open-slot p { margin: 0; color: var(--muted); font-size: 14.5px; }
.dept { display: flex; flex-direction: column; gap: 8px; }
.dept .abbr { font: 900 28px/1 var(--display); color: var(--accent); letter-spacing: .02em; }
.dept h3 { margin: 0; font-size: 15.5px; }
.dept p { margin: 0; color: var(--muted); font-size: 14px; }
.dept .lead { margin-top: 8px; padding-top: 12px; border-top: 1px solid var(--line); font-size: 14px; color: var(--text-2); }

/* ------------------------------------------------------------------ store */
.plans { align-items: stretch; }
.plan { display: flex; flex-direction: column; padding: 30px; }
.plan.featured { border-color: rgba(61, 220, 151, .45); box-shadow: 0 30px 70px -40px rgba(61, 220, 151, .6); background: linear-gradient(180deg, #102219, var(--surface)); }
.plan .ribbon { position: absolute; top: 18px; right: 18px; }
.plan h3 { margin: 0; font: 800 20px/1.2 var(--display); }
.plan .tagline { margin: 8px 0 0; color: var(--muted); font-size: 14.5px; min-height: 2.8em; }
.price { margin: 22px 0 0; display: flex; align-items: baseline; gap: 8px; }
.price strong { font: 800 46px/1 var(--display); letter-spacing: -.02em; }
.price span { color: var(--muted); font-size: 15px; }
.perks { list-style: none; margin: 24px 0 28px; padding: 0; display: grid; gap: 12px; flex: 1; align-content: start; }
.perks li { display: flex; gap: 11px; font-size: 15px; color: var(--text-2); }
.perks svg { width: 18px; height: 18px; color: var(--accent); flex-shrink: 0; margin-top: 3px; }
.plan .btn { width: 100%; }
.notice {
    display: flex; gap: 14px; align-items: flex-start; padding: 18px 20px; border-radius: var(--radius);
    background: rgba(88, 101, 242, .08); border: 1px solid rgba(88, 101, 242, .3); color: var(--text-2); font-size: 15px;
}
.notice svg { width: 22px; height: 22px; flex-shrink: 0; color: #8b95ff; margin-top: 1px; }
.notice b { color: var(--text); }
.fine { margin-top: 28px; font-size: 13.5px; color: var(--muted); max-width: 820px; }
.fine p { margin: 0 0 8px; }

/* ------------------------------------------------------------------ rules */
.rules-layout { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 48px; align-items: start; }
.toc { position: sticky; top: 96px; display: grid; gap: 4px; }
.toc a { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; color: var(--text-2); font-size: 14.5px; font-weight: 500; transition: background .2s, color .2s; }
.toc a:hover { background: rgba(255, 255, 255, .04); color: var(--text); }
.toc a.active { background: rgba(61, 220, 151, .1); color: var(--accent); }
.toc a svg { width: 17px; height: 17px; }
.toc .count { margin-left: auto; font: 500 12px var(--mono); color: var(--muted); }
.search { position: relative; margin-bottom: 28px; }
.search svg { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: var(--muted); pointer-events: none; }
.search input {
    width: 100%; height: 52px; padding: 0 16px 0 46px; border-radius: 14px;
    background: var(--surface); border: 1px solid var(--line-2); outline: none; transition: border-color .2s;
}
.search input:focus { border-color: var(--accent); }
.rule-section { scroll-margin-top: 96px; }
.rule-section + .rule-section { margin-top: 44px; }
.rule-section h2 { display: flex; align-items: center; gap: 12px; margin: 0 0 16px; font: 800 24px/1.2 var(--display); }
.rule-section h2 .ico { width: 38px; height: 38px; border-radius: 11px; }
.rule-section h2 .ico svg { width: 19px; height: 19px; }
.rule-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.rule { display: grid; grid-template-columns: 58px minmax(0, 1fr); gap: 4px; padding: 18px 20px 18px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.rule .num { font: 600 13px/1.7 var(--mono); color: var(--accent); }
.rule h3 { margin: 0; font-size: 16px; }
.rule p { margin: 4px 0 0; color: var(--text-2); font-size: 15px; }
.rule mark { background: rgba(61, 220, 151, .25); color: var(--text); border-radius: 3px; padding: 0 2px; }
.empty { padding: 40px; text-align: center; color: var(--muted); border: 1px dashed var(--line-2); border-radius: var(--radius); }
@media (max-width: 900px) {
    .rules-layout { grid-template-columns: 1fr; gap: 20px; }
    .toc { position: static; display: flex; overflow-x: auto; gap: 6px; padding-bottom: 6px; scrollbar-width: none; }
    .toc a { white-space: nowrap; border: 1px solid var(--line); }
    .toc .count { display: none; }
    .rule { grid-template-columns: 44px minmax(0, 1fr); }
}

/* ------------------------------------------------------------------ apply */
.types { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
@media (max-width: 900px) { .types { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 480px) { .types { grid-template-columns: 1fr; } }
.type {
    text-align: left; cursor: pointer; padding: 20px; border-radius: var(--radius-lg);
    background: var(--surface); border: 1px solid var(--line); transition: border-color .2s, background .2s, transform .2s;
}
.type:hover { border-color: var(--line-2); transform: translateY(-2px); }
.type[aria-pressed="true"] { border-color: var(--accent); background: linear-gradient(180deg, #0f2219, var(--surface)); box-shadow: 0 0 0 1px var(--accent) inset; }
.type h3 { margin: 14px 0 0; font-size: 17px; }
.type p { margin: 6px 0 0; color: var(--muted); font-size: 14px; line-height: 1.5; }
.form-card { margin-top: 28px; padding: clamp(22px, 4vw, 40px); }
.form-card h2 { margin: 0; font: 800 24px/1.2 var(--display); }
.form-card > p { margin: 8px 0 0; color: var(--muted); }
.form-grid { margin-top: 28px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.field { display: grid; gap: 8px; }
.field.full { grid-column: 1 / -1; }
@media (max-width: 640px) { .form-grid { grid-template-columns: 1fr; } }
.field label { font-weight: 600; font-size: 14.5px; }
.field label .req { color: var(--accent); margin-left: 3px; }
.field input, .field select, .field textarea {
    width: 100%; padding: 12px 14px; border-radius: 12px; background: var(--bg-2); border: 1px solid var(--line-2);
    outline: none; transition: border-color .2s, box-shadow .2s; font-size: 15px;
}
.field select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%238a93a3' stroke-width='2' viewBox='0 0 24 24'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 40px; }
.field textarea { min-height: 130px; resize: vertical; line-height: 1.55; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(61, 220, 151, .15); }
.field.invalid input, .field.invalid select, .field.invalid textarea { border-color: var(--danger); }
.field .hint { display: flex; justify-content: space-between; font-size: 12.5px; color: var(--muted); }
.field .err { color: var(--danger); }
.check { display: flex; gap: 12px; align-items: flex-start; font-size: 15px; color: var(--text-2); cursor: pointer; }
.check input { width: 20px; height: 20px; margin-top: 2px; accent-color: var(--accent); flex-shrink: 0; }
.check a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.form-foot { margin-top: 28px; display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.form-msg { font-size: 14.5px; }
.form-msg.error { color: var(--danger); }
.success { text-align: center; padding: clamp(32px, 6vw, 64px) 20px; }
.success .ico { width: 64px; height: 64px; border-radius: 20px; margin: 0 auto; }
.success .ico svg { width: 30px; height: 30px; }
.success h2 { margin: 22px 0 0; }
.success p { margin: 10px auto 0; max-width: 480px; color: var(--text-2); }
.success .mono { color: var(--accent); }

/* ------------------------------------------------------------------ footer */
.footer { margin-top: 40px; border-top: 1px solid var(--line); background: var(--bg-2); }
.footer-inner { padding-top: 48px; padding-bottom: 28px; display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; }
.footer p { color: var(--muted); font-size: 14.5px; max-width: 360px; }
.footer h4 { margin: 0 0 14px; font: 700 12px/1 var(--display); letter-spacing: .2em; text-transform: uppercase; color: var(--muted); }
.footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.footer ul a { color: var(--text-2); font-size: 14.5px; }
.footer ul a:hover { color: var(--accent); }
.footer-bottom { padding-top: 20px; padding-bottom: 32px; border-top: 1px solid var(--line); display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: 13px; color: var(--muted); }
@media (max-width: 760px) { .footer-inner { grid-template-columns: 1fr 1fr; } .footer-inner > :first-child { grid-column: 1 / -1; } }

/* toast */
.toast {
    position: fixed; left: 50%; bottom: 28px; z-index: 100; transform: translate(-50%, 20px); opacity: 0; pointer-events: none;
    padding: 12px 18px; border-radius: 12px; background: var(--surface-2); border: 1px solid rgba(61, 220, 151, .4);
    font-size: 14.5px; font-weight: 500; transition: opacity .25s, transform .25s; box-shadow: 0 20px 40px -20px #000;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* reveal on scroll */
.reveal { opacity: 0; transform: translateY(12px); transition: opacity .4s ease-out, transform .4s ease-out; }
.reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; }
    .reveal { opacity: 1; transform: none; }
    html { scroll-behavior: auto; }
}
[hidden] { display: none !important; }
