/* ============================================
   GROOMSMAN INVITE - STYLES
   Theme: Elegant Dark + Gold Accents
   ============================================ */

/* === CSS Variables === */
:root {
  /* LoL Client "Obsidian" Palette */
  --bg-primary: #010a13;
  --bg-secondary: #091428;
  --bg-card: #0a1428;
  --bg-card-hover: #112643;
  
  /* Hextech Gold & Magic */
  --gold: #c8aa6e;
  --gold-light: #f0e6d2;
  --gold-dark: #785a28;
  --cian: #0ac8b9;
  --blue-magic: #005a82;
  --champagne: #f7e7c0;
  
  --white: #f0e6d2; /* Beaufort white is slightly cream */
  --off-white: #cdbe91;
  --gray: #a09b8c;
  --gray-dark: #3c3c41;
  
  --success: #0ac8b9; /* LoL cyan is for positive interactions too */
  --success-dark: #005a82;
  --danger: #ef4444;
  --danger-dark: #811e1e;
  
  --font-display: 'Playfair Display', Georgia, serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --ease-out-expo: cubic-bezier(0.19, 1, 0.22, 1);
  --ease-out-back: cubic-bezier(0.34, 1.56, 0.64, 1);
  --hextech-border: 1px solid var(--gold-dark);
}

/* === Reset & Base === */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  background: var(--bg-primary);
  color: var(--off-white);
  line-height: 1.6;
  overflow-x: hidden;
}

/* Scrollbar Styling */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: var(--bg-primary);
}
::-webkit-scrollbar-thumb {
  background: var(--gold-dark);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--gold);
}

/* === Utility === */
.container {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 24px;
}

.section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  padding: 80px 0;
}

/* === Particles Canvas === */
#particles-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

/* === Confetti Canvas === */
#confetti-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 9999;
}

/* === Hextech UI Components === */
.hextech-border {
  position: relative;
  border: 1px solid var(--gold-dark);
}

.hextech-border::before {
  content: '';
  position: absolute;
  top: -2px; left: -2px; right: -2px; bottom: -2px;
  border: 1px solid var(--gold);
  pointer-events: none;
  opacity: 0.3;
}

.hextech-panel {
  background: var(--bg-secondary);
  border: 1px solid var(--gold-dark);
  box-shadow: inset 0 0 20px rgba(0,0,0,0.5);
  position: relative;
}

/* === LoL Play Button Style === */
.btn-lol {
  background: linear-gradient(to bottom, #1e2328 0%, #111111 100%);
  border: 2px solid var(--gold-dark);
  color: var(--gold-light);
  font-family: var(--font-display);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  padding: 12px 32px;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
  box-shadow: 0 0 10px rgba(0,0,0,0.5);
}

.btn-lol-primary {
  background: linear-gradient(to bottom, #005a82 0%, #00233e 100%);
  border-color: #0ac8b9;
  color: #cdbe91;
}

.btn-lol-primary:hover {
  background: linear-gradient(to bottom, #0076aa 0%, #003a66 100%);
  border-color: #0ef3e2;
  box-shadow: 0 0 20px rgba(10,200,185,0.3);
  color: #f0e6d2;
}

.btn-lol:active {
  transform: scale(0.98);
}

/* === Reveal Animations === */
[data-reveal] {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s var(--ease-out-expo), transform 0.8s var(--ease-out-expo);
}

[data-reveal].revealed {
  opacity: 1;
  transform: translateY(0);
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  z-index: 1;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(ellipse at center bottom, rgba(10,200,185,0.08) 0%, transparent 60%);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 2;
}

.hero-badge {
  font-size: 4rem;
  margin-bottom: 24px;
  display: inline-block;
  animation: float 3s ease-in-out infinite;
}

.hero-title {
  font-family: var(--font-display);
  font-weight: 900;
  line-height: 1.1;
  margin-bottom: 20px;
}

.hero-title .line1 {
  display: block;
  font-size: clamp(2.5rem, 8vw, 5rem);
  color: var(--white);
  margin-bottom: 8px;
}

.hero-title .line2 {
  display: block;
  font-size: clamp(1.8rem, 5vw, 3.5rem);
  background: linear-gradient(135deg, var(--gold-light), var(--gold), var(--gold-dark));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: 1.2rem;
  color: var(--gray);
  font-style: italic;
  margin-bottom: 60px;
  font-weight: 300;
}

.scroll-indicator {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  color: var(--gray);
  font-size: 0.85rem;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.scroll-arrow {
  animation: bounce 2s ease-in-out infinite;
  color: var(--gold);
}

/* ============================================
   STORY SECTION
   ============================================ */
.story {
  z-index: 1;
  padding: 100px 0;
}

.story .container {
  display: flex;
  flex-direction: column;
  gap: 60px;
}

.story-card {
  background: linear-gradient(135deg, var(--bg-card) 0%, rgba(26,26,26,0.8) 100%);
  border: 1px solid rgba(212,175,55,0.12);
  border-radius: 20px;
  padding: 48px 40px;
  text-align: center;
  position: relative;
  overflow: hidden;
  transition: transform 0.4s var(--ease-out-expo), border-color 0.4s ease;
}

.story-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
  opacity: 0;
  transition: opacity 0.4s ease;
}

.story-card:hover {
  transform: translateY(-4px);
  border-color: rgba(212,175,55,0.3);
}

.story-card:hover::before {
  opacity: 1;
}

.story-emoji {
  font-size: 3.5rem;
  margin-bottom: 20px;
  display: inline-block;
}

.story-card h2 {
  font-family: var(--font-display);
  font-size: 1.8rem;
  color: var(--white);
  margin-bottom: 16px;
  font-weight: 700;
}

.story-card p {
  font-size: 1.1rem;
  color: var(--off-white);
  max-width: 500px;
  margin: 0 auto 12px;
  line-height: 1.7;
}

.story-card em {
  color: var(--gold);
  font-style: italic;
}

.story-card strong {
  color: var(--gold-light);
  font-weight: 600;
}

.story-small {
  font-size: 0.9rem !important;
  color: var(--gray) !important;
  font-style: italic;
}

/* ============================================
   QUESTION SECTION
   ============================================ */
.question {
  z-index: 1;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.question::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(212,175,55,0.12) 0%, transparent 70%);
  pointer-events: none;
}

.question-build {
  margin-bottom: 40px;
}

.question-pre {
  font-size: 1.3rem;
  color: var(--off-white);
  font-style: italic;
}

.question-main {
  position: relative;
  z-index: 2;
}

.question-name {
  font-family: var(--font-script);
  font-size: clamp(2rem, 6vw, 3.5rem);
  color: var(--gold-light);
  margin-bottom: 20px;
  opacity: 0.9;
}

.question-text {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 4vw, 2.8rem);
  font-weight: 700;
  line-height: 1.4;
}

.glow-text {
  display: block;
  color: var(--white);
}

.role-text {
  display: block;
  font-size: clamp(2.5rem, 8vw, 5rem);
  font-weight: 900;
  background: linear-gradient(135deg, var(--gold-light) 0%, var(--gold) 50%, var(--champagne) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin: 16px 0;
  text-shadow: none;
  filter: drop-shadow(0 0 30px rgba(212,175,55,0.3));
  animation: glow-pulse 3s ease-in-out infinite;
}

.question-decorations {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  pointer-events: none;
}

.sparkle {
  position: absolute;
  font-size: 1.5rem;
  animation: sparkle-float 4s ease-in-out infinite;
}

.sparkle-1 { top: 10%; left: 10%; animation-delay: 0s; }
.sparkle-2 { top: 20%; right: 15%; animation-delay: 0.8s; }
.sparkle-3 { bottom: 30%; left: 15%; animation-delay: 1.6s; }
.sparkle-4 { top: 15%; right: 25%; animation-delay: 2.4s; }
.sparkle-5 { bottom: 20%; right: 10%; animation-delay: 3.2s; }

/* ============================================
   DRESSCODE SECTION
   ============================================ */
.dresscode {
  z-index: 1;
  padding: 100px 0;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3rem);
  text-align: center;
  color: var(--white);
  margin-bottom: 12px;
}

.section-subtitle {
  text-align: center;
  color: var(--gray);
  font-size: 1.1rem;
  margin-bottom: 60px;
  font-style: italic;
}

.dresscode-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.suit-image-wrapper {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.suit-image {
  max-width: 100%;
  max-height: 500px;
  object-fit: contain;
  border-radius: 16px;
  position: relative;
  z-index: 2;
  filter: drop-shadow(0 20px 40px rgba(0,0,0,0.5));
  background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-primary) 100%);
  padding: 20px;
}

.suit-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 300px;
  height: 400px;
  background: radial-gradient(ellipse, rgba(212,175,55,0.1) 0%, transparent 70%);
  z-index: 1;
}

.dresscode-list {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.dresscode-item {
  display: flex;
  align-items: center;
  gap: 16px;
  background: var(--bg-card);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 16px;
  padding: 20px;
  transition: transform 0.3s var(--ease-out-expo), border-color 0.3s ease, background 0.3s ease;
}

.dresscode-item:hover {
  transform: translateX(6px);
  border-color: rgba(212,175,55,0.25);
  background: var(--bg-card-hover);
}

.dresscode-item.gift:hover {
  border-color: rgba(74, 222, 128, 0.3);
}

.dresscode-icon {
  font-size: 2rem;
  flex-shrink: 0;
  width: 50px;
  text-align: center;
}

.dresscode-info {
  flex: 1;
}

.dresscode-info h3 {
  font-family: var(--font-display);
  font-size: 1.1rem;
  color: var(--white);
  margin-bottom: 4px;
}

.dresscode-info p {
  font-size: 0.9rem;
  color: var(--gray);
}

.dresscode-badge {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 20px;
  white-space: nowrap;
  flex-shrink: 0;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.badge-self {
  background: rgba(212,175,55,0.15);
  color: var(--gold);
  border: 1px solid rgba(212,175,55,0.3);
}

.badge-gift {
  background: rgba(74,222,128,0.12);
  color: var(--success);
  border: 1px solid rgba(74,222,128,0.25);
}

/* ============================================
   RSVP SECTION
   ============================================ */
.rsvp {
  z-index: 1;
  padding: 100px 0;
}

.rsvp .section-title {
  margin-bottom: 48px;
}

.rsvp-form-wrapper {
  max-width: 600px;
  margin: 0 auto;
}

.rsvp-message-field {
  margin-bottom: 32px;
}

.rsvp-message-field label {
  display: block;
  font-size: 1rem;
  color: var(--off-white);
  margin-bottom: 10px;
  font-weight: 500;
}

.rsvp-message-field .optional {
  color: var(--gray);
  font-weight: 300;
  font-size: 0.85rem;
}

.rsvp-message-field textarea {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 12px;
  color: var(--white);
  font-family: var(--font-body);
  font-size: 1rem;
  padding: 16px;
  resize: vertical;
  min-height: 80px;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.rsvp-message-field textarea::placeholder {
  color: var(--gray-dark);
}

.rsvp-message-field textarea:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(212,175,55,0.15);
}

.rsvp-buttons {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.rsvp-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 24px 32px;
  border: 2px solid transparent;
  border-radius: 16px;
  cursor: pointer;
  font-family: var(--font-body);
  transition: all 0.4s var(--ease-out-expo);
  position: relative;
  overflow: hidden;
}

.rsvp-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
  transition: left 0.6s ease;
}

.rsvp-btn:hover::before {
  left: 100%;
}

.btn-emoji {
  font-size: 2rem;
  margin-bottom: 4px;
}

.btn-text {
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: 1px;
}

.btn-subtext {
  font-size: 0.8rem;
  opacity: 0.7;
  font-weight: 300;
}

.btn-yes {
  background: linear-gradient(135deg, rgba(74,222,128,0.15) 0%, rgba(34,197,94,0.25) 100%);
  border-color: rgba(74,222,128,0.4);
  color: var(--success);
}

.btn-yes:hover {
  background: linear-gradient(135deg, rgba(74,222,128,0.25) 0%, rgba(34,197,94,0.4) 100%);
  border-color: var(--success);
  transform: scale(1.03);
  box-shadow: 0 8px 32px rgba(74,222,128,0.2);
}

.btn-no {
  background: rgba(255,255,255,0.03);
  border-color: rgba(255,255,255,0.08);
  color: var(--gray);
}

.btn-no:hover {
  background: rgba(248,113,113,0.08);
  border-color: rgba(248,113,113,0.25);
  color: var(--danger);
  transform: scale(1.01);
}

/* === Guilt Modal === */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(1,10,19,0.92); /* LoL Obsidian backdrop */
  backdrop-filter: blur(12px);
  z-index: 10000;
  display: none; /* Hidden by default */
  align-items: center;
  justify-content: center;
  padding: 20px;
  overflow-y: auto;
  animation: fadeIn 0.3s ease;
}

/* Ensure centering even for tall modals */
@media (max-height: 700px) {
  .modal {
    align-items: flex-start;
    padding-top: 40px;
  }
}

.modal-content {
  background: var(--bg-card);
  border: 2px solid var(--gold-dark);
  border-radius: 4px; /* LoL Client corners are sharp/slightly rounded */
  padding: 40px;
  max-width: 600px; /* Wider for PC feel */
  width: 100%;
  position: relative;
  box-shadow: 0 0 50px rgba(0,0,0,0.8), inset 0 0 20px rgba(0,0,0,0.5);
  animation: scaleIn 0.4s var(--ease-out-back);
}

.modal-emoji {
  font-size: 4rem;
  margin-bottom: 20px;
  display: inline-block;
  animation: shake 0.6s ease-in-out;
}

.modal-content h3 {
  font-family: var(--font-display);
  font-size: 1.6rem;
  color: var(--white);
  margin-bottom: 12px;
}

.modal-content p {
  color: var(--off-white);
  margin-bottom: 8px;
  font-size: 1.05rem;
}

.modal-small {
  font-size: 0.85rem !important;
  color: var(--gray) !important;
  font-style: italic;
  margin-bottom: 24px !important;
}

.modal-buttons {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 28px;
}

.modal-btn {
  padding: 16px 24px;
  border-radius: 12px;
  border: 1px solid transparent;
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  transition: all 0.3s var(--ease-out-expo);
}

.modal-btn-back {
  background: linear-gradient(135deg, rgba(74,222,128,0.2), rgba(34,197,94,0.3));
  border-color: rgba(74,222,128,0.4);
  color: var(--success);
}

.modal-btn-back:hover {
  background: linear-gradient(135deg, rgba(74,222,128,0.3), rgba(34,197,94,0.5));
  transform: scale(1.03);
}

.modal-btn-confirm {
  background: transparent;
  border-color: rgba(255,255,255,0.1);
  color: var(--gray);
}

.modal-btn-confirm:hover {
  border-color: rgba(248,113,113,0.3);
  color: var(--danger);
}

/* === Success State === */
.rsvp-success {
  text-align: center;
  padding: 60px 0;
  animation: fadeIn 0.6s ease;
}

.success-emoji {
  font-size: 5rem;
  display: inline-block;
  animation: celebrateBounce 0.8s var(--ease-out-back);
}

.success-content h3 {
  font-family: var(--font-display);
  font-size: 2.5rem;
  color: var(--gold-light);
  margin: 16px 0;
}

.success-content > p {
  font-size: 1.2rem;
  color: var(--off-white);
  margin-bottom: 32px;
}

.success-details {
  background: var(--bg-card);
  border: 1px solid rgba(212,175,55,0.15);
  border-radius: 16px;
  padding: 32px;
  display: inline-block;
}

.success-details p {
  margin: 8px 0;
  color: var(--off-white);
  font-size: 1.05rem;
}

/* === Already Responded === */
.rsvp-already {
  text-align: center;
  padding: 48px 0;
}

.already-icon {
  font-size: 3rem;
  margin-bottom: 16px;
}

.rsvp-already h3 {
  font-family: var(--font-display);
  font-size: 1.8rem;
  color: var(--white);
  margin-bottom: 12px;
}

.rsvp-already p {
  color: var(--off-white);
  font-size: 1.1rem;
}

/* === No Token State === */
.rsvp-no-token {
  text-align: center;
  padding: 48px 0;
}

.no-token-icon {
  font-size: 3rem;
  margin-bottom: 16px;
}

.rsvp-no-token h3 {
  font-family: var(--font-display);
  font-size: 1.6rem;
  color: var(--white);
  margin-bottom: 12px;
}

.rsvp-no-token p {
  color: var(--off-white);
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
  position: relative;
  z-index: 1;
  padding: 48px 0;
  border-top: 1px solid rgba(212,175,55,0.1);
}

.footer-content {
  text-align: center;
}

.footer-heart {
  font-size: 1rem;
  color: var(--off-white);
  margin-bottom: 8px;
}

.footer-info {
  font-size: 0.85rem;
  color: var(--gray);
}

.footer-copy {
  text-align: center;
  font-size: 0.95rem;
  line-height: 1.4;
}

/* ============================================
   ANIMATIONS
   ============================================ */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
  40% { transform: translateY(10px); }
  60% { transform: translateY(5px); }
}

@keyframes glow-pulse {
  0%, 100% { filter: drop-shadow(0 0 20px rgba(212,175,55,0.2)); }
  50% { filter: drop-shadow(0 0 40px rgba(212,175,55,0.4)); }
}

@keyframes sparkle-float {
  0%, 100% { 
    transform: translateY(0) rotate(0deg) scale(1); 
    opacity: 0.4;
  }
  25% { opacity: 1; }
  50% { 
    transform: translateY(-20px) rotate(180deg) scale(1.3); 
    opacity: 0.6;
  }
  75% { opacity: 1; }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes scaleIn {
  from { 
    opacity: 0; 
    transform: scale(0.85); 
  }
  to { 
    opacity: 1; 
    transform: scale(1); 
  }
}

@keyframes shake {
  0%, 100% { transform: rotate(0); }
  20% { transform: rotate(-10deg); }
  40% { transform: rotate(10deg); }
  60% { transform: rotate(-5deg); }
  80% { transform: rotate(5deg); }
}

@keyframes celebrateBounce {
  0% { transform: scale(0); }
  50% { transform: scale(1.3); }
  70% { transform: scale(0.9); }
  100% { transform: scale(1); }
}

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

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
  .section {
    padding: 60px 0;
    min-height: auto;
  }

  .hero {
    min-height: 100vh;
    min-height: 100dvh;
  }

  .story-card {
    padding: 36px 24px;
  }

  .dresscode-layout {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .suit-image {
    max-height: 350px;
  }

  .dresscode-item {
    flex-wrap: wrap;
    gap: 12px;
  }

  .dresscode-badge {
    width: 100%;
    text-align: center;
  }

  .rsvp-btn {
    padding: 20px 24px;
  }

  .modal-content {
    padding: 36px 24px;
  }

  .question-decorations {
    display: none;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 16px;
  }

  .hero-badge {
    font-size: 3rem;
  }

  .story-emoji {
    font-size: 2.5rem;
  }

  .story-card h2 {
    font-size: 1.4rem;
  }

  .section-title {
    font-size: 1.8rem;
  }

  .dresscode-icon {
    width: 40px;
    font-size: 1.5rem;
  }

  .btn-text {
    font-size: 1rem;
  }
}

/* === Loading State === */
body.loading .section:not(.hero) {
  opacity: 0.3;
  pointer-events: none;
}

/* ============================================
   LOGIN OVERLAY
   ============================================ */
.login-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--bg-primary);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.8s ease, visibility 0.8s ease;
}

.login-overlay.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.login-content {
  background: var(--bg-card);
  border: 1px solid rgba(212,175,55,0.2);
  border-radius: 24px;
  padding: 48px 40px;
  text-align: center;
  max-width: 400px;
  width: 90%;
  box-shadow: 0 20px 40px rgba(0,0,0,0.5);
  transform: translateY(0);
}

.login-icon {
  font-size: 3rem;
  margin-bottom: 16px;
}

.login-content h2 {
  font-family: var(--font-display);
  font-size: 2rem;
  color: var(--gold-light);
  margin-bottom: 8px;
}

.login-content p {
  color: var(--gray);
  margin-bottom: 32px;
}

.pin-inputs {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin-bottom: 16px;
}

.pin-box {
  width: 60px;
  height: 70px;
  background: rgba(255,255,255,0.05);
  border: 2px solid rgba(255,255,255,0.1);
  border-radius: 12px;
  color: var(--white);
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  text-align: center;
  transition: all 0.3s ease;
  /* Hide arrows */
  -moz-appearance: textfield;
  appearance: textfield;
}

.pin-box::-webkit-outer-spin-button,
.pin-box::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.pin-box:focus {
  outline: none;
  border-color: var(--gold);
  background: rgba(212,175,55,0.1);
  box-shadow: 0 0 15px rgba(212,175,55,0.2);
}

.login-error {
  color: var(--danger) !important;
  font-size: 0.9rem;
  margin-bottom: 0 !important;
  animation: shake 0.4s ease-in-out;
}

/* ============================================
   LOBBY SECTION
   ============================================ */
.lobby-section {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: radial-gradient(circle at center, #1a1a24 0%, #050508 100%);
  z-index: 9000;
  display: flex;
  flex-direction: column;
  padding: 40px 20px;
  overflow-y: auto;
}

.lobby-header {
  text-align: center;
  margin-bottom: 40px;
  position: relative;
}

.btn-leave-lobby {
  position: absolute;
  top: 0; left: 0;
  background: rgba(248,113,113,0.1);
  color: var(--danger);
  border: 1px solid rgba(248,113,113,0.3);
  padding: 8px 16px;
  border-radius: 8px;
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 0.8rem;
}

.btn-leave-lobby:hover {
  background: rgba(248,113,113,0.3);
  box-shadow: 0 0 15px rgba(248,113,113,0.4);
}

.btn-clear-chat {
  position: absolute;
  top: 0;
  left: 0;
  transform: none;
  background: rgba(248,113,113,0.12);
  color: #fca5a5;
  border: 1px solid rgba(248,113,113,0.32);
  padding: 8px 16px;
  border-radius: 8px;
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 0.8rem;
}

.btn-clear-chat:hover {
  background: rgba(248,113,113,0.24);
  box-shadow: 0 0 15px rgba(248,113,113,0.28);
}

.lobby-header h2 {
  font-family: var(--font-display);
  font-size: 2.5rem;
  color: var(--gold-light);
  letter-spacing: 4px;
}

.blinking-dot {
  display: inline-block;
  width: 12px; height: 12px;
  background-color: var(--success);
  border-radius: 50%;
  margin-left: 10px;
  box-shadow: 0 0 10px var(--success);
  animation: blink 1.5s infinite;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

.lobby-header p {
  color: var(--gray);
  margin-top: 8px;
}

.lobby-countdown {
  font-family: monospace;
  font-size: 1.2rem;
  color: var(--success);
  margin-top: 5px;
  letter-spacing: 2px;
  text-shadow: 0 0 10px rgba(74,222,128,0.5);
}

.lobby-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  max-width: 750px;
  margin: 10px auto;
  width: 100%;
}

.squad-slot {
  background: rgba(1, 10, 19, 0.6);
  border: 1px solid var(--gold-dark);
  border-radius: 4px;
  overflow: hidden;
  aspect-ratio: 10/13; /* More portrait, less 'square' */
  display: flex;
  flex-direction: column;
  transition: all 0.5s var(--ease-out-expo);
  position: relative;
}

.squad-slot.filled {
  background: linear-gradient(180deg, rgba(200, 170, 110, 0.05) 0%, rgba(9, 20, 40, 0.9) 100%);
  border-color: var(--gold);
  box-shadow: inset 0 0 15px rgba(200, 170, 110, 0.1);
}

.slot-inner {
  padding: 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  flex: 1;
}

.slot-avatar {
  width: 45px; height: 45px;
  border-radius: 50%;
  background: rgba(255,255,255,0.03);
  margin-bottom: 8px;
  border: 1px dashed var(--gold-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
}

.squad-slot.filled .slot-avatar {
  background: rgba(212,175,55,0.2);
  border: 2px solid var(--gold);
  box-shadow: 0 0 20px rgba(212,175,55,0.4);
}

.squad-slot.filled.role-trauzeuge .slot-avatar {
  border-color: #ff3366;
  box-shadow: 0 0 20px rgba(255,51,102,0.4);
}

.slot-name {
  font-family: var(--font-display);
  font-size: 1rem;
  color: var(--gold-light);
  margin-bottom: 2px;
  text-transform: uppercase;
  text-align: center;
}

.squad-slot.filled .slot-name {
  color: var(--white);
  text-shadow: 0 0 10px rgba(255,255,255,0.5);
}

.slot-status {
  font-size: 0.8rem;
  color: var(--gray-dark);
  letter-spacing: 2px;
  animation: pulse-text 2s infinite;
}

.squad-slot.filled .slot-status {
  color: var(--success);
  text-shadow: 0 0 5px var(--success);
  animation: none;
}

@keyframes pulse-text {
  0%, 100% { opacity: 0.5; }
  50% { opacity: 1; }
}

/* === LOBBY CHAT (League of Legends Style) === */
.lobby-chat {
  max-width: 1000px;
  margin: 10px auto 30px;
  width: 100%;
  background: rgba(4, 10, 15, 0.7);
  border: 1px solid rgba(135, 120, 80, 0.3);
  border-radius: 4px; /* LoL blocky style */
  display: flex;
  flex-direction: column;
  height: 450px;
}

.chat-header {
  padding: 8px 16px;
  background: rgba(0,0,0,0.4);
  border-bottom: 1px solid rgba(135, 120, 80, 0.3);
  font-size: 0.8rem;
  font-weight: bold;
  letter-spacing: 1px;
  color: rgba(135, 120, 80, 0.8);
}

.chat-messages {
  flex: 1;
  padding: 10px 16px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 4px; /* Tight lines like LoL */
  font-family: Arial, "Helvetica Neue", Helvetica, sans-serif;
}

/* Custom LoL Scrollbar */
.chat-messages::-webkit-scrollbar { width: 8px; }
.chat-messages::-webkit-scrollbar-track { background: rgba(0,0,0,0.2); }
.chat-messages::-webkit-scrollbar-thumb { background: rgba(135, 120, 80, 0.5); border-radius: 4px; }

.chat-msg {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  font-size: 0.95rem;
  line-height: 1.4;
  word-break: break-word;
}

.chat-sender {
  font-weight: bold;
  color: #f0e6d2; /* LoL yellow/gold */
  margin-right: 6px;
  white-space: nowrap;
}
.chat-sender::after {
  content: ':';
}

.msg-self .chat-sender {
  color: #a3c482; /* Slightly greenish or keep yellow, we use green for self here */
  text-align: left;
}

.chat-bubble {
  color: #ffffff; /* pure white text */
  margin: 0; padding: 0; background: none; max-width: none;
}

.msg-self .chat-bubble {
  background: none;
  align-self: flex-start;
}

/* System Messages Format */
.msg-system {
  color: #ffeb73;
  font-style: italic;
}
.msg-system .chat-sender {
  display: none !important;
}
.msg-system .chat-bubble {
  color: #ffeb73;
}

.chat-input-wrapper {
  display: flex;
  padding: 8px 12px;
  border-top: 1px solid rgba(135, 120, 80, 0.3);
  background: rgba(0,0,0,0.5);
}

.chat-input-wrapper input {
  flex: 1;
  background: transparent;
  border: none;
  color: #ffffff;
  font-family: Arial, sans-serif;
  font-size: 0.95rem;
  padding: 4px 8px;
}

.chat-input-wrapper input:focus {
  outline: none;
}

.chat-input-wrapper button {
  background: transparent;
  color: #f0e6d2;
  border: 1px solid rgba(135, 120, 80, 0.6);
  border-radius: 2px;
  padding: 0 16px;
  font-weight: bold;
  cursor: pointer;
  transition: 0.2s ease;
  font-size: 0.85rem;
}

.chat-input-wrapper button:hover {
  background: rgba(135, 120, 80, 0.15);
}

/* Hide rest of site initially */
body.locked .section {
  display: none !important;
}
body.locked .footer {
  display: none !important;
}

/* === LOGIN MOBILE RESPONSIVENESS === */
@media (max-width: 480px) {
  .login-content {
    padding: 36px 20px;
  }
  
  .login-content h2 {
    font-size: 1.6rem;
  }

  .footer-copy {
    font-size: 0.82rem;
  }

  .footer-copy-extra {
    display: none;
  }

  #btn-yes {
    min-width: 100%;
    min-height: 68px;
    padding: 18px 24px;
    font-size: 1rem;
    letter-spacing: 0.11em;
  }

  #btn-no {
    min-width: 100%;
    min-height: 54px;
    font-size: 0.9rem !important;
  }
  
  .pin-box {
    width: 50px;
    height: 60px;
    font-size: 1.6rem;
  }
  
  .lobby-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }
  
  .lobby-header h2 {
    font-size: 1.8rem;
  }
  
  .btn-leave-lobby {
    position: relative;
    margin-bottom: 16px;
    width: 100%;
    margin-left: 0;
  }

  .btn-clear-chat {
    position: relative;
    left: auto;
    transform: none;
    width: 100%;
    margin-bottom: 10px;
  }
  
  .slot-avatar {
    width: 50px; height: 50px;
    font-size: 1.2rem;
  }
  
  .slot-name {
    font-size: 0.9rem;
  }
  
  .slot-status {
    font-size: 0.6rem;
  }
}

/* ============================================
   SKINS / LOADOUT MODAL
   ============================================ */
.btn-skins {
  position: absolute;
  top: 0; right: 0;
  background: rgba(212,175,55,0.1);
  color: var(--gold);
  border: 1px solid rgba(212,175,55,0.3);
  padding: 8px 16px;
  border-radius: 8px;
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 0.8rem;
}

.btn-skins:hover {
  background: rgba(212,175,55,0.3);
  box-shadow: 0 0 15px rgba(212,175,55,0.4);
}

.btn-primary {
  background: linear-gradient(to bottom, #005a82 0%, #00233e 100%);
  color: #cdbe91;
  border: 1px solid #0ac8b9;
  padding: 18px 48px;
  font-size: 1.1rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.4s var(--ease-out-expo);
  position: relative;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.btn-primary:hover {
  background: linear-gradient(to bottom, #0076aa 0%, #003a66 100%);
  border-color: #0ef3e2;
  color: #f0e6d2;
  box-shadow: 0 15px 40px rgba(10,200,185,0.2);
  transform: translateY(-2px);
}

#btn-yes {
  min-width: min(100%, 420px);
  min-height: 74px;
  padding: 20px 40px;
  border: 1px solid #14d8d0;
  background: linear-gradient(180deg, rgba(11, 118, 155, 0.96) 0%, rgba(2, 59, 92, 0.98) 100%);
  color: #e7cf95;
  letter-spacing: 0.16em;
  box-shadow: 0 0 0 1px rgba(10, 200, 185, 0.18) inset, 0 14px 34px rgba(0, 0, 0, 0.34), 0 0 28px rgba(10, 200, 185, 0.12);
}

#btn-yes:hover {
  background: linear-gradient(180deg, rgba(15, 141, 184, 1) 0%, rgba(4, 76, 118, 1) 100%);
  border-color: #5ef7ef;
  color: #f4e7c2;
  transform: translateY(-3px) scale(1.01);
  box-shadow: 0 0 0 1px rgba(94, 247, 239, 0.24) inset, 0 18px 42px rgba(0, 0, 0, 0.38), 0 0 36px rgba(10, 220, 210, 0.22);
}

.btn-secondary {
  background: linear-gradient(to bottom, #1e2328 0%, #111111 100%);
  color: #a09b8c;
  border: 1px solid #3c3c41;
  padding: 14px 32px;
  font-size: 0.95rem;
  font-weight: 600;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 10px rgba(0,0,0,0.4);
}

.btn-secondary:hover {
  background: linear-gradient(to bottom, #2a2f36 0%, #1a1a1a 100%);
  border-color: #785a28;
  color: #cdbe91;
  box-shadow: 0 0 10px rgba(120, 90, 40, 0.4);
}

#btn-no {
  min-width: min(100%, 360px);
  min-height: 58px;
  padding: 14px 28px;
  background: linear-gradient(180deg, rgba(29, 33, 39, 0.92) 0%, rgba(14, 16, 21, 0.98) 100%) !important;
  color: #b8ae98 !important;
  border: 1px solid rgba(130, 114, 88, 0.4) !important;
  letter-spacing: 0.05em;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.26);
}

#btn-no:hover {
  background: linear-gradient(180deg, rgba(38, 44, 52, 0.96) 0%, rgba(18, 21, 27, 1) 100%) !important;
  color: #d7cab0 !important;
  border-color: rgba(212, 175, 55, 0.45) !important;
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.32);
  transform: translateY(-1px);
}

.skins-modal {
  display: none;
}

.skins-content {
  background: linear-gradient(135deg, #1a1a24 0%, #0a0a0f 100%);
  border: 1px solid var(--gold-dark);
  border-radius: 12px;
  max-width: 800px;
  width: 100%;
  padding: 40px;
  position: relative;
  display: block;
  text-align: left;
  box-shadow: 0 0 40px rgba(212,175,55,0.15);
  margin: 0 auto;
}

.skins-close-btn {
  position: absolute;
  top: 15px; 
  right: 15px;
  background: none;
  border: none;
  color: var(--gray);
  font-size: 1.5rem;
  font-weight: bold;
  cursor: pointer;
  transition: 0.2s ease;
}

.skins-close-btn:hover {
  color: var(--gold);
  transform: scale(1.1);
}

.skins-layout {
  display: flex;
  gap: 40px;
  align-items: center;
}

.skins-preview {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  background: rgba(0,0,0,0.3);
  padding: 20px;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.05);
}

.skins-image {
  max-width: 100%;
  height: auto;
  max-height: 400px; /* Default limit to prevent huge image */
  object-fit: contain;
  filter: drop-shadow(0 0 15px rgba(255,255,255,0.1));
}

.skins-tier {
  margin-top: 20px;
  font-size: 0.9rem;
  color: var(--gray);
  letter-spacing: 1px;
}

.skins-tier span {
  color: #ff8c00; /* Legendary Orange */
  font-weight: bold;
  letter-spacing: 2px;
  text-shadow: 0 0 10px rgba(255,140,0,0.4);
}

.skins-details {
  flex: 1.5;
  display: flex;
  flex-direction: column;
}

.skins-details h2 {
  font-family: var(--font-display);
  font-size: 1.2rem;
  color: var(--gray-dark);
  letter-spacing: 3px;
  margin-bottom: 5px;
}

.skins-details h3 {
  font-family: var(--font-display);
  font-size: 2.2rem;
  color: var(--gold-light);
  line-height: 1.1;
  margin-bottom: 15px;
}

.skins-desc {
  font-size: 0.95rem;
  color: var(--gray);
  line-height: 1.6;
  margin-bottom: 30px;
}

.skins-requirements {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.skins-requirements li {
  background: rgba(255,255,255,0.03);
  padding: 15px;
  border-left: 3px solid var(--gold);
  border-radius: 0 4px 4px 0;
  display: flex;
  flex-direction: column;
}

.skins-requirements li.requirement-self {
  border-left-color: #ef4444;
}

.skins-requirements li.requirement-host {
  border-left-color: #22c55e;
}

.skins-requirements li strong {
  color: var(--white);
  font-size: 1.05rem;
  margin-bottom: 4px;
}

.skins-requirements li span {
  color: var(--gray);
  font-size: 0.85rem;
}

.skins-requirements li span.highlight {
  color: var(--success);
}

/* Mobile Adjustments for Skins Modal */
@media (max-width: 768px) {
  .skins-modal {
    align-items: flex-start;
    justify-content: center;
    overflow-y: auto;
    padding: max(16px, env(safe-area-inset-top)) 16px 16px;
  }

  .skins-layout {
    flex-direction: column;
    gap: 20px;
  }
  .skins-content {
    width: 100%;
    padding: 60px 20px 20px;
    margin-top: 0;
  }
  .skins-close-btn {
    top: 15px;
    right: 15px;
    font-size: 1.8rem; /* Larger touch target */
  }
  .skins-image {
    max-height: 280px;
  }
  .btn-skins {
    position: relative;
    width: 100%;
    margin-bottom: 10px;
  }
  .lobby-header {
    display: flex;
    flex-direction: column;
  }
}

/* === SECONDARY BUTTON (HEX TECH STYLE) === */
.btn-secondary {
  background: linear-gradient(to bottom, #1e2328 0%, #111111 100%) !important;
  color: #a09b8c !important;
  border: 1px solid #3c3c41 !important;
  padding: 14px 32px !important;
  font-size: 0.95rem !important;
  font-weight: 600 !important;
  text-transform: uppercase !important;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 10px rgba(0,0,0,0.4);
}

.btn-secondary:hover {
  background: linear-gradient(to bottom, #2a2f36 0%, #1a1a1a 100%) !important;
  border-color: #785a28 !important;
  color: #cdbe91 !important;
  box-shadow: 0 0 10px rgba(120, 90, 40, 0.4);
}
