/* Shinobi Saga — public site design system */

@import url('https://fonts.googleapis.com/css2?family=Rajdhani:wght@500;600;700&family=Source+Sans+3:ital,wght@0,400;0,500;0,600;0,700;1,400&display=swap');

:root {
    --bg-void: #080706;
    --bg: #100e0c;
    --bg-elevated: #1a1612;
    --panel: #221c17;
    --panel-hover: #2a231c;
    --line: #3a3228;
    --line-bright: #5c4f3d;
    --text: #f4ebe0;
    --text-soft: #c9bfb0;
    --muted: #8f8478;
    --gold: #e4b04a;
    --gold-bright: #f5cc6a;
    --gold-dim: #9a7328;
    --crimson: #c93c35;
    --crimson-bright: #ef5a52;
    --ember: #e8783a;
    --jade: #4fa87a;
    --jade-dim: #2d6b4f;
    --scroll: #f0e4cc;
    --shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
    --glow-gold: 0 0 24px rgba(228, 176, 74, 0.22);
    --glow-crimson: 0 0 20px rgba(201, 60, 53, 0.25);
    --radius: 6px;
    --radius-lg: 12px;
    --font-display: 'Rajdhani', 'Segoe UI', sans-serif;
    --font-body: 'Source Sans 3', system-ui, sans-serif;
    --header-h: 4.25rem;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
    min-height: 100dvh;
    font-family: var(--font-body);
    font-size: 1rem;
    background: var(--bg-void);
    color: var(--text);
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -2;
    background:
        radial-gradient(ellipse 80% 50% at 50% -10%, rgba(201, 60, 53, 0.12), transparent 55%),
        radial-gradient(ellipse 60% 40% at 100% 50%, rgba(228, 176, 74, 0.06), transparent 50%),
        linear-gradient(180deg, var(--bg-void) 0%, var(--bg) 40%, #0d0b09 100%);
    pointer-events: none;
}

body::after {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    opacity: 0.035;
    background-image: url("https://www.transparenttextures.com/patterns/asfalt-dark.png");
    pointer-events: none;
}

a { color: inherit; text-decoration: none; }

img { max-width: 100%; height: auto; display: block; }

.container {
    width: min(1140px, 100%);
    margin: 0 auto;
    padding: 0 clamp(1rem, 4vw, 1.75rem);
}

/* Icons (Game Icons via Iconify) */
iconify-icon.gi {
    display: inline-block;
    vertical-align: -0.15em;
    font-size: 1.15em;
    color: var(--gold);
}
iconify-icon.gi-sm { font-size: 1em; }
iconify-icon.gi-lg { font-size: 1.45em; }
iconify-icon.gi-crimson { color: var(--crimson-bright); }
iconify-icon.gi-muted { color: var(--muted); }

/* Header */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    height: var(--header-h);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0 clamp(1rem, 4vw, 1.75rem);
    background: rgba(8, 7, 6, 0.82);
    backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--line);
}

.site-header::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--gold-dim), var(--crimson), var(--gold-dim), transparent);
    opacity: 0.55;
}

.brand {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    text-decoration: none;
}

.brand img {
    height: 38px;
    width: auto;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.5));
}

.brand-text {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.15rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--scroll);
    line-height: 1;
}

.brand-text span {
    display: block;
    font-size: 0.62rem;
    letter-spacing: 0.28em;
    color: var(--gold);
    margin-top: 0.15rem;
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 0.35rem 1.1rem;
}

.site-nav a.nav-link {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 0.8rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--text-soft);
    padding: 0.35rem 0;
    transition: color 0.2s;
}

.site-nav a.nav-link:hover { color: var(--gold-bright); }

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    padding: 0.7rem 1.25rem;
    border-radius: var(--radius);
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 0.88rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: transform 0.15s, box-shadow 0.2s, background 0.2s, border-color 0.2s;
}

.btn:active { transform: translateY(1px); }

.btn-primary {
    background: linear-gradient(180deg, var(--crimson-bright) 0%, var(--crimson) 100%);
    color: #fff;
    box-shadow: var(--glow-crimson), inset 0 1px 0 rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 120, 100, 0.35);
}

.btn-primary:hover {
    box-shadow: 0 0 32px rgba(239, 90, 82, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.btn-gold {
    background: linear-gradient(180deg, var(--gold-bright) 0%, var(--gold) 100%);
    color: #1a1208;
    box-shadow: var(--glow-gold), inset 0 1px 0 rgba(255, 255, 255, 0.35);
    border: 1px solid rgba(255, 220, 140, 0.4);
}

.btn-outline {
    background: rgba(34, 28, 23, 0.6);
    color: var(--text);
    border: 1px solid var(--line-bright);
}

.btn-outline:hover {
    border-color: var(--gold-dim);
    color: var(--gold-bright);
    background: rgba(228, 176, 74, 0.06);
}

.btn-block { width: 100%; }

/* Panels & cards */
.panel {
    background: linear-gradient(145deg, rgba(34, 28, 23, 0.95), rgba(20, 16, 13, 0.98));
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    position: relative;
    overflow: hidden;
}

.panel::before {
    content: "";
    position: absolute;
    inset: 0 auto auto 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, var(--gold-dim), var(--gold-bright), var(--gold-dim));
    opacity: 0.7;
}

.panel-body { padding: 1.35rem 1.5rem; }

.section-label {
    font-family: var(--font-display);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 0.5rem;
}

.section-title {
    font-family: var(--font-display);
    font-size: clamp(1.35rem, 2.5vw, 1.75rem);
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--scroll);
    margin-bottom: 0.35rem;
}

.section-sub {
    color: var(--muted);
    font-size: 0.92rem;
    max-width: 38rem;
}

/* Tables */
.rank-table-wrap {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    background: var(--bg-elevated);
}

table.rank-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.86rem;
}

.rank-table th,
.rank-table td {
    padding: 0.65rem 0.85rem;
    text-align: left;
    border-bottom: 1px solid var(--line);
}

.rank-table th {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 0.68rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--muted);
    background: rgba(0, 0, 0, 0.35);
}

.rank-table tbody tr:hover td { background: rgba(228, 176, 74, 0.04); }

.rank-table tr:last-child td { border-bottom: 0; }

.rank-table .num {
    font-family: var(--font-display);
    font-weight: 700;
    color: var(--gold);
    width: 2.5rem;
}

.rank-table .rank-1 .num { color: var(--gold-bright); }
.rank-table .rank-2 .num { color: #c0c0c0; }
.rank-table .rank-3 .num { color: #cd7f32; }

.empty {
    padding: 2rem 1rem;
    color: var(--muted);
    text-align: center;
    font-size: 0.9rem;
}

/* Notices */
.notice {
    padding: 0.85rem 1.1rem;
    border-radius: var(--radius);
    border: 1px solid var(--line);
    background: var(--panel);
    color: var(--text-soft);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.notice-ok { border-color: var(--jade-dim); background: rgba(79, 168, 122, 0.08); color: #a8e6c4; }
.notice-warn { border-color: #6b5520; background: rgba(232, 120, 58, 0.08); color: #f0d4a8; }

/* Footer */
.site-footer {
    margin-top: 4rem;
    padding: 1.75rem clamp(1rem, 4vw, 1.75rem) 2.25rem;
    border-top: 1px solid var(--line);
    background: rgba(8, 7, 6, 0.9);
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: space-between;
    align-items: center;
    color: var(--muted);
    font-size: 0.82rem;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 1.25rem;
}

.footer-links a {
    color: var(--muted);
    transition: color 0.2s;
}

.footer-links a:hover { color: var(--gold); }

/* Hero (home) */
.hero {
    position: relative;
    min-height: clamp(420px, 72vh, 620px);
    display: flex;
    align-items: stretch;
    margin-bottom: 0;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 72% center;
}

.hero-bg::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(100deg, rgba(8, 7, 6, 0.88) 0%, rgba(8, 7, 6, 0.55) 38%, rgba(8, 7, 6, 0.25) 62%, rgba(16, 14, 12, 0.45) 100%),
        linear-gradient(0deg, var(--bg-void) 0%, transparent 40%);
}

.hero-inner {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    align-items: center;
    padding: clamp(2.5rem, 6vw, 4rem) clamp(1.5rem, 8vw, 5rem);
    width: 100%;
    max-width: 1240px;
    margin: 0 auto;
}

@media (min-width: 900px) {
    .hero-inner {
        grid-template-columns: 1.1fr 0.9fr;
        gap: 3rem;
        padding: clamp(3rem, 7vw, 4.5rem) clamp(2rem, 10vw, 7rem);
    }
}

.hero-copy {
    max-width: 34rem;
    margin-inline: auto;
}

@media (min-width: 900px) {
    .hero-copy {
        margin-inline: 0;
        margin-left: clamp(1.5rem, 6vw, 4.5rem);
    }
}

.hero-copy .hero-logo {
    width: min(100%, 380px);
    margin-bottom: 1.25rem;
    filter: drop-shadow(0 8px 24px rgba(0, 0, 0, 0.6));
}

.hero-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.35rem 0.75rem;
    border-radius: 999px;
    border: 1px solid var(--line-bright);
    background: rgba(201, 60, 53, 0.12);
    color: var(--crimson-bright);
    font-family: var(--font-display);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    margin-bottom: 1rem;
}

.hero-copy h1 {
    font-family: var(--font-display);
    font-size: clamp(2rem, 5vw, 3.2rem);
    font-weight: 700;
    line-height: 1.05;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--scroll);
    margin-bottom: 0.75rem;
}

.hero-copy h1 em {
    font-style: normal;
    color: var(--gold-bright);
}

.hero-copy p {
    color: var(--text-soft);
    font-size: 1.05rem;
    max-width: 32rem;
    margin-bottom: 1.5rem;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
}

.launch-panel .panel-body { padding: 1.5rem; }

@media (min-width: 900px) {
    .launch-panel {
        justify-self: end;
        max-width: 22rem;
        width: 100%;
    }
}

.launch-panel h2 {
    font-family: var(--font-display);
    font-size: 0.75rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 1rem;
}

.launch-grid {
    display: grid;
    gap: 0.55rem;
}

/* Feature strip */
.features {
    padding: 2.5rem 0;
    border-bottom: 1px solid var(--line);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.85rem;
}

@media (min-width: 720px) {
    .features-grid { grid-template-columns: repeat(4, 1fr); }
}

.feature-card {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 1rem;
    border-radius: var(--radius);
    border: 1px solid var(--line);
    background: var(--bg-elevated);
    text-decoration: none;
    color: inherit;
    transition: border-color 0.2s, transform 0.15s, background 0.2s;
}

.feature-card:hover {
    border-color: var(--gold-dim);
    background: var(--panel);
    transform: translateY(-2px);
}

.feature-card iconify-icon {
    font-size: 1.65rem;
    color: var(--gold);
}

.feature-card strong {
    font-family: var(--font-display);
    font-size: 0.88rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.feature-card span {
    font-size: 0.78rem;
    color: var(--muted);
    line-height: 1.35;
}

/* Rankings */
.rankings-section {
    padding: 2.75rem 0 3rem;
}

.rankings-head {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

.rankings-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.25rem;
}

@media (min-width: 900px) {
    .rankings-grid { grid-template-columns: 1fr 1fr; }
}

.rank-panel h3 {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    font-family: var(--font-display);
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 0.65rem;
}

/* Page shell (inner pages) */
.page-hero {
    position: relative;
    padding: 2.5rem 0 2rem;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid var(--line);
    overflow: hidden;
}

.page-hero-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
    opacity: 0.22;
}

.page-hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.page-hero-bg::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent, var(--bg-void));
}

.page-hero .container { position: relative; z-index: 1; }

.page-shell { padding: 0 0 3rem; }

@media (max-width: 720px) {
    .site-nav .hide-sm { display: none; }
    .brand-text { display: none; }
}
