/* ─── Reset & Variables ────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --bg:           #0b0b0b;
    --surface:      #161616;
    --surface-2:    #1e1e1e;
    --surface-3:    #272727;
    --border:       #2c2c2c;
    --border-hover: #3d3d3d;
    --text:         #e8e8e8;
    --text-muted:   #6e6e6e;
    --text-dim:     #484848;
    --accent:       #c0392b;
    --accent-hover: #e74c3c;
    --accent-dim:   rgba(192,57,43,0.12);
    --green:        #2ecc71;
    --green-dim:    rgba(46,204,113,0.12);
    --yellow:       #f39c12;
    --yellow-dim:   rgba(243,156,18,0.12);
    --blue:         #4a9edd;
    --blue-dim:     rgba(74,158,221,0.12);
    --gray-dim:     rgba(120,120,140,0.12);
    --note-bg:      rgba(243,156,18,0.06);
    --note-border:  rgba(243,156,18,0.35);
    --note-text:    #c89b3c;
    --radius:       6px;
    --radius-lg:    10px;
    --shadow-sm:    0 1px 4px rgba(0,0,0,0.6);
    --shadow:       0 4px 24px rgba(0,0,0,0.7);
    --shadow-lg:    0 8px 48px rgba(0,0,0,0.8);
    --transition:   0.18s cubic-bezier(0.4, 0, 0.2, 1);
    --font:         'Inter', system-ui, -apple-system, sans-serif;
    --font-display: 'Rajdhani', 'Inter', system-ui, sans-serif;
    --font-mono:    'JetBrains Mono', 'Fira Code', monospace;
}

/* ─── Skip to Content ─────────────────────────────────────────────────────── */
.skip-link {
    position: absolute;
    top: -100%;
    left: 12px;
    z-index: 9999;
    background: var(--accent);
    color: #fff;
    font-size: 0.875rem;
    font-weight: 600;
    padding: 10px 18px;
    border-radius: 0 0 var(--radius) var(--radius);
    text-decoration: none;
    white-space: nowrap;
    transition: top 0.15s;
}

.skip-link:focus {
    top: 0;
    outline: none;
    color: #fff;
    text-decoration: none;
}

html { scroll-behavior: smooth; }

body {
    background: var(--bg);
    color: var(--text);
    font-family: var(--font);
    font-size: 15px;
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-display);
    font-weight: 700;
    letter-spacing: 0.02em;
    line-height: 1.15;
}


@keyframes fadeUp {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}

.page-wrap {
    animation: fadeUp 0.28s var(--transition) both;
}

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); text-decoration: underline; }

/* ─── Topbar ──────────────────────────────────────────────────────────────── */
.topbar {
    background: rgba(11, 11, 11, 0.97);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(192,57,43,0.25);
    padding: 0 1.5rem;
    height: 62px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 4px 32px rgba(0,0,0,0.85), 0 1px 0 rgba(192,57,43,0.06);
}

.topbar-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}
.topbar-brand:hover {
    text-decoration: none;
}

.brand-img {
    height: 36px;
    width: 36px;
    object-fit: contain;
    border-radius: 6px;
    background: #0d0d0d;
    border: 1px solid rgba(192,57,43,0.3);
    padding: 2px;
    transition: box-shadow var(--transition);
}

/* Logo glows only when the image itself is hovered */
.brand-img:hover {
    box-shadow: 0 0 20px rgba(192,57,43,0.6), 0 0 8px rgba(192,57,43,0.25);
}

/* Text underlines only when the text label is hovered */
.topbar-brand-text:hover {
    text-decoration: underline;
    text-decoration-color: var(--accent);
    text-underline-offset: 3px;
}
.sidebar-brand-text:hover .brand-name {
    text-decoration: underline;
    text-underline-offset: 2px;
}

.brand-sub {
    font-family: var(--font-display);
    font-size: 0.7rem;
    color: var(--accent);
    letter-spacing: 0.15em;
    text-transform: uppercase;
    font-weight: 600;
}

.topbar-brand-text {
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text);
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.topbar-brand-text span {
    color: var(--accent);
}

.topbar-nav {
    display: flex;
    align-items: center;
    gap: 4px;
}

.nav-link {
    color: var(--text-muted);
    text-decoration: none;
    padding: 6px 14px;
    border-radius: var(--radius);
    font-size: 0.875rem;
    font-weight: 500;
    transition: color var(--transition), background var(--transition);
}

.nav-link:hover {
    color: var(--text);
    background: var(--surface-2);
    text-decoration: none;
}

.nav-link.active {
    color: var(--text);
    background: var(--surface-3);
}

.nav-link.admin-link {
    color: var(--accent);
    border: 1px solid rgba(192,57,43,0.3);
}

.nav-link.admin-link:hover {
    background: var(--accent-dim);
    border-color: var(--accent);
}

.topbar-user {
    display: flex;
    align-items: center;
    gap: 10px;
}

.topbar-user-link {
    text-decoration: none;
    border-radius: var(--radius);
    padding: 4px 10px 4px 4px;
    border: 1px solid transparent;
    transition: background var(--transition), border-color var(--transition);
}

.topbar-user-link:hover {
    background: rgba(255,255,255,0.05);
    border-color: rgba(192,57,43,0.3);
    text-decoration: none;
}

.topbar-user-link:hover .user-name {
    color: var(--text);
}

.user-name {
    font-size: 0.875rem;
    color: var(--text-muted);
    max-width: 160px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    transition: color var(--transition);
}

/* ─── Layout ──────────────────────────────────────────────────────────────── */
main {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.page-wrap {
    flex: 1;
    width: 100%;
    max-width: 1100px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
    animation: fadeUp 0.28s var(--transition) both;
}

.page-wrap.wide {
    max-width: 1300px;
}

/* ─── Avatars ─────────────────────────────────────────────────────────────── */
.nav-user-info {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-avatar {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--border);
    flex-shrink: 0;
    transition: border-color var(--transition), box-shadow var(--transition);
}

.nav-avatar:hover {
    border-color: var(--accent);
    box-shadow: 0 0 0 2px rgba(192,57,43,0.2);
}

.nav-avatar-fallback {
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--surface-3);
    color: var(--text-muted);
    font-size: 0.75rem;
    font-weight: 700;
}

.msg-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--border);
    flex-shrink: 0;
}

.msg-avatar-fallback {
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--surface-3);
    color: var(--text-muted);
    font-size: 0.8rem;
    font-weight: 700;
}

/* ─── Buttons ─────────────────────────────────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 18px;
    border-radius: var(--radius);
    border: 1px solid transparent;
    font-family: var(--font-display);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: background var(--transition), border-color var(--transition),
                color var(--transition), box-shadow var(--transition),
                transform var(--transition), opacity var(--transition);
    text-decoration: none;
    white-space: nowrap;
    user-select: none;
}

.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px) !important; }

.btn-primary {
    background: transparent;
    color: var(--accent);
    border: 1.5px solid var(--accent);
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    font-size: 0.82rem;
}
.btn-primary:hover {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
    box-shadow: 0 4px 20px rgba(192,57,43,0.35);
    transform: translateY(-1px);
}

.btn-secondary {
    background: var(--surface-2);
    color: var(--text);
    border-color: var(--border);
}
.btn-secondary:hover {
    background: var(--surface-3);
    border-color: var(--border-hover);
    color: var(--text);
    transform: translateY(-1px);
}

.btn-ghost {
    background: transparent;
    color: var(--text-muted);
    border-color: var(--border);
}
.btn-ghost:hover {
    background: var(--surface-2);
    border-color: var(--border-hover);
    color: var(--text);
    transform: translateY(-1px);
}

.btn-danger {
    background: transparent;
    color: #ef4444;
    border-color: rgba(239,68,68,0.3);
}
.btn-danger:hover {
    background: rgba(239,68,68,0.08);
    border-color: rgba(239,68,68,0.6);
    color: #ef4444;
    transform: translateY(-1px);
}

.btn-steam {
    background: #1b2838;
    color: #c7d5e0;
    border-color: #2a475e;
    font-size: 0.95rem;
    padding: 10px 24px;
}
.btn-steam:hover {
    background: #2a475e;
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.4);
}

.btn-sm { padding: 5px 12px; font-size: 0.8rem; }
.btn-lg { padding: 12px 28px; font-size: 1rem; }

/* ─── Cards ───────────────────────────────────────────────────────────────── */
.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    transition: border-color var(--transition), box-shadow var(--transition);
}

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.25rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
}

.card-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text);
}

/* ─── Status Badges ───────────────────────────────────────────────────────── */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.3px;
    white-space: nowrap;
}

.badge-open        { background: var(--green-dim); color: var(--green); }
.badge-inprogress  { background: var(--blue-dim);  color: var(--blue);  }
.badge-waitinguser { background: var(--yellow-dim); color: var(--yellow); }
.badge-closed        { background: var(--gray-dim);  color: var(--text-muted); }
.badge-closedbyuser  { background: var(--yellow-dim); color: var(--yellow); }

.badge-low     { background: var(--gray-dim);   color: var(--text-muted); }
.badge-normal  { background: var(--blue-dim);   color: var(--blue); }
.badge-high    { background: var(--yellow-dim); color: var(--yellow); }
.badge-urgent  { background: var(--accent-dim); color: var(--accent); }

.badge-general        { background: var(--gray-dim);   color: var(--text-muted); }
.badge-payment        { background: var(--green-dim);  color: var(--green); }
.badge-playerreport   { background: var(--yellow-dim); color: var(--yellow); }
.badge-banappeal      { background: var(--accent-dim); color: var(--accent); }

/* ─── Forms ───────────────────────────────────────────────────────────────── */
.form-group {
    margin-bottom: 1.25rem;
}

.form-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-muted);
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-control {
    width: 100%;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: var(--text);
    padding: 9px 13px;
    font-size: 0.9rem;
    font-family: var(--font);
    transition: border-color var(--transition), box-shadow var(--transition), background var(--transition);
    outline: none;
}

.form-control:hover:not(:focus) {
    border-color: var(--border-hover);
}

.form-control:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(192,57,43,0.18);
    background: var(--surface-3);
}

.form-control::placeholder { color: var(--text-dim); }

textarea.form-control {
    resize: vertical;
    min-height: 120px;
}

select.form-control {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23777' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 36px;
}

/* ─── Tables ──────────────────────────────────────────────────────────────── */
.table-wrap {
    overflow-x: auto;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

thead th {
    background: var(--surface-2);
    color: var(--text-muted);
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 10px 16px;
    text-align: left;
    white-space: nowrap;
    border-bottom: 1px solid var(--border);
}

tbody tr {
    border-bottom: 1px solid var(--border);
    transition: background var(--transition);
}

tbody tr:last-child { border-bottom: none; }
tbody tr:hover { background: var(--surface-2); }

tbody td {
    padding: 12px 16px;
    color: var(--text);
    vertical-align: middle;
}

.table-link {
    color: var(--text);
    text-decoration: none;
    font-weight: 500;
    transition: color var(--transition);
}
.table-link:hover { color: var(--accent); text-decoration: none; }

/* ─── Alerts ──────────────────────────────────────────────────────────────── */
.alert {
    padding: 13px 16px;
    border-radius: var(--radius-lg);
    font-size: 0.875rem;
    border-left: 3px solid;
    margin-bottom: 1rem;
    line-height: 1.55;
}

.alert-warning {
    background: var(--yellow-dim);
    border-color: var(--yellow);
    color: var(--yellow);
}

.alert-danger {
    background: var(--accent-dim);
    border-color: var(--accent);
    color: #ef4444;
}

.alert-success {
    background: var(--green-dim);
    border-color: var(--green);
    color: var(--green);
}

.alert-info {
    background: var(--blue-dim);
    border-color: var(--blue);
    color: var(--blue);
}

/* ─── Page Headers ────────────────────────────────────────────────────────── */
.page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.75rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.page-title {
    font-family: var(--font-display);
    font-size: 1.75rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text);
}

.page-subtitle {
    color: var(--text-muted);
    font-size: 0.875rem;
    margin-top: 2px;
}

/* ─── Home Hero (parallax) ────────────────────────────────────────────────── */
.home-hero {
    position: relative;
    width: 100%;
    min-height: calc(100vh - 62px);
    background-attachment: fixed;
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* iOS/mobile fallback — fixed-attachment doesn't work on mobile */
@media (max-width: 768px) {
    .home-hero { background-attachment: scroll; }
}

.home-hero-overlay {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 140% 100% at 50% 40%, transparent 15%, rgba(0,0,0,0.6) 75%),
        linear-gradient(to bottom, rgba(11,11,11,0.15) 0%, rgba(11,11,11,0.55) 50%, rgba(11,11,11,0.97) 100%);
    z-index: 1;
}

.home-hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    padding: 2rem;
    max-width: 740px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.25rem;
}

/* Badge: padding 0 so border hugs the image tightly */
.home-hero-badge {
    background: rgba(0,0,0,0.72);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1.5px solid rgba(255,255,255,0.12);
    border-radius: 10px;
    padding: 0;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0,0,0,0.9), 0 0 0 4px rgba(0,0,0,0.4);
}

.home-hero-logo {
    width: 72px;
    height: 72px;
    display: block;
}

.home-hero-title {
    font-size: clamp(2.2rem, 5vw, 3.6rem);
    font-family: var(--font-display);
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #fff;
    line-height: 1.05;
    text-shadow: 0 2px 32px rgba(0,0,0,0.95);
}

.home-hero-title span { color: var(--accent); }

.home-hero-subtitle {
    font-size: clamp(0.9rem, 2vw, 1.1rem);
    color: rgba(255,255,255,0.7);
    max-width: 480px;
    line-height: 1.6;
    text-shadow: 0 1px 10px rgba(0,0,0,0.8);
}

.home-hero-btns {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 0.4rem;
}

.home-hero-status {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.78rem;
    color: rgba(255,255,255,0.65);
    margin-top: 0.2rem;
}

.home-scroll-hint {
    position: absolute;
    bottom: 2.25rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    color: rgba(255,255,255,0.75);
    filter: drop-shadow(0 0 10px rgba(255,255,255,0.35));
    /* animation handled in hero entrance block below */
}

@keyframes scrollBounce {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50%       { transform: translateX(-50%) translateY(9px); }
}

/* ─── Hero entrance animations ────────────────────────────────────────────── */
@keyframes heroFadeUp {
    from { opacity: 0; transform: translateY(28px); }
    to   { opacity: 1; transform: translateY(0); }
}
@keyframes heroBadgeDrop {
    from { opacity: 0; transform: translateY(-22px) scale(0.88); }
    to   { opacity: 1; transform: translateY(0)    scale(1); }
}

.home-hero-badge    { animation: heroBadgeDrop 0.7s cubic-bezier(0.22,1,0.36,1) 0s    both; }
.home-hero-title    { animation: heroFadeUp    0.7s cubic-bezier(0.22,1,0.36,1) 0.15s both; }
.home-hero-subtitle { animation: heroFadeUp    0.7s cubic-bezier(0.22,1,0.36,1) 0.28s both; }
.home-hero-btns     { animation: heroFadeUp    0.7s cubic-bezier(0.22,1,0.36,1) 0.42s both; }
.home-hero-status   { animation: heroFadeUp    0.6s cubic-bezier(0.22,1,0.36,1) 0.56s both; }
.home-scroll-hint   { animation: scrollBounce 2.2s ease-in-out 1.2s infinite,
                                 heroFadeUp   0.6s cubic-bezier(0.22,1,0.36,1) 0.7s  both; }

/* Respect user motion preferences */
@media (prefers-reduced-motion: reduce) {
    .home-hero-badge,
    .home-hero-title,
    .home-hero-subtitle,
    .home-hero-btns,
    .home-hero-status,
    .home-scroll-hint,
    .home-alert-bar   { animation: none; opacity: 1; transform: translateX(-50%); }
    .home-tile-left,
    .home-tile-right  { animation: none; opacity: 1; transform: none; }
    .store-promo      { animation: none; opacity: 1; transform: none; }
}

/* ─── Home cinematic strip (kovexneon — between hero and panels) ─────────── */
.home-cinematic {
    position: relative;
    width: 100%;
    height: 52vh;
    min-height: 280px;
    max-height: 580px;
    overflow: hidden;
    background: var(--bg);
    display: block;
}
.home-cinematic-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 28%;
}
.home-cinematic-vignette {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        var(--bg) 0%,
        transparent 15%,
        transparent 78%,
        var(--bg) 100%
    );
    pointer-events: none;
    z-index: 1;
}
@media (max-width: 640px) {
    .home-cinematic { height: 36vh; }
}

/* ─── Home alert bar — overlaid at bottom of hero ─────────────────────────── */
@keyframes homeAlertSlide {
    from { opacity: 0; transform: translateX(-50%) translateY(14px); }
    to   { opacity: 1; transform: translateX(-50%) translateY(0); }
}
.home-alert-bar {
    position: absolute;
    bottom: 4.5rem;
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - 4rem);
    max-width: 720px;
    z-index: 3;
    animation: homeAlertSlide 0.6s cubic-bezier(0.22,1,0.36,1) 0.72s both;
}
/* Glass treatment for hero overlay — overrides default opaque alert style */
.home-alert-bar .alert {
    margin-bottom: 0;
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border: 1px solid rgba(255,255,255,0.07);
    border-left-width: 3px;
    box-shadow: 0 4px 28px rgba(0,0,0,0.45);
    color: var(--text);
    font-size: 0.875rem;
    line-height: 1.55;
}
.home-alert-bar .alert a {
    color: inherit;
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 2px;
}
.home-alert-bar .alert-info    { background: rgba(52,152,219,0.15);  border-left-color: var(--blue); }
.home-alert-bar .alert-warning { background: rgba(243,156,18,0.13);  border-left-color: var(--yellow); }
.home-alert-bar .alert-danger  { background: rgba(192,57,43,0.15);   border-left-color: var(--accent); }

/* ─── Home full-screen panels ─────────────────────────────────────────────── */
.home-panel {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 8rem 2rem 10rem;
    background-color: var(--bg);
    background-image: url('/images/kovexneon.jpg');
    background-attachment: fixed;
    background-size: cover;
    background-position: center 20%;
    background-repeat: no-repeat;
    position: relative;
    overflow: hidden;
}

/* Dark veil over the night panel — tiles float above this */
.home-panel::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        linear-gradient(to bottom, rgba(6,6,8,0.68) 0%, rgba(6,6,8,0.62) 55%, rgba(6,6,8,0.82) 100%);
    z-index: 0;
    pointer-events: none;
}

.home-panel-alt {
    background-color: var(--surface);
    background-image: url('/images/bg-panel-day.jpg');
    background-attachment: fixed;
    background-size: cover;
    background-position: center 35%;
    background-repeat: no-repeat;
}

/* Warm veil over the sepia panel — slightly warmer tint to complement the image */
.home-panel-alt::before {
    background:
        linear-gradient(to bottom, rgba(8,6,4,0.85) 0%, rgba(8,6,4,0.80) 60%, rgba(8,6,4,0.93) 100%);
}

/* iOS/mobile: fixed-attachment doesn't work — fall back to scroll */
@media (max-width: 768px) {
    .home-panel,
    .home-panel-alt {
        background-attachment: scroll;
    }
}


.home-panel-label {
    /* h2 reset — preserves visual style while giving correct semantics */
    font-size: 0.7rem;
    font-weight: 700;
    margin: 0;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.28);
    margin-bottom: 2.5rem;
    opacity: 0;
    transform: translateY(-14px);
    transition: opacity 0.7s ease, transform 0.7s ease;
    position: relative;
    z-index: 1;
}

.home-panel-label.home-tile-visible {
    opacity: 1;
    transform: translateY(0);
}

/* ─── Scroll tiles ────────────────────────────────────────────────────────── */
.home-tile-row {
    display: grid;
    /* Asymmetric: left tile slightly wider for visual weight */
    grid-template-columns: 1.18fr 0.82fr;
    gap: 28px;
    width: 100%;
    max-width: 1140px;
    align-items: start;
    position: relative;
    z-index: 1;
}

/* Stagger: right tile drops down; also give panel-alt the mirror stagger */
.home-tile-right {
    margin-top: 100px;
}

/* Panel 2: invert stagger — left drops, right is high */
.home-panel-alt .home-tile-left  {
    margin-top: 100px;
    border-radius: 28px 28px 28px 8px; /* bottom-left cut */
}
.home-panel-alt .home-tile-right {
    margin-top: 0;
    border-radius: 28px 28px 8px 28px; /* bottom-right cut */
}

@media (max-width: 640px) {
    .home-tile-row { grid-template-columns: 1fr; }
    .home-tile-right,
    .home-panel-alt .home-tile-left { margin-top: 0; }
    .home-panel { min-height: auto; padding: 5rem 1.25rem 6rem; }
}

.home-tile {
    background: var(--surface-2);
    border: 1px solid rgba(255,255,255,0.065);
    /* Default radius: outer corners fully rounded, inner corners stay rounded */
    border-radius: 28px;
    padding: 3rem 2.75rem 2.75rem;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    gap: 20px;
    min-height: clamp(320px, 38vh, 480px);
    position: relative;
    overflow: hidden;
    /* Two-layer shadow so hover transition can interpolate smoothly */
    box-shadow: 0 0px 0px rgba(0,0,0,0), 0 2px 0 rgba(255,255,255,0.04) inset;
    transition: border-color 0.35s, transform 0.5s cubic-bezier(0.22,1,0.36,1), box-shadow 0.5s ease;
}

/* Left tile: top-left corner cut sharp — faces inward toward center */
.home-tile-left  { border-radius: 8px 28px 28px 28px; }
/* Right tile: top-right corner cut sharp — faces inward toward center */
.home-tile-right { border-radius: 28px 8px 28px 28px; }

/* Tile content stays above the orb */
.home-tile > * { position: relative; z-index: 1; }

/* Ambient glow orb — top-left corner, color-matched */
.home-tile::after {
    content: '';
    position: absolute;
    top: -80px;
    left: -80px;
    width: 320px;
    height: 320px;
    border-radius: 50%;
    background: radial-gradient(circle, var(--accent) 0%, transparent 68%);
    opacity: 0.1;
    pointer-events: none;
    z-index: 0;
    transition: opacity 0.45s ease;
}

.home-tile-blue::after    { background: radial-gradient(circle, var(--blue)    0%, transparent 68%); }
.home-tile-green::after   { background: radial-gradient(circle, var(--green)   0%, transparent 68%); }
.home-tile-yellow::after  { background: radial-gradient(circle, var(--yellow)  0%, transparent 68%); }
.home-tile-discord::after { background: radial-gradient(circle, #5865f2 0%, transparent 68%); }

.home-tile:hover {
    border-color: rgba(255,255,255,0.13);
    transform: translateY(-8px);
    box-shadow: 0 28px 64px rgba(0,0,0,0.42), 0 2px 0 rgba(255,255,255,0.06) inset;
    text-decoration: none;
}

.home-tile:hover::after { opacity: 0.2; }

.home-tile-icon {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    background: var(--accent-dim);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent);
    flex-shrink: 0;
}

.home-tile-blue    .home-tile-icon { background: var(--blue-dim);          color: var(--blue); }
.home-tile-green   .home-tile-icon { background: var(--green-dim);         color: var(--green); }
.home-tile-yellow  .home-tile-icon { background: var(--yellow-dim);        color: var(--yellow); }
.home-tile-discord .home-tile-icon { background: rgba(88,101,242,0.12);    color: #5865f2; }

.home-tile-title {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: clamp(1.2rem, 2vw, 1.55rem);
    color: var(--text);
    line-height: 1.2;
}

.home-tile:hover .home-tile-title {
    text-decoration: underline;
    text-underline-offset: 4px;
    text-decoration-color: rgba(232,232,232,0.3);
}

.home-tile-desc {
    font-size: 0.95rem;
    color: var(--text-muted);
    line-height: 1.65;
    flex: 1;
}

.home-tile-cta {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--accent);
    margin-top: auto;
    display: flex;
    align-items: center;
    gap: 4px;
}

.home-tile-blue    .home-tile-cta { color: var(--blue); }
.home-tile-green   .home-tile-cta { color: var(--green); }
.home-tile-yellow  .home-tile-cta { color: var(--yellow); }
.home-tile-discord .home-tile-cta { color: #5865f2; }

/* ─── Slide-in animations with scale for 3D depth ─────────────────────────── */
.home-tile-left {
    opacity: 0;
    transform: translateX(-80px) scale(0.9);
    transition: opacity 0.8s cubic-bezier(0.4,0,0.2,1),
                transform 1.05s cubic-bezier(0.22,1,0.36,1);
}

.home-tile-right {
    opacity: 0;
    transform: translateX(80px) scale(0.9);
    transition: opacity 0.8s cubic-bezier(0.4,0,0.2,1),
                transform 1.05s cubic-bezier(0.22,1,0.36,1);
    transition-delay: 0.18s;
}

.home-tile-left.home-tile-visible,
.home-tile-right.home-tile-visible {
    opacity: 1;
    transform: translateX(0) scale(1);
}

/* ─── Home store section ──────────────────────────────────────────────────── */
.home-store-section {
    min-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6rem 2rem;
    background-color: var(--bg);
    background-image: url('/images/storestill.jpg');
    background-attachment: fixed;
    background-size: cover;
    background-position: center center;
    position: relative;
    overflow: hidden;
}
.home-store-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(4,2,2,0.70) 0%, rgba(4,2,2,0.62) 50%, rgba(4,2,2,0.78) 100%);
    z-index: 0;
    pointer-events: none;
}
.home-store-section > * {
    position: relative;
    z-index: 1;
}
@media (max-width: 768px) {
    .home-store-section { background-attachment: scroll; }
}

.server-status-pip {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 6px var(--green);
    flex-shrink: 0;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

.server-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 1rem;
    margin-top: 0.5rem;
}

.server-info-card {
    background: linear-gradient(160deg, var(--surface-2) 0%, var(--surface) 70%);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1rem 1.25rem;
    text-align: center;
    transition: border-color var(--transition), box-shadow var(--transition), transform var(--transition);
}

.server-info-card:hover {
    border-color: var(--border-hover);
    box-shadow: var(--shadow-sm);
    transform: translateY(-2px);
}

.server-info-label {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-dim);
    margin-bottom: 6px;
}

.server-info-value {
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--text);
}

/* ─── Hero ────────────────────────────────────────────────────────────────── */
.hero {
    text-align: center;
    padding: 4rem 1rem;
}

.hero-title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 800;
    letter-spacing: -0.5px;
    color: var(--text);
    margin-bottom: 0.75rem;
}

.hero-title span {
    color: var(--accent);
}

.hero-sub {
    color: var(--text-muted);
    font-size: 1.05rem;
    max-width: 500px;
    margin: 0 auto 2.5rem;
}

.hero-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

/* ─── Feature Grid ────────────────────────────────────────────────────────── */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
    margin-top: 3rem;
}

.feature-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    text-align: center;
}

.feature-icon {
    font-size: 2rem;
    margin-bottom: 0.75rem;
}

.feature-title {
    font-weight: 600;
    font-size: 0.95rem;
    margin-bottom: 0.4rem;
    color: var(--text);
}

.feature-desc {
    font-size: 0.82rem;
    color: var(--text-muted);
    line-height: 1.5;
}

/* ─── Ticket Thread ───────────────────────────────────────────────────────── */
.ticket-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.meta-item label {
    display: block;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-dim);
    margin-bottom: 3px;
}

.meta-item span {
    font-size: 0.875rem;
    color: var(--text);
    font-weight: 500;
}

.message-thread {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin: 1.5rem 0;
}

.message {
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1rem 1.25rem;
    transition: border-color var(--transition);
}

.message.admin-message {
    border-color: rgba(192,57,43,0.25);
    background: rgba(192,57,43,0.04);
}

.message-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.6rem;
}

.message-author {
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--text);
    display: flex;
    align-items: center;
    gap: 6px;
}

.message-author .admin-tag {
    font-size: 0.7rem;
    background: var(--accent-dim);
    color: var(--accent);
    padding: 2px 7px;
    border-radius: 20px;
    font-weight: 600;
}

/* ─── Staff Role Tags ─────────────────────────────────────────────────────── */
.role-tag {
    display: inline-block;
    align-self: flex-start;
    font-size: 0.7rem;
    padding: 2px 7px;
    border-radius: 20px;
    font-weight: 600;
    letter-spacing: 0.2px;
}

.role-tag-staff { background: var(--accent-dim);  color: var(--accent); }
.role-tag-trial       { background: var(--yellow-dim);           color: var(--yellow); }
.role-tag-admin       { background: var(--blue-dim);              color: var(--blue); }
.role-tag-management  { background: rgba(46,204,113,0.15);        color: #2ecc71; }
.role-tag-owner       { background: rgba(180,120,255,0.15);       color: #b478ff; }

.message-time {
    font-size: 0.75rem;
    color: var(--text-dim);
}

.message-body {
    font-size: 0.9rem;
    color: var(--text);
    word-break: break-word;
}
.message-body p {
    margin: 0 0 0.6rem;
}
.message-body p:last-child {
    margin-bottom: 0;
}

.system-message {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px 0;
    color: var(--text-dim);
    font-size: 0.78rem;
    font-style: italic;
    position: relative;
}
.system-message::before,
.system-message::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--border);
}
.system-message svg {
    flex-shrink: 0;
    opacity: 0.6;
}

.resolve-hint {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 1rem;
    padding: 0.65rem 1rem;
    background: var(--blue-dim);
    border: 1px solid rgba(52,152,219,0.2);
    border-radius: var(--radius);
    font-size: 0.82rem;
    color: var(--text-muted);
}
.resolve-hint svg {
    flex-shrink: 0;
    color: var(--blue);
    opacity: 0.8;
}

.reply-box {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
    margin-top: 1.5rem;
}

.reply-box h3 {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* ─── Filters ─────────────────────────────────────────────────────────────── */
.filter-bar {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 1.25rem;
}

.filter-btn {
    display: inline-flex;
    align-items: center;
    height: 30px;
    padding: 0 14px;
    border-radius: 15px;
    border: 1px solid #404040;
    background: transparent;
    color: #aaa;
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    white-space: nowrap;
    line-height: 1;
    transition: border-color var(--transition), background var(--transition), color var(--transition);
}

.filter-btn:hover {
    border-color: var(--accent);
    background: rgba(192,57,43,0.08);
    color: var(--text);
    text-decoration: none;
}

.filter-btn.active {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
    font-weight: 600;
    box-shadow: 0 2px 10px rgba(192,57,43,0.3);
}

/* ─── Empty State ─────────────────────────────────────────────────────────── */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
    color: var(--text-dim);
}

.empty-state-icon {
    font-size: 2.5rem;
    margin-bottom: 0.75rem;
    opacity: 0.4;
}

.empty-state p {
    font-size: 0.9rem;
}

/* ─── Footer ──────────────────────────────────────────────────────────────── */
.footer {
    border-top: 1px solid rgba(255,255,255,0.06);
    padding: 1.5rem 2rem;
    background: radial-gradient(ellipse 70% 200% at 50% 100%, rgba(192,57,43,0.13) 0%, transparent 70%);
    position: relative;
}

/* Home page footer — minimal, centered, clearly different from inner-page footer */
.footer.home-footer {
    background: #0b0b0b !important;
    border-top: none !important;
    padding: 2.5rem 2rem !important;
    position: relative;
}

/* Centered gradient separator — fades from center outward */
.footer.home-footer::before {
    content: '';
    position: absolute;
    top: 0; left: 25%; right: 25%;
    height: 1px;
    background: linear-gradient(to right, transparent, rgba(255,255,255,0.08) 50%, transparent);
}

/* Override footer-inner to be centered column on home */
.footer.home-footer .footer-inner {
    flex-direction: row;
    justify-content: center;
    gap: 2rem;
    max-width: 680px;
    flex-wrap: wrap;
}

.footer.home-footer .footer-brand {
    display: none;
}

.footer.home-footer .footer-copy {
    color: rgba(255,255,255,0.22) !important;
    font-size: 0.72rem;
    text-align: center;
    order: 1;
}

.footer.home-footer .footer-links {
    order: 2;
}

.footer.home-footer .footer-discord {
    background: transparent !important;
    border-color: rgba(255,255,255,0.1) !important;
    color: rgba(255,255,255,0.35) !important;
    font-size: 0.72rem;
}

.footer.home-footer .footer-discord:hover {
    border-color: rgba(88,101,242,0.4) !important;
    color: rgba(255,255,255,0.7) !important;
}

.footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    max-width: 1300px;
    margin: 0 auto;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 8px;
}

.footer-logo {
    height: 28px;
    width: 28px;
    object-fit: contain;
    border-radius: 4px;
    mix-blend-mode: screen;
    filter: brightness(1.1) saturate(1.2);
    opacity: 0.85;
}

.footer-brand-text {
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--text-muted);
    letter-spacing: 0.02em;
}

.footer-brand-text span {
    color: var(--accent);
}

.footer-copy {
    font-size: 0.75rem;
    color: var(--text-dim);
    text-align: center;
}

.footer-links {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

/* ── Announcement Bar ──────────────────────────────────────────────────────── */
.site-announcement {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 8px 16px;
    font-size: 0.85rem;
    font-weight: 500;
    position: relative;
    z-index: 200;
}
.site-announcement.ann-info    { background: #1a3a5c; color: #90caff; }
.site-announcement.ann-success { background: #1a3d2b; color: #6ee7a0; }
.site-announcement.ann-warning { background: #3d2e0a; color: #fbbf24; }
.site-announcement.ann-danger  { background: #3d1a1a; color: #fca5a5; }
.ann-text, .ann-text:visited { color: inherit; text-decoration: none; }
.ann-text[href]:hover { text-decoration: underline; }
.ann-dismiss {
    background: none;
    border: none;
    color: inherit;
    opacity: 0.6;
    cursor: pointer;
    font-size: 1.1rem;
    line-height: 1;
    padding: 0 4px;
    position: absolute;
    right: 12px;
}
.ann-dismiss:hover { opacity: 1; }

.footer-discord {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: rgba(88,101,242,0.12);
    border: 1px solid rgba(88,101,242,0.25);
    color: #7289da;
    border-radius: var(--radius);
    padding: 6px 14px;
    font-size: 0.82rem;
    font-weight: 600;
    text-decoration: none;
    transition: background var(--transition), border-color var(--transition),
                color var(--transition), transform var(--transition), box-shadow var(--transition);
}

.footer-discord:hover {
    background: rgba(88,101,242,0.2);
    border-color: rgba(88,101,242,0.5);
    color: #fff;
    text-decoration: none;
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(88,101,242,0.25);
}

@media (max-width: 600px) {
    .footer-inner { justify-content: center; }
    .footer-copy { order: 3; flex-basis: 100%; }
}

/* ─── Divider ─────────────────────────────────────────────────────────────── */
.divider {
    border: none;
    border-top: 1px solid var(--border);
    margin: 1.5rem 0;
}

/* ─── Admin Stats Row ─────────────────────────────────────────────────────── */
.stats-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 1rem;
    margin-bottom: 1.75rem;
}

.stat-card {
    background: linear-gradient(160deg, var(--surface-2) 0%, var(--surface) 70%);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1rem 1.25rem;
    text-align: center;
    transition: border-color var(--transition), box-shadow var(--transition), transform var(--transition);
}

.stat-card:hover {
    border-color: var(--border-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text);
    line-height: 1;
}

.stat-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 4px;
}

/* ─── Admin ticket detail sidebar ────────────────────────────────────────── */
.ticket-layout {
    display: grid;
    grid-template-columns: 1fr 260px;
    gap: 1.5rem;
    align-items: start;
}

@media (max-width: 768px) {
    .ticket-layout {
        grid-template-columns: 1fr;
    }
}

.sidebar-card {
    background: linear-gradient(160deg, var(--surface-2) 0%, var(--surface) 70%);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
    position: sticky;
    top: 76px;
}

.sidebar-section {
    margin-bottom: 1.25rem;
}

.sidebar-section:last-child { margin-bottom: 0; }

.sidebar-label {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-dim);
    margin-bottom: 6px;
}

.sidebar-value {
    font-size: 0.875rem;
    color: var(--text);
    font-weight: 500;
}

/* ─── Linked Warning ──────────────────────────────────────────────────────── */
.link-warning {
    background: rgba(243,156,18,0.08);
    border: 1px solid rgba(243,156,18,0.3);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    text-align: center;
    max-width: 480px;
    margin: 3rem auto;
}

.link-warning-icon {
    font-size: 2.5rem;
    margin-bottom: 0.75rem;
}

.link-warning h2 {
    font-size: 1.1rem;
    color: var(--text);
    margin-bottom: 0.5rem;
}

.link-warning p {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-bottom: 1.25rem;
}

/* ─── Hamburger Button ────────────────────────────────────────────────────── */
.hamburger {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    cursor: pointer;
    padding: 12px;            /* 12+20+12 = 44px touch target */
    border-radius: var(--radius);
    border: 1px solid transparent;
    background: transparent;
    transition: background 0.15s, border-color 0.15s;
    flex-shrink: 0;
    touch-action: manipulation;
}

.hamburger:hover {
    background: var(--surface-2);
    border-color: var(--border);
}

.hamburger:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

.hamburger span {
    display: block;
    width: 20px;
    height: 2px;
    background: var(--text-muted);
    border-radius: 2px;
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1),
                opacity   0.2s  cubic-bezier(0.4, 0, 0.2, 1),
                background 0.15s;
    transform-origin: center;
}

/* Hamburger → X when sidebar is open */
.hamburger.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.is-open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (prefers-reduced-motion: reduce) {
    .hamburger span { transition: none; }
}

/* ─── Sidebar Overlay ─────────────────────────────────────────────────────── */
.sidebar-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
    z-index: 200;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s;
}

.sidebar-overlay.open {
    opacity: 1;
    pointer-events: auto;
}

/* ─── Nav Sidebar ─────────────────────────────────────────────────────────── */
.nav-sidebar {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    width: 272px;
    background: linear-gradient(180deg, #1b1b1b 0%, #151515 100%);
    border-right: 1px solid rgba(192,57,43,0.2);
    z-index: 201;
    transform: translateX(-100%);
    transition: transform 0.28s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    overflow-x: hidden;
    box-shadow: 8px 0 48px rgba(0,0,0,0.75);
}

/* custom scrollbar — matches dark theme */
.nav-sidebar::-webkit-scrollbar              { width: 4px; }
.nav-sidebar::-webkit-scrollbar-track       { background: transparent; }
.nav-sidebar::-webkit-scrollbar-thumb       { background: var(--border); border-radius: 2px; }
.nav-sidebar::-webkit-scrollbar-thumb:hover { background: var(--text-dim); }

.nav-sidebar.open {
    transform: translateX(0);
}

.sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.1rem;
    border-bottom: 1px solid rgba(192,57,43,0.18);
    flex-shrink: 0;
}

.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.brand-name {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text);
    line-height: 1.2;
}

.sidebar-close {
    background: transparent;
    border: 1px solid transparent;
    color: var(--text-muted);
    cursor: pointer;
    width: 36px;
    height: 36px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius);
    transition: background 0.15s, color 0.15s, border-color 0.15s;
    touch-action: manipulation;
    flex-shrink: 0;
}

.sidebar-close:hover {
    background: var(--surface-2);
    border-color: var(--border);
    color: var(--text);
}

.sidebar-close:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

.sidebar-nav {
    padding: 0.75rem 0.75rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.sidebar-section-label {
    font-family: var(--font-display);
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: var(--text-dim);
    padding: 13px 10px 5px;
    margin-top: 6px;
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
}

.sidebar-section-label::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--border);
    min-width: 16px;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 9px 10px;
    border-radius: var(--radius);
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    transition: background var(--transition), color var(--transition),
                border-left-color var(--transition);
    position: relative;
    border-left: 2px solid transparent;
    touch-action: manipulation;
}

/* Inline SVG icons inside sidebar links */
.sidebar-link svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    opacity: 0.5;
    transition: opacity var(--transition);
}

.sidebar-link:hover {
    background: rgba(255,255,255,0.05);
    color: var(--text);
    border-left-color: rgba(192,57,43,0.35);
    text-decoration: none;
}

.sidebar-link:hover svg {
    opacity: 0.85;
}

.sidebar-link:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: -2px;
    color: var(--text);
    background: rgba(255,255,255,0.05);
}

.sidebar-link.active {
    background: rgba(192,57,43,0.12);
    color: var(--text);
    border-left-color: var(--accent);
    font-weight: 600;
}

.sidebar-link.active svg {
    opacity: 1;
}

.sidebar-link.admin-link {
    color: #cf4444;
}

.sidebar-link.admin-link svg {
    opacity: 0.65;
}

.sidebar-link.admin-link:hover {
    background: rgba(192,57,43,0.1);
    color: #de5555;
    border-left-color: rgba(192,57,43,0.4);
}

.sidebar-link.admin-link:hover svg {
    opacity: 0.9;
}

.sidebar-link.admin-link.active {
    background: rgba(192,57,43,0.16);
    color: #e86666;
    border-left-color: var(--accent);
}

.sidebar-link.admin-link.active svg {
    opacity: 1;
}

/* Legacy class — keep for any usages outside sidebar */
.sidebar-icon {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    opacity: 0.5;
}

.sidebar-badge {
    margin-left: auto;
    background: var(--accent);
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.sidebar-user {
    border-top: 1px solid var(--border);
    flex-shrink: 0;
    background: rgba(0,0,0,0.2);
    padding: 7px;
}

/* ─── Sidebar Profile Card ────────────────────────────────────────────────── */
/* Profile link + sign-out icon in one compact row */
.sidebar-profile-card {
    display: flex;
    align-items: center;
    gap: 2px;
}

.sidebar-profile {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 7px 6px 7px 7px;
    flex: 1;
    min-width: 0;
    text-decoration: none;
    border-radius: var(--radius);
    transition: background var(--transition);
}

.sidebar-profile:hover {
    background: rgba(255,255,255,0.05);
    text-decoration: none;
}

.sidebar-profile-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(192,57,43,0.25);
    flex-shrink: 0;
    transition: border-color var(--transition);
    background: var(--surface-3);
    /* fallback initials */
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text-muted);
}

.sidebar-profile:hover .sidebar-profile-avatar {
    border-color: rgba(192,57,43,0.55);
}

.sidebar-profile-info {
    flex: 1;
    min-width: 0;
}

.sidebar-profile-name {
    font-size: 0.83rem;
    font-weight: 600;
    color: var(--text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.25;
}

.sidebar-profile-meta {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-top: 2px;
    overflow: hidden;
}

.sidebar-profile-status {
    font-size: 0.65rem;
    font-weight: 500;
    flex-shrink: 0;
    white-space: nowrap;
}

.sidebar-profile-status.verified   { color: var(--green); }
.sidebar-profile-status.unverified { color: var(--yellow); }

/* Tier label in sidebar — plain colored text, no pill
   Higher specificity (0,2,0) beats dynamic .kit-tier-* injection (0,1,0) */
.sidebar-profile .sidebar-kit-tier {
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    flex-shrink: 0;
    white-space: nowrap;
    background: none !important;
    border: none !important;
    border-radius: 0 !important;
    padding: 0 !important;
}

/* Sign-out icon button — sits to the right of the profile link */
.sidebar-signout {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: var(--radius);
    color: var(--text-muted);
    text-decoration: none;
    flex-shrink: 0;
    transition: background var(--transition), color var(--transition);
    touch-action: manipulation;
}

.sidebar-signout svg {
    opacity: 0.75;
    transition: opacity var(--transition);
}

.sidebar-signout:hover {
    background: rgba(239,68,68,0.12);
    color: #f08080;
    text-decoration: none;
}

.sidebar-signout:hover svg { opacity: 1; }

.sidebar-signout:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

/* Steam login when not authenticated */
.sidebar-steam-login {
    width: 100%;
    justify-content: center;
    font-size: 0.85rem;
}

/* Legacy */
.sidebar-user-info { display: flex; align-items: center; gap: 10px; }

/* ─── Discord Button ──────────────────────────────────────────────────────── */
.btn-discord {
    background: #5865f2;
    color: #fff;
    border-color: #5865f2;
}

.btn-discord:hover {
    background: #4752c4;
    border-color: #4752c4;
    color: #fff;
}

/* ─── Verify Steps ────────────────────────────────────────────────────────── */
.verify-steps {
    display: flex;
    flex-direction: column;
    gap: 0;
    max-width: 560px;
    margin: 0 auto;
}

.verify-step {
    display: flex;
    gap: 1.25rem;
    padding: 1.5rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
}

.verify-step.step-done {
    border-color: rgba(39, 174, 96, 0.3);
    background: rgba(39, 174, 96, 0.04);
}

.verify-step.step-active {
    border-color: rgba(41, 128, 185, 0.35);
}

.verify-step.step-disabled {
    opacity: 0.45;
}

.step-connector {
    width: 2px;
    height: 20px;
    background: var(--border);
    margin: 0 0 0 calc(1.5rem + 18px);
    flex-shrink: 0;
}

.step-connector.connector-done {
    background: rgba(39, 174, 96, 0.5);
}

.step-indicator {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 2px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-muted);
    background: var(--surface-2);
}

.step-done .step-indicator {
    border-color: var(--green);
    background: rgba(39, 174, 96, 0.12);
    color: var(--green);
}

.step-active .step-indicator {
    border-color: var(--blue);
    background: rgba(41, 128, 185, 0.12);
    color: var(--blue);
}

.step-body {
    flex: 1;
    min-width: 0;
}

.step-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 0.5rem;
}

.step-desc {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-bottom: 0.75rem;
    line-height: 1.5;
}

.step-account {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 0.25rem;
}

.step-account-name {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text);
}

.step-account-id {
    font-size: 0.75rem;
    font-family: var(--font-mono);
    color: var(--text-dim);
}

.verify-avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--border);
    flex-shrink: 0;
}

.verify-avatar-fallback {
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--surface-3);
    color: var(--text-muted);
    font-weight: 700;
    font-size: 0.9rem;
}

.discord-fallback {
    background: rgba(88, 101, 242, 0.15);
    color: #5865f2;
}

/* ─── Store ────────────────────────────────────────────────────────────────── */
.store-section-label {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-dim);
    margin-bottom: 0.75rem;
}

.store-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.store-grid-wide {
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
}

@media (max-width: 700px) {
    .store-grid { grid-template-columns: 1fr; }
}

.store-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    position: relative;
    transition: border-color var(--transition), box-shadow var(--transition), transform var(--transition);
}

.store-card:not(.store-card-disabled):hover {
    border-color: var(--accent);
    box-shadow: 0 0 0 1px var(--accent), var(--shadow);
    transform: translateY(-3px);
}

.store-card-featured {
    border-color: var(--accent);
}

.store-card-disabled {
    opacity: 0.65;
}

.store-featured-label {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    background: var(--accent);
    color: #fff;
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding: 2px 12px;
    border-radius: 0 0 6px 6px;
    white-space: nowrap;
}

.store-card-header {
    padding: 1.5rem 1.25rem 0.75rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding-top: 2rem;
}

.store-tier-badge {
    font-size: 0.7rem;
    font-weight: 800;
    letter-spacing: 0.1em;
    padding: 3px 10px;
    border-radius: 4px;
}

.store-price {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text);
}

.store-card-body {
    padding: 0.5rem 1.25rem 1rem;
    flex: 1;
}

.store-perk-list {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.store-perk {
    font-size: 0.85rem;
    color: var(--text-muted);
    padding-left: 1.1rem;
    position: relative;
}

.store-perk::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--green);
    font-weight: 700;
    font-size: 0.8rem;
}

.store-card-footer {
    padding: 0.75rem 1.25rem 1.25rem;
    border-top: 1px solid var(--border);
}

.store-card-footer .btn {
    width: 100%;
    justify-content: center;
}

.store-item {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.1rem 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.store-item-name {
    font-weight: 600;
    font-size: 0.95rem;
}

.store-item-desc {
    font-size: 0.82rem;
    color: var(--text-muted);
    flex: 1;
}

.store-item-price {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text);
    margin: 0.25rem 0;
}


/* ─── Store Promo (home page full-section version) ───────────────────────── */
.store-promo {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 1.5rem;
    max-width: 640px;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.9s cubic-bezier(0.4,0,0.2,1),
                transform 1s cubic-bezier(0.22,1,0.36,1);
}

.store-promo.home-tile-visible {
    opacity: 1;
    transform: translateY(0);
}

.store-promo-text {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.store-promo-eyebrow {
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--accent);
}

.store-promo-title {
    font-family: var(--font-display);
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    font-weight: 800;
    color: var(--text);
    line-height: 1.15;
    letter-spacing: 0.02em;
}

.store-promo-desc {
    font-size: 1rem;
    color: var(--text-muted);
    line-height: 1.6;
    max-width: 480px;
    margin: 0 auto;
}

/* ─── Ticket Category Picker ─────────────────────────────────────────────── */
.ticket-cat-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

@media (max-width: 540px) {
    .ticket-cat-grid { grid-template-columns: 1fr; }
}

.ticket-cat-btn {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 0.85rem 1rem;
    color: var(--text-muted);
    font-size: 0.9rem;
    font-weight: 500;
    font-family: var(--font);
    cursor: pointer;
    transition: border-color var(--transition), color var(--transition), background var(--transition), transform var(--transition), box-shadow var(--transition);
    text-align: left;
}

.ticket-cat-btn svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    opacity: 0.6;
    transition: opacity 0.15s;
}

.ticket-cat-btn:hover {
    border-color: var(--accent);
    color: var(--text);
    transform: translateY(-1px);
    box-shadow: var(--shadow-sm);
}

.ticket-cat-btn:hover svg { opacity: 1; }

.ticket-cat-btn.active {
    border-color: var(--accent);
    background: var(--accent-dim);
    color: var(--text);
    box-shadow: 0 0 0 1px rgba(192,57,43,0.2);
}

.ticket-cat-btn.active svg {
    opacity: 1;
    stroke: var(--accent);
}

/* ─── Internal Notes ────────────────────────────────────────────────────────── */
.internal-note {
    background: var(--note-bg);
    border: 1px dashed var(--note-border);
    border-radius: var(--radius);
    padding: 0.85rem 1rem;
    margin-bottom: 0.75rem;
}

.internal-note-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 0;
}

.internal-note-badge {
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    background: var(--note-border);
    color: #000;
    padding: 2px 7px;
    border-radius: 20px;
    margin-left: 4px;
}

/* ─── Activity Log ──────────────────────────────────────────────────────────── */
.activity-action {
    display: inline-block;
    font-size: 0.72rem;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.activity-reply    { background: var(--blue-dim);   color: var(--blue);   }
.activity-note     { background: var(--yellow-dim);  color: var(--note-text); }
.activity-status   { background: var(--accent-dim);  color: var(--accent); }
.activity-priority { background: var(--gray-dim);    color: var(--text-muted); }
.activity-role     { background: var(--green-dim);   color: var(--green);  }
.activity-delete   { background: var(--accent-dim);  color: var(--accent); }

/* ─── Profile Page ──────────────────────────────────────────────────────────── */
.profile-header {
    display: flex;
    align-items: flex-start;
    gap: 1.25rem;
    margin-bottom: 1.75rem;
    padding: 1.5rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
}

.profile-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    border: 3px solid var(--border);
    flex-shrink: 0;
    object-fit: cover;
}

.profile-avatar-fallback {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: var(--surface-3);
    border: 3px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-muted);
    flex-shrink: 0;
}

.profile-header-info { flex: 1; min-width: 0; }

.profile-name {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text);
    line-height: 1.2;
}

.profile-steam-link {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-dim);
    text-decoration: none;
    margin-top: 4px;
    transition: color var(--transition);
}
.profile-steam-link:hover { color: var(--text-muted); }

.profile-verified-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    background: var(--green-dim);
    color: var(--green);
    padding: 3px 8px;
    border-radius: 20px;
}

.profile-grid {
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 1rem;
    align-items: start;
}

@media (max-width: 680px) {
    .profile-grid { grid-template-columns: 1fr; }
    .profile-header { flex-direction: column; align-items: center; text-align: center; }
    .profile-header-info { display: flex; flex-direction: column; align-items: center; }
}

.profile-ticket-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 0.65rem 0;
    border-bottom: 1px solid var(--border);
    text-decoration: none;
    color: var(--text);
    transition: background var(--transition);
    border-radius: 4px;
    padding-left: 4px;
    padding-right: 4px;
}
.profile-ticket-row:last-child { border-bottom: none; }
.profile-ticket-row:hover { background: var(--surface-2); }

/* ─── Ticket Presence / Viewer Avatars ────────────────────────────────────── */
.viewer-stack {
    display: flex;
    align-items: center;
    gap: -6px;
}
.viewer-avatar {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    border: 2px solid var(--surface-1);
    background: var(--surface-3);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.65rem;
    font-weight: 700;
    color: var(--text-muted);
    margin-left: -6px;
    flex-shrink: 0;
}
.viewer-avatar:first-child { margin-left: 0; }
.viewer-avatar img { width: 100%; height: 100%; object-fit: cover; }
.viewer-overflow {
    background: var(--surface-3);
    font-size: 0.6rem;
    color: var(--text-dim);
}

.viewer-strip {
    display: flex;
    align-items: center;
    gap: 6px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 4px 10px 4px 8px;
}
.viewer-strip-label {
    font-size: 0.72rem;
    color: var(--text-dim);
    white-space: nowrap;
}

/* ─── Ticket Attachments ────────────────────────────────────────────────────── */
.attachment-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}
.attachment-thumb {
    width: 140px;
    height: 100px;
    object-fit: cover;
    border-radius: 6px;
    border: 1px solid var(--border);
    cursor: zoom-in;
    transition: opacity .15s, transform .15s;
    display: block;
}
.attachment-thumb:hover {
    opacity: .85;
    transform: scale(1.02);
}

/* ── Message Delete Button ──────────────────────────────────────────────── */
.btn-delete-msg {
    background: none;
    border: none;
    color: var(--text-dim);
    cursor: pointer;
    font-size: 0.75rem;
    padding: 2px 5px;
    border-radius: 4px;
    line-height: 1;
    opacity: 0;
    transition: opacity .15s, color .15s, background .15s;
}
.message:hover .btn-delete-msg,
.internal-note:hover .btn-delete-msg {
    opacity: 1;
}
.btn-delete-msg:hover {
    color: #e74c3c;
    background: rgba(231, 76, 60, 0.12);
}

/* ── Image Lightbox ─────────────────────────────────────────────────────── */
.img-lightbox-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.92);
    z-index: 9999;
    align-items: center;
    justify-content: center;
    cursor: zoom-out;
}
.img-lightbox-overlay.open {
    display: flex;
}
.img-lightbox-overlay img {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 8px 40px rgba(0,0,0,0.6);
    cursor: default;
}

/* ── Discord Embed Preview ───────────────────────────────────────────────── */
.embed-section-label {
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 0.6px;
    margin-bottom: 0.5rem;
}
.form-hint {
    font-weight: 400;
    color: var(--text-dim);
}
.discord-preview-bg {
    background: #313338;
    border-radius: 8px;
    padding: 14px;
    min-height: 120px;
    position: sticky;
    top: 80px;
}
.dp-embed {
    background: #2b2d31;
    border-radius: 0 4px 4px 0;
    display: flex;
    overflow: hidden;
}
.dp-stripe {
    width: 4px;
    flex-shrink: 0;
    background: #5865f2;
    border-radius: 4px 0 0 4px;
}
.dp-content {
    padding: 10px 14px 10px 12px;
    flex: 1;
    min-width: 0;
}
.dp-top-row {
    display: flex;
    gap: 10px;
    justify-content: space-between;
}
.dp-left-col { flex: 1; min-width: 0; }
.dp-author {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.78rem;
    font-weight: 600;
    color: #dbdee1;
    margin-bottom: 4px;
}
.dp-author-icon {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    object-fit: cover;
}
.dp-title {
    font-size: 0.92rem;
    font-weight: 700;
    color: #00b0f4;
    margin-bottom: 4px;
    word-break: break-word;
}
.dp-desc {
    font-size: 0.82rem;
    color: #dbdee1;
    line-height: 1.45;
    word-break: break-word;
    white-space: normal;
}
.dp-thumb {
    width: 68px;
    height: 68px;
    border-radius: 4px;
    object-fit: cover;
    flex-shrink: 0;
}
.dp-img {
    display: block;
    width: 100%;
    border-radius: 4px;
    margin-top: 10px;
    object-fit: cover;
    max-height: 180px;
}
.dp-footer-row {
    font-size: 0.68rem;
    color: #949ba4;
    margin-top: 8px;
}
.dp-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: #4f545c;
    color: #fff;
    border-radius: 3px;
    padding: 3px 16px;
    font-size: 0.82rem;
    font-weight: 500;
    cursor: default;
    border: 1px solid rgba(255,255,255,0.08);
    user-select: none;
}

/* ── Kit Tier Badges ─────────────────────────────────────────────────────── */
.kit-tier-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 9px;
    border-radius: 99px;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    border: 1px solid transparent;
}
.kit-tier-vip     { background: rgba(34,197,94,.15);  color: #22c55e; border-color: rgba(34,197,94,.3); }
.kit-tier-vipplus { background: rgba(20,184,166,.15); color: #14b8a6; border-color: rgba(20,184,166,.3); }
.kit-tier-mvp     { background: rgba(99,102,241,.15); color: #818cf8; border-color: rgba(99,102,241,.3); }
.kit-tier-elite   { background: rgba(168,85,247,.15); color: #c084fc; border-color: rgba(168,85,247,.3); }
.kit-tier-legend  { background: rgba(249,115,22,.15); color: #fb923c; border-color: rgba(249,115,22,.3); }

/* ── Info Content Pages ──────────────────────────────────────────────────── */
.info-content {
    padding: 1rem 0 0.5rem;
    line-height: 1.75;
    color: var(--text-muted);
}
.info-content h2 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text);
    margin: 1.5rem 0 0.75rem;
    padding-bottom: 0.4rem;
    border-bottom: 1px solid var(--border);
}
.info-content h2:first-child { margin-top: 0; }
.info-content h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text);
    margin: 1.25rem 0 0.5rem;
}
.info-content p  { margin: 0 0 0.75rem; }
.info-content ul, .info-content ol {
    margin: 0 0 0.75rem;
    padding-left: 1.5rem;
}
.info-content li { margin-bottom: 4px; }
.info-content code {
    background: var(--surface-3);
    color: var(--accent);
    padding: 1px 6px;
    border-radius: 4px;
    font-family: var(--font-mono);
    font-size: 0.85em;
}
.info-content a { color: var(--accent); }
.info-content table.info-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1rem;
    font-size: 0.88rem;
}
.info-content table.info-table th {
    background: var(--surface-3);
    color: var(--text-dim);
    text-align: left;
    padding: 6px 12px;
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.info-content table.info-table td {
    padding: 8px 12px;
    border-bottom: 1px solid var(--border);
    color: var(--text-muted);
}
.info-content table.info-table tr:last-child td { border-bottom: none; }

/* FAQ items */
.faq-item {
    border: 1px solid var(--border);
    border-radius: 8px;
    margin-bottom: 0.75rem;
    overflow: hidden;
}
.faq-question {
    padding: 0.85rem 1rem;
    font-weight: 600;
    color: var(--text);
    font-size: 0.95rem;
    background: var(--surface-2);
}
.faq-answer {
    padding: 0.85rem 1rem;
    font-size: 0.88rem;
    color: var(--text-muted);
    line-height: 1.7;
    border-top: 1px solid var(--border);
}
.faq-answer a { color: var(--accent); }
.faq-answer code {
    background: var(--surface-3);
    color: var(--accent);
    padding: 1px 5px;
    border-radius: 3px;
    font-family: var(--font-mono);
    font-size: 0.85em;
}

/* ── Vote Cards ──────────────────────────────────────────────────────────── */
.vote-card {
    display: block;
    background: var(--surface-2);
    border: 2px solid var(--border);
    border-radius: 10px;
    overflow: hidden;
    transition: border-color .15s;
}
.vote-card-clickable:hover { border-color: var(--text-dim); }
.vote-card-selected        { border-color: var(--accent) !important; }
.vote-card-thumb {
    height: 200px;
    background: var(--surface-3);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}
.vote-card-body {
    padding: 1rem 1.1rem;
}

/* ── Store Package Cards ─────────────────────────────────────────────────── */
.store-packages-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1.25rem;
    align-items: start;
}
.store-pkg-card {
    background: var(--surface-2);
    border: 1.5px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    position: relative;
    transition: border-color .15s, transform .15s;
}
.store-pkg-card:hover {
    transform: translateY(-2px);
}
.store-pkg-featured {
    border-color: var(--accent);
}
.store-pkg-popular {
    background: var(--accent);
    color: #fff;
    text-align: center;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    padding: 5px 0;
}
.store-pkg-header {
    padding: 1.25rem 1.25rem 1rem;
    border-bottom: 2px solid var(--border);
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.store-pkg-name {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--text);
    letter-spacing: -0.01em;
}
.store-pkg-tagline {
    font-size: 0.8rem;
    color: var(--text-dim);
}
.store-pkg-price {
    font-size: 2rem;
    font-weight: 800;
    line-height: 1;
    margin-top: 4px;
}
.store-pkg-features {
    padding: 1rem 1.25rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.store-pkg-feature {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 0.84rem;
    color: var(--text-muted);
    line-height: 1.4;
}
.store-pkg-feature svg {
    flex-shrink: 0;
    margin-top: 1px;
}
.store-pkg-footer {
    padding: 1rem 1.25rem 1.25rem;
}
.store-pkg-btn {
    width: 100%;
    justify-content: center;
}

/* ─── Vote winner banner ──────────────────────────────────────────────────── */
.vote-winner-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1.25rem;
    background: linear-gradient(135deg, rgba(245,196,0,.12), rgba(245,196,0,.04));
    border: 1px solid rgba(245,196,0,.3);
    border-radius: var(--radius);
    margin-bottom: 1.25rem;
    flex-wrap: wrap;
}
.vote-card-winner {
    border-color: rgba(245,196,0,.35) !important;
    background: rgba(245,196,0,.05) !important;
}

/* ─── Store page ──────────────────────────────────────────────────────────── */
.store-page-wrap { max-width: 1100px; }

/* Hero */
.store-hero {
    padding: 2.5rem 0 2rem;
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}
.store-hero-eyebrow {
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 6px;
}
.store-hero-title {
    font-family: var(--font-display);
    font-size: 2.4rem;
    font-weight: 800;
    line-height: 1.15;
    color: var(--text);
}
.store-hero-accent { color: var(--accent); }
.store-hero-desc {
    font-size: 1rem;
    color: var(--text-muted);
    max-width: 560px;
    line-height: 1.65;
}
.store-hero-badges {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}
.store-hero-badge {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    color: var(--text-muted);
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 5px 12px;
}
.store-hero-badge svg { color: var(--accent); flex-shrink: 0; }

/* Section title */
.store-section-title {
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 600;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin: 0 0 1.25rem;
}

/* Tile grid */
.store-tile-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1.25rem;
    margin-bottom: 2.5rem;
}

/* Individual tile */
.store-tile {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    cursor: pointer;
    transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
    position: relative;
    display: flex;
    flex-direction: column;
}
.store-tile:hover {
    transform: translateY(-4px);
    border-color: var(--tile-accent, var(--accent));
    box-shadow: 0 8px 32px rgba(0,0,0,.5);
}
.store-tile-featured {
    border-color: var(--tile-accent, var(--accent));
    box-shadow: 0 0 0 1px var(--tile-accent, var(--accent)), 0 6px 24px rgba(0,0,0,.4);
}
.store-tile-popular {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 2;
    background: var(--tile-accent, var(--accent));
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    padding: 3px 8px;
    border-radius: 4px;
}

/* Thumbnail */
.store-tile-thumb {
    position: relative;
    width: 100%;
    aspect-ratio: 1/1;
    background: var(--surface-2);
    overflow: hidden;
}
.store-tile-thumb-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    transition: transform .3s ease;
}
.store-tile:hover .store-tile-thumb-img { transform: scale(1.04); }
.store-tile-thumb-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, transparent 65%, rgba(0,0,0,.45) 100%);
}
.store-tile-thumb-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: .35;
}

/* Tile body */
.store-tile-body {
    padding: 12px 14px 14px;
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}
.store-tile-name {
    font-family: var(--font-display);
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 4px;
    text-transform: uppercase;
    letter-spacing: .04em;
}
.store-tile-price-row {
    display: flex;
    align-items: baseline;
    gap: 4px;
}
.store-tile-price {
    font-size: 1.35rem;
    font-weight: 800;
    line-height: 1;
}
.store-tile-period {
    font-size: 0.7rem;
    color: var(--text-dim);
    font-weight: 500;
}
.store-tile-cta {
    margin-top: auto;
    padding-top: 10px;
    align-self: stretch;
}
.store-tile-cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.78rem;
    font-weight: 600;
    border: 1px solid var(--border-hover);
    border-radius: 5px;
    padding: 5px 10px;
    transition: border-color .15s, color .15s;
}
.store-tile:hover .store-tile-cta-btn {
    border-color: var(--tile-accent, var(--accent));
}

/* How it works */
.store-howto {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.25rem 1.5rem;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    margin-bottom: 2rem;
    flex-wrap: wrap;
}
.store-howto-step {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    flex: 1;
    min-width: 160px;
}
.store-howto-step span { font-size: 0.8rem; color: var(--text-muted); }
.store-howto-num {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--accent-dim);
    border: 1px solid var(--accent);
    color: var(--accent);
    font-weight: 700;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.store-howto-arrow {
    color: var(--text-dim);
    font-size: 1.2rem;
    flex-shrink: 0;
}

/* Legal footer */
.store-legal {
    font-size: 0.78rem;
    color: var(--text-dim);
    text-align: center;
    padding: 1rem 0 .5rem;
    border-top: 1px solid var(--border);
    line-height: 1.8;
}
.store-legal a { color: var(--text-muted); text-decoration: underline; }
.store-legal a:hover { color: var(--text); }

/* ─── Package detail modal ────────────────────────────────────────────────── */
@keyframes modal-backdrop-in {
    from { opacity: 0; }
    to   { opacity: 1; }
}
@keyframes modal-slide-in {
    from { opacity: 0; transform: translateY(24px) scale(0.97); }
    to   { opacity: 1; transform: translateY(0)    scale(1); }
}
@keyframes modal-backdrop-out {
    from { opacity: 1; }
    to   { opacity: 0; }
}
@keyframes modal-slide-out {
    from { opacity: 1; transform: translateY(0)    scale(1); }
    to   { opacity: 0; transform: translateY(16px) scale(0.97); }
}

.pkg-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.75);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    backdrop-filter: blur(4px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.22s ease;
}
.pkg-modal-overlay.open {
    opacity: 1;
    pointer-events: auto;
    animation: modal-backdrop-in 0.22s ease forwards;
}
.pkg-modal-overlay.closing {
    animation: modal-backdrop-out 0.18s ease forwards;
    pointer-events: none;
}

.pkg-modal {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 980px;
    max-height: 92vh;
    overflow: hidden;
    position: relative;
    box-shadow: 0 24px 64px rgba(0,0,0,.65);
    display: flex;
    flex-direction: row;
    transform: translateY(24px) scale(0.97);
    opacity: 0;
    transition: transform 0.28s cubic-bezier(0.22,1,0.36,1), opacity 0.22s ease;
}
.pkg-modal-overlay.open .pkg-modal {
    transform: translateY(0) scale(1);
    opacity: 1;
}
.pkg-modal-close {
    position: absolute;
    top: 12px;
    right: 14px;
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.4rem;
    cursor: pointer;
    z-index: 2;
    line-height: 1;
    padding: 4px;
}
.pkg-modal-close:hover { color: var(--text); }

.pkg-modal-screenshot-wrap {
    position: relative;
    width: 58%;
    min-width: 260px;
    min-height: 460px;
    flex-shrink: 0;
    align-self: stretch;
    background: #070707;
    overflow: hidden;
    border-radius: var(--radius-lg) 0 0 var(--radius-lg);
    padding: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
}
.pkg-modal-screenshot {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    border-radius: var(--radius);
}
.pkg-modal-screenshot-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 0.78rem;
    color: var(--text-dim);
    flex: 1;
}

.pkg-modal-body { padding: 2rem 1.75rem 2rem; flex: 1; overflow-y: auto; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; position: relative; }
.pkg-modal-name {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--text);
    margin: 0 0 5px;
    line-height: 1.2;
}
.pkg-modal-tagline {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin: 3px 0 0;
}
.pkg-modal-price-row {
    display: flex;
    align-items: baseline;
    gap: 6px;
    margin-top: 1.1rem;
}
.pkg-modal-price { font-size: 1.8rem; font-weight: 800; line-height: 1; }
.pkg-modal-period { font-size: 0.82rem; color: var(--text-dim); }
.pkg-modal-divider { height: 1px; background: var(--border); margin: 1.25rem 0; width: 100%; }

.pkg-modal-features {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px 1rem;
    margin-bottom: 1.5rem;
    width: 100%;
}
.pkg-modal-feature {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 0.85rem;
    color: var(--text-muted);
}
.pkg-modal-icon {
    width: 72px;
    height: 72px;
    border-radius: 14px;
    background-size: cover;
    background-position: center;
    background-color: var(--surface-3);
    border: 2px solid transparent;
    flex-shrink: 0;
}
.pkg-modal-icon-rule {
    height: 1px;
    width: 100%;
    margin-top: 1.1rem;
    flex-shrink: 0;
}
.pkg-modal-watermark {
    position: absolute;
    top: 38%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 4.5rem;
    font-weight: 900;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    opacity: 0.06;
    pointer-events: none;
    user-select: none;
    white-space: nowrap;
    line-height: 1;
}
.pkg-modal-action { display: flex; flex-direction: column; align-items: flex-start; margin-top: auto; padding-top: 1.25rem; width: 100%; }
.store-pkg-btn { width: 100%; justify-content: center; font-size: 1rem; padding: .65rem 1rem; }

/* Drag handle — hidden on desktop, shown on mobile */
.pkg-modal-drag-handle { display: none; }

@media (max-width: 600px) {
    .store-hero-title { font-size: 1.7rem; }
    .store-howto-arrow { display: none; }

    /* Bottom sheet overlay */
    .pkg-modal-overlay {
        align-items: flex-end;
        padding: 0;
    }

    /* Sheet slides up from below via CSS transition */
    .pkg-modal {
        flex-direction: column;
        width: 100%;
        max-width: 100%;
        max-height: 88vh;
        border-radius: var(--radius-lg) var(--radius-lg) 0 0;
        border-bottom: none;
        overflow-y: auto;
        /* Start off-screen below; transition handles slide-up */
        transform: translateY(100%);
        padding-top: 0.75rem;
    }
    .pkg-modal-overlay.open .pkg-modal {
        transform: translateY(0);
    }

    /* Drag handle pill */
    .pkg-modal-drag-handle {
        display: block;
        width: 36px;
        height: 4px;
        background: var(--border-hover);
        border-radius: 2px;
        margin: 0 auto 0.5rem;
        flex-shrink: 0;
    }

    .pkg-modal-screenshot-wrap {
        width: 100%;
        min-width: unset;
        min-height: 200px;
        max-height: 260px;
        border-radius: 0;
        padding: 0.75rem;
    }
    .pkg-modal-features { grid-template-columns: 1fr; }
    .pkg-modal-body {
        overflow-y: visible;
        padding: 1.25rem 1.25rem 2rem;
    }
    .pkg-modal-action { margin-top: 1rem; padding-top: 0; }
    .pkg-modal-header { flex-direction: column; }
}

/* ── Config page tabs ──────────────────────────────────────────────────────── */
.config-tabs {
    display: flex;
    gap: 6px;
    margin-top: 1.5rem;
    flex-wrap: wrap;
    background: var(--surface-1);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 5px;
}
.config-tab {
    all: unset;
    cursor: pointer;
    font-size: 0.82rem;
    font-weight: 500;
    font-family: inherit;
    color: var(--text-muted);
    padding: 0.4rem 0.85rem;
    border-radius: 7px;
    transition: color .15s, background .15s;
    white-space: nowrap;
    user-select: none;
}
.config-tab:hover  { color: var(--text); background: var(--surface-2); }
.config-tab:focus  { outline: none; }
.config-tab.active { color: var(--text); background: var(--surface-3); font-weight: 600; }

/* ── Content page cards (on Config > Content tab) ─────────────────────────── */
.content-page-card {
    display: flex;
    flex-direction: column;
    gap: 4px;
    background: var(--surface-1);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 1rem 1.1rem;
    text-decoration: none;
    color: var(--text);
    transition: border-color .15s, background .15s;
}
.content-page-card:hover { border-color: var(--accent); background: var(--surface-2); }
.content-page-icon  { font-size: 1.4rem; margin-bottom: 2px; }
.content-page-title { font-size: 0.9rem; font-weight: 600; }
.content-page-desc  { font-size: 0.78rem; color: var(--text-muted); line-height: 1.4; }

/* ── Sidebar alert badge ──────────────────────────────────────────────────── */
.sidebar-alert-badge {
    margin-left: auto;
    background: var(--accent);
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: 9px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

/* ── Alert Center ─────────────────────────────────────────────────────────── */
.ac-refresh-info    { display: flex; align-items: center; gap: 4px; font-size: 0.82rem; color: var(--text-muted); }

.ac-refresh-count   { font-weight: 600; color: var(--text); min-width: 32px; text-align: right; }

.ac-stats-row       { display: flex; gap: 10px; margin-bottom: 20px; flex-wrap: wrap; }
.ac-stat-card       { background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius);
                      padding: 10px 18px; display: flex; flex-direction: column; align-items: center; min-width: 90px; }
.ac-stat-num        { font-size: 1.6rem; font-weight: 700; line-height: 1; }
.ac-stat-label      { font-size: 0.72rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: .04em; margin-top: 3px; }
.ac-stat-active     { border-color: var(--border); }
.ac-stat-critical   { border-color: rgba(220,38,38,.4); }
.ac-stat-critical .ac-stat-num { color: #ef4444; }
.ac-stat-high       { border-color: rgba(234,88,12,.4); }
.ac-stat-high .ac-stat-num     { color: #f97316; }
.ac-stat-low        { border-color: rgba(34,197,94,.35); }
.ac-stat-low .ac-stat-num      { color: #22c55e; }

.ac-empty           { text-align: center; padding: 48px 24px; color: var(--text-muted); display: flex; flex-direction: column;
                      align-items: center; gap: 12px; }
.ac-empty svg       { opacity: .4; }

/* Alert card */
.ac-card {
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-left: 3px solid var(--border);
    border-radius: var(--radius);
    padding: 14px 16px;
    margin-bottom: 10px;
    transition: border-color .15s;
}
.ac-card-critical { border-left-color: #ef4444; }
.ac-card-high     { border-left-color: #f97316; }
.ac-card-low      { border-left-color: #22c55e; }
.ac-card-resolved { opacity: .8; border-left-color: var(--text-dim); }

.ac-card-header {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 8px;
}

.ac-severity-badge {
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: .06em;
    padding: 2px 7px;
    border-radius: 4px;
    text-transform: uppercase;
}
.ac-sev-critical { background: rgba(239,68,68,.18); color: #f87171; border: 1px solid rgba(239,68,68,.35); }
.ac-sev-high     { background: rgba(249,115,22,.18); color: #fb923c; border: 1px solid rgba(249,115,22,.35); }
.ac-sev-low      { background: rgba(34,197,94,.14);  color: #4ade80; border: 1px solid rgba(34,197,94,.3); }

.ac-category-badge {
    font-size: 0.72rem;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 4px;
    background: var(--surface-3);
    border: 1px solid var(--border);
    color: var(--text-muted);
    letter-spacing: .03em;
}

.ac-player-name {
    font-weight: 600;
    color: var(--text);
    text-decoration: none;
    font-size: 0.95rem;
}
.ac-player-name:hover { color: var(--accent-hover); text-decoration: underline; }

.ac-steamid  { font-size: 0.75rem; color: var(--text-muted); font-family: monospace; }

.ac-server-badge {
    font-size: 0.72rem;
    padding: 2px 7px;
    border-radius: 4px;
    background: var(--blue-dim);
    border: 1px solid rgba(52,152,219,.2);
    color: #60a5fa;
}

.ac-time { font-size: 0.75rem; color: var(--text-muted); margin-left: auto; }

.ac-card-detail {
    font-size: 0.88rem;
    color: var(--text);
    margin-bottom: 8px;
    line-height: 1.45;
}

.ac-card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 16px;
    font-size: 0.78rem;
    color: var(--text-muted);
    margin-bottom: 12px;
}
.ac-card-meta strong { color: var(--text); }

.ac-card-actions { display: flex; gap: 8px; }

/* ── AC modal footer buttons ─────────────────────────────────────────────── */
.ac-foot-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 7px 13px;
    font-size: 0.79rem;
    font-weight: 600;
    border-radius: var(--radius);
    border: 1px solid transparent;
    cursor: pointer;
    white-space: nowrap;
    transition: background var(--transition), border-color var(--transition), color var(--transition);
    line-height: 1;
    letter-spacing: 0.01em;
}
.ac-foot-btn:disabled { opacity: .5; cursor: not-allowed; }

/* Ban — solid red */
.ac-foot-ban {
    background: rgba(239,68,68,.18);
    color: #fca5a5;
    border-color: rgba(239,68,68,.45);
}
.ac-foot-ban:hover:not(:disabled) { background: rgba(239,68,68,.3); border-color: rgba(239,68,68,.65); color: #fecaca; }

/* Dismiss — neutral */
.ac-foot-dismiss {
    background: var(--surface-3);
    color: #b0b0b0;
    border-color: var(--border);
}
.ac-foot-dismiss:hover:not(:disabled) { background: var(--border); color: #d8d8d8; }

/* External links — readable ghost */
.ac-foot-ext {
    background: transparent;
    color: #9a9a9a;
    border-color: var(--border);
}
.ac-foot-ext:hover:not(:disabled) { background: var(--surface-3); color: #d0d0d0; border-color: var(--border-hover); }

/* False Positive — amber */
.ac-foot-fp {
    background: rgba(234,179,8,.12);
    color: #fbbf24;
    border-color: rgba(234,179,8,.35);
}
.ac-foot-fp:hover:not(:disabled) { background: rgba(234,179,8,.22); border-color: rgba(234,179,8,.55); color: #fcd34d; }

/* Vertical divider between action and link groups */
.ac-foot-divider {
    width: 1px;
    height: 22px;
    background: var(--border);
    flex-shrink: 0;
    align-self: center;
}

/* Legacy aliases so old card-level buttons still work */
.ac-btn-ban    { display:inline-flex;align-items:center;gap:5px;padding:7px 13px;font-size:0.79rem;font-weight:600;border-radius:var(--radius);cursor:pointer;white-space:nowrap;transition:background var(--transition),border-color var(--transition),color var(--transition);background:rgba(239,68,68,.18);color:#f87171;border:1px solid rgba(239,68,68,.4); }
.ac-btn-ban:hover { background:rgba(239,68,68,.3);border-color:rgba(239,68,68,.6);color:#fca5a5; }
.ac-btn-ignore { display:inline-flex;align-items:center;gap:5px;padding:7px 13px;font-size:0.79rem;font-weight:600;border-radius:var(--radius);cursor:pointer;white-space:nowrap;transition:background var(--transition),border-color var(--transition),color var(--transition);background:var(--surface-3);color:var(--text-muted);border:1px solid var(--border); }
.ac-btn-ignore:hover { background:var(--border);color:var(--text); }
.ac-btn-fp     { display:inline-flex;align-items:center;gap:5px;padding:7px 13px;font-size:0.79rem;font-weight:600;border-radius:var(--radius);cursor:pointer;white-space:nowrap;transition:background var(--transition),border-color var(--transition),color var(--transition);background:rgba(234,179,8,.1);color:#d97706;border:1px solid rgba(234,179,8,.28); }
.ac-btn-fp:hover { background:rgba(234,179,8,.2);border-color:rgba(234,179,8,.45);color:#fbbf24; }

/* AI score badge + note */
.ac-ai-row { display: flex; align-items: center; gap: 8px; margin: 8px 0; flex-wrap: wrap; }
.ac-ai-badge {
    display: inline-flex;
    align-items: center;
    padding: 2px 9px;
    border-radius: 99px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: .02em;
}
.ac-ai-badge.ai-fp        { background: rgba(34,197,94,.12);  color: #4ade80; border: 1px solid rgba(34,197,94,.3); }
.ac-ai-badge.ai-uncertain { background: rgba(234,179,8,.12);  color: #fbbf24; border: 1px solid rgba(234,179,8,.3); }
.ac-ai-badge.ai-cheat     { background: rgba(239,68,68,.14);  color: #f87171; border: 1px solid rgba(239,68,68,.32); }
.ac-ai-note { font-size: 0.78rem; color: var(--text-muted); font-style: italic; }

/* AI dot on player card */
.ac-ai-dot {
    display: inline-block;
    width: 8px; height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
    vertical-align: middle;
}
.ac-ai-dot.ai-dot-fp        { background: #4ade80; box-shadow: 0 0 5px rgba(34,197,94,.5); }
.ac-ai-dot.ai-dot-uncertain { background: #fbbf24; box-shadow: 0 0 5px rgba(234,179,8,.5); }
.ac-ai-dot.ai-dot-cheat     { background: #f87171; box-shadow: 0 0 5px rgba(239,68,68,.5); }

/* Cumulative risk badge on player card */
.ac-risk-badge {
    display: inline-block;
    padding: 1px 7px;
    border-radius: 20px;
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    border: 1px solid;
    flex-shrink: 0;
}
.ac-risk-badge.ac-risk-low  { background: rgba(34,197,94,.10);  color: #4ade80; border-color: rgba(34,197,94,.25); }
.ac-risk-badge.ac-risk-mid  { background: rgba(234,179,8,.10);  color: #fbbf24; border-color: rgba(234,179,8,.25); }
.ac-risk-badge.ac-risk-high { background: rgba(239,68,68,.12);  color: #f87171; border-color: rgba(239,68,68,.3); }

/* False positive checklist inside modal */
.ac-fp-view { padding: 16px 22px; }
.ac-fp-heading { font-size: 0.82rem; color: #aaa; margin-bottom: 12px; }
.ac-fp-selectall {
    border-bottom: 1px solid #2a2a2a;
    padding-bottom: 10px;
    margin-bottom: 8px;
    font-weight: 600;
    color: #e0e0e0;
}
.ac-fp-list { display: flex; flex-direction: column; gap: 4px; }
.ac-fp-row {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 7px 10px;
    border-radius: 6px;
    cursor: pointer;
    transition: background .12s;
}
.ac-fp-row:hover { background: rgba(255,255,255,0.04); }
.ac-fp-row input[type="checkbox"] { accent-color: #fbbf24; width: 15px; height: 15px; flex-shrink: 0; cursor: pointer; }
.ac-fp-detail { font-size: 0.82rem; color: #c0c0c0; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ac-res-falsepositive { background: rgba(234,179,8,.12); color: #fbbf24; border: 1px solid rgba(234,179,8,.3); }

.ac-resolution-badge {
    font-size: 0.7rem;
    font-weight: 600;
    padding: 2px 7px;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: .04em;
}
.ac-res-banned  { background: rgba(239,68,68,.15); color: #f87171; border: 1px solid rgba(239,68,68,.3); }
.ac-res-ignored { background: var(--surface-3); color: var(--text-muted); border: 1px solid var(--border); }

.ac-resolved-by { font-size: 0.75rem; color: var(--text-dim); margin-top: 6px; }

/* ── Player alert cards (single-row minimal) ───────────────────────────────── */
.ac-player-card {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--surface-2);
    border-left: 3px solid var(--border);
    border-radius: var(--radius);
    padding: 10px 14px;
    margin-bottom: 6px;
    cursor: pointer;
    user-select: none;
    transition: border-color .15s, background .15s;
    flex-wrap: wrap;
}
.ac-player-card:hover { background: var(--surface-3); }
.ac-player-card.ac-card-critical { border-left-color: #ef4444; }
.ac-player-card.ac-card-high     { border-left-color: #f97316; }
.ac-player-card.ac-card-low      { border-left-color: #22c55e; }

.ac-card-name {
    font-weight: 600;
    color: #f0f0f0;
    font-size: 0.95rem;
}

.ac-alert-count-badge {
    background: rgba(255,255,255,0.07);
    color: #aaa;
    font-size: 0.72rem;
    padding: 2px 8px;
    border-radius: 10px;
    white-space: nowrap;
    border: 1px solid var(--border);
}

.ac-time { font-size: 0.75rem; color: #888; margin-left: auto; white-space: nowrap; }

@keyframes acCardFlash {
    0%   { background: rgba(239,68,68,0.18); }
    100% { background: var(--surface-2); }
}
.ac-card-new { animation: acCardFlash 1.5s ease-out; }

/* ── Alert card viewer pill ─────────────────────────────────────────────────── */
.ac-card-alert-viewers {
    font-size: 0.72rem;
    font-weight: 600;
    color: #93c5fd;
    background: linear-gradient(135deg, rgba(59,130,246,0.22), rgba(99,102,241,0.18));
    border: 1px solid rgba(99,102,241,0.4);
    border-radius: 10px;
    padding: 2px 9px;
    white-space: nowrap;
    text-shadow: 0 0 8px rgba(147,197,253,0.4);
}

/* ── Modal ─────────────────────────────────────────────────────────────────── */
.ac-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.75);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}
.ac-modal {
    background: #141414;
    border: 1px solid #2e2e2e;
    border-radius: 14px;
    width: 100%;
    max-width: 720px;
    max-height: 88vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 32px 80px rgba(0,0,0,0.85);
}
.ac-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 22px;
    border-bottom: 1px solid #2a2a2a;
    flex-shrink: 0;
    background: #161616;
}
.ac-modal-title {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}
.ac-modal-player-name {
    font-size: 1.05rem;
    font-weight: 700;
    color: #f0f0f0;
    text-decoration: none;
}
.ac-modal-player-name:hover { color: #60a5fa; text-decoration: underline; }
.ac-modal-steamid { font-size: 0.78rem; color: #888; font-family: monospace; }

.ac-modal-close {
    background: none;
    border: none;
    color: #666;
    font-size: 1rem;
    cursor: pointer;
    padding: 5px 9px;
    border-radius: 6px;
    transition: background .15s, color .15s;
    flex-shrink: 0;
}
.ac-modal-close:hover { background: rgba(255,255,255,0.08); color: #e0e0e0; }

.ac-modal-body {
    overflow-y: auto;
    flex: 1;
    background: #141414;
}
.ac-modal-body::-webkit-scrollbar              { width: 5px; }
.ac-modal-body::-webkit-scrollbar-track       { background: transparent; }
.ac-modal-body::-webkit-scrollbar-thumb       { background: var(--border); border-radius: 3px; }
.ac-modal-body::-webkit-scrollbar-thumb:hover { background: var(--text-dim); }
.ac-modal-loading {
    padding: 40px;
    text-align: center;
    color: #666;
}
.ac-modal-footer {
    padding: 12px 18px;
    border-top: 1px solid #2a2a2a;
    display: flex;
    align-items: center;
    gap: 7px;
    background: #161616;
    flex-shrink: 0;
}

/* Flag pills row at top of modal body */
.ac-modal-flags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: 14px 22px;
    border-bottom: 1px solid #2a2a2a;
    background: #111;
}
.ac-modal-flag {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 3px 9px;
    border-radius: 4px;
    letter-spacing: .04em;
    text-transform: uppercase;
}
.ac-flag-time { font-weight: 400; opacity: .75; font-size: 0.7rem; }

/* Stat grid (management only) */
.ac-modal-stat-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1px;
    border-bottom: 1px solid #2a2a2a;
    background: #2a2a2a;
}
.ac-modal-stat-card {
    background: #181818;
    padding: 16px 20px;
}
.ac-modal-stat-title {
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: .08em;
    color: #666;
    text-transform: uppercase;
    margin-bottom: 12px;
}
.ac-modal-stat-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 4px 0;
    font-size: 0.85rem;
    color: #b0b0b0;
    border-bottom: 1px solid #222;
}
.ac-modal-stat-row:last-child { border-bottom: none; }
.ac-modal-stat-val { font-weight: 600; color: #e8e8e8; }
.ac-modal-stat-hi  { color: #4ade80; }

/* Alert detail rows in modal */
.ac-modal-alerts-section { padding: 4px 0; }
.ac-detail-row {
    padding: 12px 22px;
    border-bottom: 1px solid #1e1e1e;
}
.ac-detail-row:last-child { border-bottom: none; }
.ac-detail-row-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
    flex-wrap: wrap;
}
.ac-detail-text { font-size: 0.88rem; color: #d0d0d0; line-height: 1.45; }
.ac-detail-pos  { font-size: 0.74rem; color: #666; margin-top: 4px; }
.ac-modal-weapon { font-size: 0.8rem; color: #888; }

/* ── AC Modal — mobile ───────────────────────────────────────────────────── */
@media (max-width: 600px) {
    .ac-modal-overlay {
        padding: 0;
        align-items: flex-end;
    }
    .ac-modal {
        max-width: 100%;
        max-height: 92vh;
        border-radius: 14px 14px 0 0;
        border-left: none;
        border-right: none;
        border-bottom: none;
    }
    .ac-modal-header {
        padding: 13px 14px;
        gap: 8px;
    }
    .ac-modal-title {
        gap: 6px;
        row-gap: 4px;
        min-width: 0;
        flex: 1;
    }
    .ac-modal-player-name {
        font-size: 0.92rem;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        max-width: 180px;
    }
    .ac-modal-steamid {
        font-size: 0.7rem;
    }
    .ac-modal-footer {
        padding: 10px 12px;
        flex-wrap: wrap;
        gap: 6px;
    }
    .ac-modal-footer .ac-foot-btn,
    .ac-modal-footer .ac-btn-ban,
    .ac-modal-footer .ac-btn-ignore,
    .ac-modal-footer .ac-btn-fp {
        margin-left: 0 !important;
        flex: 1 1 auto;
        justify-content: center;
        min-width: 0;
        font-size: 0.76rem;
        padding: 7px 8px;
    }
    .ac-modal-footer .ac-foot-fp {
        margin-left: 0 !important;
        flex: 0 0 100%;
        justify-content: center;
    }
    .ac-foot-divider { display: none; }
    .ac-modal-flags {
        padding: 10px 14px;
        gap: 5px;
    }
    .ac-modal-stat-grid {
        grid-template-columns: 1fr;
    }
    .ac-modal-stat-card {
        padding: 12px 14px;
    }
    .ac-detail-row {
        padding: 10px 14px;
    }
}

/* tabs reuse .config-tabs / .config-tab styles */
.content-page-arrow { font-size: 0.78rem; color: var(--accent); margin-top: 6px; }

/* ─── Staff Metrics ─────────────────────────────────────────────────────────── */
.metrics-month-nav {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-bottom: 20px;
}
.metrics-month-label {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text);
    min-width: 140px;
    text-align: center;
}
.metrics-month-arrow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: var(--surface);
    border: 1px solid var(--border);
    color: var(--text);
    font-size: 1rem;
    text-decoration: none;
    transition: background .15s, border-color .15s;
}
.metrics-month-arrow:hover { background: var(--surface-2); border-color: var(--accent); color: var(--accent); text-decoration: none; }
.metrics-month-arrow-disabled { opacity: 0.3; cursor: default; pointer-events: none; }
.role-tag-former { background: rgba(120,120,120,0.15); color: #888; }
.metrics-leaderboard {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.metrics-row {
    display: grid;
    grid-template-columns: 44px 1fr auto auto;
    align-items: center;
    gap: 16px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 12px 16px;
    transition: border-color .15s;
}
.metrics-row:hover { border-color: var(--border-hover); }

/* Rank number */
.metrics-rank {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 0.875rem;
    font-weight: 700;
    background: var(--surface-3);
    color: var(--text-muted);
    flex-shrink: 0;
}
.metrics-rank-gold   { background: rgba(212,175,55,.15); color: #d4af37; border: 1px solid rgba(212,175,55,.35); }
.metrics-rank-silver { background: rgba(192,192,192,.12); color: #c0c0c0; border: 1px solid rgba(192,192,192,.3); }
.metrics-rank-bronze { background: rgba(176,100,50,.15); color: #cd7f32; border: 1px solid rgba(176,100,50,.3); }

/* Identity */
.metrics-identity {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}
.metrics-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}
.metrics-avatar-fallback {
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--surface-3);
    color: var(--text-muted);
    font-size: 0.85rem;
    font-weight: 600;
}
.metrics-name-group {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
}
.metrics-name {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.metrics-role-badge {
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: .05em;
    text-transform: uppercase;
    padding: 1px 6px;
    border-radius: 3px;
    width: fit-content;
}
.metrics-role-owner      { background: rgba(212,175,55,.15); color: #d4af37; border: 1px solid rgba(212,175,55,.3); }
.metrics-role-management { background: rgba(52,152,219,.12); color: #60a5fa; border: 1px solid rgba(52,152,219,.25); }
.metrics-role-admin      { background: rgba(192,57,43,.12); color: #f87171; border: 1px solid rgba(192,57,43,.3); }
.metrics-role-trial      { background: var(--surface-3); color: var(--text-muted); border: 1px solid var(--border); }

/* Breakdown */
.metrics-breakdown {
    display: flex;
    gap: 20px;
    flex-shrink: 0;
}
.metrics-breakdown-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    min-width: 40px;
}
.metrics-breakdown-label {
    font-size: 0.65rem;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: .05em;
}
.metrics-breakdown-val {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text);
}
.metrics-val-red   { color: #f87171; }
.metrics-val-muted { color: var(--text-muted); }

/* Total + contribution bar */
.metrics-total-col {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
    min-width: 90px;
    flex-shrink: 0;
}
.metrics-total-num {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--text);
    line-height: 1;
}
.metrics-contrib-bar-wrap {
    width: 90px;
    height: 4px;
    background: var(--surface-3);
    border-radius: 2px;
    overflow: hidden;
}
.metrics-contrib-bar {
    height: 100%;
    background: var(--accent);
    border-radius: 2px;
    min-width: 2px;
    transition: width .3s ease;
}
.metrics-contrib-pct {
    font-size: 0.72rem;
    color: var(--text-muted);
}

@media (max-width: 700px) {
    .metrics-row {
        grid-template-columns: 36px 1fr;
        grid-template-rows: auto auto;
    }
    .metrics-breakdown { display: none; }
    .metrics-total-col {
        grid-column: 2;
        align-items: flex-start;
        flex-direction: row;
        align-items: center;
        gap: 8px;
    }
}

/* ── AC Settings page ───────────────────────────────────────────────────────── */
.ac-settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 16px;
}
.settings-section {
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 18px 20px;
}
.settings-section-title {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 14px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border);
}
.settings-field {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 14px;
}
.settings-field:last-child { margin-bottom: 0; }
.settings-field label {
    font-size: 0.83rem;
    color: var(--text);
    font-weight: 500;
}
.settings-hint {
    font-size: 0.74rem;
    color: var(--text-muted);
    line-height: 1.4;
}

/* ── Rules page ─────────────────────────────────────────────────────────── */
.rules-body { display: flex; flex-direction: column; gap: 16px; }

.rules-section {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 10px;
    overflow: hidden;
}

.rules-section-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    background: rgba(255,255,255,0.03);
    border-bottom: 1px solid var(--border);
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--text);
}

.rules-section-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--accent);
    color: #fff;
    font-size: 0.8rem;
    font-weight: 700;
    flex-shrink: 0;
}

.rules-section-body { padding: 8px 0; }

.rules-rule {
    display: flex;
    align-items: baseline;
    gap: 12px;
    padding: 9px 20px;
    border-bottom: 1px solid rgba(255,255,255,0.04);
    font-size: 0.9rem;
    line-height: 1.5;
}
.rules-rule:last-child { border-bottom: none; }
.rules-rule:hover { background: rgba(255,255,255,0.02); }

.rules-rule-num {
    font-size: 0.75rem;
    color: var(--text-dim);
    font-family: 'JetBrains Mono', monospace;
    flex-shrink: 0;
    min-width: 36px;
}

.rules-rule-text { color: var(--text); }

/* ─── Form inputs (shared dark theme) ───────────────────────────────────── */
.form-input,
.form-select,
.form-textarea {
    display: block;
    width: 100%;
    background: #1a1a1a;
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 8px;
    color: #e5e5e5;
    padding: 0.55rem 0.85rem;
    font-size: 0.9rem;
    font-family: inherit;
    transition: border-color .15s;
    box-sizing: border-box;
}
.form-input:focus,
.form-select:focus,
.form-textarea:focus {
    outline: none;
    border-color: rgba(220,50,47,0.6);
    box-shadow: 0 0 0 3px rgba(220,50,47,0.12);
}
.form-input::placeholder,
.form-textarea::placeholder { color: #555; }
.form-group { margin-bottom: 1.1rem; }
.form-label {
    display: block;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: #888;
    margin-bottom: 0.4rem;
}
.form-hint {
    display: block;
    font-size: 0.75rem;
    color: #555;
    margin-top: 0.3rem;
}
