/*
Theme Name: Apex Med Landing
Theme URI: https://apexmed-eg.com
Author: Apex Med
Author URI: https://apexmed-eg.com
Description: Professional bilingual (Arabic/English) landing page theme for Apex Med domestic workers agency. Features RTL support, WhatsApp integration, and conversion-focused design.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: apex-med
Tags: one-column, custom-colors, custom-logo, rtl-language-support, translation-ready

Apex Med - Licensed Domestic Workers Agency
*/

/* ============================================
   CSS VARIABLES & DESIGN TOKENS
   ============================================ */
:root {
    /* Warm cream background */
    --background: hsl(40, 33%, 98%);
    --foreground: hsl(220, 30%, 15%);
    
    /* Cards */
    --card: hsl(40, 40%, 99%);
    --card-foreground: hsl(220, 30%, 15%);
    
    /* Primary - Warm Teal */
    --primary: hsl(168, 65%, 35%);
    --primary-foreground: hsl(0, 0%, 100%);
    
    /* Secondary - Golden Amber */
    --secondary: hsl(38, 92%, 50%);
    --secondary-foreground: hsl(220, 30%, 15%);
    
    /* Muted */
    --muted: hsl(40, 20%, 94%);
    --muted-foreground: hsl(220, 15%, 45%);
    
    /* Accent - Coral */
    --accent: hsl(18, 76%, 58%);
    --accent-foreground: hsl(0, 0%, 100%);
    
    /* Border */
    --border: hsl(40, 20%, 88%);
    
    /* WhatsApp */
    --whatsapp: hsl(142, 70%, 45%);
    --whatsapp-foreground: hsl(0, 0%, 100%);
    
    /* Shadows */
    --shadow-soft: 0 4px 20px -2px hsla(220, 30%, 15%, 0.08);
    --shadow-elevated: 0 12px 40px -8px hsla(220, 30%, 15%, 0.15);
    
    /* Gradients */
    --cta-gradient: linear-gradient(135deg, hsl(38, 92%, 50%) 0%, hsl(28, 88%, 55%) 100%);
    --hero-gradient: linear-gradient(135deg, hsl(168, 65%, 35%) 0%, hsl(180, 55%, 40%) 100%);
    
    /* Border Radius */
    --radius: 0.75rem;
    --radius-lg: 1rem;
    --radius-xl: 1.5rem;
}

/* ============================================
   BASE STYLES
   ============================================ */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background-color: var(--background);
    color: var(--foreground);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* RTL Arabic Mode */
[dir="rtl"] body,
body.rtl {
    font-family: 'Cairo', 'Inter', sans-serif;
}

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

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

/* ============================================
   CONTAINER
   ============================================ */
.container {
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1rem;
}

@media (min-width: 768px) {
    .container {
        padding: 0 1.5rem;
    }
}

/* ============================================
   HEADER
   ============================================ */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 50;
    background: hsla(40, 40%, 99%, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 4rem;
}

@media (min-width: 768px) {
    .header-inner {
        height: 5rem;
    }
}

.site-logo img {
    height: 2.5rem;
    width: auto;
    object-fit: contain;
}

@media (min-width: 768px) {
    .site-logo img {
        height: 3rem;
    }
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

@media (min-width: 768px) {
    .header-actions {
        gap: 1rem;
    }
}

.header-phone {
    display: none;
    align-items: center;
    gap: 0.5rem;
    color: var(--primary);
    font-weight: 500;
    transition: color 0.3s ease;
}

.header-phone:hover {
    color: hsl(168, 65%, 28%);
}

@media (min-width: 768px) {
    .header-phone {
        display: flex;
    }
}

.btn-lang {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border: 1px solid hsla(168, 65%, 35%, 0.3);
    border-radius: var(--radius);
    background: transparent;
    color: var(--foreground);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-lang:hover {
    background: var(--primary);
    color: var(--primary-foreground);
    border-color: var(--primary);
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero-section {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding-top: 4rem;
}

@media (min-width: 768px) {
    .hero-section {
        padding-top: 5rem;
    }
}

.hero-bg {
    position: absolute;
    inset: 0;
}

.hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, 
        hsla(40, 33%, 98%, 0.7) 0%, 
        hsla(40, 33%, 98%, 0.5) 50%, 
        var(--background) 100%
    );
}

.hero-content {
    position: relative;
    z-index: 10;
    text-align: center;
    padding: 3rem 1rem;
    max-width: 56rem;
    margin: 0 auto;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border-radius: 9999px;
    background: hsla(168, 65%, 35%, 0.1);
    border: 1px solid hsla(168, 65%, 35%, 0.2);
    margin-bottom: 1.5rem;
    animation: fadeIn 0.6s ease-out;
}

.hero-badge-dot {
    width: 0.5rem;
    height: 0.5rem;
    border-radius: 50%;
    background: var(--primary);
    animation: pulse 2s infinite;
}

.hero-badge-text {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--primary);
}

.hero-title {
    font-size: 1.875rem;
    font-weight: 700;
    color: var(--foreground);
    margin-bottom: 1.5rem;
    line-height: 1.2;
    animation: slideUp 0.6s ease-out;
}

@media (min-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }
}

@media (min-width: 1024px) {
    .hero-title {
        font-size: 3rem;
    }
}

@media (min-width: 1280px) {
    .hero-title {
        font-size: 3.75rem;
    }
}

.hero-subtitle {
    font-size: 1.125rem;
    color: var(--muted-foreground);
    margin-bottom: 2.5rem;
    max-width: 42rem;
    margin-left: auto;
    margin-right: auto;
    animation: slideUp 0.6s ease-out 0.1s backwards;
}

@media (min-width: 768px) {
    .hero-subtitle {
        font-size: 1.25rem;
    }
}

.hero-ctas {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    animation: slideUp 0.6s ease-out 0.2s backwards;
}

@media (min-width: 640px) {
    .hero-ctas {
        flex-direction: row;
        justify-content: center;
    }
}

.hero-stats {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    margin-top: 3rem;
    color: var(--muted-foreground);
    animation: fadeIn 0.6s ease-out 0.3s backwards;
}

@media (min-width: 768px) {
    .hero-stats {
        gap: 2.5rem;
    }
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.stat-number {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
}

@media (min-width: 768px) {
    .stat-number {
        font-size: 1.875rem;
    }
}

.stat-label {
    font-size: 0.875rem;
}

.stat-divider {
    display: none;
    width: 1px;
    height: 2rem;
    background: var(--border);
}

@media (min-width: 640px) {
    .stat-divider {
        display: block;
    }
}

.hero-wave {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
}

.hero-wave svg {
    width: 100%;
    display: block;
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1rem 2rem;
    border-radius: var(--radius-lg);
    font-size: 1.125rem;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.3s ease;
    width: 100%;
}

@media (min-width: 640px) {
    .btn {
        width: auto;
    }
}

.btn-primary {
    background: var(--cta-gradient);
    color: var(--foreground);
    box-shadow: var(--shadow-soft);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-elevated);
}

.btn-whatsapp {
    background: var(--whatsapp);
    color: var(--whatsapp-foreground);
    box-shadow: var(--shadow-soft);
}

.btn-whatsapp:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-elevated);
}

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

.btn-outline:hover {
    background: var(--primary);
    color: var(--primary-foreground);
}

.btn-icon {
    width: 1.25rem;
    height: 1.25rem;
}

/* ============================================
   SECTIONS
   ============================================ */
.section {
    padding: 4rem 0;
}

@media (min-width: 768px) {
    .section {
        padding: 6rem 0;
    }
}

.section-alt {
    background: var(--muted);
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-title {
    font-size: 1.875rem;
    font-weight: 700;
    color: var(--foreground);
    margin-bottom: 1rem;
}

@media (min-width: 768px) {
    .section-title {
        font-size: 2.25rem;
    }
}

@media (min-width: 1024px) {
    .section-title {
        font-size: 3rem;
    }
}

.section-subtitle {
    font-size: 1.125rem;
    color: var(--muted-foreground);
    max-width: 48rem;
    margin: 0 auto;
}

/* ============================================
   FEATURE CARDS
   ============================================ */
.features-grid {
    display: grid;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .features-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.feature-card {
    background: var(--card);
    padding: 1.5rem;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-soft);
    transition: all 0.3s ease;
}

@media (min-width: 768px) {
    .feature-card {
        padding: 2rem;
    }
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-elevated);
}

.feature-icon {
    width: 3rem;
    height: 3rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: hsla(168, 65%, 35%, 0.1);
    border-radius: var(--radius);
    margin-bottom: 1rem;
    color: var(--primary);
}

.feature-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--foreground);
    margin-bottom: 0.5rem;
}

.feature-desc {
    font-size: 0.875rem;
    color: var(--muted-foreground);
}

/* ============================================
   NATIONALITY FLAGS
   ============================================ */
.nationalities-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

@media (min-width: 640px) {
    .nationalities-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 1.5rem;
    }
}

@media (min-width: 1024px) {
    .nationalities-grid {
        grid-template-columns: repeat(9, 1fr);
    }
}

.nationality-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    background: var(--card);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-soft);
    transition: all 0.3s ease;
}

.nationality-card:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-elevated);
}

.nationality-flag {
    font-size: 2.5rem;
}

@media (min-width: 768px) {
    .nationality-flag {
        font-size: 3rem;
    }
}

.nationality-name {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--muted-foreground);
    text-align: center;
}

@media (min-width: 768px) {
    .nationality-name {
        font-size: 0.875rem;
    }
}

/* ============================================
   CONTRACT SECTION
   ============================================ */
.contract-grid {
    display: grid;
    gap: 2rem;
}

@media (min-width: 1024px) {
    .contract-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.contract-card {
    background: var(--card);
    padding: 2rem;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-soft);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.contract-card.featured {
    border: 2px solid var(--secondary);
}

.contract-card.featured::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--cta-gradient);
}

.contract-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: var(--secondary);
    color: var(--secondary-foreground);
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
}

[dir="rtl"] .contract-badge {
    right: auto;
    left: 1rem;
}

.contract-duration {
    font-size: 3rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.contract-label {
    font-size: 1.125rem;
    color: var(--muted-foreground);
    margin-bottom: 1.5rem;
}

.contract-features {
    list-style: none;
    margin-bottom: 1.5rem;
}

.contract-features li {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0;
    font-size: 0.875rem;
    color: var(--foreground);
}

.contract-features li svg {
    color: var(--primary);
    flex-shrink: 0;
}

/* ============================================
   TESTIMONIALS
   ============================================ */
.testimonials-grid {
    display: grid;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .testimonials-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .testimonials-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.testimonial-card {
    background: var(--card);
    padding: 2rem;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-elevated);
    position: relative;
}

.testimonial-quote {
    position: absolute;
    top: 1rem;
    right: 1.5rem;
    font-size: 4rem;
    color: var(--primary);
    opacity: 0.1;
    font-family: Georgia, serif;
    line-height: 1;
}

[dir="rtl"] .testimonial-quote {
    right: auto;
    left: 1.5rem;
}

.testimonial-text {
    font-size: 1rem;
    color: var(--foreground);
    margin-bottom: 1.5rem;
    line-height: 1.7;
    position: relative;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.testimonial-avatar {
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    background: var(--primary);
    color: var(--primary-foreground);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 1.125rem;
}

.testimonial-info {
    flex: 1;
}

.testimonial-name {
    font-weight: 600;
    color: var(--foreground);
}

.testimonial-location {
    font-size: 0.875rem;
    color: var(--muted-foreground);
}

.testimonial-stars {
    color: var(--secondary);
    display: flex;
    gap: 0.125rem;
}

/* ============================================
   WHY APEX SECTION
   ============================================ */
.why-grid {
    display: grid;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .why-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .why-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.why-card {
    display: flex;
    gap: 1rem;
    padding: 1.5rem;
    background: var(--card);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-soft);
    transition: all 0.3s ease;
}

.why-card:hover {
    box-shadow: var(--shadow-elevated);
}

.why-icon {
    width: 3rem;
    height: 3rem;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: hsla(168, 65%, 35%, 0.1);
    border-radius: var(--radius);
    color: var(--primary);
}

.why-content h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--foreground);
    margin-bottom: 0.25rem;
}

.why-content p {
    font-size: 0.875rem;
    color: var(--muted-foreground);
}

/* ============================================
   FINAL CTA SECTION
   ============================================ */
.cta-section {
    background: var(--hero-gradient);
    padding: 4rem 0;
    text-align: center;
}

@media (min-width: 768px) {
    .cta-section {
        padding: 6rem 0;
    }
}

.cta-section .section-title,
.cta-section .section-subtitle {
    color: var(--primary-foreground);
}

.cta-section .section-subtitle {
    opacity: 0.9;
}

.cta-buttons {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    margin-top: 2rem;
}

@media (min-width: 640px) {
    .cta-buttons {
        flex-direction: row;
        justify-content: center;
    }
}

.cta-section .btn-primary {
    background: white;
    color: var(--primary);
}

.cta-section .btn-whatsapp {
    background: var(--whatsapp);
}

/* ============================================
   FOOTER
   ============================================ */
.site-footer {
    background: var(--foreground);
    color: var(--background);
    padding: 3rem 0 1.5rem;
}

.footer-content {
    display: grid;
    gap: 2rem;
    margin-bottom: 2rem;
}

@media (min-width: 768px) {
    .footer-content {
        grid-template-columns: repeat(3, 1fr);
    }
}

.footer-brand img {
    height: 2.5rem;
    margin-bottom: 1rem;
    filter: brightness(0) invert(1);
}

.footer-desc {
    font-size: 0.875rem;
    opacity: 0.8;
    line-height: 1.7;
}

.footer-title {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    font-size: 0.875rem;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.footer-links a:hover {
    opacity: 1;
}

.footer-contact-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
    font-size: 0.875rem;
}

.footer-contact-item svg {
    opacity: 0.8;
}

.footer-bottom {
    padding-top: 1.5rem;
    border-top: 1px solid hsla(40, 33%, 98%, 0.1);
    text-align: center;
    font-size: 0.875rem;
    opacity: 0.7;
}

/* ============================================
   FLOATING CTA
   ============================================ */
.floating-cta {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 50;
    display: flex;
    gap: 0.75rem;
    padding: 0.75rem;
    background: var(--card);
    border-radius: 9999px;
    box-shadow: var(--shadow-elevated);
}

[dir="rtl"] .floating-cta {
    right: auto;
    left: 1.5rem;
}

.floating-btn {
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.floating-btn:hover {
    transform: scale(1.1);
}

.floating-btn.phone {
    background: var(--cta-gradient);
    color: var(--foreground);
}

.floating-btn.whatsapp {
    background: var(--whatsapp);
    color: var(--whatsapp-foreground);
}

.floating-btn svg {
    width: 1.25rem;
    height: 1.25rem;
}

/* ============================================
   ANIMATIONS
   ============================================ */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

/* ============================================
   UTILITIES
   ============================================ */
.text-center { text-align: center; }
.text-primary { color: var(--primary); }
.text-muted { color: var(--muted-foreground); }
.mb-4 { margin-bottom: 1rem; }
.mb-8 { margin-bottom: 2rem; }
.hidden { display: none; }
.block { display: block; }

@media (min-width: 768px) {
    .md\:block { display: block; }
    .md\:hidden { display: none; }
}
