:root {
    /* Palette */
    --primary: #0f4c5c;
    --primary-light: #1a6d82;
    --secondary: #5ebec4;
    --accent: #d4af37;
    --bg: #f8fafc;
    --bg-soft: #f1f5f9;
    --bg-dark: #0a2e38;
    --text: #1e293b;
    --text-muted: #64748b;
    --white: #ffffff;
    --glass: rgba(255, 255, 255, 0.8);
    
    /* Spacing */
    --container: 1200px;
    --section-pad: 100px;
    --section-pad-mobile: 60px;
    
    /* Transitions */
    --ease: cubic-bezier(0.4, 0, 0.2, 1);
    --transition: all 0.4s var(--ease);
}

/* Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg);
    color: var(--text);
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3, h4, .logo {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    line-height: 1.2;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

.container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 24px;
}

.section-padding {
    padding: var(--section-pad) 0;
}

.bg-soft {
    background-color: var(--bg-soft);
}

.bg-dark {
    background-color: var(--bg-dark);
    color: var(--white);
}

/* RTL Support */
[dir="rtl"] {
    font-family: 'Inter', 'Arial', sans-serif; /* Fallback for Arabic */
}
[dir="rtl"] .hero-content {
    text-align: right;
}
[dir="rtl"] .nav-links {
    flex-direction: row-reverse;
}
[dir="rtl"] .lang-dropdown {
    left: 0;
    right: auto;
}

/* Preloader */
#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-dark);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.6s var(--ease);
}

.loader-content {
    text-align: center;
}

.loader-logo {
    font-family: 'Playfair Display', serif;
    font-size: 2.5rem;
    color: var(--white);
    letter-spacing: 4px;
    margin-bottom: 20px;
    animation: pulse 2s infinite;
}

.loader-bar {
    width: 100px;
    height: 2px;
    background: rgba(255, 255, 255, 0.1);
    margin: 0 auto;
    position: relative;
    overflow: hidden;
}

.loader-bar::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: var(--accent);
    animation: loading 1.5s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 1; }
}

@keyframes loading {
    100% { left: 100%; }
}

/* Navigation */
#navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 20px 0;
    transition: var(--transition);
}

#navbar.scrolled {
    background: var(--glass);
    backdrop-filter: blur(10px);
    padding: 15px 0;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.05);
}

.nav-container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    font-size: 1.5rem;
    letter-spacing: 2px;
    color: var(--primary);
}

.logo span {
    color: var(--accent);
}

.nav-links {
    display: none;
    gap: 40px;
}

.nav-links a {
    font-size: 0.9rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text);
    opacity: 0.8;
}

.nav-links a:hover {
    opacity: 1;
    color: var(--primary);
}

.nav-cta {
    background: var(--primary);
    color: var(--white) !important;
    padding: 5px 24px;
    border-radius: 50px;
    opacity: 1 !important;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 20px;
}

.lang-switcher {
    position: relative;
}

#langBtn {
    background: none;
    border: 1px solid rgba(0,0,0,0.1);
    padding: 6px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.8rem;
    font-weight: 600;
}

.lang-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--white);
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    border-radius: 8px;
    padding: 10px;
    display: none;
    flex-direction: column;
    min-width: 120px;
    margin-top: 10px;
}

.lang-dropdown.active {
    display: flex;
}

.lang-dropdown button {
    background: none;
    border: none;
    padding: 8px 12px;
    text-align: left;
    cursor: pointer;
    font-size: 0.9rem;
    border-radius: 4px;
}

.lang-dropdown button:hover {
    background: var(--bg-soft);
}

.hamburger {
    display: block;
    background: none;
    border: none;
    cursor: pointer;
    width: 30px;
    height: 20px;
    position: relative;
}

.hamburger span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--primary);
    position: absolute;
    transition: var(--transition);
}

.hamburger span:nth-child(1) { top: 0; }
.hamburger span:nth-child(2) { top: 9px; }
.hamburger span:nth-child(3) { top: 18px; }

.hamburger.active span:nth-child(1) { transform: translateY(9px) rotate(45deg); }
.hamburger.active span:nth-child(2) { opacity: 0; }
.hamburger.active span:nth-child(3) { transform: translateY(-9px) rotate(-45deg); }

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: 100px;
    background: radial-gradient(circle at 80% 20%, var(--secondary) 0%, transparent 40%),
                radial-gradient(circle at 10% 80%, var(--bg-soft) 0%, transparent 30%);
}

.hero-container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 24px;
    display: grid;
    grid-template-columns: 1fr;
    gap: 60px;
    align-items: center;
}

.hero-content {
    max-width: 600px;
}

.badge {
    display: inline-block;
    padding: 6px 16px;
    background: rgba(15, 76, 92, 0.1);
    color: var(--primary);
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 24px;
}

.hero h1 {
    font-size: clamp(2.5rem, 8vw, 4rem);
    margin-bottom: 24px;
    color: var(--primary);
}

.hero p {
    font-size: 1.1rem;
    color: var(--text-muted);
}

.hero-btns {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 15px;
}

.btn {
    padding: 16px 32px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    border: none;
    display: inline-block;
}

.btn-primary {
    background: var(--primary);
    color: var(--white);
    box-shadow: 0 10px 20px rgba(15, 76, 92, 0.2);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 30px rgba(15, 76, 92, 0.3);
}

.btn-secondary {
    background: var(--white);
    color: var(--primary);
    border: 1px solid rgba(15, 76, 92, 0.2);
}

.btn-secondary:hover {
    background: var(--bg-soft);
}

.hero-visual {
    position: relative;
}

.hero-image-wrapper {
    position: relative;
    border-radius: 30px;
    overflow: hidden;
    box-shadow: 0 30px 60px rgba(0,0,0,0.1);
}

.hero-image-wrapper img {
    width: 100%;
    height: 500px;
    object-fit: cover;
}

.floating-card {
    position: absolute;
    bottom: 30px;
    left: -20px;
    background: var(--white);
    padding: 20px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    animation: float 4s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

/* About Section */
.about-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 60px;
    align-items: center;
}

.about-image img {
    border-radius: 30px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.05);
}

.about-content h2 {
    font-size: 2.5rem;
    margin-bottom: 24px;
    color: var(--primary);
}

.about-content p {
    margin-bottom: 20px;
    color: var(--text-muted);
}

.stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-top: 40px;
}

.stat-num {
    display: block;
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--accent);
    font-family: 'Playfair Display', serif;
}

.stat-label {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
}

/* Services Section */
.section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 60px;
}

.section-header h2 {
    font-size: 2.5rem;
    margin-bottom: 16px;
    color: var(--primary);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.service-card {
    background: var(--white);
    padding: 40px;
    border-radius: 24px;
    transition: var(--transition);
    border: 1px solid rgba(0,0,0,0.03);
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.05);
    border-color: var(--secondary);
}

.service-icon {
    font-size: 2.5rem;
    margin-bottom: 24px;
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 16px;
}

.service-card p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* Why Choose Us */
.why-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 60px;
    align-items: center;
}

.why-list {
    margin-top: 40px;
}

.why-list li {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
}

.list-icon {
    flex-shrink: 0;
    width: 32px;
    height: 32px;
    background: var(--secondary);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

.why-list h4 {
    font-size: 1.2rem;
    margin-bottom: 8px;
}

.why-visual img {
    border-radius: 30px;
}

/* Results Section */
.results-slider {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
}

.comparison {
    display: flex;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

.before, .after {
    position: relative;
    width: 50%;
}

.comparison img {
    width: 100%;
    height: 300px;
    object-fit: cover;
}

.comparison .label {
    position: absolute;
    bottom: 15px;
    left: 15px;
    background: rgba(0,0,0,0.5);
    color: var(--white);
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 0.7rem;
    text-transform: uppercase;
}

.after .label {
    left: auto;
    right: 15px;
    background: var(--primary);
}

.result-caption {
    text-align: center;
    margin-top: 20px;
    font-weight: 500;
}

/* Testimonials */
.testi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.testi-card {
    background: var(--bg-soft);
    padding: 40px;
    border-radius: 24px;
}

.stars {
    color: var(--accent);
    margin-bottom: 20px;
}

.testi-card p {
    font-style: italic;
    margin-bottom: 30px;
    font-size: 1.1rem;
}

.patient {
    display: flex;
    align-items: center;
    gap: 15px;
}

.patient img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
}

.patient h5 {
    font-size: 1rem;
}

.patient span {
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* Booking Section */
.booking-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 60px;
}

.booking-info h2 {
    font-size: 2.5rem;
    margin-bottom: 24px;
}

.contact-details {
    margin-top: 40px;
}

.detail-item {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
}

.detail-item .icon {
    font-size: 1.5rem;
}

.booking-form-wrapper {
    background: var(--white);
    padding: 40px;
    border-radius: 30px;
    color: var(--text);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.form-group input, .form-group select, .form-group textarea {
    width: 100%;
    padding: 14px;
    border: 1px solid rgba(0,0,0,0.1);
    border-radius: 12px;
    font-family: inherit;
    transition: var(--transition);
}

.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(15, 76, 92, 0.1);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

.btn-block {
    width: 100%;
}

/* FAQ Section */
.faq-list {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.faq-question {
    width: 100%;
    padding: 24px 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.1rem;
    font-weight: 600;
    text-align: left;
    color: var(--primary);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s var(--ease);
}

.faq-answer p {
    padding-bottom: 24px;
    color: var(--text-muted);
}

.faq-item.open .faq-answer {
    max-height: 500px; /* Increased for better fit */
}

.faq-item.open .faq-icon {
    transform: rotate(45deg);
}

.faq-icon {
    font-size: 1.2rem;
    transition: var(--transition);
    color: var(--accent);
}

/* Footer */
.footer {
    padding: 80px 0 40px;
    background: var(--bg-soft);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
    margin-bottom: 60px;
}

.footer-brand .logo {
    margin-bottom: 20px;
    display: inline-block;
}

.footer-links h5, .footer-social h5 {
    margin-bottom: 20px;
    font-size: 1.1rem;
}

.footer-links a {
    display: block;
    margin-bottom: 12px;
    color: var(--text-muted);
}

.social-icons {
    display: flex;
    gap: 15px;
}

.social-icons a {
    width: 40px;
    height: 40px;
    background: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: bold;
}

.footer-bottom {
    text-align: center;
    padding-top: 40px;
    border-top: 1px solid rgba(0,0,0,0.05);
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* Reveal Animation */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* Media Queries */
@media (min-width: 768px) {
    .nav-links {
        display: flex;
        align-items: center;
    }
    .hamburger {
        display: none;
    }
    .hero-container {
        grid-template-columns: 1.2fr 0.8fr;
    }
    .about-grid, .why-grid, .booking-grid {
        grid-template-columns: 1fr 1fr;
    }
    .results-slider {
        grid-template-columns: 1fr 1fr;
    }
    .footer-grid {
        grid-template-columns: 2fr 1fr 1fr;
    }
    .form-row {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 767px) {
    .nav-links.mobile-active {
        display: flex;
        flex-direction: column;
        position: fixed;
        top: 0;
        right: 0;
        width: 80%;
        height: 100vh;
        background: var(--white);
        padding: 100px 40px;
        box-shadow: -10px 0 30px rgba(0,0,0,0.1);
        z-index: 999;
    }
}

/* Google Rating Highlight */
.rating-card {
    min-width: 220px;
    border: 1px solid rgba(66, 133, 244, 0.1);
}

.google-icon {
    background: #f8f9fa;
    padding: 8px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.rating-flex {
    display: flex;
    align-items: center;
    gap: 8px;
}

.rating-num {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
    font-family: 'Playfair Display', serif;
}

.stars-mini {
    color: #fbbc05;
    font-size: 0.8rem;
    letter-spacing: 1px;
}

.rating-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 2px;
}

.footer-rating {
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid rgba(0,0,0,0.05);
}

.footer-rating .stars {
    font-size: 1.2rem;
    margin-bottom: 8px;
}

.footer-rating p {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 4px;
}

.reviews-count {
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* RTL Adjustments for Rating */
[dir="rtl"] .rating-card {
    left: auto;
    right: -20px;
}

[dir="rtl"] .rating-flex {
    flex-direction: row-reverse;
}

@media (max-width: 768px) {
    .rating-card {
        position: static;
        margin-top: 20px;
        width: 100%;
        left: 0;
    }
}

