/* ===== GLOBAL STYLES ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body { 
    font-family: 'Arial', sans-serif; 
    margin: 0;
    padding: 0;
    background-color: #f8f9fa;
    line-height: 1.6;
    color: #333;
}

.emoji {
    font-size: 1.5em;
}

/* ===== NAVIGATION STYLES ===== */
.navbar {
    background: linear-gradient(135deg, #2c3e50 0%, #000000 100%);
    box-shadow: 0 2px 10px rgba(0,0,0,0.3);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 3px solid #fff;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
    height: 70px;
}

.nav-brand .brand-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: white;
    font-size: 1.5em;
    font-weight: bold;
    transition: opacity 0.3s;
}

.nav-brand .brand-link:hover {
    opacity: 0.8;
    text-decoration: none;
    color: white;
}

.brand-icon {
    font-size: 1.8em;
    margin-right: 10px;
}

.brand-text {
    font-family: 'Arial', sans-serif;
    letter-spacing: 1px;
}
.nav-brand .brand-link .brand-text.brand-en {
    font-size: .6em !important;
    letter-spacing: .3px;
    white-space: nowrap !important;
    line-height: 1;
    word-break: keep-all;
    overflow: visible;
}
.social-icons {
    display: flex;
    gap: 10px;
}

.social-icons a {
    color: white;
    font-size: 20px;
    text-decoration: none;
    transition: color 0.3s ease;
}

.social-icons a:hover {
    color: #ff4081; /* optional hover effect */
}
.nav-menu {
    display: flex;
    list-style: none;
    gap: 0;
    flex-wrap: nowrap;
    align-items: center;
}

.nav-item {
    margin: 0;
    flex-shrink: 0;
}

.nav-link {
    display: flex;
    align-items: center;
    white-space: nowrap;
    padding: 15px 12px;
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    border-radius: 8px;
    margin: 0 2px;
}

.nav-link:hover {
    background-color: rgba(255, 255, 255, 0.2);
    color: white;
    text-decoration: none;
    transform: translateY(-2px);
}

.nav-link.active {
    background-color: rgba(255, 255, 255, 0.3);
    color: white;
    font-weight: bold;
}

.nav-icon {
    font-size: 1.2em;
    margin-right: 8px;
}

.nav-toggle {
    display: none;
    color: white;
    font-size: 1.5em;
    cursor: pointer;
    padding: 10px;
}

/* ===== MAIN CONTENT STYLES ===== */
.main-content {
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px;
}

/* ===== HERO/WELCOME SECTIONS ===== */
.hero-section, .welcome-section {
    background: linear-gradient(135deg, #2c3e50 0%, #000000 100%);
    color: white;
    text-align: center;
    padding: 60px 20px 40px 20px;
    border-radius: 15px;
    margin-bottom: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.hero-section h1, .welcome-section h1 {
    font-size: 3.5em;
    margin: 0 0 20px 0;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.hero-section p, .welcome-section p {
    font-size: 1.3em;
    margin: 0;
    opacity: 0.95;
    max-width: 600px;
    margin: 0 auto;
}

/* ===== CARD STYLES ===== */
.content-card {
    background: white;
    padding: 30px 40px;
    border-radius: 15px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
    margin-bottom: 20px;
}

.content-card:hover {
    transform: translateY(-5px);
}

.content-card h2 {
    color: #2c3e50;
    margin-bottom: 20px;
    font-size: 1.8em;
    border-bottom: 3px solid #000000;
    padding-bottom: 10px;
    display: block;
}

.content-card p {
    color: #555;
    font-size: 1.1em;
    margin-bottom: 15px;
}

html[dir="rtl"] .content-card h2,
html[dir="rtl"] .content-card p {
    text-align: right;
    direction: rtl;
}

html[dir="ltr"] .content-card h2,
html[dir="ltr"] .content-card p {
    text-align: left;
    direction: ltr;
    unicode-bidi: normal;
}

.content-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 40px;
}

.full-width-card {
    grid-column: 1 / -1;
}

/* ===== SKILLS SECTION ===== */
.skills-section {
    background: linear-gradient(135deg, #2c3e50, #000000);
    color: white;
    padding: 40px;
    border-radius: 15px;
    margin-bottom: 40px;
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

.skill-category {
    background: rgba(255, 255, 255, 0.1);
    padding: 25px;
    border-radius: 10px;
    backdrop-filter: blur(10px);
}

.skill-category h4 {
    margin: 0 0 15px 0;
    font-size: 1.3em;
    color: #fff;
}

.skill-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.skill-list li {
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.skill-list li:last-child {
    border-bottom: none;
}

.skill-level {
    background: rgba(255, 255, 255, 0.3);
    padding: 3px 10px;
    border-radius: 15px;
    font-size: 0.8em;
    font-weight: bold;
}

/* ===== TIMELINE STYLES ===== */
.timeline-section {
    background: white;
    padding: 40px;
    border-radius: 15px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    margin-bottom: 40px;
}

.timeline {
    position: relative;
    padding-left: 30px;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 15px;
    top: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(to bottom, #2c3e50, #000000);
}

.timeline-item {
    position: relative;
    margin-bottom: 30px;
    padding-left: 40px;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -8px;
    top: 0;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #2c3e50;
    border: 3px solid white;
    box-shadow: 0 0 0 3px #2c3e50;
}

.timeline-item.current::before {
    background: #000000;
    box-shadow: 0 0 0 3px #000000;
}

.timeline-date {
    color: #2c3e50;
    font-weight: bold;
    font-size: 0.9em;
    margin-bottom: 5px;
}

.timeline-title {
    color: #2c3e50;
    font-size: 1.3em;
    margin-bottom: 10px;
    font-weight: bold;
}

.timeline-description {
    color: #555;
    line-height: 1.6;
}

/* ===== CONTACT SECTION ===== */
.contact-section {
    background: linear-gradient(135deg, #2c3e50, #000000);
    color: white;
    padding: 40px;
    border-radius: 15px;
    text-align: center;
}

.contact-section h2 {
    margin-bottom: 20px;
    font-size: 2.2em;
}

.contact-info {
    display: flex;
    justify-content: center;
    gap: 40px;
    flex-wrap: wrap;
    margin-top: 30px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.1em;
}

/* ===== HIGHLIGHT STYLES ===== */
.highlight {
    background: linear-gradient(120deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 2px 6px;
    border-radius: 4px;
    color: #2c3e50;
    font-weight: bold;
    border: 1px solid #dee2e6;
}

/* ===== BUTTON STYLES ===== */
.btn { 
    background-color: #2c3e50; 
    color: white; 
    padding: 12px 30px; 
    border: none; 
    border-radius: 6px; 
    cursor: pointer; 
    font-size: 16px;
    margin-right: 10px;
    transition: background-color 0.3s;
    text-decoration: none;
    display: inline-block;
}

.btn:hover { 
    background-color: #000000;
    text-decoration: none;
    color: white;
}

.btn-secondary {
    background-color: #6c757d;
}

.btn-secondary:hover {
    background-color: #545b62;
}

/* ===== LINK STYLES ===== */
.back-link {
    text-decoration: none;
    color: #2c3e50;
    font-weight: bold;
}

.back-link:hover {
    text-decoration: underline;
    color: #000000;
}

/* ===== FORM STYLES ===== */
.form-group { 
    margin-bottom: 20px; 
}

label { 
    display: block; 
    margin-bottom: 8px; 
    font-weight: bold; 
    color: #555;
}

input[type="text"], textarea { 
    width: 100%; 
    padding: 12px; 
    border: 2px solid #ddd; 
    border-radius: 6px; 
    font-size: 16px;
    box-sizing: border-box;
}

input[type="text"]:focus, textarea:focus {
    border-color: #2c3e50;
    outline: none;
}

textarea { 
    height: 200px; 
    resize: vertical; 
    font-family: Arial, sans-serif;
}

/* ===== MESSAGE STYLES ===== */
.success-message {
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
    padding: 15px;
    border-radius: 6px;
    margin-bottom: 20px;
}

.error-message {
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
    padding: 15px;
    border-radius: 6px;
    margin-bottom: 20px;
}

/* ===== FOOTER STYLES ===== */
.site-footer {
    background: linear-gradient(135deg, #2c3e50 0%, #000000 100%);
    color: white;
    margin-top: 50px;
    padding: 40px 0 20px 0;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-bottom: 30px;
}

.footer-section h4 {
    color: #ffffff;
    margin-bottom: 15px;
    font-size: 1.1em;
    border-bottom: 2px solid #ffffff;
    padding-bottom: 5px;
    display: inline-block;
}
.footer-section h4.footer-brand-en {
    font-size: .95em;
    letter-spacing: .5px;
    white-space: nowrap;
}

.footer-section p {
    margin-bottom: 8px;
    color: #bdc3c7;
    line-height: 1.5;
}

.footer-links {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 8px;
}

.footer-links a {
    color: #ecf0f1;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: #ffffff;
    text-decoration: underline;
}

.progress-item {
    margin-bottom: 10px;
}

.progress-item span {
    display: block;
    margin-bottom: 5px;
    font-size: 0.9em;
    color: #bdc3c7;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background-color: #34495e;
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #ffffff, #bdc3c7);
    border-radius: 4px;
    transition: width 0.3s ease;
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #34495e;
    color: #95a5a6;
    font-size: 0.9em;
}

/* ===== MOBILE RESPONSIVE ===== */
@media (max-width: 768px) {
    .content-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .hero-section h1, .welcome-section h1 {
        font-size: 2.5em;
    }
    
    .hero-section, .welcome-section {
        padding: 50px 20px;
    }
    
    .content-card {
        padding: 25px;
    }
    
    .skills-section {
        padding: 25px;
    }
    
    .timeline-section {
        padding: 25px;
    }
    
    .contact-info {
        gap: 20px;
    }
    
    .main-content {
        padding: 20px 15px;
    }
    
    /* Mobile Navigation */
    .nav-menu {
        position: fixed;
        top: 70px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 70px);
        background: linear-gradient(135deg, #2c3e50 0%, #000000 100%);
        flex-direction: column;
        justify-content: flex-start;
        align-items: center;
        transition: left 0.3s ease;
        padding-top: 50px;
    }
    
    .nav-menu.active {
        left: 0;
    }
    
    .nav-link {
        padding: 20px;
        font-size: 1.2em;
        width: 80%;
        text-align: center;
        margin: 10px 0;
    }
    
    .nav-toggle {
        display: block;
    }
    
    .brand-text {
        display: none;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .site-footer {
        padding: 30px 0 15px 0;
    }
    .hebrew-heading {
    direction: rtl;
    text-align: right;
    }
}

/* ============================================================
   ACCESSIBILITY (תפריט נגישות)
   ============================================================ */

/* Font scale — applied via JS */
html { font-size: calc(16px * var(--a11y-font-scale, 1)); }

/* High contrast */
html.a11y-high-contrast {
    filter: contrast(150%);
}
html.a11y-high-contrast body {
    background: #000 !important;
    color: #fff !important;
}
html.a11y-high-contrast a { color: #ffff00 !important; }

/* Invert */
html.a11y-invert { filter: invert(100%) hue-rotate(180deg); }

/* Grayscale */
html.a11y-grayscale { filter: grayscale(100%); }

/* Stop animations */
html.a11y-no-animations *, html.a11y-no-animations *::before, html.a11y-no-animations *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
}

/* Underline links */
html.a11y-underline-links a { text-decoration: underline !important; }

/* Large cursor */
html.a11y-large-cursor, html.a11y-large-cursor * { cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32'%3E%3Ccircle cx='8' cy='8' r='7' fill='black' stroke='white' stroke-width='2'/%3E%3C/svg%3E") 8 8, auto !important; }

/* Readable font */
html.a11y-readable-font body, html.a11y-readable-font * { font-family: Arial, Helvetica, sans-serif !important; }

/* Accessibility FAB button */
#a11y-fab {
    position: fixed;
    bottom: 24px;
    left: 24px;
    z-index: 9998;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: #2c3e50;
    color: #fff;
    border: 2px solid #fff;
    font-size: 1.4rem;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(0,0,0,.35);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform .2s, background .2s;
}
#a11y-fab:hover { background: #1a252f; transform: scale(1.08); }
#a11y-fab:focus { outline: 3px solid #f39c12; outline-offset: 2px; }

/* Accessibility panel */
#a11y-panel {
    position: fixed;
    bottom: 90px;
    left: 24px;
    z-index: 9999;
    width: 280px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0,0,0,.28);
    border: 1px solid #ddd;
    transform: translateY(20px);
    opacity: 0;
    pointer-events: none;
    transition: transform .25s ease, opacity .25s ease;
    direction: rtl;
}
#a11y-panel.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
}
.a11y-header {
    background: linear-gradient(135deg, #2c3e50, #000);
    color: #fff;
    padding: 12px 16px;
    border-radius: 12px 12px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
    font-size: 0.95rem;
}
.a11y-close {
    background: transparent;
    border: none;
    color: #fff;
    cursor: pointer;
    font-size: 1rem;
    padding: 2px 6px;
    border-radius: 4px;
}
.a11y-close:hover { background: rgba(255,255,255,.15); }
.a11y-body { padding: 14px; }
.a11y-section-label { font-size: 0.75rem; font-weight: 700; color: #999; text-transform: uppercase; letter-spacing: .5px; margin-bottom: 8px; margin-top: 4px; }
.a11y-row { display: flex; gap: 8px; margin-bottom: 10px; }
.a11y-row.a11y-wrap { flex-wrap: wrap; }
.a11y-btn {
    flex: 1;
    padding: 7px 10px;
    border: 1px solid #ddd;
    border-radius: 6px;
    background: #f8f9fa;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 600;
    transition: background .15s;
}
.a11y-btn:hover { background: #e9ecef; }
.a11y-toggle-btn {
    padding: 6px 10px;
    border: 1px solid #ddd;
    border-radius: 6px;
    background: #f8f9fa;
    cursor: pointer;
    font-size: 0.8rem;
    transition: background .15s, border-color .15s;
    margin-bottom: 4px;
}
.a11y-toggle-btn.active { background: #2c3e50; color: #fff; border-color: #2c3e50; }
.a11y-toggle-btn:hover { background: #e9ecef; }
.a11y-toggle-btn.active:hover { background: #1a252f; }
.a11y-reset-all {
    width: 100%;
    padding: 8px;
    background: #e74c3c;
    color: #fff;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 600;
    margin-top: 4px;
}
.a11y-reset-all:hover { background: #c0392b; }
.a11y-footer-links { text-align: center; margin-top: 10px; font-size: 0.75rem; }
.a11y-footer-links a { color: #666; text-decoration: underline; }

/* ============================================================
   COOKIE CONSENT BANNER
   ============================================================ */
#cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 9990;
    background: rgba(20, 30, 40, 0.97);
    color: #e0e0e0;
    padding: 14px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    transform: translateY(100%);
    transition: transform .35s ease;
    direction: rtl;
    font-size: 0.88rem;
    border-top: 2px solid #2c3e50;
    flex-wrap: wrap;
}
#cookie-banner.visible { transform: translateY(0); }
.cookie-text { flex: 1; min-width: 200px; }
.cookie-actions { display: flex; gap: 10px; }
.cookie-btn {
    padding: 8px 20px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.88rem;
    font-weight: 600;
    white-space: nowrap;
}
.cookie-btn.accept { background: #27ae60; color: #fff; }
.cookie-btn.accept:hover { background: #219a52; }
.cookie-btn.decline { background: transparent; color: #aaa; border: 1px solid #555; }
.cookie-btn.decline:hover { background: #333; color: #fff; }

/* ============================================================
   LANGUAGE SWITCHER
   ============================================================ */
.lang-switcher {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-right: 12px;
}
.lang-btn {
    padding: 4px 10px;
    border-radius: 5px;
    border: 1px solid rgba(255,255,255,.3);
    background: transparent;
    color: #ccc;
    cursor: pointer;
    font-size: 0.82rem;
    font-weight: 600;
    transition: background .15s, color .15s;
}
.lang-btn.active, .lang-btn:hover { background: rgba(255,255,255,.15); color: #fff; }
.lang-btn.active { border-color: rgba(255,255,255,.6); }