/* ============================================================
   BATTLEFIELD 6 META HUB — FINAL STYLES (Blue Original Theme)
   Author: Dex
   Theme: Dark Gunmetal + Electric Blue Accents
============================================================ */

/* ------------------------------------------------------------
   VARIABLES
------------------------------------------------------------ */
:root {
  --bg-main: #0b0e14;
  --bg-card: #171b23;
  --bg-panel: #11141b;
  --accent: #00bfff; /* Original electric blue tone */
  --accent-soft: rgba(0, 191, 255, 0.25);
  --text-light: #e2e5ea;
  --text-muted: #a8b0bb;
  --transition: 0.3s ease;
  --border-soft: 1px solid rgba(0, 191, 255, 0.25);
}

/* ------------------------------------------------------------
   GLOBAL
------------------------------------------------------------ */
body {
  margin: 0;
  font-family: "Roboto", sans-serif;
  background: var(--bg-main);
  color: var(--text-light);
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 1px;
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: var(--transition);
}
a:hover { opacity: 0.8; }

/* ------------------------------------------------------------
   HEADER + NAVIGATION
------------------------------------------------------------ */
header {
  background: var(--bg-panel);
  border-bottom: 2px solid var(--accent-soft);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 24px;
}
header h1 {
  margin: 0;
  font-size: 1.4rem;
}

nav button {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 15px;
  margin: 0 12px;
  cursor: pointer;
  transition: var(--transition);
}
nav button:hover,
nav button.active {
  color: var(--accent);
  text-shadow: 0 0 5px var(--accent);
}

/* ------------------------------------------------------------
   DISCORD BANNER
------------------------------------------------------------ */
#discord-banner {
  background: #1b1e27;
  color: var(--text-light);
  text-align: center;
  padding: 8px 0;
  border-bottom: var(--border-soft);
}
.discord-content {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
}
.discord-logo { width: 28px; }
.discord-btn {
  background: var(--accent);
  color: #fff;
  padding: 6px 14px;
  border-radius: 6px;
  font-weight: bold;
  transition: var(--transition);
}
.discord-btn:hover { background: #0099dd; }

/* ------------------------------------------------------------
   RADAR LOADER
------------------------------------------------------------ */
#loader {
  position: fixed;
  inset: 0;
  background: radial-gradient(circle at center, #0b1018 40%, #000);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  transition: opacity 0.6s ease;
}

.radar-wrapper {
  position: relative;
  width: 240px;
  height: 240px;
}

.radar-core {
  width: 240px;
  height: 240px;
  border-radius: 50%;
  border: 2px solid var(--accent-soft);
  background: radial-gradient(circle, rgba(0, 191, 255, 0.12) 5%, transparent 80%);
  overflow: hidden;
  position: relative;
  box-shadow: 0 0 20px rgba(0, 191, 255, 0.15);
}

/* Sweep Beam */
.radar-sweep {
  position: absolute;
  width: 100%;
  height: 100%;
  background: conic-gradient(from 0deg, rgba(0,191,255,0.6), transparent 60%);
  border-radius: 50%;
  animation: radarSweep 2.5s linear infinite;
}
@keyframes radarSweep {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* Radar Blips */
.radar-blip {
  position: absolute;
  width: 6px;
  height: 6px;
  background: var(--accent);
  border-radius: 50%;
  opacity: 0.8;
  transition: transform 0.2s ease, opacity 0.5s ease;
}
.radar-blip.glow {
  transform: scale(1.8);
  box-shadow: 0 0 10px var(--accent);
  opacity: 1;
}

/* Expanding Pulse Ring */
.radar-pulse-ring {
  position: absolute;
  width: 20px;
  height: 20px;
  border: 1px solid var(--accent);
  border-radius: 50%;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%) scale(0);
  animation: pulseRing 2s ease-out forwards;
}
@keyframes pulseRing {
  0% { transform: translate(-50%, -50%) scale(0); opacity: 0.9; }
  100% { transform: translate(-50%, -50%) scale(5); opacity: 0; }
}

.loader-text {
  margin-top: 25px;
  text-align: center;
}
.progress-bar {
  width: 240px;
  height: 10px;
  background: #0b0d12;
  border: 1px solid var(--accent-soft);
  border-radius: 5px;
  overflow: hidden;
  margin: 12px auto;
}
#progress-fill {
  width: 0%;
  height: 100%;
  background: var(--accent);
  transition: width 0.3s ease;
}
#progress-percent {
  color: var(--accent);
  margin-top: 5px;
}

/* ------------------------------------------------------------
   MAIN PAGE STRUCTURE
------------------------------------------------------------ */
.page {
  display: none;
  padding: 20px 40px;
}
.page.active {
  display: block;
  animation: fadeIn 0.6s ease;
}
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ------------------------------------------------------------
   META TABS
------------------------------------------------------------ */
.meta-subtabs {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-bottom: 25px;
}
.subtab {
  background: none;
  border: 1px solid var(--accent-soft);
  color: var(--text-muted);
  padding: 8px 14px;
  border-radius: 6px;
  cursor: pointer;
  transition: var(--transition);
}
.subtab.active,
.subtab:hover {
  color: var(--accent);
  background: var(--accent-soft);
}

.meta-tab {
  display: none;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.4s ease, transform 0.4s ease;
}
.meta-tab.active {
  display: block;
}
.meta-tab.fade-in {
  opacity: 1;
  transform: translateY(0);
}

/* ------------------------------------------------------------
   WEAPON GRID + CARDS
------------------------------------------------------------ */
.weapon-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}
.weapon-card {
  background: var(--bg-card);
  border: var(--border-soft);
  border-radius: 10px;
  padding: 10px;
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.weapon-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 0 12px rgba(0,191,255,0.1);
}
.weapon-img {
  width: 100%;
  border-radius: 8px;
}
.weapon-info {
  padding: 8px 0;
}
.weapon-type {
  color: var(--text-muted);
  font-size: 0.9em;
}

/* Show Attachments Button */
.toggle-btn {
  width: 100%;
  background: #10131b;
  color: var(--accent);
  border: 1px solid var(--accent-soft);
  border-radius: 6px;
  padding: 8px;
  cursor: pointer;
  transition: background 0.3s ease;
}
.toggle-btn:hover {
  background: var(--accent-soft);
}

/* ------------------------------------------------------------
   ATTACHMENTS PANEL
------------------------------------------------------------ */
.attachments-wrapper {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease;
}
.attachments-wrapper.open { /* height set dynamically */ }
.attachments {
  padding: 10px 0;
}
.attachment {
  border-top: 1px solid var(--accent-soft);
  padding: 6px 0;
}
.attachment h4 {
  margin: 0;
  color: var(--accent);
}
.attachment p {
  margin: 2px 0 0 0;
  color: var(--text-muted);
}
.points-icon {
  width: 14px;
  height: 14px;
  vertical-align: middle;
  margin-right: 4px;
  opacity: 0.85;
}

/* ------------------------------------------------------------
   INFO CARDS
------------------------------------------------------------ */
.info-card {
  background: var(--bg-card);
  border: var(--border-soft);
  border-radius: 10px;
  padding: 20px;
  text-align: center;
  color: var(--text-muted);
  font-style: italic;
}

/* ------------------------------------------------------------
   CHALLENGES
------------------------------------------------------------ */
.challenge-group {
  margin-bottom: 25px;
}
.challenge-card {
  background: var(--bg-card);
  border: var(--border-soft);
  border-radius: 8px;
  margin: 10px 0;
}
.challenge-header {
  padding: 10px;
  display: flex;
  justify-content: space-between;
  cursor: pointer;
  background: #12141c;
  color: var(--accent);
}
.challenge-card.open .challenge-body {
  display: block;
}
.challenge-body {
  display: none;
  padding: 10px;
  border-top: 1px solid var(--accent-soft);
}

/* ------------------------------------------------------------
   FOOTER
------------------------------------------------------------ */
footer {
  background: var(--bg-panel);
  border-top: 2px solid var(--accent-soft);
  padding: 20px 40px;
  color: var(--text-muted);
}
.footer-content {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
}
.footer-left h3 { color: var(--accent); }
.footer-right .social-links a {
  color: var(--accent);
  margin: 0 6px;
}
.footer-bottom {
  text-align: center;
  margin-top: 10px;
  font-size: 0.8em;
}
.footer-bottom span { color: var(--accent); }
