@import url("nav.css");
@import url("footer.css");

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, Helvetica, sans-serif;
    background-color: whitesmoke;
    color: #333;
}

.MAIN-content {
    background-color: whitesmoke;
    padding: 30px 15px;
}

.admin-edit-bar {
    max-width: 1200px;
    margin: 0 auto;
    margin-bottom: 10px;
    background: #ffffff;
    border: 3px solid #3284bc;
    border-radius: 15px;
    padding: 10px;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.1);
    display: flex;
    gap: 10px;
    flex-direction: row;
    justify-content: center;
}

.admin-edit-bar button,
.admin-edit-bar a {
    padding: 5px;
    cursor: pointer;
    border: 3px solid;
    border-radius: 10px;
    display: flex;
    gap: 5px;
    text-decoration: none;
    font-size: 16px;
    font-weight: 600;
    align-items: center;
}

#edtAdv {
    color: #3284bc;
    border-color: #3284bc;
    background: none;
}

#edtAdv:hover {
    background-color: #3284bc;
    color: #fff;
}

#banAdv {
    color: darkorange;
    border-color: darkorange;
    background: none;
}

#banAdv:hover {
    background-color: darkorange;
    color: #fff;
}

#pubAdv {
    color: #27ae60;
    border-color: #27ae60;
    background: none;
}

#pubAdv:hover {
    background-color: #27ae60;
    color: #fff;
}

#delAdv {
    color: crimson;
    border-color: crimson;
    background: none;
}

#delAdv:hover {
    background-color:  crimson;
    color: #fff;
}

.advert-detail-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    background: #ffffff;
    border: 3px solid #3284bc;
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.1);
}

/* BAŞLIK ALANI */
.advert-title-container {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
}

.advert-title-container h1 {
    font-size: 32px;
    color: #3284bc;
    margin-bottom: 8px;
}

.location-text {
    font-size: 16px;
    color: #666;
}

.location-text i {
    color: #e74c3c;
    margin-right: 5px;
}

.reid-badge span {
    background-color: #f0f4f8;
    color: #3284bc;
    border: 1px solid #3284bc;
    padding: 8px 15px;
    border-radius: 8px;
    font-weight: bold;
    font-size: 14px;
}

.section-hr {
    border: none;
    height: 3px;
    background: linear-gradient(90deg, #3284bc 1%, #3498db 20%, #3498db 80%, #3284bc 99%);
    margin: 20px 0;
}

.private-note-container {
    background-color: #fff8e1;
    border-left: 4px solid #ffc107;
    border-radius: 6px;
    padding: 12px 16px;
    margin: 10px 0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.private-note-header {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    color: #856404;
}

.private-note-header i {
    font-size: 1.1rem;
}

.private-note-content p {
    color: #533f03;
    font-size: 0.95rem;
    padding: 5px;
    padding-bottom: 0;
    line-height: 1.5;
    white-space: pre-line;
    text-align: justify;
    text-indent: 10px;
}

/* DÜZEN (GRID) */
.advert-grid {
    display: flex;
    gap: 30px;
    flex-wrap: wrap;
}

/* GALERİ */
.gallery-section {
    flex: 2;
    min-width: 320px;
}

.main-image-box {
    width: 100%;
    height: 420px;
    border-radius: 12px;
    overflow: hidden;
    border: 2px solid #e0e0e0;
    background-color: #000;
}

.main-image-box img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.thumbnail-list {
    display: flex;
    gap: 10px;
    margin-top: 15px;
    overflow-x: auto;
    padding-bottom: 5px;
}

.thumb-item {
    width: 80px;
    height: 60px;
    border-radius: 6px;
    overflow: hidden;
    cursor: pointer;
    border: 2px solid #e0e0e0;
    opacity: 0.6;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.thumb-item:hover,
.thumb-item.active {
    border-color: #3284bc;
    opacity: 1;
}

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

/* SAĞ TARAF / ÖZET KART */
.summary-section {
    flex: 1;
    min-width: 280px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.price-card {
    background: #f0f8ff;
    border: 2px solid #3498db;
    border-radius: 12px;
    padding: 20px;
    text-align: center;
}

.price-label {
    font-size: 14px;
    color: #666;
    text-transform: uppercase;
}

.price-value {
    font-size: 32px;
    color: #27ae60;
    font-weight: bold;
    margin-top: 5px;
}

.quick-features {
    display: flex;
    flex-direction: column;
    gap: 12px;
    background: #f9f9f9;
    padding: 15px;
    border-radius: 12px;
    border: 1px solid #e0e0e0;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 15px;
}

.feature-item i {
    font-size: 20px;
    color: #3284bc;
    width: 30px;
    text-align: center;
}

.feature-item small {
    display: block;
    font-size: 12px;
    color: #777;
}

.feature-item strong {
    font-size: 15px;
    color: #333;
}

.offer-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background-color: #3284bc;
    color: white;
    border: none;
    padding: 15px;
    border-radius: 12px;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    width: 100%;
    transition: background 0.3s;
}

.offer-btn:hover {
    background-color: #1e618e;
}

.contact-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background-color: #27ae60;
    color: white;
    text-decoration: none;
    padding: 15px;
    border-radius: 12px;
    font-size: 18px;
    font-weight: bold;
    transition: background 0.3s;
}

.contact-btn:hover {
    background-color: #219150;
}

/* AÇIKLAMA BLOĞU (resimlerin altında, sol kolonda) */
.description-block {
    margin-top: 25px;
    border-top: 1px solid #e8ecf0;
}

.description-block h3 {
    color: #3284bc;
    font-size: 20px;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.description-block hr {
    border: none;
    height: 2px;
    background-color: #3498db;
}

.description-text {
    line-height: 1.5;
    font-size: 16px;
    margin-top: -15px;
    color: #444;
    white-space: pre-line;
}

/* İLAN DETAY TABLOSU (wrapper içinde) */
.details-table-inner {
    margin-top: 5px;
}

.details-table-inner h3 {
    color: #fafafa;
    font-family: Montserrat, sans-serif;
    font-size: 22px;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
    justify-content: center;
    padding: 5px;
    font-weight: 800;
    background: #3284bc;
    border: #3284bc 2px solid;
    border-radius: 20px;
}

.detail-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0;
    border: 2px solid #89bdf1;
    border-radius: 10px;
    overflow: hidden;
}

.detail-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 13px 18px;
    border-bottom: 1px solid #eef2f6;
    background: #fafcfe;
    transition: background 0.2s;
}

.detail-card:hover {
    background: #edf4fc;
}

.detail-label {
    font-size: 14px;
    color: #666;
    display: flex;
    align-items: center;
    gap: 8px;
}

.detail-label i {
    color: #3284bc;
    font-size: 16px;
    width: 20px;
    text-align: center;
}

.detail-value {
    font-size: 15px;
    font-weight: 600;
    color: #2c3e50;
}

/* DANIŞMAN KARTI STİLLERİ */
.agent-card {
    background: #ffffff;
    border: 2px solid #3284bc;
    border-radius: 12px;
    padding: 15px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.agent-profile {
    display: flex;
    align-items: center;
    gap: 15px;
}

.agent-avatar {
    width: 65px;
    height: 65px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #3284bc;
}

.agent-info {
    display: flex;
    flex-direction: column;
}

.agent-title {
    font-size: 12px;
    color: #777;
    text-transform: uppercase;
    font-weight: 600;
}

.agent-name {
    font-size: 17px;
    color: #333;
    font-weight: bold;
    margin: 2px 0;
}

.agent-phone {
    font-size: 14px;
    color: #27ae60;
    text-decoration: none;
    font-weight: 600;
}

.agent-phone:hover {
    text-decoration: underline;
}

.all-adverts-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 10px;
    border-top: 1px solid #eee;
    color: #3284bc;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: color 0.2s;
}

.all-adverts-link:hover {
    color: #1e618e;
}

/* ÖZEL NOT KUTUSU */
.private-note-box {
    margin-top: 20px;
    background-color: #fff3cd;
    border: 1px solid #ffeeba;
    border-radius: 8px;
    padding: 15px;
    color: #856404;
}

.private-note-box h4 {
    margin-bottom: 5px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.detail-section-title {
    color: #3284bc;
    font-size: 16px;
    margin: 20px 0 10px 0;
    display: flex;
    align-items: center;
    gap: 8px;
    border-bottom: 2px solid #edf4fc;
    padding-bottom: 5px;
}

.facades-bar-container {
    margin-top: 20px;
    background: #ffffff;
    border: 2px solid #89bdf1;
    border-radius: 10px;
    padding: 14px 18px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.03);
}

.facades-bar-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    color: #3284bc;
    font-size: 15px;
    white-space: nowrap;
    padding-right: 15px;
    border-right: 2px solid #edf2f7;
}

.facades-bar-title i {
    font-size: 18px;
}

.facades-grid {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    width: 100%;
}

.facade-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    user-select: none;
    flex: 1;
    justify-content: center;
    min-width: 90px;
}

/* Seçili / Aktif Cephe */
.facade-badge.active {
    background-color: #3284bc;
    color: #ffffff;
    border: 1px solid #3284bc;
}

.facade-badge.active i {
    color: #ffffff;
}

/* Seçili Olmayan / Pasif Cephe */
.facade-badge.inactive {
    background-color: #f8fafc;
    color: #94a3b8;
    border: 1px solid #e2e8f0;
}

.facade-badge.inactive i {
    color: #cbd5e1;
}


/* ==========================================================================
   MOBİL UYUMLULUK VE RESPONSIVE İYİLEŞTİRMELER
   ========================================================================== */

/* Genel Responsive Kapsayıcı Düzeltmeleri */
@media (max-width: 992px) {
    .MAIN-content {
        padding: 15px 10px;
    }

    .advert-detail-wrapper {
        padding: 15px;
    }

    .advert-grid {
        gap: 20px;
    }
}

/* Tablet ve Akıllı Telefonlar (768px ve Altı) */
@media (max-width: 768px) {
    /* Admin Bar */
    .admin-edit-bar button {
        font-size: 14px;
        align-items: center;
        justify-content: center;
        gap: 5px;
    }

    /* Başlık Alanı */
    .advert-title-container {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
    }

    .advert-title-container h1 {
        font-size: 22px;
        line-height: 1.3;
    }

    .location-text {
        font-size: 14px;
    }

    .reid-badge {
        align-self: flex-start;
    }

    /* Izgara Düzeni (Grid) */
    .advert-grid {
        flex-direction: column;
    }

    .gallery-section,
    .summary-section {
        width: 100%;
        min-width: 100%;
    }

    /* Galeri */
    .main-image-box {
        height: 280px;
    }

    .thumb-item {
        width: 70px;
        height: 50px;
    }

    /* Detay Tablosu (2 Kolondan Tek Kolona) */
    .detail-grid {
        grid-template-columns: 1fr;
    }

    .detail-card {
        padding: 10px 14px;
    }

    /* Cephe Bilgisi */
    .facades-bar-container {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }

    .facades-bar-title {
        border-right: none;
        border-bottom: 2px solid #edf2f7;
        padding-right: 0;
        padding-bottom: 8px;
    }

    .facades-grid {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }

    .facade-badge {
        min-width: unset;
        padding: 8px 10px;
    }

    /* Modal / Pop-up */
    .modal-content {
        padding: 20px 15px;
        width: 95%;
        border-radius: 15px;
    }

    .modal-content h3 {
        font-size: 22px;
    }

    #offerForm .form-group label {
        font-size: 15px;
    }

    #offerForm .form-group input {
        font-size: 16px;
    }
}

/* Küçük Ekranlı Telefonlar (480px ve Altı) */
@media (max-width: 480px) {
    .admin-edit-bar button {
        flex: 1 1 100%; /* Butonlar mobilde alt alta dizilir */
    }

    .main-image-box {
        height: 220px;
    }

    .price-value {
        font-size: 26px;
    }

    .offer-btn,
    .contact-btn {
        font-size: 16px;
        padding: 12px;
    }

    .details-table-inner h3 {
        font-size: 18px;
    }

    .detail-card {
        flex-direction: row;
        justify-content: space-between;
        font-size: 13px;
    }

    .detail-label, 
    .detail-value {
        font-size: 13px;
    }
}

/* MODAL STİLLERİ */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.modal-content {
    background: #ffffff;
    padding: 25px;
    border-radius: 20px;
    width: 90%;
    max-width: 450px;
    position: relative;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    border: 3px solid #3284bc;
}

.modal-close {
    display: flex;
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 30px;
    cursor: pointer;
    background-color: #3284bc;
    color: #fff;
    border-radius: 50%;
    width: 35px;
    height: 35px;
    justify-content: center;
    align-items: center;
    line-height: 1;
}

.modal-content h3 {
    color: #3284bc;
    font-size: 30px;
    margin-bottom: 10px;
}

.modal-subtitle {
    margin-bottom: 10px;
}

.REID-no {
    background-color: #89bdf1aa;
    padding: 4px;
    border-radius: 10px;
}

#offerForm .form-group {
    display: flex;
    flex-direction: column;
    padding: 10px 0;
}

#offerForm .form-group label {
    padding-left: 10px;
    font-size: 18px;
}

#offerForm .form-group input {
    border-radius: 20px;
    border: 2px solid #3284bc;
    padding: 5px 10px;
    font-size: 20px;
}

.submit-offer-btn {
    padding: 5px;
    margin-top: 10px;
    font-size: 20px;
    background-color: #3284bc;
    color: #fff;
    width: 100%;
    border-radius: 30px;
    border: none;
}

.detail-slider {
    display: flex;
    justify-content: center;
    border: none;
    height: 3px;
    width: calc(100%);
    background: linear-gradient(90deg, #3284bc 1%, #3498db 20%, #3498db 80%, #3284bc 99%);
    margin: 20px 0;
}