﻿/* =========================================
   EMS DASHBOARD - DASH UI THEME
   ========================================= */

:root {
    --primary-color: #6366f1; /* Dash UI Purple */
    --primary-hover: #4f46e5;
    --primary-light: rgba(99, 102, 241, 0.1); /* Soft background for icons */
    --bg-light: #f4f6fc;
    --bg-gradient: linear-gradient(135deg, #f4f6fc 0%, #eef2ff 100%);
    --card-bg: #ffffff;
    --text-main: #1e293b;
    --text-muted: #64748b;
    --border-color: #e2e8f0;
    --radius-lg: 16px;
    --radius-md: 10px;
    --shadow-soft: 0 4px 20px rgba(0, 0, 0, 0.04);
    --shadow-hover: 0 10px 30px rgba(99, 102, 241, 0.15);
}

body {
    background: var(--bg-gradient);
    background-attachment: fixed;
    color: var(--text-main);
    font-family: 'Inter', system-ui, sans-serif;
    overflow-x: hidden;
}

/* 🏔️ HERO SECTION */
.hero-slider {
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    width: 100%;
}

/* Maintain 3:2 ratio */
.hero-slide {
    width: 100%;
    aspect-ratio: 2 / 1; /* 🔥 Key change */
    background-size: cover;
    background-position: center;
    position: relative;
}

    


/* CTA Button overlay styling */
.hero-btn {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    padding: 12px 30px;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 8px;
    box-shadow: 0 4px 14px rgba(99, 102, 241, 0.4);
    transition: all 0.3s ease;
    /* Positioning adjustment based on your image layout */
    margin-top: 250px;
    margin-left: 80px;
}

    .hero-btn:hover {
        background-color: var(--primary-hover);
        transform: translateY(-2px);
        box-shadow: 0 6px 20px rgba(99, 102, 241, 0.6);
    }

/* 📊 STAT CARDS */
.stat-card {
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    padding: 35px 45px; /* Fixed comment syntax error here */
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-soft);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 100%;
    position: relative;
    overflow: hidden;
}

    .stat-card:hover {
        transform: translateY(-4px);
        box-shadow: var(--shadow-hover);
    }

    .stat-card::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 4px;
        background: var(--primary-color);
        transform: scaleX(0);
        transition: transform 0.3s ease;
        transform-origin: left;
    }

    .stat-card:hover::before {
        transform: scaleX(1);
    }

    .stat-card h4 {
        font-size: 1rem;
        font-weight: 600;
        color: var(--text-muted);
        margin-bottom: 10px;
    }

    /* Emphasized Data */
    .stat-card h2 {
        font-size: 2.5rem;
        font-weight: 700;
        color: var(--primary-color);
    }

    .stat-card span {
        font-size: 0.9rem;
        color: var(--text-muted);
    }

/* 🎯 MISSION & SERVICES CARDS */
.section-title {
    text-align: center;
    margin-bottom: 60px;
}

    .section-title h2 {
        font-size: 2rem;
        margin-bottom: 10px;
        font-weight: 700;
    }

    .section-title p {
        color: var(--text-muted);
        font-size: 1.1rem;
    }

/* New Icon Wrapper for cards */
.icon-wrapper {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 55px;
    height: 55px;
    border-radius: 12px;
    background-color: var(--primary-light);
    color: var(--primary-color);
    font-size: 1.5rem;
    margin-bottom: 20px;
}

.mission-card, .service-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 35px 30px;
    transition: all 0.25s ease;
    box-shadow: var(--shadow-soft);
    height: 100%;
}

    .mission-card:hover, .service-card:hover {
        transform: translateY(-5px);
        box-shadow: var(--shadow-hover);
        border-color: var(--primary-color);
    }

    .mission-card h5, .service-card h5 {
        font-weight: 700;
        font-size: 1.15rem;
        margin-bottom: 15px;
        color: var(--text-main);
    }

    .mission-card p, .service-card p {
        color: var(--text-muted);
        font-size: 0.95rem;
        line-height: 1.6;
        margin: 0;
    }

/* Subtle Color Banding for Mission Section */
.bg-light-band {
    background-color: #f8fafc;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

/* JS Animation Classes */
.fade-up-element {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

    .fade-up-element.is-visible {
        opacity: 1;
        transform: translateY(0);
    }
/* Tablets */
@media (max-width: 992px) {
    .hero-slide {
        aspect-ratio: 2 / 1;
    }
}

/* Mobile devices */
@media (max-width: 768px) {
    .hero-slide {
        aspect-ratio: 2 / 1; /* Slightly taller for mobile */
    }

    .carousel-caption {
        bottom: 20px;
    }

    .hero-btn {
        padding: 8px 16px;
        font-size: 14px;
    }
}

/* Small phones */
@media (max-width: 480px) {
    .hero-slide {
        aspect-ratio: 2 / 1; /* Square look for very small screens */
    }

    .hero-btn {
        font-size: 12px;
        padding: 6px 12px;
    }
}
/* =========================================
   RESPONSIVE GRID (2x2 CARD LAYOUT)
   ========================================= */

/* Ensure parent row behaves correctly */
.row {
    display: flex;
    flex-wrap: wrap;
}

/* Default (Desktop ≥ 1200px) */
.stat-card,
.mission-card,
.service-card {
    height: 100%;
}


/* 🔽 Tablets (≤ 992px) → 2x2 GRID */
@media (max-width: 992px) {

    /* Force 2 columns */
    .col-lg-3,
    .col-md-6 {
        width: 50%;
        flex: 0 0 50%;
        max-width: 50%;
    }

    /* Card spacing */
    .stat-card,
    .mission-card,
    .service-card {
        padding: 22px;
    }

        /* Typography */
        .stat-card h2 {
            font-size: 1.9rem;
        }

    .section-title h2 {
        font-size: 1.6rem;
    }

    /* Button adjustment */
    .hero-btn {
        margin-top: 160px;
        margin-left: 30px;
    }
}


/* 🔽 Mobile (≤ 768px) → KEEP 2x2 GRID */
@media (max-width: 768px) {

    /* Still 2 columns */
    .col-lg-3,
    .col-md-6,
    .col-sm-6 {
        width: 50%;
        flex: 0 0 50%;
        max-width: 50%;
    }

    /* Tight spacing */
    .stat-card,
    .mission-card,
    .service-card {
        padding: 18px;
        text-align: center;
    }

        /* Smaller fonts */
        .stat-card h2 {
            font-size: 1.6rem;
        }

        .stat-card h4 {
            font-size: 0.9rem;
        }

        .mission-card h5,
        .service-card h5 {
            font-size: 1rem;
        }

        .mission-card p,
        .service-card p {
            font-size: 0.85rem;
        }

    /* Icon */
    .icon-wrapper {
        width: 48px;
        height: 48px;
        font-size: 1.2rem;
    }

    /* Button */
    .hero-btn {
        margin-top: 130px;
        margin-left: 20px;
        font-size: 13px;
    }
}


/* 🔽 Small Phones (≤ 480px) → 1 COLUMN (Better UX) */
@media (max-width: 480px) {

    /* Switch to single column */
    .col-lg-3,
    .col-md-6,
    .col-sm-6 {
        width: 100%;
        flex: 0 0 100%;
        max-width: 100%;
    }

    /* Card spacing */
    .stat-card,
    .mission-card,
    .service-card {
        padding: 16px;
    }

    /* Text */
    .section-title h2 {
        font-size: 1.2rem;
    }

    .section-title p {
        font-size: 0.85rem;
    }

    /* Button */
    .hero-btn {
        margin-top: 100px;
        margin-left: 15px;
        font-size: 12px;
        padding: 6px 12px;
    }
}