/* 
   Medical Simulation Website Design System 
   Premium, Trustworthy, High-Tech
   Version: 3.0 (Emergency Reset)
*/

:root {
    /* Color Palette - Deep Academic & Scientific */
    --primary-color: #007AFF;
    /* Apple Blue for accents */
    --primary-deep: #001A33;
    /* Deep Space Blue for main headers/sections */
    --secondary-color: #00A8CC;
    --accent-color: #FF2D55;

    /* Neutral Palette - Medical Grade */
    --text-main: #1D1D1F;
    --text-light: #48484A;
    --text-lighter: #8E8E93;

    /* Surfaces */
    --bg-body: #F2F2F7;
    --bg-white: #FFFFFF;
    --bg-section-alt: #E5E5EA;
    --bg-glass: rgba(255, 255, 255, 0.85);

    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 5rem;
    --spacing-xl: 10rem;

    /* Typography - Academic Mix */
    --font-main: "SF Pro Display", "Inter", -apple-system, sans-serif;
    --font-heading: "SF Pro Display", "Noto Sans SC", sans-serif;
    --font-serif: "Lora", "Georgia", serif;
    /* For a touch of academic prestige */

    /* Shadows & Effects */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.04);
    --shadow-md: 0 12px 24px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 32px 64px rgba(0, 0, 0, 0.12);
    --shadow-button: 0 4px 14px 0 rgba(0, 118, 255, 0.39);

    /* Border & Radius */
    --border-light: rgba(0, 0, 0, 0.08);
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 28px;
    --radius-full: 9999px;

    /* Transitions */
    --transition-smooth: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-fast: all 0.2s ease;
}

/* Reset & Base */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    overflow-y: scroll;
    /* Force scrollbar to prevent layout shift */
}

body {
    font-family: var(--font-main);
    background-color: var(--bg-body);
    color: var(--text-main);
    line-height: 1.6;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-base);
}

ul {
    list-style: none;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-main);
    margin-bottom: var(--spacing-sm);
}

img,
svg {
    display: block;
}

/* Global Form Elements - CRITICAL FIX */
input,
select,
textarea,
button {
    font-family: inherit;
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"],
select,
textarea {
    width: 100%;
    /* Default to full width in containers */
    padding: 0.75rem 1rem;
    border: 1px solid var(--border-light);
    border-radius: 8px;
    /* Standardize radius */
    font-size: 1rem;
    background: white;
    transition: all 0.2s ease;
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(0, 122, 255, 0.1);
}

/* Utilities */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
    position: relative;
    width: 100%;
}

/* Sections */
/* Sections */
.section {
    padding: 40px 0;
    /* Reduced from 60px globally for tighter look */
}

/* Hero Section (Home Page) - Full Fusion Layout */
.hero {
    /* Ultra-wide background image covers the entire section */
    background-color: #007bff;
    /* Tech Blue Fallback */
    background-image: url('../images/hero_bg_v3.png');
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    color: white;

    /* Height and spacing */
    min-height: 600px;
    /* Reduced min-height to fit image aspect ratio better */
    height: auto;
    /* Allow height to adapt */
    padding-bottom: 50px;
    /* Add some padding for content */
    display: flex;
    align-items: center;
    position: relative;
    overflow: visible;
    padding-top: 140px;
    /* Added to clear fixed header */
}

/* Add a subtle vignette overlay to ensure text legibility on all hues */
.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Dramatically darker left side for text contrast */
    background: linear-gradient(90deg,
            rgba(0, 26, 51, 1) 0%,
            rgba(0, 26, 51, 0.95) 35%,
            rgba(0, 26, 51, 0.5) 60%,
            rgba(0, 26, 51, 0.1) 100%);
    z-index: 1;
}

/* Container sits above the overlay */
.hero .container {
    z-index: 2;
    display: flex;
    /* Only flex the container inside hero */
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
}

.hero-content {
    max-width: 680px;
    text-align: left;
    background: transparent;
    padding: 0;
    margin: 0;
    border: none;
}

.hero h1 {
    color: white;
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.15;
    margin-bottom: 2rem;
    letter-spacing: -0.02em;
}

.hero h1 .highlight {
    display: block;
    background: linear-gradient(90deg, #5AC8FA, #007AFF);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero p {
    color: rgba(255, 255, 255, 0.85);
    font-size: 1.35rem;
    font-weight: 400;
    margin-bottom: 3rem;
    max-width: 580px;
    line-height: 1.6;
}

.hero-stats {
    display: flex;
    gap: 2rem;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    /* Subtle divider */
}

.stat-item h3 {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: 0.25rem;
}

.stat-item p {
    font-size: 0.875rem;
    margin-bottom: 0;
    color: rgba(255, 255, 255, 0.7);
}

.hero-actions {
    display: flex;
    gap: 1rem;
}

/* OLD HERO STYLES - Removed for fusion layout, keeping button styles */

.section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto var(--spacing-lg);
}

.section-header h2 {
    font-size: 2.25rem;
    margin-bottom: var(--spacing-sm);
    color: var(--primary-color);
}

.section-header p {
    font-size: 1.125rem;
    color: var(--text-light);
}

.mb-4 {
    margin-bottom: 1rem;
}

.mt-6 {
    margin-top: 1.5rem;
}

.mt-8 {
    margin-top: 2rem;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.75rem;
    border-radius: var(--radius-full);
    font-weight: 600;
    cursor: pointer;
    border: 1.5px solid transparent;
    transition: var(--transition-smooth);
    letter-spacing: -0.01em;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
    box-shadow: var(--shadow-button);
}

.btn-primary:hover {
    background: white;
    color: var(--primary-color);
    box-shadow: 0 8px 25px rgba(0, 122, 255, 0.4);
    transform: translateY(-2px);
}

.btn-outline {
    border-color: rgba(255, 255, 255, 0.3);
    color: white;
}

.btn-outline:hover {
    background: white;
    color: var(--primary-deep);
    border-color: white;
}

.btn-lg {
    padding: 1rem 2rem;
    font-size: 1.125rem;
}

.btn-block {
    display: flex;
    width: 100%;
}

/* Header */
.header {
    background-color: var(--bg-glass);
    backdrop-filter: var(--blur-md);
    -webkit-backdrop-filter: var(--blur-md);
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    border-bottom: 1px solid var(--glass-border);
    height: 72px;
    display: flex;
    align-items: center;
    transition: var(--transition-fast);
}

.header.scrolled {
    height: 64px;
    box-shadow: var(--shadow-sm);
}

.nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo {
    display: flex;
    align-items: center;
    font-weight: 700;
    font-size: 1.5rem;
    color: var(--primary-color);
}

.logo-icon {
    display: none;
    /* Hide old icon layout */
}

.logo-img {
    height: 40px;
    /* Increased height for better visibility */
    width: auto;
    object-fit: contain;
    margin-right: 0.75rem;
    display: block;
}

.nav-menu {
    display: flex;
    gap: 2rem;
}

.nav-link {
    font-weight: 500;
    color: var(--text-light);
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary-color);
}

.nav-cta {
    margin-left: 2rem;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
}

.menu-toggle span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: var(--primary-color);
    transition: all 0.3s;
}

/* Mobile Menu */
.mobile-menu {
    position: fixed;
    top: 80px;
    left: 0;
    width: 100%;
    background: white;
    padding: 2rem;
    flex-direction: column;
    box-shadow: var(--shadow-lg);
    display: none;
    /* JS will toggle */
    z-index: 999;
}

.mobile-menu.active {
    display: flex;
}

.mobile-menu .nav-link {
    padding: 1rem 0;
    border-bottom: 1px solid var(--border-color);
    display: block;
}

/* Trust Badges */
.trust-badges {
    display: flex;
    /* Kept for alignment inside .hero-content mostly */
    justify-content: flex-start;
    /* Align left with text */
    gap: 1.5rem;
    margin-top: 2rem;
    flex-wrap: wrap;
}

.badge-item {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.8);
    font-weight: 500;
}

/* Page Hero (Base) */
/* Page Hero (Base) */
.page-hero {
    background: var(--primary-deep);
    /* Updated to brighter blue gradient */
    background-image: linear-gradient(rgba(0, 86, 179, 0.85), rgba(0, 60, 130, 0.9)),
        url('../images/hero_premium.png');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    color: white;
    padding: 100px 0 60px;
    /* Reduced vertical padding, rely on min-height */
    text-align: center;
    position: relative;
    box-shadow: inset 0 -20px 40px rgba(0, 0, 0, 0.3);

    /* Structural Height Control */
    min-height: 320px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding-top: 100px;
    /* Offset for fixed header */
}

/* Specific Page Heroes */
/* Specific Page Heroes */
.page-hero--solutions {
    background-image: linear-gradient(rgba(0, 86, 179, 0.85), rgba(0, 60, 130, 0.9)),
        url('../images/header_solutions.png');
}

.page-hero--cases {
    background-image: linear-gradient(rgba(0, 86, 179, 0.85), rgba(0, 60, 130, 0.9)),
        url('../images/header_cases.png');
}

.page-hero--services {
    background-image: linear-gradient(rgba(0, 86, 179, 0.85), rgba(0, 60, 130, 0.9)),
        url('../images/header_services.png');
}

.page-hero--about {
    background-image: linear-gradient(rgba(0, 86, 179, 0.85), rgba(0, 60, 130, 0.9)),
        url('../images/header_about.png');
}

.page-hero--contact {
    background-image: linear-gradient(rgba(0, 86, 179, 0.85), rgba(0, 60, 130, 0.9)),
        url('../images/header_contact.png');
    /* No specific padding needed now due to flex layout */
}

.page-hero h1 {
    color: white;
    font-size: 2.75rem;
    font-weight: 700;
    margin-bottom: 1.25rem;
    letter-spacing: -0.01em;
    text-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.page-hero p {
    color: rgba(255, 255, 255, 0.9);
    max-width: 640px;
    margin: 0 auto;
    font-size: 1.15rem;
    line-height: 1.6;
}

/* ---------------- SERVICES PAGE STYLES ---------------- */

.service-detail {
    padding: var(--spacing-lg) 0;
    border-bottom: 1px solid var(--border-light);
}

.service-detail-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 4rem;
    align-items: center;
}

/* Flip order for alternating sections */
.service-detail.section-alt .service-detail-grid {
    direction: rtl;
    /* simple trick to flip columns */
}

.service-detail.section-alt .service-detail-content,
.service-detail.section-alt .service-detail-visual {
    direction: ltr;
    /* reset content direction */
}

/* Contact Page Layout */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: start;
}

@media (max-width: 992px) {
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
}

.step-indicator {
    display: flex;
    justify-content: space-between;
    margin-bottom: 2rem;
    position: relative;
}

.step-indicator::before {
    content: '';
    position: absolute;
    top: 15px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--border-color);
    z-index: 1;
}

.step-dot {
    width: 32px;
    height: 32px;
    background: white;
    border: 2px solid var(--border-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    position: relative;
    z-index: 2;
    font-size: 14px;
}

.step-dot.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

.service-detail-visual {
    background: white;
    padding: 3rem;
    border-radius: 20px;
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    aspect-ratio: 1;
}

.service-features {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin: 2rem 0;
}

.service-feature {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.95rem;
}

.service-feature-icon {
    color: var(--secondary-color);
    font-weight: bold;
}

.software-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.software-tag {
    background: #eef2f6;
    padding: 0.25rem 0.75rem;
    border-radius: 4px;
    font-size: 0.85rem;
    color: var(--text-light);
}

/* Workflow Steps */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.service-card {
    background: var(--bg-white);
    padding: var(--spacing-md);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    transition: var(--transition-smooth);
    border: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-color);
}

.service-icon {
    width: 56px;
    height: 56px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 2rem;
}

/* Service Packages */
.packages-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.package-card {
    background: var(--bg-white);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    padding: 2.5rem;
    position: relative;
    transition: var(--transition-smooth);
}

.package-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-5px);
}

.package-card.featured {
    border: 2.5px solid var(--primary-color);
    background: linear-gradient(to bottom, #ffffff, #fcfdff);
}

.package-target {
    font-family: var(--font-main);
    color: var(--text-light);
    font-size: 0.95rem;
    font-weight: 500;
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-light);
}

.result-value {
    display: block;
    font-weight: 800;
    color: var(--primary-deep);
    font-size: 1.25rem;
    letter-spacing: -0.01em;
}

.packages-note {
    text-align: center;
    font-size: 0.85rem;
    color: var(--text-lighter);
    margin-top: 2rem;
}

/* ---------------- SOLUTIONS PAGE ---------------- */

.dept-nav-section {
    background: white;
}

.dept-nav-grid {
    display: flex;
    overflow-x: auto;
    gap: 10px;
    /* Reduced gap */
    padding-bottom: 10px;
    /* Reduced nav visual gap */
    scrollbar-width: none;
    /* Firefox */
}

/* Hide scrollbar for Chrome, Safari and Opera */
.dept-nav-grid::-webkit-scrollbar {
    display: none;
    scrollbar-width: thin;
}

.dept-nav-grid::-webkit-scrollbar {
    height: 6px;
}

.dept-nav-card {
    flex: 0 0 180px;
    background: white;
    padding: 20px;
    border-radius: 12px;
    text-align: center;
    text-decoration: none;
    color: inherit;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    border: 1px solid var(--border-color);
}

.dept-nav-card:hover {
    background: white;
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.dept-nav-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    margin: 0 auto 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.dept-nav-card h3 {
    font-size: 1rem;
    margin-bottom: 0.5rem;
}

.dept-nav-count {
    font-size: 0.8rem;
    color: var(--text-lighter);
}

/* Solution Dept Sections */
.dept-section {
    padding: 30px 0;
    /* Compact mode */
    border-bottom: 1px solid var(--border-light);
    scroll-margin-top: 80px;
}

.dept-header {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 1rem;
    /* Compact header margin */
}

.dept-header-icon {
    width: 64px;
    height: 64px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.dept-slogan {
    font-size: 1.15rem;
    /* Slight reduce size */
    color: var(--primary-color);
    font-weight: 500;
    margin: 0;
}

.dept-desc {
    max-width: 900px;
    margin-bottom: 1.5rem;
    /* Compact description margin */
    color: var(--text-light);
    font-size: 1.05rem;
    line-height: 1.6;
}

.dept-cases-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.dept-cta {
    background: white;
    padding: 1.5rem 2rem;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
}

.dept-cta p {
    margin: 0;
    font-weight: 500;
    color: var(--text-main);
}

/* ---------------- CASES STYLES ---------------- */
.cases-filter {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 0.5rem 1.25rem;
    border: 1px solid var(--border-color);
    border-radius: 20px;
    background: white;
    color: var(--text-light);
    cursor: pointer;
    transition: var(--transition-base);
    font-size: 0.9rem;
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.cases-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
}

@media (min-width: 992px) {
    .featured-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        max-width: 1000px;
        margin-left: auto;
        margin-right: auto;
    }
}

.case-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition-base);
    border: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
}

.case-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.case-image {
    position: relative;
    height: 200px;
    background: var(--bg-light);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--secondary-color);
    overflow: hidden;
}

.featured-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: bold;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    z-index: 20;
    border: 2px solid white;
    font-family: "Noto Serif SC", serif;
    cursor: default;
    pointer-events: none;
}

.case-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.case-content {
    padding: 1.5rem;
    flex-grow: 1;
}

.case-tags {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.case-tag {
    font-size: 0.75rem;
    padding: 0.25rem 0.75rem;
    border-radius: 4px;
    background: #eef2f6;
    color: var(--text-light);
    font-weight: 500;
}

.case-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
}

.case-card p {
    color: var(--text-light);
    font-size: 0.95rem;
}

/* Horizontal Form Rows */
.form-row {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 1rem;
    /* Compact spacing */
}

.form-row label {
    flex: 0 0 90px;
    font-weight: 600;
    color: var(--text-main);
    font-size: 0.95rem;
    margin-bottom: 0 !important;
    text-align: right;
    /* Align right for cleaner look against input */
}

.form-row input,
.form-row textarea,
.form-row select {
    flex: 1;
}

/* Compact Form (Flat Style) */
.compact-form {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
}

.compact-form .form-row {
    margin-bottom: 0.75rem;
    /* Very tight spacing */
}

.compact-form input,
.compact-form textarea,
.compact-form select {
    border: none;
    border-bottom: 1px solid #eee;
    border-radius: 0;
    padding: 0.6rem 0;
    background: transparent;
    transition: all 0.2s;
}

.compact-form input:focus,
.compact-form textarea:focus,
.compact-form select:focus {
    box-shadow: none;
    border-bottom-color: var(--primary-color);
}

.compact-form .btn-block {
    margin-top: 1.5rem;
    border-radius: 6px;
    /* Slightly punchier button */
}

@media (max-width: 576px) {
    .form-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.25rem;
    }

    .form-row label {
        text-align: left;
    }
}

.case-detail-card {
    background: white;
    border-radius: 16px;
    padding: 3rem;
    box-shadow: var(--shadow-md);
    margin-bottom: 2rem;
    display: flex;
    gap: 2rem;
}

.case-detail-header {
    display: flex;
    gap: 2rem;
    width: 100%;
}

.case-detail-image {
    flex-shrink: 0;
    width: 120px;
    height: 120px;
    background: var(--bg-light);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
}

.case-detail-info h3 {
    font-size: 1.75rem;
    margin-bottom: 1rem;
}

.case-meta {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    color: var(--text-light);
    font-size: 0.9rem;
}

.case-meta-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Achievements */
.achievements-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
}

.panel-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.25rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--border-color);
    margin-bottom: 1.5rem;
}

.publication-item {
    display: flex;
    gap: 1rem;
    padding: 1rem 0;
    border-bottom: 1px solid var(--border-color);
}

.pub-if {
    background: var(--primary-color);
    color: white;
    font-weight: 700;
    font-size: 0.8rem;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    height: fit-content;
    white-space: nowrap;
}

.pub-content h4 {
    font-size: 1rem;
    margin-bottom: 0.25rem;
}

.pub-journal {
    font-size: 0.85rem;
    color: var(--text-light);
    font-style: italic;
}

.grants-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.grant-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: white;
    padding: 1rem;
    border-radius: 8px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
}

.grant-badge {
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    color: white;
}

.grant-badge.nsfc {
    background: #d32f2f;
}

.grant-badge.provincial {
    background: #f57c00;
}

.grant-badge.hospital {
    background: #388e3c;
}

.journals-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}

.journal-logo {
    background: var(--bg-light);
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text-light);
    border-radius: 8px;
}

/* CTA Section */
.cta-section {
    background-color: var(--primary-color);
    color: white;
    text-align: center;
    padding: 3rem 0;
}

.cta-section h2 {
    color: white;
    margin-bottom: 1rem;
}

.cta-section p {
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 2rem;
    font-size: 1.25rem;
}

/* Footer & Global Elements */
.footer {
    background-color: var(--bg-light);
    color: var(--text-main);
    padding: 80px 0 40px;
    border-top: 1px solid var(--border-color);
}

.footer .logo span:last-child {
    color: var(--text-main);
}

.footer p,
.footer-links a {
    color: var(--text-light);
}

.footer-links a:hover {
    color: var(--primary-color);
}

.footer-title {
    color: var(--text-main);
}

.footer-bottom {
    border-top: 1px solid var(--border-color);
    color: var(--text-muted);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-title {
    color: var(--text-main);
    margin-bottom: 1.5rem;
    font-size: 1.125rem;
}

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a {
    color: var(--text-light);
}

.footer-links a:hover {
    color: var(--primary-color);
}

.footer-contact p {
    display: flex;
    align-items: start;
    gap: 0.75rem;
    margin-bottom: 1rem;
    color: var(--text-light);
    font-size: 0.95rem;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid #ddd;
    color: var(--text-lighter);
    font-size: 0.85rem;
}

/* Mobile Bottom Bar & Floating Elements */
.mobile-bottom-bar {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: white;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
    padding: 0.75rem;
    z-index: 1000;
    justify-content: space-around;
    gap: 1rem;
}

.mobile-bottom-bar a {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem;
    border-radius: 6px;
    font-weight: 500;
}

.btn-phone {
    background: var(--bg-light);
    color: var(--text-main);
}

.btn-consult {
    background: var(--primary-color);
    color: white;
}

.floating-wechat {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 1001;
}

.wechat-trigger {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: #07C160;
    color: white;
    border: none;
    box-shadow: 0 4px 12px rgba(7, 193, 96, 0.3);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s;
}

.wechat-trigger:hover {
    transform: scale(1.1);
}

.wechat-popup {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 250px;
    background: white;
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    display: none;
    overflow: hidden;
}

.wechat-popup.active {
    display: block;
}

.wechat-popup-header {
    background: #07C160;
    color: white;
    padding: 0.75rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.wechat-popup-body {
    padding: 1.5rem;
    text-align: center;
}

.wechat-qr-placeholder {
    width: 150px;
    height: 150px;
    background: #f0f2f5;
    margin: 0 auto 1rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #888;
}

.wechat-note {
    font-size: 0.85rem;
    color: var(--text-light);
}

.wechat-close {
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    line-height: 1;
}

/* Responsive */
@media (max-width: 992px) {
    .hero h1 {
        font-size: 2.75rem;
    }

    .nav-menu,
    .nav-cta {
        display: none;
    }

    .menu-toggle {
        display: flex;
    }

    /* Toggle button visible */
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }

    .achievements-grid {
        grid-template-columns: 1fr;
    }

    .service-detail-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .service-detail-visual {
        order: -1;
        aspect-ratio: unset;
        height: 200px;
    }

    .service-detail.section-alt .service-detail-grid {
        direction: ltr;
    }
}

@media (max-width: 768px) {
    .hero {
        padding-top: 100px;
        text-align: center;
    }

    .hero>.container {
        flex-direction: column;
    }

    .hero-actions {
        justify-content: center;
    }

    .hero-image {
        width: 100%;
    }

    .hero-stats {
        justify-content: center;
        flex-wrap: wrap;
        text-align: center;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }

    .mobile-bottom-bar {
        display: flex;
    }

    .footer {
        padding-bottom: 80px;
    }

    /* Space for bottom bar */

    .case-detail-card {
        flex-direction: column;
        padding: 1.5rem;
    }

    .case-detail-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .case-meta {
        justify-content: center;
    }
}

/* =========================================
   Contact Page Redesign (v4) - High Contrast Fix
   ========================================= */

/* Global Page Background for Better Contrast */
body {
    background-color: #f8fafc;
    /* Light blue-grey to make white cards pop */
    color: #334155;
    /* Darker slate for higher definition text */
}

/* Main Layout Grid */
.contact-layout {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 0;
    border-radius: 20px;
    overflow: hidden;
    background: white;
    box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.1);
    /* Softer shadow */
    margin: 3rem auto 5rem;
    /* Separated from header */
    position: relative;
    z-index: 10;
    max-width: 1200px;
    min-height: 700px;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

/* Page Hero Default Style (if missing) - REMOVED DUPLICATE */

/* Left Panel: Form Area */
.contact-main {
    padding: 3.5rem;
    background: white;
}

.contact-header {
    margin-bottom: 2.5rem;
}

.contact-header h2 {
    font-size: 1.75rem;
    color: #0f172a;
    /* Nearly black for max contrast */
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 700;
}

.contact-header h2::before {
    content: '';
    display: block;
    width: 6px;
    height: 24px;
    background: var(--primary-color);
    border-radius: 3px;
}

.contact-subtitle {
    color: #64748b;
    /* Medium contrast for subtitle */
    font-size: 0.95rem;
    margin-left: 1rem;
}

/* Step Indicator */
.step-progress-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 3rem;
    position: relative;
    padding: 0 10px;
}

.step-progress-bar::before {
    content: '';
    position: absolute;
    top: 14px;
    left: 40px;
    right: 40px;
    height: 2px;
    background: #e2e8f0;
    z-index: 0;
}

.step-item {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    width: 100px;
    cursor: default;
}

.step-circle {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: white;
    border: 2px solid #cbd5e1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: #94a3b8;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.step-label {
    font-size: 0.85rem;
    color: #64748b;
    font-weight: 500;
    transition: all 0.3s ease;
}

/* Step Active State */
.step-item.active .step-circle {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
    box-shadow: 0 0 0 4px rgba(8, 97, 121, 0.15);
    /* Stronger focus ring */
}

.step-item.active .step-label {
    color: var(--primary-color);
    font-weight: 700;
}

/* Step Completed State */
.step-item.completed .step-circle {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

/* Right Panel: Sidebar Info */
.contact-sidebar {
    background: linear-gradient(135deg, #007bff 0%, #0056b3 100%);
    /* Slightly darker teal for better white text contrast */
    color: white;
    padding: 3.5rem 2.5rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
}

.contact-sidebar::before {
    content: '';
    position: absolute;
    top: -50px;
    right: -50px;
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0) 70%);
    border-radius: 50%;
}

.sidebar-header h3 {
    font-size: 1.5rem;
    margin-bottom: 2.5rem;
    color: white;
    font-weight: 600;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    padding-bottom: 1.5rem;
}

.contact-methods {
    list-style: none;
    padding: 0;
    margin: 0;
}

.contact-method-item {
    display: flex;
    align-items: flex-start;
    gap: 1.25rem;
    margin-bottom: 2.5rem;
}

.icon-box {
    background: rgba(255, 255, 255, 0.15);
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.method-content h4 {
    font-size: 0.9rem;
    opacity: 0.9;
    /* Increased opacity */
    margin: 0 0 0.35rem 0;
    font-weight: 400;
    color: #e2e8f0;
}

.method-content p {
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0;
    line-height: 1.4;
    color: white;
}

.sidebar-footer {
    background: rgba(0, 0, 0, 0.2);
    padding: 1.5rem;
    border-radius: 12px;
    margin-top: auto;
}

.qr-flex {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.qr-box {
    background: white;
    padding: 6px;
    border-radius: 6px;
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Form Styles */
.form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    display: block;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.6rem;
    font-size: 0.95rem;
}

.form-control {
    width: 100%;
    padding: 0.85rem 1rem;
    border: 1px solid #cbd5e1;
    /* Darker border for visibility */
    border-radius: 8px;
    font-size: 0.95rem;
    color: #0f172a;
    transition: all 0.2s ease;
    background: #f8fafc;
}

.form-control:focus {
    border-color: var(--primary-color);
    background: white;
    box-shadow: 0 0 0 3px rgba(8, 97, 121, 0.1);
    outline: none;
}

/* Option Cards */
.option-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.option-card {
    position: relative;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    padding: 1rem;
    cursor: pointer;
    transition: all 0.2s;
    background: white;
    display: flex;
    align-items: center;
}

.option-card:hover {
    border-color: #94a3b8;
    background: #f1f5f9;
}

.option-card input:checked+.option-content {
    color: var(--primary-color);
    font-weight: 600;
}

.option-card:has(input:checked) {
    border-color: var(--primary-color);
    background: #f0f7f9;
}

.option-content {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.95rem;
    color: #334155;
}

/* Buttons */
.step-actions {
    display: flex;
    justify-content: space-between;
    gap: 1.5rem;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #f1f5f9;
}

.btn-prev {
    padding: 0.85rem 2rem;
    border: 1px solid #cbd5e1;
    background: white;
    color: #475569;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-prev:hover {
    background: #f1f5f9;
    color: #1e293b;
    border-color: #94a3b8;
}

.btn-next {
    padding: 0.85rem 2.5rem;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    box-shadow: 0 4px 6px rgba(8, 97, 121, 0.2);
    cursor: pointer;
    transition: all 0.2s;
    flex-grow: 1;
    text-align: center;
}

.btn-next:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 15px rgba(8, 97, 121, 0.3);
}

/* Responsive */
@media (max-width: 900px) {
    .contact-layout {
        grid-template-columns: 1fr;
        margin-top: 0;
        border-radius: 0;
        box-shadow: none;
        border: none;
    }

    .contact-sidebar {
        order: 2;
        padding: 2.5rem 1.5rem;
    }

    .contact-main {
        padding: 2rem 1.5rem;
    }

    .step-progress-bar {
        margin-bottom: 2rem;
    }

    .option-grid {
        grid-template-columns: 1fr;
    }
}

/* =========================================
   Cases Page Search & Filter Styles
   ========================================= */
.cases-control-panel {
    margin-bottom: 3rem;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.search-box-wrapper {
    margin-bottom: 2.5rem;
    position: relative;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.search-box {
    position: relative;
    display: flex;
    align-items: center;
}

.search-box input {
    width: 100%;
    padding: 1rem 1rem 1rem 3.5rem;
    border: 2px solid #e2e8f0;
    border-radius: 50px;
    font-size: 1.05rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    background: white;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
}

.search-box input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(0, 123, 255, 0.15);
    background: #fff;
}

.search-box .search-icon {
    position: absolute;
    left: 1.25rem;
    color: #94a3b8;
    pointer-events: none;
    transition: color 0.3s ease;
}

/* Handled by :focus-within below */

/* Fix icon color on focus by targeting container if needed, or just let JS handle it, or use :focus-within on container */
.search-box:focus-within .search-icon {
    color: var(--primary-color);
}

.search-stats {
    text-align: center;
    margin-top: 1rem;
    font-size: 0.95rem;
    color: #64748b;
    min-height: 1.5rem;
    opacity: 0;
    transform: translateY(-5px);
    transition: all 0.3s ease;
}

.search-stats.visible {
    display: block !important;
    /* Override inline style */
    opacity: 1;
    transform: translateY(0);
}

/* Ensure filter buttons are responsive */
.cases-filter {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.8rem;
    margin-bottom: 3rem;
}

.filter-btn {
    padding: 0.6rem 1.5rem;
    border-radius: 50px;
    border: 1px solid #e2e8f0;
    background: white;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.95rem;
    font-weight: 500;
}

.filter-btn:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    transform: translateY(-1px);
}

.filter-btn.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    box-shadow: 0 4px 12px rgba(8, 97, 121, 0.2);
}

@media (max-width: 768px) {
    .cases-filter {
        gap: 0.5rem;
    }

    .filter-btn {
        padding: 0.5rem 1rem;
        font-size: 0.85rem;
    }
}

/* =========================================
   Back to Top Button
   ========================================= */
.back-to-top {
    position: fixed;
    bottom: 120px;
    right: 2rem;
    width: 3.5rem;
    height: 3.5rem;
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transform: translateY(20px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 2000;
    border: none;
    outline: none;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    background: var(--primary-dark);
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(8, 97, 121, 0.3);
}

.back-to-top svg {
    width: 24px;
    height: 24px;
    stroke-width: 2.5;
}

@media (max-width: 768px) {
    .back-to-top {
        bottom: 140px;
        /* Above mobile bottom bar */
        right: 1.5rem;
        width: 3rem;
        height: 3rem;
    }
}

/* =========================================
   Lead Gen Modal Styles
   ========================================= */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.7);
    backdrop-filter: blur(4px);
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    opacity: 0;
    transition: opacity 0.3s ease;
}

/* =========================================
   Solutions Page Layout (Sticky Sidebar)
   ========================================= */

.solutions-layout-section {
    padding: 3rem 0 5rem;
    background: #f8fafc;
}

.solutions-layout-container {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 3rem;
    align-items: start;
}

.solutions-sidebar {
    position: sticky;
    top: 120px;
    /* Adjust based on header height */
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    max-height: calc(100vh - 140px);
    overflow-y: auto;
}

.side-nav {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.side-nav-item {
    display: flex;
    align-items: center;
    padding: 0.8rem 1rem;
    border-radius: 8px;
    color: #64748b;
    font-weight: 500;
    transition: all 0.2s ease;
    text-decoration: none;
    position: relative;
}

.side-nav-item:hover {
    background: #f1f5f9;
    color: #0f172a;
}

.side-nav-item.active {
    background: #eff6ff;
    color: var(--primary-color);
    font-weight: 600;
}

.side-nav-icon {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 0.75rem;
}

.side-nav-text {
    flex-grow: 1;
}

.side-nav-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--primary-color);
    opacity: 0;
    transition: opacity 0.2s;
}

.side-nav-item.active .side-nav-dot {
    opacity: 1;
}

/* Solutions Content Area */
.solutions-content {
    display: flex;
    flex-direction: column;
    gap: 4rem;
    /* Spacing between main sections */
}

/* Override container styles for nested sections */
.solutions-content .dept-section {
    padding: 0;
    background: transparent;
}

.solutions-content .container {
    padding: 0;
    margin: 0;
    max-width: none;
}

.solutions-content .dept-header {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    margin-bottom: 1.5rem;
    border: 1px solid #e2e8f0;
}

/* Mobile Responsive */
@media (max-width: 992px) {
    .solutions-layout-container {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .solutions-sidebar {
        position: sticky;
        top: 80px;
        /* Header height */
        z-index: 100;
        padding: 0.75rem;
        margin: -1rem 0 1rem;
        border-radius: 8px;
    }

    .side-nav {
        flex-direction: row;
        overflow-x: auto;
        padding-bottom: 0.5rem;
        -webkit-overflow-scrolling: touch;
        gap: 0.75rem;
    }

    .side-nav-item {
        flex-shrink: 0;
        background: #f8fafc;
        border: 1px solid #e2e8f0;
        padding: 0.5rem 0.8rem;
    }

    .side-nav-text {
        font-size: 0.9rem;
    }

    .side-nav-dot {
        display: none;
    }
}

.modal-overlay.active {
    display: flex;
    opacity: 1;
}

.modal-container {
    background: white;
    width: 100%;
    max-width: 480px;
    border-radius: 16px;
    padding: 2.5rem;
    position: relative;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    transform: translateY(20px);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal-overlay.active .modal-container {
    transform: translateY(0);
}

.modal-close {
    position: absolute;
    top: 1.25rem;
    right: 1.25rem;
    background: transparent;
    border: none;
    font-size: 1.75rem;
    color: #94a3b8;
    cursor: pointer;
    line-height: 1;
    padding: 0.25rem;
    transition: color 0.2s;
    z-index: 50;
}

.modal-close:hover {
    color: #475569;
}

.modal-header {
    text-align: center;
    margin-bottom: 2rem;
}

.modal-icon {
    width: 64px;
    height: 64px;
    background: #e0f2fe;
    color: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
}

.modal-header h3 {
    color: #0f172a;
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.modal-header p {
    color: #64748b;
    font-size: 0.95rem;
    line-height: 1.5;
}

.lead-form .form-group {
    margin-bottom: 1.25rem;
}

.lead-form label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #334155;
    font-size: 0.9rem;
}

.lead-form .form-control {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.2s;
}

.lead-form .form-control:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.1);
}

.lead-form .btn-submit {
    width: 100%;
    margin-top: 1rem;
}

/* =========================================
   Partner Grid Styles (Homepage)
   ========================================= */

.partner-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-top: 2rem;
}

.partner-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 1.5rem;
    background: #fff;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
}

.partner-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1);
    border-color: #cbd5e1;
}

.partner-logo-container {
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.partner-logo-container img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    transition: all 0.3s ease;
}

.partner-item:hover .partner-logo-container img {
    transform: scale(1.1);
}

.partner-item span {
    font-size: 0.95rem;
    color: #334155;
    font-weight: 600;
    line-height: 1.5;
}

@media (max-width: 768px) {
    .partner-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }

    .partner-item {
        padding: 1rem;
    }

    .partner-logo-container {
        width: 60px;
        height: 60px;
        margin-bottom: 0.5rem;
    }

    .partner-item span {
        font-size: 0.85rem;
    }
}

/* Custom Lead Gen Modal Styles */
.lead-gen-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.75);
    backdrop-filter: blur(4px);
    z-index: 9999;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.lead-gen-modal.active {
    display: flex;
    opacity: 1;
}

/* Ensure modal content inside lead-gen-modal is centered and styled */
.lead-gen-modal .modal-content {
    background: white;
    width: 90%;
    max-width: 480px;
    border-radius: 16px;
    padding: 2.5rem;
    position: relative;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    transform: translateY(20px);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.lead-gen-modal.active .modal-content {
    transform: translateY(0);
}

.lead-gen-modal .close-modal {
    position: absolute;
    top: 1.25rem;
    right: 1.25rem;
    background: transparent;
    border: none;
    font-size: 1.75rem;
    color: #94a3b8;
    cursor: pointer;
    line-height: 1;
    padding: 0.25rem;
    transition: color 0.2s;
    z-index: 50;
}

.lead-gen-modal .close-modal:hover {
    color: #475569;
}