/* LoreRaid Network - Dark Gamer Theme */

:root {
    --bg-main: #121212;
    --bg-card: #1a1a1a;
    --accent: #e10600;
    --accent-soft: rgba(225, 6, 0, 0.2);
    --text-main: #ffffff;
    --text-muted: #b3b3b3;
    --border-subtle: #2a2a2a;
    --radius-lg: 14px;
    --radius-md: 10px;
    --shadow-soft: 0 0 25px rgba(0, 0, 0, 0.7);
    --shadow-glow: 0 0 18px rgba(225, 6, 0, 0.6);
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html, body {
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Rajdhani', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: radial-gradient(circle at top, #1b1b1b 0, #050505 60%) fixed;
    color: var(--text-main);
    min-height: 100vh;
}

a {
    color: var(--accent);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

.lrn-main {
    max-width: 1200px;
    margin: 90px auto 40px;
    padding: 0 16px 40px;
}

/* Header & Navigation */

.lrn-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(10, 10, 10, 0.96);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(225, 6, 0, 0.35);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.7);
}

.lrn-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
    padding: 10px 16px;
    gap: 16px;
}

.lrn-logo {
    display: flex;
    flex-direction: column;
    line-height: 1;
    text-transform: uppercase;
}

.logo-main {
    font-weight: 700;
    letter-spacing: 2px;
    color: #fff;
}

.logo-sub {
    font-weight: 600;
    font-size: 0.8rem;
    color: var(--accent);
    letter-spacing: 4px;
}

.lrn-nav {
    flex: 1;
}

.lrn-nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: center;
    gap: 18px;
}

.lrn-nav a {
    color: var(--text-muted);
    font-weight: 600;
    letter-spacing: 0.06em;
    font-size: 0.9rem;
    position: relative;
    text-transform: uppercase;
}

.lrn-nav a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -4px;
    width: 0;
    height: 2px;
    background: var(--accent);
    box-shadow: 0 0 10px rgba(225, 6, 0, 0.8);
    transition: width 0.2s ease-out;
}

.lrn-nav a:hover::after {
    width: 100%;
}

.lrn-header-search {
    display: flex;
    align-items: center;
}

.lrn-header-search input {
    background: #0b0b0b;
    border-radius: 999px;
    border: 1px solid var(--border-subtle);
    padding: 6px 12px;
    color: #fff;
    font-size: 0.85rem;
    min-width: 180px;
}

.lrn-header-search input::placeholder {
    color: #777;
}

.lrn-nav-toggle {
    display: none;
    flex-direction: column;
    gap: 4px;
    background: none;
    border: none;
    cursor: pointer;
}

.lrn-nav-toggle span {
    width: 20px;
    height: 2px;
    background: var(--text-main);
    border-radius: 999px;
}

/* Hero */

.lrn-hero {
    margin-top: 24px;
    margin-bottom: 32px;
    background: radial-gradient(circle at top left, rgba(225, 6, 0, 0.4), transparent 60%), #121212;
    border-radius: 24px;
    padding: 32px 24px;
    box-shadow: var(--shadow-soft);
    border: 1px solid rgba(255, 255, 255, 0.03);
}

.lrn-hero-content h1 {
    font-size: clamp(2.4rem, 4vw, 3rem);
    margin: 0 0 8px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.lrn-hero-content h1 span {
    color: var(--accent);
    text-shadow: var(--shadow-glow);
}

.lrn-hero-content p {
    margin: 0 0 18px;
    color: var(--text-muted);
    max-width: 420px;
}

.lrn-hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.btn-primary,
.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 9px 18px;
    border-radius: 999px;
    font-weight: 700;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    border: 1px solid transparent;
    cursor: pointer;
    transition: transform 0.12s ease-out, box-shadow 0.12s ease-out, background 0.12s ease-out, border-color 0.12s ease-out;
}

.btn-primary {
    background: var(--accent);
    box-shadow: var(--shadow-glow);
    color: #fff;
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 0 25px rgba(225, 6, 0, 0.9);
    text-decoration: none;
}

.btn-secondary {
    background: transparent;
    border-color: var(--accent);
    color: var(--accent);
}

.btn-secondary:hover {
    background: var(--accent-soft);
    text-decoration: none;
}

/* Sections & Cards */

.lrn-section {
    margin-bottom: 32px;
}

.lrn-section-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    margin-bottom: 12px;
}

.lrn-section-header h2 {
    margin: 0;
    font-size: 1.3rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.section-link {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.lrn-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 16px;
}

.lrn-card {
    background: radial-gradient(circle at top, #262626 0, var(--bg-card) 60%);
    border-radius: var(--radius-lg);
    padding: 16px 16px 14px;
    border: 1px solid rgba(255, 255, 255, 0.03);
    box-shadow: var(--shadow-soft);
    position: relative;
    overflow: hidden;
    transition: transform 0.12s ease-out, box-shadow 0.12s ease-out, border-color 0.12s ease-out;
}

.lrn-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at top, rgba(225, 6, 0, 0.12), transparent 55%);
    opacity: 0;
    transition: opacity 0.18s ease-out;
}

.lrn-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-glow);
    border-color: rgba(225, 6, 0, 0.4);
}

.lrn-card:hover::before {
    opacity: 1;
}

.lrn-card h3 {
    margin: 0 0 6px;
    font-size: 1.05rem;
}

.lrn-card-meta {
    font-size: 0.78rem;
    color: var(--text-muted);
    margin: 0 0 8px;
    text-transform: uppercase;
    letter-spacing: 0.15em;
}

.lrn-card p {
    font-size: 0.9rem;
    color: #ddd;
}

.fandom-grid .fandom-banner {
    border-radius: var(--radius-md);
    overflow: hidden;
    margin-bottom: 10px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.fandom-grid img {
    display: block;
    width: 100%;
    height: 140px;
    object-fit: cover;
}

.fandom-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 140px;
    background: linear-gradient(135deg, #262626, #1a1a1a);
    color: var(--text-muted);
    font-weight: 600;
}

/* Guide directory */

.guide-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
    margin-bottom: 12px;
}

.guide-filters input[type="search"],
.guide-filters select {
    background: #0b0b0b;
    border-radius: 999px;
    border: 1px solid var(--border-subtle);
    padding: 6px 12px;
    color: #fff;
    font-size: 0.85rem;
}

.az-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 14px;
}

.az-nav a,
.az-nav span {
    width: 24px;
    height: 24px;
    border-radius: 999px;
    font-size: 0.75rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-transform: uppercase;
    border: 1px solid var(--border-subtle);
    color: var(--text-muted);
}

.az-nav a.active {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
    box-shadow: var(--shadow-glow);
}

.pagination {
    margin-top: 16px;
    display: flex;
    justify-content: center;
    gap: 6px;
}

.pagination a,
.pagination span {
    padding: 4px 9px;
    border-radius: 999px;
    border: 1px solid var(--border-subtle);
    font-size: 0.8rem;
}

.pagination span.current {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

/* Guide & Lore detail */

.breadcrumbs {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.breadcrumbs a {
    color: var(--text-muted);
}

.guide-header h1,
.lore-header h1 {
    margin: 0 0 4px;
}

.guide-meta,
.lore-meta {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 0.12em;
}

.guide-layout {
    display: grid;
    grid-template-columns: minmax(0, 3fr) minmax(0, 1.1fr);
    gap: 20px;
}

.guide-body,
.lore-body {
    background: #111;
    border-radius: var(--radius-lg);
    padding: 16px 18px;
    border: 1px solid var(--border-subtle);
}

.guide-body h2,
.guide-body h3,
.lore-body h2,
.lore-body h3 {
    margin-top: 18px;
}

.guide-body p,
.lore-body p {
    line-height: 1.6;
    color: #e1e1e1;
}

.toc {
    background: #111;
    border-radius: var(--radius-lg);
    padding: 14px 16px;
    border: 1px solid var(--border-subtle);
    position: sticky;
    top: 90px;
}

.toc h3 {
    margin-top: 0;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.14em;
}

.toc ul {
    list-style: none;
    padding-left: 0;
    margin: 0;
    font-size: 0.85rem;
}

.toc li {
    margin-bottom: 4px;
}

.toc li.toc-h3 {
    padding-left: 14px;
    font-size: 0.8rem;
}

/* Lore grid filters */

.lore-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 14px;
}

/* Fandom page */

.fandom-hero {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1.8fr);
    gap: 20px;
    margin-bottom: 20px;
}

.fandom-hero-banner {
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.06);
    box-shadow: var(--shadow-soft);
}

.fandom-hero-banner img {
    display: block;
    width: 100%;
    height: 220px;
    object-fit: cover;
}

.fandom-hero-info {
    background: #101010;
    border-radius: var(--radius-lg);
    padding: 16px 18px;
    border: 1px solid var(--border-subtle);
}

.fandom-hero-info h1 {
    margin-top: 0;
}

/* Search */

.search-results-group {
    margin-bottom: 20px;
}

.search-results-group h2 {
    margin-bottom: 8px;
}

/* Footer */

.lrn-footer {
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    background: #050505;
}

.lrn-footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 18px 16px 26px;
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    align-items: center;
    justify-content: space-between;
    color: var(--text-muted);
    font-size: 0.83rem;
}

.lrn-footer-brand p {
    margin: 4px 0 0;
}

.lrn-footer-links {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.lrn-footer-links a {
    color: var(--text-muted);
    font-size: 0.82rem;
}

.lrn-footer-meta {
    text-align: right;
}

/* Admin */

.admin-wrapper {
    max-width: 1080px;
    margin: 40px auto;
    padding: 0 16px 40px;
}

.admin-card {
    background: #101010;
    border-radius: var(--radius-lg);
    padding: 16px 18px;
    border: 1px solid var(--border-subtle);
    box-shadow: var(--shadow-soft);
}

.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.admin-nav a {
    margin-right: 8px;
    font-size: 0.85rem;
}

.admin-nav a.active {
    color: var(--accent);
    font-weight: 600;
}

.admin-muted {
    display: block;
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 4px;
}

table.admin-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
}

table.admin-table th,
table.admin-table td {
    border-bottom: 1px solid var(--border-subtle);
    padding: 6px 4px;
    text-align: left;
}

table.admin-table th {
    font-weight: 600;
}

form.admin-form {
    display: grid;
    gap: 10px;
}

form.admin-form label {
    font-size: 0.85rem;
    font-weight: 600;
}

form.admin-form input[type="text"],
form.admin-form input[type="password"],
form.admin-form textarea,
form.admin-form select {
    width: 100%;
    background: #050505;
    border-radius: 6px;
    border: 1px solid var(--border-subtle);
    color: #fff;
    padding: 6px 8px;
    font-size: 0.9rem;
}

form.admin-form textarea {
    min-height: 160px;
    font-family: inherit;
}

.flash {
    padding: 8px 10px;
    border-radius: 6px;
    font-size: 0.85rem;
    margin-bottom: 10px;
}

.flash-error {
    background: rgba(225, 6, 0, 0.15);
    border: 1px solid rgba(225, 6, 0, 0.4);
}

.flash-success {
    background: rgba(0, 170, 80, 0.15);
    border: 1px solid rgba(0, 170, 80, 0.4);
}

/* Responsive */

@media (max-width: 900px) {
    .guide-layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .toc {
        position: static;
        margin-top: 14px;
    }

    .fandom-hero {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media (max-width: 768px) {
    .lrn-header-inner {
        align-items: center;
    }

    .lrn-nav-toggle {
        display: flex;
    }

    .lrn-nav {
        position: absolute;
        left: 0;
        right: 0;
        top: 100%;
        background: #050505;
        border-bottom: 1px solid var(--border-subtle);
        display: none;
    }

    .lrn-nav.open {
        display: block;
    }

    .lrn-nav ul {
        flex-direction: column;
        align-items: flex-start;
        padding: 8px 16px 12px;
    }

    .lrn-header-search {
        display: none;
    }
}

/* About page */

.lrn-about .lrn-section-header h1 {
    margin: 0;
    font-size: 1.75rem;
    font-weight: 700;
}

.lrn-about-content {
    max-width: 720px;
}

.lrn-about-content .lrn-lead {
    font-size: 1.1rem;
    line-height: 1.6;
    color: var(--text-muted);
    margin-bottom: 24px;
}

.lrn-about-content h2 {
    font-size: 1.15rem;
    margin: 24px 0 10px;
    color: var(--text-main);
}

.lrn-about-content p {
    line-height: 1.65;
    color: var(--text-muted);
    margin: 0 0 12px;
}

.lrn-about-list {
    margin: 0 0 16px;
    padding-left: 1.4em;
    color: var(--text-muted);
    line-height: 1.65;
}

.lrn-about-list li {
    margin-bottom: 10px;
}

.lrn-about-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 28px;
}

