/**
 * Top Header Styles
 * Carlos6 Theme
 */

/* ====================================
   Top Header Container
==================================== */
.carlos6-top-header {
    background-color: #0B1728;
    width: 100%;
    position: relative;
    z-index: 1000;
}


.carlos6-top-header a {
    color: #fff !important;
}

.top-header-container {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 72px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    min-height: 44px;
}

/* ====================================
   Right Side: Pages Links
==================================== */
.top-header-right {
    display: flex;
    align-items: center;
}

.top-header-nav {
    display: flex;
    align-items: center;
    gap: 15px;
}

.top-header-link {
    /* Typography */
    font-family: 'IBM Plex Sans Arabic', -apple-system, BlinkMacSystemFont, sans-serif;
    font-style: normal;
    font-weight: 400;
    font-size: 14px;
    line-height: 150%; /* 21px */
    
    /* Display */
    display: flex;
    align-items: center;
    text-align: center;
    
    /* Colors */
    color: #FFFFFF;
    text-decoration: none;
    
    /* Transition */
    transition: opacity 0.3s ease, color 0.3s ease;
}

.top-header-link:hover,
.top-header-link:focus {
    opacity: 0.7;
    color: #CCCCCC; /* ← رمادي عند الـ hover */
    text-decoration: none; /* ← إزالة الخط */
}

.top-header-separator {
    width: 15px;
    height: 1px;
    background-color: #FFFFFF;
    opacity: 0.2;
    transform: rotate(90deg);
    flex-shrink: 0;
}

/* ====================================
   Left Side: Contact Info
==================================== */
.top-header-left {
    display: flex;
    align-items: center;
}

.top-header-contact {
    display: flex;
    align-items: center;
    gap: 10px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-direction: row-reverse; /* ← الأيقونة على يمين النص */
    /* Typography */
    font-family: 'IBM Plex Sans Arabic', -apple-system, BlinkMacSystemFont, sans-serif;
    font-style: normal;
    font-weight: 400;
    font-size: 14px;
    line-height: 150%; /* 21px */
    
    /* Colors */
    color: #FFFFFF;
    text-decoration: none;
    
    /* Transition */
    transition: opacity 0.3s ease, color 0.3s ease; /* ← أضفنا color */
}

.contact-item:hover,
.contact-item:focus {
    opacity: 0.7;
    color: #CCCCCC; /* ← رمادي عند الـ hover */
}

.contact-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

.contact-icon svg,
.contact-icon img {
    width: 16px;
    height: 16px;
    display: block;
}

.contact-icon svg {
    fill: currentColor;
}

.contact-text {
    white-space: nowrap;
}

.contact-separator {
    width: 10px;
    height: 1px;
    background-color: #FFFFFF;
    transform: rotate(90deg);
    flex-shrink: 0;
}

/* ====================================
   Responsive Design
==================================== */

/* Tablet */
@media screen and (max-width: 1024px) {
    .top-header-container {
        padding: 0 40px;
    }
    
    .top-header-link,
    .contact-item {
        font-size: 13px;
    }
}

/* Mobile Large */
@media screen and (max-width: 768px) {
    .top-header-container {
        padding: 0 20px;
        flex-direction: column;
        gap: 10px;
        min-height: auto;
        padding-top: 12px;
        padding-bottom: 12px;
    }
    
    .top-header-right,
    .top-header-left {
        width: 100%;
        justify-content: center;
    }
    
    .top-header-nav {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .top-header-link,
    .contact-item {
        font-size: 12px;
    }
}

/* Mobile Small */
@media screen and (max-width: 480px) {
    .top-header-container {
        padding: 0 15px;
    }
    
    .top-header-nav {
        flex-direction: column;
        gap: 8px;
    }
    
    .top-header-separator {
        display: none;
    }
    
    .top-header-contact {
        flex-direction: column;
        gap: 8px;
    }
    
    .contact-separator {
        display: none;
    }
}

/* ====================================
   RTL Support
==================================== */
[dir="rtl"] .contact-item {
    flex-direction: row; /* ← في RTL نعكسها للطبيعي */
}

[dir="rtl"] .top-header-nav {
    flex-direction: row-reverse;
}

/* ====================================
   Accessibility
==================================== */
.top-header-link:focus-visible,
.contact-item:focus-visible {
    outline: 2px solid #FFFFFF;
    outline-offset: 2px;
    border-radius: 2px;
}

/* Skip to content for screen readers */
.skip-to-content {
    position: absolute;
    left: -9999px;
    z-index: 999;
    padding: 1em;
    background-color: #0B1728;
    color: #FFFFFF;
    text-decoration: none;
}

.skip-to-content:focus {
    left: 50%;
    transform: translateX(-50%);
    top: 10px;
}

/* ====================================
   Print Styles
==================================== */
@media print {
    .carlos6-top-header {
        display: none;
    }
}

/* ====================================
   High Contrast Mode
==================================== */
@media (prefers-contrast: high) {
    .top-header-link,
    .contact-item {
        font-weight: 500;
    }
    
    .top-header-separator,
    .contact-separator {
        opacity: 1;
    }
}

/* ====================================
   Reduced Motion
==================================== */
@media (prefers-reduced-motion: reduce) {
    .top-header-link,
    .contact-item {
        transition: none;
    }
}