/*
   Modern Design System - Custom CSS v1.2
   Theme: Modern SaaS | Color: Indigo/Emerald | Style: Clean/Glass
   (Includes Pricing & Footer updates)
*/

:root {
    /* --- Color Palette --- */
    --primary-50: #eef2ff;
    --primary-100: #e0e7ff;
    --primary-200: #c7d2fe;
    --primary-300: #a5b4fc;
    --primary-400: #818cf8;
    --primary-500: #6366f1;
    --primary-600: #4f46e5; /* Main Brand Color */
    --primary-700: #4338ca;
    --primary-800: #3730a3;
    --primary-900: #312e81;
    --secondary-500: #10b981;
    --slate-50: #f8fafc;
    --slate-100: #f1f5f9;
    --slate-200: #e2e8f0;
    --slate-300: #cbd5e1;
    --slate-400: #94a3b8;
    --slate-600: #475569;
    --slate-800: #1e293b;
    --slate-900: #0f172a;

    /* Gradients */
    --gradient-primary: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
    --gradient-subtle:
        radial-gradient(circle at top right, #e0e7ff 0%, transparent 40%),
        radial-gradient(circle at bottom left, #eef2ff 0%, transparent 40%);
    --gradient-dark: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);

    /* Fonts */
    --font-en: "Outfit", sans-serif;
    --font-ar: "Cairo", sans-serif;

    /* Spacing */
    --section-gap: 100px;
}

/* --- Global Reset --- */
body {
    background-color: var(--slate-50);
    color: var(--slate-600);
    font-family: var(--font-en);
    line-height: 1.7;
    overflow-x: hidden;
}

[dir="rtl"] body {
    font-family: var(--font-ar);
}

h1,
h2,
h3,
h4,
h5,
h6 {
    color: var(--slate-900);
    font-weight: 700;
    line-height: 1.25;
}

/* --- Utilities --- */
.section-padding {
    padding-top: var(--section-gap);
    padding-bottom: var(--section-gap);
}

/* Color Utilities */
.text-primary {
    color: var(--primary-600) !important;
}
.text-secondary {
    color: var(--secondary-500) !important;
}
.text-slate-500 {
    color: var(--slate-500) !important;
}
.text-slate-600 {
    color: var(--slate-600) !important;
}
.text-slate-900 {
    color: var(--slate-900) !important;
}

.bg-primary {
    background-color: var(--primary-600) !important;
}
.bg-primary-50 {
    background-color: var(--primary-50) !important;
}
.bg-primary-100 {
    background-color: var(--primary-100) !important;
}
.bg-light {
    background-color: var(--slate-50) !important;
}
.bg-white {
    background-color: #ffffff !important;
}
.bg-dark-section {
    background: var(--gradient-dark);
    color: white;
}

.text-gradient {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* --- Buttons --- */
.btn {
    padding: 0.875rem 2rem;
    font-weight: 600;
    border-radius: 50px;
    transition: all 0.3s ease;
}
.btn-primary {
    background: linear-gradient(135deg, #002332 0%, #004d5c 100%);
    border: none;
    box-shadow: 0 10px 20px -5px rgba(0, 35, 50, 0.4);
}
.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 30px -5px rgba(0, 35, 50, 0.5);
    background: linear-gradient(135deg, #003344 0%, #005d6c 100%);
}
.btn-outline-dark {
    border: 2px solid var(--slate-200);
    color: var(--slate-800);
}
.btn-outline-dark:hover {
    border-color: var(--slate-900);
    background: var(--slate-900);
    color: white;
}
.btn-light-soft {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.2);
}
.btn-light-soft:hover {
    background: white;
    color: var(--primary-600);
}

/* --- Cards --- */
/* Simple Modern Card (Features) */
.modern-card {
    background: #ffffff;
    border-radius: 24px;
    padding: 3rem 2rem;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 1px solid rgba(255, 255, 255, 0.8);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}
.modern-card:hover {
    transform: translateY(-10px);
    box-shadow:
        0 20px 25px -5px rgba(0, 0, 0, 0.1),
        0 8px 10px -6px rgba(0, 0, 0, 0.1);
    border-color: var(--primary-100);
}

/* Glass Card (Floating elements) */
.glass-card {
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.1);
    border-radius: 20px;
}

/* --- Components --- */

/* Navbar & Logo */
.navbar {
    background: rgba(255, 255, 255, 0.9) !important;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--slate-200);
    padding: 1rem 0;
    transition: all 0.3s ease;
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
}

.navbar-brand img {
    height: 40px;
    width: auto;
    display: block;
}

.navbar .nav-link {
    font-weight: 600;
    color: var(--slate-900) !important;
    padding: 0.75rem 1rem !important;
    border-radius: 8px;
    transition: all 0.2s;
}

.navbar .nav-link:hover,
.navbar .nav-link:focus,
.navbar .nav-link.active {
    color: var(--primary-600) !important;
    background: var(--primary-50);
}

/* Dropdowns */
.dropdown-menu {
    border: none;
    box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.15);
    border-radius: 16px;
    padding: 0.5rem;
    margin-top: 10px !important;
}
.dropdown-item {
    border-radius: 8px;
    padding: 8px 16px;
    font-weight: 500;
    color: var(--slate-600);
    transition: all 0.2s;
}
.dropdown-item:hover,
.dropdown-item:active {
    background-color: var(--primary-50);
    color: var(--primary-700);
}

/* Badges */
.badge {
    padding: 0.5em 1em;
    font-weight: 600;
}
.badge-soft-primary {
    background-color: var(--primary-50);
    color: var(--primary-700);
}

/* --- Forms --- */
.form-control {
    padding: 1rem 1.5rem;
    border-radius: 16px;
    border: 1px solid var(--slate-200);
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
    transition: all 0.2s;
}
.form-control:focus {
    border-color: var(--primary-500);
    box-shadow: 0 0 0 4px var(--primary-100);
    background-color: #fff;
}

/* --- Hero Section Specifics --- */
.hero-wrapper {
    position: relative;
    padding-top: 140px; /* Adjusted for fixed navbar */
    padding-bottom: 100px;
    background: linear-gradient(
        135deg,
        rgba(0, 35, 50, 0.03) 0%,
        rgba(0, 77, 92, 0.05) 50%,
        rgba(0, 109, 122, 0.03) 100%
    );
    overflow: hidden;
    z-index: 1;
}

.hero-wrapper::before {
    content: "";
    position: absolute;
    top: -20%;
    right: 5%;
    width: 400px;
    height: 400px;
    background: radial-gradient(
        circle,
        rgba(0, 35, 50, 0.08) 0%,
        transparent 60%
    );
    border-radius: 50%;
    animation: pulse-slow 8s ease-in-out infinite;
    z-index: -1;
}

.hero-wrapper::after {
    content: "";
    position: absolute;
    bottom: -10%;
    left: 5%;
    width: 300px;
    height: 300px;
    background: radial-gradient(
        circle,
        rgba(0, 77, 92, 0.06) 0%,
        transparent 60%
    );
    border-radius: 50%;
    animation: pulse-slow 10s ease-in-out infinite reverse;
    z-index: -1;
}

@keyframes pulse-slow {
    0%,
    100% {
        transform: scale(1);
        opacity: 0.5;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }
}

.hero-title {
    font-size: 3rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 1.5rem;
    color: var(--slate-900);
}

/* Background Blobs (Fix positioning) */
.blur-3xl {
    filter: blur(60px);
    z-index: -1;
}

/* Glass Card Positioning fixes */
.glass-card {
    background: rgba(255, 255, 255, 0.85); /* More opacity */
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.6);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    border-radius: 20px;
    z-index: 10; /* Ensure on top */
}

/* --- Pricing Section --- */
.pricing-card-v2 {
    background: #fff;
    border: 1px solid var(--slate-200);
    border-radius: 24px;
    padding: 3rem;
    position: relative;
    transition: all 0.3s;
    height: 100%;
}
.pricing-card-v2.popular {
    border: 2px solid var(--primary-500);
    box-shadow: 0 25px 50px -12px rgba(99, 102, 241, 0.25);
    background: linear-gradient(to bottom, #fff 0%, #eef2ff 100%);
    z-index: 2;
    transform: scale(1.05);
}
.pricing-card-v2:not(.popular):hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.price-display {
    font-size: 3rem;
    font-weight: 800;
    color: var(--slate-900);
    letter-spacing: -1px;
}

/* --- Testimonials --- */
.testimonial-card-v2 {
    background: #fff;
    border-radius: 24px;
    border: 1px solid var(--slate-100);
    padding: 2.5rem;
    height: 100%;
    position: relative;
}
.testimonial-card-v2::before {
    content: '"';
    font-size: 5rem;
    line-height: 1;
    position: absolute;
    top: 1rem;
    right: 2rem;
    color: var(--primary-100);
    font-family: serif;
}

/* --- Footer --- */
.footer-modern {
    background: linear-gradient(135deg, #002332 0%, #003d4c 100%);
    color: rgba(255,255,255,0.6);
    padding-top: 80px;
    padding-bottom: 40px;
}
.footer-title {
    color: white;
    font-weight: 700;
    margin-bottom: 1.5rem;
}
.footer-link {
    color: rgba(255,255,255,0.6);
    margin-bottom: 0.75rem;
    display: block;
    transition: 0.2s;
}
.footer-link:hover {
    color: #10b981;
    padding-inline-start: 5px;
}

/* Responsive Font Sizes */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }
    .section-padding {
        --section-gap: 60px;
    }
    .pricing-card-v2.popular {
        transform: none;
    }
}

/* Animations */
@keyframes float {
    0%,
    100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-20px);
    }
}
.animate-float {
    animation: float 6s ease-in-out infinite;
}
.delay-1 {
    animation-delay: 1s;
}
.delay-2 {
    animation-delay: 2s;
}
.delay-3 {
    animation-delay: 3s;
}
.animate-up {
    animation: floatUp 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}
@keyframes floatUp {
    0% {
        transform: translateY(20px);
        opacity: 0;
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}
