.buttons-copy {
    margin-top: 4px;
}

/* --------------------------------------------------------------------------
   Responsive buttons (global)
   -------------------------------------------------------------------------- */

/* Table action cells: wrap icon/text buttons instead of overflowing */
.table tbody td:has(.btn) {
    vertical-align: middle;
    white-space: nowrap;
}

.table td form,
.table td form[style*="inline"] {
    display: inline-flex !important;
    margin: 0;
}

.table .btn-group {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 0.25rem;
    vertical-align: middle;
}

.table .btn-group > .btn {
    border-radius: var(--bs-border-radius, 0.25rem) !important;
}

/* Page header / toolbar button rows */
.row [class*="col-"].text-end,
.row [class*="col-"].text-sm-end {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: flex-end;
    align-items: center;
}

.mb-3:has(> .btn),
.mb-4:has(> .btn),
.mb-3:has(> a > .btn),
.mb-4:has(> a > .btn) {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
}

.card-header .d-flex,
.d-flex.gap-2.flex-wrap {
    flex-wrap: wrap;
    gap: 0.5rem;
}

/* Form footer / action rows */
.row .col-md-12:has(> .btn),
.row .col-12:has(> .btn),
.d-flex.justify-content-end:has(.btn),
.d-flex.justify-content-between:has(.btn) {
    flex-wrap: wrap;
    gap: 0.5rem;
}

@media (max-width: 575.98px) {
    /* Stack card header actions on small screens */
    .card-header .d-flex.justify-content-between {
        flex-direction: column;
        align-items: stretch !important;
    }

    .card-header .d-flex.justify-content-between .btn,
    .card-header .d-flex .btn {
        width: 100%;
        justify-content: center;
    }

    /* Full-width toolbar buttons on mobile */
    .row [class*="col-"].text-end .btn,
    .row [class*="col-"].text-sm-end .btn,
    .mb-3 > .btn,
    .mb-3 > a > .btn,
    .mb-4 > .btn,
    .mb-4 > a > .btn {
        flex: 1 1 100%;
        justify-content: center;
        white-space: normal;
        text-align: center;
    }

    /* Keep compact action buttons inside tables */
    .table td .btn-sm,
    .table td .btn-group .btn {
        flex: 0 0 auto;
        width: auto;
    }

    .table .btn-group {
        width: 100%;
        justify-content: flex-start;
    }
}

@media (max-width: 767.98px) {
    .btn:not(.btn-sm):not(.btn-link) {
        white-space: normal;
    }
}

/* --------------------------------------------------------------------------
   Modern forms (global)
   -------------------------------------------------------------------------- */
@media (max-width: 575.98px) {
    body.nephroconnect-theme .card-body form .row:has([type="submit"]) .btn,
    body.nephroconnect-theme .card-body form .row:has(.btn-primary) .btn,
    body.nephroconnect-theme .nc-form-actions .btn {
        flex: 1 1 100%;
        justify-content: center;
    }

    body.nephroconnect-theme .card-body form .row:has([type="submit"]),
    body.nephroconnect-theme .nc-form-actions {
        flex-direction: column;
    }
}

body.nephroconnect-theme .card-body > form,
body.nephroconnect-theme form.nc-form {
    max-width: 100%;
}

body.nephroconnect-theme .card .card-header + .card-body > form > .alert:first-child,
body.nephroconnect-theme form.nc-form > .alert:first-child {
    margin-bottom: 1.25rem;
}

/* --------------------------------------------------------------------------
   Admin dashboard
   -------------------------------------------------------------------------- */
.admin-dash-hero {
    background: linear-gradient(120deg, #4338ca 0%, #4f6ef7 40%, #7c3aed 75%, #a855f7 100%);
    border-radius: 20px;
    box-shadow: 0 18px 45px rgba(79, 110, 247, 0.32);
}

.admin-dash-hero-blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(8px);
    pointer-events: none;
    opacity: 0.55;
}

.admin-dash-hero-blob--1 {
    width: 280px;
    height: 280px;
    top: -120px;
    right: -60px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.35), transparent 70%);
}

.admin-dash-hero-blob--2 {
    width: 220px;
    height: 220px;
    bottom: -130px;
    left: 20%;
    background: radial-gradient(circle, rgba(168, 85, 247, 0.55), transparent 70%);
}

.admin-dash-eyebrow {
    color: rgba(255, 255, 255, 0.75);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.admin-dash-clock-wrap {
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 14px;
    padding: 0.5rem 1.25rem;
    backdrop-filter: blur(6px);
}

.admin-dash-clock {
    font-size: 1.75rem;
    letter-spacing: 0.04em;
    font-variant-numeric: tabular-nums;
}

.admin-dash-hero-chip {
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 14px;
    padding: 0.75rem 0.5rem;
    text-align: center;
    color: #fff;
    backdrop-filter: blur(6px);
    transition: transform 0.2s ease, background 0.2s ease;
}

.admin-dash-hero-chip:hover {
    transform: translateY(-3px);
    background: rgba(255, 255, 255, 0.22);
}

.admin-dash-hero-chip i {
    font-size: 1.35rem;
    display: block;
    margin-bottom: 0.15rem;
    opacity: 0.9;
}

.admin-dash-hero-chip span {
    display: block;
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.1;
}

.admin-dash-hero-chip small {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.admin-dash-card {
    border: none;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(15, 23, 42, 0.06);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.admin-dash-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.1);
}

/* --------------------------------------------------------------------------
   Center metrics (redesigned stat cards)
   -------------------------------------------------------------------------- */
.admin-dash-metrics-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    padding: 0.25rem 0 0.5rem;
}

.admin-dash-metrics-title {
    font-size: 1.15rem;
    font-weight: 700;
    color: #0f172a;
    margin: 0;
}

.admin-dash-live-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.35rem 0.85rem;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #059669;
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.25);
}

.admin-dash-live-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #10b981;
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.5);
    animation: adminDashLivePulse 2s ease infinite;
}

@keyframes adminDashLivePulse {
    0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.45); }
    70% { box-shadow: 0 0 0 8px rgba(16, 185, 129, 0); }
    100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

.admin-dash-metric {
    --metric-accent: #3b82f6;
    --metric-accent-soft: rgba(59, 130, 246, 0.12);
    --metric-accent-glow: rgba(59, 130, 246, 0.18);
    position: relative;
    display: flex;
    align-items: flex-start;
    gap: 0.9rem;
    padding: 1.15rem 1.1rem;
    border-radius: 18px;
    background: #ffffff;
    border: 1px solid #e8edf3;
    color: inherit;
    text-decoration: none;
    height: 100%;
    overflow: hidden;
    isolation: isolate;
    box-shadow: 0 4px 18px rgba(15, 23, 42, 0.05);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.admin-dash-metric::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--metric-accent), transparent);
    opacity: 0.9;
}

.admin-dash-metric::after {
    content: "";
    position: absolute;
    right: -28px;
    top: -28px;
    width: 110px;
    height: 110px;
    border-radius: 50%;
    background: var(--metric-accent-soft);
    z-index: 0;
    transition: transform 0.3s ease;
}

.admin-dash-metric:hover {
    transform: translateY(-4px);
    border-color: var(--metric-accent-glow);
    box-shadow: 0 14px 32px var(--metric-accent-glow);
    color: inherit;
}

.admin-dash-metric:hover::after {
    transform: scale(1.12);
}

.admin-dash-metric:hover .admin-dash-metric__arrow {
    opacity: 1;
    transform: translateX(0);
}

.admin-dash-metric__icon {
    position: relative;
    z-index: 1;
    width: 48px;
    height: 48px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.45rem;
    flex-shrink: 0;
    color: var(--metric-accent);
    background: var(--metric-accent-soft);
    border: 1px solid var(--metric-accent-glow);
}

.admin-dash-metric__body {
    position: relative;
    z-index: 1;
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.admin-dash-metric__label {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: #64748b;
}

.admin-dash-metric__value {
    font-size: 1.55rem;
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.02em;
    color: #0f172a;
    font-variant-numeric: tabular-nums;
}

.admin-dash-metric__value small {
    font-size: 0.95rem;
    font-weight: 600;
    color: #94a3b8;
    margin-left: 0.1rem;
}

.admin-dash-metric__value--currency {
    font-size: 1.25rem;
}

.admin-dash-metric__hint {
    font-size: 0.75rem;
    color: #94a3b8;
    line-height: 1.35;
}

.admin-dash-metric__hint strong {
    color: #475569;
    font-weight: 600;
}

.admin-dash-metric__progress {
    height: 5px;
    border-radius: 999px;
    background: #e8edf3;
    overflow: hidden;
    margin: 0.2rem 0 0.1rem;
}

.admin-dash-metric__progress-fill {
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--metric-accent), #a78bfa);
    transition: width 0.6s ease;
}

.admin-dash-metric__trend {
    display: inline-flex;
    align-items: center;
    gap: 0.15rem;
    margin-left: 0.35rem;
    padding: 0.1rem 0.4rem;
    border-radius: 999px;
    font-size: 0.68rem;
    font-weight: 700;
}

.admin-dash-metric__trend.is-up {
    color: #059669;
    background: rgba(16, 185, 129, 0.12);
}

.admin-dash-metric__trend.is-down {
    color: #dc2626;
    background: rgba(239, 68, 68, 0.12);
}

.admin-dash-metric__arrow {
    position: relative;
    z-index: 1;
    align-self: center;
    font-size: 1.25rem;
    color: #cbd5e1;
    opacity: 0;
    transform: translateX(-6px);
    transition: opacity 0.2s ease, transform 0.2s ease, color 0.2s ease;
    flex-shrink: 0;
}

.admin-dash-metric:hover .admin-dash-metric__arrow {
    color: var(--metric-accent);
}

.admin-dash-metric--alert {
    animation: adminDashMetricAlert 2.5s ease infinite;
}

@keyframes adminDashMetricAlert {
    0%, 100% { border-color: #e8edf3; }
    50% { border-color: rgba(239, 68, 68, 0.45); }
}

.admin-dash-metric--primary {
    --metric-accent: #3b82f6;
    --metric-accent-soft: rgba(59, 130, 246, 0.12);
    --metric-accent-glow: rgba(59, 130, 246, 0.2);
}

.admin-dash-metric--success {
    --metric-accent: #22c55e;
    --metric-accent-soft: rgba(34, 197, 94, 0.12);
    --metric-accent-glow: rgba(34, 197, 94, 0.2);
}

.admin-dash-metric--info {
    --metric-accent: #06b6d4;
    --metric-accent-soft: rgba(6, 182, 212, 0.12);
    --metric-accent-glow: rgba(6, 182, 212, 0.2);
}

.admin-dash-metric--warning {
    --metric-accent: #f59e0b;
    --metric-accent-soft: rgba(245, 158, 11, 0.14);
    --metric-accent-glow: rgba(245, 158, 11, 0.22);
}

.admin-dash-metric--purple {
    --metric-accent: #8b5cf6;
    --metric-accent-soft: rgba(139, 92, 246, 0.12);
    --metric-accent-glow: rgba(139, 92, 246, 0.2);
}

.admin-dash-metric--teal {
    --metric-accent: #14b8a6;
    --metric-accent-soft: rgba(20, 184, 166, 0.12);
    --metric-accent-glow: rgba(20, 184, 166, 0.2);
}

.admin-dash-metric--danger {
    --metric-accent: #ef4444;
    --metric-accent-soft: rgba(239, 68, 68, 0.12);
    --metric-accent-glow: rgba(239, 68, 68, 0.2);
}

.admin-dash-metric--revenue {
    --metric-accent: #6366f1;
    --metric-accent-soft: rgba(99, 102, 241, 0.12);
    --metric-accent-glow: rgba(99, 102, 241, 0.22);
    background: linear-gradient(145deg, #ffffff 0%, #f8faff 55%, #f5f3ff 100%);
}

.admin-dash-action {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1rem 0.5rem;
    border-radius: 12px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    color: #334155;
    text-decoration: none;
    font-size: 0.8rem;
    font-weight: 500;
    text-align: center;
    height: 100%;
    transition: all 0.2s ease;
}

.admin-dash-action i {
    font-size: 1.5rem;
    color: #4f6ef7;
}

.admin-dash-action:hover {
    background: #4f6ef7;
    border-color: #4f6ef7;
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(79, 110, 247, 0.3);
}

.admin-dash-action:hover i {
    color: #fff;
}

.admin-dash-alert {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    border-radius: 10px;
    margin-bottom: 0.65rem;
    text-decoration: none;
    color: inherit;
    transition: background 0.2s ease;
}

.admin-dash-alert i {
    font-size: 1.35rem;
    margin-top: 0.1rem;
}

.admin-dash-alert strong {
    display: block;
    font-size: 0.9rem;
}

.admin-dash-alert small {
    color: #64748b;
}

.admin-dash-alert--warning { background: #fffbeb; border: 1px solid #fde68a; }
.admin-dash-alert--warning i { color: #d97706; }
.admin-dash-alert--danger { background: #fef2f2; border: 1px solid #fecaca; }
.admin-dash-alert--danger i { color: #dc2626; }
.admin-dash-alert--success { background: #f0fdf4; border: 1px solid #bbf7d0; }
.admin-dash-alert--success i { color: #16a34a; }
.admin-dash-alert--muted { background: #f8fafc; border: 1px solid #e2e8f0; }
.admin-dash-alert--muted i { color: #64748b; }

.admin-dash-stock-list li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.4rem 0;
    border-bottom: 1px dashed #e2e8f0;
    font-size: 0.85rem;
}

.admin-dash-stock-list li:last-child {
    border-bottom: none;
}

.admin-dash-schedule-card {
    overflow: hidden;
}

.admin-dash-schedule-header {
    background: linear-gradient(135deg, #4f6ef7 0%, #7c3aed 100%);
    border: none;
    color: #fff;
    padding: 1.25rem 1.5rem;
}

.admin-dash-schedule-header h4 {
    color: #fff;
}

.admin-dash-date-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 88px;
    height: 68px;
    padding: 0.5rem;
    border-radius: 10px;
    border: 1px solid #e2e8f0;
    background: #fff;
    color: #64748b;
    text-decoration: none;
    cursor: pointer;
    font: inherit;
    transition: all 0.2s ease;
}

.admin-dash-date-btn span {
    font-size: 0.75rem;
}

.admin-dash-date-btn strong {
    font-size: 0.8rem;
    color: #1e293b;
}

.admin-dash-date-btn:hover,
.admin-dash-date-btn.active {
    background: #4f6ef7;
    border-color: #4f6ef7;
    color: #fff;
    box-shadow: 0 4px 14px rgba(79, 110, 247, 0.35);
}

.admin-dash-date-btn:hover strong,
.admin-dash-date-btn.active strong {
    color: #fff;
}

.admin-dash-table thead {
    background: #f8fafc;
}

.admin-dash-table thead th {
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: #64748b;
    border-bottom: 2px solid #e2e8f0;
}

.admin-dash-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, #4f6ef7, #7c3aed);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.admin-dash-avatar--lg {
    width: 48px;
    height: 48px;
    font-size: 1.1rem;
}

.admin-dash-patient-card {
    padding: 1rem;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    background: #fff;
    height: 100%;
    transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

.admin-dash-patient-card:hover {
    border-color: #c7d2fe;
    box-shadow: 0 4px 16px rgba(79, 110, 247, 0.1);
}

.min-width-0 {
    min-width: 0;
}

.admin-dash-schedule-loading {
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.75);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    border-radius: 8px;
}

.admin-dash-date-btn:disabled {
    opacity: 0.65;
    cursor: wait;
}

/* Panel polish for the bento dashboard */
.admin-dash .nc-panel {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.admin-dash .nc-panel:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.1);
}

.admin-dash .nc-panel-title,
.admin-dash .card-title {
    position: relative;
    display: flex;
    align-items: center;
}

/* Accent bar before section titles inside cards */
.admin-dash .card-title:not(.mb-0)::before {
    content: "";
    width: 4px;
    height: 1.05em;
    border-radius: 4px;
    margin-right: 0.6rem;
    background: linear-gradient(180deg, #4f6ef7, #7c3aed);
}

.admin-dash .admin-dash-action {
    background: linear-gradient(180deg, #ffffff, #f8fafc);
}

.admin-dash .mini-stats-wid {
    border-radius: 16px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.admin-dash .mini-stats-wid:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.1);
}

/* Staggered entrance animation for dashboard tiles */
@keyframes adminDashFadeUp {
    from { opacity: 0; transform: translateY(14px); }
    to { opacity: 1; transform: translateY(0); }
}

.admin-dash-hero,
.admin-dash .bento-grid > * {
    animation: adminDashFadeUp 0.5s ease both;
}

.admin-dash .bento-grid > *:nth-child(1) { animation-delay: 0.02s; }
.admin-dash .bento-grid > *:nth-child(2) { animation-delay: 0.06s; }
.admin-dash .bento-grid > *:nth-child(3) { animation-delay: 0.1s; }
.admin-dash .bento-grid > *:nth-child(4) { animation-delay: 0.14s; }
.admin-dash .bento-grid > *:nth-child(5) { animation-delay: 0.18s; }
.admin-dash .bento-grid > *:nth-child(6) { animation-delay: 0.22s; }
.admin-dash .bento-grid > *:nth-child(7) { animation-delay: 0.26s; }
.admin-dash .bento-grid > *:nth-child(8) { animation-delay: 0.3s; }

@media (prefers-reduced-motion: reduce) {
    .admin-dash-hero,
    .admin-dash .bento-grid > * {
        animation: none;
    }

    .admin-dash-live-dot,
    .admin-dash-metric--alert {
        animation: none;
    }
}

/* --------------------------------------------------------------------------
   Bento grid layout (admin dashboard)
   -------------------------------------------------------------------------- */
.bento-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    grid-auto-rows: minmax(10px, auto);
    gap: 1.25rem;
    margin-bottom: 1.5rem;
}

/* Each direct child is a bento tile: equal stretch, no stray margins */
.bento-grid > * {
    margin: 0 !important;
    min-width: 0;
}

/* Base: single column on mobile */
.bento-grid > [class*="bento-col-"],
.bento-grid > .bento-third {
    grid-column: span 12;
}

/* Tile surface (applied to wrappers that aren't already cards/panels) */
.bento-tile {
    background: #ffffff;
    border: 1px solid #e8edf3;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(15, 23, 42, 0.05);
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
}

/* Unify radius of existing cards/panels when used as bento tiles */
.bento-grid > .card,
.bento-grid > .nc-panel,
.bento-grid > .admin-dash-metric {
    border-radius: 16px !important;
}

.bento-grid > .card {
    height: 100%;
}

.bento-grid > .nc-panel {
    display: flex;
    flex-direction: column;
    height: 100%;
}

/* Small screens: stats two-up */
@media (min-width: 576px) {
    .bento-grid > .bento-col-3,
    .bento-grid > .bento-col-2 {
        grid-column: span 6;
    }
}

/* Tablets */
@media (min-width: 768px) {
    .bento-grid > .bento-third {
        grid-column: span 6;
    }
}

/* Laptops */
@media (min-width: 992px) {
    .bento-grid > .bento-col-3 {
        grid-column: span 3;
    }
    .bento-grid > .bento-col-2 {
        grid-column: span 4;
    }
    .bento-grid > .bento-col-4 {
        grid-column: span 12;
    }
    .bento-grid > .bento-col-6 {
        grid-column: span 6;
    }
    .bento-grid > .bento-col-8 {
        grid-column: span 12;
    }
    .bento-grid > .bento-third {
        grid-column: span 4;
    }
}

/* Desktops / wide */
@media (min-width: 1200px) {
    .bento-grid > .bento-col-2 {
        grid-column: span 2;
    }
    .bento-grid > .bento-col-3 {
        grid-column: span 3;
    }
    .bento-grid > .bento-col-4 {
        grid-column: span 4;
    }
    .bento-grid > .bento-col-6 {
        grid-column: span 6;
    }
    .bento-grid > .bento-col-8 {
        grid-column: span 8;
    }
    .bento-grid > .bento-third {
        grid-column: span 4;
    }
}

/* Metric tiles fill their bento cell */
.bento-grid > .admin-dash-metric {
    height: 100%;
}

/* Quick actions tile body fills nicely */
.bento-grid > .card > .card-body {
    width: 100%;
}

/* --------------------------------------------------------------------------
   Dark mode overrides for admin dashboard components
   -------------------------------------------------------------------------- */
html[data-bs-theme="dark"] .bento-tile {
    background: #131c2e;
    border-color: #25324a;
    box-shadow: 0 6px 28px rgba(0, 0, 0, 0.45);
}

html[data-bs-theme="dark"] .admin-dash-metrics-title {
    color: #e2e8f0;
}

html[data-bs-theme="dark"] .admin-dash-live-badge {
    color: #34d399;
    background: rgba(16, 185, 129, 0.15);
    border-color: rgba(16, 185, 129, 0.3);
}

html[data-bs-theme="dark"] .admin-dash-metric {
    background: #131c2e;
    border-color: #25324a;
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.35);
}

html[data-bs-theme="dark"] .admin-dash-metric--revenue {
    background: linear-gradient(145deg, #131c2e 0%, #151f35 55%, #1a1a3e 100%);
}

html[data-bs-theme="dark"] .admin-dash-metric__label {
    color: #93a4bd;
}

html[data-bs-theme="dark"] .admin-dash-metric__value {
    color: #f1f5f9;
}

html[data-bs-theme="dark"] .admin-dash-metric__value small {
    color: #64748b;
}

html[data-bs-theme="dark"] .admin-dash-metric__hint {
    color: #64748b;
}

html[data-bs-theme="dark"] .admin-dash-metric__hint strong {
    color: #cbd5e1;
}

html[data-bs-theme="dark"] .admin-dash-metric__progress {
    background: #1e293b;
}

html[data-bs-theme="dark"] .admin-dash-metric__arrow {
    color: #475569;
}

html[data-bs-theme="dark"] .admin-dash-action {
    background: linear-gradient(180deg, #16223a, #0f1828);
    border-color: #25324a;
    color: #cbd5e1;
}

html[data-bs-theme="dark"] .admin-dash-action i {
    color: #818cf8;
}

html[data-bs-theme="dark"] .admin-dash-action:hover {
    background: #4f6ef7;
    border-color: #4f6ef7;
    color: #fff;
}

html[data-bs-theme="dark"] .admin-dash-action:hover i {
    color: #fff;
}

html[data-bs-theme="dark"] .admin-dash-date-btn {
    background: #0f1828;
    border-color: #25324a;
    color: #93a4bd;
}

html[data-bs-theme="dark"] .admin-dash-date-btn strong {
    color: #e2e8f0;
}

html[data-bs-theme="dark"] .admin-dash-table thead {
    background: #0f1828;
}

html[data-bs-theme="dark"] .admin-dash-table thead th {
    color: #93a4bd;
    border-bottom-color: #25324a;
}

html[data-bs-theme="dark"] .admin-dash-patient-card {
    background: #131c2e;
    border-color: #25324a;
}

html[data-bs-theme="dark"] .admin-dash-patient-card:hover {
    border-color: #4338ca;
    box-shadow: 0 4px 16px rgba(79, 110, 247, 0.25);
}

html[data-bs-theme="dark"] .admin-dash-stock-list li {
    border-bottom-color: #25324a;
}

html[data-bs-theme="dark"] .admin-dash-schedule-loading {
    background: rgba(11, 18, 32, 0.75);
}

/* Alert tiles: translucent tinted backgrounds on dark */
html[data-bs-theme="dark"] .admin-dash-alert--warning {
    background: rgba(245, 158, 11, 0.12);
    border-color: rgba(245, 158, 11, 0.3);
}
html[data-bs-theme="dark"] .admin-dash-alert--danger {
    background: rgba(239, 68, 68, 0.12);
    border-color: rgba(239, 68, 68, 0.3);
}
html[data-bs-theme="dark"] .admin-dash-alert--success {
    background: rgba(16, 185, 129, 0.12);
    border-color: rgba(16, 185, 129, 0.3);
}
html[data-bs-theme="dark"] .admin-dash-alert--muted {
    background: rgba(148, 163, 184, 0.1);
    border-color: rgba(148, 163, 184, 0.25);
}

html[data-bs-theme="dark"] .admin-dash-alert strong {
    color: #e2e8f0;
}

html[data-bs-theme="dark"] .admin-dash-alert small {
    color: #93a4bd;
}