@import url('https://fonts.googleapis.com/css2?family=Sora:wght@600;700;800&family=Inter:wght@400;500;600;700&family=Roboto+Mono:wght@500;600&display=swap');

:root {
    /* StreamNova Dark - exact palette per design spec */
    --void: #080b14;
    --surface-1: #0d111f;
    --surface-2: #131827;
    --surface-3: #191f31;
    --surface-4: #21283b;
    --border: #232a3d;
    --border-soft: #232a3d66;

    --text-hi: #ffffff;
    --text-mid: #94a3b8;
    --text-low: #64748b;

    --violet: #8b5cf6;
    --violet-dim: #8b5cf622;
    --cyan: #22d3ee;
    --cyan-dim: #22d3ee22;
    --coral: #ff3347;
    --coral-dim: #ff334722;
    --amber: #f59e0b;
    --amber-dim: #f59e0b22;
    --green: #22c55e;
    --green-dim: #22c55e22;
    --blue: #3b82f6;

    --radius-sm: 10px;
    --radius: 14px;
    --radius-lg: 18px;

    --shadow-tile: 0 1px 0 rgba(255,255,255,0.03) inset, 0 12px 24px -8px rgba(0,0,0,0.55), 0 2px 6px rgba(0,0,0,0.35);
    --shadow-tile-hover: 0 1px 0 rgba(255,255,255,0.05) inset, 0 20px 40px -12px rgba(0,0,0,0.65), 0 4px 10px rgba(0,0,0,0.4);
    --shadow-pop: 0 24px 60px -16px rgba(0,0,0,0.7), 0 4px 16px rgba(0,0,0,0.45);
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: 'Inter', -apple-system, sans-serif;
    background:
        radial-gradient(ellipse 900px 500px at 15% -10%, #3b82f614, transparent),
        radial-gradient(ellipse 700px 500px at 100% 10%, #8b5cf612, transparent),
        var(--void);
    color: var(--text-hi);
    min-height: 100vh;
}

h1, h2, h3, .display {
    font-family: 'Sora', sans-serif;
    font-weight: 700;
    letter-spacing: -0.01em;
    margin: 0;
}

.mono { font-family: 'Roboto Mono', monospace; font-weight: 500; }

a { color: inherit; }

/* ---------- Top navigation ---------- */
.topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 32px;
    background: linear-gradient(180deg, #10131ecc, #10131e99);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-soft);
    position: sticky;
    top: 0;
    z-index: 50;
}

.brand {
    font-family: 'Sora', sans-serif;
    font-weight: 700;
    font-size: 20px;
    letter-spacing: -0.01em;
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.brand .mark {
    width: 26px; height: 26px;
    border-radius: 7px;
    background: linear-gradient(135deg, var(--blue), var(--violet));
    display: grid;
    place-items: center;
    box-shadow: 0 0 0 1px #ffffff14 inset, 0 4px 12px -2px #7c5cfc66;
}
.brand .mark::before {
    content: '';
    width: 10px; height: 10px;
    border-radius: 2px;
    background: #0a0c14;
}

.brand span { color: var(--cyan); }
.brand .admin-tag { color: var(--text-low); font-weight: 500; font-size: 14px; margin-left: 4px; }

.nav-actions { display: flex; gap: 10px; align-items: center; }

.container { max-width: 1180px; margin: 0 auto; padding: 40px 32px; }

/* ---------- Tiles (the signature element) ---------- */
.grid { display: grid; gap: 18px; }
.grid.cols-2 { grid-template-columns: 1fr 1fr; }
.grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.grid.cols-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 860px) {
    .grid.cols-2, .grid.cols-3, .grid.cols-4 { grid-template-columns: 1fr; }
}

.tile {
    position: relative;
    background: linear-gradient(160deg, var(--surface-3), var(--surface-2));
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 22px;
    box-shadow: var(--shadow-tile);
    transition: transform .25s cubic-bezier(.2,.8,.2,1), box-shadow .25s ease, border-color .25s ease;
}
.tile:hover {
    transform: translateY(-3px) scale(1.008);
    box-shadow: var(--shadow-tile-hover);
    border-color: #363c54;
}
.tile.flush { padding: 0; overflow: hidden; }

.tile-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 4px; }

.tile h3 { font-size: 15px; color: var(--text-mid); font-weight: 600; letter-spacing: -0.005em; font-family: 'Inter', sans-serif; }
.tile .stat { font-family: 'Sora', sans-serif; font-size: 30px; font-weight: 700; margin-top: 6px; letter-spacing: -0.02em; }

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 20px;
    border-radius: var(--radius-sm);
    border: none;
    background: linear-gradient(160deg, #8a6bff, var(--violet));
    color: white;
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    box-shadow: 0 1px 0 #ffffff33 inset, 0 8px 20px -6px #7c5cfc80;
    transition: transform .15s ease, box-shadow .15s ease, filter .15s ease;
}
.btn:hover { transform: translateY(-1px); filter: brightness(1.08); }
.btn:active { transform: translateY(0px); }

.btn.danger { background: linear-gradient(160deg, #ff7a8c, var(--coral)); box-shadow: 0 1px 0 #ffffff33 inset, 0 8px 20px -6px #ff5d7380; }
.btn.secondary {
    background: var(--surface-3);
    color: var(--text-hi);
    border: 1px solid var(--border);
    box-shadow: 0 1px 0 #ffffff0d inset;
}
.btn.secondary:hover { background: var(--surface-4); }
.btn.small { padding: 7px 14px; font-size: 12.5px; }
.btn.ghost { background: transparent; box-shadow: none; color: var(--text-mid); }
.btn.ghost:hover { color: var(--text-hi); background: var(--surface-2); }

/* ---------- Forms ---------- */
input, select {
    width: 100%;
    padding: 12px 14px;
    background: var(--surface-1);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-hi);
    font-size: 14px;
    font-family: 'Inter', sans-serif;
    margin-bottom: 14px;
    transition: border-color .15s ease, box-shadow .15s ease;
}
input:focus, select:focus {
    outline: none;
    border-color: var(--violet);
    box-shadow: 0 0 0 3px var(--violet-dim);
}
input::placeholder { color: var(--text-low); }
label { font-size: 12.5px; color: var(--text-mid); display: block; margin-bottom: 7px; font-weight: 500; text-transform: uppercase; letter-spacing: 0.04em; }

/* ---------- Tables ---------- */
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { text-align: left; padding: 13px 14px; border-bottom: 1px solid var(--border-soft); }
th { color: var(--text-low); font-weight: 600; font-size: 11px; text-transform: uppercase; letter-spacing: 0.06em; }
tr:hover td { background: #ffffff03; }

/* ---------- Badges ---------- */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 11px;
    border-radius: 20px;
    font-size: 11.5px;
    font-weight: 600;
    letter-spacing: 0.02em;
}
.badge::before { content: ''; width: 6px; height: 6px; border-radius: 50%; }
.badge.running { background: var(--green-dim); color: var(--green); }
.badge.running::before { background: var(--green); box-shadow: 0 0 8px var(--green); animation: pulse-dot 1.6s ease-in-out infinite; }
.badge.stopped { background: var(--surface-3); color: var(--text-mid); }
.badge.stopped::before { background: var(--text-low); }
.badge.banned { background: var(--coral-dim); color: var(--coral); }
.badge.banned::before { background: var(--coral); }
.badge.active { background: var(--green-dim); color: var(--green); }
.badge.active::before { background: var(--green); }
.badge.scheduled { background: var(--amber-dim); color: var(--amber); }
.badge.scheduled::before { background: var(--amber); }

@keyframes pulse-dot {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.35; }
}

/* ---------- Tabs ---------- */
.tabs { display: flex; gap: 4px; margin-bottom: 28px; border-bottom: 1px solid var(--border-soft); }
.tab {
    padding: 12px 4px;
    margin-right: 24px;
    cursor: pointer;
    color: var(--text-mid);
    font-weight: 600;
    font-size: 14.5px;
    border-bottom: 2px solid transparent;
    transition: color .15s ease;
}
.tab:hover { color: var(--text-hi); }
.tab.active { color: var(--text-hi); border-bottom-color: var(--violet); }

.section { display: none; }
.section.active { display: block; animation: fade-up .35s ease; }
@keyframes fade-up { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: translateY(0); } }

/* ---------- Plan tiles ---------- */
.plan-tile {
    position: relative;
    border-radius: var(--radius);
    padding: 24px;
    background: linear-gradient(160deg, var(--surface-3), var(--surface-2));
    border: 1px solid var(--border);
    box-shadow: var(--shadow-tile);
    transition: transform .25s ease, box-shadow .25s ease;
}
.plan-tile:hover { transform: translateY(-4px); box-shadow: var(--shadow-tile-hover); }
.plan-tile.featured { border-color: var(--violet); box-shadow: 0 1px 0 rgba(255,255,255,0.06) inset, 0 20px 50px -14px #7c5cfc55; }
.plan-tile .eyebrow { font-size: 11px; color: var(--text-low); text-transform: uppercase; letter-spacing: 0.08em; font-weight: 600; }
.plan-tile .featured-tag {
    position: absolute; top: -11px; left: 20px;
    background: linear-gradient(135deg, var(--blue), var(--violet));
    color: white; font-size: 11px; font-weight: 700; padding: 4px 12px; border-radius: 20px;
}
.plan-tile .price { font-family: 'Sora', sans-serif; font-size: 34px; font-weight: 700; margin: 10px 0 4px; letter-spacing: -0.02em; }
.plan-tile .price span { font-size: 13px; color: var(--text-low); font-weight: 500; }
.plan-tile .feature-line { font-size: 13.5px; color: var(--text-mid); margin: 0 0 14px; }

/* ---------- Empty state ---------- */
.empty { color: var(--text-low); text-align: center; padding: 60px 20px; font-size: 14.5px; }
.empty-icon { font-size: 32px; margin-bottom: 10px; opacity: 0.5; }

/* ---------- Auth card ---------- */
.auth-wrap { min-height: calc(100vh - 74px); display: flex; align-items: center; justify-content: center; padding: 40px 20px; }
.auth-card {
    width: 100%; max-width: 400px;
    background: linear-gradient(160deg, var(--surface-3), var(--surface-2));
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 34px;
    box-shadow: var(--shadow-pop);
}

/* ---------- Modal ---------- */
.modal-backdrop {
    position: fixed; inset: 0; background: #05060acc; backdrop-filter: blur(6px);
    display: flex; align-items: center; justify-content: center; z-index: 100;
}
.modal {
    width: 380px;
    background: linear-gradient(160deg, var(--surface-3), var(--surface-2));
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 26px;
    box-shadow: var(--shadow-pop);
}

/* ---------- Landing page specific ---------- */
.hero { padding: 90px 32px 60px; max-width: 1180px; margin: 0 auto; text-align: center; }
.hero .eyebrow {
    display: inline-flex; align-items: center; gap: 8px;
    background: var(--surface-2); border: 1px solid var(--border);
    padding: 7px 16px; border-radius: 20px; font-size: 12.5px; color: var(--text-mid); font-weight: 600;
    margin-bottom: 26px;
}
.hero .eyebrow .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--green); box-shadow: 0 0 8px var(--green); animation: pulse-dot 1.6s ease-in-out infinite; }
.hero h1 { font-size: 58px; line-height: 1.05; max-width: 820px; margin: 0 auto 20px; }
.hero h1 .grad { background: linear-gradient(135deg, var(--blue), var(--violet)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero p.lead { font-size: 18px; color: var(--text-mid); max-width: 560px; margin: 0 auto 34px; line-height: 1.6; }
.hero .cta-row { display: flex; gap: 14px; justify-content: center; }
@media (max-width: 640px) { .hero h1 { font-size: 38px; } }

/* Tile wall - signature hero visual */
.tile-wall {
    display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px;
    max-width: 980px; margin: 60px auto 0; perspective: 1400px;
}
.tile-wall .cell {
    aspect-ratio: 16/10; border-radius: 10px;
    background: linear-gradient(160deg, var(--surface-3), var(--surface-1));
    border: 1px solid var(--border);
    transform: rotateX(6deg);
    transition: transform .3s ease, box-shadow .3s ease;
    position: relative; overflow: hidden;
}
.tile-wall .cell.live { box-shadow: 0 0 0 1px var(--cyan-dim), 0 0 24px -4px #2dd9e866; }
.tile-wall .cell.live::after {
    content: ''; position: absolute; top: 8px; left: 8px; width: 7px; height: 7px; border-radius: 50%;
    background: var(--coral); box-shadow: 0 0 8px var(--coral); animation: pulse-dot 1.4s ease-in-out infinite;
}
.tile-wall .cell:hover { transform: rotateX(0deg) translateY(-4px); }

.section-block { max-width: 1180px; margin: 0 auto; padding: 70px 32px; }
.section-block h2 { font-size: 34px; text-align: center; margin-bottom: 12px; }
.section-block .sub { text-align: center; color: var(--text-mid); font-size: 16px; margin-bottom: 50px; }

.feature-tile { padding: 26px; }
.feature-tile .icon-badge {
    width: 42px; height: 42px; border-radius: 11px;
    display: grid; place-items: center; font-size: 19px;
    background: linear-gradient(135deg, var(--violet-dim), var(--cyan-dim));
    border: 1px solid var(--border);
    margin-bottom: 16px;
}
.feature-tile h3 { color: var(--text-hi); font-size: 16px; margin-bottom: 8px; font-family: 'Sora', sans-serif; }
.feature-tile p { color: var(--text-mid); font-size: 14px; line-height: 1.6; margin: 0; }

footer.site-footer {
    border-top: 1px solid var(--border-soft); padding: 32px; text-align: center;
    color: var(--text-low); font-size: 13px; margin-top: 40px;
}

.metric-row { display: flex; gap: 24px; color: var(--text-low); font-size: 12.5px; margin-top: 10px; }
