/* ===============================================
   1. CSS RESET & VARIABLES
   =============================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #5b68d7;
    --primary-dark: #4a57c6;
    --primary-light: #7b85e7;
    --secondary: #00d4aa;
    --dark: #0a0e27;
    --light: #f8f9ff;
    --text-gray: #6b7280;
    --text-dark: #1f2937;
    --success: #10b981;
    --white: #ffffff;
    --bg-gray: #f9fafb;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    background: var(--white);
    color: var(--text-dark);
    overflow-x: hidden;
    line-height: 1.6;
}

/* ===============================================
   2. NAVIGATION STYLES
   =============================================== */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 15px 40px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
}

nav.scrolled {
    box-shadow: 0 2px 20px rgba(0,0,0,0.1);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 15px;
    text-decoration: none;
}

.logo-icon {
    width: 45px;
    height: 45px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-icon svg {
    width: 25px;
    height: 25px;
    fill: white;
}

.logo-text {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary);
}

.nav-links {
    display: flex;
    gap: 30px;
    align-items: center;
}

.nav-links a {
    color: var(--text-gray);
    text-decoration: none;
    transition: color 0.3s ease;
    font-weight: 500;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--primary);
}

.nav-cta {
    background: var(--primary);
    color: var(--white) !important;
    padding: 10px 20px;
    border-radius: 50px;
    transition: all 0.3s ease;
}

.nav-cta:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(91,104,215,0.3);
}

.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 4px;
    cursor: pointer;
}

.mobile-menu-toggle span {
    width: 25px;
    height: 2px;
    background: var(--primary);
    transition: 0.3s;
}

/* ===============================================
   3. HERO SECTION
   =============================================== */
.hero {
    min-height: 100vh;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    position: relative;
    display: flex;
    align-items: center;
    padding-top: 80px;
    padding-bottom: 0;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.05) 1px, transparent 1px);
    background-size: 50px 50px;
    animation: drift 20s linear infinite;
}

@keyframes drift {
    0% { transform: translate(0, 0); }
    100% { transform: translate(50px, 50px); }
}

.hero-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
    z-index: 10;
    position: relative;
    color: white;
}

.hero h1 {
    font-size: clamp(2.5rem, 5vw, 4.5rem);
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 30px;
    animation: fadeInUp 0.8s ease-out;
}

.hero-subtitle {
    font-size: clamp(1.2rem, 2.5vw, 1.5rem);
    opacity: 0.95;
    margin-bottom: 40px;
    animation: fadeInUp 0.8s ease-out 0.2s backwards;
}

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

.floating-metrics {
    margin-top: 60px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.metric-card {
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.2);
    padding: 20px;
    border-radius: 15px;
    text-align: center;
    animation: float 3s ease-in-out infinite;
}

.metric-card:nth-child(2) { animation-delay: 0.5s; }
.metric-card:nth-child(3) { animation-delay: 1s; }

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

.metric-value {
    font-size: clamp(2rem, 3vw, 2.5rem);
    font-weight: 800;
}

.metric-label {
    font-size: 0.9rem;
    opacity: 0.9;
    margin-top: 5px;
}

/* ===============================================
   4. CUSTOMER SUCCESS SECTION
   =============================================== */
.customer-success {
    padding: 100px 40px;
    background: var(--bg-gray);
}

.trust-metrics {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    max-width: 1000px;
    margin: 60px auto 80px;
}

.trust-metric {
    text-align: center;
}

.trust-metric-value {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--primary);
    margin-bottom: 10px;
}

.trust-metric-label {
    color: var(--text-gray);
    font-size: 1rem;
}

.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto 80px;
}

.testimonial-card {
    background: var(--white);
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    position: relative;
}

.testimonial-card::before {
    content: '"';
    position: absolute;
    top: 20px;
    left: 30px;
    font-size: 4rem;
    color: var(--primary);
    opacity: 0.2;
    font-family: Georgia, serif;
}

.testimonial-text {
    color: var(--text-gray);
    margin-bottom: 20px;
    line-height: 1.8;
    position: relative;
    z-index: 1;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-top: 20px;
}

.author-avatar {
    width: 50px;
    height: 50px;
    background: var(--primary);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

.author-info {
    flex: 1;
}

.author-name {
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 2px;
}

.author-title {
    font-size: 0.9rem;
    color: var(--text-gray);
}

.author-company {
    font-size: 0.85rem;
    color: var(--primary);
}

.certifications {
    text-align: center;
    margin-top: 80px;
}

.cert-badges {
    display: flex;
    justify-content: center;
    gap: 40px;
    flex-wrap: wrap;
    margin-top: 30px;
}

.cert-badge {
    padding: 15px 25px;
    background: var(--white);
    border-radius: 10px;
    box-shadow: 0 3px 15px rgba(0,0,0,0.08);
    font-weight: 600;
    color: var(--primary);
}

/* ===============================================
   5. OUTCOMES SECTION
   =============================================== */
.outcomes {
    padding: 80px 40px 100px 40px;
    background: var(--white);
    margin-top: 20px;
}

.section-header {
    text-align: center;
    margin-bottom: 80px;
    padding: 0 20px;
    position: relative;
    z-index: 10;
}

/* Ensure Patient Outcomes section header is properly spaced */
.outcomes .section-header {
    padding-top: 40px;
}

.section-title {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    margin-bottom: 20px;
    color: var(--primary);
    line-height: 1.2;
}

.section-subtitle {
    color: var(--text-gray);
    font-size: clamp(1rem, 2vw, 1.2rem);
    line-height: 1.4;
}

.outcomes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.outcome-card {
    background: var(--bg-gray);
    border-radius: 20px;
    padding: 40px;
    transition: all 0.3s ease;
    cursor: pointer;
}

.outcome-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(91,104,215,0.15);
}

.outcome-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 20px;
}

.outcome-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 15px;
    color: var(--text-dark);
}

.outcome-description {
    color: var(--text-gray);
    line-height: 1.6;
    margin-bottom: 20px;
}

.outcome-stat {
    font-size: 2rem;
    font-weight: 800;
    color: var(--primary);
}

/* ===============================================
   6. FEATURES SECTION
   =============================================== */
.features {
    padding: 100px 40px;
    background: var(--bg-gray);
}

.features-container {
    max-width: 1400px;
    margin: 0 auto;
}

.feature-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
    margin-bottom: 100px;
}

.feature-row:nth-child(even) {
    direction: rtl;
}

.feature-row:nth-child(even) .feature-content {
    direction: ltr;
}

.feature-visual {
    position: relative;
    height: 400px;
    background: linear-gradient(135deg, rgba(91,104,215,0.1), rgba(123,133,231,0.1));
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding: 20px;
}

.feature-visual img {
    max-height: 100%;
    object-fit: contain;
}

.feature-visual::before {
    content: '';
    position: absolute;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(91,104,215,0.2) 0%, transparent 70%);
    animation: pulse 3s ease-in-out infinite;
}

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

.feature-content h3 {
    font-size: clamp(1.8rem, 3vw, 2.5rem);
    margin-bottom: 20px;
    color: var(--primary);
}

.feature-content p {
    color: var(--text-gray);
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 30px;
}

.feature-list {
    list-style: none;
}

.feature-list li {
    padding: 10px 0;
    color: var(--text-dark);
    display: flex;
    align-items: center;
}

.feature-list li::before {
    content: '✓';
    color: var(--secondary);
    font-weight: bold;
    margin-right: 15px;
    font-size: 1.2rem;
}

/* ===============================================
   7. PRICING SECTION
   =============================================== */
.pricing {
    padding: 100px 40px;
    background: var(--white);
}

.pricing-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 40px;
    max-width: 900px;
    margin: 0 auto;
}

.pricing-card {
    background: var(--bg-gray);
    border-radius: 20px;
    padding: 40px;
    position: relative;
    transition: all 0.3s ease;
}

.pricing-card.popular {
    background: var(--primary);
    color: var(--white);
    transform: scale(1.05);
}

.pricing-card.popular .pricing-features li,
.pricing-card.popular .pricing-subtitle,
.pricing-card.popular .setup-fee {
    color: rgba(255,255,255,0.9);
}

.popular-badge {
    position: absolute;
    top: -15px;
    right: 30px;
    background: var(--secondary);
    color: var(--white);
    padding: 5px 20px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

.pricing-title {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.pricing-subtitle {
    color: var(--text-gray);
    margin-bottom: 30px;
}

.pricing-price {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 5px;
}

.pricing-period {
    font-size: 1rem;
    opacity: 0.8;
}

.setup-fee {
    color: var(--text-gray);
    font-size: 0.9rem;
    margin-top: 10px;
    margin-bottom: 30px;
}

.pricing-features {
    list-style: none;
    margin-bottom: 30px;
}

.pricing-features li {
    padding: 12px 0;
    display: flex;
    align-items: flex-start;
    color: var(--text-dark);
}

.pricing-features li::before {
    content: '✓';
    color: var(--secondary);
    font-weight: bold;
    margin-right: 12px;
    font-size: 1.1rem;
}

.pricing-card.popular .pricing-features li::before {
    color: var(--white);
}

/* ===============================================
   8. CTA SECTION
   =============================================== */
.cta {
    padding: 100px 40px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    text-align: center;
    position: relative;
    overflow: hidden;
    color: white;
}

.cta::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at center, rgba(255,255,255,0.1) 0%, transparent 50%);
}

.cta-content {
    position: relative;
    z-index: 10;
    max-width: 800px;
    margin: 0 auto;
}

.cta h2 {
    font-size: clamp(2rem, 4vw, 3rem);
    margin-bottom: 30px;
}

.cta-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-top: 40px;
    flex-wrap: wrap;
}

.btn {
    padding: 18px 40px;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 50px;
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-block;
    border: none;
    cursor: pointer;
}

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

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

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

.btn-secondary:hover {
    background: rgba(255,255,255,0.1);
}

/* ===============================================
   9. FOOTER
   =============================================== */
.footer {
    background: var(--text-dark);
    color: var(--white);
    padding: 60px 40px 30px;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 60px;
    margin-bottom: 40px;
}

.footer-brand {
    max-width: 400px;
}

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

.footer-logo .logo-icon svg {
    fill: var(--primary);
}

.footer-logo .logo-text {
    color: var(--white);
}

.footer-description {
    color: #d1d5db;
    line-height: 1.8;
    margin-bottom: 30px;
}

.footer-contact {
    color: #d1d5db;
}

.footer-contact p {
    margin-bottom: 10px;
}

.footer-contact a {
    color: #d1d5db;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-contact a:hover {
    color: var(--primary-light);
}

.footer-column h4 {
    color: var(--white);
    margin-bottom: 20px;
    font-size: 1.2rem;
}

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

.footer-links li {
    margin-bottom: 12px;
}

.footer-links a {
    color: #d1d5db;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--primary-light);
}

.footer-bottom {
    padding-top: 30px;
    border-top: 1px solid rgba(255,255,255,0.1);
    text-align: center;
    color: #9ca3af;
}

.departments {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 30px;
    justify-content: center;
}

.dept-pill {
    padding: 8px 16px;
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 20px;
    font-size: 0.9rem;
    color: white;
}

/* ===============================================
   10. RESPONSIVE DESIGN
   =============================================== */
@media (max-width: 968px) {
    .nav-links {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--white);
        flex-direction: column;
        padding: 20px;
        box-shadow: 0 10px 30px rgba(0,0,0,0.1);
        display: none;
    }

    .nav-links.active {
        display: flex;
    }

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

    .feature-row {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .feature-row:nth-child(even) {
        direction: ltr;
    }

    .feature-visual {
        height: 250px;
        padding: 15px;
    }
    
    .feature-visual img {
        width: 100%;
        height: auto;
        max-width: 300px;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .testimonials-grid {
        grid-template-columns: 1fr;
    }

    .pricing-cards {
        grid-template-columns: 1fr;
    }

    .pricing-card.popular {
        transform: scale(1);
    }
}

@media (max-width: 768px) {
    nav {
        padding: 15px 20px;
    }

    .hero-content {
        padding: 0 20px;
    }

    .floating-metrics {
        grid-template-columns: 1fr;
    }

    .outcomes-grid {
        grid-template-columns: 1fr;
    }

    .trust-metrics {
        grid-template-columns: repeat(2, 1fr);
    }

    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 100%;
        max-width: 300px;
    }

    .outcomes {
        padding: 80px 20px 60px 20px;
        margin-top: 10px;
    }
    
    .features, .cta, .customer-success, .pricing {
        padding: 80px 20px 60px 20px;
    }

    .section-header {
        margin-bottom: 40px;
    }

    .section-title {
        font-size: 2rem;
        word-wrap: break-word;
    }

    .section-subtitle {
        font-size: 1rem;
    }

    .hero-benefits {
        flex-direction: column;
        align-items: center;
    }
}

@media (max-width: 480px) {
    .logo-text {
        font-size: 1.5rem;
    }

    .logo-icon {
        width: 40px;
        height: 40px;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .section-title {
        font-size: 1.8rem;
    }

    .trust-metrics {
        grid-template-columns: 1fr;
    }
}

/* ===============================================
   11. UTILITIES
   =============================================== */
.text-center {
    text-align: center;
}

.mb-4 {
    margin-bottom: 2rem;
}

.fade-in {
    animation: fadeIn 0.5s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}