/* =============================================
   FEATURED AD — Premium Card & Section Styles
   Elegant, Eye-catching, Luxury Design
   ============================================= */

/* ── CSS Variables ── */
:root {
    --featured-gold: #d4a017;
    --featured-gold-light: #f0d060;
    --featured-gold-dark: #a67c00;
    --featured-amber: #f59e0b;
    --featured-warm: #92400e;
    --featured-cream: #fffbeb;
    --featured-bg-start: rgba(250, 240, 210, 0.35);
    --featured-bg-end: rgba(255, 248, 230, 0.2);
    --featured-border: rgba(212, 160, 23, 0.22);
    --featured-shadow: 0 8px 40px rgba(212, 160, 23, 0.10);
    --featured-transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ── Section wrapper ── */
.featured-ads-section {
    margin-bottom: 36px;
    padding: 28px 28px 32px;
    background:
        linear-gradient(135deg, var(--featured-bg-start) 0%, var(--featured-bg-end) 100%);
    border: 1px solid var(--featured-border);
    border-radius: 20px;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(2px);
}

/* Decorative top shimmer bar */
.featured-ads-section::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(
        90deg,
        transparent 0%,
        var(--featured-gold-dark) 15%,
        var(--featured-gold-light) 35%,
        var(--featured-gold) 50%,
        var(--featured-gold-light) 65%,
        var(--featured-gold-dark) 85%,
        transparent 100%
    );
    border-radius: 20px 20px 0 0;
    animation: shimmerBar 4s ease-in-out infinite;
}

@keyframes shimmerBar {
    0%, 100% { opacity: 0.7; }
    50% { opacity: 1; }
}

/* Subtle diagonal sparkle pattern overlay */
.featured-ads-section::after {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(circle at 15% 25%, rgba(212, 160, 23, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 85% 75%, rgba(240, 208, 96, 0.04) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

/* ── Section header ── */
.featured-ads-section__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 10px;
    position: relative;
    z-index: 1;
}

.featured-ads-section__title-wrap {
    display: flex;
    align-items: center;
    gap: 14px;
}

.featured-ads-section__title-wrap > div {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.featured-ads-section__icon {
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(145deg, var(--featured-gold) 0%, var(--featured-gold-dark) 100%);
    color: #fff;
    border-radius: 12px;
    font-size: 16px;
    box-shadow:
        0 4px 16px rgba(212, 160, 23, 0.35),
        inset 0 1px 0 rgba(255,255,255,0.25);
    position: relative;
}

.featured-ads-section__icon::after {
    content: '';
    position: absolute;
    inset: -2px;
    border-radius: 14px;
    border: 1px solid rgba(240, 208, 96, 0.25);
    pointer-events: none;
}

.featured-ads-section__title {
    font-size: 22px;
    font-weight: 800;
    color: var(--featured-warm);
    margin: 0;
    letter-spacing: -0.4px;
    line-height: 1.2;
}

.featured-ads-section__subtitle {
    font-size: 13px;
    font-weight: 500;
    color: var(--featured-gold-dark);
    opacity: 0.8;
    letter-spacing: 0.2px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.featured-ads-section__subtitle::before {
    content: '';
    display: inline-block;
    width: 4px;
    height: 4px;
    background: var(--featured-gold);
    border-radius: 50%;
}

/* ── Section grid ── */
.featured-ads-section__grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 22px;
    position: relative;
    z-index: 1;
}

/* =============================================
   FEATURED AD CARD — Luxury Design
   ============================================= */

.featured-ad-card {
    position: relative;
    background: #ffffff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow:
        0 2px 8px rgba(0, 0, 0, 0.04),
        0 8px 32px rgba(212, 160, 23, 0.08);
    border: 1px solid rgba(212, 160, 23, 0.15);
    transition: var(--featured-transition);
    will-change: transform;
}

.featured-ad-card:hover {
    transform: translateY(-8px) scale(1.01);
    box-shadow:
        0 20px 60px rgba(212, 160, 23, 0.18),
        0 8px 24px rgba(0, 0, 0, 0.06);
    border-color: rgba(212, 160, 23, 0.35);
}

/* Luxury left accent — gradient strip */
.featured-ad-card::before {
    content: '';
    position: absolute;
    left: 0; top: 0; bottom: 0;
    width: 4px;
    background: linear-gradient(
        180deg,
        var(--featured-gold-light) 0%,
        var(--featured-gold) 30%,
        var(--featured-gold-dark) 70%,
        var(--featured-gold-light) 100%
    );
    z-index: 10;
    border-radius: 16px 0 0 16px;
    opacity: 0.85;
    transition: opacity 0.3s;
}

.featured-ad-card:hover::before {
    opacity: 1;
}

/* Subtle glow on hover */
.featured-ad-card::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 16px;
    box-shadow: inset 0 0 0 1px rgba(240, 208, 96, 0);
    transition: box-shadow 0.4s ease;
    pointer-events: none;
    z-index: 5;
}

.featured-ad-card:hover::after {
    box-shadow: inset 0 0 0 1px rgba(240, 208, 96, 0.2);
}

.featured-ad-card__link {
    display: block;
    text-decoration: none !important;
    color: inherit !important;
}

.featured-ad-card__link:hover {
    text-decoration: none !important;
    color: inherit !important;
}

/* ── Image gallery ── */
.featured-ad-card__gallery {
    position: relative;
    height: 230px;
    overflow: hidden;
    background: linear-gradient(135deg, #f9f9f7 0%, #f0efe8 100%);
}

/* 3-image layout */
.featured-ad-card__gallery--multi {
    display: grid;
    grid-template-columns: 1fr 0.42fr;
    gap: 3px;
}

.featured-ad-card__img {
    overflow: hidden;
    position: relative;
}

.featured-ad-card__img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.featured-ad-card:hover .featured-ad-card__img img {
    transform: scale(1.08);
}

/* Subtle gradient overlay on images for depth */
.featured-ad-card__img--main::after,
.featured-ad-card__img--full::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 60%;
    background: linear-gradient(to top, rgba(0,0,0,0.12) 0%, transparent 100%);
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.featured-ad-card:hover .featured-ad-card__img--main::after,
.featured-ad-card:hover .featured-ad-card__img--full::after {
    opacity: 1;
}

.featured-ad-card__img--main {
    grid-row: 1 / 2;
}

.featured-ad-card__img-stack {
    display: grid;
    grid-template-rows: 1fr 1fr;
    gap: 3px;
}

.featured-ad-card__img--secondary {
    height: 100%;
}

.featured-ad-card__img--half {
    height: 100%;
}

.featured-ad-card__gallery:not(.featured-ad-card__gallery--multi) {
    display: block;
}

.featured-ad-card__img--full {
    height: 100%;
    position: relative;
}

.featured-ad-card__img--full img {
    height: 230px;
}

/* No image fallback */
.featured-ad-card__no-img {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #fdf6e3 0%, #f5e6c8 100%);
    color: var(--featured-warm);
    height: 230px;
}

.featured-ad-card__no-img i {
    font-size: 38px;
    opacity: 0.4;
    margin-bottom: 10px;
}

.featured-ad-card__no-img span {
    font-size: 13px;
    font-weight: 600;
    opacity: 0.6;
    max-width: 80%;
    text-align: center;
}

/* Image error state */
.featured-ad-card__img.img-error {
    background: linear-gradient(135deg, #f9f9f7 0%, #f0efe8 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.featured-ad-card__img.img-error img {
    display: none;
}

.featured-ad-card__img.img-error::after {
    content: '\f03e';
    font-family: 'Font Awesome 5 Pro', 'Font Awesome 5 Free';
    font-weight: 300;
    font-size: 26px;
    color: #d1ccc2;
}

/* ── Featured badge overlay — floating glass pill ── */
.featured-ad-card__badge {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 20;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px 6px 11px;
    background: linear-gradient(
        135deg,
        rgba(166, 124, 0, 0.92) 0%,
        rgba(212, 160, 23, 0.95) 50%,
        rgba(240, 208, 96, 0.92) 100%
    );
    color: #fff;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    border-radius: 30px;
    box-shadow:
        0 4px 20px rgba(212, 160, 23, 0.50),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    pointer-events: none;
    white-space: nowrap;
    backdrop-filter: blur(8px);
    animation: featuredBadgeGlow 3.5s ease-in-out infinite;
}

.featured-ad-card__badge i {
    font-size: 10px;
    filter: drop-shadow(0 0 2px rgba(255,255,255,0.4));
    animation: starSpin 5s linear infinite;
}

@keyframes featuredBadgeGlow {
    0%, 100% {
        box-shadow:
            0 4px 20px rgba(212, 160, 23, 0.50),
            inset 0 1px 0 rgba(255, 255, 255, 0.3);
    }
    50% {
        box-shadow:
            0 6px 30px rgba(240, 208, 96, 0.70),
            inset 0 1px 0 rgba(255, 255, 255, 0.4),
            0 0 0 4px rgba(240, 208, 96, 0.12);
    }
}

@keyframes starSpin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ── Image count indicator ── */
.featured-ad-card__img-count {
    position: absolute;
    bottom: 12px;
    right: 12px;
    z-index: 20;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 12px;
    background: rgba(0, 0, 0, 0.55);
    color: #fff;
    font-size: 11px;
    font-weight: 600;
    border-radius: 20px;
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255,255,255,0.1);
}

/* ── Card body ── */
.featured-ad-card__body {
    padding: 18px 22px 20px;
    position: relative;
}

.featured-ad-card__meta {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    flex-wrap: wrap;
}

.featured-ad-card__category {
    font-size: 11px;
    font-weight: 700;
    color: #6b7280;
    background: #f3f4f6;
    padding: 3px 12px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    transition: all 0.25s ease;
}

.featured-ad-card:hover .featured-ad-card__category {
    color: var(--featured-warm);
    background: rgba(212, 160, 23, 0.08);
}

.featured-ad-card__featured-tag {
    font-size: 10px;
    font-weight: 700;
    color: var(--featured-gold-dark);
    background: linear-gradient(135deg, rgba(240, 208, 96, 0.15) 0%, rgba(212, 160, 23, 0.10) 100%);
    border: 1px solid rgba(212, 160, 23, 0.20);
    padding: 3px 10px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.featured-ad-card__featured-tag i {
    font-size: 8px;
    color: var(--featured-gold);
}

.featured-ad-card__title {
    font-size: 17px;
    font-weight: 700;
    color: #1a1a2e;
    margin: 0 0 8px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color 0.3s ease;
}

.featured-ad-card:hover .featured-ad-card__title {
    color: var(--featured-gold-dark);
}

.featured-ad-card__location {
    font-size: 13px;
    color: #9ca3af;
    margin: 0 0 10px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.featured-ad-card__location i {
    color: var(--featured-gold);
    font-size: 12px;
}

.featured-ad-card__desc {
    font-size: 13px;
    color: #9ca3af;
    line-height: 1.55;
    margin: 0 0 14px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ── Card footer ── */
.featured-ad-card__footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 14px;
    border-top: 1px solid rgba(212, 160, 23, 0.10);
    position: relative;
}

.featured-ad-card__price {
    font-size: 19px;
    font-weight: 800;
    color: var(--featured-warm);
    letter-spacing: -0.3px;
}

.featured-ad-card__price .price-container {
    flex-direction: row;
    align-items: baseline;
    gap: 2px;
}

.featured-ad-card__price .price-label {
    display: none;
}

.featured-ad-card__price .price-value {
    gap: 2px;
}

.featured-ad-card__price .price-symbol {
    font-size: 14px;
    color: var(--featured-warm);
}

.featured-ad-card__price .price-amount {
    font-size: 19px;
    color: var(--featured-warm);
}

.featured-ad-card__price--contact {
    font-size: 14px;
    font-weight: 600;
    color: #9ca3af;
    font-style: italic;
}

.featured-ad-card__cta {
    font-size: 13px;
    font-weight: 700;
    color: var(--featured-gold-dark);
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 14px;
    border-radius: 8px;
    background: linear-gradient(135deg, rgba(240, 208, 96, 0.12) 0%, rgba(212, 160, 23, 0.08) 100%);
    transition: all 0.3s ease;
}

.featured-ad-card:hover .featured-ad-card__cta {
    background: linear-gradient(135deg, rgba(212, 160, 23, 0.18) 0%, rgba(240, 208, 96, 0.14) 100%);
    gap: 10px;
    color: var(--featured-warm);
}

.featured-ad-card__cta i {
    font-size: 11px;
    transition: transform 0.3s ease;
}

.featured-ad-card:hover .featured-ad-card__cta i {
    transform: translateX(3px);
}

/* =============================================
   FEATURED AD BADGE — for regular card partials
   (adz-cards, property-cards, job-cards)
   ============================================= */

/* Overlay badge on image */
.boost-overlay-badge--featured {
    background: linear-gradient(
        135deg,
        rgba(166, 124, 0, 0.92) 0%,
        rgba(212, 160, 23, 0.95) 50%,
        rgba(240, 208, 96, 0.92) 100%
    );
    box-shadow:
        0 4px 20px rgba(212, 160, 23, 0.50),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    animation: featuredBadgeGlow 3.5s ease-in-out infinite;
}

/* Body label */
.boost-card-label--featured span {
    color: var(--featured-gold-dark);
    background: linear-gradient(135deg, rgba(240, 208, 96, 0.15) 0%, rgba(212, 160, 23, 0.10) 100%);
    border: 1px solid rgba(212, 160, 23, 0.20);
}

/* Card highlight border — inline featured in listings */
.featured-ad-card-inline {
    position: relative;
    border: 1.5px solid rgba(212, 160, 23, 0.40) !important;
    box-shadow:
        0 4px 24px rgba(212, 160, 23, 0.10),
        0 0 0 1px rgba(240, 208, 96, 0.06) !important;
    background-image: linear-gradient(
        135deg,
        rgba(255, 248, 230, 0.5) 0%,
        transparent 80px
    ) !important;
    background-repeat: no-repeat;
    transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.featured-ad-card-inline::before,
.list-view .featured-ad-card-inline::before,
.gallery-view .featured-ad-card-inline::before {
    content: '';
    position: absolute;
    left: 0; top: 0; bottom: 0;
    width: 4px;
    background: linear-gradient(
        180deg,
        var(--featured-gold-light) 0%,
        var(--featured-gold) 30%,
        var(--featured-gold-dark) 70%,
        var(--featured-gold-light) 100%
    );
    border-radius: 12px 0 0 12px;
    z-index: 5;
    opacity: 1 !important;
    transform: none !important;
}

.featured-ad-card-inline:hover {
    box-shadow:
        0 8px 36px rgba(212, 160, 23, 0.20),
        0 0 0 1px rgba(240, 208, 96, 0.15) !important;
    transform: translateY(-3px);
}

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

@media (max-width: 991px) {
    .featured-ads-section {
        padding: 22px 20px 26px;
        border-radius: 16px;
    }

    .featured-ads-section__grid {
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
        gap: 18px;
    }

    .featured-ad-card__gallery {
        height: 200px;
    }

    .featured-ad-card__img--full img {
        height: 200px;
    }

    .featured-ads-section__icon {
        width: 38px;
        height: 38px;
        font-size: 14px;
    }
}

@media (max-width: 768px) {
    .featured-ads-section__header {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }

    .featured-ads-section__grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .featured-ad-card__gallery {
        height: 190px;
    }

    .featured-ad-card__img--full img {
        height: 190px;
    }

    .featured-ad-card__title {
        font-size: 15px;
    }

    .featured-ads-section__title {
        font-size: 20px;
    }
}

@media (max-width: 576px) {
    .featured-ads-section {
        padding: 16px 14px 20px;
        border-radius: 14px;
        margin-bottom: 22px;
    }

    .featured-ads-section__title {
        font-size: 18px;
    }

    .featured-ads-section__icon {
        width: 34px;
        height: 34px;
        font-size: 13px;
        border-radius: 10px;
    }

    .featured-ad-card {
        border-radius: 14px;
    }

    .featured-ad-card__gallery {
        height: 170px;
    }

    .featured-ad-card__gallery--multi {
        grid-template-columns: 1fr;
    }

    .featured-ad-card__img-stack {
        display: none;
    }

    .featured-ad-card__img--full img {
        height: 170px;
    }

    .featured-ad-card__body {
        padding: 14px 16px 16px;
    }

    .featured-ad-card__footer {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .featured-ad-card__cta {
        width: 100%;
        justify-content: center;
    }

    .featured-ad-card__badge {
        top: 10px;
        left: 10px;
        padding: 5px 11px 5px 9px;
        font-size: 9px;
    }
}

/* =============================================
   FEATURED AD CARD — Urgent & Combo Tags
   ============================================= */

/* Urgent tag in meta row */
.featured-ad-card__urgent-tag {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    color: #dc2626;
    background: rgba(220, 38, 38, 0.08);
    border: 1px solid rgba(220, 38, 38, 0.22);
    padding: 2px 9px;
    border-radius: 20px;
}

.featured-ad-card__urgent-tag i {
    font-size: 9px;
    animation: urgentBlink 1.5s ease-in-out infinite;
}

@keyframes urgentBlink {
    0%, 100% { opacity: 0.95; }
    50% { opacity: 0.5; }
}

/* Power Combo tag in meta row */
.featured-ad-card__combo-tag {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    color: #7c3aed;
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.08) 0%, rgba(245, 158, 11, 0.06) 100%);
    border: 1px solid rgba(124, 58, 237, 0.20);
    padding: 2px 10px;
    border-radius: 20px;
}

.featured-ad-card__combo-tag i {
    font-size: 9px;
    color: #f59e0b;
}

/* Featured card + Power Combo — animated top border */
.featured-ad-card.power-combo-card {
    position: relative;
    box-shadow:
        0 6px 40px rgba(124, 58, 237, 0.12),
        0 0 0 2px rgba(124, 58, 237, 0.18);
}

.featured-ad-card.power-combo-card::after {
    content: '';
    position: absolute;
    left: 0; top: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, #7c3aed, #f59e0b, #dc2626, #7c3aed);
    background-size: 300% 100%;
    border-radius: 16px 16px 0 0;
    z-index: 10;
    animation: comboGradientSlide 4s ease infinite;
}

@keyframes comboGradientSlide {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Featured card + Urgent — right-side red accent */
.featured-ad-card.urgent-ad-card {
    position: relative;
}

.featured-ad-card.urgent-ad-card::after {
    content: '';
    position: absolute;
    right: 0; top: 0; bottom: 0;
    width: 3px;
    background: linear-gradient(to bottom, #ef4444, #dc2626, #ef4444);
    border-radius: 0 16px 16px 0;
    z-index: 10;
}

