/* ===========================================================
   LIVE AUCTION HERO BANNER
   Same technique as players-hero/fixtures-hero — dual-layer gradient +
   stadium image, full-bleed, with the page header floating inside it.
===========================================================*/

.live-auction-hero{
    position:relative;
    overflow:hidden;
    padding:var(--space-6) 0 var(--space-5);

    background-image:
        linear-gradient(90deg, rgba(11,18,32,0.95) 20%, rgba(11,18,32,0.6) 55%, rgba(11,18,32,0.35) 100%),
        url("../images/hero/Live\ auction\ banner.webp");
    background-repeat:no-repeat;
    background-size:100% 100%, cover;
    background-position:center, center 40%;
    background-color:var(--color-bg);
}

/* ===========================================================
   LIVE AUCTION — PAGE HEADER
===========================================================*/

.auction-header{
    display:flex;
    align-items:center;
    justify-content:space-between;
    flex-wrap:wrap;
    gap:var(--space-4);

    margin:var(--space-5) 0;
}

.auction-title h1{
    font-size:1.75rem;
    margin-bottom:4px;
}

.auction-round{
    display:flex;
    align-items:center;
    gap:6px;
    font-size:var(--fs-small);
    color:var(--color-text-muted);
}

.auction-round .badge-dot{
    color:var(--color-gold);
}

.auction-header-actions{
    display:flex;
    align-items:center;
    gap:var(--space-3);
}

/* Timer widget */

.auction-timer{
    display:flex;
    align-items:center;
    gap:var(--space-3);

    padding:var(--space-3) var(--space-4);
    border-radius:var(--radius-md);

    background:var(--color-surface);
    border:1px solid var(--color-border);
}

.auction-timer-label{
    display:flex;
    flex-direction:column;
    align-items:center;
    gap:2px;
    color:var(--color-purple);
    font-size:var(--fs-tiny);
    font-weight:var(--fw-semibold);
    text-transform:uppercase;
}

.auction-timer-units{
    display:flex;
    gap:var(--space-3);
}

.auction-timer-unit{
    text-align:center;
}

.auction-timer-unit .num{
    font-family:var(--font-mono);
    font-size:1.25rem;
    font-weight:var(--fw-bold);
    color:var(--color-gold);
    display:block;
}

.auction-timer-unit .label{
    font-size:9px;
    color:var(--color-text-muted);
    text-transform:uppercase;
}

/* ===========================================================
   3-COLUMN LAYOUT
===========================================================*/

.auction-layout{
    display:grid;
    grid-template-columns:300px 1fr 340px;
    gap:var(--space-5);
    align-items:start;
}

/* ===========================================================
   TEAMS IN AUCTION (left column)
===========================================================*/

.team-list-header{
    display:flex;
    align-items:center;
    justify-content:space-between;
    margin-bottom:var(--space-4);

    font-size:var(--fs-tiny);
    font-weight:var(--fw-semibold);
    text-transform:uppercase;
    letter-spacing:0.04em;
    color:var(--color-text-muted);
}

.team-auction-row{
    display:flex;
    flex-direction:column;
    gap:var(--space-2);

    padding:var(--space-3);
    border-radius:var(--radius-md);
    border:1px solid var(--color-border);
    margin-bottom:var(--space-3);

    position:relative;
}

.team-auction-row-top{
    display:flex;
    align-items:center;
    gap:var(--space-3);
}

.team-auction-row.highest-bidder{
    border-color:var(--color-gold);
    background:rgba(232,170,61,0.06);
}

.team-auction-row .crest-badge-sm{
    width:40px;
    height:40px;
    flex-shrink:0;
}

.team-auction-info{
    flex:1;
    min-width:0;
}

.team-auction-name-row{
    display:flex;
    align-items:center;
    gap:6px;
    margin-bottom:2px;
}

.team-auction-name{
    font-size:var(--fs-small);
    font-weight:var(--fw-semibold);
}

/* Small green "online" dot — sits floating at the card's top-right corner
   (per design), not inline next to the team name. */
.online-dot{
    position:absolute;
    top:var(--space-3);
    right:var(--space-3);
    width:8px;
    height:8px;
    border-radius:50%;
    background:var(--color-success);
    box-shadow:0 0 6px rgba(34,197,94,0.6);
    flex-shrink:0;
}

.team-auction-bid{
    font-family:var(--font-mono);
    font-weight:var(--fw-bold);
    color:var(--color-text);
    font-size:1.35rem;
}

.team-auction-purse{
    text-align:right;
    font-size:var(--fs-tiny);
    color:var(--color-text-muted);
    flex-shrink:0;
}

/* ===========================================================
   CURRENT PLAYER AUCTION CARD (center)
===========================================================*/

.player-auction-card{
    position:relative;
    overflow:hidden;

    border-radius:var(--radius-lg);
    border:1px solid var(--color-purple);
    box-shadow:0 0 40px rgba(124,92,252,0.15);

    background:linear-gradient(160deg, rgba(124,92,252,0.10), var(--color-surface) 60%);
    padding:var(--space-5);
}

.sold-ribbon{
    position:absolute;
    top:18px;
    left:-38px;
    width:150px;

    transform:rotate(-45deg);
    text-align:center;

    background:var(--color-gold);
    color:#1A1305;

    font-size:var(--fs-tiny);
    font-weight:var(--fw-bold);
    letter-spacing:0.06em;
    padding:4px 0;

    z-index:2;
}

.player-auction-body{
    display:flex;
    gap:var(--space-5);
    align-items:stretch;
}

.player-silhouette{
    width:260px;
    flex-shrink:0;
    border-radius:var(--radius-md);

    /* Richer, more atmospheric glow to match the original design —
       a brighter purple core plus a cooler blue undertone, instead of
       one flat radial fade. Stretches to match the details column's
       height (align-items:stretch above) instead of a fixed 220px. */
    background:
        radial-gradient(circle at 50% 30%, rgba(168,132,255,0.55), transparent 55%),
        radial-gradient(circle at 60% 65%, rgba(59,130,246,0.25), transparent 60%),
        linear-gradient(180deg, #1A1530, #0B1220);

    display:flex;
    align-items:flex-end;
    justify-content:center;
    overflow:hidden;
}

.player-silhouette svg{
    width:70%;
    opacity:0.85;
}

.player-silhouette img{
    width:100%;
    height:100%;
    object-fit:cover;
    object-position:top center;
}

.player-auction-details{
    flex:1;
    min-width:0;
}

.player-name-row{
    display:flex;
    align-items:center;
    gap:8px;
    margin-bottom:2px;
}

.player-name-row h2{
    font-size:1.5rem;
}

.player-role{
    color:var(--color-text-muted);
    font-size:var(--fs-small);
    margin-bottom:var(--space-4);
}

.player-info-grid{
    display:grid;
    grid-template-columns:repeat(4, 1fr);
    gap:var(--space-3);
    margin-bottom:var(--space-4);
}

.player-info-grid .label{
    font-size:9px;
    color:var(--color-text-muted);
    text-transform:uppercase;
    letter-spacing:0.04em;
    display:block;
    margin-bottom:2px;
}

.player-info-grid .value{
    font-size:var(--fs-small);
    font-weight:var(--fw-semibold);
}

/* Current bid box */

.current-bid-box{
    display:flex;
    align-items:center;
    justify-content:space-between;

    padding:var(--space-4);
    border-radius:var(--radius-md);
    border:1px solid var(--color-gold);
    background:rgba(232,170,61,0.08);

    margin-bottom:var(--space-4);
}

.current-bid-label{
    font-size:var(--fs-tiny);
    color:var(--color-gold);
    text-transform:uppercase;
    letter-spacing:0.04em;
    margin-bottom:4px;
}

.current-bid-amount{
    font-family:var(--font-mono);
    font-size:2rem;
    font-weight:var(--fw-bold);
    color:var(--color-gold);
}

.sold-to-row{
    display:flex;
    align-items:center;
    gap:var(--space-3);
}

/* Bug fix: .crest-badge normally has margin:0 auto (for centering it in a
   column layout elsewhere on the site). Reused here inside a left-to-right
   row, that auto margin was pushing the crest toward the middle and
   shoving the team name off to the right. Cancel it out in this context. */
.sold-to-row .crest-badge{
    margin:0;
    flex-shrink:0;
}

/* ===========================================================
   BID TIMER (per-player countdown, resets on each new bid)
===========================================================*/

.bid-timer-box{
    display:flex;
    align-items:center;
    justify-content:space-between;

    padding:var(--space-3) var(--space-4);
    border-radius:var(--radius-md);
    border:1px solid var(--color-border);
    background:var(--color-surface-alt);

    margin-bottom:var(--space-4);
}

.bid-timer-label{
    font-size:var(--fs-tiny);
    color:var(--color-text-muted);
    text-transform:uppercase;
    letter-spacing:0.04em;
}

.bid-timer-value{
    font-family:var(--font-mono);
    font-size:2rem;
    font-weight:var(--fw-bold);
    color:var(--color-success);
    transition:color var(--transition-fast);
}

.bid-timer-value.warning{
    color:var(--color-warning);
}

.bid-timer-value.danger{
    color:var(--color-danger);
    animation:pulse-live 0.6s ease-in-out infinite;
}

.bid-btn{
    padding:8px 14px;
    border-radius:var(--radius-sm);
    width:100%;
    text-align:center;

    background:var(--color-purple);
    color:#fff;

    font-size:var(--fs-tiny);
    font-weight:var(--fw-semibold);
    text-transform:uppercase;

    flex-shrink:0;
}

.bid-btn:hover{
    background:var(--color-purple-hover);
}

.bid-btn:disabled{
    opacity:0.4;
    cursor:not-allowed;
}

.unsold-ribbon{
    background:var(--color-danger) !important;
    color:#fff !important;
}

.sold-to-label{
    font-size:var(--fs-tiny);
    color:var(--color-text-muted);
    text-transform:uppercase;
    display:block;
    margin-bottom:2px;
}

/* Next player bar */

.next-player-bar{
    display:flex;
    align-items:center;
    justify-content:space-between;
    flex-wrap:wrap;
    gap:var(--space-3);

    padding:var(--space-4);
    margin-top:var(--space-5);

    border-radius:var(--radius-md);
    border:1px solid var(--color-border);
    background:var(--color-surface);
}

.next-player-label{
    font-size:var(--fs-tiny);
    color:var(--color-text-muted);
    text-transform:uppercase;
    letter-spacing:0.04em;
    margin-right:var(--space-2);
}

.next-player-btn{
    width:32px;
    height:32px;
    border-radius:50%;

    display:flex;
    align-items:center;
    justify-content:center;

    background:var(--color-surface-alt);
    border:1px solid var(--color-border);
    color:var(--color-text);
}

.auto-next-toggle{
    display:flex;
    align-items:center;
    gap:var(--space-2);
    font-size:var(--fs-small);
}

.toggle-pill{
    width:38px;
    height:20px;
    border-radius:var(--radius-pill);
    background:var(--color-success);
    position:relative;
}

.toggle-pill::after{
    content:"";
    position:absolute;
    top:2px;
    right:2px;
    width:16px;
    height:16px;
    border-radius:50%;
    background:#fff;
}

/* Auction stats strip */

.auction-stats-strip{
    display:grid;
    grid-template-columns:repeat(5, 1fr);
    gap:var(--space-3);
    margin-top:var(--space-5);

    padding:var(--space-4);
    border-radius:var(--radius-md);
    background:var(--color-surface);
    border:1px solid var(--color-border);
}

.auction-stat{
    text-align:center;
}

.auction-stat .stat-label{
    font-size:9px;
    color:var(--color-purple);
    text-transform:uppercase;
    letter-spacing:0.04em;
    display:block;
    margin-bottom:4px;
}

.auction-stat .stat-value{
    font-size:1.15rem;
    font-weight:var(--fw-bold);
    color:var(--color-text);
}

/* ===========================================================
   BID HISTORY (right column)
===========================================================*/

.bid-history-list{
    position:relative;
    padding-left:var(--space-4);

    /* Safety net alongside the JS row-cap fix: even if the list ever grows
       past what fits, it scrolls inside the card instead of stretching the
       whole page layout. */
    max-height:520px;
    overflow-y:auto;
}

.bid-history-list::before{
    content:"";
    position:absolute;
    left:5px;
    top:6px;
    bottom:6px;
    width:1px;
    background:var(--color-border);
}

.bid-history-item{
    position:relative;
    display:flex;
    align-items:center;
    gap:var(--space-2);
    padding-bottom:var(--space-4);
}

.bid-history-item::before{
    content:"";
    position:absolute;
    left:-15px;
    top:6px;
    width:8px;
    height:8px;
    border-radius:50%;
    background:var(--color-purple);
    border:2px solid var(--color-bg);
}

.bid-history-time{
    font-size:9px;
    color:var(--color-text-faint);
    width:56px;
    flex-shrink:0;
}

.bid-history-team{
    flex:1;
    min-width:0;
    font-size:var(--fs-small);
    font-weight:var(--fw-medium);
    display:flex;
    align-items:center;
    gap:6px;
}

.bid-history-amount{
    font-family:var(--font-mono);
    font-size:var(--fs-small);
    font-weight:var(--fw-semibold);
    color:var(--color-gold);
    flex-shrink:0;
}

/* ===========================================================
   BOTTOM LIVE TICKER BAR
===========================================================*/

.auction-ticker-bar{
    display:flex;
    align-items:center;
    justify-content:space-between;
    flex-wrap:wrap;
    gap:var(--space-4);

    padding:var(--space-4) var(--space-5);
    margin:var(--space-6) 0;

    border-radius:var(--radius-md);
    border:1px solid var(--color-purple);
    background:rgba(124,92,252,0.06);
}

.ticker-message{
    display:flex;
    align-items:center;
    gap:var(--space-3);
    font-size:var(--fs-small);
}

.ticker-meta{
    display:flex;
    align-items:center;
    gap:var(--space-5);
    font-size:var(--fs-small);
    color:var(--color-text-muted);
}

/* ===========================================================
   RESPONSIVE
===========================================================*/

@media (max-width: 1300px){

    .auction-layout{
        grid-template-columns:1fr;
    }

    .player-auction-body{
        flex-direction:column;
    }

    .player-silhouette{
        width:100%;
        height:200px;
    }

}

@media (max-width: 768px){

    .player-info-grid{
        grid-template-columns:repeat(2, 1fr);
    }

    .auction-stats-strip{
        grid-template-columns:repeat(2, 1fr);
        gap:var(--space-4);
    }

    .auction-header{
        flex-direction:column;
        align-items:flex-start;
    }

    .auction-header-actions{
        flex-wrap:wrap;
        width:100%;
    }

    .auction-header-actions .btn{
        flex:1 1 auto;
        justify-content:center;
    }

}