/*
 * EKY New — chrome.css (v2.3.84, K2 Phase 2)
 *
 * Shared chrome (top-bar, main-header, logo, nav, site-footer,
 * scroll-to-top) for the Modern renderer. Loaded ONLY when a
 * singular `personal`/`expertise` post has opted in via the
 * `ekynew_modern` meta flag — see enqueue.php for the gate.
 *
 * Relationship with legacy template-parts:
 *   - 28 legacy template-parts embed the same chrome markup AND an
 *     inline <style> block with these rules. That duplication is
 *     intentional legacy debt; migration is gradual.
 *   - This file is used exclusively by pages on the Modern path, so
 *     on any given render EXACTLY ONE source of chrome CSS is live.
 *     There is no selector collision risk — the two paths never
 *     co-execute.
 *
 * Why colour literals instead of CSS custom properties:
 *   The legacy `--black`, `--teal` etc. tokens are declared at :root
 *   *inside* each legacy template-part's inline <style>. On Modern
 *   pages, those :root tokens never get emitted (the modern template
 *   does not embed the legacy <style> block), so the same var()
 *   references would resolve to `unset`. Inlining the palette keeps
 *   chrome.css self-contained and eliminates a whole class of
 *   cascade gotchas.
 *
 * When the legacy inline chrome is finally centralised (Phase 3):
 *   delete the inline `<style>` copies from each team+expertise
 *   template-part, remove the "no selector collision" clause above,
 *   and drop the conditional enqueue gate (load unconditionally).
 *   Until then, every rule here is scoped to chrome only — nothing
 *   touches the post content or sidebars.
 */

/* ── BILINGUAL VISIBILITY ─────────────────────────────────────── */
.he-content { display: inline; }
.en-content { display: none; }
body.lang-en .he-content { display: none; }
body.lang-en .en-content { display: inline; }

/* ── BODY DEFAULTS (modern path only) ─────────────────────────── */
body {
    font-family: 'Heebo', 'Assistant', Arial, sans-serif;
    color: #1a1a1a;
    line-height: 1.7;
    background: #fff;
    font-size: 16px;
    direction: rtl;
}
body.lang-en {
    direction: ltr;
    font-family: 'Assistant', 'Heebo', Arial, sans-serif;
}
html { scroll-behavior: smooth; }

/* ── .container (shared width constraint) ─────────────────────── */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 40px;
}

/* ── TOP BAR ──────────────────────────────────────────────────── */
.top-bar {
    background: #000;
    padding: 8px 0;
    font-size: 13px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}
.top-bar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.top-bar-right {
    display: flex;
    align-items: center;
    gap: 18px;
    color: rgba(255,255,255,0.6);
}
.top-bar-right a {
    color: rgba(255,255,255,0.6);
    text-decoration: none;
    transition: all .3s ease;
    display: flex;
    align-items: center;
    gap: 6px;
}
.top-bar-right a:hover { color: #486088; }
.top-bar-right .divider { color: rgba(255,255,255,0.2); }
.top-bar-left {
    display: flex;
    align-items: center;
    gap: 15px;
}
.top-bar-left a {
    color: rgba(255,255,255,0.5);
    text-decoration: none;
    font-size: 14px;
    transition: all .3s ease;
}
.top-bar-left a:hover { color: #486088; }

/* ── LANGUAGE TOGGLE BUTTON ───────────────────────────────────── */
.lang-btn {
    background: transparent;
    border: 1px solid rgba(255,255,255,0.25);
    color: rgba(255,255,255,0.7);
    padding: 3px 12px;
    border-radius: 3px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.5px;
    transition: all .3s ease;
    font-family: 'Assistant', 'Heebo', Arial, sans-serif;
}
.lang-btn:hover {
    background: rgba(255,255,255,0.1);
    border-color: #486088;
    color: #fff;
}

/* ── MAIN HEADER ──────────────────────────────────────────────── */
.main-header {
    background: #000;
    height: 75px;
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: box-shadow .3s ease;
}
.main-header.scrolled {
    box-shadow: 0 2px 20px rgba(0,0,0,0.3);
}
.main-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
}
/* v2.3.120 — Logo row rewrite.
 *
 * Layout switched from a 2-column (EKY | stacked names) box to a flat 3-item
 * inline row: EKY · separator · firm name. In RTL flex-row the first child
 * sits on the visual right, so EKY appears first, then the dash, then the
 * Hebrew firm name on the left. Subtitle ("משרד עורכי דין") removed.
 *
 * The old .logo-names / .logo-kind selectors are intentionally dropped here;
 * they are no longer emitted by main-header.php.
 */
.logo { display: flex; flex-direction: column; align-items: flex-start; }
.logo, .logo-text {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    min-width: 0;
}
.logo-main {
    font-size: 22px;
    font-weight: 800;
    color: #fff;
    letter-spacing: 4px;
    font-family: 'Assistant', 'Heebo', Arial, sans-serif;
    line-height: 1.1;
    flex-shrink: 0;
}
.logo-sep {
    font-size: 22px;
    line-height: 1.1;
    color: #486088;
    font-weight: 700;
    flex-shrink: 0;
    user-select: none;
}
.logo-firm {
    font-size: 14px;
    color: #fff;
    font-weight: 700;
    white-space: nowrap;
    font-family: 'Heebo', 'Assistant', Arial, sans-serif;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.2;
}
body.lang-en .logo-firm {
    font-family: 'Assistant', 'Heebo', Arial, sans-serif;
    letter-spacing: .01em;
}

/* ── MAIN NAV ─────────────────────────────────────────────────── */
.main-nav {
    display: flex;
    align-items: center;
    gap: 35px;
    flex-shrink: 0;
}
.main-nav a {
    color: #fff;
    font-size: 15px;
    font-weight: 500;
    text-decoration: none;
    position: relative;
    z-index: 2;
    pointer-events: auto;
    transition: all .3s ease;
    padding: 8px 0;
}
.main-nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 0;
    height: 2px;
    background: #486088;
    transition: width .3s ease;
}
body.lang-en .main-nav a::after {
    right: auto;
    left: 0;
}
.main-nav a:hover { color: #486088; }
.main-nav a:hover::after { width: 100%; }
.main-nav a.active { color: #486088; }
.main-nav a.active::after { width: 100%; }

/* ── SITE FOOTER ──────────────────────────────────────────────── */
.site-footer {
    background: #000;
    padding: 30px 0;
    border-top: 1px solid rgba(255,255,255,0.08);
}
.site-footer .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.footer-text {
    font-size: 13px;
    color: rgba(255,255,255,0.4);
}
.footer-links {
    display: flex;
    gap: 25px;
}
.footer-links a {
    font-size: 13px;
    color: rgba(255,255,255,0.4);
    text-decoration: none;
    transition: all .3s ease;
}
.footer-links a:hover { color: #486088; }

/* ── SCROLL TO TOP ────────────────────────────────────────────── */
.scroll-top {
    position: fixed;
    bottom: 30px;
    left: 30px;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: #000;
    border: 2px solid rgba(255,255,255,0.3);
    color: #fff;
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    pointer-events: none;
    transition: all .3s ease;
    z-index: 999;
}
.scroll-top.visible {
    opacity: 1;
    pointer-events: auto;
}
.scroll-top:hover {
    background: #486088;
    border-color: #486088;
}

/* ── RESPONSIVE ───────────────────────────────────────────────── */
@media (max-width: 1200px) {
    /* v2.3.120 — was .logo-names (now removed). On narrow viewports we
       drop the dash + Hebrew firm name and keep only "EKY" so the header
       stays tight. */
    .logo-sep, .logo-firm { display: none; }
}
@media (max-width: 768px) {
    .top-bar .container {
        flex-direction: column;
        gap: 8px;
        text-align: center;
    }
    .main-header { height: 60px; }
    .main-nav { gap: 18px; }
    .main-nav a { font-size: 13px; }
    .site-footer .container {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
    .container { padding: 0 20px; }
}
@media (max-width: 480px) {
    .top-bar { display: none; }
    .main-nav { gap: 12px; }
}

/* ── FOCUS VISIBLE (a11y baseline, K2 addition) ───────────────── */
.top-bar a:focus-visible,
.main-nav a:focus-visible,
.lang-btn:focus-visible,
.scroll-top:focus-visible,
.footer-links a:focus-visible {
    outline: 2px solid #486088;
    outline-offset: 2px;
    border-radius: 2px;
}

/* ── TAP TARGETS (v2.3.96 — WCAG 2.5.5 Level AAA / 2.5.8 Level AA) ──
 *
 * The v2026-04-24 round-2 audit flagged 12 interactive elements whose
 * rendered hit-area was smaller than 44 × 44 CSS pixels. Each rule
 * below bumps the minimum hit-area of a known-small control WITHOUT
 * changing its visual size — we use inline-flex centering so the
 * icon / label stays exactly where it was drawn, only the
 * transparent click catcher widens.
 *
 * We deliberately target only he *chrome* controls here; post-body
 * links inside long-form content (paragraph links, citations) are
 * exempt per WCAG 2.5.8 Exception #1 ("inline").
 *
 * Scope guard: every selector is prefixed with a chrome container
 * (.top-bar, .main-header, .site-footer, .scroll-top) so we cannot
 * accidentally widen content-area anchors.
 * ─────────────────────────────────────────────────────────────── */

/* Top bar phone / email / language buttons (small text-links, ~14px
 * tall before this rule). Use inline-flex so the widened box stays
 * on the same baseline as surrounding labels. */
.top-bar a,
.top-bar .lang-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    min-width: 44px;
    padding: 0 6px;
}

/* Main-nav links (desktop top menu). Height bumped to 44px via
 * vertical padding; horizontal flow is unchanged because they were
 * already 44px+ wide in practice. */
.main-header .main-nav a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding: 10px 4px;
}

/* Social icons in the footer — these were flagged at ~24 × 24. */
.site-footer .social-icons a,
.site-footer a[data-ekynew-social="1"] {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    min-height: 44px;
}

/* Footer text links — same reasoning as top-bar. */
.site-footer .footer-links a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding: 4px 6px;
}

/* Scroll-to-top button — already circular ~40px; lift to 44. */
.scroll-top {
    min-width: 44px;
    min-height: 44px;
}
