/* ========================================
   Landing Page Specific Styles
   ======================================== */

/* Performance Optimizations for Mobile */
* {
    -webkit-tap-highlight-color: rgba(61, 90, 148, 0.2);
}

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

/* Prevent text size adjustment on iOS */
html {
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

/* Prevent breaking of specific text like ISI- Scopus (Q1-Q2-Q3-Q4) */
.no-break-text {
    white-space: nowrap;
    display: inline-block;
}

/* Safe area insets for iPhone X and newer */
@supports (padding: max(0px)) {
    .navbar,
    .footer {
        padding-left: max(var(--spacing-md), env(safe-area-inset-left));
        padding-right: max(var(--spacing-md), env(safe-area-inset-right));
    }
    
    .scroll-to-top {
        left: max(1rem, env(safe-area-inset-left));
        bottom: max(1rem, env(safe-area-inset-bottom));
    }
}

/* Navbar */
.navbar {
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 0.25rem 0;
    transition: all var(--transition-base);
    border-bottom: 1px solid transparent;
}

.navbar.scrolled {
    background-color: rgba(255, 255, 255, 0.98);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    padding: 0.15rem 0;
    border-bottom-color: rgba(61, 90, 148, 0.1);
}

.navbar.scrolled .brand-logo {
    height: 36px !important;
    max-height: 36px;
}

.navbar.scrolled .nav-brand {
    height: 36px;
}

.navbar .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--spacing-lg);
    flex-wrap: nowrap;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    font-size: var(--font-size-xl);
    font-weight: 700;
    color: var(--primary-color);
    transition: transform var(--transition-base);
    cursor: pointer;
    padding: 0;
    margin: 0;
    line-height: 1;
    height: 42px;
}

.nav-brand:hover {
    transform: scale(1.05);
}

.brand-logo {
    height: 42px !important;
    width: auto;
    max-height: 42px;
    object-fit: cover;
    object-position: center;
    transition: all var(--transition-base);
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
    display: block;
    margin: 0;
    padding: 0;
    line-height: 1;
}

.nav-brand:hover .brand-logo {
    filter: drop-shadow(0 4px 8px rgba(61, 90, 148, 0.2));
}

.commercial-registry {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.7rem;
    font-weight: 400;
    color: var(--text-color);
    margin-right: var(--spacing-sm);
    white-space: nowrap;
}

.commercial-registry i {
    color: var(--primary-color);
    font-size: 0.8rem;
}

.cr-label {
    font-weight: 400;
    color: var(--text-color);
}

.cr-number {
    font-weight: 400;
    color: var(--text-color);
    direction: ltr;
    display: inline-block;
}

@media (max-width: 768px) {
    .commercial-registry {
        font-size: 0.65rem;
        margin-right: var(--spacing-xs);
        gap: 0.25rem;
    }
    
    .commercial-registry i {
        font-size: 0.75rem;
    }
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: var(--spacing-md);
    margin: 0;
    align-items: center;
    flex-wrap: nowrap;
}

.nav-menu li {
    position: relative;
}

.nav-menu a {
    color: var(--text-primary);
    font-weight: 600;
    transition: all var(--transition-base);
    position: relative;
    padding: var(--spacing-xs) var(--spacing-md);
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    border-radius: var(--radius-md);
    font-size: var(--font-size-base);
    min-height: 38px;
    -webkit-tap-highlight-color: rgba(61, 90, 148, 0.2);
    touch-action: manipulation;
}

.nav-menu a i {
    font-size: 0.875rem;
    opacity: 0.7;
    transition: all var(--transition-base);
}

.nav-menu a span {
    position: relative;
    z-index: 1;
}

.nav-menu a::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 0;
    height: 100%;
    background: linear-gradient(135deg, rgba(61, 90, 148, 0.1), rgba(232, 154, 60, 0.1));
    border-radius: var(--radius-md);
    transition: width var(--transition-base);
    z-index: 0;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 50%;
    transform: translateX(50%);
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    border-radius: var(--radius-full);
    transition: width var(--transition-base);
    z-index: 1;
}

.nav-menu a:hover {
    color: var(--primary-color);
    transform: translateY(-2px);
}

.nav-menu a:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

.nav-menu a:hover::before {
    width: 100%;
}

.nav-menu a:hover::after {
    width: 60%;
}

.nav-menu a:hover i {
    opacity: 1;
    transform: scale(1.1);
    color: var(--secondary-color);
}

.nav-menu a.active {
    color: var(--primary-color);
}

.nav-menu a.active::before {
    width: 100%;
    background: linear-gradient(135deg, rgba(61, 90, 148, 0.15), rgba(232, 154, 60, 0.15));
}

.nav-menu a.active::after {
    width: 60%;
}

.nav-menu a.active i {
    opacity: 1;
    color: var(--secondary-color);
}

.nav-actions {
    display: flex;
    gap: var(--spacing-sm);
    align-items: center;
    flex-wrap: nowrap;
}

.nav-actions .btn {
    white-space: nowrap;
    font-size: var(--font-size-sm);
    padding: 0.5rem 1rem;
    min-width: fit-content;
    min-height: 38px;
    -webkit-tap-highlight-color: rgba(61, 90, 148, 0.2);
    touch-action: manipulation;
}

.nav-actions .btn-outline {
    border-width: 2px;
}

.nav-actions .btn-primary {
    box-shadow: 0 4px 12px rgba(61, 90, 148, 0.25);
}

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-primary);
    padding: var(--spacing-xs);
    border-radius: var(--radius-md);
    transition: all var(--transition-base);
    width: 44px;
    height: 44px;
    min-width: 44px;
    min-height: 44px;
    align-items: center;
    justify-content: center;
    z-index: 1001;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

.mobile-menu-toggle:hover {
    background-color: var(--bg-secondary);
    color: var(--primary-color);
    transform: scale(1.1);
}

.mobile-menu-toggle:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

.mobile-menu-toggle:active {
    transform: scale(0.95);
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, #3D5A94 0%, #5176B8 50%, #3D5A94 100%);
    background-size: 200% 200%;
    animation: gradientShift 15s ease infinite;
    color: white;
    padding: 5rem 0;
    position: relative;
    overflow: hidden;
    min-height: 600px;
    display: flex;
    align-items: center;
}

@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 50%, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(232, 154, 60, 0.15) 0%, transparent 50%),
        url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 600"><path fill="rgba(255,255,255,0.05)" d="M0,300 Q300,150 600,300 T1200,300 L1200,600 L0,600 Z"/></svg>');
    background-size: cover, cover, cover;
    opacity: 1;
    animation: pulse 4s ease-in-out infinite;
}

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

.hero .container {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: var(--spacing-2xl);
    align-items: center;
    width: 100%;
}

.hero-content {
    animation: fadeInUp 0.8s ease;
}

.hero-title {
    font-size: 3rem;
    line-height: 1.3;
    margin-bottom: var(--spacing-lg);
    font-weight: 900;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    animation: fadeInUp 0.8s ease 0.2s both;
}

.hero-title .highlight {
    color: #E89A3C;
    background: linear-gradient(135deg, #E89A3C, #FFB84D);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: inline-block;
    animation: shimmer 3s ease-in-out infinite;
}

@keyframes shimmer {
    0%, 100% {
        filter: brightness(1);
    }
    50% {
        filter: brightness(1.2);
    }
}

.hero-description {
    font-size: var(--font-size-lg);
    line-height: 1.7;
    margin-bottom: var(--spacing-xl);
    opacity: 0.95;
    animation: fadeInUp 0.8s ease 0.4s both;
    text-shadow: 0 1px 5px rgba(0, 0, 0, 0.1);
    max-width: 95%;
}

.hero-actions {
    display: flex;
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-xl);
    flex-wrap: wrap;
    animation: fadeInUp 0.8s ease 0.6s both;
    align-items: center;
}

.hero-actions .btn {
    position: relative;
    overflow: hidden;
    transition: all var(--transition-base);
}

.hero-actions .btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.hero-actions .btn:hover::before {
    width: 300px;
    height: 300px;
}

.hero-actions .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
}

/* Hero Image with Floating Cards */
.hero-image {
    position: relative;
    height: 400px;
    animation: fadeInUp 0.8s ease 0.8s both;
}

.floating-card {
    position: absolute;
    background-color: white;
    color: var(--text-primary);
    padding: var(--spacing-lg);
    border-radius: var(--radius-xl);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    font-weight: 600;
    animation: float 3s ease-in-out infinite;
    transition: all var(--transition-base);
    cursor: pointer;
}

.floating-card:hover,
.floating-card:focus {
    transform: translateY(-10px) scale(1.05);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.2);
    background: linear-gradient(135deg, white, rgba(61, 90, 148, 0.05));
    outline: none;
}

.floating-card i {
    font-size: 2rem;
    color: var(--primary-color);
}

.card-1 {
    top: 10%;
    right: 10%;
    animation-delay: 0s;
}

.card-2 {
    top: 45%;
    right: 30%;
    animation-delay: 1s;
}

.card-3 {
    bottom: 10%;
    right: 5%;
    animation-delay: 2s;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    25% {
        transform: translateY(-15px) rotate(2deg);
    }
    50% {
        transform: translateY(-25px) rotate(0deg);
    }
    75% {
        transform: translateY(-15px) rotate(-2deg);
    }
}

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

.animate-in {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

/* Loading Animation */
@keyframes skeleton {
    0% {
        background-position: -200px 0;
    }
    100% {
        background-position: calc(200px + 100%) 0;
    }
}

.skeleton {
    animation: skeleton 1.5s ease-in-out infinite;
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200px 100%;
}

/* Features Section */
.features {
    background-color: var(--bg-secondary);
}

.section-header {
    text-align: center;
    margin-bottom: var(--spacing-2xl);
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.section-title {
    font-size: var(--font-size-3xl);
    color: var(--text-primary);
    margin-bottom: var(--spacing-md);
}

.section-description {
    font-size: var(--font-size-lg);
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--spacing-lg);
}

.feature-card {
    background-color: var(--bg-primary);
    padding: var(--spacing-xl);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-sm);
    transition: all var(--transition-base);
    text-align: center;
    border: 2px solid transparent;
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(61, 90, 148, 0.1), transparent);
    transition: left 0.5s;
}

.feature-card:hover::before {
    left: 100%;
}

.feature-card:hover,
.feature-card:focus {
    transform: translateY(-8px) scale(1.02);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary-light);
    background: linear-gradient(135deg, var(--bg-primary) 0%, rgba(61, 90, 148, 0.02) 100%);
    outline: none;
}

.feature-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    color: white;
    border-radius: var(--radius-xl);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.25rem;
    margin: 0 auto var(--spacing-lg);
    transition: all var(--transition-base);
    position: relative;
    box-shadow: 0 4px 15px rgba(61, 90, 148, 0.3);
}

.feature-card:hover .feature-icon {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 6px 20px rgba(61, 90, 148, 0.4);
    background: linear-gradient(135deg, var(--primary-light), var(--secondary-color));
}

.feature-card h3 {
    font-size: var(--font-size-xl);
    margin-bottom: var(--spacing-md);
}

.feature-card p {
    color: var(--text-secondary);
    line-height: 1.8;
    margin: 0;
    transition: color var(--transition-base);
}

.feature-card:hover p {
    color: var(--text-primary);
}

/* How It Works Section */
.how-it-works {
    background-color: var(--bg-primary);
}

.steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: var(--spacing-lg);
    margin-top: var(--spacing-2xl);
}

.step {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    position: relative;
    padding: var(--spacing-lg);
    transition: all var(--transition-base);
}

.step::before {
    content: '';
    position: absolute;
    top: 30px;
    right: -50%;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--primary-light), transparent);
    opacity: 0.3;
    z-index: 0;
}

.step:first-child::before {
    display: none;
}

.step:last-child::before {
    display: none;
}

/* تعريف الأسهم - إخفاء افتراضي */
.step::after {
    display: none;
    content: '';
    position: absolute;
    top: 20px;
    right: -20px;
    font-size: 1.5rem;
    color: var(--primary-light);
    opacity: 0.5;
    z-index: 1;
    transition: all var(--transition-base);
}

/* إظهار الأسهم بعد الخطوات 1، 2، 3 فقط (بين 1-2، 2-3، 3-4) */
.step:nth-child(1)::after {
    display: block !important;
    content: '←' !important;
}

.step:nth-child(2)::after {
    display: block !important;
    content: '←' !important;
}

.step:nth-child(3)::after {
    display: block !important;
    content: '←' !important;
}

.step:hover::after {
    opacity: 1 !important;
    transform: translateX(5px);
    color: var(--secondary-color);
}

/* إخفاء السهم بعد الخطوة الرابعة (الأخيرة) */
.step:nth-child(4)::after,
.step:last-child::after {
    display: none !important;
    content: '' !important;
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
}

.step:nth-child(4):hover::after,
.step:last-child:hover::after {
    display: none !important;
    content: '' !important;
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
}

.step:hover,
.step:focus {
    transform: translateY(-5px);
    outline: none;
}

.step-number {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--font-size-2xl);
    font-weight: 900;
    margin-bottom: var(--spacing-lg);
    position: relative;
    z-index: 2;
    transition: all var(--transition-base);
    box-shadow: 0 4px 15px rgba(61, 90, 148, 0.3);
}

.step:hover .step-number {
    transform: scale(1.15) rotate(360deg);
    box-shadow: 0 6px 20px rgba(61, 90, 148, 0.5);
    background: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
}

.step-content h3 {
    font-size: var(--font-size-xl);
    margin-bottom: var(--spacing-sm);
}

.step-content p {
    color: var(--text-secondary);
    margin: 0;
    transition: color var(--transition-base);
}

.step:hover .step-content p {
    color: var(--text-primary);
}

/* Stats Section */
.stats-section {
    background: linear-gradient(135deg, #3D5A94 0%, #5176B8 100%);
    color: white;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: var(--spacing-xl);
}

.stat-box {
    text-align: center;
    padding: var(--spacing-xl);
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-lg);
    backdrop-filter: blur(10px);
    transition: all var(--transition-base);
}

.stat-box:hover {
    background-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-5px);
}

.stat-box i {
    font-size: 3rem;
    margin-bottom: var(--spacing-md);
    color: #E89A3C;
}

.stat-value {
    font-size: var(--font-size-4xl);
    font-weight: 900;
    display: block;
    margin-bottom: var(--spacing-sm);
}

.stat-box p {
    margin: 0;
    font-size: var(--font-size-lg);
    opacity: 0.9;
}

/* CTA Section */
.cta-section {
    background-color: var(--bg-secondary);
    text-align: center;
    padding: 5rem 0;
}

.cta-section h2 {
    font-size: var(--font-size-3xl);
    margin-bottom: var(--spacing-md);
}

.cta-section p {
    font-size: var(--font-size-lg);
    color: var(--text-secondary);
    margin-bottom: var(--spacing-xl);
}

/* Footer */
.footer {
    background-color: var(--bg-dark);
    color: white;
    padding: var(--spacing-lg) 0 var(--spacing-sm);
    margin-top: var(--spacing-lg);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-md);
}

.footer-section h3,
.footer-section h4 {
    margin-bottom: var(--spacing-sm);
    color: white;
    font-size: var(--font-size-base);
    font-weight: 600;
}

.footer-section p {
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.5;
    font-size: var(--font-size-xs);
    margin-bottom: 0;
}

.footer-section ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.footer-section ul li {
    margin-bottom: 0.375rem;
}

.footer-section ul li a {
    color: rgba(255, 255, 255, 0.7);
    transition: color var(--transition-fast);
    font-size: var(--font-size-sm);
}

.footer-section ul li a:hover {
    color: white;
}

.contact-info li {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    margin-bottom: 0.375rem;
}

.contact-info li i {
    font-size: 0.875rem;
    width: 16px;
    flex-shrink: 0;
}

.contact-info li a {
    font-size: var(--font-size-sm);
}

.social-links {
    display: flex;
    gap: var(--spacing-xs);
    margin-top: var(--spacing-sm);
}

.social-links a {
    width: 32px;
    height: 32px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-base);
    font-size: 0.75rem;
}

.social-links a:hover {
    background-color: var(--primary-color);
    transform: translateY(-3px);
}

.footer-bottom {
    text-align: center;
    padding-top: var(--spacing-sm);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom-content {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: var(--spacing-sm);
}

.footer-bottom p {
    margin: 0;
    color: rgba(255, 255, 255, 0.5);
    font-size: var(--font-size-xs);
    line-height: 1.4;
    text-align: center;
}

.developer-credit-inline {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-sm);
}

.developer-credit-inline .developer-credit-content {
    display: inline-flex;
    align-items: center;
    gap: var(--spacing-xs);
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: var(--font-size-xs);
    transition: color var(--transition-fast);
    line-height: 1.4;
}

.developer-credit-inline .developer-credit-content:hover {
    color: rgba(255, 255, 255, 0.9);
}

.developer-credit-inline .developer-logo {
    height: 10px;
    width: auto;
    object-fit: contain;
}

.developer-credit-inline .developer-name {
    font-weight: 600;
    margin-left: var(--spacing-xs);
}

.developer-credit-inline .developer-text {
    margin-right: var(--spacing-xs);
    font-size: var(--font-size-xs);
}

/* Scroll to Top Button */
.scroll-to-top {
    position: fixed;
    bottom: 2rem;
    left: 2rem;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    box-shadow: 0 4px 15px rgba(61, 90, 148, 0.3);
    transition: all var(--transition-base);
    z-index: 999;
    opacity: 0;
    transform: translateY(20px);
}

.scroll-to-top.visible {
    display: flex;
    opacity: 1;
    transform: translateY(0);
}

.scroll-to-top:focus {
    outline: 2px solid white;
    outline-offset: 2px;
}

.scroll-to-top:hover {
    transform: translateY(-5px) scale(1.1);
    box-shadow: 0 6px 20px rgba(61, 90, 148, 0.4);
    background: linear-gradient(135deg, var(--primary-dark), var(--secondary-dark));
}

/* Responsive Design */

/* Large Desktop (1400px+) */
@media (min-width: 1400px) {
    .container {
        max-width: 1320px;
    }
    
    .hero-title {
        font-size: 3.5rem;
    }
}

/* Desktop (1200px - 1399px) */
@media (max-width: 1399px) and (min-width: 1200px) {
    .container {
        max-width: 1140px;
    }
}

/* Tablet Landscape & Small Desktop (992px - 1199px) */
@media (max-width: 1199px) and (min-width: 992px) {
    .navbar .container {
        gap: var(--spacing-md);
    }
    
    .nav-menu {
        gap: var(--spacing-sm);
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero {
        padding: 4rem 0;
        min-height: 550px;
    }
    
    .hero .container {
        grid-template-columns: 1.1fr 0.9fr;
        gap: var(--spacing-xl);
    }
    
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Tablet Portrait & Small Desktop (768px - 991px) */
@media (max-width: 991px) and (min-width: 768px) {
    .navbar .container {
        gap: var(--spacing-md);
        padding: 0 var(--spacing-lg);
    }
    
    .nav-menu {
        gap: var(--spacing-sm);
    }
    
    .nav-menu a {
        padding: var(--spacing-xs) var(--spacing-sm);
        font-size: var(--font-size-sm);
        min-height: 44px;
    }
    
    .nav-actions .btn {
        padding: 0.625rem 1rem;
        font-size: var(--font-size-sm);
        min-height: 44px;
    }
    
    .hero {
        padding: 3.5rem 0;
        min-height: 500px;
    }
    
    .hero .container {
        grid-template-columns: 1fr;
        gap: var(--spacing-xl);
        padding: 0 var(--spacing-lg);
    }
    
    .hero-content {
        text-align: center;
    }
    
    .hero-title {
        font-size: 2.25rem;
        line-height: 1.3;
        margin-bottom: var(--spacing-md);
    }
    
    .hero-description {
        font-size: var(--font-size-lg);
        line-height: 1.7;
        margin-bottom: var(--spacing-xl);
        max-width: 90%;
        margin-left: auto;
        margin-right: auto;
    }
    
    .hero-actions {
        justify-content: center;
        gap: var(--spacing-md);
    }
    
    .hero-actions .btn {
        min-height: 50px;
        padding: var(--spacing-md) var(--spacing-xl);
    }
    
    .hero-image {
        height: 300px;
        display: block;
        margin-top: var(--spacing-lg);
    }
    
    .floating-card {
        padding: var(--spacing-md);
        font-size: var(--font-size-sm);
    }
    
    .floating-card i {
        font-size: 1.5rem;
    }
    
    .section-header {
        margin-bottom: var(--spacing-xl);
    }
    
    .section-title {
        font-size: var(--font-size-3xl);
    }
    
    .section-description {
        font-size: var(--font-size-lg);
    }
    
    .features {
        padding: var(--spacing-2xl) 0;
    }
    
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-lg);
    }
    
    .feature-card {
        padding: var(--spacing-xl);
    }
    
    .how-it-works {
        padding: var(--spacing-2xl) 0;
    }
    
    .steps {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-lg);
    }
    
    /* إظهار الأسهم بين 1-2، 2-3، 3-4 في الشاشات المتوسطة أيضاً */
    .steps .step:nth-child(1)::after,
    .steps .step:nth-child(2)::after,
    .steps .step:nth-child(3)::after {
        display: block !important;
        content: '←' !important;
    }
    
    /* إخفاء السهم بعد step 4 فقط */
    .steps .step:nth-child(4)::after,
    .steps .step:last-child::after {
        display: none !important;
    }
    
    .stats-section {
        padding: var(--spacing-xl) 0;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-lg);
    }
    
    .cta-section {
        padding: var(--spacing-2xl) 0;
    }
    
    .footer {
        padding: var(--spacing-xl) 0;
    }
    
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-lg);
    }
}

/* Mobile Landscape & Small Tablet (576px - 767px) */
@media (max-width: 767px) and (min-width: 576px) {
    .navbar .container {
        padding: 0 var(--spacing-md);
    }
    
    .hero {
        padding: 2.5rem 0;
    }
    
    .hero .container {
        padding: 0 var(--spacing-md);
    }
    
    .hero-title {
        font-size: 2rem;
        line-height: 1.3;
        margin-bottom: var(--spacing-md);
    }
    
    .hero-description {
        font-size: var(--font-size-base);
        line-height: 1.7;
        margin-bottom: var(--spacing-lg);
    }
    
    .hero-actions {
        flex-direction: row;
        flex-wrap: wrap;
        gap: var(--spacing-md);
    }
    
    .hero-actions .btn {
        flex: 1;
        min-width: 200px;
        min-height: 50px;
    }
    
    .section-header {
        margin-bottom: var(--spacing-xl);
    }
    
    .section-title {
        font-size: var(--font-size-2xl);
    }
    
    .section-description {
        font-size: var(--font-size-base);
    }
    
    .features {
        padding: var(--spacing-xl) 0;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-lg);
    }
    
    .feature-card {
        padding: var(--spacing-xl);
    }
    
    .how-it-works {
        padding: var(--spacing-xl) 0;
    }
    
    .steps {
        grid-template-columns: 1fr;
        gap: var(--spacing-lg);
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-md);
    }
    
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-md);
    }
}


/* Mobile Portrait (up to 767px) */
@media (max-width: 767px) {
    .navbar {
        padding: 0.2rem 0;
    }
    
    .navbar.scrolled {
        padding: 0.15rem 0;
    }
    
    .navbar .container {
        flex-wrap: wrap;
        gap: var(--spacing-sm);
        padding: 0 var(--spacing-md);
    }
    
    .nav-brand {
        font-size: var(--font-size-lg);
        flex: 1;
        min-width: 0;
    }
    
    .brand-logo {
        height: 36px;
        max-width: 120px;
        width: auto;
    }
    
    .navbar.scrolled .brand-logo {
        height: 30px;
    }
    
    .nav-menu,
    .nav-actions {
        display: none;
    }
    
    .nav-menu.active {
        display: flex;
        flex-direction: column;
        width: 100%;
        order: 3;
        margin-top: var(--spacing-sm);
        padding: var(--spacing-md);
        border-top: 1px solid var(--border-color);
        background: var(--bg-primary);
        border-radius: var(--radius-lg);
        box-shadow: var(--shadow-md);
        animation: slideDown 0.3s ease;
        gap: var(--spacing-xs);
        max-height: calc(100vh - 100px);
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    .nav-menu.active li {
        width: 100%;
    }
    
    .nav-menu.active a {
        width: 100%;
        justify-content: flex-start;
        padding: var(--spacing-md) var(--spacing-lg);
        border-radius: var(--radius-md);
        font-size: var(--font-size-base);
        min-height: 48px; /* Touch target */
        font-weight: 600;
    }
    
    @keyframes slideDown {
        from {
            opacity: 0;
            transform: translateY(-10px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }
    
    .nav-actions.active {
        display: flex;
        flex-direction: column;
        width: 100%;
        order: 4;
        gap: var(--spacing-sm);
        margin-top: var(--spacing-sm);
        padding: var(--spacing-md);
        background: var(--bg-primary);
        border-radius: var(--radius-lg);
        box-shadow: var(--shadow-md);
        animation: slideDown 0.3s ease 0.1s both;
    }
    
    .nav-actions.active .btn {
        width: 100%;
        justify-content: center;
        padding: var(--spacing-md) var(--spacing-lg);
        font-size: var(--font-size-base);
        min-height: 48px; /* Touch target */
        font-weight: 600;
    }
    
    .mobile-menu-toggle {
        display: flex;
        order: 2;
        transition: transform var(--transition-base);
        min-width: 44px;
        min-height: 44px;
        flex-shrink: 0;
    }
    
    .mobile-menu-toggle.active {
        transform: rotate(90deg);
    }
    
    .hero {
        padding: 2.5rem 0;
        min-height: auto;
    }
    
    .hero .container {
        padding: 0 var(--spacing-md);
        grid-template-columns: 1fr;
        gap: var(--spacing-xl);
    }
    
    .hero-content {
        text-align: center;
    }
    
    .hero-title {
        font-size: 1.75rem;
        line-height: 1.4;
        margin-bottom: var(--spacing-md);
        padding: 0;
    }
    
    .hero-description {
        font-size: var(--font-size-base);
        line-height: 1.7;
        margin-bottom: var(--spacing-xl);
        padding: 0;
        text-align: center;
    }
    
    .hero-actions {
        flex-direction: column;
        width: 100%;
        gap: var(--spacing-md);
        align-items: stretch;
    }
    
    .hero-actions .btn {
        width: 100%;
        justify-content: center;
        min-height: 52px; /* Touch target */
        padding: var(--spacing-md) var(--spacing-lg);
        font-size: var(--font-size-base);
        font-weight: 600;
    }
    
    .hero-image {
        display: none;
    }
    
    .section-header {
        margin-bottom: var(--spacing-xl);
        padding: 0 var(--spacing-sm);
    }
    
    .section-title {
        font-size: var(--font-size-2xl);
        margin-bottom: var(--spacing-md);
        line-height: 1.3;
    }
    
    .section-description {
        font-size: var(--font-size-base);
        line-height: 1.6;
        padding: 0 var(--spacing-sm);
    }
    
    .features {
        padding: var(--spacing-xl) 0;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-lg);
        padding: 0 var(--spacing-sm);
    }
    
    .feature-card {
        padding: var(--spacing-xl);
        text-align: center;
    }
    
    .feature-icon {
        width: 70px;
        height: 70px;
        font-size: 2rem;
        margin-bottom: var(--spacing-lg);
    }
    
    .feature-card h3 {
        font-size: var(--font-size-xl);
        margin-bottom: var(--spacing-md);
    }
    
    .feature-card p {
        font-size: var(--font-size-base);
        line-height: 1.7;
    }
    
    .how-it-works {
        padding: var(--spacing-xl) 0;
    }
    
    .steps {
        grid-template-columns: 1fr;
        gap: var(--spacing-xl);
        padding: 0 var(--spacing-sm);
    }
    
    .step {
        padding: var(--spacing-lg);
    }
    
    .step::before {
        display: none;
    }
    
    .step::after {
        display: none !important;
    }
    
    .step-number {
        width: 60px;
        height: 60px;
        font-size: var(--font-size-2xl);
        margin-bottom: var(--spacing-lg);
    }
    
    .step-content h3 {
        font-size: var(--font-size-xl);
        margin-bottom: var(--spacing-sm);
    }
    
    .step-content p {
        font-size: var(--font-size-base);
        line-height: 1.7;
    }
    
    .stats-section {
        padding: var(--spacing-xl) 0;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-md);
        padding: 0 var(--spacing-sm);
    }
    
    .stat-box {
        padding: var(--spacing-lg);
    }
    
    .stat-box i {
        font-size: 2.5rem;
        margin-bottom: var(--spacing-sm);
    }
    
    .stat-value {
        font-size: var(--font-size-3xl);
        margin-bottom: var(--spacing-xs);
    }
    
    .stat-box p {
        font-size: var(--font-size-base);
    }
    
    .cta-section {
        padding: var(--spacing-2xl) 0;
        text-align: center;
    }
    
    .cta-section h2 {
        font-size: var(--font-size-2xl);
        margin-bottom: var(--spacing-md);
        padding: 0 var(--spacing-sm);
    }
    
    .cta-section p {
        font-size: var(--font-size-base);
        margin-bottom: var(--spacing-xl);
        padding: 0 var(--spacing-sm);
    }
    
    .footer {
        padding: var(--spacing-xl) 0 var(--spacing-md);
        margin-top: var(--spacing-xl);
    }
    
    .footer .container {
        padding: 0 var(--spacing-md);
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: var(--spacing-lg);
        margin-bottom: var(--spacing-lg);
    }
    
    .footer-section {
        text-align: center;
    }
    
    .footer-section h3,
    .footer-section h4 {
        font-size: var(--font-size-lg);
        margin-bottom: var(--spacing-md);
        font-weight: 700;
    }
    
    .footer-section p {
        font-size: var(--font-size-sm);
        line-height: 1.7;
        margin-bottom: var(--spacing-md);
    }
    
    .footer-section ul {
        margin-bottom: var(--spacing-md);
    }
    
    .footer-section ul li {
        margin-bottom: var(--spacing-sm);
    }
    
    .footer-section ul li a {
        font-size: var(--font-size-base);
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
        padding: var(--spacing-xs) 0;
    }
    
    .footer-logo {
        max-width: 150px !important;
        margin: 0 auto var(--spacing-md) !important;
    }
    
    .contact-info li {
        justify-content: center;
        margin-bottom: var(--spacing-sm);
        padding: var(--spacing-xs) 0;
    }
    
    .contact-info li a {
        font-size: var(--font-size-base);
    }
    
    .social-links {
        justify-content: center;
        margin-top: var(--spacing-md);
        gap: var(--spacing-sm);
    }
    
    .social-links a {
        min-width: 48px;
        min-height: 48px;
        font-size: 1rem;
    }
    
    .footer-bottom {
        padding-top: var(--spacing-md);
    }
    
    .footer-bottom-content {
        flex-direction: column;
        text-align: center;
        gap: var(--spacing-sm);
    }
    
    .footer-bottom p {
        font-size: var(--font-size-sm);
        line-height: 1.6;
    }
    
    .developer-credit-inline {
        flex-direction: column;
        gap: var(--spacing-xs);
        text-align: center;
    }
    
    .developer-credit-inline .developer-credit-content {
        font-size: var(--font-size-xs);
        padding: var(--spacing-xs) 0;
    }
    
    .scroll-to-top {
        width: 50px;
        height: 50px;
        bottom: 1.5rem;
        left: 1.5rem;
        font-size: 1.125rem;
        box-shadow: 0 4px 15px rgba(61, 90, 148, 0.4);
    }
    
    .scroll-to-top:hover {
        transform: translateY(-3px) scale(1.05);
    }
}

/* Small Mobile (up to 480px) */
@media (max-width: 480px) {
    .navbar .container {
        padding: 0 var(--spacing-sm);
        gap: var(--spacing-xs);
    }
    
    .brand-logo {
        height: 34px;
        max-width: 110px;
    }
    
    .navbar.scrolled .brand-logo {
        height: 28px;
    }
    
    .mobile-menu-toggle {
        min-width: 40px;
        min-height: 40px;
        font-size: 1.25rem;
    }
    
    .hero {
        padding: 2rem 0;
    }
    
    .hero .container {
        padding: 0 var(--spacing-sm);
        gap: var(--spacing-lg);
    }
    
    .hero-title {
        font-size: 1.5rem;
        line-height: 1.4;
        margin-bottom: var(--spacing-md);
        padding: 0;
    }
    
    .hero-description {
        font-size: var(--font-size-sm);
        line-height: 1.7;
        margin-bottom: var(--spacing-lg);
        padding: 0;
    }
    
    .hero-actions {
        gap: var(--spacing-sm);
    }
    
    .hero-actions .btn {
        padding: var(--spacing-md) var(--spacing-lg);
        font-size: var(--font-size-sm);
        min-height: 50px;
        font-weight: 600;
    }
    
    .section-header {
        margin-bottom: var(--spacing-lg);
        padding: 0;
    }
    
    .section-title {
        font-size: var(--font-size-xl);
        margin-bottom: var(--spacing-sm);
        line-height: 1.3;
    }
    
    .section-description {
        font-size: var(--font-size-sm);
        line-height: 1.6;
        padding: 0;
    }
    
    .features {
        padding: var(--spacing-lg) 0;
    }
    
    .features-grid {
        gap: var(--spacing-md);
        padding: 0;
    }
    
    .feature-card {
        padding: var(--spacing-lg);
    }
    
    .feature-icon {
        width: 60px;
        height: 60px;
        font-size: 1.75rem;
        margin-bottom: var(--spacing-md);
    }
    
    .feature-card h3 {
        font-size: var(--font-size-lg);
        margin-bottom: var(--spacing-sm);
    }
    
    .feature-card p {
        font-size: var(--font-size-sm);
        line-height: 1.6;
    }
    
    .how-it-works {
        padding: var(--spacing-lg) 0;
    }
    
    .steps {
        gap: var(--spacing-lg);
        padding: 0;
    }
    
    .step {
        padding: var(--spacing-md);
    }
    
    .step-number {
        width: 55px;
        height: 55px;
        font-size: var(--font-size-xl);
        margin-bottom: var(--spacing-md);
    }
    
    .step-content h3 {
        font-size: var(--font-size-lg);
        margin-bottom: var(--spacing-xs);
    }
    
    .step-content p {
        font-size: var(--font-size-sm);
        line-height: 1.6;
    }
    
    .stats-section {
        padding: var(--spacing-lg) 0;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
        padding: 0;
    }
    
    .stat-box {
        padding: var(--spacing-md);
    }
    
    .stat-box i {
        font-size: 2rem;
        margin-bottom: var(--spacing-xs);
    }
    
    .stat-value {
        font-size: var(--font-size-2xl);
        margin-bottom: var(--spacing-xs);
    }
    
    .stat-box p {
        font-size: var(--font-size-sm);
    }
    
    .cta-section {
        padding: var(--spacing-xl) 0;
    }
    
    .cta-section h2 {
        font-size: var(--font-size-xl);
        margin-bottom: var(--spacing-sm);
        padding: 0;
    }
    
    .cta-section p {
        font-size: var(--font-size-sm);
        margin-bottom: var(--spacing-lg);
        padding: 0;
    }
    
    .footer {
        padding: var(--spacing-lg) 0 var(--spacing-md);
        margin-top: var(--spacing-lg);
    }
    
    .footer .container {
        padding: 0 var(--spacing-sm);
    }
    
    .footer-content {
        gap: var(--spacing-md);
        margin-bottom: var(--spacing-md);
    }
    
    .footer-section h3,
    .footer-section h4 {
        font-size: var(--font-size-base);
        margin-bottom: var(--spacing-sm);
    }
    
    .footer-section p {
        font-size: var(--font-size-xs);
        line-height: 1.6;
        margin-bottom: var(--spacing-sm);
    }
    
    .footer-section ul {
        margin-bottom: var(--spacing-sm);
    }
    
    .footer-section ul li {
        margin-bottom: var(--spacing-xs);
    }
    
    .footer-section ul li a {
        font-size: var(--font-size-sm);
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
        padding: var(--spacing-xs) 0;
    }
    
    .footer-logo {
        max-width: 130px !important;
        margin: 0 auto var(--spacing-sm) !important;
    }
    
    .contact-info li {
        margin-bottom: var(--spacing-xs);
        padding: var(--spacing-xs) 0;
    }
    
    .contact-info li a {
        font-size: var(--font-size-sm);
    }
    
    .social-links {
        margin-top: var(--spacing-sm);
        gap: var(--spacing-xs);
    }
    
    .social-links a {
        width: 44px;
        height: 44px;
        font-size: 0.875rem;
        min-width: 44px;
        min-height: 44px;
    }
    
    .footer-bottom {
        padding-top: var(--spacing-sm);
    }
    
    .footer-bottom-content {
        gap: var(--spacing-xs);
    }
    
    .footer-bottom p {
        font-size: var(--font-size-xs);
        line-height: 1.5;
    }
    
    .developer-credit-inline .developer-credit-content {
        font-size: 0.65rem;
        padding: var(--spacing-xs) 0;
        line-height: 1.4;
    }
    
    .scroll-to-top {
        width: 48px;
        height: 48px;
        bottom: 1.25rem;
        left: 1.25rem;
        font-size: 1rem;
    }
}

/* Extra Small Mobile (up to 360px) */
@media (max-width: 360px) {
    .navbar .container {
        padding: 0 var(--spacing-xs);
        gap: var(--spacing-xs);
    }
    
    .brand-logo {
        height: 32px;
        max-width: 100px;
    }
    
    .navbar.scrolled .brand-logo {
        height: 26px;
    }
    
    .mobile-menu-toggle {
        min-width: 38px;
        min-height: 38px;
        font-size: 1.125rem;
    }
    
    .hero {
        padding: 1.5rem 0;
    }
    
    .hero .container {
        padding: 0 var(--spacing-xs);
        gap: var(--spacing-md);
    }
    
    .hero-title {
        font-size: 1.25rem;
        line-height: 1.4;
        margin-bottom: var(--spacing-sm);
        padding: 0;
    }
    
    .hero-description {
        font-size: var(--font-size-xs);
        line-height: 1.6;
        margin-bottom: var(--spacing-md);
        padding: 0;
    }
    
    .hero-actions {
        gap: var(--spacing-xs);
    }
    
    .hero-actions .btn {
        padding: var(--spacing-sm) var(--spacing-md);
        font-size: var(--font-size-xs);
        min-height: 48px;
        font-weight: 600;
    }
    
    .section-header {
        margin-bottom: var(--spacing-md);
        padding: 0;
    }
    
    .section-title {
        font-size: var(--font-size-lg);
        margin-bottom: var(--spacing-xs);
        line-height: 1.3;
    }
    
    .section-description {
        font-size: var(--font-size-xs);
        line-height: 1.5;
        padding: 0;
    }
    
    .features {
        padding: var(--spacing-md) 0;
    }
    
    .features-grid {
        gap: var(--spacing-sm);
        padding: 0;
    }
    
    .feature-card {
        padding: var(--spacing-md);
    }
    
    .feature-icon {
        width: 50px;
        height: 50px;
        font-size: 1.5rem;
        margin-bottom: var(--spacing-sm);
    }
    
    .feature-card h3 {
        font-size: var(--font-size-base);
        margin-bottom: var(--spacing-xs);
    }
    
    .feature-card p {
        font-size: var(--font-size-xs);
        line-height: 1.5;
    }
    
    .how-it-works {
        padding: var(--spacing-md) 0;
    }
    
    .steps {
        gap: var(--spacing-md);
        padding: 0;
    }
    
    .step {
        padding: var(--spacing-sm);
    }
    
    .step-number {
        width: 45px;
        height: 45px;
        font-size: var(--font-size-lg);
        margin-bottom: var(--spacing-sm);
    }
    
    .step-content h3 {
        font-size: var(--font-size-base);
        margin-bottom: var(--spacing-xs);
    }
    
    .step-content p {
        font-size: var(--font-size-xs);
        line-height: 1.5;
    }
    
    .stats-section {
        padding: var(--spacing-md) 0;
    }
    
    .stats-grid {
        gap: var(--spacing-sm);
        padding: 0;
    }
    
    .stat-box {
        padding: var(--spacing-sm);
    }
    
    .stat-box i {
        font-size: 1.75rem;
        margin-bottom: var(--spacing-xs);
    }
    
    .stat-value {
        font-size: var(--font-size-xl);
        margin-bottom: var(--spacing-xs);
    }
    
    .stat-box p {
        font-size: var(--font-size-xs);
    }
    
    .cta-section {
        padding: var(--spacing-lg) 0;
    }
    
    .cta-section h2 {
        font-size: var(--font-size-lg);
        margin-bottom: var(--spacing-xs);
        padding: 0;
    }
    
    .cta-section p {
        font-size: var(--font-size-xs);
        margin-bottom: var(--spacing-md);
        padding: 0;
    }
    
    .footer {
        padding: var(--spacing-md) 0 var(--spacing-sm);
        margin-top: var(--spacing-md);
    }
    
    .footer .container {
        padding: 0 var(--spacing-xs);
    }
    
    .footer-content {
        gap: var(--spacing-sm);
        margin-bottom: var(--spacing-sm);
    }
    
    .footer-section h3,
    .footer-section h4 {
        font-size: var(--font-size-sm);
        margin-bottom: var(--spacing-xs);
    }
    
    .footer-section p {
        font-size: 0.65rem;
        line-height: 1.5;
        margin-bottom: var(--spacing-xs);
    }
    
    .footer-section ul {
        margin-bottom: var(--spacing-xs);
    }
    
    .footer-section ul li {
        margin-bottom: var(--spacing-xs);
    }
    
    .footer-section ul li a {
        font-size: var(--font-size-xs);
        min-height: 40px;
        display: flex;
        align-items: center;
        justify-content: center;
        padding: var(--spacing-xs) 0;
    }
    
    .footer-logo {
        max-width: 110px !important;
        margin: 0 auto var(--spacing-xs) !important;
    }
    
    .contact-info li {
        margin-bottom: var(--spacing-xs);
        padding: var(--spacing-xs) 0;
    }
    
    .contact-info li a {
        font-size: var(--font-size-xs);
    }
    
    .social-links {
        margin-top: var(--spacing-xs);
        gap: var(--spacing-xs);
    }
    
    .social-links a {
        width: 40px;
        height: 40px;
        font-size: 0.75rem;
        min-width: 40px;
        min-height: 40px;
    }
    
    .footer-bottom {
        padding-top: var(--spacing-xs);
    }
    
    .footer-bottom-content {
        gap: var(--spacing-xs);
    }
    
    .footer-bottom p {
        font-size: 0.65rem;
        line-height: 1.4;
    }
    
    .developer-credit-inline .developer-credit-content {
        font-size: 0.6rem;
        padding: var(--spacing-xs) 0;
        line-height: 1.3;
    }
    
    .scroll-to-top {
        width: 44px;
        height: 44px;
        bottom: 1rem;
        left: 1rem;
        font-size: 0.875rem;
    }
}

/* Landscape Orientation for Mobile */
@media (max-width: 767px) and (orientation: landscape) {
    .navbar {
        padding: 0.15rem 0;
    }
    
    .navbar.scrolled {
        padding: 0.1rem 0;
    }
    
    .brand-logo {
        height: 34px;
    }
    
    .hero {
        padding: 1.5rem 0;
        min-height: auto;
    }
    
    .hero .container {
        gap: var(--spacing-md);
    }
    
    .hero-title {
        font-size: 1.5rem;
        line-height: 1.3;
        margin-bottom: var(--spacing-sm);
    }
    
    .hero-description {
        font-size: var(--font-size-sm);
        line-height: 1.6;
        margin-bottom: var(--spacing-md);
    }
    
    .hero-actions {
        flex-direction: row;
        gap: var(--spacing-sm);
        flex-wrap: wrap;
    }
    
    .hero-actions .btn {
        flex: 1;
        min-width: 150px;
        min-height: 48px;
    }
    
    .section-header {
        margin-bottom: var(--spacing-md);
    }
    
    .section-title {
        font-size: var(--font-size-xl);
    }
    
    .features {
        padding: var(--spacing-lg) 0;
    }
    
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-md);
    }
    
    .how-it-works {
        padding: var(--spacing-lg) 0;
    }
    
    .steps {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-md);
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-sm);
    }
    
    .footer {
        padding: var(--spacing-md) 0;
    }
}

/* iPad Specific (768px - 1024px) */
@media (min-width: 768px) and (max-width: 1024px) {
    .navbar .container {
        padding: 0 var(--spacing-lg);
    }
    
    .nav-menu {
        gap: var(--spacing-sm);
    }
    
    .nav-menu a {
        padding: var(--spacing-xs) var(--spacing-sm);
        font-size: var(--font-size-sm);
    }
    
    .nav-actions .btn {
        padding: 0.625rem 1rem;
        font-size: var(--font-size-sm);
    }
    
    .hero {
        padding: 3.5rem 0;
        min-height: 500px;
    }
    
    .hero .container {
        grid-template-columns: 1fr;
        gap: var(--spacing-xl);
        padding: 0 var(--spacing-lg);
    }
    
    .hero-content {
        text-align: center;
    }
    
    .hero-title {
        font-size: 2.25rem;
        line-height: 1.3;
        margin-bottom: var(--spacing-md);
    }
    
    .hero-description {
        font-size: var(--font-size-lg);
        line-height: 1.7;
        margin-bottom: var(--spacing-xl);
        max-width: 90%;
        margin-left: auto;
        margin-right: auto;
    }
    
    .hero-actions {
        justify-content: center;
        gap: var(--spacing-md);
    }
    
    .hero-actions .btn {
        min-height: 50px;
        padding: var(--spacing-md) var(--spacing-xl);
    }
    
    .hero-image {
        height: 250px;
        margin-top: var(--spacing-lg);
        display: block;
    }
    
    .floating-card {
        padding: var(--spacing-sm);
        font-size: var(--font-size-xs);
    }
    
    .floating-card i {
        font-size: 1.25rem;
    }
    
    .section-header {
        margin-bottom: var(--spacing-xl);
    }
    
    .section-title {
        font-size: var(--font-size-3xl);
    }
    
    .section-description {
        font-size: var(--font-size-lg);
    }
    
    .features {
        padding: var(--spacing-2xl) 0;
    }
    
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-lg);
    }
    
    .feature-card {
        padding: var(--spacing-xl);
    }
    
    .how-it-works {
        padding: var(--spacing-2xl) 0;
    }
    
    .steps {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-lg);
    }
    
    .step {
        padding: var(--spacing-lg);
    }
    
    .stats-section {
        padding: var(--spacing-xl) 0;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-lg);
    }
    
    .cta-section {
        padding: var(--spacing-2xl) 0;
    }
    
    .footer {
        padding: var(--spacing-xl) 0;
    }
    
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-lg);
    }
}

/* iPhone X and newer (375px - 414px) */
@media (min-width: 375px) and (max-width: 414px) {
    .hero {
        padding: 2.25rem 0;
    }
    
    .hero-title {
        font-size: 1.65rem;
        line-height: 1.4;
        margin-bottom: var(--spacing-md);
    }
    
    .hero-description {
        font-size: var(--font-size-base);
        line-height: 1.7;
        margin-bottom: var(--spacing-lg);
    }
    
    .hero-actions .btn {
        min-height: 50px;
        padding: var(--spacing-md) var(--spacing-lg);
    }
    
    .section-title {
        font-size: var(--font-size-2xl);
    }
    
    .feature-card {
        padding: var(--spacing-lg);
    }
    
    .feature-icon {
        width: 65px;
        height: 65px;
        font-size: 1.875rem;
    }
    
    .step-number {
        width: 55px;
        height: 55px;
        font-size: var(--font-size-xl);
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-md);
    }
}

/* High DPI Displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .brand-logo,
    .footer-logo {
        image-rendering: -webkit-optimize-contrast;
        image-rendering: crisp-edges;
    }
}

/* Touch Device Optimizations */
@media (hover: none) and (pointer: coarse) {
    .btn,
    .nav-menu a,
    .feature-card,
    .step,
    .floating-card,
    .stat-box,
    .social-links a,
    .scroll-to-top {
        -webkit-tap-highlight-color: rgba(61, 90, 148, 0.2);
        touch-action: manipulation;
    }
    
    .btn:active,
    .nav-menu a:active,
    .mobile-menu-toggle:active {
        transform: scale(0.97);
    }
    
    .feature-card:hover,
    .step:hover,
    .floating-card:hover {
        transform: none;
    }
    
    .feature-card:active {
        transform: scale(0.98);
    }
    
    .step:active {
        transform: scale(0.98);
    }
    
    /* Improve touch targets */
    .btn {
        min-height: 44px;
        min-width: 44px;
    }
    
    .nav-menu a {
        min-height: 44px;
    }
    
    .social-links a {
        min-width: 44px;
        min-height: 44px;
    }
    
    .scroll-to-top {
        min-width: 44px;
        min-height: 44px;
    }
    
    /* Remove hover effects on touch devices */
    .feature-card:hover .feature-icon {
        transform: none;
    }
    
    .step:hover .step-number {
        transform: none;
    }
    
    /* Better active states */
    .btn:active {
        opacity: 0.9;
    }
    
    .nav-menu a:active {
        background-color: rgba(61, 90, 148, 0.1);
    }
}

/* Accessibility - Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    
    .floating-card {
        animation: none !important;
    }
    
    .hero::before {
        animation: none !important;
    }
}

/* ========================================
   Additional Mobile Optimizations
   ======================================== */

/* Improve text wrapping on mobile */
@media (max-width: 767px) {
    .hero-title,
    .section-title,
    .feature-card h3,
    .step-content h3 {
        word-wrap: break-word;
        overflow-wrap: break-word;
        hyphens: auto;
    }
    
    /* Prevent horizontal scroll */
    body {
        overflow-x: hidden;
        width: 100%;
    }
    
    /* Improve touch scrolling */
    .nav-menu.active {
        -webkit-overflow-scrolling: touch;
        overscroll-behavior: contain;
    }
    
    /* Better button spacing */
    .btn {
        letter-spacing: 0.01em;
    }
    
    /* Improve image loading */
    img {
        max-width: 100%;
        height: auto;
        display: block;
    }
    
    /* Better form inputs on mobile */
    input,
    textarea,
    select {
        font-size: 16px !important; /* Prevents zoom on iOS */
    }
    
    /* Improve container max-width */
    .container {
        max-width: 100%;
        width: 100%;
    }
}

/* Improve readability on small screens */
@media (max-width: 480px) {
    body {
        font-size: 15px;
    }
    
    p {
        line-height: 1.7;
    }
    
    /* Better spacing for lists */
    ul,
    ol {
        padding-right: var(--spacing-md);
    }
    
    /* Improve link touch targets */
    a {
        min-height: 44px;
        display: inline-flex;
        align-items: center;
    }
}

/* Improve performance on mobile */
@media (max-width: 767px) {
    /* Reduce animations for better performance */
    .floating-card {
        animation-duration: 4s;
    }
    
    /* Optimize gradients */
    .hero {
        background-attachment: scroll;
    }
    
    /* Reduce shadow complexity */
    .feature-card,
    .step {
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    }
    
    .feature-card:hover,
    .step:hover {
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    }
}

/* Improve safe area handling for notched devices */
@supports (padding: max(0px)) {
    @media (max-width: 767px) {
        .navbar {
            padding-top: max(0.2rem, env(safe-area-inset-top));
            padding-bottom: max(0.2rem, env(safe-area-inset-bottom));
        }
        
        .hero {
            padding-top: max(2.5rem, env(safe-area-inset-top));
            padding-bottom: max(2.5rem, env(safe-area-inset-bottom));
        }
        
        .footer {
            padding-bottom: max(var(--spacing-md), env(safe-area-inset-bottom));
        }
        
        .scroll-to-top {
            bottom: max(1.5rem, env(safe-area-inset-bottom));
            left: max(1.5rem, env(safe-area-inset-left));
        }
    }
}

