﻿/* Modern UI for BAWACO CSKH Admin - Fixed Layout */

:root {
    --primary: #0066cc;
    --cyan: #00a3d9;
    --dark: #063b73;
    --bg: #f3f7fb;
    --border: #e6edf5;
    --text: #1f2d3d;
    --muted: #6c7a89;
    --shadow: 0 12px 28px rgba(15,45,80,.10);
    --sidebar-width: 286px;
    --topbar-height: 76px;
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
    min-height: 100%;
    font-family: "Segoe UI", Arial, sans-serif;
    color: var(--text);
    background: #f3f7fb;
}

/* =========================
   Layout chính
========================= */

.admin-shell {
    display: block !important;
    min-height: 100vh;
    background: #f3f7fb;
}

/* Sidebar cố định bên trái */
.admin-sidebar {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    width: var(--sidebar-width);
    height: 100vh;
    overflow-y: auto;
    background: linear-gradient(180deg, #0066cc, #063b73);
    color: #ffffff;
    z-index: 1000;
    box-shadow: 10px 0 30px rgba(5,45,91,.18);
}

/* Main luôn né sidebar */
.admin-main {
    margin-left: var(--sidebar-width);
    min-height: 100vh;
    width: calc(100% - var(--sidebar-width));
    background: radial-gradient(circle at top left, rgba(0,163,217,.12), transparent 32%), linear-gradient(180deg, #f7fbff 0%, var(--bg) 100%);
    position: relative;
    z-index: 1;
}

/* Topbar */
.topbar {
    min-height: var(--topbar-height);
    background: rgba(255,255,255,.92);
    backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--border);
    padding: 14px 26px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    position: sticky;
    top: 0;
    z-index: 50;
}

/* Content */
.content-area {
    display: block;
    padding: 26px;
    min-height: calc(100vh - var(--topbar-height));
    background: transparent;
    position: relative;
    z-index: 2;
}

/* =========================
   Sidebar
========================= */

.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 24px 22px;
    border-bottom: 1px solid rgba(255,255,255,.14);
}

.brand-icon {
    width: 54px;
    height: 54px;
    border-radius: 18px;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    box-shadow: 0 8px 20px rgba(0,0,0,.14);
    flex-shrink: 0;
}

.brand-logo-img {
    width: 46px;
    height: 46px;
    object-fit: contain;
}

.brand-title {
    font-weight: 800;
    letter-spacing: .5px;
    font-size: 18px;
    line-height: 1.1;
}

.brand-subtitle {
    color: rgba(255,255,255,.74);
    font-size: 12.5px;
}

.sidebar-nav {
    padding: 16px 14px 24px;
}

.nav-title {
    margin: 20px 12px 9px;
    color: rgba(255,255,255,.58);
    font-size: 11.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .9px;
}

.sidebar-nav .nav-link {
    display: flex;
    align-items: center;
    gap: 10px;
    color: rgba(255,255,255,.9);
    text-decoration: none;
    padding: 12px 14px;
    margin-bottom: 6px;
    border-radius: 16px;
    font-weight: 600;
    transition: .18s;
}

    .sidebar-nav .nav-link:hover {
        background: rgba(255,255,255,.16);
        color: #fff;
        transform: translateX(3px);
    }

/* =========================
   Topbar
========================= */

.page-title {
    font-size: 21px;
    font-weight: 800;
    color: #13293d;
    line-height: 1.15;
}

.page-subtitle {
    color: var(--muted);
    font-size: 13px;
    margin-top: 3px;
}

.user-box {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 8px 10px 8px 14px;
    box-shadow: 0 8px 22px rgba(15,45,80,.06);
    white-space: nowrap;
}

.user-name {
    font-weight: 800;
}

.role-pill {
    background: linear-gradient(135deg, var(--primary), var(--cyan));
    color: #fff;
    border-radius: 999px;
    padding: 5px 10px;
    font-size: 12px;
    font-weight: 800;
}

.btn-logout {
    border-radius: 999px;
    padding: 5px 12px;
}

/* =========================
   Dashboard / Hero
========================= */

.dashboard-hero {
    border-radius: 28px;
    padding: 26px;
    background: linear-gradient(135deg, rgba(0,102,204,.96), rgba(0,166,217,.9));
    color: #fff;
    box-shadow: var(--shadow);
    margin-bottom: 24px;
    overflow: hidden;
    position: relative;
}

    .dashboard-hero:after {
        content: "";
        position: absolute;
        width: 220px;
        height: 220px;
        border-radius: 50%;
        background: rgba(255,255,255,.12);
        right: -70px;
        top: -90px;
    }

.hero-title {
    font-size: 26px;
    font-weight: 850;
    margin-bottom: 6px;
    position: relative;
    z-index: 2;
}

.hero-desc {
    color: rgba(255,255,255,.84);
    margin-bottom: 0;
    position: relative;
    z-index: 2;
}

.hero-meta {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 18px;
    position: relative;
    z-index: 2;
}

.hero-chip {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    border-radius: 999px;
    padding: 8px 12px;
    background: rgba(255,255,255,.16);
    color: #fff;
    font-weight: 650;
    font-size: 13px;
}

/* =========================
   Cards
========================= */

.stat-card {
    border-radius: 24px;
    padding: 20px;
    color: #fff;
    min-height: 132px;
    box-shadow: 0 8px 22px rgba(15,45,80,.08);
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,.22);
}

    .stat-card:after {
        content: "";
        position: absolute;
        right: -28px;
        bottom: -36px;
        width: 120px;
        height: 120px;
        border-radius: 50%;
        background: rgba(255,255,255,.16);
    }

.stat-icon {
    width: 42px;
    height: 42px;
    border-radius: 16px;
    background: rgba(255,255,255,.18);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    margin-bottom: 14px;
}

.stat-label {
    opacity: .9;
    font-size: 13.5px;
    font-weight: 650;
}

.stat-value {
    font-size: 35px;
    font-weight: 900;
    line-height: 1.05;
    margin-top: 4px;
}

.bg-blue {
    background: linear-gradient(135deg, #1d75d8, #00a6d6);
}

.bg-orange {
    background: linear-gradient(135deg, #f59f00, #f76707);
}

.bg-green {
    background: linear-gradient(135deg, #2f9e44, #12b886);
}

.bg-red {
    background: linear-gradient(135deg, #e03131, #fa5252);
}

.modern-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 26px;
    box-shadow: 0 8px 22px rgba(15,45,80,.06);
}

.card-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 18px;
}

.card-title-main {
    font-size: 19px;
    font-weight: 850;
    margin: 0;
}

.quick-tile {
    display: flex;
    align-items: center;
    gap: 14px;
    text-decoration: none;
    color: var(--text);
    background: linear-gradient(180deg, #fff, #f8fbff);
    border: 1px solid var(--border);
    border-radius: 22px;
    padding: 18px;
    height: 100%;
    transition: .18s;
}

    .quick-tile:hover {
        transform: translateY(-3px);
        box-shadow: 0 16px 34px rgba(15,45,80,.12);
        color: var(--primary);
        border-color: rgba(0,102,204,.22);
    }

.quick-icon {
    width: 54px;
    height: 54px;
    border-radius: 19px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 26px;
    background: rgba(0,102,204,.09);
    flex-shrink: 0;
}

.quick-title {
    font-weight: 850;
    margin-bottom: 3px;
}

.quick-desc {
    color: var(--muted);
    font-size: 13px;
    line-height: 1.25;
}

.badge-soft {
    border-radius: 999px;
    padding: 5px 10px;
    font-size: 12px;
    font-weight: 800;
}

.badge-soft-blue {
    background: rgba(0,102,204,.1);
    color: #0066cc;
}

/* =========================
   Feedback List
========================= */

.filter-card {
    border: 1px solid #e6edf5;
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 8px 22px rgba(15,45,80,.06);
}

.feedback-table {
    font-size: 14px;
}

    .feedback-table th {
        background: #f5f9ff;
        color: #27496d;
        font-weight: 800;
        white-space: nowrap;
        border-bottom: 1px solid #e6edf5;
    }

    .feedback-table td {
        vertical-align: middle;
    }

.status-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    padding: 5px 10px;
    font-size: 12px;
    font-weight: 800;
    white-space: nowrap;
}

.status-new {
    background: rgba(0,102,204,.10);
    color: #0066cc;
}

.status-assigned {
    background: rgba(245,159,0,.16);
    color: #d97706;
}

.status-processing {
    background: rgba(111,66,193,.13);
    color: #6f42c1;
}

.status-completed {
    background: rgba(47,158,68,.14);
    color: #2f9e44;
}

.status-rejected {
    background: rgba(224,49,49,.12);
    color: #d92d20;
}

.table-action {
    border-radius: 999px;
    padding: 5px 12px;
    font-size: 12.5px;
    font-weight: 700;
    text-decoration: none;
}

.empty-box {
    border-radius: 22px;
    padding: 32px;
    text-align: center;
    background: #fff;
    border: 1px dashed #c9d7e6;
    color: #6c7a89;
}

.summary-pill {
    border-radius: 999px;
    padding: 7px 12px;
    background: #f3f8ff;
    color: #0066cc;
    font-weight: 800;
    font-size: 13px;
}

/* =========================
   Responsive
========================= */

@media (max-width: 992px) {
    .admin-sidebar {
        position: relative;
        width: 100%;
        height: auto;
        min-height: auto;
    }

    .admin-main {
        margin-left: 0;
        width: 100%;
    }

    .topbar {
        display: block;
        position: relative;
    }

    .user-box {
        margin-top: 12px;
        flex-wrap: wrap;
        justify-content: flex-start;
        border-radius: 18px;
    }

    .content-area {
        padding: 16px;
    }
}
/* =========================
   FIX giao diện khu vực lọc FeedbackList
========================= */

.filter-card {
    background: #ffffff;
    border: 1px solid #e6edf5;
    border-radius: 26px;
    box-shadow: 0 10px 28px rgba(15,45,80,.08);
    padding: 24px !important;
    margin-bottom: 22px;
}

    .filter-card .row {
        display: flex;
        flex-wrap: wrap;
        gap: 16px;
        align-items: end;
    }

    .filter-card .col-lg-4,
    .filter-card .col-lg-2,
    .filter-card .col-md-4,
    .filter-card .col-lg-12 {
        width: auto;
    }

    .filter-card .col-lg-4 {
        flex: 1 1 360px;
    }

    .filter-card .col-lg-2,
    .filter-card .col-md-4 {
        flex: 1 1 180px;
    }

    .filter-card .col-lg-12 {
        flex: 1 1 100%;
    }

.form-label {
    display: block;
    margin-bottom: 8px;
    color: #27496d;
    font-size: 13px;
    font-weight: 800;
}

.form-control,
.form-select {
    width: 100%;
    height: 44px;
    border: 1px solid #d7e3f0;
    border-radius: 15px;
    background: #f9fbfd;
    color: #1f2d3d;
    padding: 0 14px;
    font-size: 14px;
    outline: none;
    transition: all .18s ease;
}

    .form-control:focus,
    .form-select:focus {
        border-color: #0066cc;
        background: #ffffff;
        box-shadow: 0 0 0 4px rgba(0,102,204,.12);
    }

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    border-radius: 999px;
    border: 1px solid transparent;
    padding: 9px 18px;
    font-size: 14px;
    font-weight: 800;
    cursor: pointer;
    text-decoration: none;
    transition: all .18s ease;
}

    .btn:hover {
        transform: translateY(-1px);
    }

.btn-primary {
    background: linear-gradient(135deg, #0066cc, #00a3d9);
    color: #ffffff;
    border-color: transparent;
    box-shadow: 0 8px 18px rgba(0,102,204,.22);
}

    .btn-primary:hover {
        color: #ffffff;
        box-shadow: 0 12px 24px rgba(0,102,204,.28);
    }

.btn-outline-secondary {
    background: #ffffff;
    color: #516173;
    border-color: #d7e3f0;
}

    .btn-outline-secondary:hover {
        color: #0066cc;
        border-color: rgba(0,102,204,.35);
        background: #f5f9ff;
    }

.btn-light {
    background: rgba(255,255,255,.92);
    color: #0066cc;
    border-color: transparent;
}

.rounded-pill {
    border-radius: 999px !important;
}

.px-4 {
    padding-left: 18px !important;
    padding-right: 18px !important;
}

.fw-bold {
    font-weight: 800 !important;
}

.d-flex {
    display: flex !important;
}

.gap-2 {
    gap: 10px !important;
}

.flex-wrap {
    flex-wrap: wrap !important;
}

.ms-lg-auto {
    margin-left: auto !important;
}

.summary-pill {
    display: inline-flex;
    align-items: center;
    min-height: 42px;
    border-radius: 999px;
    padding: 9px 16px;
    background: #edf6ff;
    color: #0066cc;
    font-weight: 900;
    font-size: 14px;
    border: 1px solid rgba(0,102,204,.12);
}

.feedback-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    font-size: 14px;
    overflow: hidden;
}

    .feedback-table th {
        background: #f3f8ff;
        color: #27496d;
        font-weight: 900;
        padding: 12px 10px;
        border-bottom: 1px solid #e6edf5;
        white-space: nowrap;
    }

    .feedback-table td {
        padding: 11px 10px;
        border-bottom: 1px solid #edf2f7;
        vertical-align: middle;
    }

    .feedback-table tr:hover td {
        background: #f8fbff;
    }

.modern-card {
    overflow: hidden;
}

/* =========================
   Dashboard Quick Actions - stable compact header
========================= */

.quick-actions-card {
    padding: 0 !important;
    overflow: hidden;
}

.quick-actions-title-row {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 16px !important;
    margin: 0 !important;
    padding: 22px 24px 18px 24px !important;
    border-bottom: 1px solid #eaf0f7;
    background: linear-gradient(180deg, #ffffff 0%, #f9fcff 100%);
}

.quick-actions-heading {
    min-width: 0;
    flex: 1 1 auto;
}

.quick-kicker {
    display: inline-flex;
    align-items: center;
    margin-bottom: 8px;
    padding: 5px 11px;
    border-radius: 999px;
    background: rgba(0,102,204,.08);
    color: #0066cc;
    font-size: 12px;
    font-weight: 900;
    letter-spacing: .3px;
    text-transform: uppercase;
}

.quick-main-title {
    margin: 0 !important;
    font-size: 21px !important;
    line-height: 1.25 !important;
    color: #13293d !important;
    font-weight: 900 !important;
}

.quick-main-subtitle {
    margin-top: 5px;
    color: #6c7a89;
    font-size: 14px;
    line-height: 1.45;
}

.quick-brand-badge {
    flex: 0 0 auto;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 7px 14px !important;
    border-radius: 999px !important;
    background: #eaf5ff !important;
    color: #0066cc !important;
    font-size: 12px !important;
    font-weight: 900 !important;
    letter-spacing: .2px;
    white-space: nowrap;
    border: 1px solid rgba(0,102,204,.14);
    box-shadow: 0 6px 16px rgba(0,102,204,.08);
}

.quick-actions-body {
    margin: 0 !important;
    padding: 20px 24px 24px 24px !important;
}

.quick-actions-body > [class*="col-"] {
    padding-top: 0;
}

.quick-actions-card .quick-tile {
    min-height: 92px;
}

@media (max-width: 768px) {
    .quick-actions-title-row {
        align-items: flex-start !important;
        flex-direction: column;
        padding: 20px !important;
    }

    .quick-brand-badge {
        align-self: flex-start;
    }

    .quick-actions-body {
        padding: 18px 20px 22px 20px !important;
    }
}
