/* ───────────────────────────────────────────────
   Mamata Cloud – Global Stylesheet
   ─────────────────────────────────────────────── */

html { font-size: 14px; }
@media (min-width: 768px) { html { font-size: 15px; } }

body { margin: 0; padding: 0; }

/* ── App Shell ── */
.wrapper {
    min-height: 100vh;
    overflow: hidden;
}

/* ── Sidebar ── */
.sidebar {
    width: 240px;
    min-width: 240px;
    min-height: 100vh;
    transition: width .25s ease, min-width .25s ease;
    overflow: hidden;
}

.sidebar-logo {
    height: 36px;
    width: auto;
    object-fit: contain;
    flex-shrink: 0;
}

.sidebar-title {
    white-space: nowrap;
    overflow: hidden;
    transition: opacity .2s;
    font-size: .9rem;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: .65rem;
    padding: .55rem .85rem;
    color: #444;
    text-decoration: none;
    font-size: .875rem;
    transition: background .15s, color .15s;
    white-space: nowrap;
}

.sidebar-link i { font-size: 1.05rem; flex-shrink: 0; }

.sidebar-link:hover {
    background: #eef2ff;
    color: #1d4ed8;
}

.sidebar-link.active {
    background: #1d4ed8;
    color: #fff !important;
    font-weight: 600;
}

/* Collapsed sidebar */
.sidebar-collapsed .sidebar {
    width: 0;
    min-width: 0;
}

/* ── Main panel ── */
.main-panel {
    min-width: 0;
    overflow: hidden;
}

/* ── Top bar ── */
.topbar {
    height: 52px;
    flex-shrink: 0;
}

/* ── Tables ── */
.mc-table thead th {
    background: #f8fafc;
    font-size: .78rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: #64748b;
    border-bottom: 1px solid #e2e8f0;
    padding: .75rem 1rem;
}

.mc-table tbody td {
    padding: .75rem 1rem;
    border-bottom: 1px solid #f1f5f9;
    vertical-align: middle;
}

.mc-table tbody tr:hover { background: #f8fafc; }

/* ── Stat Cards ── */
.stat-card { transition: transform .15s, box-shadow .15s; border-radius: .75rem !important; }
.stat-card:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,0,0,.1) !important; }

.stat-icon {
    width: 56px;
    height: 56px;
    border-radius: .75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

/* ── Quick-action cards ── */
.quick-action-card {
    transition: transform .15s, box-shadow .15s, border-color .15s;
    border: 1px solid transparent !important;
    border-radius: .75rem !important;
}
.quick-action-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(29,78,216,.12) !important;
    border-color: #c7d2fe !important;
}

/* ── Validity buttons ── */
.validity-btn {
    text-align: center;
    padding: .6rem .5rem;
    line-height: 1.3;
    transition: all .15s;
}

/* ── Cards general ── */
.card { border-radius: .75rem !important; }

/* ── Focus ring ── */
.btn:focus, .form-control:focus, .form-check-input:focus {
    box-shadow: 0 0 0 3px rgba(29,78,216,.18);
}

/* ── Color utilities ── */
.text-purple { color: #7c3aed !important; }
.text-pink   { color: #db2777 !important; }

/* ── Scrollbar (webkit) ── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #94a3b8; }

/* ── Responsive sidebar collapse on mobile ── */
@media (max-width: 768px) {
    .sidebar { width: 0; min-width: 0; position: fixed; z-index: 1000; height: 100vh; }
    .sidebar-collapsed .sidebar,
    .wrapper:not(.sidebar-collapsed) .sidebar { width: 240px; min-width: 240px; }
    .wrapper:not(.sidebar-collapsed) .sidebar { box-shadow: 4px 0 24px rgba(0,0,0,.15); }
}
