/* === CSS Reset === */
html {
    font-size: 80%;  /* הקטנה גלובלית - 1rem = 12.8px */
}
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
    font-family: 'Heebo', sans-serif;
    background: var(--bg, #f8fafc);
    color: var(--text, #1e293b);
    min-height: 100vh;
}

/* === Accessibility - Skip Link === */
.skip-link {
    position: absolute;
    top: -100px;
    right: 0;
    background: var(--svivi-managers, #4285F4);
    color: #fff;
    padding: 12px 24px;
    z-index: 10000;
    font-weight: 600;
    border-radius: 0 0 0 8px;
    text-decoration: none;
    transition: top 0.2s ease;
}
.skip-link:focus {
    top: 0;
    outline: 2px solid #fff;
    outline-offset: 2px;
}

/* === Accessibility - Focus Visible === */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
    outline: 2px solid var(--svivi-managers, #4285F4);
    outline-offset: 2px;
}

/* === Accessibility - Visually Hidden (for screen readers) === */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* ============================================
   Svivi Design Tokens — v1.0
   סטנדרט עיצובי אחיד לכל הדפים
   ============================================ */
:root {
    /* === Colors — Brand === */
    --svivi-managers: #4285F4;
    --svivi-managers-light: #5E9DF5;
    --svivi-managers-glow: rgba(66, 133, 244, 0.2);

    --svivi-citizens: #34A853;
    --svivi-citizens-light: #4EBF6A;
    --svivi-citizens-glow: rgba(52, 168, 83, 0.2);

    --svivi-council: #D64B7A;
    --svivi-council-light: #E066A3;
    --svivi-council-glow: rgba(214, 75, 122, 0.2);

    --svivi-accent: #D98A2E;
    --svivi-accent-dark: #BD7522;

    /* === Colors — Neutral === */
    --svivi-bg: #f8fafc;
    --svivi-bg-card: #ffffff;
    --svivi-text: #1e293b;
    --svivi-text-secondary: #64748b;
    --svivi-text-light: #94a3b8;
    --svivi-border: #e2e8f0;
    --svivi-border-light: #f1f5f9;

    /* === Border Radius — סטנדרטי === */
    --radius-xs: 4px;
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --radius-2xl: 24px;
    --radius-full: 9999px;

    /* === Shadows — סטנדרטי === */
    --shadow-xs: 0 1px 2px rgba(0,0,0,0.05);
    --shadow-sm: 0 2px 8px rgba(0,0,0,0.06);
    --shadow-md: 0 4px 16px rgba(0,0,0,0.08);
    --shadow-lg: 0 8px 30px rgba(0,0,0,0.1);
    --shadow-xl: 0 16px 50px rgba(0,0,0,0.12);

    /* === Button Padding — סטנדרטי === */
    --btn-pad-xs: 4px 8px;
    --btn-pad-sm: 6px 12px;
    --btn-pad-md: 10px 18px;
    --btn-pad-lg: 14px 24px;
    --btn-pad-xl: 16px 32px;

    /* === Spacing === */
    --space-xs: 4px;
    --space-sm: 8px;
    --space-md: 16px;
    --space-lg: 24px;
    --space-xl: 32px;
    --space-2xl: 48px;

    /* === Typography === */
    --font-size-xs: 0.75rem;
    --font-size-sm: 0.85rem;
    --font-size-md: 1rem;
    --font-size-lg: 1.15rem;
    --font-size-xl: 1.5rem;
    --font-size-2xl: 2rem;

    /* === Transitions === */
    --transition-fast: 0.15s ease;
    --transition-normal: 0.25s ease;
    --transition-slow: 0.4s ease;
}

/* === Svivi PoC Banner === */
.svivi-poc-banner {
    background: linear-gradient(135deg, #fdf2f8 0%, #fce7f3 100%);
    border-bottom: 1px solid #f9a8d4;
    padding: 0.5rem 1.5rem;
    text-align: center;
    font-size: 0.78rem;
    color: #9f1239;
    font-family: 'Heebo', 'Arial', sans-serif;
    direction: rtl;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    z-index: 1000;
}
.svivi-poc-banner a {
    color: #9f1239;
    font-weight: 600;
    text-decoration: underline;
}

/* === Svivi Unified Navigation === */
.svivi-nav {
    padding: 12px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 12px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

/* Theme colors */
.svivi-nav[data-theme="managers"] {
    background: linear-gradient(135deg, #3570D4 0%, #4285F4 100%);
}
.svivi-nav[data-theme="council"] {
    background: linear-gradient(135deg, #AB3C62 0%, #D64B7A 100%);
}
.svivi-nav[data-theme="citizens"] {
    background: linear-gradient(135deg, #2A8642 0%, #34A853 100%);
}
.svivi-nav[data-theme="neutral"] {
    background: linear-gradient(135deg, #1e293b 0%, #334155 100%);
}

.svn-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    color: white;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.2rem;
    font-family: 'Rubik', 'Heebo', sans-serif;
}
.svn-logo-icon {
    font-size: 1.5rem;
}
.svn-logo-img {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    object-fit: cover;
}

.svn-links {
    display: flex;
    gap: 8px;
}
.svn-links a {
    display: flex;
    align-items: center;
    padding: 6px 14px;
    border-radius: 20px;
    background: rgba(255,255,255,0.12);
    color: rgba(255,255,255,0.75);
    text-decoration: none;
    font-size: 0.82rem;
    font-weight: 500;
    font-family: 'Heebo', sans-serif;
    transition: background 0.2s, color 0.2s;
    white-space: nowrap;
}
.svn-links a:hover {
    background: rgba(255,255,255,0.22);
    color: white;
}
.svn-links a.svn-active {
    background: rgba(255,255,255,0.25);
    color: white;
    font-weight: 600;
    box-shadow: 0 0 0 1px rgba(255,255,255,0.3);
}

/* === Left group (search buttons + home) === */
.svn-left-group {
    display: flex;
    align-items: center;
    gap: 8px;
}
.svn-search-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 20px;
    background: rgba(255,255,255,0.12);
    color: rgba(255,255,255,0.75);
    text-decoration: none;
    font-size: 0.82rem;
    font-weight: 500;
    font-family: 'Heebo', sans-serif;
    transition: background 0.2s, color 0.2s;
    white-space: nowrap;
}
.svn-search-btn .material-symbols-outlined {
    font-size: 1rem;
}
.svn-search-btn:hover {
    background: rgba(255,255,255,0.22);
    color: white;
}
.svn-search-btn.svn-search-active {
    background: rgba(255,255,255,0.25);
    color: white;
    font-weight: 600;
    box-shadow: 0 0 0 1px rgba(255,255,255,0.3);
}

/* === Dashboard Buttons === */
.svn-right-group {
    display: flex;
    align-items: center;
    gap: 20px;
}
.svn-dashboards {
    display: flex;
    gap: 8px;
}
.svn-dash-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 20px;
    background: rgba(255,255,255,0.12);
    color: rgba(255,255,255,0.75);
    text-decoration: none;
    font-size: 0.82rem;
    font-weight: 500;
    font-family: 'Heebo', sans-serif;
    transition: background 0.2s, color 0.2s;
    white-space: nowrap;
}
.svn-dash-btn .material-symbols-outlined {
    font-size: 1rem;
    font-variation-settings: 'FILL' 1, 'wght' 400;
}
.svn-dash-btn:hover {
    background: rgba(255,255,255,0.22);
    color: white;
}
.svn-dash-btn.svn-dash-active {
    background: rgba(255,255,255,0.25);
    color: white;
    font-weight: 600;
    box-shadow: 0 0 0 1px rgba(255,255,255,0.3);
}
.svivi-nav[data-theme="managers"] .svn-dash-managers.svn-dash-active {
    background: rgba(255,255,255,0.3);
}
.svivi-nav[data-theme="citizens"] .svn-dash-citizens.svn-dash-active {
    background: rgba(255,255,255,0.3);
}

@media (max-width: 768px) {
    .svivi-nav {
        padding: 10px 15px;
        flex-wrap: wrap;
        gap: 8px;
    }
    .svn-right-group {
        gap: 12px;
    }
    .svn-dashboards {
        gap: 4px;
    }
    .svn-dash-btn {
        padding: 5px 10px;
        font-size: 0.75rem;
    }
    .svn-dash-btn .material-symbols-outlined {
        font-size: 0.9rem;
    }
    .svn-links {
        order: 3;
        width: 100%;
        justify-content: center;
        gap: 12px;
        padding-top: 8px;
        border-top: 1px solid rgba(255,255,255,0.15);
        flex-wrap: wrap;
    }
    .svn-left-group {
        gap: 4px;
    }
    .svn-search-btn {
        padding: 5px 10px;
        font-size: 0.75rem;
    }
    .svn-search-btn .material-symbols-outlined {
        font-size: 0.9rem;
    }
}

/* === Mobile Small (480px) === */
@media (max-width: 480px) {
    .svivi-nav {
        padding: 8px 10px;
    }
    .svn-logo {
        font-size: 1rem;
        gap: 6px;
    }
    .svn-logo-icon {
        font-size: 1.2rem;
    }
    .svn-dash-btn span:not(.material-symbols-outlined) {
        display: none;
    }
    .svn-dash-btn {
        padding: 6px 8px;
    }
    .svn-search-btn span:not(.material-symbols-outlined) {
        display: none;
    }
    .svn-search-btn {
        padding: 6px 8px;
    }
    .svn-links {
        gap: 8px;
        font-size: 0.8rem;
    }
    .svn-links a {
        font-size: 0.8rem;
    }
    .svivi-poc-banner {
        padding: 0.4rem 0.75rem;
        font-size: 0.7rem;
    }
    .svivi-legal-footer {
        padding: 1rem 1rem 0.75rem;
    }
    .svivi-footer-disclaimer {
        padding: 0.75rem 1rem;
        font-size: 0.75rem;
    }
    .svivi-footer-meta {
        flex-direction: column;
        text-align: center;
        font-size: 0.75rem;
    }
}

/* === Svivi Legal Footer === */
.svivi-legal-footer {
    background: #f8fafc;
    border-top: 2px solid #e2e8f0;
    padding: 1.5rem 2rem 1rem;
    margin-top: 3rem;
    font-family: 'Heebo', 'Arial', sans-serif;
    direction: rtl;
}
.svivi-footer-inner {
    max-width: 900px;
    margin: 0 auto;
}
.svivi-footer-disclaimer {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 1rem 1.25rem;
    margin-bottom: 1rem;
    font-size: 0.8rem;
    line-height: 1.7;
    color: #64748b;
}
.svivi-footer-disclaimer strong {
    color: #475569;
}
.svivi-footer-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.75rem;
    font-size: 0.8rem;
    color: #94a3b8;
    padding: 0 0.25rem;
}
.svivi-footer-meta a {
    color: #64748b;
    text-decoration: none;
    transition: color 0.2s;
}
.svivi-footer-meta a:hover {
    color: #4285F4;
}
.svivi-footer-brand {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-weight: 600;
    color: #64748b;
}
