/* ==========================================================================
   BRIANTEST - Cyber Gaming Protocol
   Future Sci-Fi Cold Theme Stylesheet
   ========================================================================== */

:root {
  --bg-dark: #040711;
  --bg-primary: #070c18;
  --bg-surface: #0c1324;
  --bg-card: rgba(13, 22, 42, 0.75);
  --bg-card-hover: rgba(18, 30, 58, 0.9);
  
  /* Cold Neon Accents */
  --neon-cyan: #00f0ff;
  --neon-cyan-glow: rgba(0, 240, 255, 0.45);
  --neon-blue: #0077ff;
  --neon-purple: #8b5cf6;
  --neon-purple-glow: rgba(139, 92, 246, 0.35);
  --neon-mint: #00ffaa;
  --neon-crimson: #ff0055;
  --neon-amber: #f59e0b;
  
  /* Text & Borders */
  --text-white: #f8fafc;
  --text-dim: #94a3b8;
  --text-muted: #64748b;
  --border-cyan: rgba(0, 240, 255, 0.22);
  --border-purple: rgba(139, 92, 246, 0.25);
  --border-subtle: rgba(255, 255, 255, 0.08);

  /* Fonts */
  --font-display: 'Orbitron', 'Rajdhani', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', 'Courier New', monospace;
  --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Noto Sans TC", sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  background-color: var(--bg-dark);
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-dark);
  color: var(--text-white);
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
  min-height: 100vh;
}

/* Background Cyber Grid & Vignette */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-image: 
    linear-gradient(to right, rgba(0, 240, 255, 0.03) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(0, 240, 255, 0.03) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
  z-index: 0;
}

body::after {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: radial-gradient(circle at 50% 20%, rgba(0, 119, 255, 0.08) 0%, rgba(4, 7, 17, 0.95) 85%);
  pointer-events: none;
  z-index: 0;
}

/* Container */
.container {
  max-width: 1300px;
  margin: 0 auto;
  padding: 0 1.5rem;
  position: relative;
  z-index: 1;
}

/* ==========================================================================
   Header & Navigation
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(7, 12, 24, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-cyan);
  box-shadow: 0 4px 25px rgba(0, 0, 0, 0.6);
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 70px;
}

.brand-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
}

.brand-logo-img {
  height: 42px;
  width: auto;
  filter: drop-shadow(0 0 8px var(--neon-cyan-glow));
}

.nav-links {
  display: flex;
  align-items: center;
  list-style: none;
  gap: 2rem;
}

.nav-item a {
  font-family: var(--font-display);
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-decoration: none;
  color: var(--text-dim);
  transition: all 0.25s ease;
  position: relative;
  padding: 0.4rem 0;
}

.nav-item a:hover,
.nav-item a.active {
  color: var(--neon-cyan);
  text-shadow: 0 0 10px var(--neon-cyan-glow);
}

.nav-item a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0%;
  height: 2px;
  background: linear-gradient(90deg, var(--neon-cyan), var(--neon-purple));
  transition: width 0.3s ease;
}

.nav-item a:hover::after,
.nav-item a.active::after {
  width: 100%;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.hud-sound-btn, .mobile-menu-btn {
  background: rgba(0, 240, 255, 0.08);
  border: 1px solid var(--border-cyan);
  color: var(--neon-cyan);
  padding: 0.5rem 0.85rem;
  border-radius: 4px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  transition: all 0.2s;
}

.hud-sound-btn:hover {
  background: rgba(0, 240, 255, 0.2);
  box-shadow: 0 0 12px var(--neon-cyan-glow);
}

.mobile-menu-btn {
  display: none;
  font-size: 1.25rem;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero-section {
  position: relative;
  padding: 3rem 0 2.5rem;
  overflow: hidden;
}

.hero-banner-card {
  position: relative;
  border-radius: 12px;
  border: 1px solid var(--border-cyan);
  background: var(--bg-surface);
  overflow: hidden;
  box-shadow: 0 0 35px rgba(0, 240, 255, 0.12);
  min-height: 380px;
  display: flex;
  align-items: center;
}

.hero-bg-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  opacity: 0.42;
  filter: contrast(115%) saturate(120%);
  transition: transform 10s ease;
}

.hero-banner-card:hover .hero-bg-img {
  transform: scale(1.03);
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, rgba(5, 8, 17, 0.95) 0%, rgba(5, 8, 17, 0.75) 50%, rgba(5, 8, 17, 0.4) 100%);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 2;
  padding: 3rem;
  max-width: 680px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(0, 240, 255, 0.12);
  border: 1px solid var(--neon-cyan);
  color: var(--neon-cyan);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 2px;
  padding: 0.35rem 0.8rem;
  border-radius: 2px;
  margin-bottom: 1.25rem;
  box-shadow: 0 0 10px rgba(0, 240, 255, 0.2);
}

.badge-dot {
  width: 7px;
  height: 7px;
  background-color: var(--neon-mint);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--neon-mint);
  animation: pulse 1.8s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.85); }
}

.hero-title {
  font-family: var(--font-display);
  font-size: 2.8rem;
  font-weight: 900;
  line-height: 1.15;
  letter-spacing: 2px;
  margin-bottom: 1rem;
  color: #ffffff;
  text-shadow: 0 0 25px rgba(0, 240, 255, 0.35);
}

.hero-title .glow-cyan {
  color: var(--neon-cyan);
}

.hero-subtitle {
  font-size: 1.05rem;
  color: var(--text-dim);
  margin-bottom: 2rem;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex-wrap: wrap;
}

.cyber-btn {
  font-family: var(--font-display);
  font-size: 0.92rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-decoration: none;
  padding: 0.85rem 1.8rem;
  border-radius: 4px;
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  cursor: pointer;
  transition: all 0.25s ease;
  position: relative;
  overflow: hidden;
}

.cyber-btn-primary {
  background: linear-gradient(135deg, rgba(0, 240, 255, 0.9), rgba(0, 119, 255, 0.9));
  color: #040711;
  border: 1px solid var(--neon-cyan);
  box-shadow: 0 0 20px rgba(0, 240, 255, 0.4);
}

.cyber-btn-primary:hover {
  background: linear-gradient(135deg, #00f0ff, #0077ff);
  box-shadow: 0 0 30px rgba(0, 240, 255, 0.7);
  transform: translateY(-2px);
}

.cyber-btn-secondary {
  background: rgba(14, 22, 41, 0.8);
  color: var(--text-white);
  border: 1px solid var(--border-cyan);
}

.cyber-btn-secondary:hover {
  background: rgba(0, 240, 255, 0.15);
  border-color: var(--neon-cyan);
  box-shadow: 0 0 15px rgba(0, 240, 255, 0.3);
  transform: translateY(-2px);
}

/* Telemetry Ribbon */
.telemetry-bar {
  margin-top: 1.5rem;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

.telemetry-item {
  background: rgba(12, 19, 36, 0.6);
  border: 1px solid var(--border-subtle);
  border-left: 3px solid var(--neon-cyan);
  padding: 0.75rem 1.2rem;
  border-radius: 4px;
  backdrop-filter: blur(8px);
}

.telemetry-label {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.telemetry-val {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--neon-cyan);
}

/* ==========================================================================
   Filter & Controls Bar
   ========================================================================== */
.controls-section {
  padding: 1.5rem 0;
  border-bottom: 1px solid var(--border-subtle);
}

.controls-wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.filter-pills {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  overflow-x: auto;
  padding-bottom: 0.3rem;
}

.filter-btn {
  background: rgba(12, 19, 36, 0.8);
  border: 1px solid var(--border-subtle);
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 600;
  padding: 0.45rem 1rem;
  border-radius: 30px;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.filter-btn:hover,
.filter-btn.active {
  background: rgba(0, 240, 255, 0.15);
  border-color: var(--neon-cyan);
  color: var(--neon-cyan);
  box-shadow: 0 0 12px rgba(0, 240, 255, 0.25);
}

.search-box {
  position: relative;
  min-width: 260px;
}

.search-input {
  width: 100%;
  background: rgba(12, 19, 36, 0.9);
  border: 1px solid var(--border-cyan);
  color: var(--text-white);
  font-family: var(--font-mono);
  font-size: 0.85rem;
  padding: 0.55rem 1rem 0.55rem 2.2rem;
  border-radius: 4px;
  outline: none;
  transition: all 0.25s;
}

.search-input:focus {
  border-color: var(--neon-cyan);
  box-shadow: 0 0 15px var(--neon-cyan-glow);
}

.search-icon {
  position: absolute;
  left: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--neon-cyan);
  pointer-events: none;
  font-size: 0.85rem;
}

/* ==========================================================================
   Games Grid Section
   ========================================================================== */
.games-section {
  padding: 3rem 0;
}

.section-header {
  margin-bottom: 2rem;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
}

.section-title {
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 800;
  letter-spacing: 2px;
  color: #ffffff;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.section-title::before {
  content: '';
  display: inline-block;
  width: 4px;
  height: 24px;
  background: var(--neon-cyan);
  box-shadow: 0 0 10px var(--neon-cyan);
}

.section-tag {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--neon-purple);
}

.games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
  gap: 2rem;
}

/* Game Card */
.game-card {
  background: var(--bg-card);
  border: 1px solid var(--border-cyan);
  border-radius: 10px;
  overflow: hidden;
  position: relative;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5);
  display: flex;
  flex-direction: column;
}

.game-card:hover {
  transform: translateY(-6px);
  border-color: var(--neon-cyan);
  box-shadow: 0 15px 40px rgba(0, 240, 255, 0.25);
}

/* Cyber corner cuts */
.game-card::after {
  content: '';
  position: absolute;
  bottom: 0;
  right: 0;
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 0 0 16px 16px;
  border-color: transparent transparent var(--neon-cyan) transparent;
}

.game-thumb-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #000;
}

.game-thumb-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.game-card:hover .game-thumb-img {
  transform: scale(1.08);
}

.game-rating-tag {
  position: absolute;
  top: 12px;
  left: 12px;
  background: rgba(5, 8, 17, 0.85);
  border: 1px solid var(--neon-purple);
  color: #d8b4fe;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.2rem 0.6rem;
  border-radius: 2px;
  letter-spacing: 1px;
}

.game-status-tag {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(5, 8, 17, 0.85);
  border: 1px solid var(--neon-mint);
  color: var(--neon-mint);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.2rem 0.6rem;
  border-radius: 2px;
  box-shadow: 0 0 8px rgba(0, 255, 170, 0.3);
}

.game-body {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.game-category-badge {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--neon-cyan);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-bottom: 0.4rem;
}

.game-card-title {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: 1px;
  color: #ffffff;
  margin-bottom: 0.6rem;
}

.game-card-desc {
  font-size: 0.88rem;
  color: var(--text-dim);
  line-height: 1.55;
  margin-bottom: 1.25rem;
  flex-grow: 1;
}

.game-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--border-subtle);
  padding-top: 1rem;
  margin-bottom: 1.25rem;
}

.meta-record {
  display: flex;
  flex-direction: column;
}

.meta-record-label {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--text-muted);
}

.meta-record-val {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  color: var(--neon-cyan);
}

.game-play-btn {
  width: 100%;
  background: linear-gradient(90deg, rgba(0, 240, 255, 0.15), rgba(0, 119, 255, 0.25));
  border: 1px solid var(--neon-cyan);
  color: var(--neon-cyan);
  font-family: var(--font-display);
  font-size: 0.9rem;
  font-weight: 800;
  letter-spacing: 2px;
  padding: 0.8rem 1rem;
  border-radius: 4px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: all 0.25s ease;
}

.game-play-btn:hover {
  background: linear-gradient(90deg, var(--neon-cyan), var(--neon-blue));
  color: #040711;
  box-shadow: 0 0 20px rgba(0, 240, 255, 0.6);
}

/* ==========================================================================
   Features & Protocol Specs
   ========================================================================== */
.specs-section {
  padding: 3rem 0;
  background: rgba(10, 15, 29, 0.5);
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
}

.specs-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.spec-card {
  background: rgba(14, 22, 41, 0.5);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 2rem;
  position: relative;
  transition: all 0.3s;
}

.spec-card:hover {
  border-color: var(--border-purple);
  box-shadow: 0 0 20px var(--neon-purple-glow);
}

.spec-icon {
  font-size: 2rem;
  color: var(--neon-cyan);
  margin-bottom: 1rem;
  display: inline-block;
}

.spec-title {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: #ffffff;
}

.spec-desc {
  font-size: 0.88rem;
  color: var(--text-dim);
  line-height: 1.6;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
  background: #03050c;
  border-top: 1px solid var(--border-cyan);
  padding: 3rem 0 2rem;
  margin-top: 3rem;
  position: relative;
}

.footer-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.footer-copy {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
}

.footer-links {
  display: flex;
  gap: 1.5rem;
  list-style: none;
}

.footer-links a {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-dim);
  text-decoration: none;
  transition: color 0.2s;
}

.footer-links a:hover {
  color: var(--neon-cyan);
}

.footer-sub {
  text-align: center;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-muted);
  border-top: 1px solid var(--border-subtle);
  padding-top: 1.5rem;
}

/* Mobile Bottom Navigation Bar (App Dock) */
.mobile-dock {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 60px;
  background: rgba(7, 12, 24, 0.95);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-top: 1px solid var(--border-cyan);
  z-index: 99;
  justify-content: space-around;
  align-items: center;
}

.dock-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.68rem;
  font-family: var(--font-mono);
  gap: 2px;
  padding: 6px 12px;
  transition: color 0.2s;
}

.dock-item.active,
.dock-item:hover {
  color: var(--neon-cyan);
}

.dock-icon {
  font-size: 1.1rem;
}

/* ==========================================================================
   Responsive Breakpoints
   ========================================================================== */
@media (max-width: 992px) {
  .hero-title {
    font-size: 2.2rem;
  }
  .telemetry-bar {
    grid-template-columns: repeat(2, 1fr);
  }
  .specs-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
  }
  .mobile-menu-btn {
    display: flex;
  }
  .hero-content {
    padding: 2rem 1.5rem;
  }
  .hero-title {
    font-size: 1.85rem;
  }
  .games-grid {
    grid-template-columns: 1fr;
  }
  .controls-wrapper {
    flex-direction: column;
    align-items: stretch;
  }
  .search-box {
    width: 100%;
  }
  .mobile-dock {
    display: flex;
  }
  body {
    padding-bottom: 60px;
  }
}
