﻿/* =========================================================
   RAPID HMS ENTERPRISE CARDS
   ========================================================= */

/* =========================================================
   CARD
   ========================================================= */

.card {
    background: white;
    border-radius: 22px;
    border: 1px solid #e2e8f0;
    padding: 22px;
    box-shadow: 0 4px 14px rgba(15,23,42,.04);
    transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
    position: relative;
    overflow: hidden;
}

    /* HOVER */
    .card:hover {
        transform: translateY(-2px);
        box-shadow: 0 10px 28px rgba(15,23,42,.08);
        border-color: #dbeafe;
    }

/* =========================================================
   CARD HEADER
   ========================================================= */

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 20px;
}

/* LEFT */
.card-header-left {
    display: flex;
    align-items: center;
    gap: 14px;
}

/* ICON */
.card-icon {
    width: 48px;
    height: 48px;
    min-width: 48px;
    border-radius: 16px;
    background: #eff6ff;
    color: #2563eb;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

/* TITLE */
.card-title {
    margin: 0;
    font-size: 18px;
    font-weight: 700;
    color: #0f172a;
}

/* SUBTITLE */
.card-subtitle {
    margin-top: 4px;
    font-size: 13px;
    color: #64748b;
}

/* =========================================================
   CARD BODY
   ========================================================= */

.card-body {
    position: relative;
}

/* =========================================================
   CARD FOOTER
   ========================================================= */

.card-footer {
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px solid #f1f5f9;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    flex-wrap: wrap;
}

/* =========================================================
   STAT CARD
   ========================================================= */

.stat-card {
    min-height: 160px;
    border-radius: 24px;
    padding: 24px;
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
}

    /* GLOW */
    .stat-card::before {
        content: "";
        position: absolute;
        top: -40px;
        right: -40px;
        width: 120px;
        height: 120px;
        border-radius: 50%;
        background: rgba(255,255,255,.12);
    }

/* LABEL */
.stat-label {
    font-size: 15px;
    opacity: .9;
}

/* VALUE */
.stat-value {
    font-size: 42px;
    font-weight: 800;
    line-height: 1;
}

/* SUBTEXT */
.stat-subtext {
    font-size: 14px;
    opacity: .9;
}

/* =========================================================
   CARD COLORS
   ========================================================= */

.card-primary {
    background: linear-gradient( 135deg, #2563eb, #3b82f6 );
    color: white;
}

.card-success {
    background: linear-gradient( 135deg, #16a34a, #22c55e );
    color: white;
}

.card-warning {
    background: linear-gradient( 135deg, #f59e0b, #fbbf24 );
    color: white;
}

.card-danger {
    background: linear-gradient( 135deg, #dc2626, #ef4444 );
    color: white;
}

/* =========================================================
   MINI CARD
   ========================================================= */

.mini-card {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 18px;
    padding: 18px;
    display: flex;
    align-items: center;
    gap: 16px;
    transition: .2s ease;
}

    /* HOVER */
    .mini-card:hover {
        border-color: #bfdbfe;
        box-shadow: 0 8px 20px rgba(15,23,42,.05);
    }

/* ICON */
.mini-card-icon {
    width: 52px;
    height: 52px;
    border-radius: 16px;
    background: #eff6ff;
    color: #2563eb;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
}

/* TITLE */
.mini-card-title {
    font-size: 14px;
    color: #64748b;
}

/* VALUE */
.mini-card-value {
    margin-top: 4px;
    font-size: 24px;
    font-weight: 700;
    color: #0f172a;
}

/* =========================================================
   INFO CARD
   ========================================================= */

.info-card {
    background: #f8fafc;
    border-radius: 18px;
    padding: 18px;
    border: 1px dashed #cbd5e1;
}

/* =========================================================
   MOBILE
   ========================================================= */

@media(max-width:992px) {

    .card {
        padding: 18px;
        border-radius: 18px;
    }

    .card-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .card-footer {
        flex-direction: column;
        align-items: stretch;
    }

    .stat-card {
        min-height: 140px;
    }

    .stat-value {
        font-size: 34px;
    }
}
