@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@400;700;900&family=Rajdhani:wght@500;700&family=Playfair+Display:ital@1&family=Montserrat:wght@400;700&display=swap');

:root { 
    --neon: #00ffaa; 
    --neon-dim: rgba(0, 255, 170, 0.2);
    --bg: #030305; 
}

body { background: var(--bg); color: #fff; font-family: 'Rajdhani', sans-serif; margin: 0; overflow-x: hidden; }
.container { max-width: 1000px; margin: 0 auto; padding: 0 20px; }

.stars { position: fixed; top: 0; left: 0; width: 100%; height: 100%; z-index: -1; background-image: radial-gradient(2px 2px at 20px 30px, #fff, rgba(0,0,0,0)), radial-gradient(2px 2px at 50px 160px, #fff, rgba(0,0,0,0)); background-size: 250px 250px; opacity: 0.2; }

/* HERO */
.hero { height: 100vh; display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center; position: relative; }
.hero h1 { font-family: 'Orbitron', sans-serif; font-size: clamp(3rem, 10vw, 6rem); font-weight: 900; color: #fff; text-transform: uppercase; letter-spacing: 12px; margin: 0; }
.hero p { font-family: 'Playfair Display', serif; font-style: italic; color: #888; font-size: 1.3rem; margin-top: 10px; }
.scroll-down { position: absolute; bottom: 40px; font-size: 2.5rem; color: var(--neon); animation: bounce 2s infinite; cursor: pointer; text-shadow: 0 0 15px var(--neon-dim); }

/* LORE */
.lore-block { padding: 80px 0; border-left: 2px solid rgba(0,255,170,0.1); padding-left: 30px; margin: 40px 0; }
.lore-title { color: var(--neon); font-weight: 800; text-transform: uppercase; font-size: 0.8rem; letter-spacing: 3px; margin-bottom: 15px; }
.lore-content { font-size: 1.3rem; color: #bbb; line-height: 1.8; }
.highlight { color: #fff; border-bottom: 1px solid var(--neon); }

/* PORTAL */
.oath-container { padding: 100px 20px; text-align: center; position: relative; border: 1px solid var(--neon-dim); margin: 60px 0; background: rgba(0,0,0,0.3); border-radius: 20px; }
.oath-portal { width: 200px; height: 200px; border-radius: 50%; border: 4px solid #111; margin: 0 auto; position: relative; cursor: pointer; display: flex; align-items: center; justify-content: center; background: #000; }
.oath-portal.charging { border-color: var(--neon); box-shadow: 0 0 40px var(--neon-dim); }
.portal-text { font-family: 'Orbitron'; font-size: 0.8rem; color: #444; z-index: 10; transition: 0.3s; }
.progress-ring { position: absolute; top: 0; left: 0; transform: rotate(-90deg); }
.progress-ring circle { stroke-dasharray: 565; stroke-dashoffset: 565; transition: stroke-dashoffset 0.1s linear; }

/* CARDS */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 15px; }
.gamer-card { background: #0a0a0c; border: 1px solid #1a1a1f; padding: 12px; display: flex; align-items: center; gap: 12px; border-radius: 4px; transition: 0.2s; }
.gamer-card:hover { border-color: var(--neon); transform: translateY(-3px); }
.card-avatar { width: 48px; height: 48px; border-radius: 50%; border: 2px solid var(--neon); object-fit: cover; }

/* GG DRIVE */
.gg-button-box { text-align: center; margin: 100px 0; }
.gg-btn { background: transparent; border: 2px solid #fff; color: #fff; padding: 15px 45px; font-family: 'Orbitron'; font-weight: 900; cursor: pointer; transition: 0.2s; }
.gg-btn:hover { background: #fff; color: #000; box-shadow: 0 0 30px rgba(255,255,255,0.3); }

/* TERMINAL */
.terminal-box { background: #000; border: 1px solid #111; padding: 50px; margin: 100px 0; border-left: 4px solid var(--neon); clip-path: polygon(0 0, 97% 0, 100% 3%, 100% 100%, 3% 100%, 0 97%); }
.terminal-box input { width: 100%; background: #080808; border: 1px solid #222; color: var(--neon); padding: 18px; margin-bottom: 20px; font-family: 'Orbitron'; box-sizing: border-box; }
.init-btn { width: 100%; background: var(--neon); color: #000; border: none; padding: 25px; font-family: 'Orbitron'; font-weight: 900; cursor: pointer; font-size: 1.2rem; }

/* ANIMATIONS */
@keyframes bounce { 0%, 20%, 50%, 80%, 100% {transform: translateY(0);} 40% {transform: translateY(-10px);} }
@keyframes shake { 0% { transform: translate(1px, 1px); } 10% { transform: translate(-1px, -2px); } 100% { transform: translate(1px, -2px); } }
.shaking { animation: shake 0.1s infinite; }
.fade-in { opacity: 0; transform: translateY(20px); transition: 1.2s ease-out; }
.fade-in.visible { opacity: 1; transform: translateY(0); }
.flash-white { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: #fff; z-index: 9999; opacity: 0; pointer-events: none; transition: 0.2s; }
/* UPPDATERAD KORT-DESIGN MED BIO */
.gamer-card {
    background: #0a0a0c; border: 1px solid #1a1a1f; padding: 15px;
    display: flex; flex-direction: column; gap: 10px; /* Ändrat till kolumn för att få plats */
    border-radius: 4px; transition: 0.2s; position: relative;
    height: 100%; /* För att alla kort ska bli lika höga */
}
.gamer-card:hover { border-color: var(--neon); transform: translateY(-3px); background: #0f0f12; }

.card-top { display: flex; align-items: center; gap: 12px; width: 100%; }

.card-avatar {
    width: 50px; height: 50px; border-radius: 50%; border: 2px solid var(--neon);
    object-fit: cover; flex-shrink: 0; box-shadow: 0 0 10px var(--neon-dim);
}

.card-bio {
    font-size: 0.8rem; color: #888; font-style: italic; line-height: 1.4;
    border-top: 1px solid #222; margin-top: 5px; padding-top: 10px;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

.card-link {
    font-size: 0.7rem; color: #555; text-decoration: none; 
    text-transform: uppercase; font-weight: bold; margin-top: auto; display: block;
}
.card-link:hover { color: var(--neon); }

/* --- V10.5 COMPACT ELITE FIX --- */
/* Skriver över tidigare kort-regler för att garantera tight look */

.grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); 
    gap: 15px; 
}

.gamer-card {
    background: #0a0a0c;
    border: 1px solid #1a1a1f;
    border-left: 3px solid var(--neon);
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px; /* Litet avstånd mellan delarna */
    border-radius: 4px;
    transition: all 0.2s ease;
    position: relative;
    /* Tar bort tvingad höjd så den blir kompakt */
    height: auto; 
    min-height: 0;
}

.gamer-card:hover {
    transform: translateY(-3px);
    background: #111;
    border-color: var(--neon);
    box-shadow: 0 5px 20px rgba(0,255,170,0.1);
}

/* TOPPEN: Avatar + Namn (Vänster) --- Badge (Höger) */
.card-top {
    display: flex;
    align-items: center; /* Centrera vertikalt */
    justify-content: space-between; /* Trycker ut innehållet till kanterna */
    width: 100%;
}

.card-identity {
    display: flex;
    align-items: center;
    gap: 10px;
}

.card-avatar {
    width: 38px; 
    height: 38px; 
    border-radius: 4px; 
    border: 1px solid var(--neon);
    object-fit: cover;
    background: #000;
}

.card-name {
    margin: 0;
    font-size: 0.9rem;
    font-family: 'Orbitron', sans-serif;
    color: #fff;
    font-weight: 700;
    line-height: 1;
}

/* Badge flyttad till höger (Fyller röda rutan 1) */
.card-badge {
    font-size: 0.55rem;
    color: #000;
    background: var(--neon);
    padding: 2px 6px;
    border-radius: 2px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 0 5px var(--neon-dim);
}

/* BION: Tightare och snyggare */
.card-bio {
    font-size: 0.75rem;
    color: #888;
    font-style: italic;
    line-height: 1.3;
    padding-top: 6px;
    border-top: 1px solid rgba(255,255,255,0.05);
    
    /* Max 2 rader text */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* LÄNKEN: Ligger direkt under bion (Tar bort röda rutan 2) */
.card-link {
    font-size: 0.65rem;
    color: #555;
    text-decoration: none;
    text-transform: uppercase;
    font-weight: bold;
    display: flex;
    align-items: center;
    gap: 4px;
    transition: color 0.2s;
    margin-top: 4px;
}
.card-link:hover { color: var(--neon); }
.card-link::after { content: '»'; font-size: 1.1em; line-height: 0.8; }

/* --- V12.0 LIVE AWARENESS --- */
.gamer-card.live-mode {
    border-color: #ff0055;
    box-shadow: 0 0 25px rgba(255, 0, 85, 0.15);
    background: linear-gradient(135deg, #0a0a0c 0%, #1a050a 100%);
}

.live-badge {
    background: #ff0055;
    color: #fff;
    font-size: 0.6rem;
    padding: 3px 8px;
    border-radius: 2px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 1px;
    animation: pulse-red 2s infinite;
    box-shadow: 0 0 10px #ff0055;
}

@keyframes pulse-red {
    0% { box-shadow: 0 0 0 0 rgba(255, 0, 85, 0.7); }
    70% { box-shadow: 0 0 0 6px rgba(255, 0, 85, 0); }
    100% { box-shadow: 0 0 0 0 rgba(255, 0, 85, 0); }
}
