/* 
 * مستشفى الأطفال بالبحيرة Luxury Header Styles
 * Sticky, Responsive, Premium
 */

.pd-main-header, .site-header, #pdMainHeader {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    z-index: 9999 !important;
    background: transparent !important;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1) !important;
    padding: 15px 0 !important;
    border: none !important;
    box-shadow: none !important;
}

/* Ensure header respects WP Admin Bar if present */
.admin-bar .pd-main-header, 
.admin-bar .site-header, 
.admin-bar #pdMainHeader {
    top: 32px !important;
}

@media (max-width: 782px) {
    .admin-bar .pd-main-header, 
    .admin-bar .site-header, 
    .admin-bar #pdMainHeader {
        top: 46px !important;
    }
}

/* Sticky state: maintain transparency but add subtle blur for readability */
.pd-main-header.pd-sticky, .site-header.pd-sticky {
    background: rgba(255, 255, 255, 0.85) !important;
    backdrop-filter: blur(15px) !important;
    -webkit-backdrop-filter: blur(15px) !important;
    padding: 10px 0 !important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05) !important;
}

@media (min-width: 1024px) {
    .pd-main-header, .site-header, #pdMainHeader {
        max-width: 1360px !important;
        left: 50% !important;
        transform: translateX(-50%) !important;
    }
}

/* Global Logo Size Fix */
.site-header .site-logo img,
.site-header .logo img,
.pd-header-inner .pd-logo img,
#pdMainHeader img,
#pdMainHeader .pd-logo img {
    max-height: 50px !important;
    width: auto !important;
    transition: all 0.3s ease !important;
    display: inline-block !important;
}

/* Mobile Specific Refinements */
@media (max-width: 1023px) {
    .pd-main-header, .site-header, #pdMainHeader {
        left: 0 !important;
        transform: none !important;
        width: 100% !important;
        max-width: 100% !important;
        padding: 10px 0 !important;
        height: auto !important;
        border-radius: 0 !important; /* Remove theme's rounded corners */
        background: transparent !important;
    }

    .site-header.pd-sticky, .pd-main-header.pd-sticky {
        background: rgba(255, 255, 255, 0.95) !important;
    }

    .site-header .site-logo img,
    .site-header .logo img,
    .pd-header-inner .pd-logo img,
    #pdMainHeader img,
    #pdMainHeader .pd-logo img {
        max-height: 40px !important;
        margin-left: 15px !important; /* Ensure logo isn't cut off */
    }
}

.pd-header-inner {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 30px;
}

.pd-logo img {
    height: 50px;
    width: auto;
    transition: var(--pd-transition);
}

.pd-main-header.pd-sticky .pd-logo img {
    height: 40px;
}

/* Nav Menu */
.pd-nav-menu {
    display: flex;
    align-items: center;
    gap: 30px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.pd-nav-item {
    position: relative;
}

.pd-nav-link {
    color: var(--pd-dark);
    text-decoration: none;
    font-weight: 600;
    font-size: 15px;
    transition: 0.3s;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 0;
}

.pd-nav-link:hover,
.pd-nav-item:hover>.pd-nav-link {
    color: var(--pd-teal);
}

/* Transparent header links: uncomment below to set white text on hero */
/* .pd-main-header:not(.pd-sticky) .pd-nav-link { color: white; } */

/* Dropdown */
.pd-dropdown {
    position: absolute;
    top: 100%;
    left: -20px;
    background: white;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.1);
    border-radius: 12px;
    padding: 15px;
    min-width: 260px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(15px);
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
    border: 1px solid rgba(0, 0, 0, 0.05);
    list-style: none;
}

.pd-nav-item:hover .pd-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.pd-dropdown li a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 15px;
    color: var(--pd-text);
    text-decoration: none;
    font-size: 14px;
    border-radius: 8px;
    transition: 0.3s;
}

.pd-dropdown li a:hover {
    background: rgba(12, 184, 182, 0.05);
    color: var(--pd-teal);
    transform: translateX(5px);
}

.pd-dropdown-icon {
    font-size: 10px;
    opacity: 0.6;
}

/* Header Actions */
.pd-header-actions {
    display: flex;
    align-items: center;
    gap: 20px;
}

.pd-icon-btn {
    color: var(--pd-dark);
    font-size: 20px;
    cursor: pointer;
    transition: 0.3s;
}

.pd-icon-btn:hover {
    color: var(--pd-teal);
    transform: scale(1.1);
}

.pd-header-cta {
    padding: 12px 25px;
    font-size: 14px;
}

/* Mobile Toggle */
.pd-mobile-toggle {
    display: none;
    font-size: 28px;
    cursor: pointer;
}

@media (max-width: 1100px) {
    .pd-nav-menu {
        display: none;
    }

    .pd-mobile-toggle {
        display: block;
    }

    .pd-header-actions .pd-header-cta {
        display: none;
    }
}

/* Sub-dropdown for Price List */
.pd-sub-dropdown {
    position: absolute;
    left: 100%;
    top: 0;
    background: white;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.1);
    border-radius: 12px;
    padding: 15px;
    min-width: 240px;
    opacity: 0;
    visibility: hidden;
    transform: translateX(10px);
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
    border: 1px solid rgba(0, 0, 0, 0.05);
    list-style: none;
    z-index: 10000;
}

.pd-dropdown li:hover .pd-sub-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
}

/* FAQ styles */
.pd-faq-section {
    background: var(--pd-light, #f8fbfa);
}

.pd-faq-item {
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: 20px;
    overflow: hidden;
    cursor: pointer;
    background: #fff;
    transition: 0.3s;
    margin-bottom: 15px;
}

.pd-faq-item:hover {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.07);
}

.faq-question {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 22px 28px;
    font-weight: 600;
    font-size: 16px;
    color: var(--pd-dark);
}

.faq-question .dashicons {
    transition: 0.3s;
    color: var(--pd-teal);
}

.pd-faq-item.active .faq-question .dashicons {
    transform: rotate(45deg);
}

.faq-answer {
    display: none;
    padding: 0 28px 22px;
    color: var(--pd-text-light, #6b7280);
    line-height: 1.75;
    font-size: 15px;
}

.pd-faq-item.active .faq-answer {
    display: block;
}