/* ============================================ */
/* DOCTORS SECTION - FRESH MEDICAL GREEN & BLUE */
/* ============================================ */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: #ffffff;
    color: #112a20;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* ============================================ */
/* SECTION                                      */
/* ============================================ */
.doctors-section {
    padding: 80px 0 0 !important;
    margin-bottom: 0 !important;
    background: linear-gradient(135deg, #eef7fa 0%, #e1f3f7 50%, #d2edf4 100%);
    min-height: auto;
}

.container {
    max-width: 1320px;
    margin: 0 auto;
    padding: 0 15px;
    box-sizing: border-box;
}

.section-header {
    margin-bottom: 50px;
}

.section-title {
    color: #112a20;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 15px;
    text-align: center;
    line-height: 1.2;
}

.section-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, #1b5e20, #2e7d32);
    margin: 15px auto 0;
    border-radius: 2px;
}

.section-description {
    color: #2d4f40;
    font-size: 1.1rem;
    max-width: 700px;
    margin: 0 auto;
    text-align: center;
    line-height: 1.8;
}

/* ============================================ */
/* GRID SYSTEM                                  */
/* ============================================ */
.row {
    display: flex;
    flex-wrap: wrap;
    margin: 0 -12px;
}

.col-xl-3 {
    flex: 0 0 25%;
    max-width: 25%;
    padding: 0 12px;
    margin-bottom: 24px;
    box-sizing: border-box;
}

/* ============================================ */
/* DOCTOR CARDS                                 */
/* ============================================ */
.doctor-card {
    background: #ffffff;
    border-radius: 16px;
    overflow: hidden;
    transition: all 0.3s ease;
    border: 1px solid rgba(27, 94, 32, 0.12);
    height: 100%;
    display: flex;
    flex-direction: column;
    box-shadow: 0 4px 15px rgba(27, 94, 32, 0.05);
}

.doctor-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 14px 35px rgba(27, 94, 32, 0.15);
    border-color: rgba(46, 125, 50, 0.3);
}

.doctor-card-inner {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.doctor-image-wrapper {
    position: relative;
    width: 100%;
    padding-top: 60%;
    overflow: hidden;
    background: #eef7fa;
    flex-shrink: 0;
}

.doctor-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.doctor-card:hover .doctor-image {
    transform: scale(1.04);
}

/* ✅ Doctor status badge on card (Active / Inactive) */
.doctor-status {
    position: absolute;
    top: 12px;
    right: 12px;
    padding: 4px 14px;
    border-radius: 20px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    border: 1px solid rgba(27, 94, 32, 0.12);
    white-space: nowrap;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.doctor-status.active {
    color: #2e7d32;
    border-color: #2e7d32;
    background: rgba(46, 125, 50, 0.12);
}

.doctor-status.inactive {
    color: #dc2626;
    border-color: #dc2626;
    background: rgba(220, 38, 38, 0.12);
}

.doctor-info {
    padding: 18px 20px 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 140px;
}

.doctor-name {
    color: #112a20;
    font-size: 1.05rem;
    font-weight: 700;
    margin-bottom: 3px;
    line-height: 1.3;
}

.doctor-specialty {
    color: #1b5e20;
    font-size: 0.82rem;
    margin-bottom: 10px;
    font-weight: 600;
}

.doctor-meta {
    display: flex;
    gap: 14px;
    margin-bottom: 12px;
    color: #2d4f40;
    font-size: 0.78rem;
    flex-wrap: wrap;
}

.doctor-meta i {
    margin-right: 4px;
    color: #2e7d32;
}

/* ============================================ */
/* BUTTONS                                      */
/* ============================================ */
.view-details-btn {
    background: linear-gradient(135deg, #0b3c4d 0%, #155e75 100%);
    color: #ffffff;
    border: none;
    padding: 10px 18px;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.82rem;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: auto;
    width: 100%;
    text-align: center;
    white-space: nowrap;
}

.view-details-btn:hover {
    background: linear-gradient(135deg, #0e4c61 0%, #1a7491 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(11, 60, 77, 0.25);
}

/* ============================================ */
/* VIEW ALL                                     */
/* ============================================ */
.view-all-container {
    margin-top: 30px !important;
    margin-bottom: 0 !important;
    padding-bottom: 30px !important;
    text-align: center;
}

.view-all-btn {
    display: inline-block;
    padding: 14px 45px;
    background: linear-gradient(135deg, #0b3c4d 0%, #155e75 100%);
    color: #ffffff;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1.05rem;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.view-all-btn:hover {
    background: linear-gradient(135deg, #0e4c61 0%, #1a7491 100%);
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(11, 60, 77, 0.3);
    color: #ffffff;
    text-decoration: none;
}

.view-all-btn span {
    margin-left: 10px;
    transition: transform 0.3s ease;
    display: inline-block;
}

.view-all-btn:hover span {
    transform: translateX(8px);
}

/* ============================================ */
/* MODAL / POPUP                                */
/* ============================================ */
.dr-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(17, 42, 32, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    z-index: 9999;
    display: none;
    justify-content: center;
    align-items: center;
    padding: 20px;
    box-sizing: border-box;
}

.dr-popup-content {
    background: #ffffff;
    border-radius: 24px;
    max-width: 800px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    padding: 32px;
    position: relative;
    border: 1px solid rgba(27, 94, 32, 0.12);
    animation: modalSlideIn 0.3s ease;
    box-shadow: 0 20px 60px rgba(27, 94, 32, 0.2);
    box-sizing: border-box;
}

@keyframes modalSlideIn {
    from { transform: translateY(-50px) scale(0.95); opacity: 0; }
    to { transform: translateY(0) scale(1); opacity: 1; }
}

.dr-popup-close {
    position: absolute;
    top: 16px;
    right: 20px;
    font-size: 28px;
    color: #2d4f40;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10;
    line-height: 1;
    background: none;
    border: none;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.dr-popup-close:hover {
    color: #1b5e20;
    background: rgba(27, 94, 32, 0.08);
    transform: rotate(90deg);
}

.dr-popup-flex {
    display: flex;
    gap: 30px;
}

.dr-popup-image-container {
    flex: 0 0 40%;
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    background: #eef7fa;
    min-height: 320px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 3px solid rgba(27, 94, 32, 0.15);
    border-top: 3px solid #1b5e20;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

#modalImg {
    width: 100%;
    height: 100%;
    min-height: 320px;
    object-fit: cover;
    display: none;
}

.dr-popup-details {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.pop-title {
    color: #112a20;
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 20px;
    line-height: 1.2;
}

.pop-title::after {
    content: '';
    display: block;
    width: 50px;
    height: 3px;
    background: linear-gradient(90deg, #1b5e20, #2e7d32);
    margin-top: 8px;
    border-radius: 2px;
}

.pop-info p {
    color: #2d4f40;
    margin-bottom: 12px;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 8px 0;
    border-bottom: 1px solid rgba(27, 94, 32, 0.08);
    line-height: 1.5;
}

.pop-info p strong {
    color: #112a20;
    min-width: 100px;
    font-weight: 600;
    flex-shrink: 0;
}

.pop-info p span {
    color: #1b5e20;
    word-break: break-word;
    overflow-wrap: anywhere;
}

/* ✅ Status badge inside modal (Active / Inactive) */
.status-badge {
    display: inline-block;
    padding: 4px 14px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border: 1px solid transparent;
    white-space: nowrap;
}

.status-badge.active {
    background: rgba(46, 125, 50, 0.12);
    color: #2e7d32;
    border-color: #2e7d32;
}

.status-badge.inactive {
    background: rgba(220, 38, 38, 0.12);
    color: #dc2626;
    border-color: #dc2626;
}

/* ============================================ */
/* SCROLLBAR                                    */
/* ============================================ */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: #eef7fa; }
::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #0b3c4d 0%, #155e75 100%);
    border-radius: 4px;
}

/* ============================================ */
/* ✅ RESPONSIVE                                 */
/* ============================================ */
@media (max-width: 1200px) {
    .col-xl-3 {
        flex: 0 0 33.333%;
        max-width: 33.333%;
    }
}

@media (max-width: 992px) {
    .container {
        max-width: 100%;
        padding: 0 20px;
    }

    .doctors-section {
        padding: 60px 0 0 !important;
    }

    .section-header {
        margin-bottom: 40px;
    }

    .section-title {
        font-size: 2rem;
    }

    .section-description {
        font-size: 1rem;
        padding: 0 10px;
    }

    .col-xl-3 {
        flex: 0 0 50%;
        max-width: 50%;
    }

    .dr-popup-flex {
        flex-direction: column;
        gap: 20px;
    }

    .dr-popup-image-container {
        flex: 0 0 260px;
        min-height: 260px;
    }

    #modalImg {
        min-height: 260px;
    }

    .pop-title {
        font-size: 1.5rem;
    }
}

@media (max-width: 768px) {
    .doctors-section {
        padding: 50px 0 0 !important;
    }

    .container {
        padding: 0 16px;
    }

    .section-header {
        margin-bottom: 30px;
    }

    .section-title {
        font-size: 1.6rem;
    }

    .section-title::after {
        width: 60px;
        height: 3px;
        margin-top: 12px;
    }

    .section-description {
        font-size: 0.9rem;
        line-height: 1.6;
    }

    .col-xl-3 {
        flex: 0 0 100%;
        max-width: 100%;
        margin-bottom: 18px;
    }

    .doctor-card {
        border-radius: 14px;
    }

    .doctor-card:hover {
        transform: none;
    }

    .doctor-card:hover .doctor-image {
        transform: none;
    }

    .doctor-info {
        padding: 16px 18px 18px;
        min-height: auto;
    }

    .doctor-name {
        font-size: 1rem;
    }

    .doctor-specialty {
        font-size: 0.8rem;
    }

    .view-all-btn {
        padding: 12px 32px;
        font-size: 0.95rem;
        width: 100%;
        max-width: 320px;
        box-sizing: border-box;
    }

    .dr-popup-overlay {
        padding: 15px;
        align-items: flex-start;
        padding-top: 30px;
    }

    .dr-popup-content {
        padding: 22px 18px;
        border-radius: 18px;
        max-height: 85vh;
    }

    .dr-popup-close {
        top: 10px;
        right: 12px;
        width: 32px;
        height: 32px;
        font-size: 24px;
    }

    .dr-popup-image-container {
        flex: 0 0 200px;
        min-height: 200px;
        border-radius: 12px;
    }

    #modalImg {
        min-height: 200px;
    }

    .pop-title {
        font-size: 1.3rem;
        margin-bottom: 16px;
    }

    .pop-info p {
        font-size: 0.9rem;
        padding: 6px 0;
        margin-bottom: 8px;
    }

    .pop-info p strong {
        min-width: 80px;
        font-size: 0.85rem;
    }

    .status-badge {
        font-size: 11px;
        padding: 3px 12px;
    }
}

@media (max-width: 576px) {
    .doctors-section {
        padding: 40px 0 0 !important;
    }

    .container {
        padding: 0 12px;
    }

    .section-header {
        margin-bottom: 25px;
    }

    .section-title {
        font-size: 1.4rem;
    }

    .section-description {
        font-size: 0.85rem;
    }

    .doctor-card {
        border-radius: 12px;
    }

    .doctor-status {
        font-size: 9px;
        padding: 3px 10px;
        top: 10px;
        right: 10px;
    }

    .doctor-name {
        font-size: 0.95rem;
    }

    .doctor-specialty {
        font-size: 0.78rem;
    }

    .doctor-meta {
        font-size: 0.72rem;
        gap: 10px;
    }

    .view-details-btn {
        padding: 9px 14px;
        font-size: 0.78rem;
    }

    .view-all-btn {
        padding: 11px 24px;
        font-size: 0.88rem;
        letter-spacing: 0.3px;
    }

    .dr-popup-content {
        padding: 18px 14px;
        border-radius: 16px;
    }

    .pop-title {
        font-size: 1.15rem;
    }

    .dr-popup-image-container {
        flex: 0 0 170px;
        min-height: 170px;
    }

    #modalImg {
        min-height: 170px;
    }

    .pop-info p {
        font-size: 0.85rem;
        flex-direction: column;
        gap: 2px;
    }

    .pop-info p strong {
        min-width: auto;
        font-size: 0.8rem;
    }
}

@media (max-width: 380px) {
    .doctors-section {
        padding: 32px 0 0 !important;
    }

    .section-title {
        font-size: 1.25rem;
    }

    .section-description {
        font-size: 0.8rem;
    }

    .doctor-info {
        padding: 14px 14px 16px;
    }

    .doctor-name {
        font-size: 0.9rem;
    }

    .view-all-btn {
        padding: 10px 20px;
        font-size: 0.82rem;
    }

    .dr-popup-content {
        padding: 16px 12px;
    }

    .dr-popup-image-container {
        flex: 0 0 150px;
        min-height: 150px;
    }

    #modalImg {
        min-height: 150px;
    }

    .pop-title {
        font-size: 1.05rem;
    }

    .pop-info p {
        font-size: 0.8rem;
    }
}