/* ════════════════════════════════════════════════════════════════
   Glance — Custom CSS
   - Police : Outfit (Google Fonts)
   - Background : iceberg jour/nuit (auto via prefers-color-scheme)
   - Fusion visuelle : merge-top / merge-bottom
   ════════════════════════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&display=swap');

/* ────────────────────────────────────────────────
   1) Police globale
   ──────────────────────────────────────────────── */
:root,
html,
body,
.widget,
.widget-content,
.widget-header,
input, button, select, textarea, a, p, div, span, h1, h2, h3, h4, h5, h6 {
    font-family: 'Outfit', -apple-system, BlinkMacSystemFont,
                 "Segoe UI", system-ui, sans-serif !important;
}

/* L'horloge & les chiffres restent un poil plus larges */
.clock, .digit, .size-h1, .size-h2 {
    font-weight: 500;
    letter-spacing: 0.02em;
}

/* ────────────────────────────────────────────────
   2) Background : iceberg de NUIT par défaut
   ──────────────────────────────────────────────── */
body {
    background:
        linear-gradient(180deg, rgba(15, 18, 25, 0.55) 0%, rgba(15, 18, 25, 0.88) 100%),
        url('/assets/bg-night.png') center center / cover no-repeat fixed !important;
}

/* ────────────────────────────────────────────────
   3) Background : iceberg de JOUR
      Activé si :
        - le système est en clair, OU
        - le thème "jour" (light: true) est sélectionné dans le picker
   ──────────────────────────────────────────────── */
@media (prefers-color-scheme: light) {
    body {
        background:
            linear-gradient(180deg, rgba(220, 235, 250, 0.30) 0%, rgba(180, 210, 235, 0.55) 100%),
            url('/assets/bg-day.png') center center / cover no-repeat fixed !important;
    }
}

/* Quand Glance applique le thème light (light: true), il met data-scheme="light" */
body[data-scheme="light"],
html[data-scheme="light"] body,
:root[data-scheme="light"] body {
    background:
        linear-gradient(180deg, rgba(220, 235, 250, 0.30) 0%, rgba(180, 210, 235, 0.55) 100%),
        url('/assets/bg-day.png') center center / cover no-repeat fixed !important;
}

/* ────────────────────────────────────────────────
   4) Fusion visuelle Serveur OVH + PVE
   ──────────────────────────────────────────────── */
.widget.merge-top {
    margin-bottom: 0 !important;
    border-bottom-left-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
}
.widget.merge-top .widget-content,
.widget.merge-top > .widget-body {
    border-bottom-left-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
    border-bottom: none !important;
    padding-bottom: 0.5rem !important;
}

.widget.merge-bottom {
    margin-top: 0 !important;
    border-top-left-radius: 0 !important;
    border-top-right-radius: 0 !important;
}
.widget.merge-bottom > .widget-header,
.widget.merge-bottom .widget-header {
    display: none !important;
}
.widget.merge-bottom .widget-content,
.widget.merge-bottom > .widget-body {
    border-top-left-radius: 0 !important;
    border-top-right-radius: 0 !important;
    border-top: 1px solid var(--color-separator, rgba(255, 255, 255, 0.07)) !important;
    padding-top: 0.5rem !important;
    margin-top: 0 !important;
}

/* ════════════════════════════════════════════════════════════════

/* ════════════════════════════════════════════════════════════════

/* ════════════════════════════════════════════════════════════════

/* ════════════════════════════════════════════════════════════════
   Crop iframe HLTV Vitality
   ▼ AJUSTE CES 2 VARIABLES SI NÉCESSAIRE ▼
   ════════════════════════════════════════════════════════════════ */
:root {
    --hltv-visible-height: 280px;   /* ← Hauteur visible du widget (modifie ICI) */
    --hltv-scroll-offset:  480px;   /* ← Décalage interne pour cibler "Upcoming matches" */
}

.widget.hltv-frame {
    max-height: var(--hltv-visible-height) !important;
    overflow: hidden !important;
}
.widget.hltv-frame > * {
    overflow: hidden !important;
}

.widget.hltv-frame iframe {
    height: 1200px !important;
    width: calc(100% + 22px) !important;
    margin-top: calc(0px - var(--hltv-scroll-offset)) !important;
    margin-bottom: -50px !important;
    border: 0 !important;
    display: block !important;
    background: transparent !important;
}

/* ════════════════════════════════════════════════════════════════

/* ════════════════════════════════════════════════════════════════

/* ════════════════════════════════════════════════════════════════

/* ════════════════════════════════════════════════════════════════
   Barre de recherche style Google (pill + logo G coloré)
   ════════════════════════════════════════════════════════════════ */

/* Réduit l'espace du head-widgets à 0 */
main > .head-widgets,
[class*="head-widgets"] {
    margin: 0 !important;
    padding: 0 !important;
    min-height: 0 !important;
    height: 0 !important;
}

/* Conteneur du widget : centré dans le header */
.widget.header-search {
    position: fixed !important;
    top: 0 !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    width: min(480px, 42vw) !important;
    min-width: 320px !important;
    height: 3rem !important;
    z-index: 1000 !important;
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    visibility: visible !important;
    opacity: 1 !important;
    display: flex !important;
    align-items: center !important;
}

.widget.header-search .widget-header,
.widget.header-search > h2 {
    display: none !important;
}

/* Cache l'icône loupe par défaut à gauche (on met le G Google à la place) */
.widget.header-search svg {
    display: none !important;
}

/* Cache le badge "S" qui dépare le look Google */
.widget.header-search kbd,
.widget.header-search .search-widget-shortcut,
.widget.header-search [class*="shortcut"] {
    display: none !important;
}

/* INPUT style Google : pill, fond opaque, logo G en background à gauche */
.widget.header-search input,
.widget.header-search input[type="text"] {
    width: 100% !important;
    height: 2.6rem !important;
    background-color: rgba(28, 30, 38, 0.92) !important;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48'><path d='M43.611 20.083H42V20H24v8h11.303c-1.649 4.657-6.08 8-11.303 8-6.627 0-12-5.373-12-12s5.373-12 12-12c3.059 0 5.842 1.154 7.961 3.039l5.657-5.657C34.046 6.053 29.268 4 24 4 12.955 4 4 12.955 4 24s8.955 20 20 20 20-8.955 20-20c0-1.341-.138-2.65-.389-3.917z' fill='%23FFC107'/><path d='M6.306 14.691l6.571 4.819C14.655 15.108 18.961 12 24 12c3.059 0 5.842 1.154 7.961 3.039l5.657-5.657C34.046 6.053 29.268 4 24 4 16.318 4 9.656 8.337 6.306 14.691z' fill='%23FF3D00'/><path d='M24 44c5.166 0 9.86-1.977 13.409-5.192l-6.19-5.238C29.211 35.091 26.715 36 24 36c-5.202 0-9.619-3.317-11.283-7.946l-6.522 5.025C9.505 39.556 16.227 44 24 44z' fill='%234CAF50'/><path d='M43.611 20.083H42V20H24v8h11.303c-.792 2.237-2.231 4.166-4.087 5.571l6.19 5.238C36.971 39.205 44 34 44 24c0-1.341-.138-2.65-.389-3.917z' fill='%231976D2'/></svg>") !important;
    background-repeat: no-repeat !important;
    background-position: 0.95rem center !important;
    background-size: 1.15rem auto !important;
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    border-radius: 100px !important;            /* pill shape */
    padding: 0 1.2rem 0 2.85rem !important;     /* place pour le logo G */
    font-size: 0.9rem !important;
    color: rgba(255, 255, 255, 0.92) !important;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.25) !important;
    transition: background-color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.widget.header-search input::placeholder {
    color: rgba(255, 255, 255, 0.45) !important;
    font-weight: 400;
}

.widget.header-search input:hover {
    background-color: rgba(35, 38, 48, 0.95) !important;
    border-color: rgba(255, 255, 255, 0.18) !important;
}
.widget.header-search input:focus {
    background-color: rgba(40, 43, 55, 1) !important;
    border-color: rgba(255, 255, 255, 0.25) !important;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.4) !important;
    outline: none !important;
}

/* Mobile : bascule vers flux normal */
@media (max-width: 768px) {
    main > .head-widgets,
    [class*="head-widgets"] {
        height: auto !important;
        margin: 0 0 1rem 0 !important;
    }
    .widget.header-search {
        position: static !important;
        transform: none !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }
}

/* ════════════════════════════════════════════════════════════════
   Prowlarr — Barre de recherche embarquée + Indexers chips
   ════════════════════════════════════════════════════════════════ */

.section-prowlarr-indexers .widget-content { display: flex; flex-direction: column; gap: 0.85rem; }

.prowlarr-indexers .prowlarr-index-item { align-items: center; }
.prowlarr-indexers .prowlarr-index-item > span {
    text-transform: capitalize;
    background: var(--color-background);
    padding: 0.2rem 0.75rem;
    border: 1px solid var(--color-widget-content-border);
    border-radius: var(--border-radius);
    font-size: var(--font-size-tiny);
}

/* Pill style "Google" pour la recherche embarquée */
.prowlarr-quick-search { width: 100%; }
.prowlarr-quick-search-form {
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: 100%;
    height: 2.6rem;
    padding: 0 0.4rem 0 2.85rem;
    background-color: rgba(28, 30, 38, 0.92);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 100px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.25);
    transition: background-color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}
.prowlarr-quick-search-form:hover {
    background-color: rgba(35, 38, 48, 0.95);
    border-color: rgba(255, 255, 255, 0.18);
}
.prowlarr-quick-search-form:focus-within {
    background-color: rgba(40, 43, 55, 1);
    border-color: rgba(255, 255, 255, 0.28);
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.4);
}
.prowlarr-quick-search-icon {
    position: absolute;
    left: 0.95rem;
    top: 50%;
    transform: translateY(-50%);
    width: 1.05rem;
    height: 1.05rem;
    color: rgba(255, 255, 255, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
}
.prowlarr-quick-search-icon svg { width: 100%; height: 100%; }
.prowlarr-quick-search-input {
    flex: 1 1 auto;
    min-width: 0;
    height: 100%;
    background: transparent;
    border: none;
    outline: none;
    color: rgba(255, 255, 255, 0.92);
    font-size: 0.92rem;
    padding: 0;
}
.prowlarr-quick-search-input::placeholder { color: rgba(255, 255, 255, 0.45); }
.prowlarr-quick-search-input::-webkit-search-cancel-button { display: none; }

.prowlarr-quick-search-clear,
.prowlarr-quick-search-submit {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 1.95rem;
    width: 1.95rem;
    border-radius: 50%;
    border: none;
    background: transparent;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease, transform 0.1s ease;
    padding: 0;
}
.prowlarr-quick-search-clear { font-size: 1.25rem; line-height: 1; }
.prowlarr-quick-search-clear:hover { background: rgba(255, 255, 255, 0.08); color: #fff; }
.prowlarr-quick-search-submit svg { width: 1.05rem; height: 1.05rem; }
.prowlarr-quick-search-submit:not(:disabled) {
    background: var(--color-primary);
    color: var(--color-background);
}
.prowlarr-quick-search-submit:not(:disabled):hover { transform: scale(1.05); }
.prowlarr-quick-search-submit:disabled { opacity: 0.35; cursor: not-allowed; }

/* ════════════════════════════════════════════════════════════════
   Prowlarr — Modale de recherche
   ════════════════════════════════════════════════════════════════ */

body.prowlarr-modal-open { overflow: hidden; }

.prowlarr-search-modal {
    position: fixed;
    inset: 0;
    z-index: 5000;
    display: none;
    background: rgba(8, 10, 16, 0.72);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    align-items: flex-start;
    justify-content: center;
    padding: 4vh 2vw;
}
.prowlarr-search-modal.is-open { display: flex; }

.prowlarr-search-modal-dialog {
    position: relative;
    width: min(960px, 100%);
    max-height: 92vh;
    display: flex;
    flex-direction: column;
    border-radius: calc(var(--border-radius) * 2);
    background: var(--color-widget-background);
    border: 1px solid var(--color-widget-content-border);
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55);
    overflow: hidden;
}

.prowlarr-search-modal-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.9rem 1.1rem;
    border-bottom: 1px solid var(--color-widget-content-border);
    background: rgba(255, 255, 255, 0.02);
}
.prowlarr-search-modal-title {
    font-weight: 600;
    color: var(--color-text-highlight);
}
.prowlarr-search-modal-close {
    background: transparent;
    border: none;
    color: var(--color-text-subdue);
    font-size: 1.6rem;
    line-height: 1;
    cursor: pointer;
    padding: 0.1rem 0.55rem;
    border-radius: 50%;
    transition: background 0.15s ease, color 0.15s ease;
}
.prowlarr-search-modal-close:hover { background: rgba(255, 255, 255, 0.08); color: var(--color-text-highlight); }

.prowlarr-search-modal-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.6rem;
    padding: 0.85rem 1.1rem;
    border-bottom: 1px solid var(--color-widget-content-border);
}
.prowlarr-search-modal-query {
    flex: 1 1 260px;
    min-width: 0;
    height: 2.4rem;
    padding: 0 0.85rem;
    background: var(--color-background);
    border: 1px solid var(--color-widget-content-border);
    border-radius: 100px;
    color: var(--color-text-highlight);
    outline: none;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.prowlarr-search-modal-query:focus { border-color: var(--color-primary); box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.06); }
.prowlarr-search-modal-query::-webkit-search-cancel-button { display: none; }

.prowlarr-search-modal-indexers {
    height: 2.4rem;
    padding: 0 0.7rem;
    background: var(--color-background);
    border: 1px solid var(--color-widget-content-border);
    border-radius: var(--border-radius);
    color: var(--color-text-highlight);
    cursor: pointer;
    max-width: 14rem;
}

.prowlarr-search-modal-actions-end {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    margin-left: auto;
}
.prowlarr-search-modal-clear {
    height: 2.4rem;
    width: 2.4rem;
    border-radius: 50%;
    border: 1px solid transparent;
    background: transparent;
    color: var(--color-text-subdue);
    font-size: 1.25rem;
    cursor: pointer;
}
.prowlarr-search-modal-clear:hover { background: rgba(255, 255, 255, 0.06); color: var(--color-text-highlight); }
.prowlarr-search-modal-run {
    height: 2.4rem;
    padding: 0 1.1rem;
    border-radius: 100px;
    border: none;
    background: var(--color-primary);
    color: var(--color-background);
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.1s ease, opacity 0.15s ease;
}
.prowlarr-search-modal-run:hover:not(:disabled) { transform: translateY(-1px); }
.prowlarr-search-modal-run:disabled { opacity: 0.4; cursor: not-allowed; }

.prowlarr-search-modal-status {
    padding: 0.55rem 1.1rem;
    font-size: var(--font-size-h5);
    border-bottom: 1px solid transparent;
    min-height: 1.3rem;
}
.prowlarr-search-modal-status:not(:empty) { border-bottom-color: var(--color-widget-content-border); }

.prowlarr-search-modal-results {
    flex: 1 1 auto;
    overflow: auto;
    padding: 0.5rem 0.6rem 0.6rem;
}
.prowlarr-search-empty {
    text-align: center;
    padding: 2rem 0;
}

.prowlarr-search-results-table { display: flex; flex-direction: column; gap: 0; }
.prowlarr-search-results-head,
.prowlarr-search-result-row {
    display: grid;
    grid-template-columns: 1.6rem minmax(0, 1fr) 4rem 3rem 3rem 5rem;
    align-items: center;
    gap: 0.6rem;
    padding: 0.55rem 0.6rem;
}
.prowlarr-search-results-head {
    position: sticky;
    top: 0;
    background: var(--color-widget-background);
    border-bottom: 1px solid var(--color-widget-content-border);
    z-index: 1;
}
.prowlarr-search-results-head-cell { font-size: var(--font-size-h5); }
.prowlarr-search-sort-col {
    background: transparent;
    border: none;
    color: inherit;
    cursor: pointer;
    padding: 0;
    font: inherit;
    text-align: left;
    display: inline-flex;
    align-items: center;
    gap: 0.2rem;
}
.prowlarr-search-sort-col:hover { color: var(--color-text-highlight); }
.prowlarr-search-sort-tone-seed { color: var(--color-positive); }
.prowlarr-search-sort-tone-leech { color: var(--color-negative); }
.prowlarr-search-sort-arrow { font-size: 0.85em; opacity: 0.85; }

.prowlarr-search-result-row {
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    transition: background 0.12s ease;
}
.prowlarr-search-result-row:hover { background: rgba(255, 255, 255, 0.03); }
.prowlarr-search-result-row .prowlarr-search-row-check {
    width: 1.05rem;
    height: 1.05rem;
    accent-color: var(--color-primary);
    cursor: pointer;
}
.prowlarr-search-result-main { min-width: 0; display: flex; flex-direction: column; gap: 0.15rem; }
.prowlarr-search-result-title {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.prowlarr-search-result-meta { font-size: var(--font-size-h5); }

.prowlarr-search-result-num,
.prowlarr-search-result-age { text-align: right; font-variant-numeric: tabular-nums; }
.prowlarr-search-result-seed { color: var(--color-positive); }
.prowlarr-search-result-leech { color: var(--color-negative); }

.prowlarr-search-result-actions { display: inline-flex; justify-content: flex-end; gap: 0.4rem; }
.prowlarr-search-result-link {
    padding: 0.2rem 0.55rem;
    border: 1px solid var(--color-widget-content-border);
    border-radius: 100px;
    color: var(--color-text-highlight);
    background: var(--color-background);
    text-decoration: none;
    font-size: var(--font-size-h5);
    transition: background 0.15s ease, color 0.15s ease;
}
.prowlarr-search-result-link:hover { background: var(--color-primary); color: var(--color-background); }

.prowlarr-search-modal-foot {
    padding: 0.7rem 1.1rem;
    border-top: 1px solid var(--color-widget-content-border);
    display: flex;
    justify-content: flex-end;
}
.prowlarr-search-modal-grab {
    height: 2.4rem;
    padding: 0 1.2rem;
    border-radius: 100px;
    border: none;
    background: var(--color-primary);
    color: var(--color-background);
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.1s ease, opacity 0.15s ease;
}
.prowlarr-search-modal-grab:hover:not(:disabled) { transform: translateY(-1px); }
.prowlarr-search-modal-grab:disabled { opacity: 0.4; cursor: not-allowed; }

/* ── Sheet de choix de client de téléchargement ── */
.prowlarr-grab-sheet {
    position: absolute;
    inset: 0;
    display: none;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    align-items: flex-end;
    justify-content: center;
    padding: 1rem;
    z-index: 5;
}
.prowlarr-grab-sheet.is-open { display: flex; }
.prowlarr-grab-sheet-panel {
    width: min(420px, 100%);
    background: var(--color-widget-background);
    border: 1px solid var(--color-widget-content-border);
    border-radius: calc(var(--border-radius) * 1.5);
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.5);
    padding: 1rem 1rem 0.85rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    animation: prowlarr-sheet-rise 0.18s ease-out;
}
@keyframes prowlarr-sheet-rise {
    from { transform: translateY(15px); opacity: 0; }
    to   { transform: translateY(0);    opacity: 1; }
}
.prowlarr-grab-sheet-title { font-weight: 600; color: var(--color-text-highlight); }
.prowlarr-grab-sheet-sub { font-size: var(--font-size-h5); }
.prowlarr-grab-sheet-list { display: flex; flex-direction: column; gap: 0.45rem; max-height: 50vh; overflow: auto; }
.prowlarr-grab-sheet-choice {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.15rem;
    text-align: left;
    padding: 0.65rem 0.85rem;
    background: var(--color-background);
    border: 1px solid var(--color-widget-content-border);
    border-radius: var(--border-radius);
    color: var(--color-text-highlight);
    cursor: pointer;
    transition: border-color 0.15s ease, background 0.15s ease, transform 0.1s ease;
}
.prowlarr-grab-sheet-choice:hover { border-color: var(--color-primary); transform: translateY(-1px); }
.prowlarr-grab-sheet-choice-title { font-weight: 600; }
.prowlarr-grab-sheet-choice-sub { font-size: var(--font-size-h5); text-transform: capitalize; }
.prowlarr-grab-sheet-cancel {
    align-self: flex-end;
    height: 2.2rem;
    padding: 0 1rem;
    border-radius: 100px;
    border: 1px solid var(--color-widget-content-border);
    background: transparent;
    color: var(--color-text-highlight);
    cursor: pointer;
}
.prowlarr-grab-sheet-cancel:hover { background: rgba(255, 255, 255, 0.05); }

/* ── Adaptation mobile ── */
@media (max-width: 720px) {
    .prowlarr-search-modal { padding: 0; }
    .prowlarr-search-modal-dialog { max-height: 100vh; height: 100vh; border-radius: 0; }
    .prowlarr-search-results-head,
    .prowlarr-search-result-row {
        grid-template-columns: 1.4rem minmax(0, 1fr) 3.5rem 2.6rem 2.6rem;
    }
    .prowlarr-search-results-head-actions,
    .prowlarr-search-result-actions { display: none; }
}

/* ════════════════════════════════════════════════════════════════
   Widget Hellcase — v2 « Wallet »
   Layout : Hero split (total + anneau SVG) · stats glass ·
            cases en chips · status bar compacte · footer minimal
   Palette : saumon-orangé sur fond sombre
   ════════════════════════════════════════════════════════════════ */
.section-hellcase-rewards {
    --hc-accent: 22 95% 65%;
    --hc-accent-strong: 18 95% 60%;
    --hc-accent-text: 22 90% 84%;
    --hc-ok: 142 60% 55%;
    --hc-ko: 355 75% 62%;
    --hc-ring: 50px;
    --hc-ring-stroke: 6px;
}
.section-hellcase-rewards .widget-content { padding: 0.25rem 0; }

.hc-card {
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
}

/* ── HERO « bank card » ────────────────────────────────────── */
.hc-hero {
    position: relative;
    overflow: hidden;
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.1rem 0.95rem;
    background:
        linear-gradient(135deg,
            hsl(var(--hc-accent) / 0.18) 0%,
            hsl(var(--hc-accent-strong) / 0.06) 50%,
            transparent 100%),
        linear-gradient(180deg,
            rgba(255, 255, 255, 0.025) 0%,
            rgba(255, 255, 255, 0) 100%);
    border: 1px solid hsl(var(--hc-accent) / 0.28);
    border-radius: 14px;
    box-shadow:
        inset 0 1px 0 hsl(var(--hc-accent) / 0.20),
        inset 0 -1px 0 rgba(0, 0, 0, 0.20),
        0 12px 28px -16px hsl(var(--hc-accent) / 0.55);
}
.hc-hero::before {
    content: '';
    position: absolute;
    top: -45%;
    left: -10%;
    width: 60%;
    height: 200%;
    background: linear-gradient(115deg,
        transparent 30%,
        rgba(255, 255, 255, 0.05) 48%,
        rgba(255, 255, 255, 0.10) 50%,
        rgba(255, 255, 255, 0.05) 52%,
        transparent 70%);
    transform: rotate(0deg);
    pointer-events: none;
}
.hc-hero-brand {
    position: absolute;
    top: 0.5rem;
    right: 0.85rem;
    font-size: 0.6rem;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: hsl(var(--hc-accent-text) / 0.55);
    font-weight: 600;
    z-index: 1;
}

.hc-hero-main {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    min-width: 0;
}
.hc-hero-kicker {
    margin: 0;
    font-size: 0.62rem;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: hsl(var(--hc-accent-text) / 0.7);
    font-weight: 600;
}
.hc-hero-sum {
    margin: 0.05rem 0 0;
    font-size: 2.1rem;
    font-weight: 700;
    line-height: 1;
    letter-spacing: -0.03em;
    color: var(--color-text-highlight);
    display: inline-flex;
    align-items: baseline;
    gap: 0.2rem;
    text-shadow: 0 2px 14px hsl(var(--hc-accent) / 0.25);
}
.hc-hero-curr {
    font-size: 1rem;
    font-weight: 500;
    color: hsl(var(--hc-accent-text) / 0.9);
}
.hc-hero-breakdown {
    margin-top: 0.45rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem 0.7rem;
    font-size: 0.7rem;
    color: var(--color-text-subdue);
}
.hc-hero-breakdown span strong {
    color: var(--color-text-highlight);
    font-weight: 600;
    font-variant-numeric: tabular-nums;
}
.hc-hero-breakdown-sep {
    opacity: 0.4;
}

/* ── Anneau de progression SVG ───────────────────────────────── */
.hc-ring {
    position: relative;
    z-index: 1;
    width: var(--hc-ring);
    height: var(--hc-ring);
    flex: 0 0 auto;
}
.hc-ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.hc-ring-track {
    fill: none;
    stroke: rgba(255, 255, 255, 0.08);
    stroke-width: var(--hc-ring-stroke);
}
.hc-ring-progress {
    fill: none;
    stroke: url(#hcRingGrad);
    stroke-width: var(--hc-ring-stroke);
    stroke-linecap: round;
    transition: stroke-dashoffset 0.6s ease;
    filter: drop-shadow(0 0 4px hsl(var(--hc-accent) / 0.55));
}
.hc-ring-text {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-variant-numeric: tabular-nums;
    line-height: 1;
}
.hc-ring-num {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--color-text-highlight);
}
.hc-ring-label {
    margin-top: 0.15rem;
    font-size: 0.55rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: hsl(var(--hc-accent-text) / 0.7);
}

/* ── Cases (chips minimalistes) ─────────────────────────────── */
.hc-cases-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.4rem;
}
.hc-cases-title {
    font-size: 0.62rem;
    text-transform: uppercase;
    letter-spacing: 0.16em;
    color: var(--color-text-subdue);
    font-weight: 600;
    margin-right: 0.15rem;
}
.hc-case {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.3rem 0.65rem 0.3rem 0.55rem;
    border-radius: 8px;
    font-size: 0.74rem;
    font-weight: 500;
    border: 1px solid transparent;
    transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease;
    line-height: 1;
}
.hc-case:hover { transform: translateY(-1px); }
.hc-case-mark {
    width: 0.95rem;
    height: 0.95rem;
    border-radius: 4px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    font-size: 0.65rem;
    font-weight: 800;
}
.hc-case--open {
    background:
        linear-gradient(180deg,
            hsl(var(--hc-ok) / 0.18) 0%,
            hsl(var(--hc-ok) / 0.08) 100%);
    border-color: hsl(var(--hc-ok) / 0.40);
    color: hsl(var(--hc-ok) / 0.96);
}
.hc-case--open .hc-case-mark {
    background: hsl(var(--hc-ok));
    color: #08210e;
    box-shadow: 0 0 8px hsl(var(--hc-ok) / 0.55);
}
.hc-case--skip {
    background: rgba(255, 255, 255, 0.025);
    border-color: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.45);
}
.hc-case--skip .hc-case-mark {
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.5);
}
.hc-case--skip .hc-case-name {
    text-decoration: line-through;
    text-decoration-color: rgba(255, 255, 255, 0.25);
}

/* ── Status bar (ligne compacte) ────────────────────────────── */
.hc-statusbar {
    display: flex;
    flex-wrap: wrap;
    align-items: stretch;
    gap: 0;
    padding: 0.05rem;
    background: rgba(255, 255, 255, 0.025);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 10px;
    overflow: hidden;
}
.hc-status {
    flex: 1 1 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    padding: 0.45rem 0.55rem;
    font-size: 0.72rem;
    color: var(--color-text-highlight);
    border-radius: 7px;
    transition: background 0.15s ease;
    position: relative;
    min-width: 0;
}
.hc-status + .hc-status::before {
    content: '';
    position: absolute;
    left: 0;
    top: 20%;
    height: 60%;
    width: 1px;
    background: rgba(255, 255, 255, 0.06);
}
.hc-status:hover { background: rgba(255, 255, 255, 0.03); }
.hc-status-dot {
    width: 0.55rem;
    height: 0.55rem;
    border-radius: 50%;
    flex: 0 0 auto;
    position: relative;
}
.hc-status-dot::after {
    content: '';
    position: absolute;
    inset: -2px;
    border-radius: 50%;
    background: inherit;
    opacity: 0.45;
    filter: blur(4px);
    z-index: -1;
}
.hc-status--ok .hc-status-dot { background: hsl(var(--hc-ok)); }
.hc-status--ko .hc-status-dot { background: hsl(var(--hc-ko)); }
.hc-status-label {
    flex: 0 1 auto;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-weight: 500;
}
.hc-status-tag {
    margin-left: 0.05rem;
    font-size: 0.6rem;
    letter-spacing: 0.08em;
    color: var(--color-text-subdue);
    font-variant-numeric: tabular-nums;
}

/* ── Footer ultra-compact ────────────────────────────────────── */
.hc-foot {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.7rem;
    color: var(--color-text-subdue);
    padding: 0 0.1rem;
}
.hc-foot-time {
    font-variant-numeric: tabular-nums;
    color: var(--color-text-highlight);
    font-weight: 500;
}
.hc-foot-clock {
    width: 0.85rem;
    height: 0.85rem;
    opacity: 0.55;
    flex: 0 0 auto;
}
.hc-foot-pill {
    margin-left: auto;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.2rem 0.65rem;
    border-radius: 100px;
    font-size: 0.62rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    background: hsl(var(--hc-ok) / 0.13);
    border: 1px solid hsl(var(--hc-ok) / 0.35);
    color: hsl(var(--hc-ok) / 0.96);
}
.hc-foot-pill::before {
    content: '';
    width: 0.35rem;
    height: 0.35rem;
    border-radius: 50%;
    background: currentColor;
    box-shadow: 0 0 6px currentColor;
    animation: hc-pulse 2.4s ease-in-out infinite;
}
.hc-foot-pill--ko {
    background: hsl(var(--hc-ko) / 0.13);
    border-color: hsl(var(--hc-ko) / 0.35);
    color: hsl(var(--hc-ko) / 0.96);
}
@keyframes hc-pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50%      { opacity: 0.5; transform: scale(0.85); }
}

/* ── Empty / error state ─────────────────────────────────────── */
.hc-error {
    padding: 0.85rem 1rem;
    border-radius: 10px;
    background: hsl(var(--hc-ko) / 0.08);
    border: 1px solid hsl(var(--hc-ko) / 0.30);
    color: hsl(var(--hc-ko) / 0.92);
    font-size: 0.8rem;
}
.hc-error-path {
    margin-top: 0.35rem;
    font-size: 0.68rem;
    color: var(--color-text-subdue);
    word-break: break-all;
}

/* ════════════════════════════════════════════════════════════════
   Widget Vitality — Matches à venir
   Palette : jaune saffron + noir (couleurs Team Vitality)
   ════════════════════════════════════════════════════════════════ */
.section-vitality {
    --vit-yellow: 47 100% 55%;
    --vit-yellow-strong: 44 100% 50%;
    --vit-yellow-text: 47 100% 78%;
    --vit-ink: 0 0% 6%;
}
.section-vitality .widget-content { padding: 0.25rem 0; }

.vit-list {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

/* ── Match card ─────────────────────────────────────────────── */
.vit-match {
    position: relative;
    display: block;
    text-decoration: none;
    color: inherit;
    padding: 0.75rem 0.85rem 0.7rem 1rem;
    border-radius: 10px;
    background:
        linear-gradient(115deg,
            hsl(var(--vit-yellow) / 0.10) 0%,
            hsl(var(--vit-yellow) / 0.025) 35%,
            transparent 80%),
        linear-gradient(180deg,
            rgba(255, 255, 255, 0.02) 0%,
            rgba(0, 0, 0, 0.10) 100%);
    border: 1px solid hsl(var(--vit-yellow) / 0.22);
    overflow: hidden;
    transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.2s ease;
}
.vit-match::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(180deg,
        hsl(var(--vit-yellow)) 0%,
        hsl(var(--vit-yellow-strong)) 100%);
    box-shadow: 0 0 12px hsl(var(--vit-yellow) / 0.5);
}
.vit-match::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 100% 0%, hsl(var(--vit-yellow) / 0.12), transparent 55%);
    pointer-events: none;
    opacity: 0.6;
    transition: opacity 0.2s ease;
}
.vit-match:hover {
    transform: translateY(-1px);
    border-color: hsl(var(--vit-yellow) / 0.45);
    box-shadow:
        0 8px 24px -14px hsl(var(--vit-yellow) / 0.55),
        inset 0 1px 0 hsl(var(--vit-yellow) / 0.18);
}
.vit-match:hover::after { opacity: 1; }

.vit-match-teams {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    align-items: center;
    gap: 0.55rem;
    margin-bottom: 0.55rem;
    position: relative;
    z-index: 1;
}
.vit-team {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    min-width: 0;
}
.vit-team--away {
    flex-direction: row-reverse;
    text-align: right;
}
.vit-team-logo {
    width: 30px;
    height: 30px;
    object-fit: contain;
    flex: 0 0 auto;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.4));
}
.vit-team-name {
    font-size: 0.92rem;
    font-weight: 600;
    color: var(--color-text-highlight);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0;
}
.vit-team--home .vit-team-name {
    color: hsl(var(--vit-yellow));
    font-weight: 700;
    text-shadow: 0 0 12px hsl(var(--vit-yellow) / 0.35);
}

.vit-vs {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.6rem;
    height: 1.4rem;
    padding: 0 0.4rem;
    border-radius: 100px;
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid hsl(var(--vit-yellow) / 0.25);
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: hsl(var(--vit-yellow-text) / 0.82);
}

/* ── Footer (event + countdown) ─────────────────────────────── */
.vit-match-foot {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.72rem;
    color: var(--color-text-subdue);
    position: relative;
    z-index: 1;
    flex-wrap: wrap;
}
.vit-event {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.18rem 0.55rem;
    border-radius: 100px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--color-text-highlight);
    font-size: 0.68rem;
    font-weight: 500;
    max-width: 100%;
    overflow: hidden;
}
.vit-event-icon {
    width: 0.75rem;
    height: 0.75rem;
    color: hsl(var(--vit-yellow));
    flex: 0 0 auto;
}
.vit-event-name {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.vit-time {
    margin-left: auto;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    color: hsl(var(--vit-yellow));
    font-weight: 600;
    font-size: 0.74rem;
    font-variant-numeric: tabular-nums;
    text-shadow: 0 0 10px hsl(var(--vit-yellow) / 0.25);
}
.vit-time-icon {
    width: 0.78rem;
    height: 0.78rem;
    flex: 0 0 auto;
}

/* ── Empty state ────────────────────────────────────────────── */
.vit-empty {
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    padding: 1.4rem 1rem 1.5rem;
    border-radius: 10px;
    background:
        radial-gradient(circle at 50% 0%, hsl(var(--vit-yellow) / 0.08), transparent 65%),
        rgba(255, 255, 255, 0.015);
    border: 1px dashed rgba(255, 255, 255, 0.08);
    text-align: center;
}
.vit-empty-logo {
    width: 38px;
    height: 38px;
    color: hsl(var(--vit-yellow));
    opacity: 0.85;
    filter: drop-shadow(0 0 14px hsl(var(--vit-yellow) / 0.45));
}
.vit-empty-title {
    margin: 0.25rem 0 0;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--color-text-highlight);
    letter-spacing: 0.02em;
}
.vit-empty-sub {
    margin: 0;
    font-size: 0.7rem;
    color: var(--color-text-subdue);
    letter-spacing: 0.05em;
}
