/* ───────────────────────────────────────────────
   ROBLOX MURDER MYSTERY 2 — USER-FRIENDLY & PREMIUM DESIGN SYSTEM
   ──────────────────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@700;900&family=Montserrat:wght@400;500;600;700;800;900&display=swap');

:root {
    /* High Legibility Dark Mode Palette */
    --bg-base: hsl(0, 0%, 4%);
    --bg-surface: hsl(350, 6%, 7%);
    --bg-card: rgba(18, 15, 15, 0.7);
    --bg-modal: rgba(10, 8, 8, 0.98);
    --border-color: rgba(239, 68, 68, 0.18);
    --border-hover: rgba(251, 191, 36, 0.5);
    
    /* Text */
    --text-primary: #ffffff;
    --text-muted: #cbd5e1;
    
    /* Colors & Accents */
    --accent: hsl(45, 100%, 50%); /* Amber gold */
    --accent-glow: rgba(251, 191, 36, 0.25);
    --primary: hsl(354, 85%, 53%); /* Neon Crimson */
    --primary-glow: rgba(239, 68, 68, 0.4);
    
    /* MM2 Rarity colors */
    --rarity-unique: #fbbf24;
    --rarity-ancient: #c026d3;
    --rarity-godly: #ef4444;
    --rarity-chroma: #00ffff;
    
    /* Radius & Soft Shadows */
    --radius-lg: 16px;
    --radius-md: 12px;
    --radius-sm: 8px;
    --shadow-soft: 0 16px 40px rgba(0, 0, 0, 0.9);
    --shadow-glow: 0 0 24px rgba(239, 68, 68, 0.12);
    
    /* Fonts */
    --font-display: "Cinzel", "Montserrat", serif;
    --font-body: "Montserrat", sans-serif;
}

/* Base resets */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html, body {
    height: 100%;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-base);
    color: var(--text-primary);
    line-height: 1.55;
    overflow-x: hidden;
    position: relative;
    background-image: 
        radial-gradient(circle at 10% 20%, rgba(239, 68, 68, 0.06) 0%, transparent 45%),
        radial-gradient(circle at 90% 80%, rgba(251, 191, 36, 0.03) 0%, transparent 45%);
    background-attachment: fixed;
}

img {
    max-width: 100%;
    display: block;
}

/* ─── FLOATING GLOWING EMBERS ────────────────── */
.animated-background {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.leaf-particle {
    position: absolute;
    width: 10px;
    height: 10px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='12' r='8' fill='%23ef4444' opacity='0.25'/%3E%3Ccircle cx='12' cy='12' r='4' fill='%23fbbf24' opacity='0.45'/%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
    animation: fall-and-drift linear infinite;
    top: -50px;
}

@keyframes fall-and-drift {
    0% {
        transform: translateY(0) rotate(0deg) translateX(0);
        opacity: 0;
    }
    10% {
        opacity: 0.7;
    }
    90% {
        opacity: 0.7;
    }
    100% {
        transform: translateY(105vh) rotate(90deg) translateX(40px);
        opacity: 0;
    }
}

/* ─── LAYOUT ──────────────────────────────────── */
.main-container {
    min-height: 100vh;
    padding: 30px 16px 80px;
    position: relative;
    z-index: 1;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
}

/* ─── LANG SWITCHER ───────────────────────────── */
/* ─── LANG SWITCHER ───────────────────────────── */
.header-utility-row {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 16px;
}

.lang-switcher {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(15, 10, 10, 0.9);
    border: 1px solid var(--border-color);
    border-radius: 999px;
    padding: 8px 16px;
    backdrop-filter: blur(20px);
    box-shadow: var(--shadow-soft);
}

.lang-button {
    background: transparent;
    border: none;
    display: flex;
    align-items: center;
    gap: 6px;
    font-family: var(--font-body);
    font-weight: 700;
    color: var(--text-primary);
    cursor: pointer;
    font-size: 0.85rem;
}

.lang-select {
    border: none;
    background: transparent;
    font-weight: 700;
    color: var(--text-primary);
    font-family: var(--font-body);
    cursor: pointer;
    outline: none;
    font-size: 0.85rem;
}

.lang-select option {
    background-color: var(--bg-surface);
    color: var(--text-primary);
}

/* ─── LIVE ACTIVITY FEED ──────────────────────── */
.live-feed-banner {
    background: rgba(15, 10, 10, 0.85);
    border-bottom: 1px solid var(--border-color);
    backdrop-filter: blur(20px);
    height: 44px;
    width: 100%;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 999;
    display: flex;
    align-items: center;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.5);
}

.live-feed-label {
    background: linear-gradient(135deg, var(--primary), #7f1d1d);
    color: white;
    font-weight: 800;
    font-size: 0.75rem;
    height: 100%;
    display: flex;
    align-items: center;
    padding: 0 16px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    z-index: 2;
    box-shadow: 4px 0 12px rgba(0,0,0,0.4);
    white-space: nowrap;
}

.live-feed-track {
    display: flex;
    align-items: center;
    white-space: nowrap;
    padding-left: 20px;
    z-index: 1;
}

.live-feed-item {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-right: 40px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    animation: feed-scroll 34s linear infinite;
}

.feed-username {
    color: white;
    font-weight: 700;
}

.feed-item-claimed {
    font-weight: 800;
}

.feed-time {
    color: rgba(255,255,255,0.2);
    font-size: 0.75rem;
}

.feed-dot {
    width: 6px;
    height: 6px;
    background: var(--primary);
    border-radius: 50%;
    box-shadow: 0 0 6px var(--primary);
}

@keyframes feed-scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* ─── HERO SECTION ────────────────────────────── */
.section-header {
    text-align: center;
    margin-bottom: 30px;
}

.wiki-hero {
    background: linear-gradient(135deg, rgba(20, 12, 12, 0.9) 0%, rgba(10, 6, 6, 0.97) 100%);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 44px 32px;
    box-shadow: var(--shadow-soft), var(--shadow-glow);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(28px);
}

.wiki-hero::before {
    content: "";
    position: absolute;
    top: -30%;
    left: -20%;
    width: 60%;
    height: 160%;
    background: radial-gradient(ellipse, rgba(239, 68, 68, 0.12), transparent 70%);
    pointer-events: none;
}

.wiki-top {
    display: flex;
    gap: 32px;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    text-align: left;
}

.section-logo {
    width: clamp(90px, 16vw, 130px);
    border-radius: 12px;
    border: 2px solid var(--border-color);
    box-shadow: var(--shadow-soft);
    animation: float-bob 6s ease-in-out infinite;
    background: rgba(0, 0, 0, 0.4);
}

.wiki-title {
    display: grid;
    gap: 6px;
}

.wiki-label {
    text-transform: uppercase;
    letter-spacing: 0.25em;
    font-size: 0.75rem;
    color: var(--primary);
    font-weight: 800;
}

.section-title {
    font-family: var(--font-display);
    font-size: clamp(2rem, 5vw, 3.4rem);
    letter-spacing: 0.05em;
    color: var(--text-primary);
    text-shadow: 0 4px 14px rgba(0,0,0,0.8);
    line-height: 1.15;
}

.logo-line-1 {
    color: white;
}

.section-subtitle {
    margin-top: 10px;
    font-size: 1.05rem;
    color: var(--text-muted);
    font-weight: 500;
}

.hero-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin-top: 32px;
    flex-wrap: wrap;
}

.btn-primary {
    padding: 14px 38px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--primary), #7f1d1d);
    color: #ffffff;
    font-weight: 800;
    text-decoration: none;
    border: none;
    box-shadow: 0 6px 20px rgba(239, 68, 68, 0.4);
    font-family: var(--font-body);
    font-size: 1rem;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

.btn-primary:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 10px 28px rgba(239, 68, 68, 0.55), 0 0 15px rgba(251, 191, 36, 0.25);
}

.hero-note {
    font-size: 0.9rem;
    color: var(--text-muted);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* ─── WIKI STATS ──────────────────────────────── */
.wiki-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
    gap: 14px;
    margin-top: 28px;
    width: 100%;
}

.stat {
    background: rgba(0, 0, 0, 0.45);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 14px 18px;
    text-align: center;
    transition: border-color 0.25s, box-shadow 0.25s;
}

.stat:hover {
    border-color: var(--primary);
    box-shadow: 0 0 10px rgba(239, 68, 68, 0.2);
}

.stat-number {
    font-family: var(--font-display);
    font-size: 1.35rem;
    color: var(--accent);
    text-shadow: 0 2px 4px rgba(0,0,0,0.6);
}

.stat-label {
    display: block;
    font-size: 0.7rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 700;
    margin-top: 4px;
}

/* ─── HOW IT WORKS STEPS ──────────────────────── */
.steps-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
    margin-top: 32px;
    width: 100%;
}

.step-card {
    background: rgba(15, 12, 12, 0.55);
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: var(--radius-md);
    padding: 22px;
    display: flex;
    align-items: center;
    gap: 16px;
    text-align: left;
    transition: border-color 0.25s, transform 0.25s, box-shadow 0.25s;
}

.step-card:hover {
    border-color: var(--primary);
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.4);
}

.step-badge {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), #7f1d1d);
    color: white;
    font-weight: 800;
    display: grid;
    place-items: center;
    font-size: 1.1rem;
    flex-shrink: 0;
    box-shadow: 0 4px 10px rgba(239, 68, 68, 0.35);
}

.step-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.step-title {
    font-weight: 800;
    font-size: 0.95rem;
    color: white;
    letter-spacing: 0.02em;
}

.step-desc {
    font-size: 0.82rem;
    color: var(--text-muted);
    line-height: 1.45;
}

/* ─── SOCIAL PROOF ────────────────────────────── */
.social-proof {
    margin-top: 20px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 18px;
    border-radius: 999px;
    background: rgba(251, 191, 36, 0.06);
    border: 1px solid rgba(251, 191, 36, 0.2);
    font-size: 0.88rem;
    color: #ffffff;
    font-weight: 600;
    backdrop-filter: blur(12px);
}

.social-proof .dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--primary);
    box-shadow: 0 0 10px var(--primary);
    animation: pulse-dot 1.8s ease-in-out infinite;
}

/* ─── INTERACTIVE DASHBOARD CONTROLS ──────────── */
.dashboard-controls {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 24px;
    background: rgba(15, 10, 10, 0.65);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 18px;
    backdrop-filter: blur(20px);
}

@media (min-width: 768px) {
    .dashboard-controls {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }
}

.search-wrapper {
    position: relative;
    flex: 1;
    max-width: 100%;
}

@media (min-width: 768px) {
    .search-wrapper {
        max-width: 340px;
    }
}

.search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 1.1rem;
    pointer-events: none;
}

.search-input {
    width: 100%;
    background: rgba(0, 0, 0, 0.5);
    border: 1.5px solid var(--border-color);
    border-radius: 99px;
    padding: 12px 16px 12px 42px;
    color: white;
    font-family: var(--font-body);
    font-size: 0.95rem;
    outline: none;
    transition: all 0.25s ease;
}

.search-input:focus {
    border-color: var(--primary);
    background: rgba(0, 0, 0, 0.6);
    box-shadow: 0 0 12px rgba(239, 68, 68, 0.25);
}

.search-input::placeholder {
    color: rgba(255,255,255,0.4);
}

.category-tabs {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    scrollbar-width: none;
    padding-bottom: 4px;
}

.category-tabs::-webkit-scrollbar {
    display: none;
}

.tab-btn {
    background: rgba(0, 0, 0, 0.4);
    border: 1.5px solid var(--border-color);
    color: var(--text-muted);
    border-radius: 99px;
    padding: 10px 18px;
    font-size: 0.88rem;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.25s ease;
    font-family: var(--font-body);
}

.tab-btn:hover {
    color: white;
    border-color: var(--border-hover);
    background: rgba(251, 191, 36, 0.05);
}

.tab-btn.active {
    background: linear-gradient(135deg, var(--primary), #7f1d1d);
    color: white;
    border-color: transparent;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.4);
}

/* ─── ITEMS GRID & RARITIES ───────────────────── */
.items-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
    gap: 24px;
}

.item-card {
    background: var(--bg-card);
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    box-shadow: var(--shadow-soft);
    transition: all 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(20px);
}

.item-card:hover {
    transform: translateY(-4px);
}

/* Godly Card Styling */
.item-card.rarity-godly {
    border-color: rgba(239, 68, 68, 0.2);
}
.item-card.rarity-godly:hover {
    border-color: var(--rarity-godly);
    box-shadow: 0 12px 28px rgba(239, 68, 68, 0.3);
}

/* Ancient Card Styling */
.item-card.rarity-ancient {
    border-color: rgba(168, 85, 247, 0.2);
}
.item-card.rarity-ancient:hover {
    border-color: var(--rarity-ancient);
    box-shadow: 0 12px 28px rgba(168, 85, 247, 0.3);
}

/* Unique Card Styling */
.item-card.rarity-unique {
    border-color: rgba(245, 158, 11, 0.2);
}
.item-card.rarity-unique:hover {
    border-color: var(--rarity-unique);
    box-shadow: 0 12px 28px rgba(245, 158, 11, 0.35);
}

/* Chroma Card Styling (Rainbow cycling border - Slower and calmer) */
.item-card.rarity-chroma {
    animation: chroma-border 12s linear infinite;
}

@keyframes chroma-border {
    0%, 100% { border-color: #ff007f; box-shadow: 0 0 10px rgba(255, 0, 127, 0.12); }
    17% { border-color: #7f00ff; box-shadow: 0 0 12px rgba(127, 0, 255, 0.2); }
    33% { border-color: #00ffff; box-shadow: 0 0 12px rgba(0, 255, 255, 0.2); }
    50% { border-color: #7fff00; box-shadow: 0 0 12px rgba(127, 255, 0, 0.2); }
    67% { border-color: #ff7f00; box-shadow: 0 0 12px rgba(255, 127, 0, 0.2); }
    83% { border-color: #ff0000; box-shadow: 0 0 12px rgba(255, 0, 0, 0.2); }
}

.item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.stock-count {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    font-weight: 700;
}

.rarity-badge {
    font-size: 0.68rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 3px 9px;
    border-radius: 99px;
    color: white;
}

.rarity-badge.godly {
    background: rgba(239, 68, 68, 0.15);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.rarity-badge.ancient {
    background: rgba(168, 85, 247, 0.15);
    color: #c084fc;
    border: 1px solid rgba(168, 85, 247, 0.3);
}

.rarity-badge.unique {
    background: rgba(245, 158, 11, 0.15);
    color: #fbbf24;
    border: 1px solid rgba(245, 158, 11, 0.3);
    animation: pulse-gold 2s infinite;
}

.rarity-badge.chroma {
    background: linear-gradient(90deg, #ff007f, #7f00ff, #00ffff, #7fff00, #ff7f00, #ff007f);
    background-size: 400% 400%;
    animation: rainbow-bg 8s linear infinite;
    color: #ffffff;
    border: none;
    text-shadow: 0 1px 2px rgba(0,0,0,0.5);
    box-shadow: 0 0 8px rgba(0, 255, 255, 0.25);
}

@keyframes rainbow-bg {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes pulse-gold {
    0%, 100% { box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.4); }
    50% { box-shadow: 0 0 8px 2px rgba(245, 158, 11, 0.4); }
}

.item-image {
    background: linear-gradient(160deg, rgba(20, 8, 8, 0.7) 0%, rgba(0, 0, 0, 0.5) 100%);
    border-radius: var(--radius-md);
    padding: 16px;
    display: grid;
    place-items: center;
    min-height: 120px;
    border: 1px solid rgba(220, 38, 38, 0.12);
    position: relative;
}

.item-image img {
    width: auto;
    height: 95px;
    object-fit: contain;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.5));
}

.item-card:hover .item-image img {
    transform: translateY(-6px) scale(1.06);
}

.item-card.rarity-unique:hover .item-image img {
    filter: drop-shadow(0 0 12px rgba(245, 158, 11, 0.5));
}
.item-card.rarity-ancient:hover .item-image img {
    filter: drop-shadow(0 0 12px rgba(168, 85, 247, 0.5));
}
.item-card.rarity-godly:hover .item-image img {
    filter: drop-shadow(0 0 12px rgba(239, 68, 68, 0.5));
}
.item-card.rarity-chroma:hover .item-image img {
    filter: drop-shadow(0 0 14px rgba(0, 255, 255, 0.6));
}

.item-info {
    text-align: center;
}

.item-name {
    font-family: var(--font-body);
    font-weight: 800;
    font-size: 1rem;
    letter-spacing: 0.02em;
    color: var(--text-primary);
    transition: color 0.2s ease;
}

.item-card:hover .item-name {
    color: var(--primary);
}

/* ─── BUTTONS ─────────────────────────────────── */
.btn {
    border: none;
    cursor: pointer;
    font-family: var(--font-body);
}

.btn-claim {
    width: 100%;
    padding: 12px 18px;
    border-radius: 99px;
    background: linear-gradient(135deg, var(--primary), #7f1d1d);
    color: #ffffff;
    font-size: 0.95rem;
    font-weight: 800;
    border: none;
    box-shadow: 0 4px 12px rgba(220, 38, 38, 0.25);
    transition: all 0.2s ease;
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

.btn-claim:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(220, 38, 38, 0.4), 0 0 8px rgba(251, 191, 36, 0.2);
    background: linear-gradient(135deg, #ef4444, #991b1b);
}

/* Chroma button hover */
.item-card.rarity-chroma .btn-claim {
    background: linear-gradient(135deg, #00ffff, #0088cc);
    box-shadow: 0 4px 12px rgba(0, 255, 255, 0.2);
}
.item-card.rarity-chroma .btn-claim:hover {
    background: linear-gradient(135deg, #a7f3d0, #00ffff);
    box-shadow: 0 6px 16px rgba(0, 255, 255, 0.4);
}

/* Ancient button hover */
.item-card.rarity-ancient .btn-claim {
    background: linear-gradient(135deg, var(--rarity-ancient), #6b21a8);
    box-shadow: 0 4px 12px rgba(168, 85, 247, 0.2);
}
.item-card.rarity-ancient .btn-claim:hover {
    background: linear-gradient(135deg, #c084fc, var(--rarity-ancient));
    box-shadow: 0 6px 16px rgba(168, 85, 247, 0.35);
}

/* Unique button hover */
.item-card.rarity-unique .btn-claim {
    background: linear-gradient(135deg, var(--rarity-unique), #b45309);
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.2);
}
.item-card.rarity-unique .btn-claim:hover {
    background: linear-gradient(135deg, #fbbf24, var(--rarity-unique));
    box-shadow: 0 6px 16px rgba(245, 158, 11, 0.35);
}

/* ─── MODAL MAIN DESIGN ────────────────────────── */
.gen-modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 99999;
    align-items: center;
    justify-content: center;
    padding: 16px;
}
.gen-modal.open {
    display: flex;
}

.gen-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(4, 2, 2, 0.88);
    backdrop-filter: blur(10px);
}

.gen-box {
    position: relative;
    z-index: 1;
    background: var(--bg-modal);
    border: 1.5px solid var(--border-color);
    color: #fff;
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 480px;
    box-shadow: 0 24px 80px rgba(0,0,0,0.95), 0 0 30px rgba(220, 38, 38, 0.15);
    overflow: hidden;
    animation: genSlideIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

@keyframes genSlideIn {
    from { opacity: 0; transform: translateY(30px) scale(0.95); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}

.gen-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 20px;
    border-bottom: 1px solid var(--border-color);
    background: linear-gradient(135deg, var(--bg-surface) 0%, rgba(15, 8, 8, 0.95) 100%);
}

.gen-logo-row {
    display: flex;
    align-items: center;
    gap: 12px;
}

.gen-logo-img {
    width: 38px;
    height: 38px;
    border-radius: 8px;
    object-fit: contain;
    background: rgba(0,0,0,0.4);
    border: 1px solid var(--border-color);
}

.gen-label {
    color: #fff;
    font-weight: 800;
    font-size: 1rem;
    letter-spacing: 0.01em;
}

.gen-sublabel {
    color: var(--text-muted);
    font-size: 0.72rem;
    font-weight: 600;
}

.gen-close {
    background: rgba(255,255,255,0.08);
    border: none;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    color: #fff;
    font-size: 0.85rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.25s;
    flex-shrink: 0;
    border: 1px solid rgba(255,255,255,0.05);
}

.gen-close:hover { 
    background: rgba(255,255,255,0.18); 
    transform: rotate(90deg);
}

/* ─── MODAL SCREEN 1: Input ───────────────────── */
.gen-screen {
    display: none;
    padding: 24px 22px;
    flex-direction: column;
    gap: 18px;
}
.gen-screen.active { 
    display: flex; 
}

.gen-item-preview {
    display: flex;
    align-items: center;
    gap: 14px;
    background: rgba(0, 0, 0, 0.45);
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 14px;
}

.gen-item-thumb {
    width: 58px;
    height: 58px;
    object-fit: contain;
    border-radius: 10px;
    background: rgba(0,0,0,0.4);
    border: 1px solid rgba(220, 38, 38, 0.15);
    padding: 6px;
    flex-shrink: 0;
}

.gen-item-details {
    flex: 1;
    min-width: 0;
}

.gen-item-name {
    font-weight: 800;
    font-size: 1.05rem;
    color: var(--accent);
}

.gen-item-badge {
    display: inline-block;
    margin-top: 4px;
    background: linear-gradient(135deg, var(--primary), #7f1d1d);
    color: #fff;
    font-size: 0.65rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    padding: 2px 8px;
    border-radius: 99px;
}

.gen-desc {
    color: var(--text-muted);
    font-size: 0.9rem;
    text-align: center;
    line-height: 1.5;
}

.gen-input-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 0 16px;
    background: rgba(0, 0, 0, 0.45);
    transition: all 0.25s ease;
}

.gen-input-wrap:focus-within { 
    border-color: var(--primary); 
    background: rgba(0, 0, 0, 0.65);
    box-shadow: 0 0 12px rgba(220, 38, 38, 0.25);
}

.gen-input-icon { 
    font-size: 1.1rem; 
    color: var(--primary);
}

.gen-input {
    flex: 1;
    border: none;
    background: transparent;
    padding: 14px 0;
    font-size: 1rem;
    font-family: var(--font-body);
    color: #fff;
    outline: none;
}
.gen-input::placeholder { 
    color: rgba(255,255,255,0.3); 
}

.gen-error-msg {
    color: #ef4444;
    font-size: 0.8rem;
    font-weight: 600;
    min-height: 14px;
    text-align: center;
}

.gen-btn-primary {
    width: 100%;
    background: linear-gradient(135deg, var(--primary), #7f1d1d);
    color: #fff;
    border: none;
    border-radius: var(--radius-md);
    padding: 15px;
    font-size: 1.05rem;
    font-weight: 800;
    font-family: var(--font-body);
    cursor: pointer;
    letter-spacing: 0.02em;
    transition: all 0.2s ease;
    box-shadow: 0 6px 20px rgba(220, 38, 38, 0.35);
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

.gen-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(220, 38, 38, 0.5), 0 0 10px rgba(251, 191, 36, 0.2);
}

.gen-security-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: var(--text-muted);
    font-size: 0.78rem;
}

.gen-security-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--primary);
    display: inline-block;
    box-shadow: 0 0 8px var(--primary);
}

/* ─── MODAL SCREEN 2: Username Scanner ────────── */
.gen-progress-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding-bottom: 10px;
}

.avatar-scanner-container {
    width: 110px;
    height: 110px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.55);
    border: 3px solid var(--border-color);
    position: relative;
    overflow: hidden;
    margin: 10px auto;
    box-shadow: 0 0 20px rgba(220, 38, 38, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
}

.scanner-avatar-img {
    width: 75px;
    height: 75px;
    object-fit: cover;
    opacity: 0.4;
    transition: opacity 0.5s ease;
}

.avatar-scanner-container.scanning {
    border-color: var(--primary);
    box-shadow: 0 0 25px rgba(220, 38, 38, 0.45);
}

.avatar-scanner-container.scanning .scanner-avatar-img {
    opacity: 0.8;
}

.scanner-laser {
    position: absolute;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, transparent, var(--primary), transparent);
    box-shadow: 0 0 12px var(--primary);
    top: 0;
    left: 0;
    opacity: 0;
}

.avatar-scanner-container.scanning .scanner-laser {
    opacity: 1;
    animation: laser-sweep 2s linear infinite;
}

@keyframes laser-sweep {
    0%, 100% { top: 0%; }
    50% { top: 100%; }
}

.gen-spinner-ring {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 4px solid rgba(220, 38, 38, 0.15);
    border-top-color: var(--accent);
    animation: genSpin 0.9s linear infinite;
}
@keyframes genSpin { 
    to { transform: rotate(360deg); } 
}

.gen-progress-label {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--accent);
    text-align: center;
}

.gen-steps {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.gen-step {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 14px;
    border-radius: var(--radius-md);
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.gen-step.active {
    background: rgba(251, 191, 36, 0.05);
    border-color: var(--accent);
}

.gen-step.done {
    background: rgba(220, 38, 38, 0.06);
    border-color: var(--primary);
}

.gen-step-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(220, 38, 38, 0.15);
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    font-weight: 800;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.gen-step.active .gen-step-icon { 
    background: var(--accent); 
    color: var(--bg-base); 
    box-shadow: 0 0 10px var(--accent-glow);
}

.gen-step.done .gen-step-icon { 
    background: var(--primary); 
    color: #fff; 
    box-shadow: 0 0 10px var(--primary-glow);
}

.gen-step-title {
    font-size: 0.88rem;
    font-weight: 700;
    color: #fff;
}

.gen-step-sub {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 1px;
}

.gen-step.done .gen-step-sub { 
    color: var(--primary); 
    font-weight: 600;
}

.gen-progress-bar-wrap {
    background: rgba(0, 0, 0, 0.5);
    border-radius: 99px;
    height: 6px;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,0.05);
}

.gen-progress-bar {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    border-radius: 99px;
    transition: width 0.6s ease;
}

/* ─── MODAL SCREEN 3: Success Claim ────────────── */
.gen-transfer-panel {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(0, 0, 0, 0.45);
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 16px 20px;
    margin-bottom: 8px;
    position: relative;
    overflow: hidden;
}

.transfer-node {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    width: 120px;
    z-index: 1;
}

.transfer-avatar-wrap, .transfer-item-wrap {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.5);
    border: 2px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.5);
}

.transfer-avatar-wrap {
    border-color: var(--primary);
    box-shadow: 0 0 15px rgba(220, 38, 38, 0.25);
}

.transfer-item-wrap {
    border-color: var(--accent);
    box-shadow: 0 0 15px rgba(251, 191, 36, 0.25);
    border-radius: 12px;
}

.transfer-avatar-img {
    width: 54px;
    height: 54px;
    border-radius: 50%;
    object-fit: cover;
}

.transfer-item-img {
    width: 54px;
    height: 54px;
    object-fit: contain;
    filter: drop-shadow(0 0 8px var(--accent-glow));
}

.transfer-status-indicator {
    position: absolute;
    bottom: -2px;
    right: -2px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    border: 2px solid #0f0808;
}

.transfer-status-indicator.online {
    background: #10b981;
    box-shadow: 0 0 8px #10b981;
    animation: pulse-green 1.5s infinite;
}

.transfer-status-indicator.pending {
    background: var(--accent);
    box-shadow: 0 0 8px var(--accent);
    animation: pulse-yellow 1.5s infinite;
}

@keyframes pulse-green {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.2); opacity: 0.7; }
}
@keyframes pulse-yellow {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.2); opacity: 0.7; }
}

.transfer-username, .transfer-item-name {
    font-size: 0.85rem;
    font-weight: 800;
    margin-top: 8px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    width: 100%;
}

.transfer-username {
    color: #fff;
}

.transfer-item-name {
    color: var(--accent);
}

.transfer-badge {
    font-size: 0.6rem;
    font-weight: 800;
    padding: 2px 6px;
    border-radius: 99px;
    margin-top: 4px;
    letter-spacing: 0.05em;
}

.online-badge {
    background: rgba(16, 185, 129, 0.1);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.2);
}

.pending-badge {
    background: rgba(251, 191, 36, 0.1);
    color: var(--accent);
    border: 1px solid rgba(251, 191, 36, 0.2);
}

.transfer-path {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding: 0 10px;
    height: 40px;
}

.transfer-line {
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    opacity: 0.5;
}

.transfer-pulse {
    position: absolute;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 10px var(--accent);
    animation: flow-pulse 2s infinite linear;
}

@keyframes flow-pulse {
    0% { left: 10%; opacity: 0; }
    10% { opacity: 1; }
    90% { opacity: 1; }
    100% { left: 90%; opacity: 0; }
}

.gen-success-sub {
    text-align: center;
    font-size: 0.9rem;
    color: var(--text-muted);
    line-height: 1.5;
}

.gen-final-card {
    display: flex;
    align-items: center;
    gap: 14px;
    background: rgba(0, 0, 0, 0.45);
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 12px 14px;
}

.gen-final-thumb {
    width: 52px;
    height: 52px;
    object-fit: contain;
    border-radius: 8px;
    background: rgba(0,0,0,0.3);
    padding: 4px;
    flex-shrink: 0;
}

.gen-final-name {
    font-weight: 800;
    font-size: 1rem;
    color: var(--accent);
}

.gen-final-tag {
    font-size: 0.75rem;
    color: var(--primary);
    font-weight: 700;
    margin-top: 2px;
}

.gen-expire-note {
    text-align: center;
    font-size: 0.8rem;
    color: #f87171;
    font-weight: 700;
}

/* ─── CPA OFFERS INTERACTIVE ───────────────────── */
.offers-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 20px 0;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.offers-loading .spinner {
    width: 32px;
    height: 32px;
    border: 3px solid rgba(220, 38, 38, 0.15);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin-bottom: 8px;
}

.offer-container {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 8px 0 16px;
}

.offer-item {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 16px 20px;
    background: linear-gradient(135deg, var(--primary), #7f1d1d);
    border: 1.5px solid rgba(251, 191, 36, 0.2);
    border-radius: var(--radius-md);
    color: #ffffff;
    text-decoration: none;
    font-size: 1.05rem;
    font-weight: 800;
    text-align: center;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 15px rgba(220, 38, 38, 0.35);
    position: relative;
    overflow: hidden;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    font-family: var(--font-body);
}

.offer-item:hover {
    border-color: var(--accent);
    background: linear-gradient(135deg, #ef4444, #7f1d1d);
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 8px 24px rgba(220, 38, 38, 0.5), 0 0 12px rgba(251, 191, 36, 0.25);
}

.offer-item::after {
    content: '';
    position: absolute;
    top: 0;
    left: -150%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.25), transparent);
    transform: skewX(-20deg);
}

.offer-item:hover::after {
    animation: offerShine 1.5s ease-in-out infinite;
}

@keyframes offerShine {
    100% { left: 150%; }
}

.cpa-modal-footer {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid rgba(220, 38, 38, 0.15);
}

.secure-footer-line {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-muted);
}

.status-dot {
    width: 8px;
    height: 8px;
    background-color: #fbbf24;
    border-radius: 50%;
    display: inline-block;
}

.status-dot.pulsing {
    animation: pulse-dot 1.5s infinite;
}

.status-dot.success {
    background-color: var(--primary);
    box-shadow: 0 0 8px var(--primary);
}

@keyframes pulse-dot {
    0% { transform: scale(1); opacity: 1; box-shadow: 0 0 0 0 rgba(251, 191, 36, 0.5); }
    70% { transform: scale(1.2); opacity: 0.8; box-shadow: 0 0 0 6px rgba(251, 191, 36, 0); }
    100% { transform: scale(1); opacity: 1; box-shadow: 0 0 0 0 rgba(251, 191, 36, 0); }
}

/* ─── FAQ ACCORDIONS ──────────────────────────── */
.faq-section {
    margin-top: 50px;
    margin-bottom: 24px;
}

.faq-container {
    background: rgba(15, 8, 8, 0.5);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 36px 28px;
    box-shadow: var(--shadow-soft), var(--shadow-glow);
    backdrop-filter: blur(12px);
}

.faq-section-title {
    font-family: var(--font-display);
    font-size: clamp(1.6rem, 4vw, 2.3rem);
    text-align: center;
    color: var(--accent);
    margin-bottom: 28px;
    letter-spacing: 0.05em;
    text-shadow: 0 2px 4px rgba(0,0,0,0.6);
}

.faq-item {
    border-bottom: 1px solid rgba(220, 38, 38, 0.15);
    padding: 18px 0;
}

.faq-item:last-of-type {
    border-bottom: none;
}

.faq-question {
    font-family: var(--font-body);
    font-weight: 700;
    font-size: 1.05rem;
    color: var(--text-primary);
    cursor: pointer;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    user-select: none;
    transition: color 0.2s ease;
}

.faq-question::after {
    content: "＋";
    font-size: 1.1rem;
    color: var(--primary);
    transition: transform 0.25s ease;
    font-weight: 800;
}

.faq-item[open] .faq-question {
    color: var(--accent);
}

.faq-item[open] .faq-question::after {
    content: "－";
    color: var(--accent);
    transform: rotate(180deg);
}

.faq-question::-webkit-details-marker {
    display: none;
}

.faq-answer {
    padding-top: 14px;
    padding-bottom: 4px;
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.6;
    animation: faqFadeIn 0.3s ease-in-out;
}

@keyframes faqFadeIn {
    from { opacity: 0; transform: translateY(-6px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ─── SITE FOOTER ─────────────────────────────── */
.site-footer {
    margin-top: 40px;
    padding: 24px 0 16px;
    border-top: 1px solid rgba(220, 38, 38, 0.15);
}

.footer-keywords {
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-muted);
    letter-spacing: 0.03em;
}

/* ─── iOS POPUP ───────────────────────────────── */
.ios-popup {
    position: fixed;
    inset: 0;
    z-index: 250000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ios-popup-background {
    position: absolute;
    inset: 0;
    background: rgba(4, 2, 2, 0.88);
    backdrop-filter: blur(8px);
}

.ios-popup-content {
    position: relative;
    z-index: 1;
    background: var(--bg-modal);
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-lg);
    width: min(92vw, 420px);
    padding: 26px;
    text-align: center;
    box-shadow: var(--shadow-soft);
}

.ios-instruction-gif {
    width: 100%;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    background: #000;
}

.ios-instruction-text h3 {
    font-family: var(--font-display);
    color: var(--accent);
    margin: 16px 0 8px;
    font-size: 1.4rem;
}

.ios-instruction-text p {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.5;
}

/* ─── UTILITIES & ANIMATIONS ──────────────────── */
@keyframes float-bob {
    0%, 100% { transform: translateY(0); }
    50%       { transform: translateY(-8px); }
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ─── RESPONSIVE BREAKPOINTS ──────────────────── */
@media (max-width: 900px) {
    .main-container { padding-top: 20px; }
    .wiki-top { flex-direction: column; text-align: center; }
    .wiki-stats { grid-template-columns: repeat(2, 1fr); }
    .steps-container { grid-template-columns: 1fr; }
    .items-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 14px;
    }
    .item-card { padding: 14px; gap: 10px; }
    .item-image { min-height: 100px; padding: 10px; }
    .item-image img { height: 75px; }
}

@media (max-width: 480px) {
    .items-grid { 
        grid-template-columns: repeat(2, 1fr); 
        gap: 10px; 
    }
    .item-card { padding: 10px; }
    .item-image img { height: 65px; }
    .item-name { font-size: 0.9rem; }
    .btn-claim { font-size: 0.85rem; padding: 10px 12px; }
    .category-tabs { margin-top: 8px; }
    .wiki-hero { padding: 28px 16px; }
}

@media (prefers-reduced-motion: reduce) {
    * { animation: none !important; transition: none !important; }
}

/* Compact steps layout inside generator modal */
.gen-screen .steps-container {
    grid-template-columns: 1fr;
    gap: 10px;
    margin-top: 14px;
    width: 100%;
}

.gen-screen .step-card {
    padding: 12px 16px;
    background: rgba(10, 6, 6, 0.45);
    border: 1px solid rgba(255, 255, 255, 0.04);
}

.gen-screen .step-badge {
    width: 32px;
    height: 32px;
    font-size: 0.95rem;
}

.gen-screen .step-title {
    font-size: 0.85rem;
}

.gen-screen .step-desc {
    font-size: 0.75rem;
    line-height: 1.35;
}

.gen-screen .social-proof {
    margin: 4px auto 8px;
    padding: 6px 14px;
    font-size: 0.8rem;
    display: inline-flex;
}

