/* ============================================================================
   AbuJudom — Unified header action cluster
   ----------------------------------------------------------------------------
   Loaded in BOTH LTR (SiteEn) and RTL (SiteAr). Both copies are byte-identical.

   Goal:
   - The four header actions (Add Property, Language, Favorites bell, Login or
     Dashboard) live inside a single `.aj-header-actions` flex container and
     render as a cohesive group of pill buttons:
       * Add Property   -> primary filled pill (var(--aj-primary))
       * Language       -> outline segmented pill (EN / AR)
       * Favorites bell -> outline icon-pill circle
       * Login/Dashboard-> outline pill (icon + label)
   - All four share the same height, radius, hover treatment and icon size.
   - The cluster is pinned to the inline-end of the header (RIGHT in LTR,
     LEFT in RTL). The logo stays at the inline-start, the primary nav fills
     the middle. This is achieved with flex `order` on the wrapper so the
     DOM order does not need to change.

   Tokens used (defined by abujudom-enhancements.css):
     --aj-primary, --aj-primary-dark, --aj-primary-soft,
     --aj-text, --aj-text-muted, --aj-border,
     --aj-shadow, --aj-shadow-hover, --aj-radius, --aj-transition.
   ============================================================================ */

:root {
    --aj-action-h: 30px;
    --aj-action-pad-x: 11px;
    --aj-action-icon: 14px;
    --aj-action-radius: 999px;
}

/* -- 1. Header layout: logo | menu | action cluster ------------------------ */
header.main-header .logo-holder        { order: 1; }
header.main-header .nav-holder.main-menu { order: 5; }
header.main-header .aj-header-actions  { order: 9; }
header.main-header .nav-button-wrap    { order: 10; }

/* -- 2. Cluster wrapper ---------------------------------------------------- */
header.main-header .aj-header-actions {
    display: inline-flex !important;
    align-items: center;
    gap: 6px;
    flex-wrap: nowrap;
    flex-shrink: 0;
    margin: 0;
}

/* Neutralise legacy float / margin rules from the original template that
   would otherwise scatter the cluster children. */
header.main-header .aj-header-actions > .add-list_wrap,
header.main-header .aj-header-actions > .aj-lang-toggle,
header.main-header .aj-header-actions > .show-reg-form,
header.main-header .aj-header-actions > .cart-btn {
    float: none !important;
    margin: 0 !important;
    padding: 0 !important;
    height: var(--aj-action-h);
    flex-shrink: 0;
    flex-grow: 0;
    flex-basis: auto;
}

/* -- 3. Primary CTA: Add Property ----------------------------------------- */
header.main-header .aj-header-actions .add-list_wrap {
    display: inline-flex !important;
    align-items: center;
}
header.main-header .aj-header-actions .add-list_wrap .add-list,
header.main-header .aj-header-actions .add-list_wrap .aj-add-btn {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    gap: 5px;
    height: var(--aj-action-h);
    padding: 0 var(--aj-action-pad-x) !important;
    border: 1px solid var(--aj-primary, #b7cd27) !important;
    border-radius: var(--aj-action-radius) !important;
    background: var(--aj-primary, #b7cd27) !important;
    color: #ffffff !important;
    font-size: 12.5px !important;
    font-weight: 600 !important;
    letter-spacing: 0.2px;
    line-height: 1 !important;
    white-space: nowrap;
    text-decoration: none !important;
    box-shadow: var(--aj-shadow, 0 4px 12px rgba(15, 23, 42, 0.06));
    transition: background var(--aj-transition, 280ms ease),
                border-color var(--aj-transition, 280ms ease),
                color var(--aj-transition, 280ms ease),
                box-shadow var(--aj-transition, 280ms ease),
                transform var(--aj-transition, 280ms ease);
}
header.main-header .aj-header-actions .add-list_wrap .add-list:hover,
header.main-header .aj-header-actions .add-list_wrap .aj-add-btn:hover,
header.main-header .aj-header-actions .add-list_wrap .add-list:focus-visible,
header.main-header .aj-header-actions .add-list_wrap .aj-add-btn:focus-visible {
    background: var(--aj-primary-dark, #a7bd1b) !important;
    border-color: var(--aj-primary-dark, #a7bd1b) !important;
    color: #ffffff !important;
    box-shadow: var(--aj-shadow-hover, 0 12px 28px rgba(15, 23, 42, 0.14));
    transform: translateY(-1px);
}
header.main-header .aj-header-actions .add-list_wrap .add-list i,
header.main-header .aj-header-actions .add-list_wrap .aj-add-btn i {
    font-size: var(--aj-action-icon);
 
    color: inherit;
    margin: 0 !important;
}

/* -- 4. Secondary segmented pill: Language toggle ------------------------- */
header.main-header .aj-header-actions .aj-lang-toggle {
    display: inline-flex !important;
    align-items: center;
    height: var(--aj-action-h);
    padding: 2px;
    gap: 0;
    border: 1px solid var(--aj-border, #e5e7eb) !important;
    border-radius: var(--aj-action-radius) !important;
    background: transparent !important;
    overflow: hidden;
    transition: background var(--aj-transition, 280ms ease),
                border-color var(--aj-transition, 280ms ease);
}
header.main-header .aj-header-actions .aj-lang-toggle:hover {
    background: var(--aj-primary-soft, rgba(183, 205, 39, 0.12)) !important;
    border-color: var(--aj-primary, #b7cd27) !important;
}
header.main-header .aj-header-actions .aj-lang-toggle .aj-lang-opt {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    height: calc(var(--aj-action-h) - 6px);
    min-width: 30px;
    padding: 0 8px;
    border-radius: var(--aj-action-radius);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.4px;
    text-decoration: none !important;
    color: var(--aj-text-muted, #6b7280);
    background: transparent;
    transition: background var(--aj-transition, 280ms ease),
                color var(--aj-transition, 280ms ease);
}
header.main-header .aj-header-actions .aj-lang-toggle .aj-lang-opt:hover {
    color: var(--aj-text, #1f2937);
}
header.main-header .aj-header-actions .aj-lang-toggle .aj-lang-opt--active,
header.main-header .aj-header-actions .aj-lang-toggle .aj-lang-opt--active:hover {
    background: var(--aj-primary, #b7cd27) !important;
    color: #ffffff !important;
    box-shadow: 0 2px 6px rgba(183, 205, 39, 0.3);
    pointer-events: none;
}

/* -- 5. Secondary outline pill: Login / Dashboard ------------------------- */
header.main-header .aj-header-actions .show-reg-form {
    display: inline-flex !important;
    align-items: center;
    background: transparent;
    width: auto;
}
header.main-header .aj-header-actions .show-reg-form a {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: var(--aj-action-h);
    padding: 0 var(--aj-action-pad-x) !important;
    border: 1px solid var(--aj-border, #e5e7eb) !important;
    border-radius: var(--aj-action-radius) !important;
    background: transparent !important;
    color: var(--aj-text, #1f2937) !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    line-height: 1 !important;
    white-space: nowrap;
    text-decoration: none !important;
    transition: background var(--aj-transition, 280ms ease),
                border-color var(--aj-transition, 280ms ease),
                color var(--aj-transition, 280ms ease),
                box-shadow var(--aj-transition, 280ms ease);
}
header.main-header .aj-header-actions .show-reg-form a:hover,
header.main-header .aj-header-actions .show-reg-form a:focus-visible {
    background: var(--aj-primary-soft, rgba(183, 205, 39, 0.12)) !important;
    border-color: var(--aj-primary, #b7cd27) !important;
    color: var(--aj-primary-dark, #a7bd1b) !important;
}
header.main-header .aj-header-actions .show-reg-form a i {
    font-size: var(--aj-action-icon);
    line-height: 1;
    color: inherit;
    margin: 0 !important;
}
header.main-header .aj-header-actions .show-reg-form a span {
    display: inline-block;
    font-size: 13px;
    font-weight: 600;
    line-height: 1;
    color: inherit;
}

/* -- 6. Secondary outline icon-pill: Favorites bell ----------------------- */
header.main-header .aj-header-actions .cart-btn {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    width: var(--aj-action-h);
    min-width: var(--aj-action-h);
    height: var(--aj-action-h);
    padding: 0 !important;
    border: 1px solid var(--aj-border, #e5e7eb) !important;
    border-radius: var(--aj-action-radius) !important;
    background: transparent !important;
    color: var(--aj-text, #1f2937) !important;
    cursor: pointer;
    position: relative;
    overflow: visible !important;
    box-shadow: none;
    transition: background var(--aj-transition, 280ms ease),
                border-color var(--aj-transition, 280ms ease),
                color var(--aj-transition, 280ms ease),
                transform var(--aj-transition, 280ms ease);
}
header.main-header .aj-header-actions .cart-btn:hover,
header.main-header .aj-header-actions .cart-btn:focus-visible {
    background: var(--aj-primary-soft, rgba(183, 205, 39, 0.12)) !important;
    border-color: var(--aj-primary, #b7cd27) !important;
    color: var(--aj-primary-dark, #a7bd1b) !important;
    transform: translateY(-1px);
}
header.main-header .aj-header-actions .cart-btn i {
    font-size: var(--aj-action-icon);
    line-height: 1;
    color: inherit;
    margin: 0 !important;
}
header.main-header .aj-header-actions .cart-btn .cart-btn_counter {
    position: absolute;
    top: -4px;
    inset-inline-end: -4px;
    inset-inline-start: auto;
    min-width: 18px;
    height: 18px;
    padding: 0 4px;
    line-height: 18px;
    font-size: 10px;
    font-weight: 700;
    color: #ffffff;
    background: var(--aj-primary, #b7cd27);
    border-radius: 9px;
    border: 2px solid #ffffff;
    text-align: center;
    box-sizing: content-box;
}

/* -- 7. Focus visibility -------------------------------------------------- */
header.main-header .aj-header-actions .add-list_wrap .add-list:focus-visible,
header.main-header .aj-header-actions .add-list_wrap .aj-add-btn:focus-visible,
header.main-header .aj-header-actions .aj-lang-toggle .aj-lang-opt:focus-visible,
header.main-header .aj-header-actions .show-reg-form a:focus-visible,
header.main-header .aj-header-actions .cart-btn:focus-visible {
    outline: 2px solid var(--aj-primary, #b7cd27);
    outline-offset: 2px;
}

/* -- 8. Dark mode parity -------------------------------------------------- */
body.aj-dark header.main-header .aj-header-actions .aj-lang-toggle,
body.aj-dark header.main-header .aj-header-actions .show-reg-form a,
body.aj-dark header.main-header .aj-header-actions .cart-btn {
    border-color: var(--aj-border, #334155) !important;
    color: var(--aj-text, #e5e7eb) !important;
    background: transparent !important;
}
body.aj-dark header.main-header .aj-header-actions .aj-lang-toggle .aj-lang-opt {
    color: var(--aj-text-muted, #94a3b8);
}
body.aj-dark header.main-header .aj-header-actions .aj-lang-toggle:hover,
body.aj-dark header.main-header .aj-header-actions .show-reg-form a:hover,
body.aj-dark header.main-header .aj-header-actions .cart-btn:hover {
    background: rgba(183, 205, 39, 0.18) !important;
    border-color: var(--aj-primary, #b7cd27) !important;
}
body.aj-dark header.main-header .aj-header-actions .aj-lang-toggle .aj-lang-opt--active,
body.aj-dark header.main-header .aj-header-actions .aj-lang-toggle .aj-lang-opt--active:hover {
    background: var(--aj-primary, #b7cd27) !important;
    color: #0f172a !important;
}

/* -- 9. RTL: cluster pinned to the LEFT of the header --------------------- */
/* The order values above already place the cluster at the inline-end edge,
   which is LEFT under `dir="rtl"`. These rules only flip a few directional
   tweaks (the bell counter position, any directional margins). */
html[dir="rtl"] header.main-header .aj-header-actions {
    margin-inline-start: 0;
    margin-inline-end: 0;
}
html[dir="rtl"] header.main-header .aj-header-actions .cart-btn .cart-btn_counter {
    inset-inline-end: -4px;
    inset-inline-start: auto;
}

/* -- 10. Responsive ------------------------------------------------------- */
@media (max-width: 991px) {
    :root {
        --aj-action-h: 26px;
        --aj-action-pad-x: 9px;
        --aj-action-icon: 13px;
    }
    header.main-header .aj-header-actions { gap: 4px; }
    header.main-header .aj-header-actions .add-list_wrap .add-list span,
    header.main-header .aj-header-actions .add-list_wrap .aj-add-btn span,
    header.main-header .aj-header-actions .show-reg-form a span {
        display: none;
    }
    header.main-header .aj-header-actions .add-list_wrap .add-list,
    header.main-header .aj-header-actions .add-list_wrap .aj-add-btn,
    header.main-header .aj-header-actions .show-reg-form a {
        width: var(--aj-action-h);
        min-width: var(--aj-action-h);
        padding: 0 !important;
    }
}

@media (max-width: 600px) {
    :root { --aj-action-h: 24px; }
    header.main-header .aj-header-actions { gap: 3px; }
    header.main-header .aj-header-actions .aj-lang-toggle .aj-lang-opt {
        min-width: 24px;
        padding: 0 6px;
        font-size: 10px;
    }
}

/* -- 10.b Mobile nav hardening ---------------------------------------------
   Keep desktop nav hidden on small screens and only show it when the
   template toggles `.vismobmenu` from the hamburger button. */
@media (max-width: 991px) {
    html header.main-header {
        position: relative !important;
    }
    header.main-header .nav-button-wrap {
        display: block !important;
        margin-inline-start: 8px;
    }
    header.main-header .nav-holder.main-menu {
        position: absolute !important;
        top: calc(100% + 8px) !important;
        inset-inline-end: 0 !important;
        inset-inline-start: auto !important;
        width: min(92vw, 320px) !important;
        height: auto !important;
        display: block !important;
        visibility: hidden !important;
        opacity: 0 !important;
        pointer-events: none !important;
        z-index: 9999 !important;
    }
    header.main-header .nav-holder.main-menu nav > ul {
        display: block !important;
    }
    header.main-header .nav-holder.main-menu:not(.vismobmenu) nav > ul {
        display: none !important;
    }
    header.main-header .nav-holder.main-menu.vismobmenu {
        visibility: visible !important;
        opacity: 1 !important;
        pointer-events: auto !important;
    }
    header.main-header .nav-holder.main-menu nav > ul > li {
        display: block !important;
        width: 100%;
    }
    header.main-header .nav-holder.main-menu nav > ul > li > a {
        display: flex !important;
        width: 100%;
        justify-content: space-between;
        padding: 12px 10px !important;
        font-size: 14px !important;
        line-height: 1.4 !important;
    }
    header.main-header .aj-header-actions {
        margin-inline-start: auto;
        max-width: calc(100% - 140px);
        overflow-x: auto;
        scrollbar-width: none;
    }
    header.main-header .aj-header-actions::-webkit-scrollbar {
        display: none;
    }
}

@media (max-width: 600px) {
    header.main-header .aj-header-actions .add-list_wrap {
        display: none !important;
    }
}

/* JS-assisted fallback for mobile emulation environments where viewport
   breakpoints may not apply early enough. */
body.aj-mobile-nav-force header.main-header .nav-button-wrap {
    display: flex !important;
    align-items: center;
}
body.aj-mobile-nav-force header.main-header .nav-holder.main-menu {
    position: absolute !important;
    top: calc(100% + 8px) !important;
    inset-inline-end: 0 !important;
    inset-inline-start: auto !important;
    width: min(92vw, 320px) !important;
    height: auto !important;
    display: block !important;
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
    z-index: 9999 !important;
}
body.aj-mobile-nav-force header.main-header .nav-holder.main-menu nav > ul {
    display: none !important;
}
body.aj-mobile-nav-force header.main-header .nav-holder.main-menu.vismobmenu {
    visibility: visible !important;
    opacity: 1 !important;
    pointer-events: auto !important;
}
body.aj-mobile-nav-force header.main-header .nav-holder.main-menu.vismobmenu nav > ul {
    display: block !important;
}
body.aj-mobile-nav-force header.main-header .nav-holder.main-menu nav > ul > li {
    display: block !important;
    width: 100%;
}
body.aj-mobile-nav-force header.main-header .nav-holder.main-menu nav > ul > li > a {
    display: flex !important;
    width: 100%;
    justify-content: space-between;
    padding: 12px 10px !important;
    font-size: 14px !important;
    line-height: 1.4 !important;
}
body.aj-mobile-nav-force header.main-header .aj-header-actions {
    margin-inline-start: auto;
    max-width: calc(100% - 140px);
    overflow-x: auto;
    scrollbar-width: none;
}
body.aj-mobile-nav-force header.main-header .aj-header-actions::-webkit-scrollbar {
    display: none;
}
@media (max-width: 600px) {
    body.aj-mobile-nav-force header.main-header .aj-header-actions .add-list_wrap {
        display: none !important;
    }
}

/* -- 11. Brand logo: compact header + big overlapping logo ----------------
   Slim header bar (~68px) with the logo visually big (86px) that slightly
   overflows the bar for a premium, modern feel. Logo has no white-card
   backdrop — just a soft drop-shadow. Uses `overflow: visible` on the
   header and negative margin-block on the logo to keep the header height
   compact while the logo protrudes. The `html` selector prefix raises
   specificity above the rules in `abujudom-enhancements.css`. */
html header.main-header {
    min-height: 0 !important;
    height: 62px !important;
    padding-block: 0 !important;
    display: flex !important;
    align-items: center !important;
    overflow: visible !important;
}
html header.main-header .header-inner {
    display: flex !important;
    align-items: center !important;
    height: 100% !important;
    padding-block: 0 !important;
}
html header.main-header .logo-holder {
    position: relative !important;
    top: 0 !important;
    align-self: center !important;
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    z-index: 20;
    overflow: visible !important;
}
html header.main-header .logo-holder a {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    width: auto !important;
    height: auto !important;
    padding: 0 !important;
    background: transparent !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    transform: none !important;
}
html header.main-header .logo-holder a:hover,
html header.main-header .logo-holder a:focus-visible {
    background: transparent !important;
    box-shadow: none !important;
    transform: none !important;
}
html header.main-header .logo-holder img {
    display: block;
    height: 80px !important;
    max-height: 80px !important;
    width: auto !important;
    max-width: none !important;
    padding: 0 !important;
    margin-top: 0 !important;
    margin-bottom: -18px !important;  /* logo overflows downward only — premium drop */
    background: transparent !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    filter: drop-shadow(0 3px 8px rgba(0, 0, 0, 0.12)) !important;
    transition: none !important;
}
body.aj-dark header.main-header .logo-holder a,
body.aj-dark header.main-header .logo-holder a:hover {
    background: transparent !important;
    box-shadow: none !important;
}
body.aj-dark header.main-header .logo-holder img {
    filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.45)) !important;
}

/* Nav items — tighter for compact header */
html header.main-header .nav-holder {
    top: 8px !important;
    display: flex !important;
    align-items: center !important;
    height: 100% !important;
}
html header.main-header .nav-holder nav > ul > li > a {
    padding-top: 4px !important;
    padding-bottom: 4px !important;
    font-size: 13px !important;
    line-height: 1.4 !important;
}

/* Sticky-shrunk header */
html header.main-header.aj-sticky-header.aj-shrunk {
    height: 52px !important;
    min-height: 0 !important;
    padding-block: 0 !important;
}
html header.main-header.aj-sticky-header.aj-shrunk .logo-holder img {
    height: 48px !important;
    max-height: 48px !important;
    margin-top: 0 !important;
    margin-bottom: -6px !important;
    transform: none !important;
    transform-origin: center center;
}

@media (max-width: 991px) {
    html header.main-header {
        height: 54px !important;
        min-height: 0 !important;
        padding-block: 0 !important;
    }
    html header.main-header .logo-holder a {
        width: auto !important;
        height: auto !important;
        padding: 0 !important;
        background: transparent !important;
        box-shadow: none !important;
        border-radius: 0 !important;
    }
    html header.main-header .logo-holder img {
        height: 60px !important;
        max-height: 60px !important;
        max-width: none !important;
        margin-top: 0 !important;
        margin-bottom: -10px !important;
    }
}

@media (max-width: 600px) {
    html header.main-header {
        height: 48px !important;
        min-height: 0 !important;
        padding-block: 0 !important;
    }
    html header.main-header .logo-holder img {
        height: 48px !important;
        max-height: 48px !important;
        max-width: none !important;
        padding: 0 !important;
        margin-top: 0 !important;
        margin-bottom: -4px !important;
    }
}

/* -- 12. Icon-only outline pill: Login + Favorites unified --------------
   Both the login (`.show-reg-form a`) and favorites (`.cart-btn`) buttons
   are 36x36 outline circles that show only an icon. The shared marker
   class `.aj-header-actions__icon-btn` raises specificity so the desktop
   text-pill rules in section 5 are flattened to a square circle for the
   login trigger as well. The favorites button additionally renders a
   numeric badge in its top inline-end corner via `.aj-header-actions__badge`
   when the count is greater than zero (the conditional is in Razor). */
header.main-header .aj-header-actions .show-reg-form,
header.main-header .aj-header-actions .show-reg-form .aj-header-actions__icon-btn {
    width: var(--aj-action-h);
    min-width: var(--aj-action-h);
}
header.main-header .aj-header-actions .show-reg-form .aj-header-actions__icon-btn {
    padding: 0 !important;
    gap: 0 !important;
    justify-content: center;
}
header.main-header .aj-header-actions .show-reg-form .aj-header-actions__icon-btn span {
    display: none !important;
}
header.main-header .aj-header-actions a.cart-btn.aj-header-actions__icon-btn,
header.main-header .aj-header-actions a.cart-btn.aj-header-actions__icon-btn:hover,
header.main-header .aj-header-actions a.cart-btn.aj-header-actions__icon-btn:focus-visible {
    text-decoration: none !important;
}
header.main-header .aj-header-actions .cart-btn .aj-header-actions__badge {
    position: absolute;
    top: -4px;
    inset-inline-end: -4px;
    inset-inline-start: auto;
    min-width: 18px;
    height: 18px;
    padding: 0 4px;
    line-height: 14px;
    font-size: 10px;
    font-weight: 700;
    color: #ffffff;
    background: var(--aj-primary, #b7cd27);
    border-radius: 9px;
    border: 2px solid #ffffff;
    text-align: center;
    box-sizing: content-box;
    pointer-events: none;
}
html[dir="rtl"] header.main-header .aj-header-actions .cart-btn .aj-header-actions__badge {
    inset-inline-end: -4px;
    inset-inline-start: auto;
}
body.aj-dark header.main-header .aj-header-actions .cart-btn .aj-header-actions__badge {
    border-color: #0f172a;
}

/* -- 13. CLUSTER GROUPING -------------------------------------------------
   Sub-grouping the four cluster items into perceptual chunks:
     [ User . Star ]   |   Language   |   Add Property
   The User+Star pair (icon-only "me" circles) sits tighter together; the
   Language pill gets a small extra inline-start margin; a thin vertical
   divider separates Language from the primary CTA so the green Add Property
   button reads as a distinct call-to-action. The cluster baseline gap is
   8px (already set in section 2). DOM order is the source of truth for
   both LTR and RTL — section 9 pins the cluster to the inline-end edge,
   while this section governs only intra-cluster spacing and is therefore
   direction-agnostic via logical properties. */
header.main-header .aj-header-actions > .show-reg-form + .cart-btn {
    margin-inline-start: -3px;
}
header.main-header .aj-header-actions > .cart-btn + .aj-lang-toggle {
    margin-inline-start: 2px;
}
header.main-header .aj-header-actions .aj-header-actions__sep {
    align-self: center;
    width: 1px;
    height: 18px;
    background: var(--aj-border, #d1d5db);
    opacity: 0.5;
    margin-inline: 2px 4px;
    flex-shrink: 0;
}
body.aj-dark header.main-header .aj-header-actions .aj-header-actions__sep {
    background: var(--aj-border, rgba(148, 163, 184, 0.20));
}

@media (max-width: 991px) {
    header.main-header .aj-header-actions .aj-header-actions__sep {
        margin-inline: 2px 4px;
        height: 20px;
    }
}

@media (max-width: 600px) {
    header.main-header .aj-header-actions .aj-header-actions__sep {
        display: none;
    }
}

/* -- 14. HEADER LOGO — disable hover ---------------------------------------
   Neutralize the logo hover/focus effect so the main-header logo is visually
   static. Earlier rules (sections 11 + a legacy enhancement layer) animate
   transform/filter on .logo-holder a:hover img; the rules below win on
   specificity (html-prefixed) and override the !important transforms. The
   static drop-shadow filter, sizing and RTL inset defined in section 11
   remain untouched. */
html header.main-header .logo-holder a:hover img,
html header.main-header .logo-holder a:focus img,
html header.main-header .logo-holder img:hover,
html header.main-header .logo-holder img:focus {
    transform: none !important;
    scale: none !important;
    opacity: 1 !important;
    filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.15)) !important;
    box-shadow: none !important;
    transition: none !important;
}
html header.main-header .logo-holder a:hover,
html header.main-header .logo-holder a:focus {
    text-decoration: none !important;
    outline: none !important;
}
/* ============================================================================
   15. HEADER SEARCH — expanding icon -> input
   ============================================================================ */

header.main-header .aj-header-actions .aj-header-search.aj-header-search--open {
    width: clamp(220px, 30vw, 320px);
    background: #ffffff;
    border-color: var(--aj-border, #e5e7eb);
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08);
}
header.main-header .aj-header-actions .aj-header-search__input {
    flex: 1 1 auto;
    min-width: 0;
    height: 100%;
    padding-inline: 14px;
    border: 0;
    outline: 0;
    background: transparent;
    color: var(--aj-text, #1f2937);
    font-size: 14px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 250ms ease 50ms;
}
header.main-header .aj-header-actions .aj-header-search.aj-header-search--open .aj-header-search__input {
    opacity: 1;
    pointer-events: auto;
}
header.main-header .aj-header-actions .aj-header-search__input::placeholder {
    color: var(--aj-text-muted, #878c9f);
    opacity: 1;
}
header.main-header .aj-header-actions .aj-header-search__toggle {
    flex: 0 0 var(--aj-action-h);
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    width: var(--aj-action-h);
    min-width: var(--aj-action-h);
    height: var(--aj-action-h);
    padding: 0 !important;
    border: 1px solid var(--aj-border, #e5e7eb) !important;
    border-radius: var(--aj-action-radius) !important;
    background: transparent !important;
    color: var(--aj-text, #1f2937) !important;
    cursor: pointer;
    transition: background var(--aj-transition, 280ms ease),
                border-color var(--aj-transition, 280ms ease),
                color var(--aj-transition, 280ms ease);
}
header.main-header .aj-header-actions .aj-header-search.aj-header-search--open .aj-header-search__toggle {
    border-color: transparent !important;
    color: var(--aj-primary-dark, #a7bd1b) !important;
}
header.main-header .aj-header-actions .aj-header-search__toggle:hover,
header.main-header .aj-header-actions .aj-header-search__toggle:focus-visible {
    background: var(--aj-primary-soft, rgba(183, 205, 39, 0.12)) !important;
    border-color: var(--aj-primary, #b7cd27) !important;
    color: var(--aj-primary-dark, #a7bd1b) !important;
}
header.main-header .aj-header-actions .aj-header-search__toggle i {
    font-size: var(--aj-action-icon);
    line-height: 1;
    color: inherit;
    margin: 0 !important;
}
header.main-header .aj-header-actions .aj-header-search__icon-close { display: none; }
header.main-header .aj-header-actions .aj-header-search.aj-header-search--open .aj-header-search__icon-search { display: none; }
header.main-header .aj-header-actions .aj-header-search.aj-header-search--open .aj-header-search__icon-close { display: inline-block; }

body.aj-dark header.main-header .aj-header-actions .aj-header-search.aj-header-search--open {
    background: #0f172a;
    border-color: var(--aj-border, #334155);
}
body.aj-dark header.main-header .aj-header-actions .aj-header-search__input {
    color: var(--aj-text, #e5e7eb);
}

@media (max-width: 991px) {
    header.main-header .aj-header-actions .aj-header-search { width: var(--aj-action-h); height: var(--aj-action-h); }
    header.main-header .aj-header-actions .aj-header-search.aj-header-search--open { width: clamp(200px, 40vw, 260px); }
}

@media (max-width: 600px) {
    header.main-header .aj-header-actions .aj-header-search { width: var(--aj-action-h); height: var(--aj-action-h); }
    header.main-header .aj-header-actions .aj-header-search.aj-header-search--open { width: clamp(180px, 60vw, 240px); }
}

/* -- 16. Creative clear brand mark in menu ---------------------------------
   Live-ready treatment: cleaner glass card, stronger contrast, subtle halo. */
html body header.main-header .logo-holder {
    padding-inline: 8px !important;
}
html body header.main-header .logo-holder .aj-logo-card {
    position: relative;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    padding: 5px 10px !important;
    border-radius: 14px !important;
    background: linear-gradient(145deg, rgba(255,255,255,0.95), rgba(245,248,255,0.92)) !important;
    border: 1px solid rgba(183,205,39,0.35) !important;
    box-shadow: 0 8px 22px rgba(15,23,42,0.14), 0 2px 8px rgba(183,205,39,0.22) !important;
    overflow: visible !important;
}
html body header.main-header .logo-holder .aj-logo-card::before {
    content: "";
    position: absolute;
    inset: -2px;
    border-radius: 16px;
    background: linear-gradient(120deg, rgba(183,205,39,0.3), rgba(20,66,115,0.25), rgba(183,205,39,0.22));
    opacity: 0.55;
    z-index: -1;
}
html body header.main-header .logo-holder .aj-logo-card a {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
}
html body header.main-header .logo-holder .aj-logo-card img {
    height: 74px !important;
    max-height: 74px !important;
    width: auto !important;
    max-width: none !important;
    margin: 0 !important;
    filter: saturate(1.08) contrast(1.08) drop-shadow(0 5px 14px rgba(0,0,0,0.18)) !important;
}
body.aj-dark html header.main-header .logo-holder .aj-logo-card,
body.aj-dark header.main-header .logo-holder .aj-logo-card {
    background: linear-gradient(145deg, rgba(30,41,59,0.95), rgba(15,23,42,0.92)) !important;
    border-color: rgba(183,205,39,0.45) !important;
}
@media (max-width: 991px) {
    html body header.main-header .logo-holder .aj-logo-card {
        padding: 4px 8px !important;
        border-radius: 12px !important;
    }
    html body header.main-header .logo-holder .aj-logo-card img {
        height: 52px !important;
        max-height: 52px !important;
    }
}
@media (max-width: 600px) {
    html body header.main-header .logo-holder .aj-logo-card {
        padding: 3px 6px !important;
        border-radius: 10px !important;
    }
    html body header.main-header .logo-holder .aj-logo-card img {
        height: 42px !important;
        max-height: 42px !important;
    }
}
