/* ==========================================================================
   Watchlist buttons (lib/watchlist.php, js/watchlist.js) and the Auction bar
   desktop row (auction-bar.php).
   ========================================================================== */

:root {
    --tc-watch-on: var(--main-color, #FFBE35); /* filled heart */
    --tc-bar-rule: rgba(255, 255, 255, 0.22);
}

/* ---- Watch button: shared ------------------------------------------------ */

.tc-watch {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin: 0;
    padding: 0;
    border: 0;
    background: none;
    cursor: pointer;
    font: inherit;
    line-height: 1;
    -webkit-tap-highlight-color: transparent;
}

.tc-watch__icon {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linejoin: round;
    transition: transform 0.15s ease, fill 0.15s ease, stroke 0.15s ease;
}

.tc-watch[aria-pressed="true"] .tc-watch__icon {
    fill: var(--tc-watch-on);
    stroke: var(--tc-watch-on);
}

.tc-watch:active .tc-watch__icon {
    transform: scale(0.85);
}

/* No browser focus outline after a click; keyboard focus gets a ring instead. */
.tc-watch:focus,
.tc-watch:focus-visible {
    outline: none;
}

.tc-watch:focus-visible {
    box-shadow: 0 0 0 2px var(--main-color, #FFBE35);
}

.tc-watch__label--on,
.tc-watch[aria-pressed="true"] .tc-watch__label--off {
    display: none;
}

.tc-watch[aria-pressed="true"] .tc-watch__label--on {
    display: inline;
}

/* ---- Heart over an image (auction hero, widget cards) ------------------- */

.tc-hero,
.aswidget_img,
.auction_car_img {
    position: relative;
}

.tc-watch--heart {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 2;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.92);
    color: #333;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
}

.tc-watch--heart .tc-watch__icon {
    width: 20px;
    height: 20px;
}

.tc-watch--heart:hover {
    background: #fff;
}

.aswidget_img .tc-watch--heart,
.auction_car_img .tc-watch--heart {
    top: 8px;
    right: 8px;
    width: 34px;
    height: 34px;
}

.aswidget_img .tc-watch--heart .tc-watch__icon,
.auction_car_img .tc-watch--heart .tc-watch__icon {
    width: 17px;
    height: 17px;
}

/* ---- WATCH button in the Auction bar ------------------------------------ */

.tc-watch--bar {
    height: 40px;
    padding: 0 16px;
    border: 1px solid rgba(255, 255, 255, 0.7);
    border-radius: 4px;
    color: #fff;
    font-family: "Montserrat", sans-serif;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    white-space: nowrap;
}

.tc-watch--bar:hover {
    border-color: #fff;
    background: rgba(255, 255, 255, 0.08);
}

/* ---- First Look bar: WATCH beside REGISTER INTEREST ---------------------- */

/* Above the legacy .auctioncounter::before overlay, like the Auction bar. */
.lite_auction .tc-lite-actions {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 16px;
}

@media (max-width: 767px) {
    .lite_auction .tc-lite-actions {
        justify-content: center;
    }

    /* style.css gives every .btn2 margin: 10px !important. */
    .lite_auction .tc-lite-actions #reg_interest {
        margin-left: 0 !important;
        margin-right: 0 !important;
    }
}

/* ---- Mobile Auction bar (.auctionlivemobile) ----------------------------- */

/* Heart as a square outline button beside a solid SEE BIDDING button. Both
   sit above the legacy .auctioncounter::before overlay, as below. */
.auctionlivemobile .actm-right {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 8px;
}

.auctionlivemobile .tc-watch--bar {
    width: 36px;
    height: 36px;
    padding: 0;
}

.auctionlivemobile .tc-watch__label {
    display: none !important;
}

.auctionlivemobile .actm-right .history_bid.go_to_bidding_an {
    display: inline-flex;
    align-items: center;
    height: 36px;
    margin: 0;
    padding: 0 12px;
    border: 0;
    border-radius: 4px;
    background: var(--main-color, #FFBE35);
    color: #222;
    font-weight: 700;
    line-height: 1;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    white-space: nowrap;
}

.auctionlivemobile .actm-right .history_bid.go_to_bidding_an::before,
.auctionlivemobile .actm-right .history_bid.go_to_bidding_an::after {
    display: none;
}

/* ---- Auction bar desktop row --------------------------------------------- */

/* Stacked above the legacy .auctioncounter::before overlay (a transparent
   full-viewport layer), which otherwise swallows clicks on the buttons. */
.auctioncounter .row.tc-bar {
    position: relative;
    z-index: 1;
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: center;
    gap: 0;
    margin: 0;
    min-height: 60px;
    font-family: "Montserrat", sans-serif;
    color: #fff;
}

.tc-bar__kind {
    padding-right: 28px;
    color: var(--main-color, #FFBE35);
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    white-space: nowrap;
}

.tc-bar__stat {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
    padding: 0 28px;
    border-left: 1px solid var(--tc-bar-rule);
    white-space: nowrap;
}

.tc-bar__label {
    color: rgba(255, 255, 255, 0.75);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.08em;
    line-height: 1;
    text-transform: uppercase;
}

.auctioncounter .tc-bar #clockdiv.tc-bar__clock {
    display: flex;
    align-items: baseline;
    gap: 10px;
    padding: 0;
    text-align: left;
    white-space: nowrap;
}

.auctioncounter .tc-bar .tc-bar__clock .sq {
    display: inline-flex;
    align-items: baseline;
    width: auto;
}

.auctioncounter .tc-bar .tc-bar__clock .sq .bord,
.tc-bar__value .update_bid_amt {
    color: #fff;
    font-size: 21px;
    font-weight: 700;
    line-height: 1;
}

.auctioncounter .tc-bar .tc-bar__clock .sq .smalltext {
    margin-left: 1px;
    color: rgba(255, 255, 255, 0.8);
    font-size: 12px;
    font-weight: 400;
    line-height: 1;
    text-transform: none;
}

.tc-bar__value {
    display: flex;
    align-items: baseline;
    gap: 14px;
}

.auctioncounter .tc-bar .tc-bar__see {
    margin: 0;
    padding: 0;
    border: 0;
    color: #fff;
    font-size: 12px;
    font-weight: 600;
    line-height: 1;
    text-decoration: underline;
    text-underline-offset: 3px;
    text-transform: none;
}

.auctioncounter .tc-bar .tc-bar__see::before,
.auctioncounter .tc-bar .tc-bar__see::after {
    display: none;
}

.tc-bar__actions {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-left: auto;
    padding-left: 28px;
}

.auctioncounter .tc-bar .tc-bar__link {
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    white-space: nowrap;
}

.auctioncounter .tc-bar .tc-bar__cta {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    height: 40px;
    margin: 0;
    padding: 0 24px;
    border: 0;
    border-radius: 4px;
    background: var(--main-color, #FFBE35);
    color: #222;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.04em;
    line-height: 1;
    text-transform: uppercase;
    white-space: nowrap;
    cursor: pointer;
}

.auctioncounter .tc-bar .tc-bar__cta:hover {
    filter: brightness(1.06);
    color: #222;
}

.tc-bar__chevron {
    width: 18px;
    height: 18px;
    fill: #222;
    stroke: var(--main-color, #FFBE35);
}

.tc-bar__link:hover,
.tc-bar__see:hover {
    color: var(--main-color, #FFBE35);
}

@media (max-width: 1199px) {
    .tc-bar__kind {
        padding-right: 18px;
    }

    .tc-bar__stat {
        padding: 0 18px;
    }

    .tc-bar__actions {
        gap: 12px;
        padding-left: 18px;
    }

    .auctioncounter .tc-bar .tc-bar__cta {
        padding: 0 16px;
    }
}

/* Beats the legacy `.live_auction .row { display: block !important }` in
   style.css, which stacks the bar on tablets. Below 768px the row is hidden
   for .auctionlivemobile, so the override stops there. */
@media (min-width: 768px) and (max-width: 991px) {
    .auctioncounter .row.tc-bar {
        display: flex !important;
    }
}

@media (max-width: 991px) {
    .tc-bar__kind {
        display: none;
    }

    /* Tighter still so the logged-out row (Watch, Log in, Register to bid)
       fits a 768px tablet with a seven-figure bid. */
    .tc-bar__stat {
        padding: 0 14px;
    }

    .tc-bar__kind + .tc-bar__stat {
        border-left: 0;
        padding-left: 0;
    }

    .auctioncounter .tc-bar #clockdiv.tc-bar__clock {
        gap: 6px;
    }

    .auctioncounter .tc-bar .tc-bar__clock .sq .bord,
    .tc-bar__value .update_bid_amt {
        font-size: 18px;
    }

    .tc-bar__actions {
        padding-left: 14px;
    }

    .auctioncounter .tc-bar .tc-bar__cta {
        padding: 0 14px;
    }
}

/* ---- My Account dashboard: Watchlist (tc_watchlist_account_section_html) ---- */

/* The nav heart links to #watchlist: land below the sticky charcoal nav. */
.tc-watchlist {
    scroll-margin-top: 80px;
}

/* Rows share the dashboard's Draft Auctions / Live Listings layout. */
.tc-watchlist-row__image {
    position: relative;
}

.tc-watchlist-row__image img {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 4 / 3;
    object-fit: cover;
}

.tc-watchlist-row__image .tc-watch--heart {
    top: 4px;
    right: 19px; /* the column's 15px gutter + 4px */
    width: 28px;
    height: 28px;
}

.tc-watchlist-row__image .tc-watch--heart .tc-watch__icon {
    width: 14px;
    height: 14px;
}

/* Titles stay on one line, cut with an ellipsis. */
.tc-watchlist-row__details .title-hold {
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.tc-watchlist-row__glance,
.tc-watchlist-row__ends {
    margin: 0 0 6px;
    font-size: 13px;
    line-height: 1.4;
    color: #333;
    text-align: left; /* the account page justifies paragraphs */
}

.tc-watchlist-row__ends {
    margin-bottom: 0;
}

/* ---- Charcoal nav heart (tc_watchlist_nav_link) ---------------------------- */

/* .head_reg_btns a sets display: inline-block, which would stop the icon
   centring in its box. */
.tc-watch-nav,
.head_reg_btns a.tc-watch-nav {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px; /* same box as the nav's REGISTER / LOGIN / SIGN OUT links */
    margin-right: 6px;
    color: #fff;
    vertical-align: top;
}

.tc-watch-nav .tc-watch__icon {
    width: 22px;
    height: 22px;
}

/* Hover: main colour plus a ring drawn with box-shadow (no layout shift), in
   place of the nav's sliding underline (.head_reg_btns a::after /
   .new_menu_head a::before). */
.head_reg_btns a.tc-watch-nav,
.new_menu_head a.tc-watch-nav {
    border-radius: 4px;
    transition: color 0.2s ease, box-shadow 0.2s ease;
}

.head_reg_btns a.tc-watch-nav::after,
.new_menu_head a.tc-watch-nav::before {
    display: none !important;
}

.head_reg_btns a.tc-watch-nav:hover,
.head_reg_btns a.tc-watch-nav:focus-visible,
.new_menu_head a.tc-watch-nav:hover,
.new_menu_head a.tc-watch-nav:focus-visible {
    color: var(--main-color, #FFBE35);
    box-shadow: inset 0 0 0 1px var(--main-color, #FFBE35);
    outline: none;
}

.tc-watch-nav.is-watching .tc-watch__icon {
    fill: var(--tc-watch-on);
    stroke: var(--tc-watch-on);
}

.tc-watch-nav__count {
    position: absolute;
    top: 0;
    right: -2px;
    min-width: 16px;
    padding: 0 4px;
    border-radius: 8px;
    background: #fff;
    color: #333;
    font-size: 10px;
    font-weight: 700;
    line-height: 16px;
    text-align: center;
}

.tc-watch-nav__count:empty {
    display: none;
}
