:root {
  --brand-primary: #ff7b00;
  --brand-secondary: #ffd43b;
  --brand-accent: #79ffb2;
  --pitch-900: #062c1d;
  --pitch-800: #0d4f34;
  --pitch-700: #137046;
  --pitch-600: #159154;
  --grass-line: rgba(173, 255, 199, 0.12);
  --ink: #edfff3;
  --muted: #c7e8d0;
  --accent: #ffd43b;
  --accent-2: #ff7b00;
  --line: rgba(255, 255, 255, 0.16);
  --card: rgba(3, 32, 19, 0.58);
  --shadow: 0 28px 60px rgba(0, 0, 0, 0.38);
  --success: #79ffb2;
  --warning: #ffe08a;
  --danger: #ff9c9c;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Manrope", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 12% 4%, rgba(255, 212, 59, 0.08), transparent 24%),
    repeating-linear-gradient(
      90deg,
      rgba(255, 255, 255, 0.02) 0,
      rgba(255, 255, 255, 0.02) 70px,
      rgba(0, 0, 0, 0.04) 70px,
      rgba(0, 0, 0, 0.04) 140px
    ),
    linear-gradient(180deg, var(--pitch-700) 0%, var(--pitch-900) 86%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    radial-gradient(circle at 80% 12%, rgba(255, 123, 0, 0.18), transparent 30%),
    linear-gradient(
      180deg,
      transparent 0,
      transparent 8%,
      var(--grass-line) 8%,
      var(--grass-line) 9%,
      transparent 9%,
      transparent 91%,
      var(--grass-line) 91%,
      var(--grass-line) 92%,
      transparent 92%
    );
  pointer-events: none;
}

a {
  color: inherit;
  text-decoration: none;
}

main {
  padding: 0 24px 48px;
}

.site-header,
.hero,
.page-head,
.section-grid,
.section-block,
.dashboard-grid,
.flash-stack {
  max-width: 1180px;
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 24px;
  backdrop-filter: blur(12px);
  background: linear-gradient(180deg, rgba(1, 28, 17, 0.82), rgba(1, 28, 17, 0.48));
  border-bottom: 1px solid var(--line);
}

.brand {
  font-family: "Sora", sans-serif;
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.04em;
}

.brand span,
.eyebrow,
.stat {
  color: var(--accent);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 12px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 18px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--brand-primary), var(--brand-secondary));
  color: #112214;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 12px 30px rgba(255, 123, 0, 0.3);
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.button:hover {
  transform: translateY(-1px);
  box-shadow: 0 18px 36px rgba(255, 123, 0, 0.36);
}

.button.ghost {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--line);
  box-shadow: none;
}

.hero,
.dashboard-grid,
.section-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.hero {
  padding: 36px 24px 24px;
  align-items: center;
}

.hero-copy h1,
.page-head h1 {
  margin: 0;
  font-family: "Sora", sans-serif;
  font-size: clamp(2.7rem, 6vw, 5.3rem);
  line-height: 0.95;
  letter-spacing: -0.06em;
  text-shadow: 0 6px 22px rgba(0, 0, 0, 0.35);
}

.lead {
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--muted);
  max-width: 680px;
}

.cta-row,
.hero-points,
.stack-list,
.winner-list {
  display: flex;
  gap: 12px;
}

.cta-row,
.winner-list {
  flex-wrap: wrap;
}

.hero-points,
.stack-list {
  flex-direction: column;
  padding: 0;
  margin: 24px 0 0;
  list-style: none;
}

.card {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--card);
  backdrop-filter: blur(8px);
  box-shadow: var(--shadow);
}

.glass {
  background:
    radial-gradient(circle at top right, rgba(255, 212, 59, 0.14), transparent 45%),
    var(--card);
}

.panel-title,
.section-header h2,
.form-card h2,
.standings-card h2,
.schedule-card h2 {
  margin: 0;
  font-family: "Sora", sans-serif;
  letter-spacing: -0.04em;
}

.steps {
  margin: 16px 0 0;
  padding-left: 20px;
  color: var(--muted);
  line-height: 1.7;
}

.section-grid,
.section-block,
.page-head,
.dashboard-grid {
  padding: 24px;
}

.page-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
}

.section-block {
  display: grid;
  gap: 18px;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 16px;
}

.section-header.compact {
  margin-bottom: 16px;
}

.eyebrow {
  margin: 0 0 8px;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.accent-card {
  background:
    radial-gradient(circle at top left, rgba(255, 212, 59, 0.16), transparent 35%),
    linear-gradient(135deg, #032012 0%, #0a4e31 100%);
  color: white;
}

.accent-card p {
  color: rgba(255, 255, 255, 0.78);
}

.stats-card {
  display: grid;
  gap: 18px;
  align-content: center;
}

.stat {
  display: block;
  font-family: "Sora", sans-serif;
  font-size: 2rem;
  font-weight: 700;
}

.match-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.fixture-card span,
.result-card span,
.admin-match-title span,
.match-row p,
.prize-row p,
.prize-inline-row p,
.prize-inline-row small,
.locked-box p {
  color: var(--muted);
}

.table-wrap {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  padding: 14px 12px;
  text-align: left;
  border-bottom: 1px solid var(--line);
}

th {
  color: var(--muted);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.is-me {
  background: rgba(255, 212, 59, 0.12);
}

.match-row,
.prize-row,
.prize-inline-row,
.admin-match-block {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}

.match-row strong,
.prize-row strong,
.prize-inline-row strong,
.winner-chip,
.locked-box strong {
  color: #ffffff;
}

.admin-match-block {
  flex-direction: column;
  align-items: stretch;
}

.admin-match-title,
.score-form,
.prediction-form,
.prediction-form.wide {
  display: grid;
  gap: 14px;
}

.prediction-form {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.prediction-form.wide,
.score-form {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.prediction-form label,
.prediction-form select,
.prediction-form input,
.score-form input {
  width: 100%;
}

label {
  display: grid;
  gap: 8px;
  font-weight: 700;
}

input,
select {
  min-height: 46px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  font: inherit;
}

select option {
  color: #0d1f15;
}

.locked-box,
.winners-box {
  display: grid;
  gap: 12px;
}

.winner-chip {
  display: inline-flex;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(255, 123, 0, 0.2);
  border: 1px solid rgba(255, 212, 59, 0.45);
  font-weight: 700;
}

.flash-stack {
  display: grid;
  gap: 10px;
  padding: 0 24px 6px;
}

.flash {
  padding: 14px 18px;
  border-radius: 16px;
  font-weight: 700;
  border: 1px solid var(--line);
}

.flash-success {
  background: rgba(121, 255, 178, 0.15);
  color: var(--success);
}

.flash-warning {
  background: rgba(255, 224, 138, 0.15);
  color: var(--warning);
}

.flash-danger {
  background: rgba(255, 156, 156, 0.15);
  color: var(--danger);
}

.avatar-control-card {
  display: grid;
  gap: 14px;
}

.avatar-current {
  display: flex;
  gap: 16px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
}

.avatar-current .avatar-ball {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 999px;
  font-size: 1.8rem;
  background: rgba(255, 212, 59, 0.22);
  border: 1px solid rgba(255, 212, 59, 0.5);
}

.avatar-current p {
  margin: 0;
  color: var(--muted);
}

.avatar-picker {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.avatar-option {
  display: grid;
  gap: 5px;
  justify-items: center;
  min-height: 88px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
  color: var(--ink);
  cursor: pointer;
  padding: 8px;
}

.avatar-option span {
  font-size: 1.55rem;
}

.avatar-option small {
  color: var(--muted);
}

.avatar-option.is-active {
  border-color: rgba(255, 212, 59, 0.65);
  background: rgba(255, 212, 59, 0.14);
}

.pitch-card {
  overflow: hidden;
}

.league-pitch {
  position: relative;
  min-height: 620px;
  border-radius: 20px;
  border: 1px solid rgba(173, 255, 199, 0.3);
  background:
    radial-gradient(circle at center, rgba(255, 255, 255, 0.1), transparent 42%),
    repeating-linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.04) 0,
      rgba(255, 255, 255, 0.04) 42px,
      rgba(0, 0, 0, 0.06) 42px,
      rgba(0, 0, 0, 0.06) 84px
    ),
    linear-gradient(180deg, #0f7f48, #0a6138);
}

.league-pitch .center-line {
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  height: 1px;
  background: rgba(255, 255, 255, 0.52);
}

.league-pitch .center-circle {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 120px;
  height: 120px;
  transform: translate(-50%, -50%);
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.6);
}

.league-pitch .goal-box {
  position: absolute;
  left: 50%;
  width: 260px;
  height: 90px;
  transform: translateX(-50%);
  border: 1px solid rgba(255, 255, 255, 0.55);
}

.league-pitch .goal-box.top {
  top: 0;
  border-top: 0;
}

.league-pitch .goal-box.bottom {
  bottom: 0;
  border-bottom: 0;
}

.pitch-player {
  position: absolute;
  transform: translate(-50%, -50%);
  width: 66px;
  height: 66px;
  border-radius: 999px;
  background: rgba(2, 25, 15, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.45);
  display: grid;
  place-items: center;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.35);
}

.pitch-player .avatar {
  font-size: 1.55rem;
}

.pitch-player small {
  position: absolute;
  bottom: -18px;
  background: rgba(2, 25, 15, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  padding: 1px 8px;
  font-size: 0.68rem;
  color: var(--muted);
}

.pitch-player.is-me {
  border-color: rgba(255, 212, 59, 0.9);
  box-shadow: 0 0 0 3px rgba(255, 212, 59, 0.2), 0 10px 24px rgba(0, 0, 0, 0.35);
}

.admin-kpi-grid {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px 24px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.kpi-card {
  display: grid;
  gap: 8px;
  border-left: 3px solid rgba(255, 212, 59, 0.55);
}

.kpi-card span {
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.72rem;
  font-weight: 700;
}

.kpi-card strong {
  font-family: "Sora", sans-serif;
  font-size: clamp(1.5rem, 2.6vw, 2.2rem);
}

.kpi-card small {
  color: var(--muted);
}

.admin-scroll {
  max-height: 920px;
  overflow-y: auto;
  padding-right: 6px;
}

.admin-scroll::-webkit-scrollbar {
  width: 8px;
}

.admin-scroll::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.18);
  border-radius: 999px;
}

.role-form {
  display: flex;
  gap: 8px;
  align-items: center;
}

.role-form select {
  min-height: 38px;
  min-width: 110px;
}

@media (max-width: 980px) {
  .admin-kpi-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 980px) {
  .hero,
  .dashboard-grid,
  .section-grid,
  .match-grid,
  .prediction-form,
  .prediction-form.wide,
  .score-form,
  .avatar-picker {
    grid-template-columns: 1fr;
  }

  .page-head,
  .site-header,
  .site-nav,
  .match-row,
  .prize-row,
  .prize-inline-row {
    display: grid;
  }

  .hero-copy h1,
  .page-head h1 {
    font-size: clamp(2.2rem, 12vw, 3.5rem);
  }

  .league-pitch {
    min-height: 760px;
  }

  .pitch-player {
    width: 58px;
    height: 58px;
  }
}

@media (max-width: 560px) {
  .admin-kpi-grid {
    grid-template-columns: 1fr;
  }

  .role-form {
    flex-direction: column;
    align-items: stretch;
  }
}
/* === Mundialito SaaS additions === */

/* ===== Mundialito SaaS multi-tenant additions ===== */
.brand { display: inline-flex; align-items: center; gap: 10px; }
.brand-logo { width: 28px; height: 28px; object-fit: contain; border-radius: 6px; background: rgba(255,255,255,0.08); padding: 2px; }
.brand-ball { display: inline-block; animation: brandBall 3.5s ease-in-out infinite; }
@keyframes brandBall { 0%,100% { transform: translateY(0) rotate(0deg); } 50% { transform: translateY(-3px) rotate(18deg); } }

.tenant-chip {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 12px; border-radius: 999px;
  background: rgba(255,255,255,0.06); border: 1px solid var(--line);
  font-size: 0.78rem; font-weight: 700; letter-spacing: 0.04em;
}
.tenant-chip .dot { width: 10px; height: 10px; border-radius: 50%; box-shadow: 0 0 12px var(--brand-primary); }

.tenant-grid {
  display: grid; gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}
.tenant-card {
  position: relative; overflow: hidden; display: grid; gap: 12px;
  border-top: 4px solid var(--card-accent, var(--brand-primary));
  transition: transform 220ms ease, box-shadow 220ms ease;
}
.tenant-card.lift:hover { transform: translateY(-4px); box-shadow: 0 26px 50px rgba(0,0,0,0.45); }
.tenant-pill {
  display: inline-block; padding: 4px 10px; border-radius: 999px;
  background: var(--card-accent, var(--brand-primary)); color: #0e2014;
  font-size: 0.7rem; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase;
  width: fit-content;
}
.tenant-tagline { color: var(--muted); min-height: 1.2em; }
.tenant-leader {
  display: flex; gap: 12px; align-items: center;
  padding: 12px; border-radius: 14px;
  background: rgba(255,255,255,0.04); border: 1px solid var(--line);
}
.leader-avatar {
  width: 42px; height: 42px; border-radius: 999px;
  display: grid; place-items: center; font-size: 1.3rem;
  background: rgba(255, 212, 59, 0.18); border: 1px solid rgba(255,212,59,0.4);
}
.tenant-leader small, .tenant-metrics span { color: var(--muted); font-size: 0.8rem; }
.tenant-metrics { display: flex; gap: 14px; flex-wrap: wrap; }

.countdown-card {
  display: grid; grid-template-columns: 1.4fr auto auto; gap: 22px; align-items: center;
  background:
    radial-gradient(circle at top right, rgba(255,212,59,0.18), transparent 50%),
    linear-gradient(135deg, rgba(255,123,0,0.18), rgba(13,79,52,0.6));
  border-color: rgba(255,212,59,0.4);
}
.countdown-clock { display: flex; gap: 10px; }
.cd-block {
  display: grid; gap: 2px; justify-items: center; min-width: 60px;
  padding: 10px 8px; border-radius: 14px;
  background: rgba(2,25,15,0.7); border: 1px solid var(--line);
}
.cd-block strong { font-family: "Sora", sans-serif; font-size: 1.5rem; }
.cd-block small { color: var(--muted); text-transform: uppercase; letter-spacing: 0.1em; font-size: 0.65rem; }

.branding-card { display: grid; gap: 16px; }
.branding-form {
  display: grid; gap: 14px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.branding-form button { grid-column: 1 / -1; justify-self: start; }
.branding-form input[type="color"] { padding: 0; height: 46px; min-height: 46px; cursor: pointer; }
.onboard-banner {
  grid-column: 1 / -1;
  padding: 12px 14px; border-radius: 12px;
  background: rgba(121,255,178,0.12); border: 1px solid rgba(121,255,178,0.35);
  color: var(--success);
}

.animated-ball { position: relative; overflow: hidden; }
.hero-ball {
  position: absolute; right: -20px; bottom: -20px;
  font-size: 8rem; opacity: 0.18;
  animation: rotateBall 12s linear infinite;
}
@keyframes rotateBall { to { transform: rotate(360deg); } }

.lead, .stack-list, .match-grid, .dashboard-grid > * {
  animation: rise 420ms ease both;
}
@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

.confetti-layer { position: fixed; inset: 0; pointer-events: none; z-index: 9999; overflow: hidden; }
.confetti-piece {
  position: absolute; top: -20px; width: 10px; height: 14px;
  border-radius: 2px;
  animation: confettiFall linear forwards;
}
@keyframes confettiFall {
  to { transform: translateY(110vh) rotate(720deg); opacity: 0.85; }
}

@media (max-width: 980px) {
  .branding-form { grid-template-columns: 1fr; }
  .countdown-card { grid-template-columns: 1fr; text-align: center; }
  .countdown-clock { justify-content: center; }
}

/* ===== Fun layer: pulse cards, badges, rivalry, flags ===== */
.pulse-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
  margin: 1.25rem 0 1.75rem;
}
.pulse-card {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 1.1rem 1.25rem;
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.01));
}
.pulse-card::before {
  content: "";
  position: absolute;
  inset: -40% -20% auto auto;
  width: 180px;
  height: 180px;
  background: radial-gradient(circle, var(--brand-primary) 0%, transparent 65%);
  opacity: 0.25;
  pointer-events: none;
}
.pulse-big {
  font-size: 2.4rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.1;
  color: var(--brand-secondary);
}
.pulse-big small {
  font-size: 0.95rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.55);
  margin-left: 0.3rem;
}
.pulse-card p {
  color: rgba(255, 255, 255, 0.75);
  font-size: 0.92rem;
  margin: 0;
}
.pulse-streak.is-hot .pulse-big {
  color: #ff8a3d;
  text-shadow: 0 0 18px rgba(255, 138, 61, 0.45);
  animation: pulse-glow 1.6s ease-in-out infinite;
}
@keyframes pulse-glow {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.04); }
}

.badge-wall {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 0.85rem;
  margin-top: 0.75rem;
}
.badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  padding: 1rem 0.85rem;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  text-align: center;
  filter: grayscale(0.9) brightness(0.6);
  opacity: 0.65;
  transition: transform 0.2s ease, filter 0.3s ease, opacity 0.3s ease;
}
.badge.is-unlocked {
  filter: none;
  opacity: 1;
  background: linear-gradient(135deg, rgba(255, 183, 77, 0.15), rgba(255, 123, 0, 0.05));
  border-color: rgba(255, 212, 59, 0.45);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.25), inset 0 0 0 1px rgba(255, 212, 59, 0.15);
  animation: badge-pop 0.6s ease-out;
}
.badge.is-unlocked:hover {
  transform: translateY(-3px) rotate(-1deg);
}
.badge-emoji {
  font-size: 1.9rem;
  line-height: 1;
}
.badge strong {
  font-size: 0.95rem;
  color: var(--ink);
}
.badge small {
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.55);
  line-height: 1.25;
}
@keyframes badge-pop {
  0% { transform: scale(0.6); opacity: 0; }
  60% { transform: scale(1.08); opacity: 1; }
  100% { transform: scale(1); }
}

.flag {
  display: inline-block;
  font-size: 1.05em;
  margin: 0 0.15em;
  filter: drop-shadow(0 1px 1px rgba(0, 0, 0, 0.35));
}
.countdown-card .flag { font-size: 1.3em; }
.countdown-card .vs {
  font-size: 0.65em;
  color: rgba(255, 255, 255, 0.55);
  margin: 0 0.4em;
  font-weight: 400;
}

.hint {
  color: rgba(255, 255, 255, 0.55);
  font-size: 0.85rem;
  margin: 0;
}

/* ===== Quick picks + community pulse ===== */
.quick-picks {
  margin-top: 0.85rem;
}
.quick-picks .eyebrow { margin: 0 0 0.4rem; }
.quick-pick-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}
.quick-pick {
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.04);
  color: var(--ink);
  border-radius: 999px;
  padding: 0.35rem 0.85rem;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.2s ease, border-color 0.2s ease;
}
.quick-pick:hover {
  background: var(--brand-primary);
  border-color: var(--brand-primary);
  transform: translateY(-1px);
}
input.flash {
  animation: input-flash 0.4s ease;
}
@keyframes input-flash {
  0% { background-color: rgba(255, 212, 59, 0.55); }
  100% { background-color: inherit; }
}

.community-card { padding: 1.25rem; }
.community-bar {
  display: flex;
  height: 38px;
  border-radius: 999px;
  overflow: hidden;
  margin-top: 0.5rem;
  background: rgba(255, 255, 255, 0.06);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}
.community-bar .cb {
  display: flex;
  align-items: center;
  justify-content: center;
  color: #06150d;
  font-weight: 700;
  font-size: 0.85rem;
  min-width: 2.5rem;
  transition: flex-grow 0.4s ease;
}
.cb-home { background: linear-gradient(135deg, #79ffb2, #3ad48a); }
.cb-draw { background: linear-gradient(135deg, #ffd43b, #ffae00); }
.cb-away { background: linear-gradient(135deg, #6ab0ff, #4178e0); color: #f4f8ff; }

.winner-chip .medal {
  display: inline-block;
  margin-right: 0.25rem;
  animation: medal-spin 2.4s linear infinite;
  transform-origin: center;
}
@keyframes medal-spin {
  0%, 100% { transform: rotate(-8deg); }
  50% { transform: rotate(8deg); }
}

/* ===== Live banner + bonus + share ===== */
.live-card {
  border: 1px solid rgba(255, 70, 70, 0.45);
  background: linear-gradient(135deg, rgba(255, 70, 70, 0.12), rgba(255, 123, 0, 0.05));
  padding: 1.1rem 1.25rem;
  position: relative;
  overflow: hidden;
}
.live-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.6rem;
}
.live-dot {
  width: 10px; height: 10px;
  border-radius: 999px;
  background: #ff4646;
  box-shadow: 0 0 0 0 rgba(255, 70, 70, 0.7);
  animation: live-pulse 1.4s ease-out infinite;
}
@keyframes live-pulse {
  0% { box-shadow: 0 0 0 0 rgba(255, 70, 70, 0.7); }
  100% { box-shadow: 0 0 0 14px rgba(255, 70, 70, 0); }
}
.live-label {
  font-weight: 800;
  letter-spacing: 0.12em;
  color: #ff8a8a;
  font-size: 0.85rem;
}
.live-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 0.6rem;
}
.live-match {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding: 0.7rem 0.9rem;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.06);
  color: var(--ink);
  text-decoration: none;
  transition: transform 0.15s ease;
}
.live-match:hover { transform: translateY(-2px); }
.live-match small { color: rgba(255, 255, 255, 0.55); font-size: 0.78rem; }

.bonus-hint {
  margin: 0.65rem 0 0.85rem;
  padding: 0.55rem 0.85rem;
  background: rgba(121, 255, 178, 0.08);
  border: 1px dashed rgba(121, 255, 178, 0.35);
  border-radius: 10px;
  font-size: 0.88rem;
  color: rgba(237, 255, 243, 0.88);
}
.bonus-hint b { color: var(--brand-accent); }

.share-btn {
  margin-top: 0.85rem;
  width: 100%;
}

/* ===== Day jornada + inline picks ===== */
.day-card {
  margin-top: 1rem;
  padding: 1.1rem 1.25rem;
}
.day-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 0.55rem;
  margin-top: 0.5rem;
}
.day-match {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 0.6rem;
  padding: 0.6rem 0.85rem;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  color: var(--ink);
  text-decoration: none;
  transition: transform 0.15s ease, border-color 0.2s ease;
}
.day-match:hover {
  transform: translateX(2px);
  border-color: var(--brand-primary);
}
.day-match.has-pick {
  background: linear-gradient(135deg, rgba(121, 255, 178, 0.10), rgba(121, 255, 178, 0.02));
  border-color: rgba(121, 255, 178, 0.35);
}
.day-time {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--brand-secondary);
  font-variant-numeric: tabular-nums;
}
.day-teams {
  font-size: 0.92rem;
}
.day-teams .vs { font-size: 0.7em; color: rgba(255,255,255,0.5); margin: 0 0.25em; }
.day-pick {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--brand-accent);
  white-space: nowrap;
}
.day-pick.pending { color: rgba(255, 255, 255, 0.6); font-weight: 500; }

.match-row.has-pick {
  background: linear-gradient(135deg, rgba(121, 255, 178, 0.08), transparent);
  border-color: rgba(121, 255, 178, 0.3);
}
.pick-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.25rem 0.7rem;
  border-radius: 999px;
  background: rgba(121, 255, 178, 0.15);
  border: 1px solid rgba(121, 255, 178, 0.4);
  color: var(--brand-accent);
  font-weight: 700;
  font-size: 0.85rem;
  font-variant-numeric: tabular-nums;
}

/* ============================================================
   Character Studio · avatares paramétricos estilo consola
   ============================================================ */
.character-avatar {
  display: inline-block;
  width: 96px;
  height: 96px;
  border-radius: 18px;
  overflow: hidden;
  background: rgba(0, 0, 0, 0.25);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35), inset 0 0 0 1px rgba(255, 255, 255, 0.06);
  vertical-align: middle;
}
.character-avatar svg {
  display: block;
  width: 100%;
  height: 100%;
}
.character-avatar-mini { width: 44px; height: 44px; border-radius: 10px; }
.character-avatar-sm { width: 64px; height: 64px; border-radius: 14px; }
.character-avatar-lg { width: 200px; height: 200px; border-radius: 24px; }
.character-avatar-xl { width: 280px; height: 280px; border-radius: 28px; }

/* Hero card en dashboard */
.character-hero {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1.6rem;
  align-items: center;
  padding: 1.4rem 1.6rem;
}
.character-hero-art {
  display: flex;
  align-items: center;
  justify-content: center;
}
.character-hero-art .character-avatar-lg {
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.45), 0 0 0 4px rgba(255, 255, 255, 0.04);
  transition: transform 0.3s ease;
}
.character-hero-art .character-avatar-lg:hover { transform: rotate(-2deg) scale(1.02); }
.character-hero-body h2 { margin: 0.2rem 0 0.6rem; font-size: 1.6rem; }
.character-hero-actions { margin-top: 1rem; }
@media (max-width: 640px) {
  .character-hero { grid-template-columns: 1fr; text-align: center; }
}

/* Editor */
.character-studio {
  display: grid;
  grid-template-columns: minmax(280px, 360px) 1fr;
  gap: 1.4rem;
  align-items: start;
}
@media (max-width: 900px) {
  .character-studio { grid-template-columns: 1fr; }
}
.studio-preview {
  position: sticky;
  top: 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.9rem;
  padding: 1.4rem;
}
.studio-preview .character-avatar-xl {
  width: 100%;
  max-width: 320px;
  height: auto;
  aspect-ratio: 1 / 1;
  box-shadow: 0 22px 48px rgba(0, 0, 0, 0.5);
}
.studio-name {
  font-family: "Sora", sans-serif;
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: 0.02em;
  margin: 0;
}
.studio-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; justify-content: center; }
.studio-controls {
  padding: 1.2rem 1.4rem 1.4rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}
.studio-trait-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.6rem 1rem;
}
@media (max-width: 720px) { .studio-trait-list { grid-template-columns: 1fr; } }
.char-trait {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 0.65rem 0.8rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.ct-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 0.78rem;
}
.ct-label {
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--brand-secondary);
}
.ct-value {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.85);
  font-weight: 600;
}
.ct-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 36px;
}
.ct-arrow {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.06);
  color: var(--ink);
  font-size: 1.2rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.1s ease, background 0.2s ease;
  line-height: 1;
}
.ct-arrow:hover {
  background: var(--brand-primary);
  color: #0d1b2a;
  transform: scale(1.08);
}
.ct-swatches {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  flex: 1;
}
.ct-swatch {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.15);
  cursor: pointer;
  padding: 0;
  transition: transform 0.12s ease, border-color 0.2s ease;
}
.ct-swatch:hover { transform: scale(1.15); }
.ct-swatch.is-active {
  border-color: #fff;
  box-shadow: 0 0 0 2px var(--brand-primary), 0 4px 12px rgba(0, 0, 0, 0.3);
  transform: scale(1.1);
}
.ct-style-name {
  flex: 1;
  text-align: center;
  font-weight: 600;
  font-size: 0.92rem;
  color: rgba(255, 255, 255, 0.9);
}

/* ============================================================
   Mundi-Coins · billetera + mercados de apuestas
   ============================================================ */
.wallet-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(255, 212, 59, 0.18), rgba(255, 123, 0, 0.12));
  border: 1px solid rgba(255, 212, 59, 0.5);
  color: var(--brand-secondary);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  text-decoration: none;
  transition: transform 0.15s ease, box-shadow 0.2s ease;
}
.wallet-pill:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(255, 212, 59, 0.25);
}
.wallet-pill .wallet-icon { font-size: 1.1em; line-height: 1; }
.wallet-sub { font-size: 0.55em; opacity: 0.7; font-weight: 500; }

.wallet-stats { display: flex; gap: 0.6rem; flex-wrap: wrap; }
.stat-chip {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 0.65rem 1rem;
  min-width: 130px;
}
.stat-chip .stat-label {
  display: block;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.55);
}
.stat-chip strong {
  font-family: "Sora", sans-serif;
  font-size: 1.35rem;
  font-variant-numeric: tabular-nums;
}

.wallet-grid { grid-template-columns: minmax(260px, 1fr) 2fr; }
@media (max-width: 760px) { .wallet-grid { grid-template-columns: 1fr; } }

.bonus-card {
  background: linear-gradient(160deg, rgba(255, 123, 0, 0.10), rgba(255, 212, 59, 0.04));
  border-color: rgba(255, 212, 59, 0.25);
}
.bonus-card.is-ready {
  animation: bonus-pulse 2.4s ease-in-out infinite;
}
@keyframes bonus-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(255, 212, 59, 0); }
  50% { box-shadow: 0 0 0 8px rgba(255, 212, 59, 0.18); }
}

.bet-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 0.5rem; }
.bet-list li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.6rem;
  padding: 0.6rem 0.8rem;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
}
.bet-list a { color: var(--ink); text-decoration: none; display: flex; flex-direction: column; gap: 0.15rem; }
.bet-match { font-weight: 700; }
.bet-meta { font-size: 0.82rem; opacity: 0.7; }
.bet-stake { font-weight: 700; font-variant-numeric: tabular-nums; color: var(--brand-secondary); white-space: nowrap; }

.movements-card { margin-top: 1.2rem; }
.movements-card td.num, .movements-card th.num { text-align: right; font-variant-numeric: tabular-nums; }
.ledger-pos td.num strong { color: var(--brand-accent); }
.ledger-neg td.num strong { color: #ff7373; }
.reason-chip {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.18rem 0.5rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
}
.reason-welcome, .reason-daily { background: rgba(255, 212, 59, 0.2); color: var(--brand-secondary); }
.reason-bet_win { background: rgba(121, 255, 178, 0.2); color: var(--brand-accent); }
.reason-bet_stake, .reason-bet_loss { background: rgba(255, 115, 115, 0.15); color: #ff9b9b; }
.reason-bet_refund { background: rgba(58, 161, 255, 0.2); color: #6ec3ff; }

/* Markets en match_detail ------------------------------------ */
.markets-card { padding: 1.2rem 1.4rem; }
.market-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1rem;
  margin-top: 0.6rem;
}
.market-block {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 1rem 1.1rem;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}
.market-block header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.6rem;
}
.market-block h3 { margin: 0; font-size: 1rem; font-family: "Sora", sans-serif; }
.market-status {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0.15rem 0.55rem;
  border-radius: 999px;
}
.market-status.open { background: rgba(121, 255, 178, 0.18); color: var(--brand-accent); }
.market-status.closed { background: rgba(255, 255, 255, 0.1); color: rgba(255, 255, 255, 0.6); }
.market-status.won { background: rgba(255, 212, 59, 0.2); color: var(--brand-secondary); }

.market-options { display: flex; flex-direction: column; gap: 0.4rem; }
.market-opt {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 0.6rem;
  padding: 0.55rem 0.8rem;
  border-radius: 12px;
  border: 1.5px solid rgba(255, 255, 255, 0.1);
  background: rgba(0, 0, 0, 0.2);
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.market-opt:hover { border-color: var(--brand-primary); }
.market-opt input[type="radio"] { accent-color: var(--brand-primary); }
.market-opt.is-pick {
  border-color: var(--brand-accent);
  background: rgba(121, 255, 178, 0.08);
}
.market-opt.is-winner {
  border-color: var(--brand-secondary);
  background: rgba(255, 212, 59, 0.12);
  box-shadow: 0 0 0 1px rgba(255, 212, 59, 0.4);
}
.opt-label { font-weight: 600; }
.opt-odds {
  font-family: "Sora", sans-serif;
  font-weight: 700;
  color: var(--brand-secondary);
  font-variant-numeric: tabular-nums;
  font-size: 0.95rem;
}

.bet-controls {
  display: flex;
  gap: 0.6rem;
  align-items: flex-end;
  flex-wrap: wrap;
}
.stake-input { display: flex; flex-direction: column; flex: 1; gap: 0.2rem; min-width: 140px; }
.stake-input span { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.08em; color: rgba(255, 255, 255, 0.6); font-weight: 700; }
.stake-input input {
  background: rgba(0, 0, 0, 0.35);
  border: 1.5px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  padding: 0.55rem 0.7rem;
  color: var(--ink);
  font-size: 1rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.stake-input input:focus { outline: 2px solid var(--brand-primary); border-color: var(--brand-primary); }
.stake-input small { font-size: 0.7rem; opacity: 0.6; }

.bet-status {
  margin: 0;
  padding: 0.55rem 0.8rem;
  border-radius: 10px;
  font-size: 0.88rem;
  background: rgba(255, 255, 255, 0.04);
}
.bet-status.bet-won { background: rgba(121, 255, 178, 0.15); color: var(--brand-accent); }
.bet-status.bet-lost { background: rgba(255, 115, 115, 0.12); color: #ff9b9b; }
