/* ==========================================================================
   DECKITCG - PORTAL DE ORGANIZADORES DE TORNEOS POKÉMON TCG
   Vanilla CSS Design System & Components
   ========================================================================== */

:root {
  /* Contemporary Design Tokens (typeui.sh contemporary specification) */
  --primary-contemporary: #c800df;
  --secondary-contemporary: #e60076;
  --contemporary-gradient: linear-gradient(135deg, #c800df 0%, #e60076 100%);
  --contemporary-gradient-hover: linear-gradient(135deg, #d916ef 0%, #f41b86 100%);
  --contemporary-glow: rgba(200, 0, 223, 0.35);
  --contemporary-subtle: rgba(200, 0, 223, 0.12);

  /* Dark Mode Surfaces */
  --primary-dark: #080512;
  --surface-dark: rgba(18, 12, 34, 0.88);
  --surface-hover: rgba(26, 18, 50, 0.95);
  --card-dark: rgba(22, 15, 42, 0.78);
  --card-surface: rgba(28, 19, 54, 0.65);
  --card-border: rgba(200, 0, 223, 0.2);
  --card-border-glow: rgba(200, 0, 223, 0.45);
  --card-border-subtle: rgba(255, 255, 255, 0.08);

  /* Brand Accents & Pokémon Theme Harmony */
  --accent-gold: #ffcb05;
  --accent-gold-hover: #ffd72e;
  --accent-gold-glow: rgba(255, 203, 5, 0.28);
  --accent-gold-subtle: rgba(255, 203, 5, 0.1);

  --accent-blue: #3b82f6;
  --accent-cyan: #06b6d4;
  --accent-green: #16a34a;
  --accent-green-glow: rgba(22, 163, 74, 0.25);
  --accent-red: #dc2626;
  --accent-warning: #d97706;
  --accent-purple: #c800df;
  --accent-orange: #f97316;

  /* Accessible Text Tokens (WCAG 2.2 AA) */
  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;

  /* Contemporary Bento & Density Tokens */
  --sidebar-width: 280px;
  --header-height: 72px;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 24px;
  --radius-full: 9999px;

  /* Transitions & Bento Shadows */
  --transition-fast: 0.15s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-normal: 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  --shadow-card: 0 14px 34px -10px rgba(0, 0, 0, 0.7), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  --shadow-glow: 0 0 28px var(--contemporary-glow);
  --shadow-glow-gold: 0 0 28px var(--accent-gold-glow);
}

/* ==========================================================================
   Reset & Base Typography (Contemporary: Jost & Overpass Mono)
   ========================================================================== */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:focus-visible {
  outline: 2px solid var(--primary-contemporary);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  *, ::before, ::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

html, body {
  min-height: 100vh;
  background-color: var(--primary-dark);
  color: var(--text-primary);
  font-family: 'Jost', -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6, .brand, .btn {
  font-family: 'Jost', sans-serif;
  font-weight: 700;
  letter-spacing: -0.02em;
}

a {
  color: var(--accent-gold);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--secondary-contemporary);
  text-decoration: underline;
}

/* ==========================================================================
   App Layout (Sidebar + Main Content)
   ========================================================================== */
.app-container {
  display: flex;
  min-height: 100vh;
  position: relative;
  background: radial-gradient(circle at 12% 16%, rgba(200, 0, 223, 0.12) 0%, transparent 42%),
              radial-gradient(circle at 88% 84%, rgba(230, 0, 118, 0.08) 0%, transparent 48%),
              radial-gradient(circle at 50% 50%, rgba(255, 203, 5, 0.03) 0%, transparent 60%),
              var(--primary-dark);
}

/* SIDEBAR (Bento Translucent Panel) */
.sidebar {
  width: var(--sidebar-width);
  background: rgba(13, 9, 26, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-right: 1px solid var(--card-border);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  z-index: 100;
  transition: transform var(--transition-normal);
}

.sidebar-header {
  padding: 1.75rem 1.5rem 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.85rem;
  border-bottom: 1px solid rgba(200, 0, 223, 0.14);
}

.sidebar-logo {
  height: 44px;
  width: auto;
  filter: drop-shadow(0 0 12px var(--contemporary-glow));
}

.brand-text-wrap {
  display: flex;
  flex-direction: column;
}

.sidebar-brand-title {
  font-size: 1.45rem;
  font-weight: 800;
  color: #fff;
  line-height: 1.1;
  background: linear-gradient(135deg, #ffffff 40%, var(--accent-gold) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.sidebar-brand-badge {
  font-family: 'Overpass Mono', monospace;
  font-size: 0.68rem;
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--secondary-contemporary);
  background: rgba(230, 0, 118, 0.12);
  border: 1px solid rgba(230, 0, 118, 0.35);
  padding: 0.18rem 0.5rem;
  border-radius: var(--radius-full);
  display: inline-block;
  margin-top: 0.25rem;
  width: fit-content;
}

.sidebar-nav {
  flex: 1;
  padding: 1.5rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  overflow-y: auto;
}

.nav-label {
  font-family: 'Overpass Mono', monospace;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 700;
  color: var(--text-muted);
  padding: 0.5rem 0.75rem 0.25rem;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.85rem 1rem;
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  font-size: 0.95rem;
  font-weight: 600;
  transition: all var(--transition-fast);
  cursor: pointer;
  border: 1px solid transparent;
  user-select: none;
  position: relative;
  background: transparent;
}

.nav-item:hover {
  background: var(--surface-hover);
  color: var(--text-primary);
  border-color: rgba(200, 0, 223, 0.2);
  transform: translateX(2px);
}

.nav-item.active {
  background: linear-gradient(135deg, rgba(200, 0, 223, 0.22) 0%, rgba(230, 0, 118, 0.1) 100%);
  color: #fff;
  border-color: rgba(200, 0, 223, 0.45);
  box-shadow: 0 0 20px var(--contemporary-glow), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.nav-item.active::before {
  content: '';
  position: absolute;
  left: 0;
  top: 25%;
  bottom: 25%;
  width: 3px;
  border-radius: var(--radius-full);
  background: var(--contemporary-gradient);
}

.nav-item .nav-icon {
  font-size: 1.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
}

.sidebar-footer {
  padding: 1.25rem;
  border-top: 1px solid rgba(200, 0, 223, 0.14);
  background: rgba(8, 5, 18, 0.6);
}

.user-profile-widget {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.user-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 2px solid var(--primary-contemporary);
  object-fit: cover;
  background-color: var(--card-dark);
}

.user-avatar-fallback {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 2px solid var(--primary-contemporary);
  background: var(--contemporary-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  color: #fff;
  font-size: 1rem;
}

.user-info {
  flex: 1;
  min-width: 0;
}

.user-name {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.user-email {
  font-family: 'Overpass Mono', monospace;
  font-size: 0.75rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.btn-signout {
  width: 100%;
  padding: 0.65rem;
  min-height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: rgba(220, 38, 38, 0.1);
  border: 1px solid rgba(220, 38, 38, 0.3);
  color: #fca5a5;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn-signout:hover {
  background: rgba(220, 38, 38, 0.22);
  border-color: var(--accent-red);
  color: #fff;
}

/* MAIN CONTENT AREA */
.main-wrapper {
  flex: 1;
  margin-left: var(--sidebar-width);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* TOPBAR */
.topbar {
  height: var(--header-height);
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(200, 0, 223, 0.14);
  background: rgba(14, 9, 28, 0.72);
  backdrop-filter: blur(16px);
  position: sticky;
  top: 0;
  z-index: 50;
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.menu-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 1.5rem;
  cursor: pointer;
}

.topbar-title {
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--text-primary);
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.35rem 0.85rem;
  border-radius: var(--radius-full);
  font-family: 'Overpass Mono', monospace;
  font-size: 0.78rem;
  font-weight: 600;
  background: rgba(22, 163, 74, 0.12);
  border: 1px solid rgba(22, 163, 74, 0.35);
  color: #4ade80;
}

.status-indicator-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--accent-green);
  box-shadow: 0 0 8px var(--accent-green);
}

/* CONTENT VIEW WRAPPER */
.content-area {
  flex: 1;
  padding: clamp(1.25rem, 2vw, 2.25rem) clamp(1rem, 2.5vw, 2.5rem);
  max-width: min(1600px, 98%);
  width: 100%;
  margin: 0 auto;
}

/* ==========================================================================
   VIEWS & SECTIONS
   ========================================================================== */
.view-section {
  display: none;
  animation: fadeIn 0.3s ease forwards;
}

.view-section.active {
  display: block;
}

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

/* ==========================================================================
   LOGIN / LANDING VIEW (UNAUTHENTICATED) - CONTEMPORARY BENTO
   ========================================================================== */
.landing-container {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2.5rem 1.5rem;
  background: 
    radial-gradient(ellipse 80% 50% at 50% -20%, rgba(200, 0, 223, 0.22), transparent 70%),
    radial-gradient(circle 600px at 85% 85%, rgba(230, 0, 118, 0.12), transparent 60%),
    radial-gradient(circle 400px at 15% 75%, rgba(255, 203, 5, 0.05), transparent 50%),
    var(--bg-obsidian);
  position: relative;
  overflow: hidden;
}

.landing-container::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(200, 0, 223, 0.1) 1px, transparent 1px);
  background-size: 32px 32px;
  pointer-events: none;
  opacity: 0.4;
}

.login-card {
  max-width: 480px;
  width: 100%;
  background: rgba(18, 12, 34, 0.85);
  border: 1px solid rgba(200, 0, 223, 0.25);
  border-radius: var(--radius-lg);
  padding: 3.25rem 2.5rem;
  text-align: center;
  box-shadow: 
    0 24px 48px -12px rgba(0, 0, 0, 0.75),
    0 0 40px -10px rgba(200, 0, 223, 0.25),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  position: relative;
  overflow: hidden;
  z-index: 1;
}

.login-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--gradient-contemporary);
}

.login-logo {
  height: 96px;
  width: auto;
  margin-bottom: 1.5rem;
  filter: drop-shadow(0 4px 20px rgba(200, 0, 223, 0.35));
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.login-logo:hover {
  transform: scale(1.05) rotate(-1deg);
}

.login-title {
  font-family: 'Jost', sans-serif;
  font-size: 2.1rem;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.02em;
  margin-bottom: 0.5rem;
}

.login-subtitle {
  font-family: 'Jost', sans-serif;
  color: var(--text-secondary);
  font-size: 0.98rem;
  margin-bottom: 2.25rem;
  line-height: 1.55;
}

.btn-google {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.9rem;
  width: 100%;
  min-height: 48px;
  padding: 0.85rem 1.5rem;
  background: #ffffff;
  color: #0f172a;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-md);
  font-family: 'Jost', sans-serif;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  transition: all var(--transition-fast);
}

.btn-google:hover {
  background: #f8fafc;
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(255, 255, 255, 0.25);
}

.btn-google:active {
  transform: translateY(0);
}

.btn-google svg {
  width: 22px;
  height: 22px;
}

.login-footer-links {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(200, 0, 223, 0.15);
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  font-size: 0.86rem;
  color: var(--text-muted);
}

.login-footer-links a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: color var(--transition-fast);
}

.login-footer-links a:hover {
  color: var(--primary-contemporary);
}

/* ==========================================================================
   FORMS & INPUTS (CREAR TORNEO) - CONTEMPORARY BENTO
   ========================================================================== */
.form-card {
  background: rgba(18, 12, 34, 0.78);
  border: 1px solid rgba(200, 0, 223, 0.18);
  border-radius: var(--radius-lg);
  padding: clamp(1.5rem, 2.5vw, 2.75rem);
  box-shadow: 
    0 16px 40px -10px rgba(0, 0, 0, 0.6),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  position: relative;
  overflow: hidden;
}

.form-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--primary-contemporary), transparent);
}

.form-header {
  margin-bottom: 2rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid rgba(200, 0, 223, 0.14);
}

.form-title {
  font-family: 'Jost', sans-serif;
  font-size: 1.7rem;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.01em;
  margin-bottom: 0.35rem;
}

.form-subtitle {
  font-family: 'Jost', sans-serif;
  color: var(--text-secondary);
  font-size: 0.94rem;
}

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

.form-grid-full {
  grid-column: 1 / -1;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.form-label {
  font-family: 'Jost', sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.form-label .required-star {
  color: var(--accent-red);
}

.form-input, .form-textarea, .form-select {
  width: 100%;
  min-height: 46px;
  background: rgba(26, 17, 48, 0.75);
  border: 1px solid rgba(200, 0, 223, 0.22);
  border-radius: var(--radius-md);
  padding: 0.85rem 1.1rem;
  color: var(--text-primary);
  font-family: 'Jost', sans-serif;
  font-size: 0.96rem;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.2);
  transition: all var(--transition-fast);
}

.form-input:focus, .form-textarea:focus, .form-select:focus {
  outline: none;
  border-color: var(--primary-contemporary);
  box-shadow: 0 0 0 3px rgba(200, 0, 223, 0.25), inset 0 2px 4px rgba(0, 0, 0, 0.2);
  background: rgba(35, 24, 64, 0.9);
}

.form-textarea {
  min-height: 110px;
  resize: vertical;
}

/* FORMAT RADIO PILLS (BO1, BO3, BO5) */
.format-pills {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.85rem;
}

.format-pill {
  position: relative;
}

.format-pill input[type="radio"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.format-pill-label {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 72px;
  padding: 0.9rem 0.6rem;
  background: rgba(26, 17, 48, 0.65);
  border: 1px solid rgba(200, 0, 223, 0.2);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-fast);
  text-align: center;
}

.format-pill-label .format-code {
  font-family: 'Overpass Mono', monospace;
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: 0.02em;
}

.format-pill-label .format-desc {
  font-family: 'Jost', sans-serif;
  font-size: 0.76rem;
  color: var(--text-secondary);
  margin-top: 0.25rem;
}

.format-pill:hover .format-pill-label {
  border-color: rgba(200, 0, 223, 0.45);
  background: rgba(35, 24, 64, 0.75);
}

.format-pill input[type="radio"]:checked + .format-pill-label {
  background: linear-gradient(135deg, rgba(200, 0, 223, 0.22) 0%, rgba(230, 0, 118, 0.12) 100%);
  border-color: var(--primary-contemporary);
  box-shadow: 0 0 20px rgba(200, 0, 223, 0.25);
}

.format-pill input[type="radio"]:checked + .format-pill-label .format-code {
  color: #ffffff;
}

/* INTERACTIVE TOGGLE SWITCH (DECKLIST NECESARIO) */
.toggle-wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.1rem 1.35rem;
  background: rgba(26, 17, 48, 0.65);
  border: 1px solid rgba(200, 0, 223, 0.2);
  border-radius: var(--radius-md);
  min-height: 56px;
}

.toggle-info {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.toggle-title {
  font-family: 'Jost', sans-serif;
  font-weight: 600;
  font-size: 0.98rem;
  color: var(--text-primary);
}

.toggle-hint {
  font-family: 'Jost', sans-serif;
  font-size: 0.82rem;
  color: var(--text-secondary);
}

.switch {
  position: relative;
  display: inline-block;
  width: 58px;
  height: 32px;
  flex-shrink: 0;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(44, 32, 92, 0.8);
  transition: 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  border-radius: 34px;
  border: 1px solid rgba(200, 0, 223, 0.3);
}

.slider:before {
  position: absolute;
  content: "";
  height: 24px;
  width: 24px;
  left: 3px;
  bottom: 3px;
  background-color: #ffffff;
  transition: 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  border-radius: 50%;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
}

input:checked + .slider {
  background: var(--gradient-contemporary);
  border-color: var(--secondary-contemporary);
  box-shadow: 0 0 16px rgba(200, 0, 223, 0.4);
}

input:checked + .slider:before {
  transform: translateX(26px);
  background-color: #ffffff;
}

.toggle-status-text {
  font-family: 'Overpass Mono', monospace;
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--accent-gold);
  margin-left: 0.5rem;
}

/* ==========================================================================
   BUTTONS - CONTEMPORARY
   ========================================================================== */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  min-height: 46px;
  background: var(--gradient-contemporary);
  color: #ffffff;
  border: none;
  border-radius: var(--radius-md);
  padding: 0.85rem 1.85rem;
  font-family: 'Jost', sans-serif;
  font-size: 0.98rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: all var(--transition-fast);
  box-shadow: 0 4px 18px rgba(200, 0, 223, 0.35);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #d316e8 0%, #f01484 100%);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(200, 0, 223, 0.55);
}

.btn-primary:active {
  transform: translateY(0);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  min-height: 46px;
  background: rgba(26, 17, 48, 0.7);
  color: var(--text-primary);
  border: 1px solid rgba(200, 0, 223, 0.28);
  border-radius: var(--radius-md);
  padding: 0.75rem 1.4rem;
  font-family: 'Jost', sans-serif;
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn-secondary:hover {
  border-color: var(--primary-contemporary);
  background: rgba(35, 24, 64, 0.9);
  box-shadow: 0 0 15px rgba(200, 0, 223, 0.2);
  transform: translateY(-1px);
}

/* ==========================================================================
   MIS TORNEOS (TOURNAMENT LISTING) - CONTEMPORARY BENTO
   ========================================================================== */
.metrics-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.25rem;
  margin-bottom: 2.25rem;
}

.metric-card {
  background: rgba(18, 12, 34, 0.78);
  border: 1px solid rgba(200, 0, 223, 0.18);
  border-radius: var(--radius-md);
  padding: 1.35rem 1.6rem;
  display: flex;
  align-items: center;
  gap: 1.25rem;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 
    0 10px 25px -5px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.05);
  transition: transform var(--transition-fast), border-color var(--transition-fast);
}

.metric-card:hover {
  border-color: rgba(200, 0, 223, 0.4);
  transform: translateY(-2px);
}

.metric-icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.55rem;
  background: linear-gradient(135deg, rgba(200, 0, 223, 0.2) 0%, rgba(230, 0, 118, 0.1) 100%);
  border: 1px solid rgba(200, 0, 223, 0.3);
  color: #ffffff;
  flex-shrink: 0;
}

.metric-value {
  font-family: 'Overpass Mono', monospace;
  font-size: 2.1rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.1;
  letter-spacing: -0.03em;
}

.metric-label {
  font-family: 'Jost', sans-serif;
  font-size: 0.85rem;
  color: var(--text-secondary);
  font-weight: 500;
  margin-top: 0.15rem;
}

.tournaments-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 1.5rem;
}

.tournament-card {
  background: rgba(18, 12, 34, 0.78);
  border: 1px solid rgba(200, 0, 223, 0.18);
  border-radius: var(--radius-lg);
  padding: 1.85rem;
  box-shadow: 
    0 12px 30px -8px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  transition: all var(--transition-normal);
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}

.tournament-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: transparent;
  transition: background var(--transition-normal);
}

.tournament-card:hover {
  transform: translateY(-4px);
  border-color: rgba(200, 0, 223, 0.45);
  box-shadow: 
    0 20px 40px -12px rgba(0, 0, 0, 0.7),
    0 0 25px rgba(200, 0, 223, 0.2);
}

.tournament-card:hover::before {
  background: var(--gradient-contemporary);
}

.tournament-badge-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}

.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  font-family: 'Overpass Mono', monospace;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.32rem 0.75rem;
  border-radius: var(--radius-full);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
  box-sizing: border-box;
  line-height: 1.2;
}

.badge-bo {
  background: rgba(200, 0, 223, 0.15);
  color: #f0abfc;
  border: 1px solid rgba(200, 0, 223, 0.35);
}

.badge-decklist-yes {
  background: rgba(22, 163, 74, 0.15);
  color: #4ade80;
  border: 1px solid rgba(22, 163, 74, 0.35);
  text-transform: none;
  font-weight: 600;
}

.badge-decklist-no {
  background: rgba(148, 163, 184, 0.15);
  color: #cbd5e1;
  border: 1px solid rgba(148, 163, 184, 0.35);
  text-transform: none;
}

.badge-decklist-pending {
  background: rgba(217, 119, 6, 0.15);
  color: #fbbf24;
  border: 1px solid rgba(217, 119, 6, 0.35);
  text-transform: none;
}

.decklist-status-cell {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  white-space: nowrap;
}

.badge-decklist-pokemon {
  background: rgba(255, 203, 5, 0.14);
  color: var(--accent-gold);
  border: 1px solid rgba(255, 203, 5, 0.4);
  text-transform: none;
  font-weight: 700;
  font-size: 0.76rem;
  padding: 0.32rem 0.75rem;
}

.badge-team {
  background: rgba(99, 102, 241, 0.2);
  color: #a5b4fc;
  border: 1px solid rgba(99, 102, 241, 0.45);
  font-weight: 700;
}

.badge-individual {
  background: rgba(56, 189, 248, 0.15);
  color: #7dd3fc;
  border: 1px solid rgba(56, 189, 248, 0.35);
  font-weight: 600;
}

.clickable-team {
  cursor: pointer;
  transition: all var(--transition-fast);
}

.clickable-team:hover {
  color: #a5b4fc !important;
  text-decoration: underline;
}

.team-member-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 12px;
  border: 1px solid var(--border-color);
  transition: all var(--transition-fast);
}

.team-member-item:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(99, 102, 241, 0.4);
}

.tournament-card-title {
  font-family: 'Jost', sans-serif;
  font-size: 1.35rem;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 0.85rem;
  letter-spacing: -0.01em;
}

.tournament-meta-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.tournament-meta-item {
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.tournament-progress-wrap {
  margin-top: auto;
  padding-top: 1.1rem;
  border-top: 1px solid rgba(200, 0, 223, 0.14);
}

.progress-labels {
  display: flex;
  justify-content: space-between;
  font-family: 'Overpass Mono', monospace;
  font-size: 0.8rem;
  margin-bottom: 0.4rem;
  color: var(--text-secondary);
}

.progress-bar-bg {
  width: 100%;
  height: 8px;
  background: rgba(26, 17, 48, 0.8);
  border-radius: var(--radius-full);
  overflow: hidden;
  margin-bottom: 1.35rem;
}

.progress-bar-fill {
  height: 100%;
  background: var(--gradient-contemporary);
  border-radius: var(--radius-full);
  transition: width 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* EMPTY STATE */
.empty-state {
  text-align: center;
  padding: 4.5rem 2rem;
  background: rgba(18, 12, 34, 0.6);
  border: 1px dashed rgba(200, 0, 223, 0.3);
  border-radius: var(--radius-lg);
}

.empty-state-icon {
  font-size: 3.5rem;
  margin-bottom: 1rem;
  color: var(--text-muted);
}

.empty-state-title {
  font-family: 'Jost', sans-serif;
  font-size: 1.4rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 0.5rem;
}

.empty-state-desc {
  font-family: 'Jost', sans-serif;
  color: var(--text-secondary);
  font-size: 0.95rem;
  max-width: 440px;
  margin: 0 auto 1.85rem;
}

/* ==========================================================================
   DETALLE DEL TORNEO E INSCRITOS - CONTEMPORARY BENTO
   ========================================================================== */
.detail-banner {
  background: linear-gradient(135deg, rgba(22, 14, 42, 0.95) 0%, rgba(14, 9, 28, 0.98) 100%);
  border: 1px solid rgba(200, 0, 223, 0.22);
  border-radius: var(--radius-lg);
  padding: clamp(1.35rem, 2.2vw, 2.25rem);
  margin-bottom: 1.85rem;
  box-shadow: 
    0 16px 40px -10px rgba(0, 0, 0, 0.6),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.detail-nav-back {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-family: 'Jost', sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--accent-gold);
  margin-bottom: 1.1rem;
  cursor: pointer;
  transition: color var(--transition-fast);
}

.detail-nav-back:hover {
  color: #ffffff;
  text-decoration: underline;
}

.detail-header-content {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.detail-title {
  font-family: 'Jost', sans-serif;
  font-size: clamp(1.5rem, 2.8vw, 2.25rem);
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.02em;
  margin-bottom: 0.5rem;
}

.detail-badges {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 0.85rem;
}

.detail-meta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 1rem 1.25rem;
  margin-top: 1.35rem;
  padding-top: 1.35rem;
  border-top: 1px solid rgba(200, 0, 223, 0.15);
}

.detail-meta-box {
  display: flex;
  flex-direction: column;
  background: rgba(26, 17, 48, 0.55);
  border: 1px solid rgba(200, 0, 223, 0.16);
  border-radius: var(--radius-md);
  padding: 0.85rem 1.1rem;
}

.detail-meta-box span:first-child {
  font-family: 'Jost', sans-serif;
  font-size: 0.74rem;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 700;
  letter-spacing: 0.05em;
  margin-bottom: 0.2rem;
}

.detail-meta-box span:last-child {
  font-family: 'Overpass Mono', monospace;
  font-size: 0.98rem;
  color: #ffffff;
  font-weight: 600;
}

/* PLAYERS TABLE - BENTO CARD */
.players-card {
  background: rgba(18, 12, 34, 0.78);
  border: 1px solid rgba(200, 0, 223, 0.18);
  border-radius: var(--radius-lg);
  padding: clamp(1.25rem, 2vw, 2rem);
  box-shadow: 
    0 16px 40px -10px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.players-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.players-title {
  font-family: 'Jost', sans-serif;
  font-size: 1.45rem;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.01em;
}

.table-responsive {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  scrollbar-color: var(--primary-contemporary) rgba(26, 17, 48, 0.5);
}

.table-responsive::-webkit-scrollbar {
  height: 6px;
}

.table-responsive::-webkit-scrollbar-track {
  background: rgba(18, 12, 34, 0.6);
  border-radius: var(--radius-full);
}

.table-responsive::-webkit-scrollbar-thumb {
  background: var(--primary-contemporary);
  border-radius: var(--radius-full);
}

.table-responsive::-webkit-scrollbar-thumb:hover {
  background: var(--secondary-contemporary);
}

.players-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

.players-table th {
  padding: 0.95rem 1rem;
  background: rgba(26, 17, 48, 0.7);
  font-family: 'Jost', sans-serif;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  border-bottom: 1px solid rgba(200, 0, 223, 0.2);
}

.players-table th:first-child {
  border-top-left-radius: var(--radius-sm);
  width: 50px;
  text-align: center;
}

.players-table td:first-child {
  width: 50px;
  text-align: center;
  font-family: 'Overpass Mono', monospace;
  font-weight: 700;
  color: var(--text-muted);
}

.players-table th:last-child {
  border-top-right-radius: var(--radius-sm);
  text-align: right;
}

.players-table td:last-child {
  text-align: right;
}

.players-table td {
  padding: 0.95rem 1rem;
  border-bottom: 1px solid rgba(200, 0, 223, 0.1);
  font-size: 0.94rem;
  vertical-align: middle;
  color: var(--text-primary);
}

.players-table th:nth-child(2),
.players-table td:nth-child(2) {
  min-width: 160px;
}

.players-table th:nth-child(3),
.players-table td:nth-child(3) {
  min-width: 110px;
}

.players-table th:nth-child(4),
.players-table td:nth-child(4) {
  min-width: 160px;
  max-width: 240px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.players-table th:nth-child(5),
.players-table td:nth-child(5) {
  min-width: 180px;
}

.players-table th:last-child,
.players-table td:last-child {
  min-width: 230px;
}

.decklist-status-cell {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.player-actions-cell {
  display: inline-flex;
  gap: 0.5rem;
  align-items: center;
  justify-content: flex-end;
}

.players-table tr:hover td {
  background: rgba(35, 24, 64, 0.45);
}

.player-user-cell {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.player-table-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
  background: rgba(26, 17, 48, 0.9);
  border: 1px solid rgba(200, 0, 223, 0.25);
}

.player-table-initials {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--gradient-contemporary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Overpass Mono', monospace;
  font-size: 0.85rem;
  font-weight: 700;
  color: #ffffff;
}

.btn-view-deck {
  min-height: 38px;
  padding: 0.45rem 0.85rem;
  font-family: 'Jost', sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, rgba(200, 0, 223, 0.18) 0%, rgba(230, 0, 118, 0.1) 100%);
  border: 1px solid var(--primary-contemporary);
  color: #f0abfc;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
  transition: all var(--transition-fast);
}

.btn-view-deck:hover:not(:disabled) {
  background: var(--gradient-contemporary);
  color: #ffffff;
  box-shadow: 0 0 16px rgba(200, 0, 223, 0.45);
  transform: translateY(-1px);
}

.btn-view-deck:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  border-color: rgba(200, 0, 223, 0.15);
  color: var(--text-muted);
  background: transparent;
}

.btn-view-player {
  min-height: 38px;
  padding: 0.45rem 0.85rem;
  font-family: 'Jost', sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  background: rgba(56, 189, 248, 0.12);
  border: 1px solid rgba(56, 189, 248, 0.4);
  color: #38bdf8;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
  transition: all var(--transition-fast);
}

.btn-view-player:hover {
  background: rgba(56, 189, 248, 0.25);
  color: #ffffff;
  box-shadow: 0 0 16px rgba(56, 189, 248, 0.35);
  transform: translateY(-1px);
}

.btn-edit-player {
  min-height: 38px;
  padding: 0.45rem 0.85rem;
  font-family: 'Jost', sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  background: rgba(99, 102, 241, 0.15);
  border: 1px solid rgba(99, 102, 241, 0.45);
  color: #a5b4fc;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
  transition: all var(--transition-fast);
}

.btn-edit-player:hover {
  background: rgba(99, 102, 241, 0.32);
  color: #ffffff;
  box-shadow: 0 0 16px rgba(99, 102, 241, 0.45);
  transform: translateY(-1px);
}

.badge-pinid {
  background: rgba(255, 204, 0, 0.12);
  color: var(--accent-gold);
  border: 1px solid rgba(255, 204, 0, 0.35);
  font-family: 'Overpass Mono', monospace;
  font-weight: 700;
  letter-spacing: 0.06em;
}

.badge-junior {
  background: rgba(6, 182, 212, 0.18);
  color: #22d3ee;
  border: 1px solid rgba(6, 182, 212, 0.4);
}

.badge-senior {
  background: rgba(34, 197, 94, 0.18);
  color: #4ade80;
  border: 1px solid rgba(34, 197, 94, 0.4);
}

.badge-master {
  background: rgba(250, 204, 21, 0.18);
  color: #facc15;
  border: 1px solid rgba(250, 204, 21, 0.4);
}

.btn-print-deck {
  min-height: 38px;
  padding: 0.45rem 0.85rem;
  font-family: 'Jost', sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  background: rgba(255, 203, 5, 0.12);
  border: 1px solid rgba(255, 203, 5, 0.4);
  color: var(--accent-gold);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
  transition: all var(--transition-fast);
}

.btn-print-deck:hover:not(:disabled) {
  background: var(--accent-gold);
  color: #080512;
  box-shadow: 0 0 16px rgba(255, 203, 5, 0.45);
  transform: translateY(-1px);
}

.btn-print-deck:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  border-color: rgba(200, 0, 223, 0.15);
  color: var(--text-muted);
  background: transparent;
}

.btn-remove-player {
  min-height: 38px;
  min-width: 38px;
  padding: 0.45rem 0.65rem;
  font-size: 0.84rem;
  border-radius: var(--radius-sm);
  background: rgba(220, 38, 38, 0.14);
  border: 1px solid rgba(220, 38, 38, 0.35);
  color: #fca5a5;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
}

.btn-remove-player:hover {
  background: rgba(220, 38, 38, 0.28);
  border-color: var(--accent-red);
  color: #ffffff;
  box-shadow: 0 0 12px rgba(220, 38, 38, 0.35);
}


/* ==========================================================================
   MODAL: DETALLE DE DECKLIST - CONTEMPORARY BENTO
   ========================================================================== */
.modal-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(8, 5, 18, 0.85);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}

#deck-modal-overlay {
  z-index: 1200;
}

.modal-overlay.open {
  display: flex;
  animation: modalFadeIn 0.25s ease;
}

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

.deck-modal {
  background: rgba(18, 12, 34, 0.95);
  border: 1px solid rgba(200, 0, 223, 0.28);
  border-radius: var(--radius-lg);
  max-width: 840px;
  width: 100%;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  box-shadow: 
    0 28px 65px rgba(0, 0, 0, 0.9),
    0 0 40px rgba(200, 0, 223, 0.25);
  position: relative;
  overflow: hidden;
}

.deck-modal::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--gradient-contemporary);
}

.deck-modal-header {
  padding: 1.75rem 2rem;
  border-bottom: 1px solid rgba(200, 0, 223, 0.16);
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  background: linear-gradient(180deg, rgba(26, 17, 48, 0.85) 0%, rgba(18, 12, 34, 0.9) 100%);
}

.deck-headline {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.deck-player-name {
  font-family: 'Jost', sans-serif;
  font-size: 0.88rem;
  color: var(--text-secondary);
}

.deck-pokemon-title {
  font-family: 'Jost', sans-serif;
  font-size: 1.9rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.1;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  letter-spacing: -0.01em;
}

/* POKÉMON TYPE PILL */
.type-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.3rem 0.85rem;
  border-radius: var(--radius-full);
  font-family: 'Overpass Mono', monospace;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* TYPE COLOR THEMES */
.type-dragon { background: rgba(112, 56, 248, 0.2); color: #c4b5fd; border: 1px solid #7c3aed; }
.type-psychic { background: rgba(248, 88, 136, 0.2); color: #f472b6; border: 1px solid #ec4899; }
.type-fire { background: rgba(240, 128, 48, 0.2); color: #fb923c; border: 1px solid #f97316; }
.type-water { background: rgba(104, 144, 240, 0.2); color: #60a5fa; border: 1px solid #3b82f6; }
.type-grass { background: rgba(120, 200, 80, 0.2); color: #4ade80; border: 1px solid #22c55e; }
.type-electric { background: rgba(248, 208, 48, 0.2); color: #facc15; border: 1px solid #eab308; }
.type-darkness { background: rgba(112, 88, 72, 0.25); color: #a8a29e; border: 1px solid #78716c; }
.type-metal { background: rgba(184, 184, 208, 0.2); color: #cbd5e1; border: 1px solid #94a3b8; }
.type-fighting { background: rgba(192, 48, 40, 0.2); color: #f87171; border: 1px solid #ef4444; }
.type-colorless { background: rgba(168, 168, 120, 0.2); color: #e2e8f0; border: 1px solid #94a3b8; }

.deck-modal-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.btn-modal-action-print {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: rgba(255, 203, 5, 0.12);
  border: 1px solid rgba(255, 203, 5, 0.4);
  color: var(--accent-gold);
  font-family: 'Jost', sans-serif;
  font-size: 0.88rem;
  font-weight: 600;
  padding: 0.5rem 1.05rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn-modal-action-print:hover {
  background: var(--accent-gold);
  color: #080512;
  box-shadow: 0 0 16px rgba(255, 203, 5, 0.45);
  transform: translateY(-1px);
}

.modal-close-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 1.85rem;
  line-height: 1;
  cursor: pointer;
  padding: 0.25rem;
  border-radius: var(--radius-sm);
  transition: color var(--transition-fast);
}

.modal-close-btn:hover {
  color: #ffffff;
}

/* STATS SUMMARY IN MODAL */
.deck-stats-bar {
  display: flex;
  background: rgba(26, 17, 48, 0.75);
  padding: 0.95rem 2rem;
  border-bottom: 1px solid rgba(200, 0, 223, 0.15);
  gap: 2rem;
  font-family: 'Jost', sans-serif;
  font-size: 0.88rem;
}

.deck-stat-item strong {
  font-family: 'Overpass Mono', monospace;
  color: var(--accent-gold);
  font-size: 1rem;
}

.deck-cards-body {
  flex: 1;
  overflow-y: auto;
  padding: 1.85rem 2rem;
  display: flex;
  flex-direction: column;
  gap: 1.6rem;
  scrollbar-width: thin;
  scrollbar-color: var(--primary-contemporary) rgba(26, 17, 48, 0.5);
}

.deck-cards-body::-webkit-scrollbar {
  width: 6px;
}

.deck-cards-body::-webkit-scrollbar-thumb {
  background: var(--primary-contemporary);
  border-radius: var(--radius-full);
}

.deck-section-title {
  font-family: 'Jost', sans-serif;
  font-size: 1.15rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 0.85rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(200, 0, 223, 0.14);
  padding-bottom: 0.45rem;
}

.deck-section-count {
  font-family: 'Overpass Mono', monospace;
  font-size: 0.82rem;
  color: var(--accent-gold);
  font-weight: 700;
}

.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 0.85rem;
}

.card-item {
  background: rgba(26, 17, 48, 0.6);
  border: 1px solid rgba(200, 0, 223, 0.16);
  border-radius: var(--radius-sm);
  padding: 0.75rem 0.95rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  transition: all var(--transition-fast);
}

.card-item:hover {
  border-color: var(--primary-contemporary);
  background: rgba(35, 24, 64, 0.8);
  transform: translateY(-1px);
}

.card-left {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.card-name {
  font-family: 'Jost', sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.card-code {
  font-size: 0.76rem;
  color: var(--text-muted);
  font-family: 'Overpass Mono', monospace;
}

.card-qty-badge {
  background: rgba(200, 0, 223, 0.18);
  border: 1px solid rgba(200, 0, 223, 0.4);
  color: #f0abfc;
  font-family: 'Overpass Mono', monospace;
  font-weight: 700;
  font-size: 0.88rem;
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-sm);
  flex-shrink: 0;
}

.deck-modal-footer {
  padding: 1.35rem 2rem;
  border-top: 1px solid rgba(200, 0, 223, 0.16);
  display: flex;
  justify-content: flex-end;
  gap: 1rem;
  background: rgba(26, 17, 48, 0.7);
}

/* ==========================================================================
   TOAST NOTIFICATIONS - CONTEMPORARY
   ========================================================================== */
.toast-container {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 2000;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.toast {
  background: rgba(18, 12, 34, 0.95);
  border: 1px solid rgba(200, 0, 223, 0.25);
  padding: 1rem 1.45rem;
  border-radius: var(--radius-md);
  box-shadow: 
    0 12px 30px rgba(0, 0, 0, 0.75),
    0 0 20px rgba(200, 0, 223, 0.2);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  display: flex;
  align-items: center;
  gap: 0.8rem;
  font-family: 'Jost', sans-serif;
  font-size: 0.94rem;
  color: var(--text-primary);
  animation: toastSlideIn 0.3s ease;
  min-width: 280px;
}

.toast.success {
  border-color: var(--accent-green);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.75), 0 0 20px rgba(22, 163, 74, 0.25);
}

.toast.error {
  border-color: var(--accent-red);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.75), 0 0 20px rgba(220, 38, 38, 0.25);
}

@keyframes toastSlideIn {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

/* ==========================================================================
   RESPONSIVE DESIGN (TABLETS & PHONES)
   ========================================================================== */
@media (max-width: 900px) {
  .sidebar {
    transform: translateX(-100%);
  }

  .sidebar.open {
    transform: translateX(0);
  }

  .main-wrapper {
    margin-left: 0;
  }

  .menu-toggle {
    display: block;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .content-area {
    padding: 1.25rem;
  }

  .topbar {
    padding: 0 1.25rem;
  }

  .login-card {
    padding: 2.25rem 1.5rem;
  }

  .form-card {
    padding: 1.5rem;
  }

  .tournaments-grid {
    grid-template-columns: 1fr;
  }

  .format-pills {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   TOURNAMENT DELETION & ACTIONS - CONTEMPORARY BENTO
   ========================================================================== */
.tournament-card-actions {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  width: 100%;
}

.tournament-card-actions .btn-view-tournament {
  flex: 1;
}

.btn-card-delete {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  min-height: 46px;
  background: rgba(220, 38, 38, 0.12);
  border: 1px solid rgba(220, 38, 38, 0.32);
  color: #fca5a5;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-fast);
  font-size: 1.15rem;
  flex-shrink: 0;
}

.btn-card-delete:hover {
  background: rgba(220, 38, 38, 0.28);
  border-color: var(--accent-red);
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 4px 14px rgba(220, 38, 38, 0.4);
}

.btn-card-delete:active {
  transform: translateY(0);
}

.detail-header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.btn-danger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  min-height: 44px;
  background: rgba(220, 38, 38, 0.14);
  border: 1px solid rgba(220, 38, 38, 0.38);
  color: #fca5a5;
  border-radius: var(--radius-md);
  padding: 0.65rem 1.3rem;
  font-family: 'Jost', sans-serif;
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn-danger:hover {
  background: rgba(220, 38, 38, 0.26);
  border-color: #ef4444;
  color: #ffffff;
  box-shadow: 0 0 16px rgba(220, 38, 38, 0.35);
  transform: translateY(-1px);
}

.btn-danger:active {
  transform: translateY(0);
}

.confirm-modal {
  background: rgba(18, 12, 34, 0.97);
  border: 1px solid rgba(220, 38, 38, 0.35);
  border-radius: var(--radius-lg);
  max-width: 480px;
  width: 100%;
  padding: 2.25rem 2rem;
  box-shadow: 
    0 28px 65px rgba(0, 0, 0, 0.92),
    0 0 40px rgba(220, 38, 38, 0.2);
  position: relative;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  overflow: hidden;
  animation: modalPopIn 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.confirm-modal::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #dc2626, #f97316);
}

@keyframes modalPopIn {
  from {
    opacity: 0;
    transform: scale(0.92) translateY(10px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.confirm-modal-icon {
  font-size: 3.2rem;
  line-height: 1;
  margin-bottom: 0.85rem;
  filter: drop-shadow(0 0 14px rgba(220, 38, 38, 0.45));
}

.confirm-modal-title {
  font-family: 'Jost', sans-serif;
  font-size: 1.5rem;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 0.5rem;
  letter-spacing: -0.01em;
}

.confirm-modal-desc {
  font-family: 'Jost', sans-serif;
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.55;
  margin-bottom: 1.15rem;
}

.highlight-tournament-name {
  color: var(--accent-gold);
  word-break: break-word;
}

.confirm-modal-alert {
  background: rgba(220, 38, 38, 0.12);
  border: 1px solid rgba(220, 38, 38, 0.25);
  border-radius: var(--radius-sm);
  padding: 0.8rem 1rem;
  font-size: 0.84rem;
  color: #fca5a5;
  margin-bottom: 1.6rem;
  text-align: left;
  width: 100%;
  line-height: 1.45;
}

.confirm-modal-actions {
  display: flex;
  gap: 0.85rem;
  width: 100%;
  justify-content: flex-end;
}

.confirm-modal-actions button {
  flex: 1;
}

.btn-danger-solid {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  min-height: 46px;
  background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
  border: 1px solid rgba(239, 68, 68, 0.45);
  color: #ffffff;
  border-radius: var(--radius-md);
  padding: 0.75rem 1.4rem;
  font-family: 'Jost', sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  transition: all var(--transition-fast);
  box-shadow: 0 4px 18px rgba(220, 38, 38, 0.35);
}

.btn-danger-solid:hover {
  background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
  box-shadow: 0 6px 22px rgba(220, 38, 38, 0.55);
  transform: translateY(-1px);
}

.btn-danger-solid:active {
  transform: translateY(0);
}

/* ==========================================================================
   ESTILOS DE PANTALLA PARA LA HOJA DE IMPRESIÓN (OCULTA POR DEFECTO)
   ========================================================================== */
.print-decklist-sheet {
  display: none;
}

/* ==========================================================================
   HOJA DE IMPRESIÓN OFICIAL DE DECKLIST (@media print)
   Formato oficial de torneo Pokémon TCG (blanco y negro, 1 página compacta)
   ========================================================================== */
@media print {
  @page {
    size: letter portrait;
    margin: 8mm 10mm;
  }

  /* Reset para impresión limpia y sin desperdicio de tinta */
  html, body {
    background: #ffffff !important;
    color: #0f172a !important;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif !important;
    font-size: 9pt !important;
    line-height: 1.25 !important;
    margin: 0 !important;
    padding: 0 !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  /* Ocultar toda la interfaz interactiva de la web, todos los modales y overlays */
  body > :not(#print-decklist-sheet):not(script),
  #landing-view,
  #dashboard-view,
  .modal-overlay,
  #team-info-modal-overlay,
  #deck-modal-overlay,
  #player-info-modal-overlay,
  #manual-player-modal-overlay,
  #manual-team-modal-overlay,
  #delete-modal-overlay,
  #finish-tournament-modal-overlay,
  #delete-store-modal-overlay,
  #message-detail-modal-overlay,
  #toggle-user-status-modal-overlay,
  #delete-user-modal-overlay,
  #profile-setup-modal-overlay,
  .confirm-modal,
  .team-info-card,
  .modal-container,
  #toast-container,
  .sidebar,
  .topbar,
  button,
  .btn-primary,
  .btn-secondary {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
  }


  /* Mostrar exclusivamente la hoja oficial de torneo */
  #print-decklist-sheet,
  .print-decklist-sheet {
    display: block !important;
    visibility: visible !important;
    position: static !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    box-sizing: border-box !important;
    background: #ffffff !important;
    color: #0f172a !important;
  }

  .print-page-container {
    width: 100%;
    margin: 0 auto;
    page-break-inside: avoid;
  }

  /* Encabezado Oficial */
  .print-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid #0f172a;
    padding-bottom: 6px;
    margin-bottom: 8px;
  }

  .print-header-brand {
    display: flex;
    flex-direction: column;
    gap: 2px;
  }

  .print-logo-text {
    font-size: 16pt;
    font-weight: 900;
    letter-spacing: -0.5px;
    color: #0f172a;
    display: flex;
    align-items: center;
    gap: 6px;
  }

  .print-sheet-title {
    font-size: 10.5pt;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #334155;
  }

  .print-header-meta {
    text-align: right;
    font-size: 8pt;
    color: #64748b;
    line-height: 1.3;
  }

  /* Ficha de Metadatos del Torneo y Jugador */
  .print-meta-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 5px 14px;
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    padding: 7px 10px;
    margin-bottom: 8px;
    font-size: 8.5pt;
  }

  .print-meta-item {
    display: flex;
    gap: 4px;
  }

  .print-meta-label {
    font-weight: 700;
    color: #334155;
    min-width: 95px;
    flex-shrink: 0;
  }

  .print-meta-val {
    color: #0f172a;
    font-weight: 600;
    word-break: break-word;
  }

  /* Tira de Resumen de Conteo de Cartas */
  .print-stats-strip {
    display: flex;
    justify-content: space-between;
    background: #f1f5f9;
    border: 1px solid #94a3b8;
    border-radius: 4px;
    padding: 4px 12px;
    margin-bottom: 8px;
    font-size: 8.5pt;
    font-weight: 700;
  }

  .print-stat-col {
    color: #0f172a;
  }

  .print-stat-col span {
    color: #0284c7;
  }

  /* Grilla de 3 Columnas para Cartas */
  .print-columns-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 8px;
    margin-bottom: 10px;
    align-items: start;
  }

  .print-category-card {
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    background: #ffffff;
    overflow: hidden;
  }

  .print-category-header {
    background: #e2e8f0;
    padding: 4px 6px;
    font-weight: 800;
    font-size: 8.5pt;
    display: flex;
    justify-content: space-between;
    border-bottom: 1px solid #cbd5e1;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    color: #0f172a;
  }

  .print-cards-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 8pt;
  }

  .print-cards-table th {
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    padding: 2px 4px;
    font-weight: 700;
    font-size: 7pt;
    text-align: left;
    color: #64748b;
  }

  .print-cards-table td {
    padding: 2.5px 4px;
    border-bottom: 1px solid #f1f5f9;
    vertical-align: middle;
  }

  .print-cards-table tr:nth-child(even) {
    background: #fafafa;
  }

  .print-col-qty {
    width: 22px;
    text-align: center;
    font-weight: 800;
    color: #0f172a;
  }

  .print-col-name {
    font-weight: 600;
    color: #1e293b;
    word-break: break-word;
  }

  .print-col-code {
    width: 58px;
    text-align: right;
    font-family: monospace;
    font-size: 7pt;
    color: #64748b;
  }

  .print-empty-msg {
    padding: 6px;
    font-size: 7.5pt;
    font-style: italic;
    color: #94a3b8;
    text-align: center;
  }

  /* Pie de Validación Oficial y Firmas */
  .print-footer-box {
    border: 1px solid #94a3b8;
    border-radius: 4px;
    padding: 6px 10px;
    background: #f8fafc;
    font-size: 8pt;
  }

  .print-verif-row {
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 700;
    color: #0f172a;
    margin-bottom: 8px;
  }

  .print-checkbox-box {
    display: inline-block;
    width: 12px;
    height: 12px;
    border: 1.5px solid #0f172a;
    border-radius: 2px;
    text-align: center;
    line-height: 10px;
    font-size: 8pt;
    font-weight: 900;
  }

  .print-signatures-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-top: 14px;
    margin-bottom: 4px;
  }

  .print-sig-line {
    border-top: 1px solid #475569;
    padding-top: 3px;
    text-align: center;
    font-size: 7.5pt;
    font-weight: 600;
    color: #334155;
  }

  .print-notes-row {
    margin-top: 6px;
    font-size: 7pt;
    color: #64748b;
  }
}

/* ==========================================================================
   14. DASHBOARD ESTADÍSTICAS
   ========================================================================== */
.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.dashboard-stat-card {
  background-color: var(--card-bg);
  border: 1px solid var(--border-dark);
  border-radius: 12px;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.dashboard-stat-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(131, 105, 255, 0.2);
  border-color: rgba(131, 105, 255, 0.4);
}

.dashboard-stat-icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.dashboard-stat-label {
  font-size: 0.95rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.dashboard-stat-value {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--text-primary);
  font-family: 'Outfit', sans-serif;
  letter-spacing: -0.5px;
}

@media (max-width: 900px) {
  .dashboard-charts-grid {
    grid-template-columns: 1fr !important;
  }
}

/* ==========================================================================
   15. GESTIÓN DE RONDAS, ENFRENTAMIENTOS Y STANDINGS (PORTAL WEB TIENDA)
   ========================================================================== */
.tournament-tab-nav {
  display: flex;
  gap: 0.75rem;
  margin: 1.5rem 0 1.25rem;
  border-bottom: 1px solid var(--border-dark);
  padding-bottom: 0.75rem;
  overflow-x: auto;
}

.tournament-tab-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: transparent;
  border: 1px solid transparent;
  padding: 0.65rem 1.2rem;
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.tournament-tab-btn:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.05);
}

.tournament-tab-btn.active {
  color: var(--accent-gold);
  background: rgba(245, 158, 11, 0.12);
  border-color: rgba(245, 158, 11, 0.35);
}

.tab-pill {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-primary);
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 0.75rem;
}

.tab-pill-active {
  background: rgba(16, 185, 129, 0.2);
  color: #10B981;
  border: 1px solid rgba(16, 185, 129, 0.4);
}

.badge-status-open {
  background: rgba(16, 185, 129, 0.15);
  color: #10B981;
  border: 1px solid rgba(16, 185, 129, 0.4);
}

.badge-status-progress {
  background: rgba(245, 158, 11, 0.15);
  color: #F59E0B;
  border: 1px solid rgba(245, 158, 11, 0.4);
}

.badge-status-finished {
  background: rgba(139, 92, 246, 0.15);
  color: #A78BFA;
  border: 1px solid rgba(139, 92, 246, 0.4);
}

.badge-round-info {
  background: rgba(59, 130, 246, 0.15);
  color: #60A5FA;
  border: 1px solid rgba(59, 130, 246, 0.4);
}

.rounds-header-card {
  background: var(--card-bg);
  border: 1px solid var(--border-dark);
  border-radius: var(--radius-md);
  padding: 1rem 1.25rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.rounds-selector-wrap {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.rounds-label {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text-muted);
}

.rounds-pills-container {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.round-pill-btn {
  padding: 0.45rem 0.9rem;
  border-radius: var(--radius-sm);
  background: var(--surface-dark);
  border: 1px solid var(--border-dark);
  color: var(--text-secondary);
  font-weight: 700;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.round-pill-btn:hover {
  color: var(--text-primary);
  border-color: rgba(245, 158, 11, 0.5);
}

.round-pill-btn.active {
  background: var(--accent-gold);
  color: var(--primary-dark);
  border-color: var(--accent-gold);
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.3);
}

.round-status-box {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.active-round-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-primary);
}

.badge-round-active {
  background: rgba(16, 185, 129, 0.2);
  color: #10B981;
  border: 1px solid rgba(16, 185, 129, 0.4);
}

.badge-round-completed {
  background: rgba(107, 114, 128, 0.2);
  color: #9CA3AF;
  border: 1px solid rgba(107, 114, 128, 0.4);
}

.pairing-form-card {
  background: var(--card-bg);
  border: 1px solid var(--border-dark);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  margin-bottom: 1.5rem;
}

.pairing-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.pairing-title {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--accent-gold);
}

.pairing-controls-grid {
  display: grid;
  grid-template-columns: 1fr 1fr auto auto;
  gap: 1rem;
  align-items: flex-end;
}

@media (max-width: 960px) {
  .pairing-controls-grid {
    grid-template-columns: 1fr;
  }
}

.pairing-form-card.bye-mode {
  border-color: rgba(245, 158, 11, 0.6);
  box-shadow: 0 0 20px rgba(245, 158, 11, 0.12);
}

.bye-info-banner {
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.4);
  border-radius: var(--radius-sm);
  padding: 0.75rem 1rem;
  margin-bottom: 1rem;
  animation: fadeIn 0.2s ease-in-out;
}

.bye-info-content {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.88rem;
  color: #FCD34D;
  line-height: 1.4;
}

.bye-info-icon {
  font-size: 1.3rem;
  flex-shrink: 0;
}

.player-2-bye-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(245, 158, 11, 0.15);
  border: 1.5px dashed rgba(245, 158, 11, 0.6);
  border-radius: var(--radius-sm);
  color: #FCD34D;
  font-weight: 700;
  font-size: 0.85rem;
  height: 42px;
  padding: 0 0.75rem;
  letter-spacing: 0.5px;
}

.pairing-btn-wrap {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  align-items: flex-start;
}

.bye-checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.85rem;
  color: var(--accent-gold);
  cursor: pointer;
  font-weight: 600;
  user-select: none;
}

.unassigned-players-box {
  margin-top: 1.25rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border-dark);
}

.unassigned-header {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  margin-bottom: 0.75rem;
}

.unassigned-title {
  font-size: 0.88rem;
  color: var(--text-primary);
  font-weight: 700;
}

.unassigned-tip {
  font-size: 0.78rem;
  color: var(--text-muted);
}

.unassigned-chips {
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.unassigned-player-card {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-dark);
  border-radius: var(--radius-sm);
  padding: 0.4rem 0.6rem 0.4rem 0.75rem;
  transition: all 0.2s ease;
}

.unassigned-player-card:hover {
  border-color: rgba(245, 158, 11, 0.4);
  background: rgba(255, 255, 255, 0.07);
}

.unassigned-player-info {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.unassigned-player-name {
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--text-primary);
}

.unassigned-player-meta {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.unassigned-actions {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.btn-quick-pair,
.btn-quick-bye {
  border: none;
  cursor: pointer;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 8px;
  border-radius: 6px;
  transition: all 0.15s ease;
}

.btn-quick-pair {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-secondary);
}

.btn-quick-pair:hover {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}

.btn-quick-bye {
  background: rgba(245, 158, 11, 0.2);
  color: #FCD34D;
  border: 1px solid rgba(245, 158, 11, 0.4);
}

.btn-quick-bye:hover {
  background: #F59E0B;
  color: #0F172A;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.4);
}

.matches-list-card {
  background: var(--card-bg);
  border: 1px solid var(--border-dark);
  border-radius: var(--radius-md);
  padding: 1.25rem;
}

.matches-list-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.matches-list-title {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--text-primary);
}

.matches-completion-label {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--accent-gold);
  background: rgba(245, 158, 11, 0.12);
  padding: 3px 10px;
  border-radius: 6px;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.matches-container {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.match-card {
  background: var(--surface-dark);
  border: 1px solid var(--border-dark);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
  transition: all 0.2s ease;
}

.match-card.completed {
  border-color: rgba(16, 185, 129, 0.4);
  background: linear-gradient(180deg, rgba(16, 185, 129, 0.04) 0%, var(--surface-dark) 100%);
}

.match-card-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.match-table-tag {
  font-weight: 800;
  font-size: 0.88rem;
  color: var(--info-blue);
  background: rgba(59, 130, 246, 0.15);
  padding: 3px 10px;
  border-radius: 6px;
  border: 1px solid rgba(59, 130, 246, 0.3);
}

.match-players-row,
.match-versus-row {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  width: 100%;
}

.match-player-box {
  flex: 1;
  min-width: 0;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-dark);
  border-radius: 8px;
  padding: 0.5rem 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  transition: all 0.2s ease;
}

.match-player-box.winner {
  background: rgba(16, 185, 129, 0.15);
  border-color: rgba(16, 185, 129, 0.5);
  box-shadow: 0 0 12px rgba(16, 185, 129, 0.2);
}

.match-player-box.loser {
  opacity: 0.6;
}

.match-player-avatar {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  background: var(--surface-dark);
  border: 1px solid var(--border-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.9rem;
  color: var(--accent-gold);
  flex-shrink: 0;
}

.match-player-avatar.bye-avatar {
  background: rgba(245, 158, 11, 0.2);
  border-color: rgba(245, 158, 11, 0.5);
  color: #FCD34D;
}

.match-player-details {
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow: hidden;
  gap: 1px;
}

.match-player-name {
  font-weight: 800;
  font-size: 0.88rem;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.match-player-sub {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.74rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.match-player-pin {
  color: var(--text-secondary);
}

.match-player-deck {
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.match-vs-divider {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  color: var(--accent-gold);
  font-size: 0.8rem;
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.35);
  padding: 3px 8px;
  border-radius: 6px;
  flex-shrink: 0;
}

.match-controls-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px dashed var(--border-dark);
}

.bo1-result-btn-group {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.bo1-btn {
  padding: 0.45rem 0.9rem;
  border-radius: 6px;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  border: 1px solid var(--border-dark);
  background: var(--card-bg);
  color: var(--text-secondary);
  transition: all 0.2s ease;
}

.bo1-btn:hover {
  border-color: var(--accent-gold);
  color: var(--text-primary);
}

.bo1-btn.active-p1,
.bo1-btn.active-p2 {
  background: #10B981;
  color: #fff;
  border-color: #10B981;
  box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3);
}

.bo1-btn.active-tie {
  background: #3B82F6;
  color: #fff;
  border-color: #3B82F6;
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
}

.bo3-games-grid {
  display: flex;
  gap: 0.85rem;
  align-items: center;
  flex-wrap: wrap;
}

.bo3-game-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
}

.bo3-game-label {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-weight: 700;
  text-transform: uppercase;
}

.bo3-game-buttons {
  display: flex;
  gap: 3px;
}

.game-btn {
  padding: 5px 9px;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 800;
  cursor: pointer;
  border: 1px solid var(--border-dark);
  background: var(--card-bg);
  color: var(--text-secondary);
  transition: all 0.15s ease;
}

.game-btn:hover {
  border-color: var(--accent-gold);
  color: var(--text-primary);
}

.game-btn.selected-w {
  background: #10B981;
  color: #fff;
  border-color: #10B981;
}

.game-btn.selected-l {
  background: #EF4444;
  color: #fff;
  border-color: #EF4444;
}

.game-btn.selected-t {
  background: #3B82F6;
  color: #fff;
  border-color: #3B82F6;
}

.game-score-summary {
  font-weight: 800;
  font-size: 0.9rem;
  color: var(--accent-gold);
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.matches-actions-footer {
  display: flex;
  justify-content: flex-end;
  gap: 1rem;
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border-dark);
  flex-wrap: wrap;
}

.standings-table th,
.standings-table td {
  padding: 0.85rem 1rem;
}

.rank-medal {
  font-size: 1.25rem;
  display: inline-block;
  vertical-align: middle;
}

.btn-remove-match {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 0.9rem;
  transition: all 0.15s ease;
}

.btn-remove-match:hover {
  color: var(--accent-red);
  background: rgba(239, 68, 68, 0.15);
}

/* ==========================================================================
   MODAL: INSCRIBIR JUGADOR MANUAL CON RK9
   ========================================================================== */
.manual-player-modal {
  animation: fadeInModal 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@media (max-width: 640px) {
  .manual-player-grid {
    grid-template-columns: 1fr !important;
  }
}

.rk9-counter-valid {
  background: rgba(16, 185, 129, 0.15) !important;
  border-color: rgba(16, 185, 129, 0.4) !important;
  color: #10B981 !important;
}

.rk9-counter-warning {
  background: rgba(245, 158, 11, 0.15) !important;
  border-color: rgba(245, 158, 11, 0.4) !important;
  color: #F59E0B !important;
}

/* ==========================================================================
   ADMIN PANEL STYLES (o.montecinos.vasquez@gmail.com)
   ========================================================================== */
.btn-category-filter {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  padding: 6px 14px;
  border-radius: var(--radius-full);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn-category-filter:hover {
  background: var(--surface-hover);
  color: var(--text-primary);
}

.btn-category-filter.active {
  background: linear-gradient(135deg, rgba(200, 0, 223, 0.25), rgba(230, 0, 118, 0.2));
  border-color: var(--primary-contemporary);
  color: #fff;
  box-shadow: 0 0 12px var(--contemporary-glow);
}

.btn-delete-row {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #ef4444;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-delete-row:hover {
  background: #ef4444;
  color: #fff;
  border-color: #ef4444;
  transform: translateY(-1px);
}

.btn-view-row {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(131, 105, 255, 0.1);
  border: 1px solid rgba(131, 105, 255, 0.3);
  color: #8369ff;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-view-row:hover {
  background: #8369ff;
  color: #fff;
  border-color: #8369ff;
  transform: translateY(-1px);
}

.btn-danger-solid {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: #fff;
  border: none;
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius-md);
  font-weight: 700;
  font-size: 0.92rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: all var(--transition-fast);
}

.btn-danger-solid:hover {
  background: linear-gradient(135deg, #dc2626, #b91c1c);
  box-shadow: 0 4px 14px rgba(239, 68, 68, 0.4);
  transform: translateY(-1px);
}

/* TOPBAR LEGAL LINK & ICON */
.topbar-legal-link {
  font-size: 0.82rem;
  color: var(--text-secondary);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-full);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
  transition: all 0.2s ease;
}

.topbar-legal-link:hover {
  color: var(--accent-gold);
  border-color: rgba(245, 158, 11, 0.4);
  background: rgba(245, 158, 11, 0.1);
  transform: translateY(-1px);
}

.topbar-decki-icon {
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(200, 0, 223, 0.25);
  transition: transform 0.2s ease;
}

.topbar-decki-icon:hover {
  transform: scale(1.08);
}

/* BOTONES DE ACCIÓN DE SOLO ICONO (ADMIN) */
.btn-icon-action {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  background: rgba(255, 255, 255, 0.05);
}

.btn-icon-action:hover {
  transform: scale(1.08);
}

.btn-icon-action.btn-toggle-disable {
  color: #f59e0b;
  background: rgba(245, 158, 11, 0.12);
  border-color: rgba(245, 158, 11, 0.3);
}

.btn-icon-action.btn-toggle-disable:hover {
  background: rgba(245, 158, 11, 0.22);
  border-color: rgba(245, 158, 11, 0.6);
}

.btn-icon-action.btn-toggle-enable {
  color: #10b981;
  background: rgba(16, 185, 129, 0.12);
  border-color: rgba(16, 185, 129, 0.3);
}

.btn-icon-action.btn-toggle-enable:hover {
  background: rgba(16, 185, 129, 0.22);
  border-color: rgba(16, 185, 129, 0.6);
}

.btn-icon-action.btn-delete-icon {
  color: #ef4444;
  background: rgba(239, 68, 68, 0.12);
  border-color: rgba(239, 68, 68, 0.3);
}

.btn-icon-action.btn-delete-icon:hover {
  background: rgba(239, 68, 68, 0.22);
  border-color: rgba(239, 68, 68, 0.6);
}

/* BADGES DE TIPO DE CUENTA Y ESTADO DE USUARIO */
.badge-freemium {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-secondary);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.badge-premium {
  background: rgba(245, 158, 11, 0.18);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.45);
  font-weight: 700;
}

.badge-user-active {
  background: rgba(16, 185, 129, 0.14);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.35);
}

.badge-user-disabled {
  background: rgba(239, 68, 68, 0.14);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.35);
}

/* ==========================================================================
   ESTILOS TORNEOS 3v3 POR EQUIPOS
   ========================================================================== */
.badge-team {
  background: rgba(99, 102, 241, 0.2) !important;
  color: #a5b4fc !important;
  border: 1px solid rgba(99, 102, 241, 0.45) !important;
  font-weight: 700;
}

.badge-individual {
  background: rgba(59, 130, 246, 0.18) !important;
  color: #93c5fd !important;
  border: 1px solid rgba(59, 130, 246, 0.4) !important;
}

.clickable-team {
  cursor: pointer;
  transition: transform 0.18s ease, filter 0.18s ease, color 0.18s ease;
}

.clickable-team:hover {
  transform: translateX(3px);
  filter: brightness(1.2);
}

.clickable-team:hover strong {
  text-decoration: underline;
  color: #c7d2fe !important;
}

.team-member-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  transition: background-color 0.2s, border-color 0.2s;
}

.team-member-item:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(99, 102, 241, 0.4);
}

/* ==========================================================================
   CONTROL DE ACCESO Y SOLICITUDES DE TIENDAS (ADMIN & PENDING VIEW)
   ========================================================================== */
.pending-approval-card {
  background: rgba(22, 15, 42, 0.92);
  border: 1px solid rgba(200, 0, 223, 0.35);
  border-radius: var(--radius-xl);
  padding: clamp(2rem, 3.5vw, 3rem);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8), 0 0 35px rgba(200, 0, 223, 0.18);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  width: 92%;
  max-width: 580px;
  margin: auto;
  text-align: center;
}

.btn-access-approve {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: #ffffff;
  border: none;
  padding: 0.45rem 0.95rem;
  font-size: 0.84rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all var(--transition-fast);
  box-shadow: 0 2px 8px rgba(16, 185, 129, 0.25);
}

.btn-access-approve:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.45);
  filter: brightness(1.1);
}

.btn-access-reject {
  background: rgba(239, 68, 68, 0.12);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.35);
  padding: 0.45rem 0.95rem;
  font-size: 0.84rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all var(--transition-fast);
}

.btn-access-reject:hover {
  background: rgba(239, 68, 68, 0.28);
  border-color: #ef4444;
  color: #ffffff;
  transform: translateY(-1px);
}

.btn-access-revoke {
  background: rgba(239, 68, 68, 0.1);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.35);
  padding: 0.4rem 0.85rem;
  font-size: 0.82rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: all var(--transition-fast);
}

.btn-access-revoke:hover {
  background: rgba(239, 68, 68, 0.25);
  border-color: #ef4444;
  color: #ffffff;
  transform: translateY(-1px);
}

.btn-access-grant {
  background: rgba(16, 185, 129, 0.12);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.38);
  padding: 0.4rem 0.85rem;
  font-size: 0.82rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: all var(--transition-fast);
}

.btn-access-grant:hover {
  background: rgba(16, 185, 129, 0.25);
  border-color: #10b981;
  color: #ffffff;
  transform: translateY(-1px);
}

@keyframes pulseGlow {
  0%, 100% {
    transform: scale(1);
    opacity: 0.9;
  }
  50% {
    transform: scale(1.18);
    opacity: 0.45;
  }
}

.pulse-indicator {
  animation: pulseGlow 1.8s infinite ease-in-out;
}

/* ==========================================================================
   3V3 BOARDS ALIGNMENT STYLING (MATCH CARD & PREVIEWS)
   ========================================================================== */
.boards-alignment-wrapper {
  margin-top: 0.85rem;
  padding: 0.85rem 1rem;
  background: rgba(15, 23, 42, 0.65);
  border-radius: var(--radius-md);
  border: 1px solid rgba(99, 102, 241, 0.22);
}

.boards-alignment-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.75rem;
  padding-bottom: 0.4rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.boards-alignment-title {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.74rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: #a5b4fc;
}

.boards-alignment-table-tag {
  font-size: 0.7rem;
  color: var(--text-muted);
  font-weight: 600;
}

.boards-alignment-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
}

@media (max-width: 920px) {
  .boards-alignment-grid {
    grid-template-columns: 1fr;
  }
}

.board-duel-card {
  background: rgba(30, 41, 59, 0.45);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  transition: all var(--transition-fast);
}

.board-duel-card:hover {
  background: rgba(30, 41, 59, 0.75);
  border-color: rgba(99, 102, 241, 0.4);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
}

.board-duel-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2px;
}

.board-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 2px 8px;
  border-radius: 6px;
  background: rgba(99, 102, 241, 0.22);
  color: #c7d2fe;
  border: 1px solid rgba(99, 102, 241, 0.4);
}

.board-contestant-box {
  background: rgba(15, 23, 42, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 7px;
  padding: 0.45rem 0.6rem;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.board-contestant-box.is-bye {
  background: rgba(245, 158, 11, 0.1);
  border-color: rgba(245, 158, 11, 0.25);
}

.board-player-line {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.board-player-icon {
  font-size: 0.8rem;
  flex-shrink: 0;
  opacity: 0.85;
}

.board-player-name {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1;
}

.board-meta-line {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.69rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  padding-left: 1.15rem;
}

.board-deck-tag {
  color: #cbd5e1;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.board-popid-tag {
  color: var(--info-blue);
  font-weight: 600;
}

.board-vs-divider-row {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  margin: 1px 0;
  gap: 8px;
}

.board-vs-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.12), transparent);
}

.board-vs-badge {
  font-size: 0.64rem;
  font-weight: 900;
  color: var(--accent-gold);
  background: rgba(245, 158, 11, 0.14);
  border: 1px solid rgba(245, 158, 11, 0.35);
  padding: 1px 7px;
  border-radius: 10px;
  letter-spacing: 0.6px;
  flex-shrink: 0;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
}

/* ==========================================================================
   19. BÚSQUEDA Y PREVISUALIZACIÓN DE DECKS EN LA WEB (LIMITLESS TCG / RK9)
   ========================================================================== */

.web-deck-filter-chip {
  padding: 6px 14px;
  font-size: 0.8rem;
  font-weight: 600;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.web-deck-filter-chip:hover {
  background: rgba(245, 158, 11, 0.12);
  border-color: rgba(245, 158, 11, 0.4);
  color: var(--accent-gold);
}

.web-deck-filter-chip.active {
  background: var(--accent-gold);
  color: #000;
  font-weight: 700;
  border-color: var(--accent-gold);
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.3);
}

.web-deck-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: 14px;
  padding: 1rem 1.25rem;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.web-deck-card:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(245, 158, 11, 0.5);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}

.web-deck-card.is-champion {
  border-left: 4px solid var(--accent-gold);
}

.web-deck-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.web-deck-name {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0;
  font-family: 'Outfit', sans-serif;
}

.web-deck-meta-info {
  font-size: 0.8rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.web-deck-breakdown-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 0.4rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.web-deck-mini-pill {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
}

.web-category-section {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 0.85rem 1rem;
}

.web-category-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.6rem;
  padding-bottom: 0.4rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.web-category-title {
  font-size: 0.88rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
}

.web-category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 8px;
}

.web-card-row {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.03);
  padding: 6px 10px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  font-size: 0.82rem;
}

.web-card-row:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(99, 102, 241, 0.3);
}

.web-card-qty {
  font-weight: 800;
  font-size: 0.8rem;
  padding: 2px 6px;
  border-radius: 5px;
  min-width: 26px;
  text-align: center;
}

.web-card-name {
  font-weight: 600;
  color: var(--text-primary);
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.web-card-code {
  font-size: 0.72rem;
  font-family: 'Overpass Mono', monospace;
  color: var(--text-muted);
}

/* ==========================================================================
   PANEL ADMIN: GESTIÓN DE MEMBRESÍAS PREMIUM (BETA TESTERS)
   ========================================================================== */
.btn-duration-pill,
.btn-modal-duration-pill {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 1rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-family: 'Jost', sans-serif;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn-duration-pill small,
.btn-modal-duration-pill small {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-weight: 400;
  margin-top: 2px;
}

.btn-duration-pill:hover,
.btn-modal-duration-pill:hover {
  background: rgba(245, 158, 11, 0.15);
  border-color: rgba(245, 158, 11, 0.4);
  color: #fbbf24;
}

.btn-duration-pill.active,
.btn-modal-duration-pill.active {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.25), rgba(217, 119, 6, 0.25));
  border-color: #f59e0b;
  color: #fbbf24;
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.3);
}

.btn-duration-pill.active small,
.btn-modal-duration-pill.active small {
  color: #fde68a;
  font-weight: 500;
}

.btn-premium-icon {
  background: rgba(245, 158, 11, 0.15) !important;
  border-color: rgba(245, 158, 11, 0.35) !important;
  color: #fbbf24 !important;
}

.btn-premium-icon:hover {
  background: rgba(245, 158, 11, 0.3) !important;
  border-color: #f59e0b !important;
  box-shadow: 0 0 8px rgba(245, 158, 11, 0.4) !important;
}

.badge-premium {
  background: rgba(245, 158, 11, 0.2) !important;
  border: 1px solid #f59e0b !important;
  color: #fbbf24 !important;
  font-weight: 700;
}

.badge-freemium {
  background: rgba(148, 163, 184, 0.15) !important;
  border: 1px solid rgba(148, 163, 184, 0.3) !important;
  color: #cbd5e1 !important;
}





