/* =====================================================
   POPUP – GRİ / BEYAZ KART VE KIRMIZI VURGULAR
   Yalnızca bu eklentinin popup penceresini etkiler.
   ===================================================== */
.hacpop-dialog{box-sizing:border-box;position:fixed;inset:0;width:min(var(--hacpop-width,720px),calc(100vw - 32px));max-width:calc(100vw - 32px);height:auto;max-height:calc(100dvh - 48px);margin:auto;padding:0;border:1px solid #d8d9df;border-radius:17px;background:#fff;color:#202024;font:400 15px/1.55 Arial,Helvetica,sans-serif;box-shadow:0 24px 90px #0005;overflow:auto;scrollbar-width:thin;scrollbar-color:#ccc transparent}.hacpop-dialog:not([open]){display:none}.hacpop-dialog *{box-sizing:border-box}.hacpop-dialog::backdrop{background:#12151bcc;backdrop-filter:blur(3px)}.hacpop-dialog .hacpop-close{position:sticky;top:12px;float:right;z-index:2;width:38px;height:38px;margin:12px 12px -50px 0;padding:0;border:1px solid #d8d9df;border-radius:50%;background:#fff;color:#202024;box-shadow:0 2px 10px #0002;font:400 27px/1 Arial,Helvetica,sans-serif;display:flex;align-items:center;justify-content:center;cursor:pointer}.hacpop-dialog .hacpop-close:hover{background:#E60023;color:#fff;border-color:#E60023}.hacpop-close:focus-visible,.hacpop-cta:focus-visible,.hacpop-clickable:focus-visible{outline:3px solid #E60023;outline-offset:-4px}.hacpop-body{width:100%;min-height:80px}.hacpop-clickable{cursor:pointer}.hacpop-dialog .hacpop-image{display:block;width:100%;height:auto;max-height:72dvh;object-fit:contain;background:#e9eaf0;margin:0}.hacpop-text{padding:26px;background:#fff}.hacpop-dialog .hacpop-text h2{font:700 25px/1.3 Arial,Helvetica,sans-serif;color:#202024;margin:0 0 12px;padding-right:25px;overflow-wrap:anywhere}.hacpop-content{color:#64666d;overflow-wrap:anywhere}.hacpop-content p{margin:0 0 12px}.hacpop-content img{max-width:100%;height:auto}.hacpop-dialog .hacpop-cta{display:inline-flex;align-items:center;justify-content:center;margin-top:8px;min-height:43px;padding:10px 20px;border-radius:8px;background:#E60023;color:#fff;text-decoration:none;font-weight:700;border:1px solid #E60023}.hacpop-dialog .hacpop-cta:hover{background:#B8001C;border-color:#B8001C;color:#fff}@media(max-width:600px){.hacpop-dialog{width:calc(100vw - 24px);max-width:calc(100vw - 24px);max-height:calc(100dvh - 28px);border-radius:12px}.hacpop-text{padding:20px}.hacpop-dialog .hacpop-text h2{font-size:21px}.hacpop-dialog .hacpop-image{max-height:65dvh}.hacpop-dialog .hacpop-cta{width:100%}}

/* =====================================================
   BOYUT – Her ilanın paneldeki genişliği ve yüksekliği kullanılır.
   Taşan içerik pencerenin içinde kaydırılabilir.
   ===================================================== */
.hacpop-dialog{overflow:hidden;max-height:none;max-width:calc(100vw - 24px)}
.hacpop-scroll{height:100%;overflow:auto;scrollbar-width:thin;scrollbar-color:#ccc transparent}
.hacpop-stage{position:relative;width:100%}
.hacpop-frame{position:absolute;top:0;left:0;display:flow-root;transform-origin:top left;background:#fff}
.hacpop-dialog .hacpop-close{position:absolute;top:12px;right:12px;float:none;margin:0}
.hacpop-dialog .hacpop-image{max-height:none;width:100%;max-width:none;height:auto;object-fit:initial}
/* Metin ve görsel aynı oranla yalnızca ekran daraldığında küçülür. */
@media(max-width:600px){
    .hacpop-dialog .hacpop-image{max-height:none}
    .hacpop-text{padding:26px}
    .hacpop-dialog .hacpop-text h2{font-size:25px}
    .hacpop-dialog .hacpop-cta{width:auto}
}

/* =====================================================
   ÜST BUTON – Popup'ın en üstünde, ortada.
   ===================================================== */
.hacpop-dialog .hacpop-actions{display:flex;justify-content:center;padding:12px 48px 10px;background:#fff}
.hacpop-dialog .hacpop-actions .hacpop-cta{margin:0;max-width:100%;text-align:center}
.hacpop-scroll{overflow-x:hidden;scrollbar-gutter:stable}

/* =====================================================
   GÖRSEL / METİN – Temanın paragraf boşluklarını azaltır.
   Editöre eklenen görselleri de kapsar.
   ===================================================== */
.hacpop-dialog .hacpop-text{padding:10px 20px 18px}
.hacpop-dialog .hacpop-content p{margin:0 0 8px!important;padding:0!important}
.hacpop-dialog .hacpop-content > :first-child{margin-top:0!important}
.hacpop-dialog .hacpop-content > :last-child{margin-bottom:0!important}
.hacpop-dialog .hacpop-content figure{margin:0 0 10px!important}
.hacpop-dialog .hacpop-content img{display:block;max-width:100%;height:auto;margin:0 auto 8px!important}

.hacpop-dialog .hacpop-content p:empty{display:none}

/* =====================================================
   MİNİMUM ARALIK – Buton / görsel / metin boşluğu sıfır.
   İlan resminin dosya içindeki kenarları bu ayardan bağımsızdır.
   ===================================================== */
.hacpop-dialog .hacpop-body{display:flex;flex-direction:column;gap:0!important}
.hacpop-dialog .hacpop-actions{padding:12px 48px 0!important;margin:0!important}
.hacpop-dialog .hacpop-text{padding:0 20px 18px!important;margin:0!important}
.hacpop-dialog .hacpop-image{padding:0!important;border:0!important;margin:0!important}
.hacpop-dialog .hacpop-content{margin:0!important;padding:0!important}
.hacpop-dialog .hacpop-content img{padding:0!important;border:0!important;margin:0 auto!important}
.hacpop-dialog .hacpop-content p,
.hacpop-dialog .hacpop-content figure,
.hacpop-dialog .hacpop-content .wp-block-image,
.hacpop-dialog .hacpop-content .hacpop-media{margin-top:0!important;margin-bottom:0!important;padding-top:0!important;padding-bottom:0!important}

/* =====================================================
   ZEMİN RENGİ – İlanın yönetim panelindeki renk seçimi.
   Metin koyu zeminde açık, açık zeminde koyu görünür.
   ===================================================== */
.hacpop-dialog,.hacpop-dialog .hacpop-frame,
.hacpop-dialog .hacpop-actions,.hacpop-dialog .hacpop-text,
.hacpop-dialog .hacpop-image{background:var(--hacpop-bg,#fff)!important}
.hacpop-dialog .hacpop-text h2{color:var(--hacpop-ink,#202024)!important}
.hacpop-dialog .hacpop-content{color:var(--hacpop-muted,#64666d)}
/* Metnin altındaki buton ortada ve metne yakın tutulur. */
.hacpop-dialog .hacpop-actions{padding:8px 48px 16px!important}
.hacpop-dialog .hacpop-text{padding-bottom:0!important}

.hacpop-dialog .hacpop-content p,.hacpop-dialog .hacpop-content li{color:inherit}

/* 3.1.18: Kapatma düğmesi görselin dışında (görseldeki başlığı örtmesin); kurumsal kırmızı. */
.hacpop-dialog{overflow:visible!important}
.hacpop-dialog .hacpop-scroll{border-radius:inherit;overflow-y:auto}
.hacpop-dialog .hacpop-close{position:absolute!important;top:-16px!important;right:-16px!important;z-index:5;background:#1C1F22!important;color:#fff!important;border:2px solid #fff!important;box-shadow:0 4px 14px #0006}
.hacpop-dialog .hacpop-close:hover{background:#E60023!important;border-color:#fff!important}
@media(max-width:600px){.hacpop-dialog .hacpop-close{top:-14px!important;right:-6px!important;width:34px;height:34px}}
.hacpop-dialog .hacpop-cta,.hacpop-dialog .hacpop-cta:hover{background:#E60023;border-color:#E60023}
