/* =========================================================
   ADS / MARKETPLACE
   Собрано из рабочих файлов, чтобы убрать мелкие patch-CSS.
========================================================= */


/* ===== ads.css ===== */
/* =========================
   ADS MODERN — stable version
========================= */

.ads-page {
    max-width: 1180px;
    margin: 0 auto;
    padding: 28px 16px;
}

.ads-hero {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 22px;
    margin-bottom: 22px;
    padding: 28px;
    border-radius: 24px;
    background: radial-gradient(circle at 80% 20%, rgba(37, 99, 235, .18), transparent 35%), linear-gradient(135deg, #fff, #eff6ff);
    border: 1px solid rgba(148, 163, 184, .25);
    box-shadow: 0 18px 45px rgba(15, 23, 42, .07);
}

.ads-kicker {
    display: inline-flex;
    margin-bottom: 10px;
    color: #2563eb;
    font-weight: 900;
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: .06em;
}

.ads-hero h1 {
    margin: 0 0 8px;
    font-size: clamp(30px, 4vw, 48px);
    line-height: 1.05;
    letter-spacing: -.045em;
}

.ads-hero p {
    max-width: 620px;
    margin: 0;
    color: #64748b;
    font-size: 16px;
    line-height: 1.5;
}

.ads-add-btn,
.ads-edit-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 18px;
    border-radius: 14px;
    background: #2563eb;
    color: #fff !important;
    text-decoration: none !important;
    font-weight: 800;
    box-shadow: 0 10px 24px rgba(37, 99, 235, .24);
}

.ads-search {
    display: grid;
    grid-template-columns: 1fr 220px 120px;
    align-items: end;
    gap: 12px;
    margin-bottom: 18px;
}

.ads-search label {
    display: grid;
    gap: 6px;
    font-size: 13px;
    color: #475569;
    font-weight: 700;
}

.ads-search input,
.ad-form input,
.ad-form select,
.ad-form textarea {
    width: 100%;
    min-height: 46px;
    padding: 12px 14px;
    border: 1px solid #dbe2ea;
    border-radius: 14px;
    background: #fff;
    font-size: 15px;
    box-sizing: border-box;
}

.ads-search button,
.ad-form button {
    min-height: 46px;
    border: 0;
    border-radius: 14px;
    background: #111827;
    color: #fff;
    font-weight: 800;
    cursor: pointer;
}

.ads-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    margin-bottom: 24px;
}

.ads-categories a {
    padding: 9px 14px;
    border-radius: 999px;
    background: #fff;
    color: #111827 !important;
    text-decoration: none !important;
    font-weight: 800;
    font-size: 14px;
    border: 1px solid #e2e8f0;
}

.ads-categories a.active {
    background: #111827;
    color: #fff !important;
}

.ads-categories a.ads-subcategory {
    font-size: 13px;
    background: #f8fafc;
}

.ads-section-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 14px;
}

.ads-section-head h2 {
    margin: 0;
    font-size: 24px;
    letter-spacing: -.025em;
}

.ads-section-head span {
    color: #64748b;
    font-weight: 700;
}

.ads-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
}

.classified-card {
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow: hidden;
    border-radius: 22px;
    background: #fff;
    border: 1px solid #e2e8f0;
    color: inherit !important;
    text-decoration: none !important;
    box-shadow: 0 12px 30px rgba(15, 23, 42, .06);
    transition: transform .2s ease, box-shadow .2s ease;
}

.classified-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 45px rgba(15, 23, 42, .1);
}

.classified-card.is-vip {
    border-color: #f59e0b;
    box-shadow: 0 18px 45px rgba(245, 158, 11, .18);
}

.classified-card-image {
    position: relative;
    height: 190px;
    overflow: hidden;
    background: #e2e8f0;
}

.classified-card.no-photo .classified-card-image {
    height: 118px;
    background: #f8fafc;
}

.classified-card-image img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    transition: transform .35s ease;
}

.classified-card:hover .classified-card-image img {
    transform: scale(1.055);
}

.ad-no-image {
    width: 100%;
    min-height: 190px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #64748b;
    font-weight: 800;
    background: radial-gradient(circle at 30% 20%, #fff, transparent 30%), linear-gradient(135deg, #e0f2fe, #dbeafe);
}

.ad-no-image.compact {
    min-height: 118px;
    height: 118px;
    flex-direction: column;
    gap: 8px;
    font-size: 15px;
    background: radial-gradient(circle at 30% 20%, #ffffff, transparent 32%), linear-gradient(135deg, #f8fafc, #e2e8f0);
}

.ad-no-image.compact span {
    font-size: 34px;
    line-height: 1;
}

.ad-no-image.compact small {
    color: #64748b;
    font-weight: 800;
}

.ad-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 2;
    padding: 6px 10px;
    border-radius: 999px;
    background: #f59e0b;
    color: #111827;
    font-weight: 900;
    font-size: 12px;
    text-transform: uppercase;
}

.ad-badge.premium {
    background: #111827;
    color: #fff;
}

.classified-card-body {
    padding: 15px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.classified-card-meta {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    color: #64748b;
    font-size: 13px;
    margin-bottom: 8px;
}

.classified-card h3 {
    margin: 0 0 10px;
    color: #111827;
    font-size: 18px;
    line-height: 1.22;
    letter-spacing: -.025em;
}

.classified-card-price {
    display: block;
    margin-bottom: 8px;
    color: #111827;
    font-size: 21px;
    font-weight: 950;
}

.classified-card-price.muted,
.muted {
    color: #64748b;
}

.classified-card p {
    margin: 0 0 14px;
    color: #475569;
    line-height: 1.45;
    font-size: 14px;
}

.classified-card-footer {
    margin-top: auto;
    display: flex;
    justify-content: space-between;
    color: #64748b;
    font-size: 13px;
}

.ads-empty {
    grid-column: 1 / -1;
    padding: 28px;
    border-radius: 22px;
    background: #fff;
    border: 1px solid #e2e8f0;
    text-align: center;
}

.ads-empty a {
    display: inline-flex;
    margin-top: 10px;
    padding: 10px 16px;
    border-radius: 12px;
    background: #2563eb;
    color: #fff !important;
    text-decoration: none !important;
    font-weight: 800;
}

/* detail */
.ad-detail-page {
    max-width: 1180px;
    margin: 0 auto;
    padding: 28px 16px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 330px;
    gap: 24px;
    align-items: start;
}

.ad-detail-main {
    display: grid;
    gap: 18px;
}

.ad-breadcrumbs {
    color: #64748b;
    font-size: 14px;
}

.ad-breadcrumbs a {
    color: #2563eb;
}

.ad-detail-gallery,
.ad-detail-card,
.ad-contact-box,
.related-ads,
.ad-form-page {
    border-radius: 22px;
    background: #fff;
    border: 1px solid #e2e8f0;
    box-shadow: 0 12px 30px rgba(15, 23, 42, .06);
}

.ad-detail-gallery {
    padding: 14px;
}

.classified-main-photo {
    position: relative;
    display: block;
    width: 100%;
    padding: 0;
    border: 0;
    border-radius: 18px;
    overflow: hidden;
    background: #e2e8f0;
    cursor: zoom-in;
}

.classified-main-photo img {
    width: 100%;
    max-height: 560px;
    min-height: 320px;
    object-fit: cover;
    display: block;
}

.classified-photo-mark {
    position: absolute;
    top: 14px;
    left: 14px;
    padding: 7px 12px;
    border-radius: 999px;
    background: #f59e0b;
    color: #111827;
    font-weight: 900;
    text-transform: uppercase;
}

.classified-photo-mark.premium {
    background: #111827;
    color: #fff;
}

.classified-photo-count {
    position: absolute;
    left: 14px;
    bottom: 14px;
    padding: 9px 12px;
    border-radius: 999px;
    background: rgba(15, 23, 42, .78);
    color: #fff;
    font-weight: 800;
}

.classified-thumbs {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 8px;
    margin-top: 10px;
}

.classified-thumb {
    height: 78px;
    padding: 0;
    border: 0;
    border-radius: 12px;
    overflow: hidden;
    background: #e2e8f0;
    cursor: zoom-in;
}

.classified-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.ad-detail-card {
    padding: 24px;
}

.ad-detail-card h1 {
    margin: 0 0 12px;
    font-size: clamp(28px, 4vw, 44px);
    line-height: 1.08;
    letter-spacing: -.04em;
}

.ad-detail-price {
    margin-bottom: 14px;
    color: #111827;
    font-size: 34px;
    font-weight: 950;
}

.ad-detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 22px;
    color: #64748b;
    font-size: 14px;
}

.ad-detail-card h2 {
    margin: 0 0 10px;
    font-size: 22px;
}

.ad-description {
    font-size: 17px;
    line-height: 1.65;
    color: #1f2937;
}

.ad-detail-no-photo-compact {
    display: grid;
    gap: 5px;
    margin: 0 0 22px;
    padding: 15px;
    border-radius: 16px;
    background: #f8fafc;
    border: 1px dashed #cbd5e1;
    color: #64748b;
}

.ad-detail-no-photo-compact span {
    font-size: 32px;
}

.ad-detail-no-photo-compact strong {
    color: #111827;
}

.ad-contact-box {
    position: sticky;
    top: 18px;
    padding: 20px;
}

.ad-contact-box h3 {
    margin: 0 0 14px;
    font-size: 22px;
}

.ad-contact-actions {
    display: grid;
    gap: 10px;
    margin-bottom: 18px;
}

.ad-contact-action {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 10px 12px;
    border: 0;
    border-radius: 14px;
    background: #f1f5f9;
    color: #111827 !important;
    font-weight: 900;
    text-decoration: none !important;
    cursor: pointer;
}

.ad-contact-action.phone { background: #16a34a; color: #fff !important; }
.ad-contact-action.telegram { background: #229ed9; color: #fff !important; }

.ad-seller {
    display: grid;
    gap: 5px;
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e2e8f0;
}

.ad-seller strong { font-size: 14px; color: #64748b; }
.ad-seller span { font-weight: 900; }
.ad-seller small { color: #64748b; }

.ad-safe-box {
    padding: 14px;
    margin: 16px 0;
    border-radius: 16px;
    background: #f8fafc;
    color: #475569;
}

.ad-safe-box strong { color: #111827; }

.related-ads { padding: 20px; }
.related-ads h2 { margin: 0 0 14px; }
.related-ads-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.related-classified-card { display: grid; gap: 7px; color: inherit !important; text-decoration: none !important; }
.related-classified-card img,
.related-no-image {
    width: 100%;
    height: 110px;
    object-fit: cover;
    border-radius: 14px;
}

.related-no-image {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f1f5f9;
    color: #64748b;
    font-size: 28px;
}
.related-classified-card strong { line-height: 1.2; }
.related-classified-card span { color: #111827; font-weight: 900; }

.ad-mobile-contact-bar { display: none; }

.ad-form-page {
    max-width: 760px;
    margin: 28px auto;
    padding: 24px;
}
.ad-form p { margin-bottom: 16px; }
.ad-form label { display: block; margin-bottom: 6px; font-weight: 800; }
.ad-form button { padding: 13px 20px; }
.form-help { display: block; margin-top: 6px; color: #64748b; font-size: 13px; }

/* lightbox compatibility */
.portal-lightbox { position: fixed; inset: 0; z-index: 9999; display: none; color: #fff; }
.portal-lightbox.is-open { display: block; }
.portal-lightbox__backdrop { position: absolute; inset: 0; background: rgba(0,0,0,.92); }
.portal-lightbox__dialog { position: absolute; inset: 18px; display: grid; grid-template-rows: auto 1fr auto; min-height: 0; }
.portal-lightbox__stories { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 5px; margin-bottom: 12px; }
.portal-lightbox__story { height: 4px; border-radius: 999px; overflow: hidden; background: rgba(255,255,255,.25); }
.portal-lightbox__story span { display: block; width: 0%; height: 100%; border-radius: inherit; background: #fff; }
.portal-lightbox__story.is-done span { width: 100%; }
.portal-lightbox__close, .portal-lightbox__fullscreen, .portal-lightbox__nav { position: absolute; z-index: 4; border: 0; color: #fff; background: rgba(17,24,39,.62); cursor: pointer; backdrop-filter: blur(10px); }
.portal-lightbox__close, .portal-lightbox__fullscreen { top: 22px; width: 44px; height: 44px; border-radius: 999px; font-size: 26px; }
.portal-lightbox__close { right: 22px; }
.portal-lightbox__fullscreen { right: 76px; font-size: 20px; }
.portal-lightbox__nav { top: 50%; transform: translateY(-50%); width: 54px; height: 74px; border-radius: 18px; font-size: 58px; line-height: 1; }
.portal-lightbox__nav--prev { left: 18px; }
.portal-lightbox__nav--next { right: 18px; }
.portal-lightbox__image-wrap { position: relative; display: flex; align-items: center; justify-content: center; min-height: 0; overflow: hidden; user-select: none; touch-action: none; }
.portal-lightbox__image { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 12px; }
.portal-lightbox__bottom { display: grid; gap: 12px; padding-top: 12px; }
.portal-lightbox__counter { text-align: center; font-weight: 800; }
.portal-lightbox__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.portal-lightbox__action { border: 0; border-radius: 999px; padding: 10px 14px; background: rgba(255,255,255,.12); color: #fff !important; font-weight: 800; text-decoration: none !important; cursor: pointer; }
.portal-lightbox__thumbs { display: flex; gap: 8px; max-width: 100%; overflow-x: auto; padding: 2px 0 8px; }
.portal-lightbox__thumb { flex: 0 0 76px; height: 58px; padding: 0; border: 2px solid transparent; border-radius: 10px; overflow: hidden; background: #111827; opacity: .58; cursor: pointer; }
.portal-lightbox__thumb.is-active { border-color: #fff; opacity: 1; }
.portal-lightbox__thumb img { width: 100%; height: 100%; object-fit: cover; }

@media (max-width: 1000px) {
    .ads-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .ad-detail-page { grid-template-columns: 1fr; }
    .ad-contact-box { position: static; }
    .related-ads-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 700px) {
    .ads-page, .ad-detail-page { padding: 20px 14px; }
    .ads-hero { display: grid; padding: 22px; }
    .ads-search { grid-template-columns: 1fr; }
    .ads-grid { grid-template-columns: 1fr; }
    .classified-card-image { height: 220px; }
    .classified-card.no-photo .classified-card-image,
    .ad-no-image.compact {
        height: 118px;
        min-height: 118px;
    }
    .classified-main-photo img { min-height: 260px; }
    .classified-thumbs { grid-template-columns: repeat(4, 1fr); }
    .ad-detail-card { padding: 18px; }
    .related-ads-grid { grid-template-columns: 1fr; }
    .ad-mobile-contact-bar {
        position: fixed;
        left: 10px;
        right: 10px;
        bottom: 10px;
        z-index: 80;
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 8px;
        padding: 8px;
        border-radius: 18px;
        background: rgba(255,255,255,.94);
        box-shadow: 0 16px 45px rgba(15,23,42,.2);
        backdrop-filter: blur(12px);
    }
    .ad-mobile-contact-bar a {
        display: flex;
        align-items: center;
        justify-content: center;
        min-height: 44px;
        border-radius: 14px;
        background: #16a34a;
        color: #fff !important;
        text-decoration: none !important;
        font-weight: 900;
    }
    .ad-mobile-contact-bar a + a { background: #229ed9; }
    .portal-lightbox__dialog { inset: 8px; }
    .portal-lightbox__nav { display: none; }
    .portal-lightbox__close, .portal-lightbox__fullscreen { top: 18px; width: 40px; height: 40px; }
    .portal-lightbox__close { right: 14px; }
    .portal-lightbox__fullscreen { right: 62px; }
}




/* =========================
   ADS UPLOAD PREVIEW PATCH
   Добавь в самый низ static/css/ads.css
========================= */

.ad-upload-preview-box {
    padding: 14px;
    border: 1px dashed #cbd5e1;
    border-radius: 16px;
    background: #f8fafc;
}

.ad-upload-preview-box strong,
.ad-upload-preview-box small {
    display: block;
}

.ad-upload-preview-box small {
    margin-top: 4px;
    color: #64748b;
}

.ad-upload-preview {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
    margin-top: 12px;
}

.ad-upload-preview-empty,
.ad-upload-preview-error {
    grid-column: 1 / -1;
    margin: 0;
    padding: 12px;
    border-radius: 12px;
    background: #ffffff;
    color: #64748b;
}

.ad-upload-preview-error {
    color: #b91c1c;
    background: #fee2e2;
}

.ad-upload-preview-item {
    position: relative;
    height: 100px;
    overflow: hidden;
    border-radius: 14px;
    background: #e2e8f0;
}

.ad-upload-preview-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.ad-upload-preview-item span {
    position: absolute;
    left: 7px;
    top: 7px;
    min-width: 24px;
    min-height: 24px;
    padding: 3px 7px;
    border-radius: 999px;
    background: rgba(15, 23, 42, .78);
    color: #ffffff;
    font-size: 12px;
    font-weight: 900;
}

.ad-upload-preview-item span.is-cover {
    background: #f59e0b;
    color: #111827;
}

.classified-existing-photo {
    position: relative;
    overflow: hidden;
    border-radius: 10px;
}

.classified-existing-photo img {
    width: 100%;
    height: 90px;
    object-fit: cover;
    display: block;
}

.classified-existing-photo span {
    position: absolute;
    left: 6px;
    top: 6px;
    padding: 4px 7px;
    border-radius: 999px;
    background: #f59e0b;
    color: #111827;
    font-size: 11px;
    font-weight: 900;
}

@media (max-width: 700px) {
    .ad-upload-preview {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ad-upload-preview-item {
        height: 118px;
    }
}





/* ===== ADS UPLOAD PREVIEW + DELETE PHOTO ===== */

.ad-upload-preview-box {
    padding: 14px;
    border: 1px dashed #cbd5e1;
    border-radius: 16px;
    background: #f8fafc;
}

.ad-upload-preview-box strong,
.ad-upload-preview-box small {
    display: block;
}

.ad-upload-preview-box small {
    margin-top: 4px;
    color: #64748b;
}

.ad-upload-preview {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
    margin-top: 12px;
}

.ad-upload-preview-empty,
.ad-upload-preview-error {
    grid-column: 1 / -1;
    margin: 0;
    padding: 12px;
    border-radius: 12px;
    background: #ffffff;
    color: #64748b;
}

.ad-upload-preview-error {
    color: #b91c1c;
    background: #fee2e2;
}

.ad-upload-preview-item,
.classified-existing-photo {
    position: relative;
    height: 100px;
    overflow: hidden;
    border-radius: 14px;
    background: #e2e8f0;
}

.ad-upload-preview-item img,
.classified-existing-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.ad-upload-preview-item span,
.classified-existing-photo span {
    position: absolute;
    left: 7px;
    top: 7px;
    min-width: 24px;
    min-height: 24px;
    padding: 3px 7px;
    border-radius: 999px;
    background: rgba(15, 23, 42, .78);
    color: #ffffff;
    font-size: 12px;
    font-weight: 900;
}

.ad-upload-preview-item span.is-cover,
.classified-existing-photo span {
    background: #f59e0b;
    color: #111827;
}

.classified-existing-photo form {
    position: absolute;
    right: 7px;
    bottom: 7px;
    margin: 0;
}

.classified-existing-photo button {
    min-height: 0;
    padding: 6px 9px;
    border: 0;
    border-radius: 999px;
    background: rgba(220, 38, 38, .94);
    color: #ffffff;
    font-size: 12px;
    font-weight: 800;
    cursor: pointer;
}

@media (max-width: 700px) {
    .ad-upload-preview,
    .classified-existing-gallery-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ad-upload-preview-item,
    .classified-existing-photo {
        height: 118px;
    }
}





/* ===== FIX PHOTO DISPLAY ===== */

.classified-card-image {
    position: relative;
    width: 100%;
    height: 220px !important;
    overflow: hidden;
    background: #e5e7eb;
}

.classified-card-image img {
    position: absolute;
    inset: 0;
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
    z-index: 1;
}

.classified-card-image picture,
.classified-card-image a {
    display: block;
    width: 100%;
    height: 100%;
}

.ad-no-image {
    width: 100%;
    height: 100%;
    min-height: 0 !important;
}



/* ===== FINAL FIX: показываем фото поверх всех заглушек ===== */

.classified-card-image::before,
.classified-card-image::after {
    content: none !important;
    display: none !important;
}

.classified-card-image {
    background: transparent !important;
}

.classified-card-image img {
    position: relative !important;
    z-index: 999 !important;
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
}

/* =========================
   CLASSIFIEDS ANTI-ADBLOCK IMAGE FIX
   Public image/card classes do not use "ads" / "ad" words.
========================= */

.classified-card {
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow: hidden;
    border-radius: 22px;
    background: #fff;
    border: 1px solid #e2e8f0;
    color: inherit !important;
    text-decoration: none !important;
    box-shadow: 0 14px 34px rgba(15, 23, 42, .08);
}

.classified-photo-frame {
    position: relative;
    width: 100%;
    height: 220px;
    overflow: hidden;
    flex: 0 0 auto;
    border-radius: 22px 22px 0 0;
    background: #e5e7eb;
}

.classified-photo-frame::before,
.classified-photo-frame::after {
    content: none !important;
    display: none !important;
}

.classified-photo-frame img,
.classified-photo-img {
    width: 100% !important;
    height: 100% !important;
    max-width: none !important;
    max-height: none !important;
    display: block !important;
    object-fit: cover !important;
    object-position: center center !important;
    opacity: 1 !important;
    visibility: visible !important;
    filter: none !important;
    mix-blend-mode: normal !important;
}

.classified-photo-empty {
    width: 100%;
    height: 140px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 8px;
    border-radius: 22px 22px 0 0;
    background: radial-gradient(circle at 30% 20%, #fff, transparent 32%), linear-gradient(135deg, #f8fafc, #e2e8f0);
    color: #64748b;
    font-weight: 900;
}

.classified-photo-empty span { font-size: 34px; line-height: 1; }
.classified-photo-empty small { color: #64748b; font-weight: 900; }

.classified-main-photo {
    position: relative;
    display: block;
    width: 100%;
    padding: 0;
    border: 0;
    border-radius: 18px;
    overflow: hidden;
    background: #e2e8f0;
    cursor: zoom-in;
}

.classified-main-photo img {
    width: 100% !important;
    max-height: 560px;
    min-height: 320px;
    object-fit: cover !important;
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
    filter: none !important;
}

.classified-photo-mark {
    position: absolute;
    top: 14px;
    left: 14px;
    z-index: 5;
    padding: 7px 12px;
    border-radius: 999px;
    background: #f59e0b;
    color: #111827;
    font-weight: 950;
    text-transform: uppercase;
}

.classified-photo-mark.premium { background: #111827; color: #fff; }

.classified-photo-count {
    position: absolute;
    left: 14px;
    bottom: 14px;
    z-index: 5;
    padding: 9px 12px;
    border-radius: 999px;
    background: rgba(15, 23, 42, .78);
    color: #fff;
    font-weight: 900;
}

.classified-thumbs {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 8px;
    margin-top: 10px;
}

.classified-thumb {
    height: 78px;
    padding: 0;
    border: 0;
    border-radius: 12px;
    overflow: hidden;
    background: #e2e8f0;
    cursor: zoom-in;
}

.classified-thumb img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    display: block !important;
}

.related-classified-card {
    display: grid;
    gap: 7px;
    color: inherit !important;
    text-decoration: none !important;
}

.related-classified-card img,
.related-no-image {
    width: 100% !important;
    height: 110px !important;
    object-fit: cover !important;
    border-radius: 14px;
    display: block !important;
}

.related-classified-card strong { line-height: 1.2; }
.related-classified-card span { color: #111827; font-weight: 900; }

.classified-existing-gallery { margin-top: 22px; }
.classified-existing-gallery h3 { margin: 0 0 12px; color: #111827; }

.classified-existing-gallery-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
}

.classified-existing-photo {
    position: relative;
    height: 100px;
    overflow: hidden;
    border-radius: 14px;
    background: #e2e8f0;
}

.classified-existing-photo img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    display: block !important;
}

.classified-existing-photo span {
    position: absolute;
    left: 7px;
    top: 7px;
    min-width: 24px;
    min-height: 24px;
    padding: 3px 7px;
    border-radius: 999px;
    background: #f59e0b;
    color: #111827;
    font-size: 12px;
    font-weight: 900;
}

.classified-existing-photo form { position: absolute; right: 7px; bottom: 7px; margin: 0; }

.classified-existing-photo button {
    min-height: 0;
    padding: 6px 9px;
    border: 0;
    border-radius: 999px;
    background: rgba(220, 38, 38, .94);
    color: #fff;
    font-size: 12px;
    font-weight: 900;
    cursor: pointer;
}

@media (max-width: 700px) {
    .classified-photo-frame { height: 220px; }
    .classified-thumbs { grid-template-columns: repeat(4, 1fr); }
    .classified-existing-gallery-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .classified-existing-photo { height: 118px; }
}



/* ===== FAVORITES + PHONE REVEAL ===== */

.classified-card {
    position: relative;
}

.classified-card-link {
    display: flex;
    flex-direction: column;
    flex: 1;
    color: inherit !important;
    text-decoration: none !important;
}

.classified-favorite-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 8;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, .94);
    color: #111827;
    font-size: 24px;
    line-height: 1;
    font-weight: 900;
    cursor: pointer;
    box-shadow: 0 10px 24px rgba(15, 23, 42, .16);
}

.classified-favorite-btn.is-active {
    background: #fee2e2;
    color: #dc2626;
}

.ad-contact-action.favorite.is-active {
    background: #fee2e2;
    color: #dc2626 !important;
}

.ad-phone-hidden {
    padding: 12px;
    border-radius: 14px;
    background: #f8fafc;
    border: 1px dashed #cbd5e1;
}

.ad-mobile-contact-bar button {
    border: 0;
    min-height: 44px;
    border-radius: 14px;
    background: #16a34a;
    color: #fff !important;
    text-decoration: none !important;
    font-weight: 950;
    cursor: pointer;
}

/* ===== TELEGRAM BUTTON COLOR FIX ===== */

.ad-contact-action.telegram {
    background: linear-gradient(135deg, #2AABEE 0%, #229ED9 100%) !important;
    color: #ffffff !important;
}

.ad-contact-action.telegram:hover {
    filter: brightness(1.05);
}

.portal-lightbox__action[href*="t.me"],
.portal-lightbox__action[href*="telegram"] {
    background: linear-gradient(135deg, #2AABEE 0%, #229ED9 100%) !important;
    color: #ffffff !important;
}

.ad-mobile-contact-bar a[href*="t.me"],
.ad-mobile-contact-bar a[href*="telegram"] {
    background: linear-gradient(135deg, #2AABEE 0%, #229ED9 100%) !important;
    color: #ffffff !important;
}

.ad-mobile-contact-bar button {
    background: #16a34a !important;
    color: #ffffff !important;
}

/* ===== PHOTO DRAG DROP SORTER ===== */

.ad-photo-uploader {
    margin-top: 12px;
    padding: 16px;
    border: 2px dashed #cbd5e1;
    border-radius: 18px;
    background:
        radial-gradient(circle at 20% 10%, rgba(37, 99, 235, .08), transparent 30%),
        #f8fafc;
}

.ad-photo-uploader.is-dragover {
    border-color: #2563eb;
    background:
        radial-gradient(circle at 20% 10%, rgba(37, 99, 235, .14), transparent 32%),
        #eff6ff;
}

.ad-photo-uploader-head {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    align-items: flex-start;
    margin-bottom: 12px;
}

.ad-photo-uploader-title {
    display: grid;
    gap: 4px;
}

.ad-photo-uploader-title strong {
    color: #111827;
    font-size: 16px;
}

.ad-photo-uploader-title small {
    color: #64748b;
    line-height: 1.35;
}

.ad-photo-counter {
    flex: 0 0 auto;
    padding: 7px 10px;
    border-radius: 999px;
    background: #ffffff;
    color: #111827;
    font-weight: 900;
    border: 1px solid #e2e8f0;
}

.ad-photo-pick-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 16px;
    border-radius: 14px;
    background: #2563eb;
    color: #ffffff !important;
    font-weight: 900;
    cursor: pointer;
    text-decoration: none !important;
    box-shadow: 0 10px 22px rgba(37, 99, 235, .22);
}

.ad-photo-pick-btn input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.ad-upload-preview {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
    margin-top: 14px;
}

.ad-upload-preview-empty,
.ad-upload-preview-error {
    grid-column: 1 / -1;
    margin: 0;
    padding: 14px;
    border-radius: 14px;
    background: #ffffff;
    color: #64748b;
    font-weight: 800;
}

.ad-upload-preview-error {
    color: #b91c1c;
    background: #fee2e2;
}

.ad-upload-preview-item {
    position: relative;
    height: 112px;
    overflow: hidden;
    border-radius: 16px;
    background: #e2e8f0;
    border: 2px solid transparent;
    box-shadow: 0 8px 18px rgba(15, 23, 42, .08);
    cursor: grab;
    touch-action: none;
}

.ad-upload-preview-item:active {
    cursor: grabbing;
}

.ad-upload-preview-item.is-dragging {
    opacity: .45;
    transform: scale(.96);
}

.ad-upload-preview-item.is-cover {
    border-color: #f59e0b;
}

.ad-upload-preview-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    pointer-events: none;
}

.ad-upload-preview-badge {
    position: absolute;
    left: 7px;
    top: 7px;
    z-index: 2;
    min-width: 24px;
    min-height: 24px;
    padding: 4px 8px;
    border-radius: 999px;
    background: rgba(15, 23, 42, .78);
    color: #ffffff;
    font-size: 12px;
    font-weight: 900;
}

.ad-upload-preview-item.is-cover .ad-upload-preview-badge {
    background: #f59e0b;
    color: #111827;
}

.ad-upload-remove {
    position: absolute;
    right: 7px;
    top: 7px;
    z-index: 3;
    width: 28px;
    height: 28px;
    border: 0;
    border-radius: 999px;
    background: rgba(220, 38, 38, .95);
    color: #ffffff;
    font-size: 18px;
    font-weight: 900;
    line-height: 1;
    cursor: pointer;
}

.ad-upload-handle {
    position: absolute;
    left: 7px;
    bottom: 7px;
    z-index: 2;
    padding: 4px 7px;
    border-radius: 999px;
    background: rgba(255, 255, 255, .92);
    color: #111827;
    font-size: 12px;
    font-weight: 900;
}

.ad-upload-preview-note {
    margin: 10px 0 0;
    color: #64748b;
    font-size: 13px;
}

@media (max-width: 700px) {
    .ad-photo-uploader-head {
        display: grid;
    }

    .ad-photo-counter {
        justify-self: start;
    }

    .ad-upload-preview {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ad-upload-preview-item {
        height: 132px;
    }
}

/* ===== FIX CATEGORY BADGE GREEN ===== */
.classified-category-badge {
    background: linear-gradient(135deg, #16a34a, #15803d) !important;
    color: #ffffff !important;
    box-shadow: 0 10px 24px rgba(22, 163, 74, .28) !important;
}

/* ===== GREEN CATEGORY BADGE ON PHOTO ===== */

.classified-photo-frame {
    position: relative !important;
}

.classified-media-top {
    position: absolute;
    left: 14px;
    top: 14px;
    right: 14px;
    z-index: 20;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    pointer-events: none;
}

.classified-category-badge {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    min-height: 36px;
    padding: 0 13px;
    border-radius: 999px;
    background: linear-gradient(135deg, #16a34a, #15803d) !important;
    color: #ffffff !important;
    font-size: 13px;
    font-weight: 900;
    box-shadow: 0 10px 24px rgba(22, 163, 74, .28) !important;
    pointer-events: auto;
}

/* =========================================================
   QUICK VIEW + VIP/PREMIUM POLISH
   Safe additive block
========================================================= */

.classified-card {
    position: relative;
}

.classified-card.is-vip {
    border-color: rgba(245, 158, 11, .9) !important;
    box-shadow: 0 18px 45px rgba(245, 158, 11, .18) !important;
}

.classified-card.is-premium {
    border-color: rgba(17, 24, 39, .24) !important;
    box-shadow: 0 18px 45px rgba(15, 23, 42, .11) !important;
}

.classified-status-badge,
.ad-badge {
    z-index: 25;
}

.classified-quick-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: calc(100% - 28px);
    min-height: 48px;
    margin: 0 14px 14px;
    border: 0;
    border-radius: 16px;
    background: linear-gradient(135deg, #1f2937, #111827);
    color: #ffffff;
    font-size: 15px;
    font-weight: 900;
    cursor: pointer;
    box-shadow: 0 12px 28px rgba(15, 23, 42, .22);
}

.classified-quick-btn:hover {
    transform: translateY(-2px);
}

.classified-favorite-btn,
.classified-save-action {
    transition: transform .18s ease, background .18s ease, color .18s ease;
}

.classified-favorite-btn.is-active,
.classified-save-action.is-active,
.quick-view-action.favorite.is-active {
    background: #fee2e2 !important;
    color: #dc2626 !important;
}

.classified-favorite-btn:active,
.classified-save-action:active,
.quick-view-action.favorite:active {
    transform: scale(.96);
}

/* Quick modal */

.quick-view-overlay {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: none;
}

.quick-view-overlay.is-open {
    display: block;
}

.quick-view-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, .78);
    backdrop-filter: blur(5px);
}

.quick-view-dialog {
    position: absolute;
    left: 50%;
    top: 50%;
    width: min(980px, calc(100vw - 20px));
    max-height: calc(100vh - 20px);
    overflow: auto;
    transform: translate(-50%, -50%);
    border-radius: 28px;
    background: #ffffff;
    box-shadow: 0 30px 80px rgba(0,0,0,.35);
}

.quick-view-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.08fr) 420px;
    min-height: 540px;
}

.quick-view-gallery {
    background: #0f172a;
}

.quick-view-gallery img {
    width: 100%;
    height: 100%;
    min-height: 540px;
    object-fit: cover;
    display: block;
}

.quick-view-body {
    display: flex;
    flex-direction: column;
    padding: 26px;
}

.quick-view-close {
    position: absolute;
    top: 16px;
    right: 16px;
    z-index: 20;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 999px;
    background: rgba(15,23,42,.75);
    color: #ffffff;
    font-size: 30px;
    cursor: pointer;
}

.quick-view-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
    color: #64748b;
    font-size: 13px;
    font-weight: 800;
}

.quick-view-title {
    margin: 0 0 14px;
    color: #111827;
    font-size: clamp(28px, 3vw, 40px);
    line-height: 1.05;
    letter-spacing: -.04em;
}

.quick-view-price {
    margin-bottom: 18px;
    color: #111827;
    font-size: 34px;
    font-weight: 950;
}

.quick-view-description {
    color: #334155;
    line-height: 1.6;
    font-size: 15px;
}

.quick-view-actions {
    display: grid;
    gap: 10px;
    margin-top: auto;
    padding-top: 22px;
}

.quick-view-action {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    border: 0;
    border-radius: 14px;
    text-decoration: none !important;
    font-weight: 900;
    cursor: pointer;
}

.quick-view-action.primary {
    background: #111827;
    color: #ffffff !important;
}

.quick-view-action.phone {
    background: #16a34a;
    color: #ffffff !important;
}

.quick-view-action.telegram {
    background: linear-gradient(135deg, #2AABEE 0%, #229ED9 100%);
    color: #ffffff !important;
}

.quick-view-action.favorite {
    background: #f1f5f9;
    color: #111827 !important;
}

@media (max-width: 860px) {
    .quick-view-dialog {
        width: calc(100vw - 10px);
        max-height: calc(100vh - 10px);
        border-radius: 24px;
    }

    .quick-view-grid {
        grid-template-columns: 1fr;
        min-height: 0;
    }

    .quick-view-gallery img {
        min-height: 260px;
        max-height: 310px;
    }

    .quick-view-body {
        padding: 18px;
    }
}



/* ===== VIP / PREMIUM BADGE FIX =====
   Рубрика остаётся зелёной слева сверху.
   VIP/Premium уходит вниз слева и не перекрывает рубрику.
*/

.classified-photo-frame {
    position: relative !important;
}

.classified-media-top {
    position: absolute !important;
    left: 14px !important;
    top: 14px !important;
    right: 78px !important;
    z-index: 30 !important;
    display: flex !important;
    align-items: flex-start !important;
    justify-content: flex-start !important;
    pointer-events: none !important;
}

.classified-category-badge {
    max-width: 100% !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    background: linear-gradient(135deg, #16a34a, #15803d) !important;
    color: #ffffff !important;
    box-shadow: 0 10px 24px rgba(22, 163, 74, .28) !important;
}

.classified-favorite-btn {
    z-index: 35 !important;
}

.ad-badge,
.classified-status-badge {
    position: absolute !important;
    left: 14px !important;
    top: auto !important;
    bottom: 14px !important;
    right: auto !important;
    z-index: 30 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    min-height: 34px !important;
    padding: 0 12px !important;
    border-radius: 999px !important;
    font-size: 12px !important;
    line-height: 1 !important;
    font-weight: 950 !important;
    letter-spacing: .03em !important;
    text-transform: uppercase !important;
    box-shadow: 0 10px 24px rgba(15, 23, 42, .22) !important;
}

.ad-badge,
.classified-status-badge.vip {
    background: linear-gradient(135deg, #fbbf24, #f59e0b) !important;
    color: #111827 !important;
}

.ad-badge.premium,
.classified-status-badge.premium {
    background: linear-gradient(135deg, #111827, #334155) !important;
    color: #ffffff !important;
}

.classified-photo-count {
    position: absolute !important;
    right: 14px !important;
    bottom: 14px !important;
    left: auto !important;
    z-index: 30 !important;
}

.classified-card.is-vip {
    border-color: rgba(245, 158, 11, .8) !important;
}

.classified-card.is-premium {
    border-color: rgba(17, 24, 39, .22) !important;
}

@media (max-width: 700px) {
    .classified-media-top {
        left: 12px !important;
        top: 12px !important;
        right: 74px !important;
    }

    .ad-badge,
    .classified-status-badge {
        left: 12px !important;
        bottom: 12px !important;
    }

    .classified-photo-count {
        right: 12px !important;
        bottom: 12px !important;
    }
}



/* =========================================================
   FAVORITES PAGE
========================================================= */

.favorites-page {
    padding-bottom: 96px;
}

.favorites-hero {
    align-items: center;
}

.favorites-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin: 0 0 18px;
    padding: 16px 18px;
    border-radius: 18px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    box-shadow: 0 12px 30px rgba(15, 23, 42, .06);
}

.favorites-toolbar strong {
    color: #111827;
    font-size: 22px;
    font-weight: 950;
}

.favorites-toolbar span {
    color: #64748b;
    font-weight: 800;
}

.favorites-toolbar button {
    min-height: 42px;
    padding: 0 14px;
    border: 0;
    border-radius: 14px;
    background: #fee2e2;
    color: #dc2626;
    font-weight: 900;
    cursor: pointer;
}

.favorites-toolbar button:disabled {
    opacity: .45;
    cursor: not-allowed;
}

.favorites-empty {
    padding: 34px 20px;
    border-radius: 24px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    text-align: center;
    box-shadow: 0 12px 30px rgba(15, 23, 42, .06);
}

.favorites-empty[hidden] {
    display: none !important;
}

.favorites-empty-icon {
    width: 74px;
    height: 74px;
    margin: 0 auto 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: #f8fafc;
    color: #111827;
    font-size: 46px;
    line-height: 1;
    box-shadow: inset 0 0 0 1px #e2e8f0;
}

.favorites-empty h2 {
    margin: 0 0 8px;
    color: #111827;
    font-size: 26px;
    letter-spacing: -.03em;
}

.favorites-empty p {
    margin: 0 auto 16px;
    max-width: 420px;
    color: #64748b;
    line-height: 1.5;
}

.favorites-empty a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 16px;
    border-radius: 14px;
    background: #111827;
    color: #ffffff !important;
    text-decoration: none !important;
    font-weight: 900;
}

.favorites-list {
    display: grid;
    gap: 12px;
}

.favorite-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    align-items: center;
    gap: 12px;
    padding: 16px;
    border-radius: 18px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    box-shadow: 0 12px 30px rgba(15, 23, 42, .06);
}

.favorite-card-title {
    color: #111827 !important;
    text-decoration: none !important;
    font-weight: 950;
    font-size: 18px;
    line-height: 1.25;
}

.favorite-card-link {
    min-height: 40px;
    padding: 0 13px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: #111827;
    color: #ffffff !important;
    text-decoration: none !important;
    font-weight: 900;
}

.favorite-card-remove {
    min-height: 40px;
    padding: 0 13px;
    border: 0;
    border-radius: 12px;
    background: #f1f5f9;
    color: #475569;
    font-weight: 900;
    cursor: pointer;
}

@media (max-width: 700px) {
    .favorites-toolbar {
        display: grid;
    }

    .favorite-card {
        grid-template-columns: 1fr;
    }

    .favorite-card-link,
    .favorite-card-remove {
        width: 100%;
    }
}


/* =========================================
   ADS MAGIC POLISH
   stronger VIP/Premium + smoother action layer
========================================= */
.classified-card.is-vip {
    border-color: #fbbf24 !important;
    box-shadow: 0 18px 48px rgba(245, 158, 11, .24), inset 0 0 0 1px rgba(251,191,36,.35) !important;
}

.classified-card.is-vip::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(120deg, transparent 0%, rgba(255,255,255,.0) 35%, rgba(255,255,255,.35) 48%, rgba(255,255,255,0) 62%, transparent 100%);
    transform: translateX(-120%);
    animation: vipShimmer 4.8s ease-in-out infinite;
}

@keyframes vipShimmer { 0%, 55% { transform: translateX(-120%); } 78%, 100% { transform: translateX(120%); } }

.ad-badge-vip,
.classified-photo-mark:not(.premium) {
    background: linear-gradient(135deg, #fde68a, #f59e0b, #f97316) !important;
    color: #111827 !important;
    box-shadow: 0 8px 18px rgba(245,158,11,.38) !important;
}

.ad-badge-premium,
.classified-photo-mark.premium {
    background: linear-gradient(135deg, #172554, #2563eb) !important;
    color: #ffffff !important;
    box-shadow: 0 8px 18px rgba(37,99,235,.32) !important;
}

.classified-card-floating-actions {
    opacity: .96;
}

.classified-card:hover .classified-card-floating-actions {
    opacity: 1;
    transform: translateY(-2px);
}

@media (max-width: 700px) {
    .classified-card.is-vip::after { display: none; }
}


/* ===== ads_olx.css ===== */
/* OLX/Allegro inspired ads redesign. Safe override file. */

.ads-olx-page {
    --ads-ink: #082f35;
    --ads-muted: #667985;
    --ads-line: #dfe8eb;
    --ads-soft: #f3f7f8;
    --ads-teal: #064f55;
    --ads-teal-2: #007782;
    --ads-green: #1fa463;
    --ads-yellow: #ffc400;
    --ads-purple: #6c4ee6;
    --ads-orange: #ff6a00;
    color: var(--ads-ink);
}

.ads-olx-hero {
    background:
        radial-gradient(circle at 12% 10%, rgba(0, 119, 130, .11), transparent 30%),
        linear-gradient(135deg, #ffffff, #f4fbfb);
    border: 1px solid var(--ads-line);
    box-shadow: 0 12px 34px rgba(8, 47, 53, .07);
}

.ads-olx-search {
    background: #ffffff;
    border: 1px solid var(--ads-line);
    box-shadow: 0 8px 28px rgba(8, 47, 53, .06);
}

.ads-olx-search button,
.ads-side-filter button,
.ads-add-btn {
    background: linear-gradient(135deg, #063f46, #075d64) !important;
    color: #ffffff !important;
    border: none !important;
    box-shadow: 0 10px 22px rgba(6, 79, 85, .22);
}

.ads-olx-categories {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding: 12px 4px 14px;
    scrollbar-width: thin;
}

.ads-olx-categories a {
    flex: 0 0 auto;
    background: #ffffff;
    border: 1px solid var(--ads-line);
    color: var(--ads-ink);
    border-radius: 999px;
    padding: 10px 16px;
    font-weight: 900;
    box-shadow: 0 5px 16px rgba(8, 47, 53, .04);
}

.ads-olx-categories a.active,
.ads-olx-categories a:hover {
    background: #e9fbfd;
    border-color: #9de5e9;
    color: var(--ads-teal);
    text-decoration: none;
}

.ads-market-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 330px;
    gap: 24px;
    align-items: start;
}

.ads-market-main {
    min-width: 0;
}

.ads-olx-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin: 10px 0 16px;
}

.ads-olx-head h2 {
    margin-bottom: 2px;
}

.ads-sort-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 0 16px;
    border: 1px solid var(--ads-line);
    border-radius: 14px;
    background: #ffffff;
    color: var(--ads-ink);
    font-weight: 900;
    box-shadow: 0 6px 18px rgba(8, 47, 53, .04);
    white-space: nowrap;
}

.ads-list-modern {
    display: flex !important;
    flex-direction: column;
    gap: 14px;
}

.ads-list-modern .classified-card {
    position: relative;
    display: grid;
    grid-template-columns: 255px minmax(0, 1fr) auto;
    min-height: 188px;
    overflow: hidden;
    background: #ffffff;
    border: 1px solid var(--ads-line);
    border-radius: 18px;
    box-shadow: 0 9px 24px rgba(8, 47, 53, .055);
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.ads-list-modern .classified-card:hover {
    transform: translateY(-2px);
    border-color: #b9dce0;
    box-shadow: 0 18px 36px rgba(8, 47, 53, .1);
}

.ads-list-modern .classified-card.is-vip {
    border-color: rgba(255, 196, 0, .9);
    box-shadow:
        0 0 0 1px rgba(255, 196, 0, .28),
        0 16px 38px rgba(255, 196, 0, .13);
}

.ads-list-modern .classified-card.is-premium {
    border-color: rgba(108, 78, 230, .58);
    box-shadow:
        0 0 0 1px rgba(108, 78, 230, .13),
        0 16px 38px rgba(108, 78, 230, .09);
}

.ads-list-modern .classified-card-link {
    display: contents;
    color: inherit;
    text-decoration: none;
}

.ads-list-modern .classified-photo-frame {
    position: relative;
    min-height: 188px;
    background: #eef3f4;
    overflow: hidden;
}

.ads-list-modern .classified-photo-img,
.ads-list-modern .classified-photo-empty {
    width: 100%;
    height: 100%;
    min-height: 188px;
    object-fit: cover;
    display: block;
}

.ads-list-modern .classified-photo-empty {
    display: flex;
    flex-direction: column;
    gap: 8px;
    align-items: center;
    justify-content: center;
    color: #71828a;
    background: linear-gradient(135deg, #eef3f4, #f7fafb);
    font-weight: 900;
}

.ads-list-modern .classified-category-badge {
    position: absolute;
    left: 12px;
    top: 12px;
    z-index: 3;
    max-width: calc(100% - 24px);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    background: rgba(0, 122, 87, .96);
    color: #ffffff;
    border-radius: 999px;
    padding: 8px 12px;
    font-weight: 950;
    font-size: 14px;
    box-shadow: 0 8px 18px rgba(0, 0, 0, .13);
}

.ads-list-modern .ad-badge {
    position: absolute;
    left: 0;
    bottom: 18px;
    z-index: 4;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 9px 14px 9px 12px;
    border-radius: 0 999px 999px 0;
    color: #ffffff;
    font-size: 14px;
    font-weight: 950;
    letter-spacing: .02em;
    text-transform: uppercase;
    box-shadow: 0 10px 22px rgba(0, 0, 0, .18);
}

.ads-list-modern .ad-badge-vip {
    background: linear-gradient(135deg, #ffb300, #ff7b00);
    color: #221300;
}

.ads-list-modern .ad-badge-premium {
    background: linear-gradient(135deg, #7c5cff, #3e2dc3);
}

.ads-list-modern .classified-card.is-vip::before,
.ads-list-modern .classified-card.is-premium::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 5px;
    z-index: 5;
}

.ads-list-modern .classified-card.is-vip::before {
    background: linear-gradient(#ffb300, #ff7b00);
}

.ads-list-modern .classified-card.is-premium::before {
    background: linear-gradient(#7c5cff, #3e2dc3);
}

.ads-list-modern .classified-photo-count {
    position: absolute;
    left: 12px;
    bottom: 12px;
    z-index: 6;
    background: rgba(0, 0, 0, .72);
    color: #ffffff;
    border-radius: 10px;
    padding: 6px 9px;
    font-size: 13px;
    font-weight: 900;
}

.ads-list-modern .classified-card-body {
    min-width: 0;
    padding: 20px 22px;
    display: flex;
    flex-direction: column;
    gap: 9px;
}

.ads-list-modern .classified-card-topline {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    color: var(--ads-muted);
    font-size: 14px;
    font-weight: 750;
}

.ads-list-modern .classified-card-body h3 {
    margin: 0;
    color: #101923;
    font-size: 22px;
    line-height: 1.2;
    letter-spacing: -.02em;
}

.ads-list-modern .classified-card:hover h3 {
    color: var(--ads-teal-2);
}

.ads-list-modern .classified-card-price {
    display: block;
    color: var(--ads-teal);
    font-size: 27px;
    line-height: 1;
    font-weight: 950;
    letter-spacing: -.03em;
}

.ads-list-modern .classified-card-price.muted {
    color: #4d5b63;
    font-size: 22px;
}

.ads-list-modern .classified-card-desc {
    margin: 0;
    color: #4b616b;
    font-size: 15px;
    line-height: 1.42;
}

.ads-list-modern .classified-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-top: auto;
}

.ads-list-modern .classified-type-chip {
    display: inline-flex;
    align-items: center;
    background: #eef3f4;
    color: #50626b;
    border-radius: 999px;
    padding: 6px 10px;
    font-size: 13px;
    font-weight: 900;
}

.ads-list-modern .classified-views {
    color: var(--ads-muted);
    font-weight: 800;
    white-space: nowrap;
}

.ads-list-modern .classified-favorite-btn {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 8;
    width: 48px;
    height: 48px;
    border: 1px solid rgba(8, 47, 53, .10);
    border-radius: 50%;
    background: rgba(255, 255, 255, .95);
    color: #0b2730;
    font-size: 29px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 22px rgba(8, 47, 53, .10);
    cursor: pointer;
    transition: transform .16s ease, background .16s ease, color .16s ease;
}

.ads-list-modern .classified-favorite-btn:hover {
    transform: scale(1.06);
}

.ads-list-modern .classified-favorite-btn.is-active {
    background: #ffe2e6;
    border-color: #ffc2ca;
    color: #e21d3d;
}

.ads-list-modern .classified-quick-btn {
    align-self: end;
    justify-self: end;
    margin: 0 18px 18px 0;
    min-width: 178px;
    height: 48px;
    padding: 0 18px;
    border: none;
    border-radius: 14px;
    background: linear-gradient(135deg, #0d1728, #111c31);
    color: #ffffff;
    font-weight: 950;
    cursor: pointer;
    box-shadow: 0 11px 22px rgba(13, 23, 40, .17);
}

.ads-list-modern .classified-quick-btn:hover {
    filter: brightness(1.07);
}

.ads-market-sidebar {
    position: sticky;
    top: 90px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.ads-filter-card,
.ads-side-card {
    background: #ffffff;
    border: 1px solid var(--ads-line);
    border-radius: 18px;
    padding: 20px;
    box-shadow: 0 9px 24px rgba(8, 47, 53, .055);
}

.ads-filter-card-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.ads-filter-card-head h3 {
    margin: 0;
    font-size: 22px;
}

.ads-filter-card-head a {
    color: var(--ads-teal-2);
    font-weight: 900;
}

.ads-side-filter {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.ads-side-filter label {
    display: flex;
    flex-direction: column;
    gap: 7px;
    color: #26343b;
    font-weight: 900;
}

.ads-side-filter input {
    width: 100%;
    min-height: 46px;
    border: 1px solid var(--ads-line);
    border-radius: 12px;
    padding: 0 13px;
    font: inherit;
    color: var(--ads-ink);
    background: #fbfdfd;
}

.ads-side-filter button {
    min-height: 48px;
    border-radius: 12px;
    font-weight: 950;
    cursor: pointer;
}

.ads-side-card strong {
    display: block;
    margin-bottom: 8px;
    font-size: 17px;
}

.ads-side-card p {
    margin: 0;
    color: var(--ads-muted);
    line-height: 1.45;
}

.ads-promo-side-card {
    background: linear-gradient(135deg, #fff9e8, #ffffff);
    border-color: rgba(255, 196, 0, .45);
}

.ads-promo-side-card a {
    display: inline-flex;
    margin-top: 14px;
    background: var(--ads-teal);
    color: #ffffff;
    border-radius: 12px;
    padding: 10px 14px;
    font-weight: 950;
    text-decoration: none;
}

/* Favorites */
.favorites-page .favorites-toolbar {
    background: #ffffff;
    border: 1px solid var(--ads-line);
    box-shadow: 0 9px 24px rgba(8, 47, 53, .055);
}

.favorites-page .favorites-empty {
    background: #ffffff;
    border: 1px dashed #b9dce0;
}

/* Quick view polish */
.quick-view-dialog {
    border-radius: 24px !important;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,.45) !important;
}

.quick-view-action.primary {
    background: linear-gradient(135deg, #063f46, #075d64) !important;
}

/* Detail page smaller polish */
.ad-detail-page .ad-contact-box,
.ad-detail-page .ad-detail-card,
.ad-detail-page .related-ads {
    border-color: var(--ads-line);
    box-shadow: 0 9px 24px rgba(8, 47, 53, .055);
}

@media (max-width: 1020px) {
    .ads-market-layout {
        grid-template-columns: 1fr;
    }

    .ads-market-sidebar {
        position: static;
        order: -1;
    }

    .ads-filter-card {
        display: none;
    }
}

@media (max-width: 760px) {
    .ads-olx-page {
        margin-left: -6px;
        margin-right: -6px;
    }

    .ads-olx-hero {
        border-radius: 22px;
    }

    .ads-olx-search {
        display: grid;
        gap: 10px;
    }

    .ads-olx-head {
        align-items: flex-start;
    }

    .ads-sort-chip {
        display: none;
    }

    .ads-list-modern {
        gap: 16px;
    }

    .ads-list-modern .classified-card {
        display: block;
        border-radius: 22px;
        min-height: 0;
    }

    .ads-list-modern .classified-card-link {
        display: block;
    }

    .ads-list-modern .classified-photo-frame,
    .ads-list-modern .classified-photo-img,
    .ads-list-modern .classified-photo-empty {
        min-height: 0;
        height: 245px;
    }

    .ads-list-modern .classified-card-body {
        padding: 18px 18px 78px;
    }

    .ads-list-modern .classified-card-body h3 {
        font-size: 24px;
    }

    .ads-list-modern .classified-card-price {
        font-size: 30px;
    }

    .ads-list-modern .classified-quick-btn {
        position: absolute;
        left: 18px;
        right: 18px;
        bottom: 16px;
        width: auto;
        margin: 0;
        height: 54px;
        border-radius: 17px;
        font-size: 16px;
    }

    .ads-list-modern .classified-favorite-btn {
        width: 54px;
        height: 54px;
        top: 14px;
        right: 14px;
        font-size: 31px;
    }

    .ads-list-modern .ad-badge {
        bottom: 18px;
        font-size: 15px;
        padding: 10px 15px 10px 13px;
    }

    .ads-market-sidebar {
        display: none;
    }
}

@media (max-width: 420px) {
    .ads-list-modern .classified-photo-frame,
    .ads-list-modern .classified-photo-img,
    .ads-list-modern .classified-photo-empty {
        height: 218px;
    }

    .ads-list-modern .classified-card-body h3 {
        font-size: 22px;
    }

    .ads-list-modern .classified-card-price {
        font-size: 28px;
    }
}

/* === GOLD VIP / CLEAN SEARCH PATCH === */
.ads-olx-page {
    --vip-gold-1: #fff7d1;
    --vip-gold-2: #ffd447;
    --vip-gold-3: #ffb300;
    --vip-gold-4: #d98a00;
    --premium-1: #ede7ff;
    --premium-2: #7c4dff;
    --premium-3: #4d2fd6;
}

.ads-olx-page .ads-olx-search {
    display: grid !important;
    grid-template-columns: minmax(0, 1.4fr) minmax(160px, .75fr) auto;
    gap: 12px !important;
    align-items: end;
    padding: 18px !important;
    border-radius: 22px !important;
    margin: 18px 0 14px !important;
    overflow: visible !important;
}

.ads-olx-page .ads-olx-search label {
    display: flex !important;
    flex-direction: column !important;
    gap: 7px !important;
    min-width: 0 !important;
    margin: 0 !important;
    color: #52636d !important;
    font-weight: 900 !important;
}

.ads-olx-page .ads-olx-search label span {
    font-size: 14px !important;
    line-height: 1.2 !important;
}

.ads-olx-page .ads-olx-search input {
    width: 100% !important;
    min-height: 50px !important;
    border: 1px solid var(--ads-line) !important;
    border-radius: 15px !important;
    padding: 0 16px !important;
    background: #ffffff !important;
    box-shadow: none !important;
    font: inherit !important;
    color: var(--ads-ink) !important;
    outline: none !important;
}

.ads-olx-page .ads-olx-search input:focus {
    border-color: #8adbe0 !important;
    box-shadow: 0 0 0 4px rgba(0, 119, 130, .10) !important;
}

.ads-olx-page .ads-olx-search button {
    min-width: 140px !important;
    min-height: 50px !important;
    border-radius: 15px !important;
    padding: 0 22px !important;
    font-weight: 950 !important;
    cursor: pointer !important;
}

.ads-list-modern .classified-card.is-vip {
    border-color: rgba(255, 179, 0, .98) !important;
    background:
        linear-gradient(#ffffff, #ffffff) padding-box,
        linear-gradient(135deg, #ffd447, #ffb300, #ff7a00) border-box !important;
    box-shadow:
        0 0 0 2px rgba(255, 196, 0, .36),
        0 18px 42px rgba(255, 179, 0, .22) !important;
}

.ads-list-modern .classified-card.is-vip::before {
    width: 7px !important;
    background: linear-gradient(180deg, #fff2a6, #ffc400 45%, #ff8700) !important;
    box-shadow: 0 0 18px rgba(255, 179, 0, .55) !important;
}

.ads-list-modern .classified-card.is-premium {
    border-color: rgba(124, 77, 255, .72) !important;
    box-shadow:
        0 0 0 1px rgba(124, 77, 255, .18),
        0 16px 38px rgba(124, 77, 255, .13) !important;
}

.ads-list-modern .ad-badge-vip {
    background: linear-gradient(135deg, #fff07a 0%, #ffc400 38%, #ff9d00 100%) !important;
    color: #2b1700 !important;
    border: 1px solid rgba(255, 255, 255, .55) !important;
    text-shadow: 0 1px 0 rgba(255,255,255,.45) !important;
    box-shadow:
        0 10px 20px rgba(255, 145, 0, .34),
        inset 0 1px 0 rgba(255,255,255,.65) !important;
}

.ads-list-modern .ad-badge-premium {
    background: linear-gradient(135deg, #9a7cff, #6c4ee6 55%, #3d2ac2) !important;
    color: #ffffff !important;
    border: 1px solid rgba(255, 255, 255, .32) !important;
    box-shadow:
        0 10px 20px rgba(108, 78, 230, .28),
        inset 0 1px 0 rgba(255,255,255,.28) !important;
}

.ads-promo-info-card {
    background: #ffffff;
    border: 1px solid var(--ads-line);
    border-radius: 18px;
    padding: 18px;
    box-shadow: 0 9px 24px rgba(8, 47, 53, .055);
}

.ads-promo-info-card--vip {
    background: linear-gradient(135deg, #fff9df, #ffffff 65%);
    border-color: rgba(255, 179, 0, .72);
    box-shadow: 0 12px 28px rgba(255, 179, 0, .13);
}

.ads-promo-info-card--premium {
    background: linear-gradient(135deg, #f3efff, #ffffff 68%);
    border-color: rgba(124, 77, 255, .45);
}

.ads-promo-title {
    display: flex;
    align-items: center;
    gap: 9px;
    margin-bottom: 12px;
}

.ads-promo-title span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 12px;
    background: rgba(255,255,255,.74);
    box-shadow: inset 0 0 0 1px rgba(8,47,53,.06);
    font-size: 20px;
}

.ads-promo-title strong {
    color: #0b1728;
    font-size: 20px;
    font-weight: 950;
}

.ads-promo-title em {
    margin-left: auto;
    padding: 5px 8px;
    border-radius: 999px;
    background: rgba(255,255,255,.82);
    color: #6b7280;
    font-style: normal;
    font-size: 12px;
    font-weight: 900;
}

.ads-promo-info-card ul {
    display: grid;
    gap: 8px;
    margin: 0;
    padding: 0;
    list-style: none;
    color: #344650;
    font-weight: 750;
    line-height: 1.35;
}

.ads-promo-info-card li::before {
    content: "✓";
    margin-right: 8px;
    color: #0e8d58;
    font-weight: 950;
}

@media (max-width: 1020px) {
    .ads-market-sidebar .ads-promo-info-card,
    .ads-market-sidebar .ads-side-card {
        display: none;
    }
}

@media (max-width: 760px) {
    .ads-olx-page .ads-olx-search {
        grid-template-columns: 1fr !important;
        padding: 14px !important;
        border-radius: 20px !important;
        gap: 11px !important;
    }

    .ads-olx-page .ads-olx-search button {
        width: 100% !important;
        min-width: 0 !important;
    }

    .ads-list-modern .classified-card.is-vip {
        box-shadow:
            0 0 0 2px rgba(255, 196, 0, .42),
            0 15px 32px rgba(255, 179, 0, .24) !important;
    }

    .ads-list-modern .classified-card.is-vip::before,
    .ads-list-modern .classified-card.is-premium::before {
        width: 6px !important;
    }
}

/* NEXT LEVEL ADS FILTERS / SORT / RECENT */
.ads-filter-panel {
    display: block;
    padding: 16px;
}

.ads-filter-main {
    display: grid;
    grid-template-columns: minmax(220px, 1.6fr) minmax(150px, .9fr) 120px 120px 170px auto;
    gap: 12px;
    align-items: end;
}

.ads-filter-field {
    display: flex;
    flex-direction: column;
    gap: 7px;
    min-width: 0;
}

.ads-filter-field span {
    color: #52606d;
    font-size: 13px;
    font-weight: 900;
}

.ads-filter-field input,
.ads-filter-field select {
    width: 100%;
    height: 44px;
    border: 1px solid #d7dee8;
    border-radius: 14px;
    background: #ffffff;
    color: #111827;
    padding: 0 13px;
    font-weight: 800;
    outline: none;
}

.ads-filter-field input:focus,
.ads-filter-field select:focus {
    border-color: #0b5ed7;
    box-shadow: 0 0 0 4px rgba(11, 94, 215, 0.1);
}

.ads-filter-submit {
    height: 44px;
    border: none;
    border-radius: 14px;
    background: #0b5ed7;
    color: #ffffff;
    padding: 0 20px;
    font-weight: 1000;
    cursor: pointer;
}

.ads-filter-submit:hover {
    background: #094db2;
}

.ads-filter-extra {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-top: 12px;
}

.ads-checkbox-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: 1px solid #d7dee8;
    border-radius: 999px;
    background: #ffffff;
    padding: 9px 13px;
    color: #111827;
    font-weight: 900;
    cursor: pointer;
}

.ads-checkbox-pill input {
    width: 16px;
    height: 16px;
    accent-color: #0b5ed7;
}

.ads-filter-reset {
    color: #52606d;
    font-size: 14px;
    font-weight: 900;
}

.ads-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 310px;
    gap: 18px;
    align-items: start;
}

.ads-side-column {
    position: sticky;
    top: 92px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.ads-promo-info-card,
.ads-recent-box {
    background: #ffffff;
    border: 1px solid #e1e7ef;
    border-radius: 22px;
    padding: 16px;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.06);
}

.ads-promo-info-card h3,
.ads-recent-box h3 {
    margin: 0 0 12px;
    font-size: 18px;
    color: #111827;
}

.ads-promo-info-row {
    display: grid;
    gap: 4px;
    border-radius: 16px;
    padding: 12px;
    margin-top: 8px;
    border: 1px solid transparent;
}

.ads-promo-info-row strong {
    font-size: 14px;
    font-weight: 1000;
}

.ads-promo-info-row span {
    color: #52606d;
    font-size: 13px;
    line-height: 1.35;
}

.ads-promo-info-row.vip {
    background: linear-gradient(135deg, #fff7d6, #fff1a8);
    border-color: #f3c969;
}

.ads-promo-info-row.vip strong {
    color: #7a4a00;
}

.ads-promo-info-row.premium {
    background: #eef5ff;
    border-color: #b9d5ff;
}

.ads-promo-info-row.premium strong {
    color: #0b5ed7;
}

.ads-promo-info-row.new {
    background: #ecfdf5;
    border-color: #a7f3d0;
}

.ads-promo-info-row.new strong {
    color: #047857;
}

.ad-badge-new {
    left: 12px;
    top: 50px;
    background: #10b981;
    color: #ffffff;
    border-color: rgba(255,255,255,.7);
}

.classified-seller-mini {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-top: 8px;
    color: #52606d;
    font-size: 13px;
    font-weight: 800;
}

.classified-seller-avatar {
    width: 22px;
    height: 22px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #eef4ff;
    overflow: hidden;
    font-size: 12px;
}

.classified-seller-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.ads-recent-list {
    display: flex;
    flex-direction: column;
    gap: 9px;
}

.ads-recent-item {
    display: grid;
    grid-template-columns: 58px minmax(0, 1fr);
    gap: 10px;
    align-items: center;
    border: 1px solid #edf1f5;
    border-radius: 15px;
    padding: 8px;
    color: #111827;
    text-decoration: none;
}

.ads-recent-item:hover {
    background: #f7fbff;
    text-decoration: none;
}

.ads-recent-item img,
.ads-recent-empty {
    width: 58px;
    height: 48px;
    border-radius: 12px;
    object-fit: cover;
    background: #eef2f7;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ads-recent-item strong {
    display: block;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    font-size: 13px;
    font-weight: 1000;
}

.ads-recent-item small {
    display: block;
    margin-top: 3px;
    color: #0b5ed7;
    font-weight: 1000;
}

.seller-more-ads {
    border: 1px solid #e1e7ef;
    border-radius: 22px;
    padding: 18px;
    background: #ffffff;
}

@media (max-width: 1020px) {
    .ads-layout {
        grid-template-columns: 1fr;
    }

    .ads-side-column {
        position: static;
        order: -1;
    }

    .ads-filter-main {
        grid-template-columns: 1fr 1fr;
    }

    .ads-filter-field-wide,
    .ads-filter-sort,
    .ads-filter-submit {
        grid-column: 1 / -1;
    }
}

@media (max-width: 640px) {
    .ads-filter-panel {
        padding: 12px;
        border-radius: 18px;
    }

    .ads-filter-main {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .ads-filter-submit {
        width: 100%;
    }

    .ads-promo-info-card {
        display: none;
    }

    .ads-recent-box {
        border-radius: 18px;
        padding: 13px;
    }
}

/* Marketplace PRO add-on: seller card, HOT, hover gallery, floating actions */
.ads-list-modern .classified-card,
.ads-olx-list .classified-card {
    transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.ads-list-modern .classified-card:hover,
.ads-olx-list .classified-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 38px rgba(8, 47, 53, .11);
    border-color: #b8dadd;
}

.classified-hover-gallery {
    position: relative;
    background: #eef4f5;
}

.classified-gallery-shot {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transform: scale(1.015);
    transition: opacity .25s ease, transform .35s ease;
}

.classified-gallery-shot.is-active {
    opacity: 1;
    transform: scale(1);
}

.classified-card-floating-actions {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 8;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.classified-card-floating-actions .classified-favorite-btn,
.classified-floating-btn {
    position: static !important;
    width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255,255,255,.75);
    border-radius: 50%;
    background: rgba(255,255,255,.92);
    color: #082f35;
    font-size: 19px;
    font-weight: 950;
    line-height: 1;
    box-shadow: 0 8px 20px rgba(0,0,0,.13);
    backdrop-filter: blur(8px);
    cursor: pointer;
    transition: transform .18s ease, background .18s ease, color .18s ease;
}

.classified-card-floating-actions .classified-favorite-btn:hover,
.classified-floating-btn:hover {
    transform: scale(1.08);
    background: #ffffff;
    color: #006d77;
}

.classified-card-floating-actions .classified-favorite-btn.is-active {
    background: #fff1f2;
    color: #e11d48;
}

.classified-floating-btn.is-copied {
    background: #dcfce7;
    color: #15803d;
}

.classified-badges-stack {
    position: absolute;
    left: 10px;
    top: 10px;
    z-index: 7;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
}

.classified-badges-stack .ad-badge {
    position: static !important;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    border-radius: 999px;
    padding: 7px 10px;
    font-size: 11px;
    font-weight: 1000;
    text-transform: uppercase;
    letter-spacing: .04em;
    box-shadow: 0 8px 18px rgba(0,0,0,.14);
}

.ad-badge-vip {
    background: linear-gradient(135deg, #ffdf5d, #ffb300 52%, #ff8a00) !important;
    color: #3b2600 !important;
    border: 1px solid rgba(255,255,255,.8) !important;
}

.ad-badge-premium {
    background: linear-gradient(135deg, #e8f1ff, #3b82f6) !important;
    color: #ffffff !important;
    border: 1px solid rgba(255,255,255,.72) !important;
}

.ad-badge-hot {
    background: linear-gradient(135deg, #ff7a18, #ef233c) !important;
    color: #ffffff !important;
    border: 1px solid rgba(255,255,255,.72) !important;
}

.ad-badge-new {
    background: linear-gradient(135deg, #dcfce7, #22c55e) !important;
    color: #064e3b !important;
    border: 1px solid rgba(255,255,255,.72) !important;
}

.classified-gallery-dots {
    position: absolute;
    left: 50%;
    bottom: 10px;
    z-index: 7;
    transform: translateX(-50%);
    display: flex;
    gap: 4px;
    max-width: calc(100% - 24px);
}

.classified-gallery-dots span {
    width: 18px;
    height: 4px;
    border-radius: 999px;
    background: rgba(255,255,255,.55);
    box-shadow: 0 1px 3px rgba(0,0,0,.18);
}

.classified-gallery-dots span.is-active {
    background: #ffffff;
}

.classified-seller-card-mini {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 12px;
    padding: 10px 12px;
    border: 1px solid #e0ecef;
    border-radius: 16px;
    background: linear-gradient(135deg, #ffffff, #f5fbfc);
}

.classified-seller-card-mini .classified-seller-avatar {
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    border-radius: 50%;
    background: #e7f4f6;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    font-size: 18px;
}

.classified-seller-card-mini .classified-seller-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.classified-seller-info {
    min-width: 0;
    display: flex;
    flex-direction: column;
    line-height: 1.15;
}

.classified-seller-info strong {
    max-width: 190px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #082f35;
    font-size: 13px;
    font-weight: 950;
}

.classified-seller-info small {
    margin-top: 3px;
    color: #667985;
    font-size: 12px;
    font-weight: 800;
}

.classified-seller-verified {
    margin-left: auto;
    width: 24px;
    height: 24px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #0ea5e9;
    color: #ffffff;
    font-weight: 1000;
}

.classified-card.is-hot {
    border-color: #ffd2b8 !important;
}

@media (max-width: 760px) {
    .classified-card-floating-actions {
        flex-direction: row;
        top: 8px;
        right: 8px;
    }

    .classified-card-floating-actions .classified-favorite-btn,
    .classified-floating-btn {
        width: 35px;
        height: 35px;
        font-size: 17px;
    }

    .classified-badges-stack {
        top: 8px;
        left: 8px;
        gap: 5px;
    }

    .classified-badges-stack .ad-badge {
        padding: 6px 8px;
        font-size: 10px;
    }

    .classified-seller-card-mini {
        padding: 9px 10px;
        border-radius: 14px;
    }
}


/* Ad limits and seller profile status */
.ad-limit-box {
    margin: 0 0 16px;
    padding: 14px 16px;
    border: 1px solid #e0e9f2;
    border-radius: 18px;
    background: #f8fbff;
    color: #334155;
    font-weight: 800;
}

.ad-limit-box span {
    display: block;
    margin-top: 5px;
    color: #64748b;
    font-size: 14px;
}

.classified-seller-status {
    margin-left: auto;
    min-width: 32px;
    justify-content: center;
}

/* ===== ads marketplace cleanup: Kufar/OLX-like categories first ===== */
.ads-market-home {
    max-width: 1180px;
    padding-top: 18px;
}

.ads-topbar-market {
    display: grid;
    grid-template-columns: 54px minmax(0, 1fr) auto;
    gap: 14px;
    align-items: center;
    margin-bottom: 18px;
}

.ads-market-logo {
    width: 54px;
    height: 54px;
    border-radius: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #00a878;
    color: #fff !important;
    font-weight: 950;
    text-decoration: none !important;
    box-shadow: 0 10px 24px rgba(0, 168, 120, .18);
}

.ads-market-search {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 58px;
    min-height: 54px;
    border-radius: 16px;
    background: #f1f4f5;
    overflow: hidden;
    border: 1px solid #e3eaec;
}

.ads-market-search input {
    border: 0;
    background: transparent;
    padding: 0 18px;
    font-size: 18px;
    outline: none;
}

.ads-market-search button {
    border: 0;
    background: #063f46;
    color: #fff;
    font-size: 30px;
    font-weight: 900;
    cursor: pointer;
}

.ads-market-add {
    min-height: 54px;
    padding: 0 20px;
    border-radius: 16px;
    background: #00a878;
    color: #fff !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 950;
    text-decoration: none !important;
    white-space: nowrap;
}

.ads-catalog-strip {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(155px, 190px);
    gap: 12px;
    overflow-x: auto;
    padding: 4px 2px 18px;
    margin-bottom: 12px;
    scroll-snap-type: x mandatory;
}

.ads-catalog-strip-item {
    scroll-snap-align: start;
    min-height: 88px;
    display: grid;
    grid-template-columns: 50px minmax(0, 1fr);
    align-items: center;
    gap: 12px;
    padding: 14px;
    background: #fff;
    border: 1px solid #e3eaec;
    border-radius: 18px;
    color: #092f35 !important;
    text-decoration: none !important;
    box-shadow: 0 8px 20px rgba(8,47,53,.05);
}

.ads-catalog-icon,
.ads-category-tile-icon {
    width: 50px;
    height: 50px;
    border-radius: 14px;
    background: #f0f4f5;
    color: #007782;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 950;
    font-size: 23px;
    text-transform: uppercase;
}

.ads-catalog-strip-item strong,
.ads-category-tile-kufar strong {
    display: block;
    font-size: 16px;
    line-height: 1.15;
}

.ads-catalog-strip-item small,
.ads-category-tile-kufar small {
    display: block;
    margin-top: 5px;
    color: #667985;
    font-weight: 700;
    line-height: 1.25;
}

.ads-popular-categories {
    margin: 10px 0 26px;
}

.ads-section-head-simple h1 {
    margin: 0 0 6px;
    color: #082f35;
    font-size: clamp(30px, 5vw, 44px);
    letter-spacing: -.04em;
}

.ads-section-head-simple p {
    margin: 0 0 16px;
    color: #667985;
    font-size: 16px;
}

.ads-category-grid-kufar {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
}

.ads-category-tile-kufar {
    min-height: 112px;
    display: grid;
    grid-template-columns: 62px minmax(0, 1fr);
    align-items: center;
    gap: 14px;
    padding: 18px;
    border-radius: 22px;
    background: #fff;
    border: 1px solid #e3eaec;
    color: #082f35 !important;
    text-decoration: none !important;
    box-shadow: 0 10px 24px rgba(8,47,53,.055);
}

.ads-category-tile-kufar:hover,
.ads-catalog-strip-item:hover {
    transform: translateY(-2px);
    border-color: #a7e5df;
}

.ads-category-page-head {
    margin: 10px 0 22px;
}

.ads-back-link {
    display: inline-flex;
    margin-bottom: 10px;
    color: #007782 !important;
    font-weight: 900;
    text-decoration: none !important;
}

.ads-category-page-head h1 {
    margin: 0 0 16px;
    font-size: clamp(34px, 5vw, 52px);
    letter-spacing: -.05em;
    color: #082f35;
}

.ads-subcategory-list-olx {
    background: #fff;
    border-radius: 22px;
    border: 1px solid #e3eaec;
    overflow: hidden;
    box-shadow: 0 10px 24px rgba(8,47,53,.055);
}

.ads-subcategory-list-olx a {
    min-height: 58px;
    padding: 0 20px;
    border-bottom: 1px solid #e3eaec;
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: #082f35 !important;
    font-size: 20px;
    font-weight: 850;
    text-decoration: none !important;
}

.ads-subcategory-list-olx a:last-child { border-bottom: 0; }
.ads-subcategory-list-olx a.active { background: #e9fbfd; color: #007782 !important; }
.ads-subcategory-list-olx span { font-size: 34px; color: #007782; }

.ads-compact-filters {
    display: grid;
    grid-template-columns: 1fr 130px 130px 200px auto auto;
    gap: 10px;
    align-items: end;
    margin: 16px 0 24px;
    padding: 14px;
    border-radius: 22px;
    background: #fff;
    border: 1px solid #e3eaec;
    box-shadow: 0 8px 22px rgba(8,47,53,.045);
}

.ads-compact-filters label {
    display: grid;
    gap: 6px;
    color: #667985;
    font-size: 12px;
    font-weight: 850;
}

.ads-compact-filters input,
.ads-compact-filters select {
    min-height: 46px;
    border: 1px solid #dfe8eb;
    border-radius: 14px;
    padding: 0 12px;
    font-size: 15px;
    background: #fff;
}

.ads-compact-filters button {
    min-height: 46px;
    padding: 0 20px;
    border: 0;
    border-radius: 14px;
    background: #063f46;
    color: #fff;
    font-weight: 950;
    cursor: pointer;
}

.ads-kufar-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 24px;
}

.ads-kufar-cards {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.ads-kufar-cards .classified-card {
    border-radius: 6px;
    box-shadow: none;
    border: 1px solid #e2e8f0;
}

.ads-kufar-cards .classified-card:hover {
    transform: none;
    box-shadow: 0 10px 24px rgba(8,47,53,.08);
}

.ads-kufar-cards .classified-card-link {
    display: block;
    color: inherit;
    text-decoration: none !important;
}

.ads-kufar-cards .classified-photo-frame {
    position: relative;
    aspect-ratio: 1 / .78;
    background: #f2f5f6;
    overflow: hidden;
}

.ads-kufar-cards .classified-photo-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.ads-kufar-cards .classified-photo-empty {
    min-height: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #667985;
    font-weight: 900;
    background: #eef3f4;
}

.ads-kufar-cards .classified-card-body {
    padding: 14px 16px 16px;
}

.ads-kufar-cards .classified-card-topline {
    color: #667985;
    font-size: 13px;
    font-weight: 700;
    margin-bottom: 8px;
}

.ads-kufar-cards .classified-card-body h3 {
    margin: 0 0 10px;
    font-size: 18px;
    line-height: 1.22;
    color: #10272c;
}

.ads-kufar-cards .classified-card-price {
    display: block;
    margin-bottom: 9px;
    color: #111;
    font-size: 23px;
    line-height: 1.05;
    font-weight: 950;
}

.ads-kufar-cards .classified-card-price.muted {
    color: #4d5b63;
    font-size: 16px;
    font-weight: 850;
    letter-spacing: 0;
}

.ads-kufar-cards .classified-card-desc {
    min-height: 40px;
    margin: 0 0 10px;
    color: #667985;
    font-size: 14px;
    line-height: 1.35;
}

.ads-kufar-cards .classified-seller-card-mini,
.ads-kufar-cards .classified-report-line,
.ads-kufar-cards .classified-gallery-dots,
.ads-kufar-cards .classified-floating-btn:not(.classified-quick-btn) {
    display: none !important;
}

.ads-kufar-cards .classified-card-floating-actions {
    position: absolute;
    top: 10px;
    right: 10px;
    display: flex;
    gap: 8px;
    z-index: 5;
}

.ads-kufar-cards .classified-favorite-btn,
.ads-kufar-cards .classified-quick-btn {
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 50%;
    background: rgba(255,255,255,.96);
    color: #082f35;
    font-size: 22px;
    box-shadow: 0 8px 16px rgba(0,0,0,.10);
    cursor: pointer;
}

.ads-kufar-cards .classified-quick-btn { font-size: 0; }
.ads-kufar-cards .classified-quick-btn::before { content: "👁"; font-size: 18px; }

.ads-kufar-cards .classified-badges-stack {
    position: absolute;
    left: 10px;
    top: 10px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    z-index: 4;
}

.ads-kufar-cards .ad-badge {
    position: static;
    display: inline-flex;
    width: max-content;
    padding: 7px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 950;
}

.ads-kufar-cards .ad-badge-new { background: #35d27f; color: #05351d; }
.ads-kufar-cards .ad-badge-vip { background: #ffe08a; color: #4b3400; }
.ads-kufar-cards .ad-badge-premium { background: #dbeafe; color: #123b7a; }
.ads-kufar-cards .ad-badge-hot { background: #ffd6d6; color: #7a1212; }

.ads-kufar-cards .classified-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    color: #667985;
    font-size: 13px;
}

.ads-side-column-soft { position: sticky; top: 90px; }

.ad-form textarea[name="description"] {
    min-height: 120px;
}

@media (max-width: 980px) {
    .ads-topbar-market { grid-template-columns: 48px minmax(0,1fr); }
    .ads-market-add { grid-column: 1 / -1; }
    .ads-category-grid-kufar { grid-template-columns: repeat(2, minmax(0,1fr)); }
    .ads-compact-filters { grid-template-columns: repeat(2, minmax(0,1fr)); }
    .ads-kufar-layout { grid-template-columns: 1fr; }
    .ads-side-column-soft { display: none; }
    .ads-kufar-cards { grid-template-columns: repeat(2, minmax(0,1fr)); }
}

@media (max-width: 620px) {
    .ads-market-home { padding-left: 12px; padding-right: 12px; }
    .ads-topbar-market { gap: 10px; }
    .ads-market-logo { width: 48px; height: 48px; border-radius: 14px; }
    .ads-market-search { min-height: 48px; grid-template-columns: 1fr 52px; }
    .ads-market-search input { font-size: 16px; padding: 0 13px; }
    .ads-catalog-strip { grid-auto-columns: 152px; }
    .ads-category-grid-kufar { grid-template-columns: 1fr 1fr; gap: 10px; }
    .ads-category-tile-kufar { min-height: 96px; grid-template-columns: 46px 1fr; padding: 12px; border-radius: 18px; }
    .ads-category-tile-icon, .ads-catalog-icon { width: 44px; height: 44px; border-radius: 13px; }
    .ads-category-tile-kufar strong { font-size: 15px; }
    .ads-category-tile-kufar small { display: none; }
    .ads-subcategory-list-olx a { font-size: 17px; min-height: 54px; padding: 0 14px; }
    .ads-compact-filters { grid-template-columns: 1fr; padding: 12px; }
    .ads-kufar-cards { grid-template-columns: 1fr 1fr; gap: 10px; }
    .ads-kufar-cards .classified-card-body { padding: 10px 11px 12px; }
    .ads-kufar-cards .classified-card-body h3 { font-size: 15px; }
    .ads-kufar-cards .classified-card-price { font-size: 18px; }
    .ads-kufar-cards .classified-card-price.muted { font-size: 13px; }
    .ads-kufar-cards .classified-card-desc,
    .ads-kufar-cards .classified-card-footer { font-size: 12px; }
}

/* =========================================================
   CATEGORY ICONS — SzczecinTut custom colored SVG set
========================================================= */
.ads-catalog-icon,
.ads-category-tile-icon {
    overflow: hidden;
    background: linear-gradient(135deg, #f8fafc, #eef2ff) !important;
    border: 1px solid rgba(148, 163, 184, .22);
}

.ads-category-svg {
    width: 46px;
    height: 46px;
    display: block;
    filter: drop-shadow(0 7px 12px rgba(15, 23, 42, .10));
}

.ads-category-tile-kufar .ads-category-svg {
    width: 58px;
    height: 58px;
}

.ads-category-tile-kufar {
    align-items: center;
}

.ads-category-tile-kufar small {
    line-height: 1.35;
}

.ads-subcategory-list-olx a {
    text-transform: none;
}

@media (max-width: 720px) {
    .ads-category-svg { width: 40px; height: 40px; }
    .ads-category-tile-kufar .ads-category-svg { width: 48px; height: 48px; }
}

/* === Kufar-like categories corrective patch === */
.ads-kufar-home{background:#f3f7fb;min-height:100vh;padding:18px 0 48px}.ads-kufar-topbar{display:flex;align-items:center;gap:14px;margin:0 auto 18px;max-width:1120px;padding:0 14px}.ads-kufar-brand{width:66px;height:66px;border-radius:18px;background:#09b27d;color:#fff;display:flex;align-items:center;justify-content:center;font-weight:900;font-size:24px;text-decoration:none;box-shadow:0 8px 20px rgba(0,130,90,.16)}.ads-kufar-search{flex:1;display:flex;height:58px;background:#fff;border-radius:18px;overflow:hidden;box-shadow:0 8px 24px rgba(22,45,64,.08);border:1px solid rgba(18,43,59,.06)}.ads-kufar-search input{flex:1;border:0;background:#fff;padding:0 18px;font-size:18px;outline:none;min-width:0}.ads-kufar-search button{width:74px;border:0;background:#073e47;color:#fff;font-size:34px;font-weight:900}.ads-kufar-plus{width:56px;height:56px;border-radius:50%;background:#e8fff6;color:#08ad78;display:flex;align-items:center;justify-content:center;text-decoration:none;font-size:32px;font-weight:900}.ads-kufar-categories{max-width:1120px;margin:0 auto 18px;padding:0 14px}.ads-kufar-category-scroller{display:grid;grid-auto-flow:column;grid-template-rows:repeat(3,86px);grid-auto-columns:minmax(265px,1fr);gap:10px 18px;overflow-x:auto;scroll-snap-type:x mandatory;padding:4px 4px 10px;-webkit-overflow-scrolling:touch;scrollbar-width:none}.ads-kufar-category-scroller::-webkit-scrollbar{display:none}.ads-kufar-category-item{scroll-snap-align:start;display:grid;grid-template-columns:82px 1fr;align-items:center;gap:14px;min-width:0;text-decoration:none;color:#153943;border-radius:16px;padding:6px;background:transparent;transition:background .18s ease,transform .18s ease}.ads-kufar-category-item:hover{background:rgba(255,255,255,.75);transform:translateY(-1px)}.ads-kufar-category-figure{width:82px;height:82px;border-radius:14px;background:#eef2f5;display:flex;align-items:center;justify-content:center;overflow:hidden;box-shadow:inset 0 0 0 1px rgba(10,37,50,.04)}.ads-kufar-category-name{font-size:20px;line-height:1.12;font-weight:650;max-width:150px;overflow-wrap:anywhere;hyphens:auto}.ads-kufar-dots{display:flex;justify-content:center;gap:8px;margin:8px 0 0}.ads-kufar-dots span{width:10px;height:10px;border-radius:50%;background:#d2d9df}.ads-kufar-dots span:first-child{background:#222}.ads-kufar-actions-row{max-width:1120px;margin:0 auto 18px;padding:0 14px}.ads-kufar-submit-wide{display:flex;align-items:center;justify-content:center;height:56px;border-radius:14px;border:1.5px solid #08ad78;background:#fff;color:#08ad78;text-decoration:none;font-size:20px;font-weight:800}.ads-kufar-filters{max-width:1120px;margin:0 auto 24px}.ads-kufar-layout{max-width:1120px;margin:0 auto}.ads-kufar-section-head h2{font-size:28px}.ads-kufar-category-inside{max-width:1120px;margin:0 auto 18px;padding:0 14px}.ads-kufar-current-head{display:flex;align-items:center;gap:14px;margin:12px 0 18px}.ads-kufar-current-icon{width:70px;height:70px;border-radius:17px;background:#eef2f5;display:flex;align-items:center;justify-content:center}.ads-kufar-current-head h1{font-size:38px;line-height:1.05;margin:0;color:#0b3942}.ads-kufar-subcategories{background:#fff;border-radius:20px;box-shadow:0 10px 28px rgba(18,45,62,.08);overflow:hidden}.ads-kufar-subcategories a{display:flex;align-items:center;justify-content:space-between;padding:17px 20px;text-decoration:none;color:#153943;font-size:19px;border-bottom:1px solid #edf0f2}.ads-kufar-subcategories a:last-child{border-bottom:0}.ads-kufar-subcategories a.active{font-weight:800;color:#08ad78}.cat-svg{width:62px;height:62px;fill:none;stroke:#123943;stroke-width:6;stroke-linecap:round;stroke-linejoin:round}.cat-auto{stroke:#1666b1}.cat-home{stroke:#0f8b67}.cat-work{stroke:#d78312}.cat-service{stroke:#7c4dcc}.cat-computer{stroke:#3157d5}.cat-phone,.cat-electronics{stroke:#10a894}.cat-appliance{stroke:#dd697c}.cat-furniture{stroke:#c15b7d}.cat-kids{stroke:#ef9f21}.cat-pets{stroke:#d45745}.cat-gift{stroke:#11a86f}.cat-docs{stroke:#6071d9}.cat-default{stroke:#6a7b89}@media (min-width:900px){.ads-kufar-category-scroller{grid-auto-flow:row;grid-template-rows:none;grid-template-columns:repeat(4,minmax(0,1fr));overflow:visible}.ads-kufar-dots{display:none}.ads-kufar-category-name{max-width:none}.ads-kufar-submit-wide{max-width:360px;margin-left:auto}}@media (max-width:700px){.ads-kufar-home{padding-top:14px}.ads-kufar-topbar{gap:10px;margin-bottom:14px}.ads-kufar-brand{width:58px;height:58px;border-radius:16px;font-size:22px}.ads-kufar-plus{width:48px;height:48px;font-size:30px}.ads-kufar-search{height:56px;border-radius:16px}.ads-kufar-search input{font-size:17px}.ads-kufar-search button{width:62px;font-size:30px}.ads-kufar-categories{padding-right:0}.ads-kufar-category-scroller{grid-template-rows:repeat(3,78px);grid-auto-columns:300px;gap:8px 14px}.ads-kufar-category-item{grid-template-columns:74px 1fr;gap:12px}.ads-kufar-category-figure{width:74px;height:74px}.ads-kufar-category-name{font-size:19px;max-width:170px}.cat-svg{width:56px;height:56px}.ads-kufar-submit-wide{height:54px;font-size:19px}.ads-kufar-filters{margin-left:14px;margin-right:14px}.ads-kufar-current-head h1{font-size:31px}.ads-kufar-subcategories a{font-size:18px;padding:16px 18px}}

/* =========================================================
   CATEGORY PHOTOS — Kufar-like category pictures
   Uses AdCategory.icon uploaded in admin.
========================================================= */
.ads-photo-cats-home .ads-kufar-categories {
    margin-top: 6px;
    margin-bottom: 22px;
}

.ads-photo-cats-home .ads-photo-category-scroller {
    grid-template-rows: repeat(3, 88px);
    grid-auto-columns: 310px;
    gap: 8px 20px;
    padding-top: 2px;
}

.ads-photo-cats-home .ads-photo-category-item {
    grid-template-columns: 96px minmax(0, 1fr);
    min-height: 88px;
    padding: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}

.ads-photo-cats-home .ads-photo-category-item:hover {
    background: transparent;
}

.ads-photo-cats-home .ads-photo-category-figure {
    width: 92px;
    height: 82px;
    border-radius: 14px;
    background: #f0f1f2;
    border: 0;
    box-shadow: none;
}

.ads-category-photo {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.ads-category-photo-default {
    object-fit: contain;
    padding: 14px;
    background: #eef2f7;
}

.ads-photo-cats-home .ads-photo-category-name {
    max-width: 185px;
    font-size: 19px;
    line-height: 1.16;
    font-weight: 650;
    color: #20252b;
    overflow-wrap: normal;
    word-break: normal;
    hyphens: none;
}

.ads-photo-current-head {
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 16px 0 20px;
}

.ads-photo-current-image {
    width: 92px;
    height: 82px;
    border-radius: 16px;
    overflow: hidden;
    background: #f0f1f2;
    flex: 0 0 auto;
}

.ads-photo-current-head h1 {
    margin: 0;
    color: #20252b;
    font-size: clamp(30px, 5vw, 46px);
    line-height: 1.05;
    letter-spacing: -0.035em;
}

.ads-photo-parent-link {
    display: inline-flex;
    margin-bottom: 4px;
    color: #08ad78;
    font-size: 14px;
    font-weight: 800;
    text-decoration: none;
}

.ads-photo-subcategory-title {
    margin: 8px 0 12px;
    color: #20252b;
    font-size: 22px;
    font-weight: 900;
}

.ads-photo-subcategory-scroller {
    display: grid;
    grid-auto-flow: column;
    grid-template-rows: repeat(2, 150px);
    grid-auto-columns: 205px;
    gap: 12px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    padding: 0 4px 12px;
}

.ads-photo-subcategory-scroller::-webkit-scrollbar {
    display: none;
}

.ads-photo-subcategory-card {
    position: relative;
    scroll-snap-align: start;
    display: block;
    min-height: 150px;
    overflow: hidden;
    border-radius: 18px;
    background: #f1f1f1;
    text-decoration: none;
    color: #20252b;
    box-shadow: inset 0 0 0 1px rgba(15, 23, 42, .04);
}

.ads-photo-subcategory-card.active {
    box-shadow: inset 0 0 0 3px rgba(8, 173, 120, .50);
}

.ads-photo-subcategory-card > span:last-child {
    position: absolute;
    top: 14px;
    left: 14px;
    right: 14px;
    z-index: 2;
    font-size: 18px;
    line-height: 1.1;
    font-weight: 900;
}

.ads-photo-subcategory-image {
    position: absolute;
    inset: 0;
}

.ads-photo-subcategory-image .ads-category-photo {
    object-fit: cover;
}

.ads-photo-subcategory-image::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(241,241,241,.85), rgba(241,241,241,.18) 48%, rgba(241,241,241,0));
}

@media (min-width: 900px) {
    .ads-photo-cats-home .ads-photo-category-scroller {
        grid-auto-flow: row;
        grid-template-rows: none;
        grid-template-columns: repeat(4, minmax(0, 1fr));
        overflow: visible;
    }

    .ads-photo-cats-home .ads-photo-category-item {
        grid-template-columns: 92px 1fr;
    }

    .ads-photo-cats-home .ads-photo-category-name {
        max-width: none;
    }

    .ads-photo-subcategory-scroller {
        grid-auto-flow: row;
        grid-template-rows: none;
        grid-template-columns: repeat(4, minmax(0, 1fr));
        overflow: visible;
    }
}

@media (max-width: 700px) {
    .ads-photo-cats-home .ads-photo-category-scroller {
        grid-template-rows: repeat(3, 74px);
        grid-auto-columns: 308px;
        gap: 8px 18px;
    }

    .ads-photo-cats-home .ads-photo-category-item {
        grid-template-columns: 86px minmax(0, 1fr);
        min-height: 74px;
    }

    .ads-photo-cats-home .ads-photo-category-figure {
        width: 78px;
        height: 70px;
        border-radius: 12px;
    }

    .ads-photo-cats-home .ads-photo-category-name {
        font-size: 18px;
        max-width: 190px;
    }

    .ads-photo-current-image {
        width: 82px;
        height: 74px;
        border-radius: 14px;
    }

    .ads-photo-subcategory-scroller {
        grid-template-rows: repeat(2, 128px);
        grid-auto-columns: 180px;
        gap: 10px;
    }

    .ads-photo-subcategory-card {
        min-height: 128px;
        border-radius: 16px;
    }

    .ads-photo-subcategory-card > span:last-child {
        font-size: 17px;
    }
}

/* =========================================================
   KUFAR PHOTO CATEGORIES V2
   Compact photo + light label, not huge icon cards.
   Put this after previous category CSS.
========================================================= */

.ads-photo-cats-home .ads-kufar-categories {
    margin-top: 2px;
    margin-bottom: 10px;
    padding-left: 26px;
    padding-right: 0;
}

.ads-photo-cats-home .ads-photo-category-scroller {
    grid-template-rows: repeat(3, 70px);
    grid-auto-columns: 324px;
    gap: 8px 18px;
    padding: 0 0 12px;
}

.ads-photo-cats-home .ads-photo-category-item {
    grid-template-columns: 104px minmax(0, 1fr);
    min-height: 70px;
    gap: 14px;
    padding: 0;
    border-radius: 0;
    background: transparent !important;
    box-shadow: none !important;
}

.ads-photo-cats-home .ads-photo-category-item:hover {
    transform: none;
    background: transparent !important;
}

.ads-photo-cats-home .ads-photo-category-figure {
    width: 100px;
    height: 70px;
    border-radius: 10px;
    background: #f1f2f3;
    overflow: hidden;
    box-shadow: none;
    border: 0;
}

.ads-photo-cats-home .ads-photo-category-name {
    max-width: 180px;
    color: #24272b;
    font-size: 17px;
    line-height: 1.18;
    font-weight: 400;
    letter-spacing: 0;
    overflow-wrap: normal;
    word-break: normal;
    hyphens: none;
}

.ads-category-photo {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.ads-category-photo-default {
    object-fit: contain;
    padding: 18px;
    opacity: .45;
    background: #f1f2f3;
}

.ads-kufar-promo-strip {
    max-width: 1120px;
    margin: 2px auto 16px;
    padding: 0 26px 4px;
    display: flex;
    gap: 12px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.ads-kufar-promo-strip::-webkit-scrollbar { display: none; }

.ads-kufar-promo-card {
    flex: 0 0 188px;
    min-height: 122px;
    border-radius: 14px;
    padding: 15px 12px;
    color: #fff !important;
    text-decoration: none !important;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow: hidden;
    box-shadow: none;
}

.ads-kufar-promo-card strong {
    font-size: 19px;
    line-height: 1.08;
    font-weight: 800;
}

.ads-kufar-promo-card span {
    font-size: 13px;
    line-height: 1.2;
    opacity: .92;
}

.ads-kufar-promo-card.promo-green { background: linear-gradient(135deg, #06a36f, #10b981); }
.ads-kufar-promo-card.promo-blue { background: linear-gradient(135deg, #1774e6, #38a3ff); }
.ads-kufar-promo-card.promo-orange { background: linear-gradient(135deg, #f97316, #fb923c); }

.ads-photo-current-head {
    align-items: center;
    gap: 14px;
    margin: 16px 0 18px;
}

.ads-photo-current-image {
    width: 104px;
    height: 76px;
    border-radius: 12px;
    background: #f1f2f3;
}

.ads-photo-current-head h1 {
    font-size: clamp(28px, 5vw, 42px);
    font-weight: 800;
    color: #24272b;
    letter-spacing: -0.03em;
}

.ads-photo-subcategory-title {
    margin: 10px 0 12px;
    color: #24272b;
    font-size: 22px;
    font-weight: 800;
}

.ads-photo-subcategory-scroller {
    grid-template-rows: repeat(2, 132px);
    grid-auto-columns: 188px;
    gap: 12px;
}

.ads-photo-subcategory-card {
    min-height: 132px;
    border-radius: 14px;
    background: #f1f2f3;
}

.ads-photo-subcategory-card > span:last-child {
    top: 13px;
    left: 13px;
    right: 10px;
    color: #24272b;
    font-size: 17px;
    font-weight: 750;
    line-height: 1.12;
}

.ads-photo-subcategory-image::after {
    background: linear-gradient(180deg, rgba(242,243,244,.88), rgba(242,243,244,.26) 54%, rgba(242,243,244,0));
}

/* Filters: less like a raw form, more like marketplace controls */
.ads-kufar-filters {
    border: 0;
    box-shadow: none;
    background: transparent;
    gap: 9px;
    align-items: end;
    padding-top: 0;
}

.ads-kufar-filters label span {
    font-size: 13px;
    color: #66757f;
    font-weight: 500;
}

.ads-kufar-filters input,
.ads-kufar-filters select {
    min-height: 42px;
    border-radius: 12px;
    border-color: #d8dee4;
    background: #fff;
    font-size: 15px;
}

.ads-kufar-filters button,
.ads-checkbox-pill {
    min-height: 42px;
    border-radius: 999px;
}

@media (min-width: 900px) {
    .ads-photo-cats-home .ads-photo-category-scroller {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        grid-auto-flow: row;
        grid-template-rows: none;
        overflow: visible;
    }

    .ads-photo-cats-home .ads-photo-category-item {
        grid-template-columns: 98px 1fr;
    }

    .ads-kufar-promo-card { flex-basis: 220px; }
}

@media (max-width: 700px) {
    .ads-photo-cats-home .ads-kufar-categories {
        padding-left: 26px;
    }

    .ads-photo-cats-home .ads-photo-category-scroller {
        grid-template-rows: repeat(3, 66px);
        grid-auto-columns: 318px;
        gap: 8px 18px;
        padding-bottom: 8px;
    }

    .ads-photo-cats-home .ads-photo-category-item {
        grid-template-columns: 102px minmax(0, 1fr);
        min-height: 66px;
        gap: 14px;
    }

    .ads-photo-cats-home .ads-photo-category-figure {
        width: 96px;
        height: 66px;
        border-radius: 10px;
    }

    .ads-photo-cats-home .ads-photo-category-name {
        max-width: 178px;
        font-size: 17px;
        line-height: 1.16;
        font-weight: 400;
    }

    .ads-kufar-promo-strip {
        padding-left: 26px;
        padding-right: 0;
        margin-bottom: 16px;
    }

    .ads-kufar-promo-card {
        flex-basis: 176px;
        min-height: 116px;
        border-radius: 13px;
    }

    .ads-kufar-promo-card strong {
        font-size: 18px;
    }

    .ads-photo-subcategory-scroller {
        grid-template-rows: repeat(2, 122px);
        grid-auto-columns: 174px;
        gap: 10px;
    }

    .ads-photo-subcategory-card {
        min-height: 122px;
    }

    .ads-photo-subcategory-card > span:last-child {
        font-size: 16px;
        font-weight: 750;
    }
}

/* =========================================================
   KUFAR PHOTO CATEGORIES V3
   2-row mobile category strip + promo cards closer to ads.
========================================================= */

.ads-photo-cats-home .ads-kufar-categories {
    margin-top: 0 !important;
    margin-bottom: 8px !important;
    padding-left: 26px !important;
    padding-right: 0 !important;
}

.ads-photo-cats-home .ads-photo-category-scroller {
    grid-template-rows: repeat(2, 72px) !important;
    grid-auto-columns: 324px !important;
    gap: 8px 18px !important;
    padding: 0 0 10px !important;
}

.ads-photo-cats-home .ads-photo-category-item {
    grid-template-columns: 104px minmax(0, 1fr) !important;
    min-height: 72px !important;
    gap: 14px !important;
    align-items: center !important;
}

.ads-photo-cats-home .ads-photo-category-figure {
    width: 100px !important;
    height: 72px !important;
    border-radius: 10px !important;
    background: #f1f2f3 !important;
}

.ads-photo-cats-home .ads-photo-category-name {
    max-width: 180px !important;
    color: #24272b !important;
    font-size: 16px !important;
    line-height: 1.16 !important;
    font-weight: 400 !important;
    letter-spacing: 0 !important;
}

.ads-kufar-dots {
    margin-top: 5px !important;
}

.ads-kufar-promo-strip {
    max-width: 1120px;
    margin: 8px auto 16px !important;
    padding: 0 26px 4px !important;
    display: flex;
    gap: 12px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.ads-kufar-promo-strip::-webkit-scrollbar { display: none; }

.ads-kufar-promo-card {
    flex: 0 0 188px !important;
    min-height: 116px !important;
    border-radius: 14px !important;
    padding: 14px 12px !important;
    color: #fff !important;
    text-decoration: none !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    overflow: hidden;
    position: relative;
}

.ads-kufar-promo-card::after {
    content: "";
    position: absolute;
    right: -24px;
    bottom: -28px;
    width: 92px;
    height: 92px;
    border-radius: 50%;
    background: rgba(255,255,255,.20);
}

.ads-kufar-promo-card strong {
    position: relative;
    z-index: 1;
    font-size: 18px !important;
    line-height: 1.08 !important;
    font-weight: 800 !important;
}

.ads-kufar-promo-card span {
    position: relative;
    z-index: 1;
    font-size: 13px !important;
    line-height: 1.2 !important;
    opacity: .92;
}

.ads-kufar-promo-card.promo-green { background: linear-gradient(135deg, #06a36f, #10b981) !important; }
.ads-kufar-promo-card.promo-blue { background: linear-gradient(135deg, #1774e6, #38a3ff) !important; }
.ads-kufar-promo-card.promo-orange { background: linear-gradient(135deg, #f97316, #fb923c) !important; }
.ads-kufar-promo-card.promo-dark { background: linear-gradient(135deg, #374151, #111827) !important; }

.ads-kufar-actions-row {
    margin-top: 0 !important;
}

.ads-mobile-bottom-nav {
    display: none;
}

@media (min-width: 900px) {
    .ads-photo-cats-home .ads-photo-category-scroller {
        grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
        grid-auto-flow: row !important;
        grid-template-rows: none !important;
        overflow: visible !important;
    }

    .ads-kufar-promo-card { flex-basis: 220px !important; }
}

@media (max-width: 700px) {
    .ads-kufar-home {
        padding-bottom: 92px !important;
    }

    .ads-photo-cats-home .ads-kufar-categories {
        padding-left: 26px !important;
    }

    .ads-photo-cats-home .ads-photo-category-scroller {
        grid-template-rows: repeat(2, 66px) !important;
        grid-auto-columns: 318px !important;
        gap: 8px 18px !important;
        padding-bottom: 8px !important;
    }

    .ads-photo-cats-home .ads-photo-category-item {
        grid-template-columns: 102px minmax(0, 1fr) !important;
        min-height: 66px !important;
        gap: 14px !important;
    }

    .ads-photo-cats-home .ads-photo-category-figure {
        width: 96px !important;
        height: 66px !important;
        border-radius: 10px !important;
    }

    .ads-photo-cats-home .ads-photo-category-name {
        max-width: 176px !important;
        font-size: 16px !important;
        line-height: 1.16 !important;
        font-weight: 400 !important;
    }

    .ads-kufar-promo-strip {
        padding-left: 26px !important;
        padding-right: 0 !important;
        margin-bottom: 14px !important;
    }

    .ads-kufar-promo-card {
        flex-basis: 176px !important;
        min-height: 108px !important;
        border-radius: 13px !important;
    }

    .ads-kufar-promo-card strong {
        font-size: 17px !important;
    }

    .ads-mobile-bottom-nav {
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 1000;
        display: grid;
        grid-template-columns: repeat(5, 1fr);
        min-height: 68px;
        padding: 6px 4px max(6px, env(safe-area-inset-bottom));
        background: rgba(255,255,255,.96);
        border-top: 1px solid rgba(15,23,42,.08);
        box-shadow: 0 -8px 26px rgba(15,23,42,.08);
        backdrop-filter: blur(14px);
    }

    .ads-mobile-bottom-nav a {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 2px;
        color: #7b858b !important;
        text-decoration: none !important;
        font-size: 12px;
        line-height: 1.05;
        font-weight: 600;
    }

    .ads-mobile-bottom-nav a span {
        font-size: 24px;
        line-height: 1;
        font-weight: 800;
    }

    .ads-mobile-bottom-nav a em {
        font-style: normal;
    }

    .ads-mobile-bottom-nav a.active,
    .ads-mobile-bottom-nav a.add {
        color: #08ad78 !important;
    }

    .ads-mobile-bottom-nav a.add span {
        width: 34px;
        height: 34px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        background: #e8fff6;
    }
}

/* =========================================================
   MANAGED PROMO BANNERS
   Блок появляется только если в админке есть активные плашки.
========================================================= */

.ads-managed-promo-strip {
    max-width: 1120px;
    margin: 8px auto 16px !important;
    padding: 0 26px 4px !important;
    display: flex;
    gap: 12px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.ads-managed-promo-strip::-webkit-scrollbar {
    display: none;
}

.ads-managed-promo-card {
    flex: 0 0 188px !important;
    height: 116px !important;
    min-height: 116px !important;
    padding: 0 !important;
    border-radius: 14px !important;
    overflow: hidden;
    background: #eef2f7;
    display: block !important;
    text-decoration: none !important;
    box-shadow: 0 8px 20px rgba(15, 23, 42, .06);
}

.ads-managed-promo-card::after {
    display: none !important;
}

.ads-managed-promo-card img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

@media (min-width: 900px) {
    .ads-managed-promo-card {
        flex-basis: 220px !important;
        height: 126px !important;
        min-height: 126px !important;
    }
}

@media (max-width: 700px) {
    .ads-managed-promo-strip {
        padding-left: 26px !important;
        padding-right: 0 !important;
        margin-bottom: 14px !important;
    }

    .ads-managed-promo-card {
        flex-basis: 176px !important;
        height: 108px !important;
        min-height: 108px !important;
        border-radius: 13px !important;
    }
}
