:root {
    --pr-bg: #1b2a3a;
    --pr-bg-2: #203245;
    --pr-surface: #263c53;
    --pr-surface-2: #2e4863;
    --pr-surface-hover: #375574;
    --pr-border: #446485;
    --pr-border-soft: #35506c;
    --pr-text: #f2f5fb;
    --pr-text-muted: #8b96b8;
    --pr-text-dim: #5d6889;
    --pr-accent: #22e07a;
    --pr-accent-2: #16b866;
    --pr-accent-glow: rgba(34, 224, 122, 0.35);
    --pr-warn: #f5b12e;
    --pr-danger: #ff5470;
    --pr-live: #ff3b5c;
    --pr-gold: #ffd166;
    --font-display: "Outfit", "Segoe UI", sans-serif;
    --font-body: "Inter", "Segoe UI", sans-serif;
}

* {
    box-sizing: border-box;
}

html {
    margin: 0;
    padding: 0;
    background: var(--pr-bg);
}

body {
    margin: 0;
    padding: 0;
    display: flow-root;
    min-height: 100vh;
    background-image: url('/bg-stadium.png');
    background-size: cover;
    background-position: center 65%;
    background-repeat: no-repeat;
    background-attachment: fixed;
    color: var(--pr-text);
    font-family: var(--font-body);
    font-size: 16px;
    -webkit-tap-highlight-color: transparent;
    scrollbar-width: thin;
    scrollbar-color: var(--pr-border) transparent;
}

a {
    color: inherit;
    text-decoration: none;
}

h1, h2, h3, h4, h5 {
    font-family: var(--font-display);
    margin: 0 0 12px;
}

.pr-app {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Header */

.pr-header {
    position: sticky;
    top: 0;
    z-index: 30;
    background: transparent;
    padding: 10px 18px 2px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease, box-shadow 0.2s ease;
}

/* Importante: acá solo se puede cambiar fondo/sombra, nunca padding ni tamaños.
   Si el header cambia de alto al scrollear, en páginas cortas eso corre el punto
   máximo de scroll, lo que dispara otro evento de scroll y hace que la clase se
   agregue/saque en bucle infinito (el header "titila" al llegar al final). */
.pr-header.pr-scrolled {
    background: linear-gradient(180deg, rgba(35, 27, 20, 0.85), rgba(35, 27, 20, 0.6));
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.25);
}

.pr-brand {
    display: flex;
    align-items: center;
    gap: 10px;
}

.pr-brand img {
    height: 88px;
    display: block;
    filter:
        drop-shadow(1px 0 0 #fff)
        drop-shadow(-1px 0 0 #fff)
        drop-shadow(0 1px 0 #fff)
        drop-shadow(0 -1px 0 #fff);
}

/* Layout */

.pr-content-row {
    flex: 1;
    width: 100%;
}

.pr-main {
    flex: 1;
    padding-bottom: 84px;
    max-width: 720px;
    width: 100%;
    margin: 0 auto;
}

.pr-side-rail {
    display: none;
}

/* Los rieles laterales solo aparecen cuando sobra espacio real a los costados
   del contenido central (720px + margen), para no forzar el layout en pantallas
   medianas y no quedar pegados a la navegación. */
@media (min-width: 1180px) {
    .pr-content-row {
        display: flex;
        justify-content: center;
        align-items: flex-start;
        gap: 28px;
        padding: 0 20px;
    }

    .pr-main {
        margin: 0;
    }

    .pr-side-rail {
        display: block;
        flex: none;
        width: 300px;
        position: sticky;
        top: 96px;
    }
}

.pr-ad-slot-rail {
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pr-page {
    padding: 14px 14px 26px;
    animation: pr-fade-in 0.25s ease-out;
}

@keyframes pr-fade-in {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}

.pr-ad-wrap {
    padding: 8px 14px 0;
}

.pr-ad-wrap:last-child {
    padding: 0 14px 8px;
}

.pr-score-input {
    width: 46px;
    text-align: center;
    background: var(--pr-surface-2);
    border: 1px solid var(--pr-border);
    color: var(--pr-text);
    border-radius: 8px;
    padding: 5px;
    font-family: var(--font-display);
    font-weight: 700;
}

/* Bottom nav */

.pr-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    display: flex;
    background: rgba(13, 21, 38, 0.92);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-top: 1px solid var(--pr-border-soft);
    padding: 10px 8px calc(10px + env(safe-area-inset-bottom));
    z-index: 20;
    box-shadow: 0 -8px 30px rgba(0, 0, 0, 0.35);
}

.pr-nav-item {
    flex: 1;
    text-align: center;
    padding: 6px 4px;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--pr-text-dim);
    border-radius: 12px;
    transition: color 0.15s ease, background 0.15s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

.pr-nav-icon {
    font-size: 1.15rem;
    line-height: 1;
}

.pr-nav-item.active {
    color: var(--pr-accent);
    background: rgba(34, 224, 122, 0.1);
}

/* Generic */

.pr-muted {
    color: var(--pr-text-muted);
}

.pr-date-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: linear-gradient(135deg, var(--pr-surface), var(--pr-surface-2));
    border: 1px solid var(--pr-border);
    border-radius: 14px;
    padding: 10px 8px;
    margin-bottom: 16px;
    text-transform: capitalize;
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 0.95rem;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.pr-btn {
    background: var(--pr-surface-2);
    color: var(--pr-text);
    border: 1px solid var(--pr-border);
    border-radius: 10px;
    padding: 9px 16px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.1s ease, background 0.15s ease, border-color 0.15s ease;
    font-family: var(--font-body);
}

.pr-btn:hover {
    background: var(--pr-surface-hover);
    border-color: var(--pr-text-dim);
}

.pr-btn:active {
    transform: scale(0.96);
}

.pr-date-nav .pr-btn {
    width: 36px;
    height: 36px;
    padding: 0;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    flex: none;
}

.pr-btn-primary {
    background: linear-gradient(135deg, var(--pr-accent), var(--pr-accent-2));
    color: #04160c;
    border: none;
    font-weight: 700;
    box-shadow: 0 6px 18px var(--pr-accent-glow);
}

.pr-btn-primary:hover {
    filter: brightness(1.08);
}

.pr-btn-primary:disabled {
    opacity: 0.4;
    box-shadow: none;
    cursor: not-allowed;
}

.pr-btn-warn {
    background: var(--pr-warn);
    color: #241a02;
    border: none;
    font-weight: 700;
}

.pr-btn-danger {
    background: var(--pr-danger);
    color: #2a0512;
    border: none;
    font-weight: 700;
}

.pr-btn-link {
    background: none;
    border: none;
    color: var(--pr-text-dim);
    text-decoration: underline;
    font-size: 0.82rem;
    padding: 0 0 0 8px;
    cursor: pointer;
}

.pr-btn-link:hover {
    color: var(--pr-danger);
}

/* League groups & match cards */

.pr-league-card {
    margin-bottom: 16px;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid var(--pr-border-soft);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
}

.pr-league-header {
    display: flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, var(--pr-surface-2), var(--pr-bg-2));
    padding: 10px 14px;
    font-family: var(--font-display);
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--pr-text);
    border-bottom: 1px solid var(--pr-border-soft);
}

.pr-league-icon {
    font-size: 0.9rem;
    filter: drop-shadow(0 0 4px var(--pr-accent-glow));
}

.pr-league-logo {
    width: 22px;
    height: 22px;
    object-fit: contain;
    flex: none;
    background: rgba(255, 255, 255, 0.88);
    border-radius: 50%;
    padding: 3px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
}

.pr-favorite-hero {
    margin-bottom: 18px;
}

.pr-favorite-hero-label {
    font-family: var(--font-display);
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--pr-gold);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 8px;
}

.pr-favorite-hero .pr-match-card {
    border-width: 2px;
}

.pr-league-card .pr-match-card {
    border: none;
    border-radius: 0;
    margin-bottom: 0;
    border-bottom: 1px solid var(--pr-border-soft);
    box-shadow: none;
    background: var(--pr-surface);
}

.pr-league-card .pr-match-card:last-child {
    border-bottom: none;
}

.pr-league-card .pr-match-card:hover {
    transform: none;
    background: var(--pr-surface-hover);
    box-shadow: none;
}

.pr-league-card .pr-match-card.is-live {
    box-shadow: inset 3px 0 0 var(--pr-live);
}

.pr-match-row {
    display: flex;
    align-items: center;
    gap: 10px;
    background: linear-gradient(145deg, var(--pr-surface), var(--pr-bg-2));
    border: 1px solid var(--pr-border-soft);
    border-radius: 14px;
    padding: 14px;
    margin-bottom: 10px;
    position: relative;
    transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

a.pr-match-row:hover {
    transform: translateY(-2px);
    border-color: var(--pr-accent);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

.pr-match-row.is-live {
    border-color: rgba(255, 59, 92, 0.5);
    box-shadow: 0 0 0 1px rgba(255, 59, 92, 0.15), 0 8px 24px rgba(255, 59, 92, 0.08);
}

.pr-team {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.92rem;
    font-weight: 500;
    min-width: 0;
}

.pr-team-name {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.pr-team:last-of-type {
    flex-direction: row-reverse;
    text-align: right;
}

.pr-avatar {
    flex: none;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 0.72rem;
    color: #fff;
    letter-spacing: 0.02em;
}

.pr-avatar.lg {
    width: 64px;
    height: 64px;
    font-size: 1.2rem;
    margin: 0 auto 8px;
}

.pr-avatar.xl {
    width: 84px;
    height: 84px;
    font-size: 1.6rem;
    margin: 0 auto 8px;
}

.pr-avatar-img {
    background: transparent;
    object-fit: contain;
}

.pr-score {
    min-width: 68px;
    text-align: center;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.05rem;
    font-variant-numeric: tabular-nums;
    color: var(--pr-text);
}

.pr-score.is-time {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--pr-text-muted);
}

.pr-live-badge {
    position: absolute;
    top: -9px;
    right: 10px;
    background: var(--pr-live);
    color: #fff;
    font-size: 0.62rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    padding: 3px 8px;
    border-radius: 999px;
    display: flex;
    align-items: center;
    gap: 4px;
    box-shadow: 0 2px 10px rgba(255, 59, 92, 0.5);
}

.pr-live-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #fff;
    animation: pr-pulse 1.2s ease-in-out infinite;
}

@keyframes pr-pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.4; transform: scale(0.7); }
}

.pr-minute {
    min-width: 68px;
    text-align: center;
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--pr-live);
}

.pr-greeting {
    font-family: var(--font-display);
    font-size: 1.15rem;
    font-weight: 700;
    margin: 0 0 12px;
}

.pr-match-card.is-favorite {
    border-color: var(--pr-gold);
    box-shadow: 0 0 0 1px rgba(255, 209, 102, 0.25), 0 8px 24px rgba(255, 209, 102, 0.1);
}

.pr-favorite-badge {
    position: absolute;
    top: -9px;
    left: 14px;
    font-size: 0.9rem;
}

.pr-mc-team-name.is-favorite {
    font-weight: 800;
    font-size: 0.86rem;
    color: var(--pr-gold);
}

.pr-date-count {
    font-weight: 500;
    color: var(--pr-text-muted);
    text-transform: none;
    font-size: 0.85rem;
    margin-left: 4px;
}

/* Match card (list) — crest above name, minute+score centered */

.pr-match-card {
    display: flex;
    align-items: center;
    gap: 4px;
    background: linear-gradient(145deg, var(--pr-surface), var(--pr-bg-2));
    border: 1px solid var(--pr-border-soft);
    border-radius: 16px;
    padding: 16px 10px;
    margin-bottom: 10px;
    position: relative;
    scroll-margin-top: 76px;
    transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.pr-match-card:hover {
    transform: translateY(-2px);
    border-color: var(--pr-accent);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

.pr-match-card.is-live {
    border-color: rgba(255, 59, 92, 0.5);
    box-shadow: 0 0 0 1px rgba(255, 59, 92, 0.15), 0 8px 24px rgba(255, 59, 92, 0.08);
}

.pr-match-card .pr-live-badge {
    top: -9px;
    right: 14px;
}

.pr-mc-team {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    min-width: 0;
    text-align: center;
}

.pr-mc-team .pr-avatar {
    width: 52px;
    height: 52px;
    font-size: 0.95rem;
}

.pr-mc-team-name {
    font-size: 0.78rem;
    font-weight: 600;
    line-height: 1.2;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    max-width: 100%;
}

.pr-mc-center {
    flex: none;
    width: 96px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
}

.pr-mc-minute {
    font-size: 0.7rem;
    font-weight: 800;
    color: var(--pr-live);
    letter-spacing: 0.02em;
}

.pr-mc-minute.is-finished {
    color: var(--pr-text-dim);
}

.pr-mc-score {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
    line-height: 1;
}

.pr-mc-time {
    font-family: var(--font-display);
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--pr-text-muted);
}

/* Empty state */

.pr-empty {
    text-align: center;
    padding: 40px 16px;
    color: var(--pr-text-muted);
}

.pr-empty-icon {
    font-size: 2.4rem;
    margin-bottom: 10px;
    opacity: 0.7;
}

/* League tabs */

.pr-league-tabs {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 10px;
    margin-bottom: 14px;
}

.pr-tab {
    flex: none;
    background: var(--pr-surface);
    border: 1px solid var(--pr-border);
    border-radius: 999px;
    padding: 7px 16px;
    font-size: 0.83rem;
    font-weight: 600;
    white-space: nowrap;
    transition: background 0.15s ease, color 0.15s ease;
}

.pr-tab.active {
    background: linear-gradient(135deg, var(--pr-accent), var(--pr-accent-2));
    color: #04160c;
    border-color: transparent;
}

/* League list (tables landing) */

.pr-league-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.pr-league-list-item {
    display: flex;
    align-items: center;
    gap: 12px;
    background: linear-gradient(145deg, var(--pr-surface), var(--pr-bg-2));
    border: 1px solid var(--pr-border-soft);
    border-radius: 14px;
    padding: 14px 16px;
    transition: transform 0.15s ease, border-color 0.15s ease;
    width: 100%;
    text-align: left;
    color: inherit;
    font-family: var(--font-body);
    font-size: 1rem;
    cursor: pointer;
}

.pr-checkbox-row {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    flex-wrap: nowrap;
    gap: 8px;
    padding: 8px 0;
    font-size: 0.92rem;
    cursor: pointer;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    border-bottom: 1px solid var(--pr-border-soft);
}

.pr-checkbox-row:last-child {
    border-bottom: none;
}

.pr-checkbox-row input {
    flex: none;
    width: 18px;
    height: 18px;
    margin: 0;
    accent-color: var(--pr-accent);
}

.pr-checkbox-label {
    flex: 1 1 auto;
    min-width: 0;
    overflow-wrap: anywhere;
    text-align: left;
}

.pr-league-list-item:hover {
    transform: translateY(-2px);
    border-color: var(--pr-accent);
}

.pr-league-list-item .pr-league-icon {
    font-size: 1.3rem;
}

.pr-league-list-name {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.pr-league-list-name strong {
    font-size: 0.95rem;
}

.pr-league-list-name .pr-muted {
    font-size: 0.75rem;
}

.pr-league-list-arrow {
    font-size: 1.3rem;
    color: var(--pr-text-dim);
}

.pr-back-link {
    display: inline-block;
    margin-bottom: 10px;
    color: var(--pr-text-muted);
    font-size: 0.85rem;
    font-weight: 600;
}

.pr-back-link:hover {
    color: var(--pr-accent);
}

/* Standings table */

.pr-table-wrap {
    border-radius: 14px;
    overflow-x: auto;
    overflow-y: hidden;
    border: 1px solid var(--pr-border-soft);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
}

.pr-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.83rem;
    background: var(--pr-surface);
}

.pr-table th {
    padding: 10px 6px;
    text-align: center;
    background: var(--pr-bg-2);
    color: var(--pr-text-dim);
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    font-weight: 700;
}

.pr-table td {
    padding: 9px 6px;
    text-align: center;
    border-top: 1px solid var(--pr-border-soft);
}

.pr-table th:nth-child(2), .pr-table td:nth-child(2) {
    text-align: left;
}

.pr-table tbody tr {
    transition: background 0.15s ease;
}

.pr-table tbody tr:hover {
    background: var(--pr-surface-hover);
}

.pr-table tbody tr.zone-title td:first-child {
    box-shadow: inset 3px 0 0 var(--pr-accent);
}

.pr-table tbody tr.zone-relegation td:first-child {
    box-shadow: inset 3px 0 0 var(--pr-danger);
}

.pr-pos {
    font-family: var(--font-display);
    font-weight: 700;
    color: var(--pr-text-muted);
}

.pr-team-cell {
    display: flex;
    align-items: center;
    gap: 8px;
}

.pr-pts {
    font-family: var(--font-display);
    font-weight: 800;
    color: var(--pr-accent);
}

.pr-form {
    display: flex;
    gap: 3px;
}

.pr-form-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 4px;
    font-size: 0.62rem;
    font-weight: 700;
    color: #fff;
}

.pr-form-w { background: var(--pr-accent-2); }
.pr-form-d { background: var(--pr-text-dim); }
.pr-form-l { background: var(--pr-danger); }

/* Match detail header */

.pr-match-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: radial-gradient(circle at 50% 0%, rgba(34, 224, 122, 0.08), transparent 60%), var(--pr-surface);
    border: 1px solid var(--pr-border-soft);
    border-radius: 18px;
    padding: 28px 14px 22px;
    margin-bottom: 18px;
    text-align: center;
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.3);
}

.pr-team-block {
    flex: 1;
    font-weight: 600;
    font-size: 0.9rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    cursor: pointer;
    transition: transform 0.15s ease;
}

.pr-team-block:hover {
    transform: translateY(-2px);
    color: var(--pr-accent);
}

.pr-team-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 12px 0 18px;
}

.pr-team-header h3 {
    margin: 0;
    text-align: center;
}

.pr-pitch {
    position: relative;
    aspect-ratio: 630 / 1245;
    width: 80%;
    max-width: 340px;
    margin-left: auto;
    margin-right: auto;
    background-image: url('/pitch-chalk.png');
    background-size: cover;
    background-position: center;
    border-radius: 6px;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.45);
    overflow: hidden;
    margin-bottom: 16px;
}

.pr-pitch-row {
    position: absolute;
    left: 0;
    right: 0;
    display: flex;
    justify-content: space-evenly;
    align-items: center;
    gap: 2px;
    padding: 0 10px;
    z-index: 1;
    transform: translateY(-50%);
}

.pr-pitch-rows {
    position: absolute;
    inset: 0;
    transform: translate(-1%, 3%);
}

.pr-pitch-row[data-line="F"] { top: 15%; }
.pr-pitch-row[data-line="M"] { top: 38%; }
.pr-pitch-row[data-line="D"] { top: 65%; }
.pr-pitch-row[data-line="G"] { top: 85%; }

.pr-pitch-player {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1px;
    flex: 1 1 0;
    min-width: 0;
    max-width: 52px;
}

.pr-pitch-photo-wrap {
    position: relative;
    width: 100%;
    max-width: 42px;
    aspect-ratio: 1 / 1;
}

.pr-pitch-photo {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.12);
    border: 2px solid #fdfdf6;
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.25), 0 0 6px rgba(255, 255, 255, 0.5);
}

.pr-pitch-number-badge {
    position: absolute;
    top: -4px;
    left: -4px;
    min-width: 18px;
    height: 18px;
    padding: 0 3px;
    border-radius: 50%;
    background: #fdfdf6;
    color: #1b3a1b;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 0.66rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
    z-index: 2;
}

.pr-pitch-photo img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
}

.pr-pitch-jersey-fallback {
    font-family: "Kalam", "Caveat", var(--font-display);
    font-weight: 700;
    font-size: 1.15rem;
    line-height: 1;
    color: #fdfdf6;
    text-shadow: 0 0 6px rgba(255, 255, 255, 0.55), 0 1px 2px rgba(0, 0, 0, 0.5);
}

.pr-pitch-name {
    font-family: "Kalam", "Caveat", var(--font-display);
    font-size: 0.86rem;
    font-weight: 400;
    color: #f1f5ee;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6);
    text-align: center;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.pr-roster {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.pr-roster-group {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--pr-text-dim);
    margin: 16px 0 8px;
}

.pr-roster-group:first-child {
    margin-top: 0;
}

.pr-roster-row {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--pr-surface);
    border: 1px solid var(--pr-border-soft);
    border-radius: 10px;
    padding: 10px 14px;
}

.pr-scorer-row {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--pr-surface);
    border: 1px solid var(--pr-border-soft);
    border-radius: 10px;
    padding: 10px 14px;
    margin-bottom: 8px;
}

.pr-scorer-pos {
    flex: none;
    width: 22px;
    text-align: center;
    font-family: var(--font-display);
    font-weight: 700;
    color: var(--pr-text-muted);
    font-size: 0.85rem;
}

.pr-player-avatar {
    position: relative;
    flex: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    overflow: hidden;
    background: var(--pr-surface-2);
    display: flex;
    align-items: center;
    justify-content: center;
}

.pr-player-avatar img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
    background: var(--pr-surface-2);
}

.pr-player-initials {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 0.85rem;
    color: var(--pr-text-muted);
}

.pr-scorer-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.pr-scorer-name {
    font-weight: 600;
    font-size: 0.92rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.pr-scorer-team {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.78rem;
    color: var(--pr-text-muted);
}

.pr-scorer-team .pr-avatar {
    width: 18px;
    height: 18px;
    font-size: 0.6rem;
}

.pr-scorer-stats {
    flex: none;
    text-align: right;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 1px;
}

.pr-scorer-stats strong {
    font-family: var(--font-display);
    font-size: 1.2rem;
    color: var(--pr-accent);
}

.pr-scorer-stats .pr-muted {
    font-size: 0.72rem;
}

.pr-roster-jersey {
    flex: none;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--pr-surface-2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 0.8rem;
    color: var(--pr-text-muted);
}

.pr-roster-name {
    flex: 1;
    font-weight: 600;
    font-size: 0.92rem;
}

.pr-score-block {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0 12px;
}

.pr-big-score {
    font-family: var(--font-display);
    font-size: 2.3rem;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
    line-height: 1;
}

.pr-status {
    margin-top: 6px;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--pr-text-muted);
}

.pr-status.is-live {
    color: var(--pr-live);
}

.pr-events {
    list-style: none;
    padding: 0;
    margin: 0;
}

.pr-timeline {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.pr-h2h-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 22px;
}

.pr-h2h-row {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--pr-surface);
    border: 1px solid var(--pr-border-soft);
    border-radius: 10px;
    padding: 8px 12px;
    font-size: 0.82rem;
}

.pr-h2h-date {
    flex: none;
    width: 56px;
    color: var(--pr-text-muted);
    font-size: 0.72rem;
}

.pr-h2h-team {
    flex: 1;
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 6px;
}

.pr-h2h-team .pr-avatar {
    flex: none;
    width: 20px;
    height: 20px;
    font-size: 0.6rem;
}

.pr-h2h-team-name {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.pr-h2h-away {
    flex-direction: row-reverse;
    text-align: right;
}

.pr-h2h-score {
    flex: none;
    font-family: var(--font-display);
    font-weight: 700;
    padding: 0 4px;
}

.pr-timeline::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    width: 1px;
    background: var(--pr-border-soft);
    transform: translateX(-0.5px);
}

.pr-timeline-row {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 8px;
    padding: 6px 0;
}

.pr-timeline-side {
    display: flex;
    align-items: center;
    gap: 6px;
    min-height: 20px;
}

.pr-timeline-home {
    justify-content: flex-end;
    text-align: right;
}

.pr-timeline-away {
    justify-content: flex-start;
    text-align: left;
}

.pr-timeline-text {
    font-size: 0.82rem;
    color: var(--pr-text-muted);
}

.pr-timeline-text strong {
    color: var(--pr-text);
    font-weight: 600;
    margin: 0 4px;
}

.pr-timeline-icon {
    font-size: 0.95rem;
    flex: none;
}

.pr-timeline-minute {
    flex: none;
    font-family: var(--font-display);
    font-size: 0.72rem;
    font-weight: 800;
    color: var(--pr-text-dim);
    background: var(--pr-bg);
    border: 1px solid var(--pr-border-soft);
    border-radius: 999px;
    padding: 3px 8px;
    z-index: 1;
}

.pr-events li {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--pr-surface);
    border: 1px solid var(--pr-border-soft);
    border-radius: 10px;
    padding: 10px 14px;
    margin-bottom: 7px;
    font-size: 0.88rem;
}

/* Forms */

.pr-login, .pr-veedor-control {
    max-width: 420px;
}

.pr-field {
    margin-bottom: 14px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.pr-field label {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--pr-text-muted);
}

.pr-field input:not([type="checkbox"]), .pr-select {
    background: var(--pr-surface-2);
    border: 1px solid var(--pr-border);
    color: var(--pr-text);
    border-radius: 10px;
    padding: 11px 13px;
    font-size: 1rem;
    width: 100%;
    font-family: var(--font-body);
    transition: border-color 0.15s ease;
}

.pr-field input:focus, .pr-select:focus {
    outline: none;
    border-color: var(--pr-accent);
}

.pr-select {
    margin-bottom: 16px;
}

.pr-control-row {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}

.pr-control-row > div {
    flex: 1;
    min-width: 140px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.pr-error {
    color: var(--pr-danger);
    font-size: 0.88rem;
    font-weight: 500;
}

/* Ads / sponsor */

.pr-sponsor-banner {
    display: block;
    margin-bottom: 12px;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--pr-border-soft);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.pr-sponsor-banner img {
    width: 100%;
    display: block;
}

.pr-ad-slot {
    background: var(--pr-surface);
    border: 1px dashed var(--pr-border);
    border-radius: 10px;
    padding: 14px;
    text-align: center;
    color: var(--pr-text-dim);
    font-size: 0.75rem;
    margin: 12px 0;
}

/* Blazor infra */

#blazor-error-ui {
    background: var(--pr-danger);
    color: white;
    bottom: 0;
    box-sizing: border-box;
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

#blazor-error-ui .dismiss {
    cursor: pointer;
    position: absolute;
    right: 0.75rem;
    top: 0.5rem;
}

.loading-progress {
    position: relative;
    display: block;
    width: 8rem;
    height: 8rem;
    margin: 20vh auto 1rem;
}

.loading-progress circle {
    fill: none;
    stroke: var(--pr-border);
    stroke-width: 0.6rem;
    transform-origin: 50% 50%;
    transform: rotate(-90deg);
}

.loading-progress circle:last-child {
    stroke: var(--pr-accent);
    stroke-dasharray: calc(3.141 * var(--blazor-load-percentage, 0%) * 0.8), 500%;
    transition: stroke-dasharray 0.05s ease-in-out;
}

.loading-progress-text {
    text-align: center;
    color: var(--pr-text-muted);
    font-family: var(--font-display);
}

.loading-progress-text::after {
    content: var(--blazor-load-percentage-text, "Cargando");
}

/* Noticias */

.pr-news-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.pr-news-card {
    display: flex;
    gap: 12px;
    background: linear-gradient(145deg, var(--pr-surface), var(--pr-bg-2));
    border: 1px solid var(--pr-border-soft);
    border-radius: 14px;
    padding: 10px;
    color: var(--pr-text);
    transition: transform 0.15s ease, border-color 0.15s ease;
}

.pr-news-card:hover {
    transform: translateY(-2px);
    border-color: var(--pr-border);
}

.pr-news-image {
    width: 96px;
    height: 96px;
    flex: none;
    object-fit: cover;
    border-radius: 10px;
    background: var(--pr-surface-2);
}

.pr-news-body {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
}

.pr-news-league {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--pr-accent);
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.pr-news-headline {
    margin: 0;
    font-size: 0.92rem;
    line-height: 1.3;
}

.pr-news-desc {
    margin: 0;
    font-size: 0.8rem;
    color: var(--pr-text-muted);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.pr-news-date {
    font-size: 0.7rem;
}

/* Footer */

.pr-footer {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 18px 14px 6px;
    text-align: center;
    font-size: 0.72rem;
    color: var(--pr-text-dim);
    border-top: 1px solid var(--pr-border-soft);
    margin-top: 10px;
}

.pr-footer-links a {
    color: var(--pr-text-muted);
    text-decoration: underline;
}

.pr-legal h4 {
    font-family: var(--font-display);
    margin: 20px 0 6px;
    font-size: 0.95rem;
}

.pr-legal p {
    color: var(--pr-text-muted);
    font-size: 0.88rem;
    line-height: 1.5;
    margin: 0 0 8px;
}

.pr-legal a {
    color: var(--pr-accent);
    text-decoration: underline;
}
