/* ============================================================
   RCN Overrides — wins against Motors theme defaults
   ============================================================ */

body.rcn-theme .rcn-hero__title,
body.rcn-theme h1.rcn-hero__title {
    color: #fff !important;
    background: none !important;
    text-shadow: 0 2px 10px rgba(0,0,0,0.4) !important;
}
body.rcn-theme .rcn-hero__title-accent {
    color: transparent !important;
    background: linear-gradient(135deg, #DC2626 0%, #FCD34D 100%) !important;
    -webkit-background-clip: text !important;
    background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
}
body.rcn-theme .rcn-hero__subtitle { color: rgba(255,255,255,0.85) !important; }

body.rcn-theme .rcn-hero__tabs {
    background: #F1F5F9 !important;
    border-bottom: 1px solid #E2E8F0 !important;
}
body.rcn-theme .rcn-hero__tab {
    background: transparent !important;
    color: #64748B !important;
    border: none !important;
    border-bottom: 3px solid transparent !important;
    padding: 16px 12px !important;
    font-weight: 600 !important;
    text-transform: none !important;
}
body.rcn-theme .rcn-hero__tab svg { color: currentColor !important; }
body.rcn-theme .rcn-hero__tab:hover { background: rgba(220,38,38,0.04) !important; color: #0F172A !important; }
body.rcn-theme .rcn-hero__tab.active {
    background: #fff !important;
    color: #DC2626 !important;
    border-bottom-color: #DC2626 !important;
}

body.rcn-theme .rcn-listing-panel__title,
body.rcn-theme h1.rcn-listing-panel__title {
    font-size: 22px !important;
    line-height: 1.2 !important;
    font-weight: 800 !important;
    color: #0F172A !important;
    letter-spacing: -0.01em !important;
    text-transform: none !important;
    margin: 0 0 8px !important;
    padding: 0 !important;
    word-break: normal !important;
    word-wrap: normal !important;
}

/* === Gallery hero — arrows clickable === */
body.rcn-theme .rcn-gallery {
    background: #fff !important;
    border-radius: 14px !important;
    overflow: hidden !important;
}
body.rcn-theme .rcn-gallery__hero {
    aspect-ratio: 16 / 10 !important;
    background: #0F172A !important;
    position: relative !important;
    user-select: none;
    -webkit-user-select: none;
    touch-action: pan-y;
    cursor: zoom-in !important;
}
body.rcn-theme .rcn-gallery__hero img {
    width: 100% !important;
    height: 100% !important;
    object-fit: contain !important;
    max-width: none !important;
    pointer-events: none !important;
    user-select: none;
    -webkit-user-drag: none;
}
body.rcn-theme .rcn-gallery__nav,
body.rcn-theme .rcn-gallery__prev,
body.rcn-theme .rcn-gallery__next,
body.rcn-theme .rcn-gallery__expand {
    position: absolute !important;
    z-index: 50 !important;
    pointer-events: auto !important;
    background: rgba(220, 38, 38, .92) !important;
    color: #fff !important;
    border: none !important;
    border-radius: 50% !important;
    width: 44px !important;
    height: 44px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    cursor: pointer !important;
    transition: transform .15s, background .15s !important;
    box-shadow: 0 4px 14px rgba(0,0,0,.3) !important;
}
body.rcn-theme .rcn-gallery__nav svg,
body.rcn-theme .rcn-gallery__prev svg,
body.rcn-theme .rcn-gallery__next svg,
body.rcn-theme .rcn-gallery__expand svg,
body.rcn-theme .rcn-gallery__close svg {
    pointer-events: none !important;
}
body.rcn-theme .rcn-gallery__prev { left: 14px !important; top: 50% !important; transform: translateY(-50%) !important; }
body.rcn-theme .rcn-gallery__next { right: 14px !important; top: 50% !important; transform: translateY(-50%) !important; }
body.rcn-theme .rcn-gallery__expand {
    right: 14px !important;
    bottom: 14px !important;
    width: 38px !important;
    height: 38px !important;
    background: rgba(15, 23, 42, .82) !important;
}
body.rcn-theme .rcn-gallery__nav:hover {
    background: #b91c1c !important;
    transform: translateY(-50%) scale(1.06) !important;
}
body.rcn-theme .rcn-gallery__expand:hover {
    transform: scale(1.06) !important;
    background: #0F172A !important;
}
body.rcn-theme .rcn-gallery__counter {
    position: absolute !important;
    top: 14px !important;
    right: 14px !important;
    background: rgba(15, 23, 42, .82) !important;
    color: #fff !important;
    padding: 5px 12px !important;
    border-radius: 999px !important;
    font-size: 12.5px !important;
    font-weight: 700 !important;
    z-index: 50 !important;
    pointer-events: none !important;
}

body.rcn-theme .rcn-gallery__overlay {
    display: none !important;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.92);
    z-index: 9999;
    align-items: center;
    justify-content: center;
    padding: 40px;
}
body.rcn-theme .rcn-gallery__overlay.is-open {
    display: flex !important;
}
body.rcn-theme .rcn-gallery__overlay img {
    max-width: 90vw !important;
    max-height: 86vh !important;
    object-fit: contain !important;
    pointer-events: auto !important;
}
body.rcn-theme .rcn-gallery__close {
    position: absolute !important;
    top: 20px !important;
    right: 20px !important;
    background: rgba(255,255,255,.1) !important;
    color: #fff !important;
    border: none !important;
    width: 46px !important;
    height: 46px !important;
    border-radius: 50% !important;
    cursor: pointer !important;
    z-index: 10000 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}
body.rcn-theme .rcn-gallery__close:hover { background: rgba(255,255,255,.22) !important; }

body.rcn-theme .rcn-gallery__thumbs {
    display: flex !important;
    gap: 8px !important;
    padding: 10px 12px !important;
    overflow-x: auto !important;
    background: #fff !important;
}
body.rcn-theme .rcn-gallery__thumb {
    flex: 0 0 auto !important;
    width: 84px !important;
    height: 60px !important;
    border-radius: 8px !important;
    overflow: hidden !important;
    border: 2px solid transparent !important;
    padding: 0 !important;
    background: #f1f5f9 !important;
    cursor: pointer !important;
    transition: all .15s !important;
}
body.rcn-theme .rcn-gallery__thumb img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    display: block !important;
    pointer-events: none;
}
body.rcn-theme .rcn-gallery__thumb.active {
    border-color: #DC2626 !important;
    box-shadow: 0 0 0 2px rgba(220,38,38,.18) !important;
}

body.rcn-theme .rcn-listing-card,
body.rcn-theme a.rcn-listing-card {
    text-decoration: none !important;
    background: #fff !important;
    color: inherit !important;
}
body.rcn-theme .rcn-listing-card__title {
    font-size: 15px !important;
    font-weight: 700 !important;
    color: #0F172A !important;
    text-transform: none !important;
    margin: 0 0 10px !important;
    padding: 0 !important;
}
body.rcn-theme .rcn-listing-card__price {
    font-family: 'JetBrains Mono', monospace !important;
    font-size: 18px !important;
    font-weight: 700 !important;
    color: #DC2626 !important;
}

body.rcn-theme .rcn-btn { text-transform: none !important; font-family: inherit !important; }
body.rcn-theme .rcn-btn-primary {
    background: #DC2626 !important;
    color: #fff !important;
    border: 1.5px solid #DC2626 !important;
}
body.rcn-theme .rcn-btn-primary:hover {
    background: #B91C1C !important;
    border-color: #B91C1C !important;
    color: #fff !important;
}
body.rcn-theme .rcn-btn-outline {
    background: transparent !important;
    color: #0F172A !important;
    border: 1.5px solid #CBD5E1 !important;
}
body.rcn-theme .rcn-btn-outline:hover {
    border-color: #DC2626 !important;
    color: #DC2626 !important;
}

body.rcn-theme .rcn-input,
body.rcn-theme .rcn-select,
body.rcn-theme .rcn-textarea,
body.rcn-theme select.rcn-input,
body.rcn-theme input.rcn-input,
body.rcn-theme textarea.rcn-textarea {
    background: #fff !important;
    border: 1.5px solid #E2E8F0 !important;
    border-radius: 10px !important;
    padding: 11px 14px !important;
    font-size: 14px !important;
    color: #0F172A !important;
    box-shadow: none !important;
    height: auto !important;
    line-height: 1.4 !important;
    font-family: inherit !important;
}
body.rcn-theme .rcn-input:focus,
body.rcn-theme select.rcn-input:focus {
    border-color: #DC2626 !important;
    box-shadow: 0 0 0 4px rgba(220,38,38,0.08) !important;
    outline: none !important;
}

body.rcn-theme .rcn-input-icon {
    position: relative !important;
    display: block !important;
}
body.rcn-theme .rcn-input-icon .rcn-input,
body.rcn-theme .rcn-input-icon input.rcn-input,
body.rcn-theme .rcn-input-icon input[type="text"],
body.rcn-theme .rcn-input-icon input[type="search"] {
    padding-left: 40px !important;
}
body.rcn-theme .rcn-input-icon > svg,
body.rcn-theme .rcn-input-icon svg,
body.rcn-theme .rcn-input-icon i,
body.rcn-theme .rcn-input-icon .rcn-icon,
body.rcn-theme .rcn-input-icon > span > svg {
    position: absolute !important;
    left: 14px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    color: #94A3B8 !important;
    width: 16px !important;
    height: 16px !important;
    pointer-events: none !important;
    z-index: 2;
}

body.rcn-theme .rcn-header {
    background: #0F172A !important;
    box-shadow: 0 1px 0 rgba(255,255,255,0.04), 0 4px 12px rgba(0,0,0,0.18) !important;
}
body.rcn-theme .rcn-header__link,
body.rcn-theme .rcn-header__link-toggle,
body.rcn-theme button.rcn-header__link-toggle {
    background: transparent !important;
    color: rgba(255,255,255,0.78) !important;
    border: none !important;
    text-transform: none !important;
    font-weight: 600 !important;
}
body.rcn-theme .rcn-header__link:hover,
body.rcn-theme .rcn-header__link-toggle:hover {
    color: #fff !important;
    background: rgba(255,255,255,0.06) !important;
}
body.rcn-theme .rcn-header__menu-panel,
body.rcn-theme .rcn-header__user-menu {
    background: #fff !important;
    border-radius: 14px !important;
    box-shadow: 0 16px 40px rgba(15,23,42,0.16) !important;
    padding: 12px !important;
}
body.rcn-theme .rcn-header__menu-item { color: #0F172A !important; text-decoration: none !important; }
body.rcn-theme .rcn-header__menu-item:hover { background: #F1F5F9 !important; }
body.rcn-theme .rcn-header__sell-btn {
    background: #DC2626 !important;
    color: #fff !important;
    border: 1.5px solid #DC2626 !important;
}

body.rcn-theme .rcn-section { padding: 64px 0 !important; background: transparent; }
body.rcn-theme .rcn-section-alt { background: #F1F5F9 !important; }
body.rcn-theme .rcn-section__title {
    color: #0F172A !important;
    text-transform: none !important;
    letter-spacing: -0.02em !important;
}
body.rcn-theme .rcn-cat-tile { text-decoration: none !important; }
body.rcn-theme .rcn-cat-tile h3 { color: #fff !important; text-transform: none !important; margin: 0 0 4px !important; }
body.rcn-theme .rcn-cat-tile p { color: rgba(255,255,255,0.75) !important; margin: 0 !important; }

body.rcn-theme .rcn-footer { background: #0F172A !important; color: rgba(255,255,255,0.7) !important; }
body.rcn-theme .rcn-footer a { color: rgba(255,255,255,0.6) !important; text-decoration: none !important; }
body.rcn-theme .rcn-footer a:hover { color: #fff !important; }
body.rcn-theme .rcn-footer__heading { color: #fff !important; text-transform: uppercase !important; }

body.rcn-theme #top-bar,
body.rcn-theme #wrapper > #header,
body.rcn-theme #wrapper > .stm-top-bar,
body.rcn-theme .stm-header,
body.rcn-theme #stm-boats-header { display: none !important; }

body.rcn-home.rcn-theme #main .wpb-content-wrapper,
body.rcn-home.rcn-theme #main .vc_row,
body.rcn-home.rcn-theme #main .stm-listing-search-row { display: none !important; }

body.rcn-listing-archive .stm-classic-filter,
body.rcn-listing-archive .stm-filter-sidebar,
body.rcn-listing-archive .stm-classified-archive,
body.rcn-tax-archive .stm-classic-filter,
body.rcn-tax-archive .stm-filter-sidebar,
body.rcn-tax-archive .stm-classified-archive { display: none !important; }

body.rcn-theme .rcn-listing-panel__title,
body.rcn-theme .rcn-hero__title,
body.rcn-theme .rcn-section__title,
body.rcn-theme .rcn-listing-card__title,
body.rcn-theme .rcn-listing-row__title {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif !important;
}

[x-cloak] { display: none !important; }

/* View-stat pills — single listing + user dashboard */
body.rcn-theme .rcn-listing-panel__viewstat {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 6px !important;
    margin: -4px 0 16px !important;
}
body.rcn-theme .rcn-listing-panel__viewstat-pill {
    display: inline-flex !important;
    align-items: center !important;
    gap: 4px !important;
    padding: 4px 10px !important;
    border-radius: 999px !important;
    font-size: 11.5px !important;
    font-weight: 700 !important;
    background: #f1f5f9 !important;
    color: #475569 !important;
    line-height: 1.2 !important;
}
body.rcn-theme .rcn-listing-panel__viewstat-pill--hot {
    background: linear-gradient(135deg, #fef2f2, #fee2e2) !important;
    color: #b91c1c !important;
}
body.rcn-theme .rcn-listing-panel__viewstat-pill--hot svg {
    color: #dc2626 !important;
}
body.rcn-theme .rcn-user-listing-row__viewstat {
    display: inline-flex !important;
    align-items: center !important;
    gap: 4px !important;
    padding: 2px 8px !important;
    background: linear-gradient(135deg, #fef2f2, #fee2e2) !important;
    color: #b91c1c !important;
    border-radius: 999px !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    margin-left: 8px !important;
    line-height: 1.3 !important;
    vertical-align: middle !important;
}
body.rcn-theme .rcn-user-listing-row__viewstat--quiet {
    background: #f1f5f9 !important;
    color: #64748b !important;
}
body.rcn-theme .rcn-user-listing-row__viewstat svg {
    color: currentColor !important;
}

/* Save Search button */
body.rcn-theme .rcn-savesearch {
    display: inline-flex !important;
    align-items: center !important;
    gap: 6px !important;
    padding: 8px 14px !important;
    background: #fff !important;
    border: 1.5px solid #FCA5A5 !important;
    color: #DC2626 !important;
    border-radius: 10px !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    cursor: pointer !important;
    transition: all .15s !important;
    text-decoration: none !important;
    white-space: nowrap !important;
}
body.rcn-theme .rcn-savesearch:hover {
    background: linear-gradient(135deg, #fef2f2, #fee2e2) !important;
    border-color: #DC2626 !important;
    box-shadow: 0 4px 12px rgba(220, 38, 38, .15) !important;
    transform: translateY(-1px) !important;
}
body.rcn-theme .rcn-savesearch--saved {
    background: linear-gradient(135deg, #ecfdf5, #d1fae5) !important;
    color: #047857 !important;
    border-color: #6ee7b7 !important;
    cursor: default !important;
}
body.rcn-theme .rcn-savesearch--saved:hover {
    transform: none !important;
    box-shadow: none !important;
}

/* ============================================================
   LISTING CARD BADGES — premium glass redesign
   ============================================================ */
body.rcn-theme .rcn-listing-card__image {
    position: relative !important;
}
body.rcn-theme .rcn-listing-card__image .rcn-listing-card__badge {
    position: absolute !important;
    top: 10px !important;
    left: 10px !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 5px !important;
    padding: 5px 10px !important;
    border-radius: 8px !important;
    font: 700 11px/1.2 'Inter', system-ui, sans-serif !important;
    letter-spacing: 0.01em !important;
    text-transform: none !important;
    background: rgba(15, 23, 42, 0.78) !important;
    color: #fff !important;
    backdrop-filter: blur(10px) saturate(160%) !important;
    -webkit-backdrop-filter: blur(10px) saturate(160%) !important;
    box-shadow: 0 4px 12px rgba(0,0,0,0.22), inset 0 1px 0 rgba(255,255,255,0.08) !important;
    white-space: nowrap !important;
    z-index: 3 !important;
    border: none !important;
    transition: transform .2s !important;
}
body.rcn-theme .rcn-listing-card__image .rcn-listing-card__badge svg {
    width: 11px !important;
    height: 11px !important;
    flex-shrink: 0 !important;
    color: currentColor !important;
    opacity: .95 !important;
}
body.rcn-theme .rcn-listing-card__image .rcn-listing-card__badge + .rcn-listing-card__badge {
    top: 44px !important;
}
body.rcn-theme .rcn-listing-card__image .rcn-listing-card__badge + .rcn-listing-card__badge + .rcn-listing-card__badge {
    top: 78px !important;
}
body.rcn-theme .rcn-listing-card__image .rcn-listing-card__badge.rcn-badge-brand {
    background: linear-gradient(135deg, rgba(220,38,38,0.95), rgba(185,28,28,0.92)) !important;
    color: #fff !important;
    box-shadow: 0 4px 14px rgba(220,38,38,0.4), inset 0 1px 0 rgba(255,255,255,0.18) !important;
}
body.rcn-theme .rcn-listing-card__image .rcn-listing-card__badge.rcn-badge-brand svg {
    color: #FCD34D !important;
}
body.rcn-theme .rcn-listing-card__image .rcn-listing-card__badge.rcn-badge-success {
    background: linear-gradient(135deg, rgba(16,185,129,0.95), rgba(5,150,105,0.92)) !important;
    color: #fff !important;
    box-shadow: 0 4px 14px rgba(16,185,129,0.35), inset 0 1px 0 rgba(255,255,255,0.18) !important;
}
body.rcn-theme .rcn-listing-card__image .rcn-listing-card__badge.rcn-badge-dark,
body.rcn-theme .rcn-listing-card__image .rcn-listing-card__badge.rcn-badge-sold {
    background: linear-gradient(135deg, rgba(15,23,42,0.92), rgba(30,41,59,0.92)) !important;
    color: rgba(255,255,255,0.95) !important;
    text-transform: uppercase !important;
    letter-spacing: 0.06em !important;
    font-size: 10.5px !important;
}
body.rcn-theme .rcn-listing-card__image .rcn-listing-card__badge.rcn-badge-warning,
body.rcn-theme .rcn-listing-card__image .rcn-listing-card__badge.rcn-badge-featured {
    background: linear-gradient(135deg, rgba(245,158,11,0.95), rgba(217,119,6,0.92)) !important;
    color: #fff !important;
    box-shadow: 0 4px 14px rgba(245,158,11,0.35), inset 0 1px 0 rgba(255,255,255,0.18) !important;
}
body.rcn-theme .rcn-listing-card__image .rcn-listing-card__badge.rcn-badge-danger {
    background: linear-gradient(135deg, rgba(190,18,60,0.95), rgba(157,23,77,0.92)) !important;
    color: #fff !important;
}
body.rcn-theme .rcn-listing-card__image .rcn-listing-card__badge.rcn-badge-info {
    background: linear-gradient(135deg, rgba(37,99,235,0.95), rgba(29,78,216,0.92)) !important;
    color: #fff !important;
}
body.rcn-theme .rcn-listing-card__image .rcn-listing-card__badge.rcn-badge-outline {
    background: rgba(255,255,255,0.18) !important;
    color: #fff !important;
    border: 1px solid rgba(255,255,255,0.28) !important;
}
body.rcn-theme .rcn-listing-card__photo-count {
    background: rgba(15,23,42,0.72) !important;
    backdrop-filter: blur(8px) !important;
    -webkit-backdrop-filter: blur(8px) !important;
    padding: 3px 8px !important;
    font-size: 10.5px !important;
    font-weight: 700 !important;
    border-radius: 6px !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.22) !important;
}
body.rcn-theme .rcn-listing-card:hover .rcn-listing-card__badge {
    transform: translateY(-1px) !important;
}
@media (max-width: 600px) {
    body.rcn-theme .rcn-listing-card__image .rcn-listing-card__badge {
        font-size: 10.5px !important;
        padding: 4px 8px !important;
        gap: 4px !important;
        top: 8px !important;
        left: 8px !important;
    }
    body.rcn-theme .rcn-listing-card__image .rcn-listing-card__badge + .rcn-listing-card__badge {
        top: 36px !important;
    }
}
