/* ===========================
   HEXCOACH - Global Stylesheet
   Dark Blue Modern Theme
   =========================== */

@import url('https://fonts.googleapis.com/css2?family=Caveat:wght@600&family=Inter:wght@300;400;500;600;700;800;900&family=Outfit:wght@400;600;700;800;900&family=Orbitron:wght@400;500;600;700;800;900&display=swap');

:root {
  --bg-primary: #000000;
  --bg-secondary: #0a0a0a;
  --bg-card: #111111;
  --bg-card-hover: #181818;
  --bg-glass: rgba(17, 17, 17, 0.7);
  --accent-blue: #ff4655;
  --accent-blue-bright: #ff707c;
  --accent-purple: #ff4655;
  --accent-cyan: #ff4655;
  --accent-gold: #f59e0b;
  --accent-green: #10b981;
  --accent-red: #ff4655;
  --accent-orange: #f97316;
  --border-color: rgba(255, 70, 85, 0.15);
  --border-glow: rgba(255, 70, 85, 0.4);
  --text-primary: #ffffff;
  --text-secondary: #a0a0a0;
  --text-muted: #666666;
  --gradient-primary: linear-gradient(135deg, #ff4655 0%, #ff707c 100%);
  --gradient-hero: linear-gradient(180deg, #000000 0%, #0a0a0a 50%, #000000 100%);
  --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.4);
  --shadow-glow: 0 0 40px rgba(255, 70, 85, 0.15);
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
  line-height: 1.6;
}

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg-primary); }
::-webkit-scrollbar-thumb { background: var(--accent-blue); border-radius: 3px; }

/* ===== NAVBAR ===== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2rem;
  height: 64px;
  background: rgba(6, 13, 31, 0.85);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-color);
}

.navbar-left {
  display: flex;
  align-items: center;
  gap: 2.5rem;
}

.nav-links {
  display: flex;
  gap: 1.5rem;
  align-items: center;
}

.nav-links a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  transition: color 0.2s;
}

.nav-links a:hover {
  color: var(--text-primary);
}

.navbar-logo {
  display: flex;
  align-items: center;
  gap: 0;
  text-decoration: none;
  cursor: pointer;
}

.navbar-logo .logo-icon {
  display: none;
}

.navbar-logo .logo-text {
  font-family: 'Orbitron', sans-serif;
  font-size: 1.3rem;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.navbar-logo .logo-dot {
  color: #ff4655;
  font-family: 'Orbitron', sans-serif;
  font-size: 1.3rem;
  font-weight: 900;
}

.navbar-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Floating tagline pill below navbar */
.nav-tagline-pill {
  position: fixed;
  top: 68px;
  right: 24px;
  z-index: 999;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 50px;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-secondary);
  letter-spacing: 0.02em;
  white-space: nowrap;
  backdrop-filter: blur(12px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
  animation: fadeSlideIn 0.6s ease 0.3s both;
}

.nav-tagline-pill svg {
  color: var(--accent-blue);
  flex-shrink: 0;
}

.nav-tagline-pill .highlight {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 800;
}

@keyframes fadeSlideIn {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 20px;
  border-radius: var(--radius-sm);
  font-family: 'Inter', sans-serif;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  border: none;
  text-decoration: none;
}

.btn-primary {
  background: var(--gradient-primary);
  color: white;
  box-shadow: 0 0 20px rgba(255, 70, 85, 0.3);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 0 30px rgba(255, 70, 85, 0.5);
}

.btn-secondary {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  background: var(--bg-card);
  border-color: var(--border-glow);
}

.btn-outline {
  background: transparent;
  color: var(--accent-blue-bright);
  border: 1px solid var(--accent-blue);
}

.btn-outline:hover {
  background: rgba(255, 70, 85, 0.1);
}

.btn-update {
  background: linear-gradient(135deg, #f59e0b, #ef4444);
  color: white;
  padding: 8px 18px;
  font-size: 0.85rem;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  font-weight: 700;
  transition: all 0.2s;
}

.btn-update:hover {
  opacity: 0.85;
  transform: scale(1.02);
}

.btn-beta {
  background: transparent;
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 14px 32px;
  font-size: 0.95rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-radius: var(--radius-sm);
  transition: all 0.2s;
}

.btn-beta:hover {
  background: white;
  color: black;
  border-color: white;
  box-shadow: 0 0 20px rgba(255,255,255,0.4);
}

/* ===== FOOTER ===== */
footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  padding: 3rem 2rem 1.5rem;
  margin-top: 6rem;
}

.footer-top {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 3rem;
  max-width: 1200px;
  margin: 0 auto 2rem;
}

.footer-brand .logo-text {
  font-family: 'Orbitron', sans-serif;
  font-size: 1.4rem;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.footer-brand p {
  color: var(--text-secondary);
  font-size: 0.85rem;
  margin-top: 0.5rem;
  max-width: 280px;
}

.footer-section h4 {
  color: var(--text-primary);
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 1rem;
}

.footer-section ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.footer-section ul li a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.875rem;
  transition: color 0.2s;
}

.footer-section ul li a:hover {
  color: var(--accent-blue-bright);
}

.social-links {
  display: flex;
  gap: 12px;
  margin-top: 0.5rem;
}

.social-link {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.85rem;
  transition: all 0.2s;
}

.social-link:hover {
  border-color: var(--accent-blue);
  color: var(--text-primary);
}

.footer-divider {
  border: none;
  border-top: 1px solid var(--border-color);
  margin: 0;
}

.footer-bottom {
  max-width: 1200px;
  margin: 1.5rem auto 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer-legal {
  font-size: 0.7rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ===== CARDS ===== */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  transition: all 0.2s ease;
}

.card:hover {
  border-color: var(--border-glow);
  box-shadow: var(--shadow-glow);
}

/* ===== BADGES & TAGS ===== */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.badge-win { background: rgba(16, 185, 129, 0.15); color: #10b981; border: 1px solid rgba(16, 185, 129, 0.3); }
.badge-loss { background: rgba(239, 68, 68, 0.15); color: #ef4444; border: 1px solid rgba(239, 68, 68, 0.3); }
.badge-gold { background: rgba(245, 158, 11, 0.15); color: #f59e0b; border: 1px solid rgba(245, 158, 11, 0.3); }
.badge-platinum { background: rgba(6, 182, 212, 0.15); color: #06b6d4; border: 1px solid rgba(6, 182, 212, 0.3); }
.badge-diamond { background: rgba(139, 92, 246, 0.15); color: #a78bfa; border: 1px solid rgba(139, 92, 246, 0.3); }

/* ===== RANK ICONS (emoji-based) ===== */
.rank-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  background: var(--bg-secondary);
}

/* ===== UTILITY ===== */
.page { display: none; }
.page.active { display: block; }

.main-content {
  padding-top: 64px;
  min-height: 100vh;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

.section-title {
  font-family: 'Outfit', sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 1rem;
}

/* ===== GLOW PULSE ===== */
@keyframes pulse-glow {
  0%, 100% { box-shadow: 0 0 20px rgba(255, 70, 85, 0.2); }
  50% { box-shadow: 0 0 40px rgba(255, 70, 85, 0.4); }
}

@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-8px); }
}

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes shimmer {
  0% { background-position: -200% center; }
  100% { background-position: 200% center; }
}

.fade-in { animation: fadeInUp 0.5s ease forwards; }

/* ===== WIN/LOSS COLORS ===== */
.text-win { color: var(--accent-green); }
.text-loss { color: var(--accent-red); }
.text-blue { color: var(--accent-blue-bright); }
.text-gold { color: var(--accent-gold); }
.text-muted { color: var(--text-muted); }
.text-secondary { color: var(--text-secondary); }

/* ===== PROGRESS BAR ===== */
.progress-bar {
  height: 6px;
  background: var(--bg-secondary);
  border-radius: 3px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  border-radius: 3px;
  transition: width 0.5s ease;
}

/* ===== TABS ===== */
.tabs {
  display: flex;
  gap: 4px;
  background: var(--bg-secondary);
  border-radius: var(--radius-sm);
  padding: 4px;
}

.tab {
  padding: 6px 16px;
  border-radius: 6px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  color: var(--text-secondary);
  border: none;
  background: transparent;
}

.tab.active {
  background: var(--accent-blue);
  color: white;
}

.tab:hover:not(.active) {
  color: var(--text-primary);
  background: var(--bg-card);
}

/* ===== SEPARATOR ===== */
.sep {
  border: none;
  border-top: 1px solid var(--border-color);
  margin: 1.5rem 0;
}

/* ===== LANG SWITCHER ===== */
.lang-switcher {
  display: flex;
  align-items: center;
  gap: 4px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: 3px;
  flex-shrink: 0;
}

.lang-btn {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 16px;
  border: none;
  background: transparent;
  cursor: pointer;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-muted);
  font-family: 'Inter', sans-serif;
  transition: all 0.2s;
  white-space: nowrap;
}

.lang-btn:hover {
  color: var(--text-primary);
}

.lang-btn.lang-active {
  background: var(--gradient-primary);
  color: white;
  box-shadow: 0 0 10px rgba(255,70,85,0.3);
}

.lang-btn .lang-flag {
  font-size: 1rem;
  line-height: 1;
}

/* ===== REAL GAME ASSETS (DDragon / Community Dragon) ===== */

/* Champion square icons */
.champ-sq {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  object-fit: cover;
  border: 2px solid rgba(255,70,85,0.3);
  display: block;
  flex-shrink: 0;
}

.champ-sq-sm { width: 28px; height: 28px; border-radius: 5px; }
.champ-sq-lg { width: 52px; height: 52px; border-radius: 10px; }
.champ-sq-xl { width: 64px; height: 64px; border-radius: 12px; }
.champ-sq-sb { /* scoreboard */ width: 36px; height: 36px; border-radius: 6px; }

/* Profile / summoner icon */
.profile-icon-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: inherit;
  display: block;
}

/* Rank emblem — large (used in rank cards) */
.rank-emblem-img {
  width: 350px; /* Compensate for massive transparent padding in Riot assets */
  height: 350px;
  object-fit: contain;
  filter: drop-shadow(0 0 8px rgba(0,0,0,0.5));
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
}

/* Rank mini crest (past seasons, inline) */
.rank-mini-img {
  width: 22px;
  height: 22px;
  object-fit: contain;
  vertical-align: middle;
}

/* Floating card champion image (home) */
.fc-champ-img {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  object-fit: cover;
  border: 2px solid rgba(255,70,85,0.4);
}

/* Other account icon */
.oa-icon-img {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  object-fit: cover;
  border: 1.5px solid var(--border-color);
  flex-shrink: 0;
}

/* Scoreboard champion cell */
.sb-champ-cell {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
}

/* Chat avatar profile icon */
.chat-player-icon {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: cover;
  border: 1.5px solid var(--accent-blue);
}

/* ===== TEAM DOT (scoreboard headers) ===== */
.team-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  margin-right: 6px;
  vertical-align: middle;
}
.team-dot-blue { background: #3b82f6; box-shadow: 0 0 6px rgba(59,130,246,0.5); }
.team-dot-red  { background: #ef4444; box-shadow: 0 0 6px rgba(239,68,68,0.5); }

/* ===== MATCHUP VS (analysis) ===== */
.mb-vs-inner {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  flex-wrap: wrap;
}

/* ===== PORO ICON (signup verification) ===== */
.poro-icon-inline {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: cover;
  vertical-align: middle;
  border: 1.5px solid var(--accent-gold);
  margin-right: 6px;
}

.poro-instruction {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px;
}

.poro-preview-img {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--accent-gold);
  box-shadow: 0 0 20px rgba(245,158,11,0.3);
}

/* ===== MSG AVATAR (chat) ===== */
.msg-avatar {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.msg-avatar-ai svg {
  display: block;
}

.msg-avatar-player {
  border-radius: 50%;
  overflow: hidden;
}

/* ===== TOOLTIP ===== */
[data-tip] {
  position: relative;
}

[data-tip]:hover::after {
  content: attr(data-tip);
  position: absolute;
  bottom: calc(100% + 6px);
  left: 50%;
  transform: translateX(-50%);
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  font-size: 0.75rem;
  padding: 4px 10px;
  border-radius: 6px;
  white-space: nowrap;
  pointer-events: none;
  z-index: 100;
}

/* UNIVERSAL NAVBAR SEARCH */
.navbar-search { display:flex; align-items:center; background:var(--bg-card); border:1px solid var(--border-color); border-radius:50px; overflow:visible; padding:4px 4px 4px 0; position:relative; }
.ns-region { display:flex; align-items:center; gap:6px; padding:6px 12px; cursor:pointer; font-size:0.8rem; font-weight:600; color:var(--text-secondary); border-radius:50px 0 0 50px; transition:background 0.2s; }
.ns-region:hover { background:rgba(59,130,246,0.08); }
.ns-dropdown { display:none; position:absolute; top:calc(100% + 6px); left:0; min-width:140px; background:var(--bg-card); border:1px solid var(--border-color); border-radius:var(--radius-md); box-shadow:0 8px 32px rgba(0,0,0,0.6); z-index:200; }
.ns-dropdown.open { display:block; }
.ns-input { background:transparent; border:none; outline:none; color:var(--text-primary); font-family:'Inter', sans-serif; font-size:0.85rem; padding:6px 10px; width:200px; }
.ns-input::placeholder { color:var(--text-muted); }
.ns-btn { width:32px; height:32px; border-radius:50%; background:var(--gradient-primary); border:none; cursor:pointer; display:flex; align-items:center; justify-content:center; color:white; transition:transform 0.2s; }
.ns-btn:hover { transform:scale(1.1); }

/* ===========================
   ANTI-JITTER / FIXED SIZES 
   (Prevent layout shift on lang switch)
   =========================== */

#cta-signup-nav { min-width: 220px; justify-content: center; text-align: center; }
.lang-switcher { min-width: 110px; justify-content: center; }

/* Home */
.feature-card { min-height: 240px; }

/* Signup Auth Panels */
.auth-panel { min-height: 550px; display: flex; flex-direction: column; justify-content: space-between; }

/* Profile Layout */
.rank-card { min-height: 220px; display: flex; flex-direction: column; justify-content: space-between; }
.match-type-badge { min-width: 130px !important; }
.match-duration { min-width: 120px !important; }
.match-kda { min-width: 105px !important; }

/* Analysis Board */
.insight-box { min-height: 260px; display: flex; flex-direction: column; justify-content: space-between; }
.wp-card { min-height: 310px; }
.swing-card { min-height: 480px; }
.chat-card { min-height: 520px; }
.obj-content { min-height: 60px; }
.prog-chart { min-height: 100px; }

