/* Reset และ Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Sarabun', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #f4f7fa;
    min-height: 100vh;
    color: #2c3e50;
    line-height: 1.6;
    overflow-x: clip;
}

/* Sidebar */
.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 260px;
    height: 100vh;
    background: linear-gradient(135deg, #059669 0%, #10b981 100%);
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    z-index: 1000;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.sidebar-header {
    padding: 18px 16px 16px;
    background: rgba(0, 0, 0, 0.18);
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
    min-height: 68px;
}

.sidebar-header::before {
    content: '';
    position: absolute;
    top: -28px;
    right: -28px;
    width: 90px;
    height: 90px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.07);
    pointer-events: none;
}

.sidebar-header::after {
    content: '';
    position: absolute;
    bottom: -20px;
    right: 24px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    pointer-events: none;
}

.logo {
    display: flex;
    align-items: center;
    gap: 11px;
    color: white;
    min-width: 0;
    flex-shrink: 0;
}

.logo-icon {
    width: 42px;
    height: 42px;
    background: rgba(255, 255, 255, 0.18);
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25em;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15), inset 0 1px 0 rgba(255,255,255,0.2);
}

.logo-text {
    display: flex;
    flex-direction: column;
    gap: 1px;
    min-width: 0;
}

.logo-text h2 {
    font-size: 1.15em;
    font-weight: 700;
    letter-spacing: 0.2px;
    line-height: 1.15;
    white-space: nowrap;
}

.logo-text span {
    font-size: 0.7em;
    opacity: 0.72;
    letter-spacing: 0.6px;
    font-weight: 400;
    white-space: nowrap;
}

.sidebar-toggle {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.18);
    color: white;
    font-size: 1em;
    cursor: pointer;
    padding: 7px 9px;
    border-radius: 8px;
    transition: all 0.2s ease;
    flex-shrink: 0;
    line-height: 1;
}

.sidebar-toggle:hover {
    background: rgba(255, 255, 255, 0.22);
    border-color: rgba(255, 255, 255, 0.35);
}

.sidebar-nav {
    padding: 16px 0 12px;
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.sidebar-nav::-webkit-scrollbar {
    width: 5px;
}

.sidebar-nav::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.08);
}

.sidebar-nav::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.28);
    border-radius: 4px;
}

.sidebar-nav::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.45);
}

.sidebar-footer {
    padding: 16px 20px;
    background: rgba(0, 0, 0, 0.14);
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    flex-shrink: 0;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px 25px;
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: all 0.3s ease;
    font-size: 1.05em;
    font-weight: 500;
    border-left: 3px solid transparent;
}

.nav-item:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-left-color: white;
}

.nav-item.active {
    background: rgba(255, 255, 255, 0.15);
    color: white;
    border-left-color: white;
}

.nav-item i {
    font-size: 1.3em;
    width: 24px;
    text-align: center;
}

/* ── Dropdown เมนูรายงาน ── */
.nav-dropdown {
    position: relative;
    width: 100%;
}

.nav-dropdown-toggle {
    cursor: pointer;
    user-select: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-dropdown-arrow {
    font-size: 0.8rem !important;
    width: auto !important;
    transition: transform 0.25s ease;
    opacity: 0.8;
}

.nav-dropdown.open .nav-dropdown-arrow {
    transform: rotate(180deg);
}

.nav-submenu {
    display: none;
    background: rgba(0, 0, 0, 0.18);
    border-radius: 8px;
    margin: 2px 10px 6px 10px;
    padding: 4px 0;
    overflow: hidden;
    transition: all 0.25s ease;
}

.nav-dropdown.open .nav-submenu {
    display: block;
}

.nav-subitem {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 18px 10px 24px;
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    font-size: 0.92rem;
    font-weight: 500;
    transition: all 0.2s ease;
    border-left: 3px solid transparent;
}

.nav-subitem i {
    font-size: 1.05rem;
    width: 20px;
    text-align: center;
}

.nav-subitem:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #ffffff;
    border-left-color: #34d399;
    padding-left: 28px;
}

.nav-subitem.active {
    background: rgba(255, 255, 255, 0.2);
    color: #ffffff;
    font-weight: 700;
    border-left-color: #10b981;
}

.nav-dropdown.has-active > .nav-dropdown-toggle {
    background: rgba(255, 255, 255, 0.15);
    color: #ffffff;
    border-left-color: #34d399;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 12px;
    color: white;
}

.user-info i {
    font-size: 2.5em;
}

.user-details {
    display: flex;
    flex-direction: column;
}

.user-name {
    font-weight: 600;
    font-size: 0.95em;
}

.user-role {
    font-size: 0.85em;
    opacity: 0.8;
}

/* Main Content */
.main-content {
    margin-left: 260px;
    min-height: 100vh;
    background: #f4f7fa;
    transition: all 0.3s ease;
    width: calc(100% - 260px);
    box-sizing: border-box;
}

/* Top Bar */
.top-bar {
    background: white;
    padding: 20px 30px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 100;
}

.top-bar-left {
    display: flex;
    align-items: center;
    gap: 15px;
}

.mobile-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5em;
    color: #059669;
    cursor: pointer;
}

.page-title {
    font-size: 1.8em;
    color: #2c3e50;
    font-weight: 600;
}

.top-bar-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.date-display {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #7f8c8d;
    font-size: 0.95em;
}

.date-display i {
    color: #10b981;
}

/* Content Wrapper */
.content-wrapper {
    padding: 30px;
    width: 100%;
    box-sizing: border-box;
}

/* Page Header */
.page-header {
    background: white;
    padding: 25px 30px;
    border-radius: 10px;
    margin-bottom: 30px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    border-left: 4px solid #10b981;
    width: 100%;
    box-sizing: border-box;
}

.header-content h2 {
    color: #2c3e50;
    font-size: 1.8em;
    font-weight: 700;
    margin-bottom: 5px;
}

.header-content p {
    color: #7f8c8d;
    font-size: 1.05em;
}

/* Tab Content */
.tab-content {
    display: none;
    width: 100%;
}

.tab-content.active {
    display: block;
    width: 100%;
}

/* Cards */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    margin-bottom: 30px;
}

.card {
    background: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.05);
    box-sizing: border-box;
    width: 100%;
}

.card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
    transform: translateY(-2px);
}

/* Card Heading with Icon */
.card h3 {
    color: #2c3e50;
    margin-bottom: 20px;
    font-size: 1.3em;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

.card h3 i {
    color: #10b981;
    font-size: 1.1em;
}

.card h3::before {
    display: none;
}

/* Chart Container */
.chart-container {
    position: relative;
    height: 400px;
    width: 100%;
}

.chart-container-sm {
    position: relative;
    height: 300px;
    width: 100%;
}

.chart-container-md {
    position: relative;
    height: 350px;
    width: 100%;
}

/* Overview Charts Layout */
.overview-charts {
    margin-bottom: 30px;
}

.overview-charts .chart-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
    margin-bottom: 25px;
}

.overview-charts .chart-col-1 {
    grid-column: span 1;
}

.overview-charts .chart-col-2 {
    grid-column: span 2;
}

.overview-charts .chart-col-full {
    grid-column: span 3;
}

@media (max-width: 1024px) {
    .overview-charts .chart-row {
        grid-template-columns: 1fr;
    }

    .overview-charts .chart-col-1,
    .overview-charts .chart-col-2,
    .overview-charts .chart-col-full {
        grid-column: span 1;
    }
}

/* Stats Cards */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
    width: 100%;
    box-sizing: border-box;
}

/* Year selection buttons - overview tab */
.year-btn {
    padding: 8px 18px;
    border: 2px solid #10b981;
    border-radius: 20px;
    background: white;
    color: #059669;
    font-family: inherit;
    font-size: 0.95em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s ease;
}

.year-btn:hover {
    background: #ecfdf5;
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(16, 185, 129, 0.2);
}

.year-btn.active {
    background: linear-gradient(135deg, #059669, #10b981);
    color: white;
    border-color: transparent;
    box-shadow: 0 3px 10px rgba(16, 185, 129, 0.4);
}

.stat-card {
    background: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border-left: 4px solid #10b981;
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.stat-card.stat-primary {
    border-left-color: #3498db;
}

.stat-card.stat-success {
    border-left-color: #10b981;
}

.stat-card.stat-warning {
    border-left-color: #f39c12;
}

.stat-card.stat-danger {
    border-left-color: #e74c3c;
}

.stat-card.stat-info {
    border-left-color: #3498db;
}

.stat-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
}

.stat-title {
    font-size: 0.95em;
    color: #7f8c8d;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stat-icon {
    width: 50px;
    height: 50px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5em;
}

.stat-primary .stat-icon {
    background: rgba(52, 152, 219, 0.1);
    color: #3498db;
}

.stat-success .stat-icon {
    background: rgba(16, 185, 129, 0.1);
    color: #10b981;
}

.stat-warning .stat-icon {
    background: rgba(243, 156, 18, 0.1);
    color: #f39c12;
}

.stat-danger .stat-icon {
    background: rgba(231, 76, 60, 0.1);
    color: #e74c3c;
}

.stat-info .stat-icon {
    background: rgba(52, 152, 219, 0.1);
    color: #3498db;
}

.stat-value {
    font-size: 2em;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 5px;
}

.stat-desc {
    font-size: 0.9em;
    color: #95a5a6;
}

/* Tables */
.table-container {
    background: white;
    border-radius: 10px;
    overflow-x: auto;
    overflow-y: auto;
    max-height: 75vh;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    min-width: max-content;
}

.data-table thead {
    background: transparent;
}

.data-table thead th {
    padding: 12px 14px;
    text-align: left;
    font-weight: 600;
    color: white;
    background: linear-gradient(135deg, #059669 0%, #10b981 100%);
    font-size: 0.9em;
    white-space: nowrap;
    letter-spacing: 0.3px;
    /* sticky header */
    position: sticky;
    top: 0;
    z-index: 2;
}

/* First column: sticky left */
.data-table thead th:first-child,
.data-table tbody td:first-child {
    position: sticky;
    left: 0;
}

.data-table thead th:first-child {
    z-index: 4; /* corner cell: sticks in both axes */
}

.data-table tbody td:first-child {
    z-index: 1;
    background: white;
    box-shadow: 2px 0 6px -2px rgba(0, 0, 0, 0.1);
}

.data-table tbody tr:hover td:first-child {
    background: #f8f9fa;
}

.sortable-th {
    cursor: pointer;
    user-select: none;
    white-space: nowrap;
    transition: background 0.2s ease;
}

.sortable-th:hover {
    background: linear-gradient(135deg, #0369a1, #0284c7) !important;
}

.sortable-th.sorted {
    background: linear-gradient(135deg, #1d4ed8, #2563eb) !important;
}

.sort-indicator {
    font-size: 0.75em;
    opacity: 0.55;
    margin-left: 4px;
    display: inline-block;
    transition: opacity 0.2s ease;
}

.sortable-th.sorted .sort-indicator {
    opacity: 1;
}

.data-table tbody tr {
    border-bottom: 1px solid #ecf0f1;
    transition: all 0.2s ease;
}

.data-table tbody tr:hover {
    background: #f8f9fa;
}

.data-table tbody td {
    padding: 10px 14px;
    color: #2c3e50;
    font-size: 0.9em;
    vertical-align: middle;
    white-space: nowrap;
}

/* Monthly Compare – month checkbox grid */
.mc-months-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.mc-month-label {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border: 2px solid rgba(16, 185, 129, 0.25);
    border-radius: 10px;
    cursor: pointer;
    font-size: 0.9em;
    transition: all 0.2s ease;
    background: #f9fafb;
}

.mc-month-label:hover {
    border-color: #10b981;
    background: #ecfdf5;
}

.mc-month-label input[type="checkbox"] {
    accent-color: #059669;
    width: 16px;
    height: 16px;
    cursor: pointer;
}

.mc-month-label:has(input:checked) {
    border-color: #059669;
    background: #d1fae5;
    color: #065f46;
    font-weight: 600;
}

/* Footer */
.content-footer {
    background: white;
    padding: 20px 30px;
    margin-top: 40px;
    border-radius: 10px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
    color: #7f8c8d;
    font-size: 0.9em;
}

.footer-content i {
    color: #10b981;
    margin-right: 8px;
}

/* Responsive */
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
    }

    .sidebar.active {
        transform: translateX(0);
    }

    .main-content {
        margin-left: 0;
    }

    .mobile-toggle {
        display: block;
    }

    .page-title {
        font-size: 1.3em;
    }

    .content-wrapper {
        padding: 15px;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .cards-grid {
        grid-template-columns: 1fr;
    }

    .footer-content {
        flex-direction: column;
        text-align: center;
    }
}

/* Utilities */
.mt-20 {
    margin-top: 20px;
}

.mb-20 {
    margin-bottom: 20px;
}

.text-center {
    text-align: center;
}

/* Filter Styles */
.filter-select {
    padding: 10px 15px;
    border: 2px solid #e0e6ed;
    border-radius: 8px;
    font-size: 1em;
    min-width: 150px;
    transition: all 0.3s ease;
    background: white;
    color: #2c3e50;
}

.filter-select:focus {
    outline: none;
    border-color: #10b981;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1);
}

/* Loading State */
.loading {
    text-align: center;
    padding: 40px;
    color: #10b981;
}

.loading::after {
    content: '';
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 4px solid #e0e6ed;
    border-top-color: #10b981;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Global loading overlay — shown while a tab's data is still being fetched */
#global-loading-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    background: rgba(255,255,255,0.35);
    backdrop-filter: blur(1px);
}
#global-loading-overlay.show { display: flex; }
#global-loading-overlay .global-loading-box {
    background: white;
    padding: 20px 32px;
    border-radius: 12px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.18);
    display: flex;
    align-items: center;
    gap: 14px;
    font-weight: 600;
    color: #059669;
    font-size: 1.05em;
    animation: globalLoadingFadeIn 0.2s ease;
}
#global-loading-overlay .global-loading-spinner {
    width: 26px;
    height: 26px;
    border: 3px solid #d1fae5;
    border-top-color: #10b981;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    flex-shrink: 0;
}
@keyframes globalLoadingFadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* Trend comparison: last full fiscal year vs last 30 days — embedded inline in existing
   .stat-card tiles (tcInlineStatHtml) and as compact table cells (tcTableCell) */
.tc-delta-big {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 2em;
    font-weight: 800;
    margin: 6px 0 8px;
    line-height: 1.1;
}
.tc-delta-big.tc-up { color: #dc2626; }
.tc-delta-big.tc-down { color: #059669; }
.tc-delta-big.tc-flat { color: #9ca3af; font-size: 1.1em; }
.tc-delta-big.tc-neutral-up,
.tc-delta-big.tc-neutral-down { color: #4f46e5; }
.tc-subvalues { font-size: 0.85em; color: #9ca3af; }
.tc-subvalues .tc-sv-value { font-weight: 700; color: #374151; }
.tc-subvalues .tc-sv-unit { margin-left: 4px; }
.tc-subvalues-label { font-size: 0.72em; color: #9ca3af; margin-top: 3px; }

@keyframes pulse-warning {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.4);
        transform: scale(1);
    }
    50% {
        box-shadow: 0 0 0 4px rgba(245, 158, 11, 0);
        transform: scale(1.02);
    }
}

/* Badge Styles */
.badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 0.85em;
    font-weight: 600;
    text-align: center;
}

.badge-info {
    background: #dbeafe;
    color: #1e40af;
}

.badge-warning {
    background: #fef3c7;
    color: #92400e;
}

.badge-success {
    background: #d1fae5;
    color: #065f46;
}

.badge-danger {
    background: #fee2e2;
    color: #991b1b;
}

/* Hourly Analysis Styles */
.filters-bar {
    display: flex;
    gap: 20px;
    padding: 15px 0;
    border-bottom: 2px solid #e5e7eb;
    margin-bottom: 20px;
    flex-wrap: wrap;
    align-items: center;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.filter-group label {
    font-size: 0.9em;
    font-weight: 600;
    color: #374151;
}

.filter-group select,
.filters-bar select,
.map-controls select {
    padding: 8px 12px;
    border: 2px solid #d1d5db;
    border-radius: 8px;
    font-size: 0.9em;
    font-family: inherit;
    background: white;
    min-width: 150px;
    transition: all 0.3s ease;
}

.filter-group select:focus,
.filters-bar select:focus,
.map-controls select:focus {
    outline: none;
    border-color: #059669;
    box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.1);
}

#hourly-tab {
    width: 100%;
}

.charts-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    margin-bottom: 30px;
    width: 100%;
}

.charts-grid .chart-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    width: 100%;
}

/* Table tabs */
.table-tabs {
    display: flex;
    gap: 5px;
    margin-bottom: 15px;
    border-bottom: 2px solid #e5e7eb;
    padding-bottom: 0;
}

.table-tab-btn {
    padding: 10px 20px;
    border: none;
    background: transparent;
    font-family: inherit;
    font-size: 0.9em;
    font-weight: 600;
    color: #6b7280;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: all 0.3s ease;
}

.table-tab-btn:hover {
    color: #059669;
    background: #f0fdf4;
}

.table-tab-btn.active {
    color: #059669;
    border-bottom-color: #059669;
    background: #f0fdf4;
}

.table-tab-content {
    display: none;
}

.table-tab-content.active {
    display: block;
}

/* ========================================================
   ONE PAGE EXECUTIVE DASHBOARD STYLES
   ======================================================== */
.op-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
    background: #ffffff;
    padding: 14px 20px;
    border-radius: 14px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.04);
    border: 1px solid #e5e7eb;
}
.op-year-btn-group {
    display: flex;
    gap: 8px;
    align-items: center;
}
.op-year-btn {
    padding: 8px 18px;
    border: 2px solid #10b981;
    border-radius: 20px;
    background: white;
    color: #059669;
    font-family: inherit;
    font-size: 0.95em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s ease;
}
.op-year-btn:hover {
    background: #ecfdf5;
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(16, 185, 129, 0.2);
}
.op-year-btn.active {
    background: linear-gradient(135deg, #059669, #10b981);
    color: white;
    border-color: transparent;
    box-shadow: 0 3px 10px rgba(16, 185, 129, 0.4);
}
.op-actions {
    display: flex;
    gap: 10px;
    align-items: center;
}
.op-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 18px;
    border-radius: 9px;
    font-size: 0.92rem;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
    font-family: inherit;
}
.op-btn-primary {
    background: linear-gradient(135deg, #059669, #10b981);
    color: #ffffff;
    box-shadow: 0 3px 10px rgba(5,150,105,0.25);
}
.op-btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 5px 14px rgba(5,150,105,0.35);
}
.op-btn-save {
    background: linear-gradient(135deg, #2563eb, #3b82f6);
    color: #ffffff;
    box-shadow: 0 3px 10px rgba(37,99,235,0.25);
}
.op-btn-save:hover {
    transform: translateY(-1px);
    box-shadow: 0 5px 14px rgba(37,99,235,0.35);
}

/* One Page Canvas Container */
.op-canvas-wrap {
    overflow-x: auto;
    padding-bottom: 24px;
}
.op-container {
    width: 1240px;
    margin: 0 auto;
    background: #f8fafc;
    border-radius: 20px;
    box-shadow: 0 10px 35px rgba(0,0,0,0.07);
    border: 1.5px solid #d1fae5;
    padding: 22px 26px 18px 26px;
    position: relative;
    box-sizing: border-box;
    font-family: 'Sarabun', sans-serif;
    color: #1e293b;
}

/* Header */
.op-header {
    background: linear-gradient(135deg, #059669 0%, #10b981 35%, #059669 70%, #047857 100%);
    border-radius: 18px;
    padding: 18px 24px 22px 24px;
    margin-bottom: 20px;
    box-shadow: 0 8px 24px rgba(5, 150, 105, 0.25);
    position: relative;
    overflow: hidden;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.op-header::before {
    content: '';
    position: absolute;
    top: -60px;
    right: -60px;
    width: 320px;
    height: 320px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.18) 0%, transparent 70%);
    pointer-events: none;
}
.op-header::after {
    content: '';
    position: absolute;
    bottom: -80px;
    left: -80px;
    width: 260px;
    height: 260px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.15) 0%, transparent 70%);
    pointer-events: none;
}
.op-header-center h1 {
    margin: 0;
    font-size: 1.85rem;
    font-weight: 800;
    color: #ffffff !important;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.28);
    letter-spacing: -0.2px;
    line-height: 1.25;
}
.op-header-center .op-year-title {
    font-size: 1.45rem;
    font-weight: 800;
    color: #f0fdf4 !important;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.2);
    margin: 3px 0 8px;
}
.op-pill-badge {
    display: inline-block;
    padding: 6px 24px;
    background: #ffffff !important;
    color: #047857 !important;
    border-radius: 999px;
    font-size: 0.96rem;
    font-weight: 800;
    letter-spacing: 0.2px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.16);
}
.op-icon-hospital-3d {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, #dcfce7, #bbf7d0);
    border: 2px solid #86efac;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #059669;
    font-size: 2rem;
    box-shadow: 0 6px 14px rgba(5,150,105,0.18);
}
.op-icon-medical-3d {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, #e0f2fe, #bae6fd);
    border: 2px solid #7dd3fc;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #0284c7;
    font-size: 2rem;
    box-shadow: 0 6px 14px rgba(2,132,199,0.18);
}

/* Top KPI Bar */
.op-kpi-bar {
    display: grid;
    grid-template-columns: 195px 1.15fr 1.35fr 1.05fr 1.2fr 1.2fr;
    background: #ffffff;
    border: 1.5px solid #a7f3d0;
    border-radius: 18px;
    box-shadow: 0 4px 16px rgba(16,185,129,0.08);
    overflow: hidden;
    margin-bottom: 18px;
}
.op-kpi-item {
    padding: 12px 14px;
    display: flex;
    align-items: center;
    gap: 12px;
    border-right: 1px solid #e5e7eb;
}
.op-kpi-item:last-child {
    border-right: none;
}
.op-kpi-prov-badge {
    background: linear-gradient(135deg, #047857, #065f46);
    color: #ffffff;
    border-radius: 14px;
    padding: 8px 12px;
    margin: 6px;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 3px 8px rgba(6,95,70,0.3);
}
.op-kpi-prov-badge .prov-text {
    line-height: 1.15;
}
.op-kpi-prov-badge .prov-sub {
    font-size: 0.76rem;
    font-weight: 500;
    color: #d1fae5;
}
.op-kpi-prov-badge .prov-name {
    font-size: 1.35rem;
    font-weight: 800;
    color: #ffffff;
}
.op-kpi-icon-circle {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    flex-shrink: 0;
}
.op-kpi-icon-green {
    background: #dcfce7;
    color: #16a34a;
    border: 1.5px solid #86efac;
}
.op-kpi-icon-red {
    background: #fee2e2;
    color: #dc2626;
    border: 1.5px solid #fca5a5;
}
.op-kpi-content {
    min-width: 0;
    line-height: 1.2;
}
.op-kpi-label {
    font-size: 0.82rem;
    font-weight: 600;
    color: #4b5563;
    margin-bottom: 2px;
}
.op-kpi-val {
    font-size: 1.45rem;
    font-weight: 800;
    color: #0f172a;
}
.op-kpi-sub {
    font-size: 0.74rem;
    font-weight: 600;
    color: #6b7280;
}
.op-kpi-down {
    color: #16a34a;
}
.op-kpi-up {
    color: #dc2626;
}

/* 3 Hospital Tables Grid */
.op-tables-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-bottom: 18px;
}
.op-card {
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 4px 14px rgba(0,0,0,0.05);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}
.op-card-green {
    border: 1.5px solid #86efac;
}
.op-card-blue {
    border: 1.5px solid #93c5fd;
}
.op-card-orange {
    border: 1.5px solid #fca5a5;
}

.op-card-header {
    padding: 10px 14px;
    display: flex;
    align-items: center;
    gap: 10px;
    color: #ffffff;
}
.op-card-header-green {
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
}
.op-card-header-blue {
    background: linear-gradient(135deg, #1d4ed8 0%, #1e40af 100%);
}
.op-card-header-orange {
    background: linear-gradient(135deg, #ea580c 0%, #c2410c 100%);
}

.op-card-badge {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 1rem;
    flex-shrink: 0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.15);
}
.op-card-badge-gold {
    color: #d97706;
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    border: 1.5px solid #fbbf24;
}
.op-card-badge-blue {
    color: #1d4ed8;
    background: linear-gradient(135deg, #dbeafe, #bfdbfe);
    border: 1.5px solid #60a5fa;
}
.op-card-badge-warn {
    color: #dc2626;
    background: linear-gradient(135deg, #fee2e2, #fecaca);
    border: 1.5px solid #f87171;
}

.op-card-titles {
    min-width: 0;
    line-height: 1.15;
}
.op-card-title {
    font-size: 0.98rem;
    font-weight: 800;
}
.op-card-sub {
    font-size: 0.72rem;
    opacity: 0.92;
    font-weight: 400;
}

/* Tables inside cards */
.op-table {
    width: 100%;
    table-layout: fixed;
    border-collapse: collapse;
    font-size: 0.77rem;
}
.op-table th {
    background: #f8fafc;
    color: #475569;
    font-weight: 700;
    padding: 7px 3px;
    text-align: center;
    font-size: 0.71rem;
    line-height: 1.15;
    border-bottom: 1.5px solid #e2e8f0;
    box-sizing: border-box;
}
.op-table td {
    padding: 8px 3px;
    text-align: center;
    border-bottom: 1px solid #f1f5f9;
    vertical-align: middle;
    box-sizing: border-box;
    font-size: 0.79rem;
}
.op-table th:nth-child(1), .op-table td:nth-child(1) {
    width: 38%;
    text-align: left;
    padding-left: 8px;
    box-sizing: border-box;
}
.op-table th:nth-child(2), .op-table td:nth-child(2) { width: 15%; }
.op-table th:nth-child(3), .op-table td:nth-child(3) { width: 15%; }
.op-table th:nth-child(4), .op-table td:nth-child(4) { width: 16%; white-space: nowrap; }
.op-table th:nth-child(5), .op-table td:nth-child(5) { width: 16%; white-space: nowrap; }

.op-table td.hos-col {
    font-weight: 700;
    color: #1e3a8a;
    text-align: left;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.op-table td.hos-col svg {
    vertical-align: -2px;
    margin-right: 4px;
    display: inline-block;
}
.op-table td.hos-col .hos-name {
    display: inline;
    vertical-align: middle;
}
.op-table .val-curr {
    font-weight: 800;
    font-size: 0.88rem;
    color: #0f172a;
}
.op-table .val-prev {
    color: #64748b;
    font-weight: 600;
}
.op-val-pill {
    display: block;
    height: 4px;
    border-radius: 999px;
    margin-top: 3px;
}
.op-val-pill-green { background: #22c55e; }
.op-val-pill-blue { background: #3b82f6; }
.op-val-pill-red { background: #ef4444; }

/* Bottom Section Grid */
.op-bottom-grid {
    display: grid;
    grid-template-columns: 1fr 1.1fr;
    gap: 16px;
    margin-bottom: 14px;
}
.op-bottleneck-card {
    background: #ffffff;
    border: 1.5px solid #67e8f9;
    border-radius: 16px;
    padding: 14px 16px;
    box-shadow: 0 4px 14px rgba(6,182,212,0.06);
}
.op-executive-card {
    background: linear-gradient(135deg, #ffffff 0%, #f0fdfa 100%);
    border: 1.5px solid #93c5fd;
    border-radius: 16px;
    padding: 14px 18px;
    box-shadow: 0 4px 14px rgba(59,130,246,0.06);
    position: relative;
    overflow: hidden;
}
.op-section-header {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    font-size: 0.98rem;
    margin-bottom: 12px;
}
.op-section-header-teal {
    color: #0e7490;
}
.op-section-header-blue {
    color: #1e40af;
}

/* 4 Bottleneck Sub-Cards */
.op-bottleneck-items {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}
.op-bn-item {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 10px 8px;
    text-align: center;
}
.op-bn-icon {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    margin: 0 auto 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.05rem;
}
.op-bn-title {
    font-size: 0.76rem;
    font-weight: 700;
    color: #475569;
    margin-bottom: 2px;
}
.op-bn-time {
    font-size: 1.05rem;
    font-weight: 800;
    color: #0f172a;
    line-height: 1.15;
}
.op-bn-delta {
    font-size: 0.7rem;
    font-weight: 700;
    margin-top: 3px;
}

/* Executive Bullet Points */
.op-exec-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
    position: relative;
    z-index: 2;
}
.op-exec-item {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 0.86rem;
    color: #1e293b;
    line-height: 1.35;
}
.op-exec-check {
    color: #16a34a;
    font-size: 1rem;
    margin-top: 2px;
    flex-shrink: 0;
}

/* Footer */
.op-footer {
    padding-top: 8px;
    border-top: 1px solid #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.74rem;
    color: #64748b;
    font-weight: 500;
}

/* ========================================================
   ONE PAGE 2 EXECUTIVE DASHBOARD STYLES
   ======================================================== */
.op2-container {
    width: 1240px;
    margin: 0 auto;
    background: #ffffff;
    border-radius: 20px;
    box-shadow: 0 10px 35px rgba(0,0,0,0.08);
    border: 1.5px solid #d1fae5;
    padding: 22px 26px 18px 26px;
    position: relative;
    box-sizing: border-box;
    font-family: 'Sarabun', sans-serif;
    color: #1e293b;
}
.op2-sec-badge {
    background: #047857;
    background: linear-gradient(135deg, #047857 0%, #065f46 100%);
    color: #ffffff !important;
    font-size: 1.05rem;
    font-weight: 800;
    padding: 6px 18px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 3px 8px rgba(4,120,87,0.25);
    margin-bottom: 12px;
    position: relative;
    z-index: 1;
}
.op2-sec-badge span {
    color: #ffffff !important;
    font-weight: 800;
    position: relative;
    z-index: 2;
    display: inline-block;
}
.op2-sec-badge svg {
    position: relative;
    z-index: 2;
    stroke: #ffffff;
}
.op2-sec1-card {
    background: #ffffff;
    border: 1.5px solid #a7f3d0;
    border-radius: 16px;
    box-shadow: 0 4px 14px rgba(16,185,129,0.06);
    padding: 12px 18px;
    margin-bottom: 12px;
    display: grid;
    grid-template-columns: 1.2fr 1fr 1.3fr;
    gap: 16px;
    align-items: center;
}
.op2-sec1-col {
    display: flex;
    align-items: center;
    gap: 14px;
}
.op2-sec1-divider {
    border-right: 1.5px solid #e5e7eb;
    padding-right: 16px;
}
.op2-steps-grid {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: 8px;
    margin-bottom: 18px;
}
.op2-step-card {
    background: #ffffff;
    border: 1.5px solid #e2e8f0;
    border-radius: 12px;
    padding: 8px 6px;
    text-align: center;
    box-shadow: 0 2px 6px rgba(0,0,0,0.03);
}
.op2-step-card-avg {
    border-color: #fde047;
    background: #fefce8;
}
.op2-step-header {
    background: #047857;
    color: #ffffff;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 3px 6px;
    border-radius: 6px;
    margin-bottom: 5px;
    white-space: nowrap;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}
.op2-step-header-gold {
    background: #d97706;
}
.op2-step-time {
    font-size: 1.05rem;
    font-weight: 800;
    color: #0f172a;
    line-height: 1.15;
}
.op2-step-prev {
    font-size: 0.7rem;
    color: #64748b;
    margin: 2px 0;
}
.op2-step-delta {
    font-size: 0.72rem;
    font-weight: 800;
}
.op2-target-grid {
    display: grid;
    grid-template-columns: 1.15fr 1fr 1fr;
    gap: 14px;
    margin-bottom: 18px;
}
.op2-target-box {
    background: #ffffff;
    border: 1.5px solid #a7f3d0;
    border-radius: 16px;
    padding: 14px 18px;
    display: flex;
    align-items: center;
    gap: 14px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.04);
}
.op2-target-box-blue {
    border-color: #93c5fd;
    background: linear-gradient(135deg, #ffffff 0%, #eff6ff 100%);
}
.op2-target-box-green {
    border-color: #86efac;
    background: linear-gradient(135deg, #ffffff 0%, #f0fdf4 100%);
}
.op2-target-box-gold {
    border-color: #fde047;
    background: linear-gradient(135deg, #ffffff 0%, #fefce8 100%);
}
.op2-sec3-card {
    background: #ffffff;
    border: 1.5px solid #a7f3d0;
    border-radius: 16px;
    box-shadow: 0 4px 14px rgba(0,0,0,0.05);
    padding: 14px 18px 10px 18px;
    margin-bottom: 18px;
}
.op2-chart-header-row {
    display: grid;
    grid-template-columns: 240px 1fr 200px;
    align-items: center;
    padding: 4px 6px 10px 6px;
    border-bottom: 1.5px solid #e2e8f0;
    font-weight: 700;
    font-size: 0.85rem;
    color: #475569;
}
.op2-pill-hdr {
    background: #047857;
    color: #ffffff;
    padding: 4px 16px;
    border-radius: 999px;
    font-size: 0.8rem;
    display: inline-block;
    text-align: center;
}
.op2-hos-row {
    display: grid;
    grid-template-columns: 240px 1fr 200px;
    align-items: center;
    padding: 5px 6px;
    border-bottom: 1px solid #f1f5f9;
    font-size: 0.82rem;
}
.op2-hos-row:hover {
    background: #f8fafc;
}
.op2-hos-info {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
    color: #0f172a;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.op2-rank-badge {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #16a34a;
    color: #ffffff;
    font-size: 0.72rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.op2-rank-badge-red {
    background: #dc2626;
}
.op2-bar-track {
    background: #f1f5f9;
    height: 16px;
    border-radius: 4px;
    position: relative;
    display: flex;
    align-items: center;
    margin: 0 12px;
}
.op2-bar-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 0.3s ease;
}
.op2-bar-green {
    background: linear-gradient(90deg, #16a34a, #22c55e);
}
.op2-bar-red {
    background: linear-gradient(90deg, #dc2626, #ef4444);
}
.op2-bar-val {
    position: absolute;
    right: -52px;
    font-weight: 800;
    font-size: 0.85rem;
    color: #0f172a;
}
.op2-change-col {
    display: flex;
    align-items: center;
    gap: 4px;
    font-weight: 800;
    font-size: 0.82rem;
    padding-left: 12px;
}
.op2-legend {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    font-size: 0.76rem;
    font-weight: 700;
    color: #475569;
    padding-top: 8px;
    margin-top: 6px;
    border-top: 1px dashed #cbd5e1;
}
.op2-sec4-grid {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 16px;
    margin-bottom: 14px;
}
.op2-exec-box {
    background: #ffffff;
    border: 1.5px solid #93c5fd;
    border-radius: 16px;
    padding: 14px 18px;
    box-shadow: 0 4px 12px rgba(59,130,246,0.05);
}
.op2-top3-box {
    background: #ffffff;
    border: 1.5px solid #86efac;
    border-radius: 16px;
    padding: 14px 18px;
    box-shadow: 0 4px 12px rgba(34,197,94,0.05);
}
.op2-top3-hdr {
    background: #047857;
    background: linear-gradient(135deg, #047857 0%, #065f46 100%);
    color: #ffffff !important;
    font-size: 0.95rem;
    font-weight: 800;
    padding: 6px 14px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 12px;
    position: relative;
    z-index: 1;
}
.op2-top3-hdr span {
    color: #ffffff !important;
    font-weight: 800;
    position: relative;
    z-index: 2;
    display: inline-block;
}
.op2-top3-hdr i {
    position: relative;
    z-index: 2;
}
.op2-top3-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 10px;
    border-bottom: 1px solid #f1f5f9;
    font-size: 0.86rem;
    font-weight: 700;
}
.op2-top3-row:last-child {
    border-bottom: none;
}

/* One Page Date Filter & Quick Range Styles */
.op-quick-range-group {
    display: flex;
    gap: 6px;
    align-items: center;
}
.op-range-btn {
    padding: 7px 13px;
    border-radius: 8px;
    border: 1.5px solid #cbd5e1;
    background: #ffffff;
    color: #475569;
    font-size: 0.85rem;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s ease;
    font-family: inherit;
}
.op-range-btn:hover {
    border-color: #059669;
    color: #059669;
    background: #f0fdf4;
}
.op-range-btn.active {
    background: #059669;
    color: #ffffff;
    border-color: #059669;
    box-shadow: 0 2px 6px rgba(5,150,105,0.25);
}
.op-custom-range {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #f8fafc;
    padding: 4px 10px;
    border-radius: 10px;
    border: 1.5px solid #e2e8f0;
}
.op-date-input {
    padding: 5px 8px;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    font-size: 0.85rem;
    font-family: inherit;
    color: #0f172a;
    background: #ffffff;
    font-weight: 600;
}
.op-date-input:focus {
    outline: none;
    border-color: #059669;
    box-shadow: 0 0 0 2px rgba(5,150,105,0.15);
}
.op-btn-apply {
    padding: 6px 14px;
    border-radius: 6px;
    border: none;
    background: #059669;
    color: #ffffff;
    font-size: 0.85rem;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: all 0.2s;
    font-family: inherit;
}
.op-btn-apply:hover {
    background: #047857;
}


/* ============================================================
   One Page 3: รายงานการส่งข้อมูลระยะเวลาบริการ
   ============================================================ */
.op3-container {
    width: 1240px;
    margin: 0 auto;
    background: #ffffff;
    border-radius: 20px;
    box-shadow: 0 10px 35px rgba(0,0,0,0.08);
    border: 1.5px solid #d1fae5;
    padding: 22px 26px 18px 26px;
    position: relative;
    box-sizing: border-box;
    font-family: 'Sarabun', sans-serif;
    color: #1e293b;
}

.op3-kpi-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
    margin-bottom: 18px;
}

.op3-kpi-card {
    border-radius: 14px;
    padding: 16px 18px;
    display: flex;
    align-items: center;
    gap: 14px;
    box-shadow: 0 4px 14px rgba(0,0,0,0.03);
    transition: transform 0.2s;
}

.op3-kpi-card:hover {
    transform: translateY(-2px);
}

.op3-kpi-card--total {
    border: 1.5px solid #bfdbfe;
    background: linear-gradient(135deg, #f8fafc 0%, #eff6ff 100%);
}
.op3-kpi-card--green {
    border: 1.5px solid #86efac;
    background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%);
}
.op3-kpi-card--orange {
    border: 1.5px solid #fed7aa;
    background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%);
}
.op3-kpi-card--red {
    border: 1.5px solid #fca5a5;
    background: linear-gradient(135deg, #fef2f2 0%, #fee2e2 100%);
}

.op3-kpi-icon {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.45rem;
    flex-shrink: 0;
    box-shadow: 0 3px 8px rgba(0,0,0,0.06);
}

.op3-kpi-icon--total { background: #dbeafe; color: #1d4ed8; }
.op3-kpi-icon--green { background: #bbf7d0; color: #15803d; }
.op3-kpi-icon--orange { background: #fde68a; color: #b45309; }
.op3-kpi-icon--red { background: #fecaca; color: #b91c1c; }

.op3-kpi-content {
    flex: 1;
    min-width: 0;
}

.op3-kpi-label {
    font-size: 0.86rem;
    font-weight: 700;
    color: #475569;
    margin-bottom: 2px;
}

.op3-kpi-val {
    font-size: 1.85rem;
    font-weight: 800;
    line-height: 1.15;
}

.op3-kpi-sub {
    font-size: 0.76rem;
    font-weight: 600;
    color: #64748b;
    margin-top: 2px;
}

.op3-sec-badge {
    display: inline-block;
    white-space: nowrap;
    padding: 7px 18px;
    border-radius: 20px;
    font-size: 0.95rem;
    font-weight: 800;
    line-height: 1.4;
    margin-bottom: 12px;
    background: #047857;
    background: linear-gradient(135deg, #047857 0%, #065f46 100%);
    color: #ffffff !important;
    box-shadow: 0 4px 12px rgba(4,120,87,0.2);
}

.op3-sec-badge i {
    margin-right: 8px;
    display: inline-block;
    vertical-align: middle;
}

.op3-sec-badge span {
    display: inline-block;
    vertical-align: middle;
    color: #ffffff !important;
}

.op3-table-wrap {
    background: #ffffff;
    border-radius: 14px;
    border: 1px solid #e2e8f0;
    overflow: hidden;
    margin-bottom: 18px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.04);
}

.op3-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.88rem;
    text-align: left;
}

.op3-table th {
    background: #f8fafc;
    color: #334155;
    font-weight: 700;
    padding: 12px 14px;
    border-bottom: 2px solid #e2e8f0;
    white-space: nowrap;
}

.op3-table td {
    padding: 11px 14px;
    border-bottom: 1px solid #f1f5f9;
    color: #1e293b;
    vertical-align: middle;
}

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

.op3-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.82rem;
    font-weight: 700;
    white-space: nowrap;
}

.op3-badge-green {
    background: #dcfce7;
    color: #15803d;
    border: 1px solid #86efac;
}

.op3-badge-orange {
    background: #fef3c7;
    color: #b45309;
    border: 1px solid #fde68a;
}

.op3-badge-red {
    background: #fee2e2;
    color: #b91c1c;
    border: 1px solid #fca5a5;
}

.op3-insights-card {
    background: #f8fafc;
    border: 1.5px solid #e2e8f0;
    border-radius: 14px;
    padding: 16px 20px;
    margin-bottom: 16px;
}

/* ── ⭐️ One Page Surin Summary Report (ops-*) ── */
.ops-container {
    width: 1240px;
    margin: 0 auto 30px auto;
    background: #ffffff;
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 4px 25px rgba(0, 0, 0, 0.07);
    border: 1px solid #e2e8f0;
    font-family: 'Sarabun', sans-serif;
    color: #1e293b;
    box-sizing: border-box;
}

.ops-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 16px;
    border-bottom: 2px solid #e2e8f0;
    margin-bottom: 16px;
}

.ops-header-left {
    display: flex;
    align-items: center;
    gap: 14px;
}

.ops-header-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: linear-gradient(135deg, #059669 0%, #10b981 100%);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    box-shadow: 0 4px 12px rgba(5, 150, 105, 0.25);
    flex-shrink: 0;
}

.ops-header-text h1 {
    font-size: 1.45rem;
    font-weight: 800;
    color: #0f172a;
    line-height: 1.25;
    margin: 0;
}

.ops-header-text p {
    font-size: 0.88rem;
    color: #64748b;
    margin: 3px 0 0 0;
}

.ops-header-right {
    text-align: right;
}

.ops-badge-row {
    display: flex;
    gap: 8px;
    justify-content: flex-end;
    margin-bottom: 4px;
}

.ops-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 700;
}

.ops-badge-gold {
    background: #fef3c7;
    color: #b45309;
    border: 1px solid #fde68a;
}

.ops-badge-teal {
    background: #ecfdf5;
    color: #047857;
    border: 1px solid #a7f3d0;
}

.ops-header-sub {
    font-size: 0.78rem;
    color: #64748b;
}

.ops-kpi-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 10px;
    margin-bottom: 14px;
}

.ops-kpi-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 12px 14px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-shadow: 0 1px 3px rgba(0,0,0,0.02);
}

.ops-kpi-title {
    font-size: 0.82rem;
    font-weight: 700;
    color: #475569;
    margin-bottom: 4px;
}

.ops-kpi-val {
    font-size: 1.65rem;
    font-weight: 800;
    color: #0f172a;
    line-height: 1.2;
}

.ops-kpi-sub {
    font-size: 0.75rem;
    color: #64748b;
    margin-top: 4px;
    white-space: nowrap;
}

.ops-grid-2col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.ops-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 14px 16px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.02);
}

.ops-card-header {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
    font-weight: 800;
    color: #0f172a;
    margin-bottom: 12px;
    padding-bottom: 6px;
    border-bottom: 1px solid #f1f5f9;
}

.ops-steps-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.ops-step-row {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.84rem;
}

.ops-step-name {
    width: 80px;
    font-weight: 700;
    color: #334155;
    flex-shrink: 0;
}

.ops-step-bar-wrap {
    flex: 1;
    background: #f1f5f9;
    height: 16px;
    border-radius: 999px;
    overflow: hidden;
    position: relative;
}

.ops-step-bar {
    height: 100%;
    border-radius: 999px;
    transition: width 0.3s ease;
}

.ops-step-val {
    width: 50px;
    text-align: right;
    font-weight: 800;
    color: #0f172a;
    flex-shrink: 0;
}

.ops-step-diff {
    width: 65px;
    text-align: right;
    font-size: 0.78rem;
    font-weight: 700;
    flex-shrink: 0;
}

.ops-dist-bar-wrap {
    display: flex;
    height: 30px;
    border-radius: 8px;
    overflow: hidden;
    font-size: 0.8rem;
    font-weight: 800;
    color: white;
    text-align: center;
    line-height: 30px;
}

.ops-dist-green { background: #10b981; }
.ops-dist-orange { background: #f59e0b; }
.ops-dist-red { background: #ef4444; }

.ops-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.84rem;
}

.ops-table th {
    background: #f8fafc;
    color: #475569;
    font-weight: 700;
    padding: 7px 10px;
    border-bottom: 1px solid #e2e8f0;
    text-align: left;
}

.ops-table td {
    padding: 7px 10px;
    border-bottom: 1px solid #f1f5f9;
    color: #334155;
}

.ops-table tr:last-child td {
    border-bottom: none;
}

.ops-table-mini th, .ops-table-mini td {
    padding: 5px 6px;
    font-size: 0.78rem;
}

.ops-table-hosp th {
    background: #f1f5f9;
    padding: 8px 10px;
    font-size: 0.82rem;
}

.ops-table-hosp td {
    padding: 8px 10px;
    font-size: 0.83rem;
}

.ops-table-hosp tr:hover td {
    background: #f8fafc;
}

.ops-pill {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 999px;
    font-weight: 800;
    font-size: 0.83rem;
    text-align: center;
}

.ops-pill-green { background: #dcfce7; color: #15803d; }
.ops-pill-yellow { background: #fef3c7; color: #b45309; }
.ops-pill-red { background: #fee2e2; color: #b91c1c; }

.ops-delta-down { color: #16a34a; font-weight: 700; }
.ops-delta-up { color: #dc2626; font-weight: 700; }

.ops-chart-legend {
    display: flex;
    gap: 14px;
    align-items: center;
    font-size: 0.78rem;
    font-weight: 600;
    color: #475569;
}

.ops-legend-item {
    display: flex;
    align-items: center;
    gap: 5px;
}

.ops-legend-box {
    display: inline-block;
    width: 14px;
    height: 10px;
    border-radius: 2px;
}

.ops-legend-dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.ops-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 18px;
    padding-top: 14px;
    border-top: 1px solid #e2e8f0;
    font-size: 0.82rem;
    color: #64748b;
}

/* ============================================================
   Data Audit & Reconciliation Report (.audit-*)
   ============================================================ */
.audit-container {
    background: #ffffff;
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    border: 1px solid #e2e8f0;
    font-family: 'Sarabun', sans-serif;
    color: #1e293b;
    margin-bottom: 24px;
}

.audit-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, #065f46 0%, #047857 50%, #059669 100%);
    color: #ffffff;
    padding: 20px 24px;
    border-radius: 12px;
    margin-bottom: 20px;
    box-shadow: 0 4px 12px rgba(4, 120, 87, 0.15);
    flex-wrap: wrap;
    gap: 16px;
}

.audit-header-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.audit-header-icon {
    width: 52px;
    height: 52px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    backdrop-filter: blur(4px);
    flex-shrink: 0;
}

.audit-header-text h1 {
    font-size: 1.35rem;
    font-weight: 800;
    margin: 0 0 4px 0;
    letter-spacing: -0.3px;
    color: #ffffff;
}

.audit-header-text p {
    font-size: 0.88rem;
    margin: 0 0 8px 0;
    opacity: 0.92;
}

.audit-header-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 0.8rem;
    opacity: 0.9;
    flex-wrap: wrap;
}

.audit-badge-pill {
    background: rgba(255, 255, 255, 0.22);
    border: 1px solid rgba(255, 255, 255, 0.35);
    padding: 6px 14px;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.audit-kpi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 14px;
    margin-bottom: 20px;
}

.audit-kpi-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 14px 16px;
    border-left: 4px solid #059669;
}

.audit-kpi-title {
    font-size: 0.82rem;
    font-weight: 700;
    color: #64748b;
    margin-bottom: 6px;
}

.audit-kpi-val {
    font-size: 1.45rem;
    font-weight: 800;
    color: #0f172a;
    line-height: 1.2;
}

.audit-kpi-sub {
    font-size: 0.78rem;
    color: #64748b;
    margin-top: 4px;
}

.audit-filter-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
    flex-wrap: wrap;
}

.audit-filter-group {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.audit-filter-btn {
    border: 1px solid #cbd5e1;
    background: #ffffff;
    color: #475569;
    padding: 5px 12px;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.audit-filter-btn:hover {
    background: #f1f5f9;
    border-color: #94a3b8;
}

.audit-filter-btn.active {
    background: #047857;
    color: #ffffff;
    border-color: #047857;
}

.audit-search {
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    padding: 6px 12px;
    font-size: 0.82rem;
    width: 220px;
    outline: none;
    font-family: inherit;
}

.audit-search:focus {
    border-color: #047857;
    box-shadow: 0 0 0 2px rgba(4, 120, 87, 0.15);
}

.audit-table-wrap {
    overflow-x: auto;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    margin-bottom: 20px;
}

.audit-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.8rem;
    white-space: nowrap;
}

.audit-table thead th {
    padding: 8px 10px;
    font-weight: 700;
    border-bottom: 1px solid #cbd5e1;
}

.audit-th-grp {
    text-align: center;
    font-size: 0.82rem;
    border-right: 1px solid #e2e8f0;
}

.audit-th-hosp { background: #f1f5f9; color: #334155; }
.audit-th-total { background: #e0f2fe; color: #0369a1; border-left: 2px solid #38bdf8; }
.audit-th-clean { background: #ecfdf5; color: #047857; border-left: 2px solid #34d399; }
.audit-th-dpall { background: #fef3c7; color: #92400e; border-left: 2px solid #fbbf24; }
.audit-th-dpopd { background: #ede9fe; color: #5b21b6; border-left: 2px solid #a78bfa; }

.audit-sub-th th {
    background: #f8fafc;
    color: #475569;
    font-size: 0.76rem;
    border-right: 1px solid #f1f5f9;
}

.audit-table tbody td {
    padding: 7px 10px;
    border-bottom: 1px solid #f1f5f9;
    border-right: 1px solid #f8fafc;
}

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

.audit-table tfoot td {
    padding: 9px 10px;
    background: #f8fafc;
    font-weight: 800;
    border-top: 2px solid #cbd5e1;
    border-right: 1px solid #e2e8f0;
}

/* Badges for Diff & Status */
.audit-diff-zero {
    display: inline-block;
    padding: 2px 7px;
    border-radius: 6px;
    background: #dcfce7;
    color: #15803d;
    font-weight: 700;
    font-size: 0.74rem;
}

.audit-diff-pos {
    display: inline-block;
    padding: 2px 7px;
    border-radius: 6px;
    background: #ffedd5;
    color: #c2410c;
    font-weight: 700;
    font-size: 0.74rem;
}

.audit-diff-neg {
    display: inline-block;
    padding: 2px 7px;
    border-radius: 6px;
    background: #fee2e2;
    color: #b91c1c;
    font-weight: 700;
    font-size: 0.74rem;
}

.audit-waiting {
    display: inline-block;
    padding: 2px 7px;
    border-radius: 6px;
    background: #f1f5f9;
    color: #94a3b8;
    font-weight: 600;
    font-size: 0.72rem;
}

.audit-note-card {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 12px;
    padding: 16px 20px;
    font-size: 0.82rem;
    color: #166534;
}

.audit-note-header {
    font-weight: 800;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.88rem;
}

.audit-note-body ul {
    margin: 0;
    padding-left: 20px;
    line-height: 1.6;
}

.audit-note-body li {
    margin-bottom: 4px;
}

/* ========================================================
   ONE PAGE 5 (EXECUTIVE DASHBOARD 2) - Ex_Onepage3.png
   ======================================================== */
.op5-container {
    width: 1240px;
    margin: 0 auto;
    background: #ffffff;
    border-radius: 20px;
    box-shadow: 0 10px 35px rgba(0,0,0,0.08);
    border: 1.5px solid #d1fae5;
    padding: 22px 26px 18px 26px;
    position: relative;
    box-sizing: border-box;
    font-family: 'Sarabun', sans-serif;
    color: #1e293b;
}

/* Header */
.op5-header {
    background: linear-gradient(135deg, #064e3b 0%, #047857 45%, #059669 100%);
    border-radius: 16px;
    padding: 18px 28px;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 6px 18px rgba(4, 120, 87, 0.25);
    margin-bottom: 14px;
    position: relative;
    overflow: hidden;
}
.op5-header::before {
    content: '';
    position: absolute;
    top: -40px;
    right: -40px;
    width: 140px;
    height: 140px;
    background: radial-gradient(circle, rgba(255,255,255,0.15) 0%, rgba(255,255,255,0) 70%);
    border-radius: 50%;
}
.op5-header-left, .op5-header-right {
    flex-shrink: 0;
}
.op5-header-center {
    text-align: center;
    flex-grow: 1;
}
.op5-header-center h1 {
    font-size: 1.65rem;
    font-weight: 800;
    margin: 0;
    letter-spacing: -0.5px;
    line-height: 1.25;
    color: #ffffff;
    text-shadow: 0 2px 4px rgba(0,0,0,0.15);
}
.op5-header-center .op5-subtitle {
    font-size: 1.35rem;
    font-weight: 800;
    margin-top: 2px;
    color: #fef08a;
}
.op5-header-center .op5-year-title {
    font-size: 1.3rem;
    font-weight: 800;
    margin-top: 2px;
    color: #ffffff;
}
.op5-pill-badge {
    display: inline-block;
    background: #022c22;
    color: #ffffff;
    padding: 4px 18px;
    border-radius: 999px;
    font-size: 0.95rem;
    font-weight: 800;
    margin-top: 6px;
    border: 1px solid rgba(255,255,255,0.2);
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
}

/* Section Badges */
.op5-sec-badge {
    display: inline-block !important;
    white-space: nowrap !important;
    padding: 7px 18px !important;
    border-radius: 20px !important;
    font-size: 0.95rem !important;
    font-weight: 800 !important;
    line-height: 1.4 !important;
    margin-bottom: 12px !important;
    background: #047857 !important;
    background: linear-gradient(135deg, #047857 0%, #065f46 100%) !important;
    color: #ffffff !important;
    box-shadow: 0 4px 12px rgba(4, 120, 87, 0.2) !important;
    position: relative;
    z-index: 1;
}
.op5-sec-badge i,
.op5-sec-badge svg {
    margin-right: 8px !important;
    display: inline-block !important;
    vertical-align: middle !important;
    font-size: 0.95rem !important;
    color: #ffffff !important;
    position: relative;
    z-index: 2;
}
.op5-sec-badge i.fa-lightbulb {
    color: #fde047 !important;
}
.op5-sec-badge span {
    display: inline-block !important;
    vertical-align: middle !important;
    color: #ffffff !important;
    font-size: 0.95rem !important;
    font-weight: 800 !important;
    position: relative;
    z-index: 2;
}

/* Section 1 Card */
.op5-sec1-card {
    background: #ffffff;
    border: 1.5px solid #a7f3d0;
    border-radius: 16px;
    box-shadow: 0 4px 14px rgba(16,185,129,0.06);
    padding: 12px 18px;
    margin-bottom: 12px;
    display: grid;
    grid-template-columns: 1.25fr 1fr 1.35fr;
    gap: 16px;
    align-items: center;
}
.op5-sec1-col {
    display: flex;
    align-items: center;
    gap: 14px;
}
.op5-sec1-divider {
    border-right: 1.5px solid #e5e7eb;
    padding-right: 16px;
}

/* 8 Steps Grid */
.op5-steps-grid {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: 8px;
    margin-bottom: 16px;
}
.op5-step-card {
    background: #ffffff;
    border: 1.5px solid #e2e8f0;
    border-radius: 12px;
    padding: 8px 6px;
    text-align: center;
    box-shadow: 0 2px 6px rgba(0,0,0,0.03);
}
.op5-step-card-avg {
    border-color: #fde047;
    background: #fefce8;
}
.op5-step-header {
    background: #047857;
    color: #ffffff;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 3px 6px;
    border-radius: 6px;
    margin-bottom: 5px;
    white-space: nowrap;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}
.op5-step-header-gold {
    background: #d97706;
}
.op5-step-time {
    font-size: 1.05rem;
    font-weight: 800;
    color: #0f172a;
    line-height: 1.15;
}
.op5-step-prev {
    font-size: 0.7rem;
    color: #64748b;
    margin: 2px 0;
}
.op5-step-delta {
    font-size: 0.72rem;
    font-weight: 800;
}

/* Section 2: Hospital Category Cards Grid */
.op5-targets-container {
    display: grid;
    grid-template-columns: repeat(5, 1fr) 1.6fr;
    gap: 10px;
    margin-bottom: 16px;
    align-items: stretch;
}
.op5-cat-card {
    background: #ffffff;
    border: 1.5px solid #e2e8f0;
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.op5-cat-header {
    padding: 5px 8px;
    font-size: 0.78rem;
    font-weight: 800;
    color: #ffffff;
    text-align: center;
    white-space: nowrap;
}
.op5-cat-body {
    padding: 10px 8px 8px 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex-grow: 1;
}
.op5-cat-icon {
    width: 44px;
    height: 44px;
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.op5-cat-target {
    font-size: 0.74rem;
    font-weight: 700;
    color: #475569;
}
.op5-cat-target-val {
    font-size: 0.95rem;
    font-weight: 800;
    color: #0f172a;
    margin-top: 1px;
}

/* Big Pass Rate Card */
.op5-pass-card {
    background: #ffffff;
    border: 2px solid #86efac;
    border-radius: 14px;
    padding: 12px 16px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    box-shadow: 0 4px 14px rgba(22, 163, 74, 0.08);
}
.op5-pass-header {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1.05rem;
    font-weight: 800;
    color: #15803d;
}
.op5-pass-val {
    font-size: 1.7rem;
    font-weight: 800;
    color: #0f172a;
    line-height: 1.2;
    margin: 4px 0 6px 0;
}
.op5-pass-legend {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.75rem;
    font-weight: 700;
    color: #475569;
}
.op5-legend-item {
    display: flex;
    align-items: center;
    gap: 5px;
}
.op5-legend-box-green {
    width: 14px;
    height: 10px;
    background: #16a34a;
    border-radius: 2px;
}
.op5-legend-box-orange {
    width: 14px;
    height: 10px;
    background: #ea580c;
    border-radius: 2px;
}

/* Section 3: Hospital Tier Groups */
.op5-tiers-wrap {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 16px;
}
.op5-tier-row {
    display: grid;
    grid-template-columns: 210px 1fr;
    gap: 18px;
    align-items: center;
    padding: 12px 18px;
    background: #ffffff;
    border: 1.5px solid #cbd5e1;
    border-radius: 14px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    position: relative;
    transition: all 0.2s ease;
}
.op5-tier-row:hover {
    border-color: #94a3b8;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
}
.op5-tier-badge-card {
    border-radius: 10px;
    padding: 10px 14px;
    color: #ffffff;
    display: flex;
    flex-direction: column;
    gap: 6px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}
.op5-tier-title-row {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.92rem;
    font-weight: 800;
}
.op5-tier-status-pill {
    background: rgba(255, 255, 255, 0.92);
    color: #064e3b;
    font-size: 0.75rem;
    font-weight: 800;
    padding: 3px 10px;
    border-radius: 999px;
    text-align: center;
    display: inline-block;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.op5-hosp-subgrid {
    display: flex;
    flex-direction: column;
    gap: 6px;
    border-left: 2px solid #e2e8f0;
    padding-left: 18px;
}
.op5-hosp-bar-row {
    display: grid;
    grid-template-columns: 200px 1fr 60px;
    align-items: center;
    gap: 14px;
    font-size: 0.84rem;
    padding: 2px 0;
}
.op5-hosp-bar-row:not(:last-child) {
    border-bottom: 1px dashed #f1f5f9;
    padding-bottom: 5px;
}
.op5-hosp-name {
    font-weight: 700;
    color: #1e293b;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.op5-hosp-bar-track {
    background: #f1f5f9;
    height: 14px;
    border-radius: 7px;
    overflow: hidden;
    position: relative;
}
.op5-hosp-bar-fill {
    height: 100%;
    border-radius: 7px;
    transition: width 0.4s ease;
}
.op5-bar-green {
    background: linear-gradient(90deg, #16a34a 0%, #22c55e 100%);
}
.op5-bar-orange {
    background: linear-gradient(90deg, #ea580c 0%, #f97316 100%);
}
.op5-hosp-val {
    font-weight: 800;
    font-size: 0.95rem;
    text-align: right;
    color: #0f172a;
}

/* Section 4: Exec Takeaways & Top 3 */
.op5-sec4-grid {
    display: grid;
    grid-template-columns: 1.6fr 1fr;
    gap: 14px;
    margin-bottom: 12px;
    align-items: stretch;
}
.op5-exec-card {
    background: #ffffff;
    border: 1.5px solid #d1fae5;
    border-radius: 16px;
    padding: 14px 18px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.03);
}
.op5-exec-list {
    list-style: none;
    padding: 0;
    margin: 8px 0 0 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.op5-exec-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 0.86rem;
    color: #1e293b;
    line-height: 1.35;
}
.op5-exec-check {
    color: #16a34a;
    font-size: 1.1rem;
    margin-top: 1px;
    flex-shrink: 0;
}

.op5-top3-card {
    background: #ffffff;
    border: 1.5px solid #d1fae5;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.03);
    display: flex;
    flex-direction: column;
}
.op5-top3-hdr {
    background: linear-gradient(135deg, #047857 0%, #065f46 100%);
    color: #ffffff;
    padding: 8px 14px;
    font-weight: 800;
    font-size: 0.92rem;
    display: flex;
    align-items: center;
    gap: 8px;
}
.op5-top3-body {
    padding: 12px 16px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    justify-content: center;
    flex-grow: 1;
}
.op5-top3-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.88rem;
    border-bottom: 1px dashed #e2e8f0;
    padding-bottom: 6px;
}
.op5-top3-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}
.op5-top3-name {
    font-weight: 700;
    color: #1e293b;
}
.op5-top3-val {
    font-weight: 800;
    color: #047857;
    font-size: 1.05rem;
}

/* Footer */
.op5-footer {
    background: #022c22;
    color: #ecfdf5;
    border-radius: 10px;
    padding: 8px 16px;
    font-size: 0.78rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

