/*
 * Dr. Matan Orgil - Plastic Surgery Landing Page
 * Custom Stylesheet
 * Brand Palette: Deep Navy Blue (#102e4a), Slate Steel Blue (#6386ac)
 * RTL Localized (dir="rtl")
 */

/* 1. IMPORTS & CSS VARIABLE TOKENS */
@import url('https://fonts.googleapis.com/css2?family=Google+Sans:ital,opsz,wght@0,17..18,400..700;1,17..18,400..700&display=swap');

:root {
    /* Brand Color Palette */
    --color-primary: #102e4a;
    /* Deep Midnight Navy */
    --color-primary-hover: #0a1f33;
    --color-accent: #6386ac;
    /* Slate Steel Blue */
    --color-accent-hover: #4e6f96;
    --color-accent-light: #f1f5f9;
    --color-gold: #c5a880;
    /* Luxury gold highlights */
    --color-gold-hover: #b4956c;

    /* Backgrounds */
    --bg-main: #f8fafc;
    /* Pristine luxury cool white */
    --bg-secondary: #ffffff;
    /* Pure white for overlays/cards */
    --bg-dark: #102e4a;
    /* Deep Navy for dark sections/footer */

    /* Typography Colors */
    --text-main: #0f172a;
    /* High-contrast Slate-900 */
    --text-muted: #475569;
    /* Readable Slate-600 */
    --text-light: #f8fafc;
    /* Light text for dark components */

    /* Borders & Accents */
    --border-color: rgba(16, 46, 74, 0.08);
    /* 1px black/5 equivalent */
    --border-focus: #6386ac;

    /* Typography */
    --font-heading: 'Google Sans', 'Google Sans Hebrew', sans-serif;
    --font-body: 'Google Sans', 'Google Sans Hebrew', sans-serif;

    /* Shadows & Transitions */
    --shadow-soft: 0 4px 20px rgba(16, 46, 74, 0.03);
    --shadow-medium: 0 10px 30px rgba(16, 46, 74, 0.06);
    --shadow-heavy: 0 20px 40px rgba(16, 46, 74, 0.1);
    --transition-smooth: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    --transition-fast: all 0.15s ease-in-out;
}

/* 2. GENERAL RESET & BASE STYLES */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-main);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
}

/* Focus States for Keyboard Navigation */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 3px solid var(--border-focus);
    outline-offset: 2px;
}

.max-width-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* RTL Number Reversal Protection */
.ltr-dir {
    direction: ltr;
    display: inline-block;
}

/* 3. BUTTONS & ACTIONS */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 1rem;
    padding: 12px 28px;
    border-radius: 50px;
    border: none;
    cursor: pointer;
    transition: var(--transition-smooth);
    text-decoration: none;
    text-align: center;
}

.btn-primary {
    background-color: var(--color-primary);
    color: var(--text-light);
}

.btn-primary:hover {
    background-color: var(--color-primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(16, 46, 74, 0.15);
}

.btn-outline {
    background-color: transparent;
    color: var(--color-primary);
    border: 1.5px solid var(--color-primary);
}

.btn-outline:hover {
    background-color: var(--color-accent-light);
    transform: translateY(-2px);
}

.btn-gold {
    background-color: var(--color-gold);
    color: white;
}

.btn-gold:hover {
    background-color: var(--color-gold-hover);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(197, 168, 128, 0.25);
}

.btn-header {
    padding: 8px 20px !important;
    font-size: 0.9rem !important;
}

/* 4. HEADER & FLOATING GLASSMORPHIC NAVBAR */
.main-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 84px;
    z-index: 998;
    background-color: rgba(248, 250, 252, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-color);
    transition: var(--transition-smooth);
}

.main-header.scrolled {
    height: 72px;
    background-color: rgba(248, 250, 252, 0.95);
    box-shadow: var(--shadow-soft);
}

.header-container {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-list {
    list-style: none;
    display: flex;
    gap: 32px;
}

.nav-link {
    text-decoration: none;
    font-family: var(--font-heading);
    font-weight: 500;
    font-size: 0.95rem;
    color: var(--text-muted);
    transition: var(--transition-fast);
    padding: 8px 0;
    position: relative;
}

.nav-link:hover {
    color: var(--color-primary);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background-color: var(--color-accent);
    transform: scaleX(0);
    transition: transform 0.25s ease-out;
}

.nav-link:hover::after {
    transform: scaleX(1);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 24px;
}

.header-contact {
    display: flex;
    align-items: center;
    gap: 16px;
}

.header-whatsapp-link {
    color: var(--color-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-fast);
    text-decoration: none;
}

.header-whatsapp-link:hover {
    color: #25D366;
    transform: scale(1.1);
}

.header-whatsapp-icon {
    width: 22px;
    height: 22px;
}

.header-phone-link {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--color-primary);
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.95rem;
    text-decoration: none;
    transition: var(--transition-fast);
    padding: 6px 14px;
    border-radius: 20px;
}

.header-phone-link:hover {
    color: var(--color-accent);
    background-color: rgba(99, 134, 172, 0.08);
}

.header-phone-icon {
    width: 18px;
    height: 18px;
    color: var(--color-accent);
}

/* Hamburger toggle for Mobile menu */
.mobile-nav-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 24px;
    height: 16px;
    background: transparent;
    border: none;
    cursor: pointer;
    z-index: 1001;
}

.hamburger-line {
    width: 100%;
    height: 2px;
    background-color: var(--color-primary);
    transition: var(--transition-smooth);
}

/* Hamburger to X transition when mobile menu is active */
.mobile-nav-toggle[aria-expanded="true"] .hamburger-line:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.mobile-nav-toggle[aria-expanded="true"] .hamburger-line:nth-child(2) {
    opacity: 0;
}

.mobile-nav-toggle[aria-expanded="true"] .hamburger-line:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* Mobile Nav Menu Overlay */
.mobile-nav-menu {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: rgba(248, 250, 252, 0.98);
    backdrop-filter: blur(20px);
    z-index: 997;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition-smooth);
}

.mobile-nav-menu.open {
    opacity: 1;
    visibility: visible;
}

.mobile-nav-list {
    list-style: none;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 28px;
}

.mobile-nav-link {
    text-decoration: none;
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-primary);
    transition: var(--transition-fast);
}

.mobile-nav-link:hover {
    color: var(--color-accent);
}

/* 5. HERO SECTION */
.hero-section {
    padding-top: 140px;
    padding-bottom: 0px;
    background: radial-gradient(circle at 10% 20%, rgba(99, 134, 172, 0.05) 0%, rgba(248, 250, 252, 0) 90%);
}

/* 6. BEFORE-AFTER IMAGE CAROUSEL */
.gallery-carousel-wrapper {
    position: relative;
    width: 100%;
}

.gallery-carousel-container {
    display: flex;
    transition: transform 0.5s cubic-bezier(0.25, 1, 0.5, 1);
    width: 100%;
}

.gallery-slide {
    flex: 0 0 100%;
    width: 100%;
    box-sizing: border-box;
}

.gallery-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-dot {
    cursor: pointer;
}

/* 7. TESTIMONIALS CAROUSEL */
.testimonials-wrapper {
    width: 100%;
    position: relative;
    overflow: hidden;
}

.testimonials-container {
    display: flex;
    transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1);
    width: 100%;
}

.testimonial-card {
    flex: 0 0 100%;
    width: 100%;
    padding: 16px;
    box-sizing: border-box;
}

/* 8. CORE CONVERSION WIDGETS */

/* A. Desktop Floating WhatsApp Widget */
.desktop-whatsapp-float {
    position: fixed;
    left: 30px;
    bottom: 30px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, #25D366 0%, #128C7E 100%);
    box-shadow: 0 8px 30px rgba(37, 211, 102, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    z-index: 999;
    cursor: pointer;
    text-decoration: none;
    transition: var(--transition-smooth);
    animation: whatsappRipple 2.5s infinite;
}

.desktop-whatsapp-float:hover {
    transform: scale(1.1) translateY(-3px);
    box-shadow: 0 12px 36px rgba(37, 211, 102, 0.5);
}

@keyframes whatsappRipple {
    0% {
        box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.4), 0 8px 30px rgba(37, 211, 102, 0.3);
    }

    70% {
        box-shadow: 0 0 0 16px rgba(37, 211, 102, 0), 0 8px 30px rgba(37, 211, 102, 0.3);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(37, 211, 102, 0), 0 8px 30px rgba(37, 211, 102, 0.3);
    }
}

@media (max-width: 768px) {
    .desktop-whatsapp-float {
        display: none !important;
        /* Hide strictly on mobile devices */
    }
}

/* B. Mobile Floating Capsule Actions Dock */
.mobile-action-bar {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - 32px);
    max-width: 320px;
    height: 64px;
    border-radius: 32px;
    background-color: rgba(248, 250, 252, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(16, 46, 74, 0.1);
    box-shadow: 0 10px 40px rgba(16, 46, 74, 0.15);
    z-index: 9999;
    display: none;
    /* Hidden on desktop viewports by default */
}

.mobile-action-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
    padding: 0 10px;
}

.mobile-action-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-primary);
    background-color: transparent;
    transition: var(--transition-fast);
    text-decoration: none;
}

.mobile-action-btn:active {
    background-color: rgba(99, 134, 172, 0.1);
}

.mobile-action-btn.mobile-whatsapp {
    color: #25D366;
}

.mobile-action-btn.mobile-cta {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-accent) 100%);
    color: white;
    width: 140px;
    border-radius: 28px;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.9rem;
    box-shadow: 0 4px 15px rgba(16, 46, 74, 0.2);
}

@media (max-width: 768px) {
    .mobile-action-bar {
        display: block;
        /* Visible ONLY on mobile/tablet viewports */
    }

    body {
        padding-bottom: 100px !important;
        /* Add spacing at the bottom of the body to prevent content overlay */
    }
}

/* 9. RESPONSIVE MEDIA QUERIES */
@media (max-width: 1024px) {
    .nav-list {
        gap: 20px;
    }

    .before-after-slider {
        height: 400px;
    }
}

@media (max-width: 768px) {
    .main-header {
        height: 72px;
    }

    .desktop-nav,
    .header-actions {
        display: none;
    }

    .mobile-nav-toggle {
        display: flex;
    }
}

/* 10. REPEATING BRAND EMBLEM PATTERNS */
.bg-pattern-light {
    position: relative;
}

.bg-pattern-light::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='309 40 101 114' width='66' height='75'%3E%3Cpath fill='%236386ac' fill-opacity='0.025' d='m409.98,40.49l-.02,52.2h-3.02c-20.66,0-39.37-12.57-47.3-31.56-7.93,18.98-26.65,31.56-47.32,31.56h-3l-.04-52.2h6.96v44.11c23.14-2.09,43.39-21.65,43.39-43.2h0c0,21.54,20.27,41.11,43.38,43.2v-44.11h6.96Z'/%3E%3Cpath fill='%236386ac' fill-opacity='0.025' d='m403.02,153.11v-44.15c-23.12,2.12-43.38,21.71-43.38,43.23h0c0-21.53-20.26-41.11-43.39-43.23v44.15h-6.96l.04-52.2h3c20.67,0,39.39,12.57,47.32,31.56,7.93-18.98,26.63-31.56,47.3-31.56h3.02l.02,52.2h-6.96Z'/%3E%3C/svg%3E");
    background-repeat: repeat;
    pointer-events: none;
    z-index: 0;
}

.bg-pattern-light > * {
    position: relative;
    z-index: 1;
}

.bg-pattern-dark {
    position: relative;
    overflow: hidden;
}

.bg-pattern-dark::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='309 40 101 114' width='66' height='75'%3E%3Cpath fill='%236386ac' fill-opacity='0.12' d='m409.98,40.49l-.02,52.2h-3.02c-20.66,0-39.37-12.57-47.3-31.56-7.93,18.98-26.65,31.56-47.32,31.56h-3l-.04-52.2h6.96v44.11c23.14-2.09,43.39-21.65,43.39-43.2h0c0,21.54,20.27,41.11,43.38,43.2v-44.11h6.96Z'/%3E%3Cpath fill='%236386ac' fill-opacity='0.12' d='m403.02,153.11v-44.15c-23.12,2.12-43.38,21.71-43.38,43.23h0c0-21.53-20.26-41.11-43.39-43.23v44.15h-6.96l.04-52.2h3c20.67,0,39.39,12.57,47.32,31.56,7.93-18.98,26.63-31.56,47.3-31.56h3.02l.02,52.2h-6.96Z'/%3E%3C/svg%3E");
    background-repeat: repeat;
    pointer-events: none;
    z-index: 0;
}

.bg-pattern-dark > * {
    position: relative;
    z-index: 1;
}