/* ===================================================================
   NekoSMP — shared stylesheet
   Monochrome (black & white) with a quiet rose tint that keeps the
   "neko" spirit. Restrained motion, real micro-interactions.
   =================================================================== */

/* ---------- Design tokens ---------- */
:root {
    /* Surfaces */
    --bg:            #0a0a0b;
    --bg-soft:       #101012;
    --surface:       rgba(255, 255, 255, 0.04);
    --surface-2:     rgba(255, 255, 255, 0.07);
    --border:        rgba(255, 255, 255, 0.09);
    --border-strong: rgba(255, 255, 255, 0.16);

    /* Text */
    --text:        #fafafa;
    --text-muted:  #a1a1aa;
    --text-faint:  #71717a;
    --text-sub:    var(--text-muted); /* legacy alias */

    /* Accent — quiet rose */
    --accent:       #ff8fb4;
    --accent-soft:  #ffb3cd;
    --accent-deep:  #e2729a;
    --accent-tint:  rgba(255, 143, 180, 0.10);
    --accent-ring:  rgba(255, 143, 180, 0.30);

    /* Status */
    --ok:      #54d18f;
    --offline: #ff6b6b;

    /* Type */
    --font-display: 'Space Grotesk', 'Segoe UI', sans-serif;
    --font-body:    'Inter', 'Segoe UI', sans-serif;

    /* Shape */
    --r-sm:   8px;
    --r:      12px;
    --r-lg:   18px;
    --r-xl:   24px;
    --r-pill: 999px;

    /* Elevation */
    --shadow-sm: 0 4px 14px -8px rgba(0, 0, 0, 0.7);
    --shadow:    0 24px 50px -24px rgba(0, 0, 0, 0.85);

    --header-h: 74px;
    --maxw: 1200px;
}

/* ---------- Reset & base ---------- */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
    font-family: var(--font-body);
    background-color: var(--bg);
    background-image:
        radial-gradient(900px 480px at 50% -6%, rgba(255, 143, 180, 0.06), transparent 62%),
        radial-gradient(700px 420px at 100% 0%, rgba(255, 255, 255, 0.025), transparent 60%);
    background-attachment: fixed;
    color: var(--text);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    overflow-x: hidden;
}
body.modal-open { overflow: hidden; }

a { text-decoration: none; color: inherit; transition: color 0.2s ease; }
img { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; }
:focus-visible { outline: 2px solid var(--accent-ring); outline-offset: 2px; border-radius: 4px; }
::selection { background: var(--accent-tint); color: var(--text); }

/* Scroll reveal (only active when JS is on) */
.js [data-reveal] { opacity: 0; transform: translateY(18px); transition: opacity 0.6s ease, transform 0.6s ease; }
.js [data-reveal].in { opacity: 1; transform: none; }

/* ---------- Layout helpers ---------- */
.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.section { padding: 130px 0; }
[id] { scroll-margin-top: calc(var(--header-h) + 28px); }

.eyebrow {
    display: inline-flex; align-items: center; gap: 9px;
    font-size: 0.76rem; font-weight: 600; letter-spacing: 0.2em;
    text-transform: uppercase; color: var(--accent); margin-bottom: 18px;
}
.eyebrow::before { content: ""; width: 22px; height: 1px; background: var(--accent); opacity: 0.55; }

.section-head { text-align: center; max-width: 640px; margin: 0 auto 76px; }
.section-head .eyebrow { justify-content: center; }
.section-title {
    font-family: var(--font-display); font-size: clamp(2rem, 4.2vw, 3rem);
    font-weight: 600; letter-spacing: -0.02em; line-height: 1.1; color: var(--text);
}
.section-title .hl { color: var(--accent); }
.section-sub { margin-top: 18px; color: var(--text-muted); font-size: 1.05rem; }

/* ---------- Header ---------- */
.site-header {
    position: fixed; inset: 0 0 auto 0; height: var(--header-h); z-index: 1000;
    background: rgba(10, 10, 11, 0.7); backdrop-filter: blur(18px) saturate(140%);
    border-bottom: 1px solid var(--border);
}
.header-inner {
    height: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px;
    display: flex; align-items: center; gap: 26px;
}
.brand {
    font-family: var(--font-display); font-weight: 700; font-size: 1.3rem;
    letter-spacing: -0.01em; color: var(--text); flex-shrink: 0;
}
.brand b { color: var(--accent); font-weight: 700; }

.main-nav { flex: 1; display: flex; justify-content: center; gap: 4px; }
.main-nav a {
    position: relative; padding: 9px 15px; border-radius: var(--r-sm);
    font-size: 0.92rem; font-weight: 500; color: var(--text-muted);
    transition: color 0.2s ease, background 0.2s ease;
}
.main-nav a:hover { color: var(--text); background: var(--surface); }
.main-nav a.active { color: var(--text); }
.main-nav a.active::after {
    content: ""; position: absolute; left: 15px; right: 15px; bottom: 3px;
    height: 2px; border-radius: 2px; background: var(--accent);
}

.header-actions { display: flex; align-items: center; gap: 14px; flex-shrink: 0; }
#auth-actions { display: flex; align-items: center; gap: 14px; }

/* Online status — minimal monochrome chip with a rose dot */
.status-pill {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 7px 13px; border-radius: var(--r-pill);
    background: var(--surface); border: 1px solid var(--border);
    color: var(--text); font-size: 0.85rem; font-weight: 600;
    font-variant-numeric: tabular-nums;
}
.status-pill .status-label { color: var(--text-faint); font-weight: 500; }
.pulse-dot {
    width: 7px; height: 7px; border-radius: 50%; background: var(--accent);
    box-shadow: 0 0 0 0 var(--accent-ring); animation: pulse 2.6s infinite;
}
@keyframes pulse {
    0%   { box-shadow: 0 0 0 0 rgba(255, 143, 180, 0.45); }
    70%  { box-shadow: 0 0 0 7px rgba(255, 143, 180, 0); }
    100% { box-shadow: 0 0 0 0 rgba(255, 143, 180, 0); }
}

/* Logged-in user chip */
.user-chip {
    display: inline-flex; align-items: center; gap: 10px;
    padding: 5px 6px 5px 8px; border-radius: var(--r-pill);
    background: var(--surface); border: 1px solid var(--border-strong);
}
.user-ava {
    width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center;
    background: var(--text); color: #0a0a0b;
    font-family: var(--font-display); font-weight: 700; font-size: 0.85rem;
}
.user-name { font-size: 0.9rem; font-weight: 600; color: var(--text); }
.user-logout {
    display: grid; place-items: center; width: 28px; height: 28px;
    border: none; border-radius: 50%; background: transparent; color: var(--text-faint);
    transition: background 0.2s ease, color 0.2s ease;
}
.user-logout:hover { background: var(--surface-2); color: var(--offline); }
.user-logout svg { width: 16px; height: 16px; }

/* Mobile nav toggle */
.nav-toggle {
    display: none; flex-direction: column; justify-content: center; gap: 5px;
    width: 40px; height: 40px; border: 1px solid var(--border-strong);
    border-radius: var(--r-sm); background: var(--surface);
}
.nav-toggle span { display: block; width: 18px; height: 2px; margin: 0 auto; background: var(--text); border-radius: 2px; transition: transform 0.25s ease, opacity 0.2s ease; }
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 9px;
    padding: 12px 22px; border: 1px solid transparent; border-radius: var(--r);
    font-family: var(--font-body); font-size: 0.95rem; font-weight: 600; line-height: 1;
    transition: transform 0.18s ease, background 0.2s ease, border-color 0.2s ease, color 0.2s ease, opacity 0.2s ease;
    white-space: nowrap;
}
.btn svg { width: 18px; height: 18px; }
.btn-primary { background: var(--text); color: #0a0a0b; }
.btn-primary:hover { transform: translateY(-1px); background: #fff; }
.btn-ghost { background: var(--surface); border-color: var(--border-strong); color: var(--text); }
.btn-ghost:hover { transform: translateY(-1px); background: var(--surface-2); border-color: rgba(255, 255, 255, 0.26); }
.btn-lg { padding: 15px 28px; font-size: 1.02rem; }
.btn-block { width: 100%; }

/* Header auth buttons */
.btn-signin { font-size: 0.92rem; font-weight: 600; color: var(--text-muted); padding: 8px 6px; transition: color 0.2s ease; }
.btn-signin:hover { color: var(--text); }
.btn-signup {
    padding: 10px 20px; border: none; border-radius: var(--r);
    background: var(--text); color: #0a0a0b; font-size: 0.9rem; font-weight: 700;
    transition: transform 0.18s ease, background 0.2s ease;
}
.btn-signup:hover { transform: translateY(-1px); background: #fff; }

/* ---------- Ambient motes ---------- */
#petals { position: fixed; inset: 0; pointer-events: none; z-index: 0; overflow: hidden; }
.petal {
    position: absolute; top: -5vh; border-radius: 50%;
    background: radial-gradient(circle, var(--accent-soft), transparent 70%);
    opacity: 0.12; animation: drift linear infinite;
}
@keyframes drift {
    0%   { transform: translateY(-5vh) translateX(0); opacity: 0; }
    10%  { opacity: 0.12; }
    90%  { opacity: 0.12; }
    100% { transform: translateY(105vh) translateX(36px); opacity: 0; }
}

/* ---------- Hero (home) — designed background, no video ---------- */
.hero {
    position: relative; min-height: 100vh; display: flex; align-items: center; justify-content: center;
    padding: calc(var(--header-h) + 70px) 24px 110px; overflow: hidden; text-align: center;
}
.hero-bg { position: absolute; inset: 0; z-index: -3; background: var(--bg); }
.hero-bg::before {
    content: ""; position: absolute; inset: 0;
    background-image: radial-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px);
    background-size: 26px 26px;
    -webkit-mask-image: radial-gradient(ellipse 72% 62% at 50% 38%, #000 28%, transparent 76%);
    mask-image: radial-gradient(ellipse 72% 62% at 50% 38%, #000 28%, transparent 76%);
}
.hero-bg::after {
    content: ""; position: absolute; inset: 0;
    background:
        radial-gradient(620px 380px at 50% 26%, rgba(255, 143, 180, 0.16), transparent 70%),
        radial-gradient(900px 520px at 50% 118%, rgba(255, 143, 180, 0.05), transparent 70%),
        linear-gradient(to bottom, transparent 58%, var(--bg));
}
.hero-orb { position: absolute; z-index: -2; border-radius: 50%; filter: blur(80px); pointer-events: none; }
.hero-orb.one { width: 440px; height: 440px; background: rgba(255, 143, 180, 0.16); top: -90px; left: -70px; animation: float1 16s ease-in-out infinite; }
.hero-orb.two { width: 400px; height: 400px; background: rgba(255, 255, 255, 0.045); bottom: -120px; right: -60px; animation: float2 20s ease-in-out infinite; }
@keyframes float1 { 0%,100% { transform: translate(0,0); } 50% { transform: translate(30px, 30px); } }
@keyframes float2 { 0%,100% { transform: translate(0,0); } 50% { transform: translate(-30px, -20px); } }

.hero-inner { position: relative; z-index: 1; max-width: 840px; }
.hero-badge {
    display: inline-flex; align-items: center; gap: 9px; padding: 7px 16px; margin-bottom: 30px;
    border-radius: var(--r-pill); background: rgba(255, 255, 255, 0.04); border: 1px solid var(--border);
    font-size: 0.8rem; font-weight: 600; letter-spacing: 0.04em; color: var(--text-muted); backdrop-filter: blur(6px);
}
.hero-badge .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 8px var(--accent); }
.hero h1 {
    font-family: var(--font-display); font-size: clamp(2.7rem, 7vw, 5.1rem);
    font-weight: 600; line-height: 1.04; letter-spacing: -0.03em; margin-bottom: 24px;
}
.hero h1 .hl { color: var(--accent); }
.hero-desc { max-width: 600px; margin: 0 auto 42px; font-size: 1.14rem; color: var(--text-muted); }

/* Join / IP bar */
.join-bar {
    display: inline-flex; align-items: stretch; gap: 6px; padding: 6px; border-radius: var(--r-lg);
    background: rgba(16, 16, 18, 0.85); border: 1px solid var(--border-strong);
    box-shadow: var(--shadow); backdrop-filter: blur(10px); margin-bottom: 20px;
}
.ip-copy {
    display: flex; flex-direction: column; justify-content: center; text-align: left;
    padding: 6px 18px; border-radius: var(--r); background: transparent; border: none; color: var(--text);
    transition: background 0.2s ease; position: relative;
}
.ip-copy:hover { background: var(--surface); }
.ip-copy .ip-label { font-size: 0.68rem; text-transform: uppercase; letter-spacing: 0.12em; color: var(--text-faint); display: flex; align-items: center; gap: 6px; }
.ip-copy .ip-label svg { width: 13px; height: 13px; }
.ip-copy .ip-value { font-family: var(--font-display); font-weight: 600; font-size: 1.05rem; }
.ip-copy .copied-flag {
    position: absolute; top: -34px; left: 50%; transform: translateX(-50%) translateY(4px);
    background: var(--text); color: #0a0a0b; font-size: 0.72rem; font-weight: 700; padding: 4px 10px;
    border-radius: var(--r-sm); opacity: 0; pointer-events: none; transition: opacity 0.2s ease, transform 0.2s ease; white-space: nowrap;
}
.ip-copy.copied .copied-flag { opacity: 1; transform: translateX(-50%) translateY(0); }

.hero-secondary { margin-bottom: 56px; }

/* Stats */
.stats { display: flex; flex-wrap: wrap; justify-content: center; gap: 16px; margin-bottom: 30px; }
.stat { min-width: 158px; padding: 20px 28px; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--border); backdrop-filter: blur(8px); }
.stat .num { font-family: var(--font-display); font-size: 1.75rem; font-weight: 600; color: var(--text); }
.stat .lbl { font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-faint); margin-top: 3px; }
.hero-meta { color: var(--text-faint); font-size: 0.82rem; letter-spacing: 0.02em; }
.hero-meta b { color: var(--text-muted); font-weight: 600; }

/* ---------- Features ---------- */
.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(310px, 1fr)); gap: 24px; }
.feature-card { padding: 38px 34px; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--border); transition: transform 0.25s ease, border-color 0.25s ease, background 0.25s ease; }
.feature-card:hover { transform: translateY(-4px); border-color: var(--border-strong); background: var(--surface-2); }
.feature-icon { display: grid; place-items: center; width: 54px; height: 54px; border-radius: 14px; background: var(--accent-tint); border: 1px solid var(--accent-ring); color: var(--accent); margin-bottom: 22px; }
.feature-icon svg { width: 27px; height: 27px; }
.feature-card h3 { font-family: var(--font-display); font-size: 1.28rem; font-weight: 600; margin-bottom: 10px; }
.feature-card p { color: var(--text-muted); font-size: 0.96rem; }

/* ---------- Steps ---------- */
.steps-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.step-card { position: relative; padding: 36px 32px; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--border); }
.step-num { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; margin-bottom: 22px; background: var(--accent-tint); border: 1px solid var(--accent-ring); color: var(--accent); font-family: var(--font-display); font-weight: 700; font-size: 1.2rem; }
.step-card h3 { font-family: var(--font-display); font-size: 1.2rem; font-weight: 600; margin-bottom: 9px; }
.step-card p { color: var(--text-muted); font-size: 0.95rem; }
.step-card code { font-family: var(--font-display); color: var(--accent); background: var(--accent-tint); padding: 2px 8px; border-radius: 6px; font-size: 0.92rem; }

/* ---------- FAQ ---------- */
.faq { max-width: 820px; margin: 0 auto; }
.faq-item { border: 1px solid var(--border); border-radius: var(--r); background: var(--surface); margin-bottom: 14px; overflow: hidden; transition: border-color 0.2s ease, background 0.2s ease; }
.faq-item.active { border-color: var(--border-strong); background: var(--surface-2); }
.faq-question { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 22px 24px; cursor: pointer; font-weight: 600; font-size: 1.04rem; color: var(--text); user-select: none; }
.faq-chevron { width: 18px; height: 18px; color: var(--accent); flex-shrink: 0; transition: transform 0.3s ease; }
.faq-item.active .faq-chevron { transform: rotate(180deg); }
.faq-answer { max-height: 0; overflow: hidden; transition: max-height 0.35s ease; color: var(--text-muted); padding: 0 24px; font-size: 0.97rem; }
.faq-answer p { padding-bottom: 24px; }
.faq-item.active .faq-answer { max-height: 340px; }
.faq-answer strong { color: var(--text); }
.faq-answer a { color: var(--accent); }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--border); background: rgba(8, 8, 9, 0.6); padding: 64px 0 44px; position: relative; z-index: 1; }
.footer-inner { text-align: center; }
.footer-brand { font-family: var(--font-display); font-weight: 700; font-size: 1.3rem; color: var(--text); margin-bottom: 20px; }
.footer-brand b { color: var(--accent); }
.footer-links { display: flex; justify-content: center; flex-wrap: wrap; gap: 28px; margin-bottom: 24px; }
.footer-links a { color: var(--text-muted); font-size: 0.95rem; font-weight: 500; display: inline-flex; align-items: center; gap: 8px; }
.footer-links a:hover { color: var(--accent); }
.footer-links svg { width: 18px; height: 18px; }
.footer-note { color: var(--text-faint); font-size: 0.85rem; }

/* ---------- Modals ---------- */
.modal-overlay { position: fixed; inset: 0; z-index: 2000; display: flex; align-items: center; justify-content: center; padding: 20px; background: rgba(4, 4, 5, 0.72); backdrop-filter: blur(8px); opacity: 0; pointer-events: none; transition: opacity 0.25s ease; }
.modal-overlay.active { opacity: 1; pointer-events: auto; }
.modal-box { width: 100%; max-width: 430px; max-height: 90vh; overflow-y: auto; padding: 38px; border-radius: var(--r-xl); background: var(--bg-soft); border: 1px solid var(--border-strong); box-shadow: var(--shadow); text-align: center; position: relative; transform: translateY(12px) scale(0.98); transition: transform 0.28s ease; }
.modal-overlay.active .modal-box { transform: translateY(0) scale(1); }
.modal-box::-webkit-scrollbar { width: 6px; }
.modal-box::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 10px; }
.modal-close { position: absolute; top: 16px; right: 16px; width: 34px; height: 34px; display: grid; place-items: center; border-radius: var(--r-sm); border: none; background: var(--surface); color: var(--text-muted); transition: background 0.2s ease, color 0.2s ease; }
.modal-close:hover { background: var(--surface-2); color: var(--text); }
.modal-close svg { width: 16px; height: 16px; }
.modal-brand { font-family: var(--font-display); font-weight: 700; font-size: 1.4rem; margin-bottom: 6px; }
.modal-brand b { color: var(--accent); }
.modal-subtitle { color: var(--text-muted); font-size: 0.94rem; margin-bottom: 28px; }
.field { text-align: left; margin-bottom: 16px; }
.field-row { display: flex; gap: 14px; }
.field-row .field { flex: 1; }
.field label { display: block; font-size: 0.78rem; font-weight: 600; letter-spacing: 0.03em; color: var(--text-muted); margin-bottom: 7px; }
.field input { width: 100%; padding: 13px 15px; border-radius: var(--r); border: 1px solid var(--border-strong); background: rgba(0, 0, 0, 0.3); color: var(--text); font-family: var(--font-body); font-size: 0.98rem; transition: border-color 0.2s ease, box-shadow 0.2s ease; }
.field input::placeholder { color: var(--text-faint); }
.field input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-tint); }
.field-hint { font-size: 0.78rem; color: var(--text-faint); margin-top: 6px; }
.form-message { font-size: 0.86rem; font-weight: 600; min-height: 18px; margin-bottom: 12px; }
.modal-box .btn { width: 100%; margin-top: 6px; }
.modal-footer { margin-top: 22px; font-size: 0.9rem; color: var(--text-muted); }
.modal-footer .link { color: var(--accent); font-weight: 600; cursor: pointer; }
.modal-footer .link:hover { color: var(--accent-soft); }

/* ---------- Page header (sub-pages) ---------- */
.page-shell { max-width: var(--maxw); margin: 0 auto; padding: calc(var(--header-h) + 72px) 24px 110px; position: relative; z-index: 1; }
.page-head { text-align: center; max-width: 660px; margin: 0 auto 56px; }
.page-head .eyebrow { justify-content: center; }
.page-head h1 { font-family: var(--font-display); font-size: clamp(2.2rem, 5vw, 3.3rem); font-weight: 600; letter-spacing: -0.02em; line-height: 1.08; }
.page-head h1 .hl { color: var(--accent); }
.page-head p { margin-top: 16px; color: var(--text-muted); font-size: 1.04rem; }

/* ---------- Store ---------- */
.store-banner {
    position: relative; overflow: hidden; border-radius: var(--r-xl);
    padding: 76px 40px; text-align: center; border: 1px solid var(--border);
    background: radial-gradient(720px 320px at 50% -30%, var(--accent-tint), transparent 68%), var(--surface);
    margin-bottom: 50px;
}
.store-banner::before {
    content: ""; position: absolute; inset: 0;
    background-image: radial-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px);
    background-size: 24px 24px;
    -webkit-mask-image: radial-gradient(ellipse 60% 90% at 50% 0%, #000, transparent 72%);
    mask-image: radial-gradient(ellipse 60% 90% at 50% 0%, #000, transparent 72%);
}
.store-banner > * { position: relative; z-index: 1; }
.store-banner h1 { font-family: var(--font-display); font-size: clamp(2.3rem, 5vw, 3.4rem); font-weight: 600; letter-spacing: -0.02em; margin: 8px 0 14px; }
.store-banner h1 .hl { color: var(--accent); }
.store-banner p { color: var(--text-muted); max-width: 540px; margin: 0 auto; }

.store-sign-board {
    position: relative;
    display: inline-block;
    padding: 22px 56px 18px;
    margin-bottom: 20px;
}
.store-sign-board::before {
    content: "";
    position: absolute; inset: 0;
    border: 1px solid rgba(255, 143, 180, 0.32);
    border-radius: 6px;
    background: linear-gradient(135deg, rgba(255,143,180,0.07) 0%, transparent 55%, rgba(255,143,180,0.04) 100%);
    box-shadow: 0 0 36px rgba(255,143,180,0.08), inset 0 0 24px rgba(255,143,180,0.04);
}
.store-sign-board::after {
    content: "";
    position: absolute; inset: 5px;
    border: 1px solid rgba(255, 143, 180, 0.08);
    border-radius: 3px;
    pointer-events: none;
}
.sign-gem {
    position: absolute;
    width: 9px; height: 9px;
    background: var(--accent);
    transform: rotate(45deg);
    box-shadow: 0 0 10px var(--accent), 0 0 20px rgba(255,143,180,0.4);
    z-index: 2;
}
.sign-gem.tl { top: -4px;    left: -4px;  }
.sign-gem.tr { top: -4px;    right: -4px; }
.sign-gem.bl { bottom: -4px; left: -4px;  }
.sign-gem.br { bottom: -4px; right: -4px; }
.sign-divider {
    display: flex; align-items: center; gap: 10px;
    margin-top: 4px; opacity: 0.65;
}
.sign-divider::before, .sign-divider::after {
    content: ""; flex: 1; height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,143,180,0.45), transparent);
}
.sign-divider span { color: var(--accent); font-size: 0.6rem; }

.filters { display: flex; justify-content: center; flex-wrap: wrap; gap: 10px; margin-bottom: 50px; }
.filter-btn { padding: 9px 20px; border-radius: var(--r-pill); background: var(--surface); border: 1px solid var(--border); color: var(--text-muted); font-size: 0.88rem; font-weight: 600; transition: all 0.2s ease; }
.filter-btn:hover { color: var(--text); border-color: var(--border-strong); }
.filter-btn.active { background: var(--text); border-color: var(--text); color: #0a0a0b; }

.store-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); gap: 24px; align-items: stretch; }
.store-card { position: relative; display: flex; flex-direction: column; padding: 36px 32px; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--border); transition: transform 0.25s ease, border-color 0.25s ease, background 0.25s ease; }
.store-card:hover { transform: translateY(-6px); border-color: var(--border-strong); background: var(--surface-2); }
.store-card.featured { border-color: var(--accent-ring); background: linear-gradient(180deg, var(--accent-tint), var(--surface)); }
.store-card[hidden] { display: none; }
.card-badge { position: absolute; top: 18px; right: 18px; padding: 5px 12px; border-radius: var(--r-pill); font-size: 0.68rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; }
.card-badge.popular { background: var(--accent); color: #0a0a0b; }
.card-badge.limited { background: rgba(255, 107, 107, 0.15); color: #ff9a9a; border: 1px solid rgba(255, 107, 107, 0.3); }
.card-badge.best { background: var(--text); color: #0a0a0b; }
.card-icon { display: grid; place-items: center; width: 56px; height: 56px; border-radius: 14px; background: var(--accent-tint); border: 1px solid var(--accent-ring); color: var(--accent); margin-bottom: 22px; }
.card-icon svg { width: 28px; height: 28px; }
.card-name { font-family: var(--font-display); font-size: 1.55rem; font-weight: 600; }
.card-price { margin: 8px 0 26px; font-size: 1.45rem; font-weight: 700; color: var(--text); }
.card-price .per { font-size: 0.85rem; font-weight: 500; color: var(--text-faint); }
.card-features { list-style: none; flex: 1; margin-bottom: 30px; }
.card-features li { position: relative; padding-left: 26px; margin-bottom: 12px; font-size: 0.93rem; color: var(--text-muted); }
.card-features li::before {
    content: ""; position: absolute; left: 0; top: 3px; width: 16px; height: 16px;
    background-color: var(--accent);
    -webkit-mask: url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2024%2024'%20fill='none'%20stroke='%23000'%20stroke-width='3'%20stroke-linecap='round'%20stroke-linejoin='round'%3E%3Cpolyline%20points='20%206%209%2017%204%2012'/%3E%3C/svg%3E") no-repeat center / contain;
            mask: url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2024%2024'%20fill='none'%20stroke='%23000'%20stroke-width='3'%20stroke-linecap='round'%20stroke-linejoin='round'%3E%3Cpolyline%20points='20%206%209%2017%204%2012'/%3E%3C/svg%3E") no-repeat center / contain;
}

/* ---------- Leaderboard ---------- */
.lb-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-bottom: 40px; }
.lb-card { padding: 24px; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--border); text-align: center; transition: transform 0.2s ease, border-color 0.2s ease; }
.lb-card:hover { transform: translateY(-3px); border-color: var(--border-strong); }
.lb-card .lbl { font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-faint); margin-bottom: 12px; }
.lb-card .val { font-family: var(--font-display); font-size: 1.5rem; font-weight: 600; }
.lb-card .login-link { color: var(--accent); cursor: pointer; }
.lb-card .login-link:hover { color: var(--accent-soft); }
.lb-note { text-align: center; margin-top: 18px; color: var(--text-faint); font-size: 0.82rem; }

.lb-table { border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--border); padding: 14px; box-shadow: var(--shadow); }
.lb-row { display: grid; grid-template-columns: 56px 1fr 90px 140px; align-items: center; gap: 12px; padding: 15px 16px; border-radius: var(--r); transition: background 0.2s ease; }
.lb-row.head { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-faint); font-weight: 600; }
.lb-row:not(.head):hover { background: var(--surface); }
#lb-rows .lb-row + .lb-row { border-top: 1px solid var(--border); }
.col-rank { font-family: var(--font-display); font-weight: 700; font-size: 1.05rem; color: var(--text-faint); }
.col-player { display: flex; align-items: center; gap: 12px; font-weight: 600; }
.col-level { text-align: center; color: var(--text-muted); font-variant-numeric: tabular-nums; }
.col-balance { text-align: right; color: var(--text); font-weight: 700; font-variant-numeric: tabular-nums; }
.avatar { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; font-family: var(--font-display); font-weight: 700; font-size: 0.95rem; color: var(--text); background: var(--surface-2); border: 1px solid var(--border); flex-shrink: 0; }
.rank-1 .col-rank { color: var(--accent); }
.rank-1 .avatar { border-color: var(--accent-ring); color: var(--accent); }
.rank-2 .col-rank { color: #d4d4d8; }
.rank-3 .col-rank { color: #a1a1aa; }

/* ---------- Download ---------- */
.download-wrap { max-width: 780px; margin: 0 auto; text-align: center; }
.launcher-card { padding: 32px; border-radius: var(--r-xl); background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow); margin-bottom: 26px; }
.launcher-preview { border-radius: var(--r); margin-bottom: 26px; width: 100%; box-shadow: var(--shadow); }
.launcher-card p { color: var(--text-muted); margin-bottom: 26px; }
.launcher-meta { display: flex; justify-content: center; flex-wrap: wrap; gap: 24px; margin-top: 28px; color: var(--text-faint); font-size: 0.85rem; }
.launcher-meta span { display: inline-flex; align-items: center; gap: 7px; }
.launcher-meta svg { width: 15px; height: 15px; color: var(--accent); }
.help-banner { display: inline-flex; align-items: center; gap: 8px; padding: 14px 24px; border-radius: var(--r-pill); background: var(--surface); border: 1px solid var(--border); color: var(--text-muted); font-size: 0.95rem; }
.help-banner a { color: var(--accent); font-weight: 600; }
.help-banner a:hover { color: var(--accent-soft); }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
    .nav-toggle { display: flex; order: 3; }
    .header-inner { gap: 14px; }
    .brand { flex: 1; }
    .main-nav { position: absolute; top: var(--header-h); left: 0; right: 0; flex-direction: column; gap: 4px; padding: 14px; background: #0c0c0e; border-bottom: 1px solid var(--border); box-shadow: 0 20px 40px -16px rgba(0,0,0,0.8); transform: translateY(-12px); opacity: 0; pointer-events: none; transition: opacity 0.2s ease, transform 0.2s ease; }
    .main-nav.open { transform: translateY(0); opacity: 1; pointer-events: auto; }
    .main-nav a { width: 100%; padding: 12px 16px; }
    .main-nav a.active::after { display: none; }
    .header-actions { order: 2; }
    .lb-cards { grid-template-columns: 1fr; }
    .steps-grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
    .section { padding: 90px 0; }
    .section-head { margin-bottom: 52px; }
    .btn-signin, .status-pill .status-label, .user-name { display: none; }
    .status-pill { padding: 7px 11px; }
    .join-bar { flex-direction: column; width: 100%; max-width: 350px; }
    .join-bar .btn { width: 100%; }
    .ip-copy { align-items: center; text-align: center; }
    .field-row { flex-direction: column; gap: 0; }
    .modal-box { padding: 28px 22px; }
    .lb-row { grid-template-columns: 40px 1fr 110px; }
    .col-level { display: none; }
    .store-banner { padding: 56px 24px; }
}

/* ---------- Motion ---------- */
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: translateY(0); } }
.rise { animation: rise 0.7s ease both; }
.rise-1 { animation-delay: 0.07s; }
.rise-2 { animation-delay: 0.14s; }
.rise-3 { animation-delay: 0.21s; }
.rise-4 { animation-delay: 0.28s; }

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; scroll-behavior: auto !important; }
    #petals, .hero-orb { display: none; }
    .js [data-reveal] { opacity: 1; transform: none; }
}
