/* League pages. Sits on top of site.css. Instant + ghost: every view paints a skeleton first. */
.league { --skel: #e6e9ee; }
.league .lnav { display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: center; margin: 0 0 18px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.league .lnav a { text-decoration: none; font-weight: 600; padding: 4px 8px; border-radius: 6px; }
.league .lnav a.on { background: var(--accent2); color: #fff; }
.league .lnav .lang { margin-left: auto; }
.league .lnav .lang button { border: 1px solid var(--line); background: var(--card); padding: 4px 10px; border-radius: 6px; cursor: pointer; font-weight: 600; }
.league .lnav .lang button.on { background: var(--ink); color: #fff; border-color: var(--ink); }
.skel { background: linear-gradient(90deg, var(--skel) 25%, #f2f4f7 50%, var(--skel) 75%); background-size: 200% 100%; animation: sk 1.2s infinite; border-radius: 6px; color: transparent !important; }
@keyframes sk { 0% { background-position: 200% 0 } 100% { background-position: -200% 0 } }
.skel.h1 { height: 34px; width: 50%; margin-bottom: 14px; }
.skel.line { height: 16px; margin: 8px 0; }
.skel.row { height: 40px; margin: 6px 0; }
.league .err { border-left: 4px solid var(--accent); background: #fdeeee; padding: 12px 14px; border-radius: 0 8px 8px 0; }
.league .wake { border-left: 4px solid #e0a100; background: #fff8e1; padding: 12px 14px; border-radius: 0 8px 8px 0; }
.league .kv { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; margin: 12px 0 18px; }
.league .kv div { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; }
.league .kv b { display: block; font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--dim); }
.league .kv span { font-size: 20px; font-weight: 700; }
.league .mng { color: #b45309; font-weight: 700; } .league .dead { color: #9f1239; font-weight: 700; } .league .gained { font-weight: 700; color: var(--accent2); }
.league .bracket { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.league .bracket .st { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; }
.league .bracket .st b { display: block; font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--dim); margin-bottom: 4px; }
.league .bracket .st .w { font-weight: 700; }
.league .bracket .champ { grid-column: 1 / -1; text-align: center; font-size: 20px; }
.league form .f { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px 14px; margin-bottom: 14px; }
.league label { display: block; font-size: 13px; font-weight: 600; color: var(--dim); }
.league input, .league select, .league textarea { width: 100%; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; font: inherit; background: #fff; }
.league input[type=number] { width: 70px; padding: 6px; text-align: center; }
.league input[type=checkbox], .league input[type=radio] { width: auto; }
.league button.cta, .league .btn { display: inline-block; padding: 10px 18px; border-radius: 8px; background: var(--accent); color: #fff; font-weight: 700; border: 0; cursor: pointer; font: inherit; text-decoration: none; }
.league .btn.sec, .league button.sec { background: var(--card); color: var(--ink); border: 1px solid var(--line); padding: 6px 12px; font-weight: 600; cursor: pointer; border-radius: 8px; font: inherit; }
.league button:disabled { opacity: .5; cursor: default; }
.league .budget { font-size: 18px; font-weight: 700; } .league .budget.over { color: var(--accent); }
.league .muted { color: var(--dim); font-size: 14px; }
.league .ok { border-left: 4px solid #2e8b3d; background: #eefaf0; padding: 12px 14px; border-radius: 0 8px 8px 0; }
.league table td input[type=number] { width: 56px; }
.league .tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 16px; }
.league .tabs a { padding: 6px 12px; border: 1px solid var(--line); border-radius: 8px; background: var(--card); text-decoration: none; font-weight: 600; }
.league .tabs a.on { background: var(--ink); color: #fff; border-color: var(--ink); }
@media (max-width: 640px) { .league .bracket { grid-template-columns: 1fr; } }
