/**
 * Tennis Data Hub — Players module CSS
 *
 * Loadet automatisk på spillersider (kategori 56) via players.php.
 *
 * Indeholder:
 *   - CSS-variabler specifikt til spiller-modulet
 *   - Sektion-baggrunde (.tdh-section--hero, --menu, --live, ...)
 *   - Intern menu-styling
 *   - Social-bar-styling
 *
 * Værdierne her matcher den nuværende Divi-template på spillersider
 * (verificeret via DevTools, 13. maj 2026).
 */

/* ═══════════════════════════════════════════════════════════
   CSS-VARIABLER (module-specifikke)
   ═══════════════════════════════════════════════════════════ */

.tdh-player-profile {
    --tdh-primary:     #0f5c5c;
    --tdh-menu-bar:    #1c9090;
    --tdh-section-alt: #f4f4f4;
}


/* ═══════════════════════════════════════════════════════════
   SEKTION-BASE
   ═══════════════════════════════════════════════════════════ */

.tdh-player-profile .tdh-section {
    position: relative;
    width: 100%;
    margin: 0;
    padding: 0;
}

/* Indre container — 1200px max-bredde matcher Divi's globale .container.
   Det sikrer at hero og alle sektioner flugter med resten af sitet. */
.tdh-player-profile .tdh-section-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0;
    box-sizing: border-box;
}


/* ═══════════════════════════════════════════════════════════
   SEKTION-VARIANTER (baggrunde + padding)
   ═══════════════════════════════════════════════════════════ */

/* 1. Hero — mørkegrøn, 55/40 padding */
.tdh-player-profile .tdh-section--hero {
    background-color: var(--tdh-primary);
    padding-top: 55px;
    padding-bottom: 40px;
}
/* Hero bruger samme 1200px-container som de andre sektioner (ingen override) */

/* 2. Menu — lysere grøn, 5/5 padding */
.tdh-player-profile .tdh-section--menu {
    background-color: var(--tdh-menu-bar);
    padding-top: 5px;
    padding-bottom: 5px;
}

/* 2b. Eksternt link — bånd identisk med menu-bjælken, placeret mellem
   "Seneste kampe" og "Nyheder". Indvendigt bruger sektionen klassen
   .tdh-player-menu (samme som menuen), så tekst-styling og link-hover
   arves 1:1 — ingen separat CSS nødvendig. Kun synlig hvis ACF-feltet
   'eksternt-link' er udfyldt. */
.tdh-player-profile .tdh-section--extlink {
    background-color: var(--tdh-menu-bar);
    padding-top: 5px;
    padding-bottom: 5px;
}

/* 3. Live — grå baggrund med 40px padding-top der giver visuel afstand
   til den grønne menu-bjælke ovenfor (matcher Rublev's gamle Divi-template). */
.tdh-player-profile .tdh-section--live {
    background-color: var(--tdh-section-alt);
    padding-top: 40px;
    padding-bottom: 0;
}

/* Live-shortcoden sætter margin: 40px på .tdh-live-wrapper for at give afstand
   når den bruges standalone. Inde i master-shortcoden styrer .tdh-section--live's
   egen padding-top dén afstand i stedet, så vi nulstiller wrapper-marginen.
   Vigtigt: undgår også margin-collapse der ville få den hvide body-baggrund
   til at lække ud mellem menu- og live-sektionerne. */
.tdh-player-profile .tdh-section--live .tdh-live-wrapper {
    margin: 0;
}

/* Symmetrisk margin mellem flere kort-blokke inde i live-sektionen.
   tdh_shortcode_live() rendrer hver kamp-blok som <div class="tdh-wrap">...</div>,
   så når der er fx upcoming + finished_live (eller suspended + live + upcoming)
   får vi 40px luft mellem dem — samme afstand som mellem live-sektion og
   seneste-kampe-sektion nedenfor. */
.tdh-player-profile .tdh-section--live .tdh-live-wrapper > .tdh-wrap + .tdh-wrap {
    margin-top: 40px;
}

/* 4. Seneste kampe — grå, 40/40 */
.tdh-player-profile .tdh-section--kampe {
    background-color: var(--tdh-section-alt);
    padding-top: 40px;
    padding-bottom: 40px;
}

/* 5. Rangliste — hvid, 40/40 */
.tdh-player-profile .tdh-section--rangliste {
    background-color: #ffffff;
    padding-top: 40px;
    padding-bottom: 40px;
}

/* 6. Nyheder — mørkegrøn, 40/40, indre hvid box med border-radius */
.tdh-player-profile .tdh-section--nyheder {
    background-color: var(--tdh-primary);
    padding-top: 40px;
    padding-bottom: 40px;
}
.tdh-player-profile .tdh-section--nyheder .tdh-section-header h3 {
    color: #ffffff;
    font-family: 'Roboto Condensed', Helvetica, Arial, Lucida, sans-serif;
    font-weight: 700;
    font-size: 36px;
    line-height: 1.2em;
    margin: 0;
}
.tdh-player-profile .tdh-section--nyheder .tdh-section-header .tdh-tag {
    background: #ffffff;
    color: #0f5c5c;
    line-height: 1.6;
}
.tdh-player-profile .tdh-section--nyheder .tdh-news {
    background-color: #ffffff;
    border-radius: 10px;
    border: 1px solid #e2dfd8;
    padding: 25px 25px 10px 25px;
    overflow: hidden;
}

/* Underafsnit (Underlag, H2H): H3 under H2 Statistik, men i den mindre størrelse */
.tdh-player-profile .tdh-section-header h4,
.tdh-player-profile .tdh-section-header h3.tdh-sub-h {
    font-size: 24px;
    font-weight: 700;
    letter-spacing: -0.2px;
    margin: 0;
    padding: 0;
    line-height: 1.2;
}

/* 7. Sæsoner — grå, 40/40 */
.tdh-player-profile .tdh-section--saeson {
    background-color: var(--tdh-section-alt);
    padding-top: 40px;
    padding-bottom: 40px;
}

/* 9. Titler — hvid, 40/40 */
.tdh-player-profile .tdh-section--titler {
    background-color: #ffffff;
    padding-top: 40px;
    padding-bottom: 40px;
}

/* 10. Biografi — hvid, 35/35 */
.tdh-player-profile .tdh-section--bio {
    background-color: #ffffff;
    padding-top: 35px;
    padding-bottom: 35px;
}

/* 11. Follow — baggrundsbillede med mørk overlay, 35/35 */
.tdh-player-profile .tdh-section--follow {
    background-image: linear-gradient(180deg, rgba(0,0,0,0.65) 0%, rgba(0,0,0,0.65) 100%),
                      url('https://www.tennissporten.dk/wp-content/uploads/2026/02/tennis-header.webp');
    background-size: cover;
    background-position: 50% 50%;
    background-repeat: no-repeat;
    padding-top: 35px;
    padding-bottom: 35px;
}


/* ═══════════════════════════════════════════════════════════
   INDLEJREDE TDH-WRAPS — fjern indre padding/margin
   ═══════════════════════════════════════════════════════════
   Live, kampe, sæson, h2h, titler bruger shortcodes som internt
   wrapper deres output i .tdh-wrap > .tdh-container > .tdh-section.
   Disse har deres egne baggrunde og spacing fra hovedplugin'ets
   shared CSS. Vi nulstiller dem så de ikke konflikter med vores
   sektion-baggrunde. */

.tdh-player-profile .tdh-section .tdh-wrap {
    background: transparent;
}
.tdh-player-profile .tdh-section .tdh-container {
    padding: 0;
}


/* ═══════════════════════════════════════════════════════════
   INTERN MENU (.tdh-player-menu)
   ═══════════════════════════════════════════════════════════ */

.tdh-player-profile .tdh-player-menu {
    color: #ffffff;
    font-family: 'Roboto Condensed', Helvetica, Arial, Lucida, sans-serif;
    font-size: 16px;
    font-weight: normal;
    line-height: 1.7em;
    text-align: center;
    margin: 0;
    padding: 0;
}
.tdh-player-profile .tdh-player-menu a {
    color: #ffffff;
    text-decoration: none;
}
.tdh-player-profile .tdh-player-menu a:hover {
    text-decoration: underline;
}
.tdh-player-profile .tdh-menu-sep {
    color: #ffffff;
}


/* ═══════════════════════════════════════════════════════════
   SOCIAL BAR (.tdh-follow-*)
   ═══════════════════════════════════════════════════════════
   Designet matcher Aryna Sabalenkas spillerside (gamle system):
   hvide cirkulære ikoner med plain hvid baggrund og det fyldte
   ikon i hvid på cirklen via brand-farver. */

.tdh-player-profile .tdh-follow-title {
    color: #ffffff;
    text-align: center;
    font-family: 'Roboto Condensed', Helvetica, Arial, Lucida, sans-serif;
    font-weight: 700;
    font-size: 36px;
    line-height: 1.2em;
    margin: 0 0 25px 0;
}

.tdh-player-profile .tdh-follow-icons {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 60px;
}

/* Hvid cirkel med ikon i fuld bredde af cirklen — matcher Rublev's
   klassiske look med Divi's et_pb_icon-moduler. Alle ikoner får sitets
   primær-grønne farve så social-bar har visuel sammenhæng med resten af
   spillersidens design. */
.tdh-player-profile .tdh-follow-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    background-color: #ffffff;
    border-radius: 50%;
    color: var(--tdh-primary);
    text-decoration: none;
    transition: transform 0.2s ease;
    box-sizing: border-box;
}

/* Font Awesome <i>-tag inde i cirklen */
.tdh-player-profile .tdh-follow-icon i {
    font-size: 30px;
    line-height: 1;
    color: inherit;
}

.tdh-player-profile .tdh-follow-icon:hover {
    transform: translateY(-2px);
}


/* ═══════════════════════════════════════════════════════════
   BIO-SEKTION (.tdh-bio)
   ═══════════════════════════════════════════════════════════ */

.tdh-player-profile .tdh-bio {
    max-width: 720px;
    margin: 0 auto;
    color: #1a1a1a;
    line-height: 1.7em;
}
.tdh-player-profile .tdh-bio h2,
.tdh-player-profile .tdh-bio h3,
.tdh-player-profile .tdh-bio h4 {
    color: var(--tdh-primary);
    font-family: 'Roboto Condensed', Helvetica, Arial, Lucida, sans-serif;
    font-weight: 700;
}
.tdh-player-profile .tdh-bio h3 {
    font-size: 28px;
    line-height: 1.2em;
    margin: 0 0 15px 0;
}
.tdh-player-profile .tdh-bio p {
    margin: 0 0 15px 0;
}
.tdh-player-profile .tdh-bio p:last-child {
    margin-bottom: 0;
}


/* ═══════════════════════════════════════════════════════════
   MOBILE OVERRIDES (≤980px)
   ═══════════════════════════════════════════════════════════ */

@media only screen and (max-width: 980px) {
    .tdh-player-profile .tdh-section-inner {
        padding: 0 20px;
    }
    .tdh-player-profile .tdh-section--hero {
        padding-top: 70px;
        padding-bottom: 70px;
    }
    .tdh-player-profile .tdh-section--follow .tdh-follow-icons {
        gap: 36px;
    }
}


/* ═══════════════════════════════════════════════════════════
   MOBILE OVERRIDES (≤767px)
   ═══════════════════════════════════════════════════════════ */

@media only screen and (max-width: 767px) {
    .tdh-player-profile .tdh-section--hero {
        padding-top: 30px;
        padding-bottom: 25px;
    }
    .tdh-player-profile .tdh-section--menu {
        padding-top: 8px;
        padding-bottom: 8px;
    }
    .tdh-player-profile .tdh-section-inner {
        padding: 0 20px;
    }
    .tdh-player-profile .tdh-follow-title {
        font-size: 28px;
    }
    .tdh-player-profile .tdh-follow-icon {
        width: 48px;
        height: 48px;
    }
    .tdh-player-profile .tdh-follow-icon i {
        font-size: 24px;
    }
    .tdh-player-profile .tdh-section--nyheder .tdh-section-header h3 {
        font-size: 28px;
    }
}


/* ═══════════════════════════════════════════════════════════
 * ═══════════════════════════════════════════════════════════
 *
 *   SUB-SHORTCODE CSS
 *
 *   Stilarter for de individuelle spiller-sub-shortcodes
 *   ([tennis_hero], [tennis_saeson], [tennis_titler],
 *   [tennis_rivaler], [tennis_kampe], [tennis_rangliste],
 *   [tennis_live]).
 *
 *   Flyttet hertil fra tennis-data-hub.php (tdh_output_css)
 *   som del af modul-udflytningen 14. maj 2026.
 *
 *   Reglerne er ikke scopet under .tdh-player-profile fordi
 *   sub-shortcoderne bruges både i master-shortcoden og kan
 *   bruges standalone. Fil-niveau-scoping sikres af at
 *   players.css kun loades på kategori 56 via
 *   Tennis_Data_Hub_Players::enqueue_assets().
 *
 * ═══════════════════════════════════════════════════════════
 * ═══════════════════════════════════════════════════════════ */


/* ═══ Grid ═══ */
.tdh-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }

/* ═══ Surface tags ═══ */
.tdh-surface-tag { padding: 3px 10px; border-radius: 4px; font-size: 13px; text-transform: uppercase; letter-spacing: 0.5px; font-weight: 600; display: inline-block; }
.tdh-surface-tag.hard { background: rgba(37,99,235,0.08); color: #1d4ed8; }
.tdh-surface-tag.clay { background: rgba(194,65,12,0.08); color: #c2410c; }
.tdh-surface-tag.grass { background: var(--primary-light); color: var(--primary); }
.tdh-surface-tag.indoor { background: rgba(109,40,217,0.08); color: #6d28d9; }

/* ═══ Desktop/Mobile column toggle (spillertabeller) ═══ */
.tdh-col-desktop { }
.tdh-col-mobile { display: none; }

/* ═══ Hero ([tennis_hero]) ═══ */
.tdh-hero { position: relative; padding: 0; overflow: hidden; background: var(--primary); color: #fff; }
.tdh-hero-inner { max-width: 100%; margin: 0 auto; display: flex; gap: 36px; align-items: flex-start; position: relative; z-index: 1; }
.tdh-hero-photo { width: 150px; height: 150px; border-radius: 16px; overflow: hidden; flex-shrink: 0; position: relative; }
.tdh-hero-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tdh-hero-info { flex: 1; }
.tdh-hero-info h1 { font-size: 48px; font-weight: 900; letter-spacing: -1px; line-height: 1.1; margin: 0 0 4px 0; padding: 0; color: #fff; }
.tdh-hero-info h1 span { color: rgba(255,255,255,0.6); }
.tdh-hero-subtitle { font-size: 17px; color: rgba(255,255,255,0.65); margin-bottom: 22px; line-height: 1.5; }
.tdh-hero-subtitle img { vertical-align: middle; margin-right: 4px; }
.tdh-hero-sub-group { display: inline; }
.tdh-hero-sub-sep { display: inline; }
.tdh-hero-stats { display: flex; gap: 60px; flex-wrap: wrap; }
.tdh-hero-stat { display: flex; flex-direction: column; }
.tdh-hero-stat-value { font-size: 30px; font-weight: 600; line-height: 1.2; color: #fff; }
.tdh-hero-stat-value.tdh-rank { color: #fbbf24; }
.tdh-hero-stat-label { font-size: 12px; text-transform: uppercase; letter-spacing: 1.8px; color: rgba(255,255,255,0.45); margin-top: 2px; }

/* ═══ Bar Charts ([tennis_rivaler] m.fl.) ═══ */
.tdh-bar-row { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.tdh-bar-label { width: 48px; font-size: 16px; text-align: right; color: var(--text-dim); flex-shrink: 0; font-weight: 600; }
.tdh-bar-track { flex: 1; height: 32px; background: var(--bg-card-alt); border-radius: 4px; overflow: hidden; display: flex; }
.tdh-bar-fill-w { background: var(--primary); display: flex; align-items: center; justify-content: flex-end; padding-right: 10px; font-size: 14px; font-weight: 600; color: #fff; min-width: 32px; }
.tdh-bar-fill-l { background: var(--red); opacity: 0.65; display: flex; align-items: center; padding-left: 10px; font-size: 14px; font-weight: 600; color: #fff; min-width: 22px; }
.tdh-bar-pct { width: 50px; text-align: right; font-size: 16px; color: var(--text-muted); flex-shrink: 0; }

/* ═══ Surface Cards + Season selector ([tennis_saeson]) ═══ */
.tdh-surface-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.tdh-surface-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px; padding: 20px; text-align: center; box-shadow: 0 1px 3px rgba(0,0,0,0.04); }
.tdh-surface-card .tdh-sname { font-size: 13px; text-transform: uppercase; letter-spacing: 2px; color: var(--text-muted); margin-bottom: 10px; font-weight: 600; }
.tdh-surface-card .tdh-srecord { font-size: 28px; font-weight: 600; }
.tdh-surface-card .tdh-spct { font-size: 16px; color: var(--text-dim); margin-top: 4px; }
.tdh-surface-card.hard { border-top: 3px solid #2563eb; }
.tdh-surface-card.clay { border-top: 3px solid #c2410c; }
.tdh-surface-card.grass { border-top: 3px solid var(--primary); }
.tdh-season-selector { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 20px; }
.tdh-season-btn { font-size: 16px; font-weight: 600; padding: 8px 16px; border: 1px solid var(--border); border-radius: 6px; background: var(--bg-card); color: var(--text-dim); cursor: pointer; transition: all 0.15s ease; }
.tdh-season-btn:hover { border-color: var(--primary); color: var(--primary); }
.tdh-season-btn.active { background: var(--primary); color: #fff; border-color: var(--primary); }

/* ═══ Titles ([tennis_titler]) ═══ */
.tdh-title-item { display: flex; justify-content: space-between; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--border-light); font-size: 16px; }
.tdh-title-item.tdh-grand-slam { background: linear-gradient(90deg, rgba(146,64,14,0.06) 0%, transparent 60%); margin: 0 -16px; padding: 12px 16px; }
.tdh-title-item:last-child { border-bottom: none; }
.tdh-title-name { font-weight: 600; flex: 1; }
.tdh-title-meta { display: flex; gap: 14px; align-items: center; }
.tdh-title-meta span { font-size: 16px; color: var(--text-muted); }

/* ═══ Rivals ([tennis_rivaler] — bruger tdh-bar-row layout) ═══ */
.tdh-rival-label { width: 160px; font-size: 16px; text-align: left; color: var(--text-dim); flex-shrink: 0; font-weight: 600; }

/* ═══ Matches: Desktop table ([tennis_kampe]) ═══ */
.tdh-matches-table { overflow-x: auto; }
.tdh-matches-table table th:last-child, .tdh-matches-table table td:last-child { text-align: right; }

/* ═══ Matches: Mobile cards ([tennis_kampe]) ═══ */
.tdh-matches-cards { display: none; }
.tdh-match-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: 8px; padding: 14px 16px; margin-bottom: 10px; display: flex; flex-direction: column; gap: 4px; }
.tdh-mc-top { display: flex; justify-content: space-between; align-items: center; font-size: 16px; color: var(--text-muted); }
.tdh-mc-top .tdh-mc-date { font-size: 16px; }
.tdh-mc-top .tdh-mc-round { font-size: 16px; }
.tdh-mc-tournament { font-weight: 700; font-size: 16px; color: var(--primary); }
.tdh-mc-main { display: flex; justify-content: space-between; align-items: center; margin-top: 4px; }
.tdh-mc-opponent { font-weight: 600; font-size: 16px; }
.tdh-mc-right { display: flex; align-items: center; gap: 10px; }
.tdh-mc-result { font-size: 16px; font-weight: 700; padding: 2px 8px; display: flex; align-items: center; justify-content: center; border-radius: 4px; }
.tdh-mc-result.w { background: var(--primary-light); color: var(--primary); }
.tdh-mc-result.l { background: var(--red-light); color: var(--red); }
.tdh-mc-result.c { background: var(--bg-card-alt); color: var(--text-muted); font-style: italic; font-weight: 600; }
.tdh-mc-score { font-size: 16px; font-weight: 600; color: var(--text); }

/* ═══ Matches expand/collapse ([tennis_kampe]) ═══ */
.tdh-matches-wrap .tdh-match-hidden { display: none; }
.tdh-matches-wrap .tdh-matches-table tr.tdh-match-hidden { display: none; }
.tdh-matches-wrap.tdh-matches-expanded .tdh-matches-table tr.tdh-match-hidden { display: table-row; }
.tdh-matches-wrap.tdh-matches-expanded .tdh-matches-cards .tdh-match-hidden { display: flex; }
.tdh-expand-wrap { margin-top: 16px; text-align: center; }
.tdh-expand-btn { display: inline-flex; align-items: center; gap: 8px; font-family: inherit; font-size: 16px; font-weight: 600; padding: 10px 20px; border: 1px solid var(--border); border-radius: 6px; background: var(--bg-card); color: var(--text-dim); cursor: pointer; transition: all 0.15s ease; }
.tdh-expand-btn:hover { border-color: var(--primary); color: var(--primary); }
.tdh-expand-arrow { width: 14px; height: 14px; transition: transform 0.2s ease; }
.tdh-expand-btn[aria-expanded="true"] .tdh-expand-arrow { transform: rotate(180deg); }

/* ═══ Rankings ([tennis_rangliste]) ═══ */
.tdh-row-highlight td { background: var(--primary-light); }
.tdh-row-highlight td:first-child { color: var(--gold); font-weight: 700; }
.tdh-row-highlight td.tdh-name { font-weight: 700; }


/* ═══════════════════════════════════════════════════════════
   Responsive for sub-shortcodes (≤768px)
   ═══════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
    .tdh-hero { padding: 0; }
    .tdh-hero-inner { flex-direction: column; gap: 18px; }
    .tdh-hero-photo { width: 100px; height: 100px; border-radius: 12px; }
    .tdh-hero-info h1 { font-size: 34px; }
    .tdh-hero-sub-group { display: block; }
    .tdh-hero-sub-sep { display: none; }
    .tdh-hero-stats { gap: 14px 66px; }
    .tdh-hero-stat-value { font-size: 24px; }
    .tdh-hero-stat-label { font-size: 11px; letter-spacing: 1.2px; }
    .tdh-grid-2 { grid-template-columns: 1fr; }
    .tdh-col-desktop { display: none; }
    .tdh-col-mobile { display: table-cell; }
    .tdh-bar-label { width: 36px; font-size: 11px; }
    .tdh-bar-pct { width: 38px; font-size: 11px; }
    .tdh-bar-row { gap: 6px; }
    .tdh-surface-grid { grid-template-columns: 1fr; }
    .tdh-season-selector { gap: 4px; }
    .tdh-season-btn { padding: 5px 10px; font-size: 11px; }
    .tdh-rival-label { width: 110px; font-size: 16px; }
    .tdh-title-meta { gap: 10px; }
    .tdh-matches-table { display: none; }
    .tdh-matches-cards { display: block; }
}


/* ═══════════════════════════════════════════════════════════
   Live Matches ([tennis_live] — fra Fase 4 + styling-pass)
   ═══════════════════════════════════════════════════════════ */

.tdh-live-wrapper { margin: 40px 0 0 0; padding: 0; }

/* Næste kamp + Netop afsluttet — fjern td-border da tabellen kun har én række */
.tdh-upcoming-table table td,
.tdh-finished-table table td { border-bottom: none; }

/* Kort-container (wrapper indholdet i hvidt .tdh-card for live + finished) */
.tdh-card.tdh-live-container { padding: 10px 14px; }
.tdh-live-container + .tdh-live-container { margin-top: 12px; }

/* LIVE-chip (erstatter den gamle .tdh-live-header) */
.tdh-live-chip { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; text-transform: uppercase; letter-spacing: 1.8px; font-weight: 700; color: var(--red); white-space: nowrap; }
.tdh-live-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: var(--red); animation: tdh-pulse 1.6s ease-in-out infinite; }
@keyframes tdh-pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.35; } }

/* Scoreboard (kun live nu — finished bruger [tennis_kampe]-struktur).
   Scopes under .tdh-card for at slå .tdh-wrap td (specificitet 0,2,1 > 0,1,1)
   fra tdh-shared.css som ellers overstyrer padding/font-size. */
.tdh-live-scoreboard { width: 100%; border-collapse: collapse; margin: 0 0 4px; }
.tdh-card .tdh-live-scoreboard th { padding: 2px 8px; text-align: center; font-size: 11px; text-transform: uppercase; letter-spacing: 1px; font-weight: 600; color: var(--text-muted); border-bottom: 1px solid var(--border-light); }
.tdh-card .tdh-live-scoreboard td { padding: 3px 10px; border: none; border-bottom: 1px solid var(--border-light); font-size: 15px; }
.tdh-card .tdh-live-scoreboard tr:last-child td { border-bottom: none; }
.tdh-card .tdh-live-scoreboard tr:hover td { background: transparent; }
.tdh-sb-player { font-weight: 600; color: var(--text); }
.tdh-sb-player img { height: 16px; width: auto; margin-right: 6px; vertical-align: middle; border-radius: 2px; box-shadow: 0 0 0 1px rgba(0,0,0,0.15); }
.tdh-sb-set { min-width: 56px; text-align: center; font-variant-numeric: tabular-nums; color: var(--text-dim); font-weight: 500; white-space: nowrap; }
.tdh-sb-set.tdh-sb-current { background: var(--red-light); color: var(--red); font-weight: 700; }
.tdh-sb-set sup { font-size: 0.7em; }
.tdh-sb-game { min-width: 48px; text-align: center; font-variant-numeric: tabular-nums; color: var(--text); font-weight: 600; white-space: nowrap; }

/* Long/short-varianter af sæt- og parti-headers. Default (desktop): vis lang
   tekst ("1. sæt", "Parti"), skjul kort tekst. Mobil-blokken nedenfor skifter
   til kort tekst — for parti altid, for sæt-headers kun ved 4+ sæt. */
.tdh-sb-set-short,
.tdh-sb-game-short { display: none; }

/* Meta-cell i thead: chip + server-tekst venstre-alignment.
   Scopes under .tdh-card for at slå .tdh-wrap td/th-regler. */
.tdh-card .tdh-live-scoreboard th.tdh-sb-meta { text-align: left; padding: 2px 10px; border-bottom: 1px solid var(--border-light); }
.tdh-live-meta-wrap { display: inline-flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.tdh-live-meta-sep { color: var(--text-muted); font-weight: 400; }

/* Server-tekst (nu inline i thead-meta) */
.tdh-live-server-text { font-size: 12px; text-transform: uppercase; letter-spacing: 1px; color: var(--text-dim); font-weight: 500; }

/* Opdateret-timestamp (skjult — vises ikke længere efter beslutning 18. maj 2026) */
.tdh-live-updated { display: none; }

/* Menu-link (Fase 7) — uændret */
.tdh-player-live-link { display: none; }
.tdh-player-live-sep { display: none; }
.tdh-player-live-link[data-state="live"] { color: #ffffff !important; display: inline !important; }
.tdh-player-live-link[data-state="upcoming"],
.tdh-player-live-link[data-state="finished_live"] { display: inline !important; }

/* Mobil */
@media (max-width: 768px) {
    /* Container-padding: 16px top/bottom, 5px sider (fra default 14px) for at
       frigøre plads til scoreboardet.
       Selector matcher specificitet med desktop-reglen .tdh-card.tdh-live-container
       (0,2,0) — uden .tdh-card-præfikset taber denne regel i specificitet. */
    .tdh-card.tdh-live-container { padding: 16px 5px; }
    /* Meta-celle venstrejusteres så den flugter med spillernavnene under
       (default text-align: left fra desktop-reglen arves). */
    .tdh-live-meta-wrap { flex-direction: column; gap: 4px; align-items: flex-start; }
    .tdh-live-meta-sep { display: none; }
    /* td-padding: matcher desktop-specificitet (0,3,1) ved at scope under .tdh-card
       og .tdh-live-scoreboard. Tidligere bare ".tdh-live-scoreboard td" (0,1,1)
       tabte til desktop-reglen ".tdh-card .tdh-live-scoreboard td { padding: 3px 10px }"
       og blev aldrig anvendt — det er derfor "Parti" ved 3 sæt overflowede, da
       cellen ikke havde 6px 6px padding (som ville passe inden i 38px width) men
       i stedet 3px 10px (som krævede >58px bredde for "Parti"-teksten). */
    .tdh-card .tdh-live-scoreboard td { padding: 6px 6px; font-size: 15px; }
    /* Header-celler (th): halver venstre/højre padding på mobil (8px → 4px) for at
       frigøre plads. Specificitet 0,3,1 matcher desktop-reglen, vinder pga senere
       placering i kaskaden. */
    .tdh-card .tdh-live-scoreboard th { padding: 2px 4px; }
    /* Spillernavn-celle: smallere padding + lidt mindre font for at frigøre plads. */
    .tdh-card .tdh-live-scoreboard td.tdh-sb-player { padding: 6px 4px; font-size: 14px; }
    /* width-værdier kræver min-width: 0 for at faktisk virke. Default desktop-reglerne
       har min-width 56px (sb-set) og 48px (sb-game) som ellers vinder over min width-regler. */
    .tdh-sb-set { width: 30px; min-width: 0; }
    /* sb-game er 50px så "Parti"-teksten (~42px ved 11px font + uppercase + letter-spacing)
       passer indenfor cellen med 4px padding på hver side. 38px var for snæver. */
    .tdh-sb-game { width: 50px; min-width: 0; }

    /* Ved 4-5 sæt: krymp sæt- og parti-kolonnerne yderligere, da indholdet kun
       er ét tal i header og max 2 tegn i body (fx "6²" eller "40"). min-width: 0
       nuller default min-width (56px på sb-set, 48px på sb-game) så width-værdier
       under disse faktisk virker. */
    .tdh-live-scoreboard[data-sets="4"] .tdh-sb-set,
    .tdh-live-scoreboard[data-sets="5"] .tdh-sb-set { width: 22px; min-width: 0; }
    .tdh-live-scoreboard[data-sets="4"] .tdh-sb-game,
    .tdh-live-scoreboard[data-sets="5"] .tdh-sb-game { width: 28px; min-width: 0; }

    /* Parti-header: skift til "P" KUN ved 4-5 sæt. Ved ≤3 sæt er der plads
       til "Parti" og det fulde ord bevares. */
    .tdh-live-scoreboard[data-sets="4"] .tdh-sb-game-long,
    .tdh-live-scoreboard[data-sets="5"] .tdh-sb-game-long { display: none; }
    .tdh-live-scoreboard[data-sets="4"] .tdh-sb-game-short,
    .tdh-live-scoreboard[data-sets="5"] .tdh-sb-game-short { display: inline; }

    /* Sæt-headers: skift til kompakt ("1", "2"…) kun ved 4 eller 5 sæt,
       hvor "1. SÆT" ellers klippes på 375px-viewport. Ved ≤3 sæt bevares
       den fulde "1. SÆT"-tekst. */
    .tdh-live-scoreboard[data-sets="4"] .tdh-sb-set-long,
    .tdh-live-scoreboard[data-sets="5"] .tdh-sb-set-long { display: none; }
    .tdh-live-scoreboard[data-sets="4"] .tdh-sb-set-short,
    .tdh-live-scoreboard[data-sets="5"] .tdh-sb-set-short { display: inline; }
}
    
/* ════════════════════════════════════════════════════════════
 * SUSPENDED (Udsat kamp) — tilføjet 16. maj 2026
 * ════════════════════════════════════════════════════════════
 * Genbruger live-kortets layout. Skifter farver fra rød (live)
 * til amber/orange (suspended) og fjerner pulse-animationen.
 * Tilføjer "Kamp genoptages..."-besked under scoreboardet.
 *
 * INDSÆT: i slutningen af players.css (efter linje 554, dvs.
 * efter den eksisterende @media (max-width: 768px)-blok).
 * ════════════════════════════════════════════════════════════ */

/* Section-tag: gul/orange variant af .tdh-tag */
.tdh-tag.tdh-tag--suspended { background: #f59e0b; color: #1f2937; }

/* Chip i scoreboard-meta: "AFBRUDT · 3. SÆT" */
.tdh-live-chip.tdh-live-chip--suspended { color: #b45309; }

/* Dot/prik: amber, INGEN pulse-animation (kampen er ikke live) */
.tdh-live-dot.tdh-live-dot--suspended { background: #f59e0b; animation: none; }

/* Genoptages-besked nederst i kortet */
.tdh-suspended-resume {
    margin-top: 12px;
    padding: 8px 12px;
    background: #fef3c7;
    border-left: 3px solid #f59e0b;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 500;
    color: #78350f;
}

/* Menu-link skal også vises for suspended-state */
.tdh-player-live-link[data-state="suspended"] { display: inline !important; }

/* Mobil */
@media (max-width: 768px) {
    .tdh-suspended-resume { text-align: center; font-size: 12px; }
}