/* LOCUS GRID – affischstil i 3D, mörkt tema: svart, vitt och loggans cyan */
:root {
  --bg: #07080A;
  --surface: #111215;            /* fasta ytor: vänlista, chatt, profil */
  --surface-2: rgba(17,18,21,.82);
  --paper: rgba(12,13,16,.5);    /* genomskinliga kort i 3D */
  --ink: #F4F6F8;                /* text och "bläck" */
  --on-ink: #08090A;             /* text på vita/cyan ytor */
  --ink-2: #A3A8B0;
  --ink-3: #6B7079;
  --line: rgba(255,255,255,.1);
  --soft: rgba(255,255,255,.05);
  --cyan: #00E1FF;
  --cyan-ink: #00E1FF;
  --green: #2FD487;
  --amber: #FFB547;
  --red: #FF5A65;
  --cond: "Big Shoulders Display", "Arial Narrow", sans-serif;
  --sans: "Inter", system-ui, sans-serif;
  --ease: cubic-bezier(.2, .8, .2, 1);
  --shadow: 0 0 0 1px rgba(255,255,255,.07), 0 50px 100px -40px rgba(0,0,0,.85);
}
*, *::before, *::after { box-sizing: border-box; }

html { background: var(--bg); }
body { margin: 0; color: var(--ink); font: 16px/1.55 var(--sans); -webkit-font-smoothing: antialiased; }
img { display: block; max-width: 100%; }
a { color: inherit; }
button { font: inherit; color: inherit; }
h1, h2, h3 { margin: 0; font-family: var(--cond); font-weight: 900; text-transform: uppercase; line-height: .86; letter-spacing: .005em; }
p { margin: 0 0 1em; }
.c { color: var(--cyan-ink); }
.spaced { font: 600 13px/1.2 var(--sans); letter-spacing: .32em; text-transform: uppercase; }

/* scen */
#stage { position: fixed; inset: 0; overflow: hidden; background: radial-gradient(90% 60% at 50% 45%, #121418 0%, var(--bg) 70%); }
#gl { position: absolute; inset: 0; width: 100%; height: 100%; }
#css { position: absolute; inset: 0; }
#css > div { pointer-events: none; }
#world { position: absolute; visibility: hidden; }

/* knappar – raka, kraftiga */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; height: 54px; padding: 0 26px; border: 2px solid var(--ink); background: transparent; color: var(--ink); font: 800 17px/1 var(--cond); letter-spacing: .14em; text-transform: uppercase; text-decoration: none; cursor: pointer; transition: background .2s, color .2s, transform .2s var(--ease); white-space: nowrap; }
.btn:hover { background: var(--ink); color: var(--on-ink); transform: translateY(-2px); }
.btn svg { width: 18px; height: 18px; }
.btn-ink { background: var(--ink); color: var(--on-ink); }
.btn-ink:hover { background: transparent; border-color: var(--ink); color: var(--ink); }
.btn-cyan { background: var(--cyan); border-color: var(--cyan); color: var(--ink); }
.btn-cyan:hover { background: var(--ink); border-color: var(--ink); color: var(--on-ink); }
.btn-sm { height: 40px; padding: 0 16px; font-size: 14px; }
.icon-btn { width: 42px; height: 42px; border: 1.5px solid var(--line); background: var(--surface-2); color: var(--ink); display: grid; place-items: center; cursor: pointer; position: relative; backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); transition: border-color .2s; }
.icon-btn:hover { border-color: var(--ink); }
.icon-btn svg { width: 19px; height: 19px; }

/* logotyp: befintlig ikon + ordbild */
.logo { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); }
.logo img { width: 32px; height: 32px; }
.logo span { font: 900 24px/1 var(--cond); letter-spacing: .12em; text-transform: uppercase; white-space: nowrap; }
.logo span b { color: var(--cyan-ink); font-weight: 900; }

/* toppfält */
.top { position: fixed; top: 0; left: 0; right: 0; z-index: 40; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 28px; pointer-events: none; }
.top > * { pointer-events: auto; }
.top-right { display: flex; align-items: center; gap: 8px; }
.pill { display: inline-flex; align-items: center; gap: 10px; height: 42px; padding: 0 16px; background: var(--surface-2); border: 1.5px solid var(--line); font: 700 12px var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-2); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); white-space: nowrap; }
.pill b { color: var(--ink); font-variant-numeric: tabular-nums; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--red); flex: none; }
.dot.open { background: var(--green); animation: ping 2s infinite; }
@keyframes ping { 0% { box-shadow: 0 0 0 0 rgba(22,180,108,.5); } 70%, 100% { box-shadow: 0 0 0 8px rgba(22,180,108,0); } }
.me-chip { display: none; align-items: center; gap: 10px; height: 42px; padding: 0 12px 0 4px; background: var(--surface-2); border: 1.5px solid var(--line); cursor: pointer; }
.me-chip:hover { border-color: var(--ink); }
.me-chip .av { width: 32px; height: 32px; font-size: 15px; }
.me-chip b { font: 800 16px var(--cond); letter-spacing: .08em; text-transform: uppercase; }
body.logged-in .me-chip { display: inline-flex; }
body.logged-in .guest-only { display: none !important; }
body:not(.logged-in) .member-only { display: none !important; }
.badge-n { position: absolute; top: -6px; right: -6px; min-width: 19px; height: 19px; padding: 0 5px; background: var(--cyan); color: var(--ink); font: 800 11px/19px var(--sans); text-align: center; }
.top { background: linear-gradient(rgba(7,8,10,.92), rgba(7,8,10,0)); }
/* huvudmeny */
.top-nav { display: flex; gap: 2px; margin-right: auto; margin-left: 26px; }
.top-nav a { position: relative; padding: 10px 12px; font: 800 15px var(--cond); letter-spacing: .14em; text-transform: uppercase; text-decoration: none; color: var(--ink-2); transition: color .2s; white-space: nowrap; }
.top-nav a:hover { color: var(--ink); }
.top-nav a[aria-current] { color: var(--cyan); }
.top-nav a[aria-current]::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: 2px; height: 2px; background: var(--cyan); }
/* nivåfärger från Locus Grid (Level 1–10) */
.lv1 { --lv: #6b7686; } .lv2 { --lv: #8d99ab; } .lv3 { --lv: #b7c2d3; } .lv4 { --lv: #ffd24d; } .lv5 { --lv: #ffa93a; }
.lv6 { --lv: #ff8a2e; } .lv7 { --lv: #e05ab5; } .lv8 { --lv: #7d55d4; } .lv9 { --lv: #d92b1c; } .lv10 { --lv: #00e1ff; }
.lvl[class*="lv"] { background: var(--lv); color: #08090A; }

/* stopp-räls till höger */
.rail { position: fixed; left: 26px; top: 50%; translate: 0 -50%; z-index: 30; display: flex; flex-direction: column; gap: 4px; list-style: none; margin: 0; padding: 0; transition: opacity .4s, transform .4s var(--ease); }
.rail a { display: flex; flex-direction: row-reverse; align-items: center; justify-content: flex-end; gap: 12px; text-decoration: none; padding: 5px 0; font: 800 14px var(--cond); letter-spacing: .16em; text-transform: uppercase; color: var(--ink-3); transition: color .2s; }
.rail a span { padding: 5px 10px; background: var(--surface-2); transition: background .2s, color .2s; }
.rail a::after { content: ""; width: 16px; height: 2px; background: currentColor; transition: width .4s var(--ease); }
.rail a:hover { color: var(--ink); }
.rail a.on { color: var(--ink); }
.rail a.on span { background: var(--ink); color: var(--on-ink); }
.rail a.on::after { width: 40px; background: var(--cyan); }
.depth-meter { position: fixed; left: 28px; bottom: 26px; z-index: 30; display: flex; align-items: center; gap: 14px; }
.depth-meter .bar { width: 150px; height: 3px; background: var(--line); }
.depth-meter .bar i { display: block; height: 100%; width: calc(var(--depth, 0) * 100%); background: var(--ink); }
.depth-meter .spaced { font-size: 11px; color: var(--ink-3); }
.hint { position: fixed; left: 50%; bottom: 26px; translate: -50% 0; z-index: 30; display: flex; flex-direction: column; align-items: center; gap: 10px; transition: opacity .6s, transform .6s var(--ease); }
.hint .mouse { width: 24px; height: 38px; border: 2px solid var(--ink); border-radius: 14px; position: relative; }
.hint .mouse::after { content: ""; position: absolute; left: 50%; top: 7px; width: 3px; height: 7px; border-radius: 2px; background: var(--cyan-ink); translate: -50% 0; animation: wheel 1.8s infinite; }
.hint .spaced { font-size: 11px; color: var(--ink-2); white-space: nowrap; }
@keyframes wheel { 60% { transform: translateY(9px); opacity: 0; } 100% { opacity: 0; } }
body.started .hint { opacity: 0; transform: translateY(10px); pointer-events: none; }

/* ---------- affischpaneler i 3D ---------- */
.panel { position: relative; width: 1180px; background: var(--paper); color: var(--ink); padding: 70px 76px; overflow: hidden; border: 1px solid var(--line); box-shadow: 0 50px 100px -50px rgba(0,0,0,.7); }
/* snedstreck i hörnen – eget motiv i loggans cyan */
.panel::before { content: ""; position: absolute; left: 0; top: 0; width: 150px; height: 150px; background: linear-gradient(135deg, var(--cyan) 0 34%, transparent 34% 42%, var(--cyan) 42% 46%, transparent 46%); pointer-events: none; }
.panel::after { content: ""; position: absolute; right: 0; bottom: 0; width: 170px; height: 86px; background: linear-gradient(-28deg, var(--ink) 0 52%, transparent 52%); opacity: .9; pointer-events: none; }
.panel > * { position: relative; z-index: 1; }
/* blek sexkant som bakgrundsmotiv */
.ghost { position: absolute !important; z-index: 0 !important; right: -90px; top: 50%; translate: 0 -50%; width: 560px; opacity: .06; filter: grayscale(1) brightness(1.8); pointer-events: none; }
.rule { display: flex; align-items: center; justify-content: center; gap: 18px; margin-bottom: 40px; color: var(--ink); }
.rule::before, .rule::after { content: ""; width: 70px; height: 2px; background: var(--ink); }
.rule.left { justify-content: flex-start; }
.rule.left::before { display: none; }
.tag { display: inline-block; font: 900 22px/1 var(--cond); letter-spacing: .06em; text-transform: uppercase; padding-top: 12px; border-top: 3px solid var(--cyan); margin-bottom: 10px; }
.panel h2 { font-size: 150px; }
.sub { display: block; font: 800 24px/1 var(--cond); letter-spacing: .28em; text-transform: uppercase; color: var(--cyan-ink); margin: 14px 0 0; }
.lead { font-size: 23px; line-height: 1.55; color: var(--ink-2); max-width: 54ch; margin-top: 30px; }
.lead b { color: var(--ink); }
.bottom-row { display: flex; align-items: center; gap: 22px; margin-top: 46px; font: 600 13px var(--sans); letter-spacing: .3em; text-transform: uppercase; }
.bottom-row i { width: 2px; height: 16px; background: var(--cyan); }
.corner-note { position: absolute !important; right: 26px; bottom: 18px; z-index: 2 !important; color: var(--on-ink); font: 600 10px/1.5 var(--sans); letter-spacing: .3em; text-transform: uppercase; text-align: right; }
.corner-note::after { content: ""; display: block; width: 34px; height: 2px; background: var(--cyan); margin: 6px 0 0 auto; }
.arrow-link { display: inline-flex; gap: 10px; align-items: center; font: 800 18px var(--cond); letter-spacing: .14em; text-transform: uppercase; text-decoration: none; border-bottom: 3px solid var(--cyan); padding-bottom: 4px; }
.arrow-link:hover { color: var(--cyan-ink); }

/* start */
.hero { width: 1240px; text-align: center; padding: 76px 80px 70px; }
.hero .ghost { right: auto; left: 50%; translate: -50% -50%; width: 760px; opacity: .05; }
.hero .rule { margin-bottom: 30px; }
.hero h1 { font-size: 220px; letter-spacing: 0; margin-top: 8px; }
.hero .sub { font-size: 46px; letter-spacing: .32em; margin-top: 10px; }
.lockup { display: flex; align-items: center; justify-content: center; gap: 28px; margin: 44px 0 10px; }
.lockup img { width: 96px; height: 96px; }
.lockup i { width: 2px; height: 70px; background: var(--ink); }
.lockup span { font: 900 54px/.9 var(--cond); letter-spacing: .1em; text-transform: uppercase; text-align: left; }
.lockup span small { display: block; font: 600 13px var(--sans); letter-spacing: .32em; color: var(--ink-2); margin-top: 8px; }
.hero .lead { margin: 26px auto 34px; text-align: center; }
.row { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.hero .links { margin-top: 18px; font-size: 14px; color: var(--ink-3); display: flex; gap: 10px; justify-content: center; }
.hero .links a { color: var(--ink-2); text-decoration: none; }
.hero .links a:hover { color: var(--ink); text-decoration: underline; }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); margin-top: 50px; border-top: 2px solid var(--ink); }
.stats > div { padding: 22px 10px 0; display: flex; flex-direction: column; align-items: center; gap: 10px; }
.stats > div + div { border-left: 1px solid var(--line); }
.stats b { font: 900 42px/1 var(--cond); }
.stats .k { font: 600 12px var(--sans); letter-spacing: .28em; text-transform: uppercase; color: var(--ink-3); }
.flags, .soc { display: flex; gap: 10px; height: 54px; align-items: center; }
.flags img { height: 22px; width: auto; }
.soc a { width: 42px; height: 42px; display: grid; place-items: center; border: 1.5px solid var(--line); color: var(--ink); transition: background .2s, color .2s, border-color .2s; }
.soc a:hover { background: var(--ink); color: var(--on-ink); border-color: var(--ink); }
.soc svg { width: 19px; height: 19px; }

/* startpanel med samma info som nuvarande startsida */
.dash { width: 1580px; display: grid; grid-template-columns: 1.3fr 1fr; gap: 26px 44px; padding: 70px 72px 56px; }
.dash .ghost { right: auto; left: 30%; width: 700px; opacity: .045; }
.dash-hero h1 { font-size: 112px; }
.dash-hero .sub { font-size: 28px; letter-spacing: .3em; }
.dash-hero .lead { margin: 26px 0 28px; }
.dash-hero .links { justify-content: flex-start; margin-top: 16px; display: flex; gap: 10px; font-size: 14px; color: var(--ink-3); }
.dash-hero .links a { color: var(--ink-2); text-decoration: none; }
.dash-mm { display: grid; gap: 18px; margin-top: 36px; padding-top: 22px; border-top: 2px solid var(--ink); }
.dash-mm .mm-open { margin-top: 12px; line-height: 1.8; }
.dash-mm .mm-open b[data-countdown] { color: var(--ink); font: 900 26px var(--cond); letter-spacing: .04em; font-variant-numeric: tabular-nums; }
.dash-srv { display: grid; gap: 10px; }
.dash-srv .chips { display: flex; flex-wrap: wrap; gap: 8px; }
.dash-srv .chips span { display: inline-flex; align-items: center; gap: 8px; padding: 8px 13px; border: 1px solid var(--line); font: 800 17px/1 var(--cond); letter-spacing: .08em; text-transform: uppercase; color: var(--ink-2); }
.dash-srv img { height: 11px; width: auto; }
.dash-side { display: grid; gap: 18px; align-content: start; }
.dash-card { border: 1px solid var(--line); background: rgba(255,255,255,.03); padding: 34px 36px; position: relative; }
.dash-card::before { content: ""; position: absolute; left: -1px; top: -1px; width: 44px; height: 44px; background: linear-gradient(135deg, var(--cyan) 0 30%, transparent 30%); }
.dash-card h3 { font-size: 40px; margin-bottom: 14px; }
.dash-card p { color: var(--ink-2); font-size: 18px; line-height: 1.6; margin-bottom: 20px; }
.dash-card p b { color: var(--ink); }
.dash-stats { grid-column: 1 / -1; margin-top: 10px; }
body.narrow .dash { width: 660px; grid-template-columns: 1fr; padding: 50px 40px; }
body.narrow .dash-hero h1 { font-size: 110px; }
body.narrow .dash-mm { grid-template-columns: 1fr; }
body.narrow .dash-card h3 { font-size: 44px; }

/* matchmaking */
.mm-grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: 56px; align-items: end; }
.mm-state { display: inline-flex; align-items: center; gap: 10px; font: 900 22px var(--cond); letter-spacing: .14em; text-transform: uppercase; color: var(--red); }
.mm-state.open { color: var(--green); }
.mm-state .dot { background: currentColor; }
.countdown { font: 900 190px/.85 var(--cond); font-variant-numeric: tabular-nums; margin: 18px 0 8px; }
.mm-open { font: 700 17px var(--sans); letter-spacing: .22em; text-transform: uppercase; color: var(--ink-2); }
.mm-open b { color: var(--ink); }
.week { display: grid; grid-template-columns: repeat(7, 1fr); margin-top: 34px; border: 2px solid var(--ink); }
.week span { text-align: center; padding: 12px 0; font: 900 18px var(--cond); letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); }
.week span + span { border-left: 1px solid var(--line); }
.week span.on { background: var(--ink); color: var(--on-ink); }
.week span.on + span.on { border-left-color: rgba(0,0,0,.25); }
.week span.today { box-shadow: inset 0 -4px 0 var(--cyan); color: var(--ink); }
.week span.on.today { color: var(--on-ink); box-shadow: inset 0 -4px 0 var(--cyan); }
.servers .tag { margin-bottom: 18px; }
.srv { display: flex; align-items: center; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--line); font: 900 26px var(--cond); letter-spacing: .06em; text-transform: uppercase; }
.srv img { height: 22px; }
.srv:first-of-type { border-top: 2px solid var(--ink); }

/* trust factor */
.tf { margin-top: 44px; }
.tf-bar { position: relative; height: 18px; background: var(--soft); border: 2px solid var(--ink); }
.tf-bar i { position: absolute; inset: 0 auto 0 0; width: 78%; background: repeating-linear-gradient(-45deg, var(--cyan) 0 10px, #33E8FF 10px 20px); }
.tf-mark { position: absolute; top: -14px; bottom: -14px; width: 3px; background: var(--ink); }
.tf-mark span { position: absolute; top: calc(100% + 8px); left: 50%; translate: -50% 0; font: 900 22px var(--cond); letter-spacing: .1em; text-transform: uppercase; white-space: nowrap; }
.tf-mark.t { left: 70%; } .tf-mark.e { left: 85%; } .tf-mark.e span { color: var(--cyan-ink); }
.my-tf { display: flex; align-items: baseline; gap: 14px; margin-bottom: 18px; }
.my-tf b { font: 900 76px/1 var(--cond); }

/* stöd + live + partners */
.split { display: grid; grid-template-columns: 1.2fr .8fr; gap: 56px; align-items: center; }
.boxed { border: 2px solid var(--ink); padding: 40px; text-align: center; }
.boxed svg { width: 64px; height: 64px; stroke: var(--ink); }
.boxed b { display: block; font: 900 32px/1 var(--cond); text-transform: uppercase; margin: 18px 0 10px; }
.boxed span { color: var(--ink-2); }
.partner-logo { aspect-ratio: 1; display: grid; place-items: center; background: rgba(0,0,0,.35); border: 1px solid var(--line); }
.partner-logo img { width: 70%; }

/* partnerpanelen behåller Northern Wolves egna färger: svart, vitt och rött */
.panel.nw { --cyan-ink: #E2001A; }   /* bara namnet i rött – ramar och snedstreck förblir Locus-blå */

/* topp 10 */
.lb-head { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 30px; }
.lb { border-top: 2px solid var(--ink); }
.lrow { display: grid; grid-template-columns: 90px 54px 1fr auto; align-items: center; gap: 18px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.lrow .pos { font: 900 28px var(--cond); color: var(--ink-3); }
.lrow:nth-child(-n+3) .pos { color: var(--ink); }
.lrow:first-child .pos { color: var(--cyan-ink); }
.lrow .nm { font: 600 22px var(--sans); letter-spacing: -.01em; }
.lrow .el { font: 900 26px var(--cond); font-variant-numeric: tabular-nums; }
.lvl { display: inline-grid; place-items: center; width: 38px; height: 38px; background: var(--cyan); color: var(--on-ink); font: 900 20px var(--cond); clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%); }

/* plattformen */
.feat-grid { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 2px solid var(--ink); margin-top: 40px; }
.feat { padding: 26px 22px 24px; border-bottom: 1px solid var(--line); }
.feat:not(:nth-child(4n+1)) { border-left: 1px solid var(--line); }
.feat .n { font: 900 16px var(--cond); letter-spacing: .14em; color: var(--cyan-ink); }
.feat h3 { font-size: 26px; margin: 8px 0 12px; }
.feat ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.feat li { color: var(--ink-2); font-size: 16.5px; line-height: 1.45; padding-left: 14px; position: relative; }
.feat li::before { content: ""; position: absolute; left: 0; top: .55em; width: 7px; height: 2px; background: var(--cyan); }

/* sidfot-panel */
.foot { text-align: center; }
.foot .lockup { margin: 10px 0 34px; }
.foot .row a { min-width: 180px; }
.foot .legal { color: var(--ink-3); font-size: 15px; max-width: 70ch; margin: 36px auto 0; }

/* ---------- socialt: vänner, chatt, profil ---------- */
.av { position: relative; flex: none; width: 40px; height: 40px; display: grid; place-items: center; background: var(--ink); color: var(--on-ink); font: 900 18px var(--cond); }
.av.me-av { background: var(--cyan); color: var(--ink); }
.av .st { position: absolute; right: -3px; bottom: -3px; width: 13px; height: 13px; border-radius: 50%; border: 2.5px solid var(--surface); background: var(--ink-3); }
.st.online { background: var(--green); } .st.match, .st.lobby { background: var(--cyan); } .st.away { background: var(--amber); } .st.offline { background: #4A4E56; }

.friends { position: fixed; top: 78px; right: 16px; bottom: 16px; width: 340px; z-index: 45; display: flex; flex-direction: column; background: var(--surface); box-shadow: var(--shadow); transform: translateX(calc(100% + 30px)); transition: transform .5s var(--ease); }
.friends::before { content: ""; position: absolute; left: 0; top: 0; width: 70px; height: 70px; background: linear-gradient(135deg, var(--cyan) 0 30%, transparent 30%); pointer-events: none; }
body.friends-open .friends { transform: none; }
.friends header { position: relative; display: flex; justify-content: space-between; align-items: center; padding: 26px 20px 12px 24px; }
.friends header h3 { font-size: 36px; }
.f-search { margin: 0 16px 8px; display: flex; align-items: center; gap: 8px; padding: 0 12px; height: 42px; border: 1.5px solid var(--line); }
.f-search:focus-within { border-color: var(--ink); }
.f-search input { flex: 1; background: none; border: 0; outline: 0; color: var(--ink); font: 15px var(--sans); }
.f-search svg { width: 16px; color: var(--ink-3); }
.f-list { flex: 1; overflow-y: auto; padding: 0 8px 14px; }
.f-group { font: 700 11px var(--sans); letter-spacing: .26em; text-transform: uppercase; color: var(--ink-3); padding: 14px 12px 6px; }
.f-row { display: flex; align-items: center; gap: 12px; padding: 9px 12px; cursor: pointer; transition: background .2s; }
.f-row:hover { background: var(--soft); }
.f-row .info { flex: 1; min-width: 0; }
.f-row .info b { display: block; font-size: 15px; font-weight: 600; }
.f-row .info span { display: block; font-size: 13px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.f-row .info span.match, .f-row .info span.lobby { color: var(--cyan-ink); font-weight: 600; }
.f-row.offline .info b { color: var(--ink-3); }
.f-row.offline .av { background: #2E3137; color: var(--ink-3); }
.f-acts { display: flex; gap: 4px; opacity: 0; transition: opacity .2s; }
.f-row:hover .f-acts { opacity: 1; }
.f-acts button { width: 32px; height: 32px; border: 1.5px solid var(--line); background: var(--surface); display: grid; place-items: center; cursor: pointer; }
.f-acts button:hover { background: var(--ink); color: var(--on-ink); border-color: var(--ink); }
.f-acts svg { width: 15px; height: 15px; }

.chats { position: fixed; right: 372px; bottom: 16px; z-index: 46; display: flex; gap: 12px; align-items: flex-end; pointer-events: none; }
body:not(.friends-open) .chats { right: 16px; }
.chat { width: 320px; height: 430px; display: flex; flex-direction: column; background: var(--surface); box-shadow: var(--shadow); pointer-events: auto; animation: pop .35s var(--ease); }
.chat.min { height: 60px; overflow: hidden; }
@keyframes pop { from { transform: translateY(20px); opacity: 0; } }
.chat header { display: flex; align-items: center; gap: 10px; padding: 10px 10px 10px 12px; border-bottom: 2px solid var(--ink); cursor: pointer; }
.chat header .av { width: 36px; height: 36px; font-size: 16px; }
.chat header .info { flex: 1; min-width: 0; }
.chat header b { display: block; font: 900 20px/1 var(--cond); letter-spacing: .06em; text-transform: uppercase; }
.chat header span { font-size: 12px; color: var(--ink-2); }
.chat header button { width: 30px; height: 30px; border: 0; background: none; cursor: pointer; color: var(--ink-2); }
.chat header button:hover { background: var(--soft); color: var(--ink); }
.msgs { flex: 1; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 6px; background: var(--soft); }
.msg { max-width: 80%; padding: 9px 13px; font-size: 14.5px; line-height: 1.4; background: var(--surface); align-self: flex-start; box-shadow: 0 0 0 1px var(--line); }
.msg.me { align-self: flex-end; background: var(--ink); color: var(--on-ink); box-shadow: none; }
.msg-time { align-self: center; font: 700 10px var(--sans); letter-spacing: .26em; text-transform: uppercase; color: var(--ink-3); margin: 6px 0; }
.typing { align-self: flex-start; font-size: 13px; color: var(--ink-2); padding: 4px 6px; }
.chat form { display: flex; gap: 8px; padding: 10px; border-top: 1px solid var(--line); }
.chat input { flex: 1; min-width: 0; height: 40px; padding: 0 12px; border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); font: 14.5px var(--sans); outline: 0; }
.chat input:focus { border-color: var(--ink); }
.chat form button { width: 40px; height: 40px; border: 2px solid var(--ink); background: transparent; color: var(--ink); cursor: pointer; display: grid; place-items: center; transition: background .2s, color .2s; }
.chat form button:hover { background: var(--ink); color: var(--on-ink); }

.overlay { position: fixed; inset: 0; z-index: 60; display: grid; place-items: center; padding: 20px; background: rgba(10,10,11,.35); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); opacity: 0; pointer-events: none; transition: opacity .35s; }
body.overlay-open .overlay { opacity: 1; pointer-events: auto; }
.sheet { position: relative; width: min(860px, 100%); max-height: calc(100vh - 40px); overflow-y: auto; background: var(--surface); box-shadow: var(--shadow); transform: translateY(24px); transition: transform .45s var(--ease); }
body.overlay-open .sheet { transform: none; }
.sheet .x { position: absolute; top: 16px; right: 16px; z-index: 3; }
.pf-banner { position: relative; height: 160px; background: #000; overflow: hidden; }
.pf-banner::before { content: ""; position: absolute; left: 0; top: 0; width: 260px; height: 160px; background: linear-gradient(120deg, var(--cyan) 0 30%, transparent 30% 36%, var(--cyan) 36% 39%, transparent 39%); }
.pf-banner img { position: absolute; right: -40px; top: -60px; width: 300px; opacity: .14; }
.pf-head { display: flex; align-items: flex-end; gap: 22px; padding: 0 36px; margin-top: -44px; position: relative; }
.pf-head .av { width: 104px; height: 104px; font-size: 52px; box-shadow: 0 0 0 6px var(--surface); }
.pf-head .av .st { width: 22px; height: 22px; border-width: 4px; right: -6px; bottom: -6px; }
.pf-head .who { flex: 1; padding: 54px 0 2px; }  /* namnet under bannern */
.pf-head h2 { font-size: 54px; }
.pf-head .who span { color: var(--ink-2); font-size: 14px; letter-spacing: .2em; text-transform: uppercase; font-weight: 600; }
.pf-head .acts { display: flex; gap: 8px; padding-bottom: 8px; }
.pf-body { padding: 30px 36px 36px; }
.pf-stats { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 2px solid var(--ink); }
.pf-stats div { padding: 16px 16px 14px 0; }
.pf-stats div + div { padding-left: 16px; border-left: 1px solid var(--line); }
.pf-stats .k, .pf-trust .k, .pf-sec { font: 700 11px var(--sans); letter-spacing: .26em; text-transform: uppercase; color: var(--ink-3); }
.pf-stats b { display: block; font: 900 36px/1 var(--cond); margin-top: 8px; white-space: nowrap; }
.pf-trust { margin: 20px 0 28px; }
.pf-trust .bar { height: 12px; background: var(--soft); border: 2px solid var(--ink); margin-top: 10px; position: relative; }
.pf-trust .bar i { position: absolute; inset: 0 auto 0 0; background: repeating-linear-gradient(-45deg, var(--cyan) 0 8px, #33E8FF 8px 16px); }
.pf-trust .row { display: flex; justify-content: space-between; align-items: baseline; }
.pf-trust .tier { font: 900 20px var(--cond); letter-spacing: .1em; text-transform: uppercase; }
.pf-trust .tier.elite { color: var(--cyan-ink); }
.matches { display: grid; margin-top: 10px; border-top: 2px solid var(--ink); }
.mrow { display: grid; grid-template-columns: 1fr auto auto auto auto; gap: 18px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); }
.mrow b { font: 900 22px var(--cond); letter-spacing: .06em; text-transform: uppercase; }
.mrow span { color: var(--ink-2); font-size: 14px; }
.mrow .res { font: 900 16px var(--cond); letter-spacing: .14em; color: var(--red); }
.mrow.w .res { color: var(--green); }
.mrow .sc { font: 900 22px var(--cond); color: var(--ink); }
.mrow .d { font: 900 20px var(--cond); color: var(--red); min-width: 40px; text-align: right; }
.mrow.w .d { color: var(--green); }
.demo-note { margin-top: 20px; font: 700 10px var(--sans); letter-spacing: .26em; text-transform: uppercase; color: var(--ink-3); text-align: center; }
.login-sheet { width: min(460px, 100%); padding: 56px 40px 36px; text-align: center; }
.login-sheet::before { content: ""; position: absolute; left: 0; top: 0; width: 110px; height: 110px; background: linear-gradient(135deg, var(--cyan) 0 30%, transparent 30%); }
.login-sheet img { width: 74px; margin: 0 auto 18px; }
.login-sheet h2 { font-size: 64px; margin-bottom: 12px; }
.login-sheet p { color: var(--ink-2); }

.toast { position: fixed; left: 50%; top: 82px; translate: -50% 0; z-index: 80; padding: 12px 20px; background: var(--ink); color: var(--on-ink); font: 800 15px var(--cond); letter-spacing: .14em; text-transform: uppercase; transform: translateY(-20px); opacity: 0; transition: .4s var(--ease); pointer-events: none; border-left: 4px solid var(--cyan); }
.toast.show { transform: none; opacity: 1; }

/* mobil: smalare paneler i 3D */
body.narrow .panel { width: 640px; padding: 50px 40px; }
body.narrow .hero { width: 660px; }
body.narrow .panel h2 { font-size: 96px; }
body.narrow .hero h1 { font-size: 132px; }
body.narrow .hero .sub { font-size: 30px; }
body.narrow .lockup span { font-size: 40px; }
body.narrow .stats { grid-template-columns: 1fr 1fr; }
body.narrow .stats > div:nth-child(3) { border-left: 0; }
body.narrow .stats > div:nth-child(n+3) { border-top: 1px solid var(--line); margin-top: 16px; }
body.narrow .mm-grid, body.narrow .split { grid-template-columns: 1fr; gap: 34px; }
body.narrow .countdown { font-size: 130px; }
body.narrow .feat-grid { grid-template-columns: 1fr 1fr; }
body.narrow .feat:nth-child(odd) { border-left: 0; }
body.narrow .feat:nth-child(even) { border-left: 1px solid var(--line); }
body.narrow .lrow { grid-template-columns: 60px 44px 1fr auto; }
body.narrow .partner-logo { max-width: 280px; margin: 0 auto; }
body.narrow .bottom-row { flex-wrap: wrap; gap: 12px; letter-spacing: .2em; }
@media (max-width: 1240px) {
  .top { flex-wrap: wrap; }
  .top-nav { order: 3; width: 100%; margin: 6px 0 0; overflow-x: auto; scrollbar-width: none; }
  .top-nav::-webkit-scrollbar { display: none; }
  .pill { display: none; }
}
@media (max-width: 760px) {
  .pill, .top .btn:not(.btn-ink), .me-chip b { display: none; }
  .top { padding: 12px; }
  .rail { top: auto; bottom: 12px; left: 12px; right: 12px; translate: none; flex-direction: row; gap: 4px; overflow-x: auto; scrollbar-width: none; padding: 6px; background: var(--surface-2); box-shadow: var(--shadow); }
  .rail::-webkit-scrollbar { display: none; }
  .rail a { padding: 0; }
  .rail a::after { display: none; }
  .rail a span { display: block; white-space: nowrap; padding: 9px 12px; background: transparent; }
  .depth-meter, .hint { display: none; }
  .friends { top: 66px; left: 10px; right: 10px; width: auto; bottom: 10px; }
  .chats { left: 10px; right: 10px !important; bottom: 10px; }
  .chat { width: 100%; height: 62vh; }
  .chat:not(:last-child) { display: none; }
  .pf-head { flex-wrap: wrap; padding: 0 20px; }
  .pf-head h2 { font-size: 48px; }
  .pf-head .acts { width: 100%; }
  .pf-body { padding: 20px; }
  .pf-stats { grid-template-columns: 1fr 1fr; }
  .mrow { grid-template-columns: 1fr auto auto; }
  .mrow .when, .mrow .kd { display: none; }
}

/* vänlista: rubrik, nivåbricka och flik för att visa listan igen */
.friends header h3 .f-on { font-size: .55em; letter-spacing: .14em; color: var(--green); vertical-align: middle; margin-left: 6px; }
.f-lvl { flex: none; width: 30px; height: 30px; display: grid; place-items: center; border: 1px solid var(--line); font: 900 15px var(--cond); color: var(--ink-3); }
.f-lvl[class*="lv"] { color: var(--lv); border-color: color-mix(in srgb, var(--lv) 55%, transparent); background: color-mix(in srgb, var(--lv) 10%, transparent); }
.f-row:hover .f-lvl { display: none; }
.f-row.offline { opacity: .72; }
.friends-tab { position: fixed; right: 0; top: 50%; translate: 0 -50%; z-index: 44; writing-mode: vertical-rl; padding: 26px 16px; border: 1.5px solid var(--ink-3); border-right: 0; background: var(--surface); color: var(--ink); font: 900 18px var(--cond); letter-spacing: .22em; text-transform: uppercase; cursor: pointer; box-shadow: -10px 0 30px -10px rgba(0,0,0,.6); transition: color .2s, opacity .3s, background .2s, padding .2s; }
.friends-tab:hover { background: var(--ink); color: var(--on-ink); padding-right: 20px; }
.friends-tab:hover { color: var(--ink); }
.friends-tab span { color: var(--green); }
body.friends-open .friends-tab { opacity: 0; pointer-events: none; }
@media (max-width: 760px) { .friends-tab { display: none !important; } }

/* profil och vänner-knapp överst i vänlistan, mindre rubrik */
.f-me { display: flex; align-items: center; justify-content: flex-end; gap: 4px; padding: 16px 16px 4px; }
.f-me .hb { border-color: transparent; background: transparent; color: var(--ink-2); }
.f-me .hb:hover { color: var(--ink); border-color: var(--line); }
.f-me .hb.on { color: var(--ink); border-color: var(--ink-3); }
.f-me .badge-n { top: -5px; right: -5px; }
.f-me .me-chip { padding: 0; border: 0; background: none; height: auto; margin-left: 6px; }
.f-me .me-chip b { display: none; }
.f-me .me-chip .av { width: 38px; height: 38px; font-size: 18px; }
/* popup för notiser och meddelanden */
.f-pop { margin: 6px 12px 4px; border: 1px solid var(--line); background: #15161A; max-height: 46vh; overflow-y: auto; padding-bottom: 6px; }
.f-pop[hidden] { display: none; }
.n-row { display: flex; gap: 12px; align-items: flex-start; padding: 10px 14px; width: 100%; text-align: left; background: none; border: 0; color: inherit; font: inherit; }
.n-row + .n-row { border-top: 1px solid var(--line); }
.n-row .info { flex: 1; min-width: 0; }
.n-row .info span { display: block; font-size: 14px; color: var(--ink-2); line-height: 1.4; }
.n-row .info b { color: var(--ink); font-weight: 600; }
.n-row small { font-size: 11.5px; color: var(--ink-3); white-space: nowrap; }
.n-row .info small { display: block; margin-top: 2px; }
.n-ic { flex: none; width: 40px; height: 40px; display: grid; place-items: center; border: 1px solid var(--line); color: var(--ink-2); }
.n-acts { display: flex; gap: 6px; margin-top: 8px; }
.n-acts button { height: 30px; padding: 0 12px; border: 1.5px solid var(--ink); background: transparent; color: var(--ink); font: 800 12px var(--cond); letter-spacing: .14em; text-transform: uppercase; cursor: pointer; }
.n-acts button:hover, .n-acts button:first-child { background: var(--ink); color: var(--on-ink); }
.n-acts button:first-child:hover { background: transparent; color: var(--ink); }
.n-thread { cursor: pointer; align-items: center; }
.n-thread:hover { background: rgba(255,255,255,.04); }
.n-thread .info b { display: block; }
.n-thread.unread .info span { color: var(--ink); font-weight: 600; }
.n-thread.unread small { color: var(--ink); }
.n-empty { padding: 14px; color: var(--ink-3); font-size: 14px; }
.friends header { padding-top: 12px !important; }
.friends header h3 { font-size: 22px !important; letter-spacing: .04em; }
.friends header h3 .f-on { font-size: .62em; letter-spacing: .12em; }
