/**
 * תפריט מלא (MENU) מתחת ל־ORA RUVEN — פאנל עם כל הדפים
 */
/* מניעת קפיצות גלילה כש־ensureBrandStack עוטף את .brand — scroll anchoring */
html {
    overflow-anchor: none;
    scrollbar-gutter: stable;
}

.site-brand-stack {
    position: fixed;
    top: max(14px, env(safe-area-inset-top, 0px));
    left: max(18px, env(safe-area-inset-left, 0px));
    right: auto;
    z-index: 10050;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    pointer-events: auto;
    max-width: min(92vw, 280px);
    text-align: left; /* כמו דפי LTR — פינה שמאלית-עליונה גם ב־html[dir=rtl] */
}

/* ב־RTL פס הגלילה האנכי לעיתים בצד שמאל — מרחק קטן כדי שלא יכסה את המותג */
html[dir="rtl"] .site-brand-stack {
    left: max(36px, calc(20px + env(safe-area-inset-left, 0px)));
}

.site-brand-stack .brand {
    position: static !important;
    top: auto !important;
    left: auto !important;
    right: auto !important;
    margin: 0 !important;
    padding: 0 !important;
    pointer-events: none;
}
.site-brand-home {
    text-decoration: none;
    color: inherit;
    pointer-events: auto;
    display: inline-block;
    max-width: 100%;
}
.site-brand-home .brand {
    pointer-events: auto;
}

/* דף ניווט: המותג היה ללא אירועי עכבר — נשאר טקסט בלבד */
body.nav-page .site-brand-stack .brand {
    pointer-events: none;
}

/* Back to exhibitions (injected by exhibition-gallery.js) */
a.ex-back-exhibitions:any-link,
a.ex-back-exhibitions:visited {
    color: rgba(235, 235, 235, 0.72);
}
a.ex-back-exhibitions {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    margin: 0;
    padding: 0;
    font-size: 10.5px;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: rgba(235, 235, 235, 0.72);
    text-decoration: none;
    pointer-events: auto;
    transition: color 0.2s ease, opacity 0.2s ease;
}
a.ex-back-exhibitions:hover,
a.ex-back-exhibitions:focus-visible {
    color: #fff;
    outline: none;
}
.ex-back-exhibitions-arrow {
    font-size: 11px;
    line-height: 1;
    opacity: 0.75;
    transition: opacity 0.2s ease, transform 0.2s ease;
}
a.ex-back-exhibitions:hover .ex-back-exhibitions-arrow,
a.ex-back-exhibitions:focus-visible .ex-back-exhibitions-arrow {
    opacity: 1;
    transform: translateX(-2px);
}
.ex-back-exhibitions-label {
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s ease;
}
a.ex-back-exhibitions:hover .ex-back-exhibitions-label,
a.ex-back-exhibitions:focus-visible .ex-back-exhibitions-label {
    border-bottom-color: rgba(255, 255, 255, 0.35);
}

.site-full-menu-trigger {
    margin: 0;
    padding: 6px 14px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: #f0f0f0;
    background: rgba(0, 0, 0, 0.55);
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 999px;
    cursor: pointer;
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.site-full-menu-trigger:hover,
.site-full-menu-trigger:focus-visible {
    background: rgba(40, 40, 40, 0.85);
    border-color: rgba(255, 255, 255, 0.5);
    color: #fff;
    outline: none;
}

.site-full-menu-backdrop {
    position: fixed;
    inset: 0;
    z-index: 10090;
    background: rgba(0, 0, 0, 0.55);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.22s ease, visibility 0.22s ease;
}

.site-full-menu-backdrop.is-open {
    opacity: 1;
    visibility: visible;
}

.site-full-menu {
    box-sizing: border-box;
    position: fixed;
    z-index: 100100;
    top: 0;
    right: 0;
    bottom: 0;
    width: min(440px, 100vw);
    max-width: 100%;
    margin: 0;
    padding: 0;
    background: rgba(14, 15, 18, 0.97);
    border-left: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: -12px 0 40px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transform: translateX(100%);
    transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}

.site-full-menu.is-open {
    transform: translateX(0);
}

.site-full-menu__head {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: calc(14px + env(safe-area-inset-top, 0px)) 16px 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.site-full-menu__title {
    margin: 0;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #eaeaea;
}

.site-full-menu__close {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    margin: 0;
    padding: 0;
    border: none;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.08);
    color: #eee;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
}

.site-full-menu__close:hover {
    background: rgba(255, 255, 255, 0.16);
}

.site-full-menu__scroll {
    flex: 1 1 auto;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: 10px 14px calc(28px + env(safe-area-inset-bottom, 0px));
}

.site-full-menu details {
    margin: 0 0 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.03);
    overflow: hidden;
}

.site-full-menu summary {
    list-style: none;
    cursor: pointer;
    padding: 11px 12px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #cfd5de;
}

.site-full-menu summary::-webkit-details-marker {
    display: none;
}

.site-full-menu summary::after {
    content: "+";
    float: right;
    opacity: 0.55;
    font-weight: 400;
}

html[dir="rtl"] .site-full-menu summary::after {
    float: left;
}

.site-full-menu details[open] summary::after {
    content: "−";
}

.site-full-menu .site-full-menu__links {
    margin: 0;
    padding: 0 10px 12px 12px;
    list-style: none;
}

/* פריטים עליונים בלי קטגוריה — רק רשימת קישורים, בלי כותרת כפולה */
.site-full-menu ul.site-full-menu__links--flat {
    margin: 0 0 10px;
    padding: 2px 6px 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.site-full-menu ul.site-full-menu__links--flat li {
    margin: 0 0 4px;
}

.site-full-menu ul.site-full-menu__links--flat li:last-child {
    margin-bottom: 0;
}

.site-full-menu ul.site-full-menu__links--flat .site-full-menu__link-sub {
    margin-top: 1px;
}

.site-full-menu ul.site-full-menu__links--flat a {
    padding: 5px 8px;
}

.site-full-menu .site-full-menu__links li {
    margin: 0 0 2px;
}

.site-full-menu .site-full-menu__links a {
    display: block;
    padding: 8px 8px;
    font-size: 13px;
    line-height: 1.35;
    color: #d5d5d5;
    text-decoration: none;
    border-radius: 6px;
}

.site-full-menu .site-full-menu__links a:hover,
.site-full-menu .site-full-menu__links a:focus-visible {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    outline: none;
}

.site-full-menu .site-full-menu__link-sub {
    display: block;
    font-size: 11px;
    color: #7a8088;
    margin-top: 2px;
}

body.site-full-menu-open {
    overflow: hidden;
}

@media (min-width: 900px) {
    .site-full-menu {
        width: min(480px, 42vw);
    }
}

/* קישור MENU (נייד / מצר דפדפן — ניווט לדף התפריט, בלי Overlay) */
a.site-full-menu-trigger.site-full-menu-trigger--href {
    text-decoration: none;
    display: inline-block;
    text-align: center;
    box-sizing: border-box;
}

/* דף תפריט עצמאי — אותן יחידות התפריט, ללא משטח צף ותפיסת viewport */
.site-full-menu.site-full-menu--page {
    position: relative;
    z-index: auto;
    top: auto;
    right: auto;
    bottom: auto;
    left: auto;
    width: 100%;
    max-width: min(560px, 100%);
    margin: 0 auto;
    transform: none;
    box-shadow: 0 8px 42px rgba(0, 0, 0, 0.4);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    overflow: visible;
}

.site-full-menu.site-full-menu--page .site-full-menu__scroll {
    overflow: visible;
    -webkit-overflow-scrolling: touch;
    flex: 0 1 auto;
    max-height: none;
}

body.site-menu-page-body #siteFullMenuPageMount {
    margin-top: 0.75rem;
}

/* כפתור MENU בנייד — בשורה עם המותג ב־.site-brand-stack */
@media (max-width: 1100px) {
    /* RTL היה הופך סדר flex — נעצרים ב־LTR כדי ש־ORA תמיד משמאל ו־MENU מימין */
    .site-brand-stack:has(> a.mobile-top-menu-btn) {
        direction: ltr;
        unicode-bidi: isolate;
        text-align: left;
        flex-direction: row;
        flex-wrap: nowrap;
        align-items: center;
        justify-content: space-between;
        align-content: flex-start;
        gap: 10px;
        /* left+right (לא 100vw) — מונע חיתוך «MENU»→«MEN» בגלל פס גלילה */
        left: max(12px, env(safe-area-inset-left, 0px));
        right: max(14px, env(safe-area-inset-right, 0px));
        width: auto;
        max-width: none;
        box-sizing: border-box;
    }
    html[dir="rtl"] .site-brand-stack:has(> a.mobile-top-menu-btn) {
        left: max(12px, env(safe-area-inset-left, 0px));
        right: max(14px, env(safe-area-inset-right, 0px));
    }
    .site-brand-stack:has(> a.mobile-top-menu-btn) > .brand,
    .site-brand-stack:has(> a.mobile-top-menu-btn) > a.site-brand-home {
        flex: 1 1 auto;
        min-width: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        max-width: calc(100% - 112px);
    }
    .site-brand-stack:has(> a.mobile-top-menu-btn) > a.ex-back-exhibitions {
        flex: 1 1 100%;
        margin-top: 2px;
    }
    /* לא ליירש מ־body a:any-link (כחול־לבנדר) בדפים בלי mobile-home.css */
    a.mobile-top-menu-btn:any-link,
    a.mobile-top-menu-btn:visited {
        color: #f5f5f5 !important;
        text-decoration: none;
        text-decoration-color: transparent;
    }
    a.mobile-top-menu-btn:hover {
        color: #fff !important;
        text-decoration-color: transparent;
    }
    a.mobile-top-menu-btn:active {
        color: #fff !important;
    }
    a.mobile-top-menu-btn {
        pointer-events: auto;
        flex: 0 0 auto;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        box-sizing: border-box;
        white-space: nowrap;
        overflow: visible;
        min-height: 44px;
        min-width: 4.75rem;
        padding: 0 16px;
        margin: 0;
        font-size: 12px;
        font-weight: 700;
        letter-spacing: 0.14em;
        text-transform: uppercase;
        border: 1px solid rgba(255, 255, 255, 0.35);
        border-radius: 999px;
        background: rgba(0, 0, 0, 0.45);
    }
}
