/* ==========================================================================
   LOGINPAGE 19 - TACTICAL ESPORTS (2-Column HUD Lobby + Horizontal Battle Pass)
   ========================================================================== */
:root {
  --bg-carbon: #0a0d12;
  --surface-slate: #11161f;
  --surface-dark: #07090d;
  --border-slate: rgba(255, 255, 255, 0.09);
  --border-lime: rgba(163, 230, 53, 0.35);
  --lime: #a3e635;
  --crimson: #f43f5e;
  --cyan: #22d3ee;
  --text-main: #f8fafc;
  --text-sub: #94a3b8;
  --text-muted: #64748b;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { overflow-x: hidden; max-width: 100%; }
body {
  font-family: var(--font-sans); background-color: var(--bg-carbon);
  background-image:
    radial-gradient(circle at 85% 5%, rgba(163,230,53,0.12) 0%, transparent 45%),
    linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px);
  background-size: 100% 100%, 30px 30px, 30px 30px;
  color: var(--text-main); min-height: 100vh; min-height: 100dvh; line-height: 1.5;
}
#app-loader { position: fixed; inset: 0; z-index: 9999; background: var(--bg-carbon); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; transition: opacity 0.3s, visibility 0.3s; }
#app-loader.fade-out { opacity: 0; visibility: hidden; }
.tac-spinner { width: 38px; height: 38px; border-radius: 50%; border: 3px solid rgba(163,230,53,0.16); border-top-color: var(--lime); animation: spin 0.7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.tac-shell { width: 100%; max-width: 920px; margin: 0 auto; padding: 18px 16px 40px; }
.tac-shell.centered { max-width: 440px; min-height: 100vh; display: flex; flex-direction: column; justify-content: center; }

/* HUD Topbar */
.tac-header {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  padding: 12px 16px; background: var(--surface-slate); border: 1px solid var(--border-slate);
  border-left: 4px solid var(--lime); border-radius: 14px; margin-bottom: 16px;
}
.tac-brand { display: flex; align-items: center; gap: 10px; min-width: 0; flex: 1; }
.tac-logo { width: 38px; height: 38px; border-radius: 10px; background: rgba(163,230,53,0.12); border: 1px solid var(--border-lime); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.tac-logo img { width: 24px; height: 24px; object-fit: contain; }
.tac-title { font-size: 15px; font-weight: 800; letter-spacing: 0.04em; text-transform: uppercase; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tac-sub { font-size: 11px; color: var(--text-sub); }
.tac-pill { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 6px; background: rgba(163,230,53,0.12); border: 1px solid var(--border-lime); color: var(--lime); font-family: var(--font-mono); font-size: 10.5px; font-weight: 700; }
.tac-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--lime); box-shadow: 0 0 8px var(--lime); }

/* 2-Column Lobby Grid */
.lobby-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; }
.lobby-grid > * { min-width: 0; max-width: 100%; }
@media (min-width: 780px) { .lobby-grid { grid-template-columns: 400px minmax(0, 1fr); align-items: start; } }

.tac-panel { background: var(--surface-slate); border: 1px solid var(--border-slate); border-radius: 16px; padding: 20px; }
.tac-eyebrow { display: inline-flex; align-items: center; gap: 6px; font-family: var(--font-mono); font-size: 10px; font-weight: 700; letter-spacing: 0.08em; color: var(--lime); background: rgba(163,230,53,0.1); border: 1px solid var(--border-lime); padding: 3px 9px; border-radius: 6px; margin-bottom: 10px; }
.tac-hero-title { font-size: 20px; font-weight: 800; margin-bottom: 4px; }
.tac-hero-sub { font-size: 12px; color: var(--text-sub); margin-bottom: 16px; }

.tac-tabs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; padding: 4px; background: var(--surface-dark); border: 1px solid var(--border-slate); border-radius: 10px; margin-bottom: 14px; }
.tac-tab-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 8px 6px; border: none; border-radius: 7px; background: transparent; color: var(--text-sub); font-family: inherit; font-size: 12px; font-weight: 700; cursor: pointer; }
.tac-tab-btn.active { background: var(--lime); color: #0a0d12; }

.tac-field { margin-bottom: 12px; }
.tac-label { display: block; font-size: 11px; font-weight: 700; color: var(--text-sub); text-transform: uppercase; margin-bottom: 6px; }
.tac-input-wrap { position: relative; display: flex; align-items: center; }
.tac-input-icon { position: absolute; left: 14px; color: var(--lime); font-size: 14px; pointer-events: none; }
.tac-input { width: 100%; height: 46px; padding: 0 42px 0 40px; border-radius: 10px; background: var(--surface-dark); border: 1px solid var(--border-slate); color: #fff; font-family: var(--font-mono); font-size: 14px; font-weight: 700; outline: none; }
.tac-input:focus { border-color: var(--lime); box-shadow: 0 0 0 3px rgba(163,230,53,0.18); }
.tac-eye-btn { position: absolute; right: 10px; background: none; border: none; color: var(--text-sub); cursor: pointer; padding: 6px; }

.btn-tac-primary { width: 100%; height: 46px; border: none; border-radius: 10px; background: var(--lime); color: #0a0d12; font-family: inherit; font-size: 13.5px; font-weight: 800; text-transform: uppercase; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 8px; text-decoration: none; }
.btn-tac-secondary { width: 100%; height: 40px; border-radius: 10px; background: rgba(255,255,255,0.04); border: 1px solid var(--border-slate); color: var(--text-main); font-family: inherit; font-size: 12px; font-weight: 600; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 8px; text-decoration: none; }
.btn-tac-danger { width: 100%; height: 44px; border-radius: 10px; background: rgba(244,63,94,0.15); border: 1px solid rgba(244,63,94,0.4); color: #fda4af; font-family: inherit; font-size: 13px; font-weight: 700; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 8px; }

.tac-scanner { background: var(--surface-dark); border: 1px dashed var(--border-lime); border-radius: 14px; padding: 16px; text-align: center; margin-bottom: 12px; }
.tac-viewfinder { position: relative; width: 60px; height: 60px; margin: 0 auto 10px; border-radius: 12px; background: rgba(163,230,53,0.1); border: 1px solid var(--border-lime); display: flex; align-items: center; justify-content: center; color: var(--lime); font-size: 24px; overflow: hidden; }
.tac-laser { position: absolute; left: 6px; right: 6px; height: 2px; background: var(--lime); animation: scanLine 2s infinite; }
@keyframes scanLine { 0%, 100% { top: 8px; } 50% { top: 50px; } }
.tac-error { display: flex; align-items: center; gap: 8px; padding: 10px 12px; margin-bottom: 12px; border-radius: 10px; background: rgba(244,63,94,0.14); border: 1px solid rgba(244,63,94,0.35); color: #fda4af; font-size: 12px; font-weight: 600; }
.tac-divider { display: flex; align-items: center; gap: 10px; margin: 12px 0 10px; font-size: 11px; color: var(--text-muted); }
.tac-divider::before, .tac-divider::after { content: ""; flex: 1; height: 1px; background: var(--border-slate); }

/* Right Lobby: Ping + Horizontal Battle Pass Carousel */
.ping-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 14px; }
@media (max-width: 460px) { .ping-strip { grid-template-columns: repeat(2, 1fr); } }
.ping-tile { background: var(--surface-slate); border: 1px solid var(--border-slate); border-radius: 10px; padding: 10px; display: flex; align-items: center; justify-content: space-between; font-size: 11.5px; }
.ping-game { color: var(--text-sub); font-weight: 700; }
.ping-ms { font-family: var(--font-mono); font-weight: 800; color: var(--lime); }

.tac-sec-head { font-size: 13px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 10px; display: flex; align-items: center; gap: 8px; }
.battle-carousel {
  display: flex; gap: 10px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 8px; margin-bottom: 14px;
}
.tac-pkg-card {
  flex: 0 0 185px; scroll-snap-align: start; background: var(--surface-slate); border: 1px solid var(--border-slate);
  border-radius: 14px; padding: 14px; display: flex; flex-direction: column; justify-content: space-between; gap: 10px;
}
.tac-pkg-card.popular { border-color: var(--lime); background: linear-gradient(180deg, rgba(163,230,53,0.12), var(--surface-slate)); }
.tac-pkg-badge { font-family: var(--font-mono); font-size: 9.5px; font-weight: 800; padding: 2px 8px; border-radius: 4px; background: rgba(255,255,255,0.08); color: var(--text-sub); display: inline-block; width: fit-content; }
.tac-pkg-card.popular .tac-pkg-badge { background: var(--lime); color: #0a0d12; }

.tac-faq-item { background: var(--surface-slate); border: 1px solid var(--border-slate); border-radius: 10px; margin-bottom: 8px; overflow: hidden; }
.tac-faq-btn { width: 100%; background: none; border: none; padding: 11px 14px; color: #fff; font-family: inherit; font-size: 12px; font-weight: 600; text-align: left; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.tac-faq-item.open .tac-faq-btn i { transform: rotate(180deg); color: var(--lime); }
.tac-faq-ans { display: none; padding: 0 14px 12px; font-size: 11.5px; color: var(--text-sub); }
.tac-faq-item.open .tac-faq-ans { display: block; }

.tac-meta-box { background: var(--surface-dark); border: 1px solid var(--border-slate); border-radius: 10px; padding: 10px 12px; font-size: 11px; display: flex; flex-direction: column; gap: 5px; margin-top: 12px; }
.tac-meta-row { display: flex; justify-content: space-between; align-items: center; }
.tac-meta-row span:first-child { color: var(--text-muted); }
.tac-meta-row span:last-child { font-family: var(--font-mono); font-weight: 700; }

.wa-fab { position: fixed; right: 18px; bottom: 18px; z-index: 40; width: 50px; height: 50px; border-radius: 50%; background: #22c55e; color: #fff; border: none; display: flex; align-items: center; justify-content: center; font-size: 24px; cursor: pointer; box-shadow: 0 10px 24px rgba(34,197,94,0.4); }
.modal-backdrop { position: fixed; inset: 0; z-index: 50; background: rgba(10,13,18,0.8); backdrop-filter: blur(8px); display: none; align-items: center; justify-content: center; padding: 16px; }
.modal-backdrop.open { display: flex; }
.modal-tac { width: 100%; max-width: 360px; background: var(--surface-slate); border: 1px solid var(--border-lime); border-radius: 18px; padding: 20px; }
.qris-white { background: #fff; color: #0a0d12; border-radius: 12px; padding: 12px; text-align: center; margin: 12px 0; }
.qris-white img { width: 145px; height: 145px; object-fit: contain; margin: 6px auto; display: block; }
.tac-footer { text-align: center; font-size: 11px; color: var(--text-muted); margin-top: 14px; }
