
    :root {
      --bg: #030308;
      --cyan: #00f0ff;
      --purple: #bf00ff;
      --magenta: #ff00aa;
      --glass: rgba(8, 14, 32, 0.62);
      --border: rgba(0, 240, 255, 0.28);
    }

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

    body {
      font-family: 'Rajdhani', sans-serif;
      background: var(--bg);
      color: #e0f7ff;
      overflow: hidden;
      height: 100vh;
    }

    canvas#particles { position: fixed; inset: 0; z-index: 0; }

    .grid-overlay {
      position: fixed; inset: 0; z-index: 1; pointer-events: none;
      background-image:
        linear-gradient(rgba(0,240,255,0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0,240,255,0.03) 1px, transparent 1px);
      background-size: 60px 60px;
      animation: gridMove 40s linear infinite;
    }
    @keyframes gridMove {
      from { background-position: 0 0; }
      to { background-position: 60px 60px; }
    }

    .geo { position: fixed; border: 1px solid rgba(0,240,255,0.15); z-index: 1; pointer-events: none; }
    .geo-1 { width: 180px; height: 180px; top: 12%; left: 8%; animation: float 18s ease-in-out infinite; }
    .geo-2 { width: 90px; height: 90px; bottom: 18%; right: 12%; border-radius: 50%; border-color: rgba(191,0,255,0.25); animation: float 14s ease-in-out infinite reverse; }
    .geo-3 { width: 140px; height: 140px; top: 55%; left: 4%; clip-path: polygon(50% 0%, 100% 50%, 50% 100%, 0% 50%); animation: float 22s ease-in-out infinite; }
    @keyframes float {
      0%,100% { transform: translateY(0) rotate(25deg); }
      50% { transform: translateY(-30px) rotate(35deg); }
    }

    .view { position: relative; z-index: 10; height: 100vh; }

    /* AUTH */
    #auth { display: flex; align-items: center; justify-content: center; }

    .auth-card {
      width: 440px; padding: 48px 40px;
      background: var(--glass);
      backdrop-filter: blur(28px) saturate(180%);
      border: 1px solid var(--border);
      position: relative; overflow: hidden;
      box-shadow: 0 0 80px rgba(0,240,255,0.08), 0 25px 50px rgba(0,0,0,0.5), inset 0 0 40px rgba(0,240,255,0.03);
      transform-style: preserve-3d;
      transition: transform 0.15s ease-out;
    }
    .auth-card::before {
      content: ''; position: absolute; top: 0; left: -100%;
      width: 60%; height: 100%;
      background: linear-gradient(90deg, transparent, rgba(0,240,255,0.06), transparent);
      animation: scan 4.5s infinite;
    }
    @keyframes scan { to { left: 200%; } }

    .logo {
      font-family: 'Orbitron', sans-serif;
      font-size: 42px; font-weight: 900; letter-spacing: 8px; text-align: center;
      background: linear-gradient(90deg, var(--cyan), var(--purple), var(--cyan));
      background-size: 200%;
      -webkit-background-clip: text; background-clip: text; color: transparent;
      animation: shine 6s linear infinite;
    }
    @keyframes shine { to { background-position: 200%; } }

    .tagline {
      text-align: center; font-size: 13px; letter-spacing: 4px;
      color: rgba(0,240,255,0.6); margin: 6px 0 36px; text-transform: uppercase;
    }

    .tabs { display: flex; margin-bottom: 32px; border-bottom: 1px solid rgba(0,240,255,0.15); }
    .tab {
      flex: 1; padding: 12px; text-align: center;
      font-family: 'Orbitron'; font-size: 13px; letter-spacing: 2px;
      color: rgba(255,255,255,0.4); cursor: pointer; position: relative; transition: 0.3s;
    }
    .tab.active { color: var(--cyan); }
    .tab.active::after {
      content: ''; position: absolute; bottom: -1px; left: 20%; right: 20%;
      height: 2px; background: var(--cyan); box-shadow: 0 0 12px var(--cyan);
    }

    .field { margin-bottom: 20px; position: relative; }
    .field label {
      display: block; font-size: 11px; letter-spacing: 2px;
      color: rgba(0,240,255,0.5); margin-bottom: 6px; text-transform: uppercase;
    }
    .field input {
      width: 100%; padding: 14px 16px 14px 18px;
      background: rgba(0,10,30,0.6);
      border: 1px solid rgba(0,240,255,0.2);
      color: #fff; font-family: 'Rajdhani'; font-size: 16px; outline: none; transition: 0.3s;
    }
    .field input:focus {
      border-color: var(--cyan);
      box-shadow: 0 0 20px rgba(0,240,255,0.25), inset 0 0 12px rgba(0,240,255,0.05);
    }

    .confirm-row, .reg-only { display: none; }

    .btn-enter {
      width: 100%; padding: 16px; margin-top: 12px;
      font-family: 'Orbitron'; font-size: 14px; letter-spacing: 4px;
      background: transparent; border: 1px solid var(--cyan); color: var(--cyan);
      cursor: pointer; transition: 0.4s;
    }
    .btn-enter:hover {
      background: rgba(0,240,255,0.12);
      box-shadow: 0 0 30px rgba(0,240,255,0.4), inset 0 0 20px rgba(0,240,255,0.1);
      letter-spacing: 6px;
    }

    .socials { display: flex; justify-content: center; gap: 16px; margin-top: 28px; }
    .social {
      width: 42px; height: 42px;
      border: 1px solid rgba(0,240,255,0.2);
      display: flex; align-items: center; justify-content: center;
      color: rgba(0,240,255,0.7); cursor: pointer; transition: 0.3s;
      font-family: 'Orbitron'; font-size: 11px; letter-spacing: 1px;
    }
    .social:hover {
      border-color: var(--cyan); color: var(--cyan);
      box-shadow: 0 0 16px rgba(0,240,255,0.3); transform: translateY(-3px);
    }

    #portal {
      position: fixed; inset: 0; z-index: 100;
      display: none; align-items: center; justify-content: center; background: #000;
    }
    .portal-ring {
      width: 80px; height: 80px; border: 3px solid var(--cyan); border-radius: 50%;
      box-shadow: 0 0 40px var(--cyan), inset 0 0 40px var(--cyan);
      animation: portalExpand 1.4s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
    }
    @keyframes portalExpand {
      0% { transform: scale(0.2); opacity: 1; }
      70% { transform: scale(18); opacity: 1; }
      100% { transform: scale(30); opacity: 0; }
    }

    /* DASHBOARD */
    #dashboard { display: none; flex-direction: column; }

    .hud {
      height: 64px; display: flex; align-items: center; padding: 0 28px;
      background: var(--glass); backdrop-filter: blur(20px);
      border-bottom: 1px solid var(--border); z-index: 20;
    }
    .hud-logo { font-family: 'Orbitron'; font-weight: 700; letter-spacing: 4px; font-size: 18px; color: var(--cyan); }
    .hud-search {
      margin-left: 48px; width: 280px; padding: 8px 16px;
      background: rgba(0,20,40,0.5); border: 1px solid rgba(0,240,255,0.15);
      color: #fff; font-family: 'Rajdhani'; outline: none;
    }
    .hud-right { margin-left: auto; display: flex; align-items: center; gap: 20px; }
    .hud-item {
      position: relative; width: 36px; height: 36px;
      border: 1px solid rgba(0,240,255,0.18);
      display: flex; align-items: center; justify-content: center;
      cursor: pointer; color: rgba(0,240,255,0.75); transition: 0.25s;
    }
    .hud-item:hover { border-color: var(--cyan); box-shadow: 0 0 12px rgba(0,240,255,0.25); }
    .hud-item svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.6; }
    .badge {
      position: absolute; top: -6px; right: -8px;
      min-width: 16px; height: 16px; padding: 0 4px;
      background: var(--magenta); font-size: 9px;
      display: flex; align-items: center; justify-content: center; color: #fff;
      font-family: 'Orbitron';
    }
    .user-chip {
      display: flex; align-items: center; gap: 10px;
      padding: 6px 14px; border: 1px solid rgba(0,240,255,0.2);
      font-family: 'Orbitron'; font-size: 12px; letter-spacing: 1px;
    }
    .user-chip .dot {
      width: 8px; height: 8px; background: #00ff88; border-radius: 50%;
      box-shadow: 0 0 8px #00ff88;
    }

    .dash-body { flex: 1; display: flex; overflow: hidden; }

    .left-zone {
      width: 320px; padding: 28px 20px;
      display: flex; flex-direction: column; align-items: center;
      border-right: 1px solid rgba(0,240,255,0.1);
      background: rgba(0,8,20,0.35);
    }

    .avatar-wrap {
      position: relative; width: 250px; height: 300px;
      display: flex; align-items: center; justify-content: center;
      margin-bottom: 12px; cursor: grab;
    }
    .avatar-wrap:active { cursor: grabbing; }
    #avatar3d { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 2; }

    .ring { position: absolute; border-radius: 50%; border: 1.5px solid; pointer-events: none; z-index: 3; }
    .r1 { width: 230px; height: 230px; border-color: rgba(0,240,255,0.2); border-top-color: var(--cyan); animation: spin 12s linear infinite; }
    .r2 { width: 198px; height: 198px; border-color: rgba(191,0,255,0.18); border-bottom-color: var(--purple); animation: spin 8s linear infinite reverse; }
    .r3 { width: 166px; height: 166px; border-color: rgba(255,0,170,0.12); border-left-color: var(--magenta); animation: spin 16s linear infinite; }
    @keyframes spin { to { transform: rotate(360deg); } }

    .holo-base {
      position: absolute; bottom: 18px; left: 50%; transform: translateX(-50%);
      width: 140px; height: 18px; z-index: 1; pointer-events: none;
      background: radial-gradient(ellipse, rgba(0,240,255,0.45), transparent 70%);
      filter: blur(2px);
    }

    .drag-hint {
      font-size: 10px; letter-spacing: 3px; color: rgba(0,240,255,0.35);
      text-transform: uppercase; margin-bottom: 10px;
    }

    .callsign { font-family: 'Orbitron'; font-size: 20px; letter-spacing: 3px; color: #fff; }
    .rank {
      font-size: 12px; letter-spacing: 3px; color: var(--purple);
      margin: 4px 0 22px; text-transform: uppercase;
    }

    .mini-stats { width: 100%; display: flex; flex-direction: column; gap: 14px; }
    .stat-row { display: flex; justify-content: space-between; font-size: 14px; color: rgba(255,255,255,0.6); }
    .stat-row span:last-child { color: var(--cyan); font-family: 'Orbitron'; font-size: 13px; }

    .content-grid {
      flex: 1; padding: 28px;
      display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
      gap: 20px; overflow-y: auto;
    }

    .h-card {
      background: var(--glass); backdrop-filter: blur(16px);
      border: 1px solid var(--border); padding: 24px; min-height: 200px;
      position: relative; transition: 0.35s cubic-bezier(0.2, 0.8, 0.2, 1); overflow: hidden;
    }
    .h-card:hover {
      transform: translateY(-8px) rotateX(4deg);
      border-color: rgba(0,240,255,0.5);
      box-shadow: 0 20px 40px rgba(0,0,0,0.4), 0 0 30px rgba(0,240,255,0.15);
    }
    .h-card h3 {
      font-family: 'Orbitron'; font-size: 13px; letter-spacing: 2px;
      color: var(--cyan); margin-bottom: 16px;
      display: flex; align-items: center; gap: 10px;
    }
    .h-card h3::before {
      content: ''; width: 8px; height: 8px;
      border: 1px solid var(--cyan); transform: rotate(45deg);
      box-shadow: 0 0 8px var(--cyan); flex-shrink: 0;
    }

    .items-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
    .item-slot {
      aspect-ratio: 1; background: rgba(0,240,255,0.05);
      border: 1px solid rgba(0,240,255,0.15);
      display: flex; align-items: center; justify-content: center;
      transition: 0.2s; position: relative;
    }
    .item-slot:hover {
      background: rgba(0,240,255,0.12);
      box-shadow: 0 0 12px rgba(0,240,255,0.3);
    }
    .item-slot.empty { color: rgba(0,240,255,0.25); font-size: 18px; }

    .g-item { width: 46%; height: 46%; }
    .g-diamond { clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%); background: linear-gradient(135deg, #00f0ff, #007a88); box-shadow: 0 0 10px rgba(0,240,255,0.5); }
    .g-hex { clip-path: polygon(25% 0, 75% 0, 100% 50%, 75% 100%, 25% 100%, 0 50%); background: linear-gradient(135deg, #bf00ff, #5a007a); box-shadow: 0 0 10px rgba(191,0,255,0.45); }
    .g-tri { clip-path: polygon(50% 0, 100% 100%, 0 100%); background: linear-gradient(180deg, #ff00aa, #7a0055); }
    .g-bar { clip-path: polygon(10% 20%, 90% 20%, 80% 80%, 20% 80%); background: linear-gradient(90deg, #00f0ff, #bf00ff); }
    .g-oct { clip-path: polygon(30% 0, 70% 0, 100% 30%, 100% 70%, 70% 100%, 30% 100%, 0 70%, 0 30%); background: linear-gradient(135deg, #00ffcc, #006688); }
    .g-core { border-radius: 50%; background: radial-gradient(circle at 35% 35%, #fff, #00f0ff 40%, #003344); box-shadow: 0 0 12px #00f0ff; }

    .friend {
      display: flex; align-items: center; gap: 10px;
      padding: 8px 0; border-bottom: 1px solid rgba(255,255,255,0.04); font-size: 14px;
    }
    .f-dot {
      width: 7px; height: 7px; background: #00ff88; border-radius: 50%;
      box-shadow: 0 0 6px #00ff88; animation: pulse 2s infinite;
    }
    .f-dot.away { background: #ffaa00; box-shadow: 0 0 6px #ffaa00; animation: none; }
    @keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.4; } }

    .bar-wrap { margin-top: 12px; }
    .bar-label { display: flex; justify-content: space-between; font-size: 12px; margin-bottom: 4px; color: rgba(255,255,255,0.5); }
    .bar { height: 4px; background: rgba(0,240,255,0.1); overflow: hidden; }
    .bar > div { height: 100%; background: linear-gradient(90deg, var(--cyan), var(--purple)); box-shadow: 0 0 8px var(--cyan); }

    .log-line { font-size: 12px; color: rgba(0,240,255,0.55); padding: 5px 0; font-family: monospace; }
    .log-line span { color: var(--purple); }

    .market-row { display: flex; gap: 10px; }
    .market-row .item-slot { flex: 1; height: 74px; aspect-ratio: auto; }

    @media (max-width: 900px) {
      .left-zone { width: 240px; }
      .avatar-wrap { width: 200px; height: 240px; }
    }
  
/* ===== CapricaWeb additions ===== */
body { overflow-y: auto; min-height: 100vh; height: auto; }
#auth { min-height: 100vh; height: auto; padding: 24px 12px; }
.auth-card { max-width: 100%; transition: width .3s; }
.auth-card.wide { width: 680px; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.hint { font-size: 12px; color: rgba(224,247,255,.5); margin: -10px 0 16px; letter-spacing: .5px; }
.msg { min-height: 20px; font-size: 14px; margin: 4px 0 6px; color: #ff6b8a; text-align: center; }
.msg.ok { color: #4dffb0; }
.steps { display: flex; justify-content: center; gap: 10px; margin-bottom: 22px; }
.steps .s { width: 26px; height: 26px; line-height: 24px; text-align: center; border: 1px solid rgba(0,240,255,.25); font-family: Orbitron; font-size: 12px; color: rgba(255,255,255,.4); }
.steps .s.on { color: var(--cyan); border-color: var(--cyan); box-shadow: 0 0 12px rgba(0,240,255,.4); }
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.acard { cursor: pointer; border: 1px solid rgba(0,240,255,.2); background: rgba(0,10,30,.5); transition: .3s; }
.acard:hover { border-color: var(--cyan); }
.acard.sel { border-color: var(--magenta); box-shadow: 0 0 22px rgba(255,0,170,.45); }
.aimg { aspect-ratio: 1/1; background: linear-gradient(160deg, rgba(0,240,255,.15), rgba(191,0,255,.25)) center/cover no-repeat; display: flex; align-items: center; justify-content: center; }
.aimg span { font-family: Orbitron; font-size: 44px; color: rgba(255,255,255,.5); }
.aname { text-align: center; padding: 8px; font-family: Orbitron; font-size: 12px; letter-spacing: 2px; }
.row2 { display: flex; gap: 12px; }
.row2 .btn-enter { flex: 1; }
.btn-enter.ghost { border-color: rgba(255,255,255,.25); color: rgba(255,255,255,.6); }
.btn-enter:disabled { opacity: .4; cursor: not-allowed; }
.summary { border: 1px solid rgba(0,240,255,.2); padding: 14px 16px; margin-bottom: 18px; line-height: 1.9; font-size: 15px; }
.summary b { color: var(--cyan); font-weight: 600; }
.progress { height: 4px; background: rgba(0,240,255,.1); margin-bottom: 12px; display: none; overflow: hidden; }
.progress.on { display: block; }
.progress div { height: 100%; width: 35%; background: var(--cyan); box-shadow: 0 0 12px var(--cyan); animation: slide 1.2s ease-in-out infinite; }
@keyframes slide { from { margin-left: -35%; } to { margin-left: 100%; } }
.hud-btn, .btn-small { background: transparent; border: 1px solid var(--cyan); color: var(--cyan); font-family: Orbitron; font-size: 11px; letter-spacing: 2px; padding: 9px 14px; cursor: pointer; transition: .3s; }
.hud-btn:hover, .btn-small:hover { background: rgba(0,240,255,.12); box-shadow: 0 0 18px rgba(0,240,255,.35); }
.hud-btn { margin-left: 16px; }
.kv { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; padding: 6px 0; border-bottom: 1px solid rgba(0,240,255,.08); }
.kv span { opacity: .6; } .kv b { font-weight: 600; word-break: break-all; text-align: right; }
.mono { font-family: monospace; font-size: 12px; }
.h-card .btn-small { margin-top: 12px; }
.h-card .field { margin-bottom: 12px; }
.plain { font-size: 14px; opacity: .75; line-height: 1.6; margin-bottom: 10px; }
.h-card.dim { opacity: .45; }
@media (max-width: 720px) {
  .auth-card, .auth-card.wide { width: 100%; padding: 32px 20px; }
  .cards { grid-template-columns: repeat(2, 1fr); }
  .two { grid-template-columns: 1fr; }
  #dashboard { height: auto; min-height: 100vh; }
  .dash-body { flex-direction: column; overflow: visible; }
  .left-zone { width: 100%; border-right: 0; }
  .content-grid { overflow: visible; }
  .content-grid { grid-template-columns: 1fr; }
  .avatar-wrap { margin: 0 auto; }
}

.acard .aname { position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0 0 0 0); }
.acard { position:relative; }
