/* 
 * Главный файл стилей для сайта "Работа в Израиле"
 * Версия 1.0
 */

/* ========== CSS Variables ========== */
:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --secondary: #6b7280;
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --light: #f9fafb;
    --dark: #1f2937;
    --whatsapp: #25D366;
    
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    
    --radius-sm: 0.375rem;
    --radius: 0.5rem;
    --radius-md: 0.75rem;
    --radius-lg: 1rem;
    
    --spacing-1: 0.25rem;
    --spacing-2: 0.5rem;
    --spacing-3: 1rem;
    --spacing-4: 1.5rem;
    --spacing-5: 2rem;
    --spacing-6: 3rem;
}

/* ========== Reset & Base Styles ========== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: #fff;
    color: var(--dark);
    line-height: 1.6;
    padding-top: 72px; /* Для фиксированного header */
}

/* ========== Typography ========== */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: var(--spacing-3);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.75rem; }
h4 { font-size: 1.5rem; }
h5 { font-size: 1.25rem; }
h6 { font-size: 1rem; }

p {
    margin-bottom: var(--spacing-3);
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    color: var(--primary-dark);
}

/* ========== Container & Layout ========== */
.container {
    width: 100%;
    padding-right: var(--spacing-3);
    padding-left: var(--spacing-3);
    margin-right: auto;
    margin-left: auto;
}

@media (min-width: 576px) {
    .container { max-width: 540px; }
}

@media (min-width: 768px) {
    .container { max-width: 720px; }
}

@media (min-width: 992px) {
    .container { max-width: 960px; }
}

@media (min-width: 1200px) {
    .container { max-width: 1140px; }
}

@media (min-width: 1400px) {
    .container { max-width: 1320px; }
}

/* ========== Header & Navigation ========== */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow);
    padding: 0.75rem 0;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--spacing-3);
    flex-wrap: wrap;
}

.logo {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--primary);
    display: flex;
    align-items: center;
    gap: var(--spacing-2);
    white-space: nowrap;
}

.logo:hover {
    color: var(--primary-dark);
}

/* Navigation */
.nav-menu {
    display: flex;
    align-items: center;
    gap: var(--spacing-1);
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-link {
    color: var(--dark);
    font-weight: 500;
    padding: var(--spacing-2) 0.75rem;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    gap: var(--spacing-2);
    white-space: nowrap;
    font-size: 0.9rem;
}

.nav-link:hover,
.nav-link.active {
    background-color: var(--primary);
    color: white;
}

/* Search Form */
.search-form {
    flex: 1;
    min-width: 200px;
    max-width: 400px;
    position: relative;
}

.search-input {
    width: 100%;
    padding: 0.6rem 1rem 0.6rem 2.5rem;
    border: 2px solid #e5e7eb;
    border-radius: var(--radius);
    font-size: 0.9rem;
    transition: all 0.2s;
}

.search-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.search-form::before {
    content: '🔍';
    position: absolute;
    left: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    opacity: 0.5;
    z-index: 1;
}

/* Mobile Buttons */
.mobile-menu-btn,
.mobile-search-btn {
    display: none;
    background: none;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    color: var(--dark);
    padding: var(--spacing-2);
    border-radius: var(--radius);
}

/* WhatsApp Button */
.whatsapp-nav-btn {
    background-color: var(--whatsapp);
    color: white;
    border: none;
    padding: var(--spacing-2) var(--spacing-3);
    border-radius: var(--radius);
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: var(--spacing-2);
    transition: all 0.2s;
}

.whatsapp-nav-btn:hover {
    background-color: #128C7E;
    transform: translateY(-1px);
}

/* ========== Hero Section ========== */
.hero {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    padding: var(--spacing-6) 0;
    margin-bottom: var(--spacing-6);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1440 320"><path fill="%23ffffff" fill-opacity="0.1" d="M0,96L48,112C96,128,192,160,288,160C384,160,480,128,576,112C672,96,768,96,864,112C960,128,1056,160,1152,160C1248,160,1344,128,1392,112L1440,96L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z"></path></svg>') bottom/cover no-repeat;
}

.hero .container {
    position: relative;
    z-index: 1;
}

.hero h1 {
    color: white;
    font-size: 3rem;
}

.hero p {
    font-size: 1.25rem;
    opacity: 0.95;
    max-width: 700px;
    margin: 0 auto var(--spacing-5);
}

/* Stats in Hero */
.stat-number {
    font-size: 3rem;
    font-weight: 700;
    line-height: 1;
    color: white;
    text-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.stat-label {
    font-size: 1rem;
    opacity: 0.9;
    color: white;
}

/* ========== Quick Links ========== */
.quick-links-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: var(--spacing-2);
    margin-top: var(--spacing-3);
}

.quick-link {
    display: block;
    padding: var(--spacing-2) var(--spacing-3);
    background-color: var(--light);
    border-radius: var(--radius);
    color: var(--dark);
    text-align: center;
    font-weight: 500;
    transition: all 0.3s ease;
    border: 1px solid #e5e7eb;
}

.quick-link:hover {
    background-color: var(--primary);
    color: white;
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary);
}

/* ========== Job Cards ========== */
.job-card {
    border: 1px solid #e5e7eb;
    border-radius: var(--radius-md);
    padding: var(--spacing-4);
    margin-bottom: var(--spacing-3);
    transition: all 0.3s ease;
    background: white;
    height: 100%;
}

.job-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary);
}

.job-card.urgent {
    border-left: 4px solid var(--danger);
}

.job-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: var(--spacing-2);
}

.job-title a {
    color: var(--dark);
}

.job-title a:hover {
    color: var(--primary);
}

.job-meta {
    color: var(--secondary);
    font-size: 0.9rem;
    margin-bottom: var(--spacing-2);
}

.job-stats span {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}

/* ========== Section Titles ========== */
.section-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: var(--spacing-4);
    display: flex;
    align-items: center;
    gap: var(--spacing-2);
    color: var(--dark);
}

/* ========== Stats Cards ========== */
.stats-card {
    border: 1px solid #e5e7eb;
    border-radius: var(--radius-md);
    overflow: hidden;
    margin-bottom: var(--spacing-4);
    background: white;
}

.stats-card-header {
    background-color: var(--light);
    padding: var(--spacing-3) var(--spacing-4);
    border-bottom: 1px solid #e5e7eb;
}

.stats-card-body {
    padding: var(--spacing-4);
}

.stats-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.stats-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--spacing-2) 0;
    border-bottom: 1px solid #f3f4f6;
}

.stats-item:last-child {
    border-bottom: none;
}

.stats-link {
    color: var(--dark);
    transition: color 0.2s;
}

.stats-link:hover {
    color: var(--primary);
}

.stats-count {
    background-color: var(--primary);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.8rem;
    font-weight: 600;
}

/* ========== CTA Section ========== */
.cta-section {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    padding: var(--spacing-6) var(--spacing-5);
    border-radius: var(--radius-lg);
    text-align: center;
    margin: var(--spacing-6) 0;
    position: relative;
    overflow: hidden;
}

.cta-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1440 320"><path fill="%23ffffff" fill-opacity="0.1" d="M0,96L48,112C96,128,192,160,288,160C384,160,480,128,576,112C672,96,768,96,864,112C960,128,1056,160,1152,160C1248,160,1344,128,1392,112L1440,96L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z"></path></svg>') bottom/cover no-repeat;
}

.cta-section h2 {
    color: white;
    font-size: 2.5rem;
    position: relative;
    z-index: 1;
}

.cta-section p {
    font-size: 1.25rem;
    opacity: 0.95;
    margin-bottom: var(--spacing-5);
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    position: relative;
    z-index: 1;
}

/* ========== Buttons ========== */
.btn {
    display: inline-block;
    font-weight: 500;
    line-height: 1.5;
    text-align: center;
    text-decoration: none;
    vertical-align: middle;
    cursor: pointer;
    user-select: none;
    border: 1px solid transparent;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    border-radius: var(--radius);
    transition: all 0.2s;
}

.btn-light {
    color: #000;
    background-color: #f8f9fa;
    border-color: #f8f9fa;
}

.btn-light:hover {
    background-color: #e9ecef;
    border-color: #e9ecef;
}

.btn-outline-light {
    color: #f8f9fa;
    border-color: #f8f9fa;
}

.btn-outline-light:hover {
    color: #000;
    background-color: #f8f9fa;
}

.btn-primary {
    color: #fff;
    background-color: var(--primary);
    border-color: var(--primary);
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    border-color: var(--primary-dark);
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

.btn-lg {
    padding: 1rem 2rem;
    font-size: 1.25rem;
    border-radius: var(--radius-md);
}

.btn-link {
    font-weight: 400;
    color: var(--primary);
    text-decoration: underline;
    background-color: transparent;
    border: none;
    padding: 0;
}

.btn-link:hover {
    color: var(--primary-dark);
}

/* ========== Badges ========== */
.badge {
    display: inline-block;
    padding: 0.35em 0.65em;
    font-size: 0.75em;
    font-weight: 700;
    line-height: 1;
    text-align: center;
    white-space: nowrap;
    vertical-align: baseline;
    border-radius: var(--radius-sm);
}

.badge-primary {
    color: #fff;
    background-color: var(--primary);
}

.badge-secondary {
    color: #fff;
    background-color: var(--secondary);
}

.badge-success {
    color: #fff;
    background-color: var(--success);
}

.badge-warning {
    color: #000;
    background-color: var(--warning);
}

.badge-danger {
    color: #fff;
    background-color: var(--danger);
}

/* ========== Utility Classes ========== */
.text-center { text-align: center !important; }
.text-muted { color: var(--secondary) !important; }

.d-flex { display: flex !important; }
.flex-wrap { flex-wrap: wrap !important; }
.justify-content-center { justify-content: center !important; }
.justify-content-between { justify-content: space-between !important; }
.align-items-center { align-items: center !important; }
.align-items-start { align-items: flex-start !important; }

.w-100 { width: 100% !important; }

.bg-dark { background-color: #212529 !important; }
.bg-primary { background-color: var(--primary) !important; }
.text-white { color: #fff !important; }

/* Spacing */
.m-0 { margin: 0 !important; }
.mb-0 { margin-bottom: 0 !important; }
.mb-2 { margin-bottom: var(--spacing-1) !important; }
.mb-3 { margin-bottom: var(--spacing-3) !important; }
.mb-4 { margin-bottom: var(--spacing-4) !important; }
.mb-5 { margin-bottom: var(--spacing-5) !important; }
.mt-3 { margin-top: var(--spacing-3) !important; }
.mt-4 { margin-top: var(--spacing-4) !important; }
.mt-5 { margin-top: var(--spacing-5) !important; }
.my-4 { margin-top: var(--spacing-4) !important; margin-bottom: var(--spacing-4) !important; }
.mx-4 { margin-left: var(--spacing-4) !important; margin-right: var(--spacing-4) !important; }

.p-0 { padding: 0 !important; }
.py-3 { padding-top: var(--spacing-3) !important; padding-bottom: var(--spacing-3) !important; }
.py-4 { padding-top: var(--spacing-4) !important; padding-bottom: var(--spacing-4) !important; }
.py-5 { padding-top: var(--spacing-5) !important; padding-bottom: var(--spacing-5) !important; }
.px-4 { padding-left: var(--spacing-4) !important; padding-right: var(--spacing-4) !important; }
.pt-3 { padding-top: var(--spacing-3) !important; }
.pt-4 { padding-top: var(--spacing-4) !important; }
.pt-5 { padding-top: var(--spacing-5) !important; }
.pb-4 { padding-bottom: var(--spacing-4) !important; }

.gap-1 { gap: var(--spacing-1) !important; }
.gap-2 { gap: var(--spacing-2) !important; }
.gap-3 { gap: var(--spacing-3) !important; }

.me-2 { margin-right: var(--spacing-1) !important; }
.me-3 { margin-right: var(--spacing-3) !important; }
.ms-1 { margin-left: var(--spacing-1) !important; }

/* Row & Columns */
.row {
    display: flex;
    flex-wrap: wrap;
    margin-right: -0.75rem;
    margin-left: -0.75rem;
}

.row > * {
    flex-shrink: 0;
    width: 100%;
    max-width: 100%;
    padding-right: 0.75rem;
    padding-left: 0.75rem;
}

.col-12 { flex: 0 0 auto; width: 100%; }
.col-6 { flex: 0 0 auto; width: 50%; }
.col-md-6 { flex: 0 0 auto; width: 100%; }
.col-lg-6 { flex: 0 0 auto; width: 100%; }

@media (min-width: 768px) {
    .col-md-6 { width: 50%; }
}

@media (min-width: 992px) {
    .col-lg-6 { width: 50%; }
}

/* ========== Footer ========== */
.site-footer {
    background: linear-gradient(135deg, #1a202c 0%, #2d3748 100%);
    color: white;
    padding: var(--spacing-6) 0 var(--spacing-4);
    margin-top: var(--spacing-6);
    position: relative;
}

.site-footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--success));
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--spacing-5);
    margin-bottom: var(--spacing-5);
}

.footer-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: var(--spacing-3);
    position: relative;
    padding-bottom: var(--spacing-2);
}

.footer-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 30px;
    height: 2px;
    background: var(--primary);
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links li {
    margin-bottom: var(--spacing-2);
}

.footer-links a {
    color: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    gap: var(--spacing-2);
    padding: 0.25rem 0;
    font-size: 0.9rem;
}

.footer-links a:hover {
    color: white;
    padding-left: 5px;
}

.footer-contacts p {
    margin-bottom: 0.75rem;
    color: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    gap: var(--spacing-2);
    font-size: 0.9rem;
}

.social-links {
    display: flex;
    gap: var(--spacing-2);
    margin-top: var(--spacing-3);
}

.social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-radius: 50%;
    transition: all 0.3s;
}

.social-link:hover {
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.2);
}

.social-link.facebook:hover { background: #1877f2 !important; }
.social-link.telegram:hover { background: #0088cc !important; }
.social-link.linkedin:hover { background: #0a66c2 !important; }
.social-link.whatsapp:hover { background: #25D366 !important; }

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: var(--spacing-4);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: var(--spacing-3);
}

.copyright {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.85rem;
    line-height: 1.4;
}

.stats {
    color: rgba(255, 255, 255, 0.6);
    display: flex;
    align-items: center;
    gap: var(--spacing-3);
    font-size: 0.8rem;
}

.footer-newsletter {
    background: rgba(255, 255, 255, 0.05);
    padding: var(--spacing-3);
    border-radius: var(--radius);
    margin-top: var(--spacing-3);
}

.newsletter-form {
    display: flex;
    gap: var(--spacing-2);
}

.newsletter-input {
    flex: 1;
    padding: 0.5rem 0.75rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
}

.newsletter-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.newsletter-btn {
    background: var(--primary);
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-weight: 500;
    white-space: nowrap;
    transition: background 0.3s;
}

.newsletter-btn:hover {
    background: var(--primary-dark);
}

/* ========== Accessibility ========== */
.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;
}

a:focus,
button:focus {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

/* ========== Animations ========== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in {
    animation: fadeInUp 0.6s ease-out forwards;
    opacity: 0;
}

.delay-1 { animation-delay: 0.2s; }
.delay-2 { animation-delay: 0.4s; }
.delay-3 { animation-delay: 0.6s; }

/* ========== Media Queries ========== */
@media (max-width: 992px) {
    body {
        padding-top: 112px;
    }
    
    .mobile-search-btn {
        display: block;
    }
    
    .search-form:not(.expanded) {
        display: none;
    }
    
    .search-form.expanded {
        flex: 1 1 100%;
        order: 3;
        margin-top: var(--spacing-2);
        max-width: 100%;
    }
}

@media (max-width: 768px) {
    .mobile-menu-btn {
        display: block;
    }
    
    .nav-menu {
        position: fixed;
        top: 72px;
        left: 0;
        right: 0;
        background: white;
        flex-direction: column;
        padding: var(--spacing-3);
        box-shadow: 0 5px 20px rgba(0,0,0,0.1);
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s;
        z-index: 999;
        border-radius: 0 0 var(--radius-lg) var(--radius-lg);
        max-height: calc(100vh - 72px);
        overflow-y: auto;
    }
    
    .nav-menu.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }
    
    .nav-link {
        width: 100%;
        justify-content: flex-start;
        padding: 0.75rem 1rem;
    }
    
    .whatsapp-nav-btn {
        width: 100%;
        justify-content: center;
        margin-top: var(--spacing-2);
    }
    
    /* Hero adjustments */
    .hero {
        padding: var(--spacing-5) 0;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .hero p {
        font-size: 1.1rem;
    }
    
    .stat-number {
        font-size: 2.5rem;
    }
    
    /* Quick links */
    .quick-links-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    /* CTA */
    .cta-section {
        padding: var(--spacing-5) var(--spacing-3);
    }
    
    .cta-section h2 {
        font-size: 2rem;
    }
    
    .cta-section p {
        font-size: 1.1rem;
    }
    
    /* Footer */
    .site-footer {
        padding: var(--spacing-5) 0 var(--spacing-3);
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-4);
    }
    
    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
    
    .newsletter-form {
        flex-direction: column;
    }
}

@media (max-width: 576px) {
    .logo span {
        font-size: 1.1rem;
    }
    
    .header-content {
        gap: var(--spacing-2);
    }
    
    .quick-links-grid {
        grid-template-columns: 1fr;
    }
    
    .btn-lg {
        padding: 0.75rem 1.5rem;
        font-size: 1rem;
    }
    
    .hero h1 {
        font-size: 1.75rem;
    }
    
    .cta-section h2 {
        font-size: 1.75rem;
    }
}