/* ===== CSS Variables ===== */
:root {
    --primary-color: #9a5a22;
    --primary-dark: #573116;
    --primary-light: #c47a35;
    --secondary-color: #243528;
    --accent-color: #d4a24c;
    --success-color: #10b981;
    --danger-color: #ef4444;
    --warning-color: #f59e0b;
    --dark-color: #1f2937;
    --light-color: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --border-radius: 0.5rem;
    --transition: all 0.3s ease;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

/* ===== Base Styles ===== */
html, body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', sans-serif;
    background-color: #f7f4ee;
    color: var(--gray-800);
    line-height: 1.6;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* ===== Typography ===== */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    color: var(--dark-color);
}

h1:focus {
    outline: none;
}

/* ===== Links ===== */
a {
    color: var(--primary-color);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--primary-dark);
}

/* ===== Buttons ===== */
.btn {
    border-radius: var(--border-radius);
    font-weight: 600;
    padding: 0.625rem 1.25rem;
    transition: var(--transition);
    border: none;
    cursor: pointer;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    border: none;
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-color) 100%);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-outline-primary {
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
    background: transparent;
}

.btn-outline-primary:hover {
    color: white;
    background: var(--primary-color);
}

.btn-secondary {
    background-color: var(--secondary-color);
    color: white;
}

.btn-secondary:hover {
    background-color: #7c3aed;
    transform: translateY(-2px);
}

.btn-success {
    background-color: var(--success-color);
    color: white;
}

.btn-danger {
    background-color: var(--danger-color);
    color: white;
}

.btn:focus, .btn:active:focus, .form-control:focus, .form-check-input:focus {
    box-shadow: 0 0 0 0.2rem rgba(37, 99, 235, 0.25);
    outline: none;
}

/* ===== Cards ===== */
.card {
    border: none;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    background: white;
}

.card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-4px);
}

.product-card {
    overflow: hidden;
}

.product-card img {
    transition: var(--transition);
}

.product-card:hover img {
    transform: scale(1.05);
}

/* ===== Forms ===== */
.form-control, .form-select {
    border-radius: var(--border-radius);
    border: 1px solid var(--gray-300);
    padding: 0.625rem 1rem;
    transition: var(--transition);
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(37, 99, 235, 0.1);
}

.valid.modified:not([type=checkbox]) {
    outline: 2px solid var(--success-color);
}

.invalid {
    outline: 2px solid var(--danger-color);
}

.validation-message {
    color: var(--danger-color);
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

/* ===== Layout ===== */
.content {
    padding-top: 1.5rem;
}

.container {
    max-width: 1280px;
}

/* ===== Navigation ===== */
.navbar-brand {
    display: inline-flex;
    align-items: center;
    gap: .7rem;
    font-weight: 700;
    font-size: 1.5rem;
}

.navbar-brand .brand-name {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.navbar-brand .brand-name small {
    display: block;
    font-size: .55rem;
    letter-spacing: .24em;
    line-height: 1;
}

.brand-logo {
    width: 48px;
    height: 61px;
    object-fit: contain;
    border-radius: .45rem;
    background: white;
    filter: drop-shadow(0 2px 4px rgba(22, 16, 10, .12));
}

.navbar {
    border-bottom: 3px solid rgba(154, 90, 34, 0.12);
}

/* ===== Badges ===== */
.badge {
    border-radius: 999px;
    padding: 0.25rem 0.5rem;
    font-size: 0.75rem;
    font-weight: 700;
}

/* ===== Hero Section ===== */
.hero-section {
    background:
        radial-gradient(circle at 78% 20%, rgba(213, 151, 69, .22), transparent 34%),
        linear-gradient(135deg, #0a110c 0%, #17251a 55%, #273c2a 100%);
    color: white;
    padding: 0;
    border-radius: 1rem;
    margin-bottom: 3rem;
    box-shadow: var(--shadow-xl);
    overflow: hidden;
    min-height: 560px;
}

.hero-overlay {
    display: flex;
    align-items: center;
    min-height: 560px;
    padding: 5rem 0;
    background: linear-gradient(90deg, rgba(10, 17, 12, .48), rgba(10, 17, 12, .08));
}

.hero-copy h1 {
    color: white;
    text-shadow: 0 2px 20px rgba(0, 0, 0, .35);
}

.hero-kicker {
    display: inline-block;
    margin-bottom: 1rem;
    color: #f3c46d;
    font-size: .82rem;
    font-weight: 800;
    letter-spacing: .16em;
    text-transform: uppercase;
}

.prime-dealer-badge {
    display: inline-flex;
    align-items: center;
    gap: .75rem;
    padding: .7rem 1rem;
    text-align: left;
    border: 1px solid rgba(243, 196, 109, .48);
    border-radius: .85rem;
    background: rgba(255, 255, 255, .1);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .08);
    backdrop-filter: blur(6px);
}

.prime-dealer-badge strong,
.prime-dealer-badge small {
    display: block;
}

.prime-dealer-badge strong {
    color: white;
    font-size: .9rem;
}

.prime-dealer-badge small {
    margin-top: .12rem;
    color: rgba(255, 255, 255, .7);
    font-size: .72rem;
}

.prime-check {
    display: grid;
    place-items: center;
    flex: 0 0 2rem;
    width: 2rem;
    height: 2rem;
    color: #17251a;
    border-radius: 50%;
    background: #f3c46d;
    font-weight: 900;
}

.hero-logo-panel {
    width: min(100%, 360px);
    margin-inline: auto;
    padding: 1rem;
    border: 1px solid rgba(255, 255, 255, .3);
    border-radius: 1.25rem;
    background: rgba(255, 255, 255, .97);
    box-shadow: 0 24px 55px rgba(0, 0, 0, .38);
}

.hero-logo-panel img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: .6rem;
}

.upload-panel {
    padding: 1rem;
    border: 2px dashed var(--gray-300);
    border-radius: .75rem;
    background: #faf8f3;
}

.product-image-preview img {
    width: min(100%, 320px);
    max-height: 260px;
    object-fit: contain;
    border-radius: .75rem;
    border: 1px solid var(--gray-200);
    background: white;
}

.inventory-button {
    width: 2rem;
    height: 2rem;
    padding: 0;
    line-height: 1;
}

.featured-toggle {
    display: grid;
    place-items: center;
    width: 2.35rem;
    height: 2.35rem;
    padding: 0;
    color: #9ca3af;
    border: 1px solid var(--gray-300);
    border-radius: 50%;
    background: white;
    font-size: 1.35rem;
    line-height: 1;
    transition: var(--transition);
}

.featured-toggle:hover:not(:disabled) {
    color: #b16f09;
    border-color: #e7bd66;
    background: #fff9e8;
    transform: translateY(-1px) scale(1.05);
}

.featured-toggle.is-featured {
    color: #9a5a00;
    border-color: #e7bd66;
    background: linear-gradient(135deg, #fff7cf, #f6d77d);
    box-shadow: 0 4px 12px rgba(177, 111, 9, .18);
}

.featured-toggle:disabled {
    cursor: not-allowed;
    opacity: .45;
}

.square-secure-label {
    margin-bottom: .75rem;
    color: var(--gray-600);
    font-size: .85rem;
    font-weight: 700;
}

#square-card-container {
    min-height: 90px;
    padding: .75rem;
    border: 1px solid var(--gray-200);
    border-radius: .75rem;
    background: white;
}

footer .text-muted {
    color: #c9d0ca !important;
}

footer h5,
footer h6 {
    color: #fff !important;
}

/* ===== Admin Order Command Center ===== */
.admin-dashboard-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    padding: 2rem;
    color: white;
    border-radius: 1.25rem;
    background:
        radial-gradient(circle at 90% 15%, rgba(212, 162, 76, .34), transparent 30%),
        linear-gradient(135deg, #18251b 0%, #2d432f 58%, #6b3d1b 100%);
    box-shadow: 0 20px 45px rgba(31, 41, 55, .2);
}

.admin-dashboard-hero h1 {
    margin: .2rem 0 .45rem;
    color: white;
    font-size: clamp(1.8rem, 4vw, 2.7rem);
}

.admin-dashboard-hero p {
    color: rgba(255, 255, 255, .76);
}

.admin-eyebrow,
.section-kicker {
    color: #d7a74f;
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .16em;
    text-transform: uppercase;
}

.dashboard-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .85rem;
    min-height: 320px;
    color: var(--gray-600);
    font-weight: 700;
}

.dashboard-metric {
    display: flex;
    align-items: center;
    gap: 1rem;
    height: 100%;
    padding: 1.25rem;
    border: 1px solid rgba(31, 41, 55, .07);
    border-radius: 1rem;
    background: white;
    box-shadow: 0 8px 24px rgba(31, 41, 55, .07);
}

.metric-icon {
    display: grid;
    place-items: center;
    flex: 0 0 3.2rem;
    width: 3.2rem;
    height: 3.2rem;
    border-radius: .9rem;
    font-size: 1.45rem;
}

.metric-pending .metric-icon {
    background: #fff3cd;
}

.metric-processing .metric-icon {
    background: #dbeafe;
}

.metric-shipped .metric-icon {
    background: #ede9fe;
}

.metric-revenue .metric-icon {
    background: #dcfce7;
}

.metric-value {
    color: var(--gray-800);
    font-size: 1.75rem;
    font-weight: 800;
    line-height: 1;
}

.metric-label {
    margin-top: .35rem;
    color: var(--gray-600);
    font-size: .82rem;
    font-weight: 700;
}

.dashboard-section {
    padding: 1.5rem;
    border: 1px solid rgba(31, 41, 55, .08);
    border-radius: 1.15rem;
    background: rgba(255, 255, 255, .95);
    box-shadow: 0 10px 30px rgba(31, 41, 55, .07);
}

.pending-section {
    border-color: rgba(245, 158, 11, .28);
    background: linear-gradient(180deg, #fffdf6 0%, #fff 100%);
}

.dashboard-section-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.25rem;
}

.dashboard-section-heading h2 {
    margin: .25rem 0;
    font-size: 1.45rem;
}

.dashboard-section-heading p {
    margin: 0;
    color: var(--gray-600);
    font-size: .92rem;
}

.count-pill {
    flex: 0 0 auto;
    padding: .35rem .75rem;
    color: #1e3a2a;
    border-radius: 999px;
    background: #e5eee7;
    font-size: .75rem;
    font-weight: 800;
}

.pending-count {
    color: #8a4b08;
    background: #fff0c7;
}

.pending-order-card {
    height: 100%;
    padding: 1.15rem;
    border: 1px solid #f0ddb3;
    border-radius: 1rem;
    background: white;
    box-shadow: 0 8px 22px rgba(120, 77, 15, .08);
}

.pending-order-card h3 {
    margin: 0 0 .15rem;
    font-size: 1rem;
}

.order-number-tile {
    display: grid;
    place-items: center;
    min-width: 3.4rem;
    height: 3.4rem;
    padding: 0 .45rem;
    color: white;
    border-radius: .85rem;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    font-size: .88rem;
    font-weight: 800;
}

.status-badge,
.payment-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: .3rem .65rem;
    border-radius: 999px;
    font-size: .72rem;
    font-weight: 800;
}

.status-pending {
    color: #8a4b08 !important;
    border-color: #f6d887 !important;
    background-color: #fff3cd !important;
}

.status-processing {
    color: #174ea6 !important;
    border-color: #a9caf9 !important;
    background-color: #dbeafe !important;
}

.status-shipped {
    color: #54319d !important;
    border-color: #c9b7f5 !important;
    background-color: #ede9fe !important;
}

.status-delivered {
    color: #116337 !important;
    border-color: #a8dfbd !important;
    background-color: #dcfce7 !important;
}

.status-cancelled,
.status-refunded {
    color: #4b5563 !important;
    border-color: #d1d5db !important;
    background-color: #f3f4f6 !important;
}

.payment-completed {
    color: #11713f !important;
}

.payment-pending {
    color: #a05a08 !important;
}

.payment-failed {
    color: #b42318 !important;
}

.payment-unknown {
    color: var(--gray-600) !important;
}

.pending-order-facts {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: .6rem;
    margin-top: 1rem;
    padding: .85rem;
    border-radius: .8rem;
    background: #faf7f0;
}

.pending-order-facts div {
    min-width: 0;
}

.pending-order-facts span,
.pending-order-facts strong {
    display: block;
}

.pending-order-facts span {
    color: var(--gray-600);
    font-size: .68rem;
    font-weight: 700;
    text-transform: uppercase;
}

.pending-order-facts strong {
    margin-top: .18rem;
    overflow: hidden;
    font-size: .86rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dashboard-order-table {
    border: 1px solid var(--gray-200);
    border-radius: .9rem;
}

.dashboard-order-table thead th {
    padding: .85rem;
    color: var(--gray-600);
    border-bottom-width: 1px;
    background: #f7f5f0;
    font-size: .72rem;
    letter-spacing: .04em;
    text-transform: uppercase;
    white-space: nowrap;
}

.dashboard-order-table tbody td {
    padding: .9rem .85rem;
}

.dashboard-order-table tbody tr:last-child td {
    border-bottom: 0;
}

.status-select {
    padding: .4rem 2rem .4rem .65rem;
    border-width: 1px;
    border-style: solid;
    border-radius: 999px;
    font-size: .76rem;
    font-weight: 800;
}

.dashboard-empty {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.35rem;
    color: #27603d;
    border: 1px dashed #a8d5b7;
    border-radius: .9rem;
    background: #f2fbf5;
}

.dashboard-empty p {
    color: #5d7565;
    font-size: .87rem;
}

.dashboard-empty.compact {
    padding: .9rem 1rem;
}

.empty-check {
    display: grid;
    place-items: center;
    flex: 0 0 2.5rem;
    width: 2.5rem;
    height: 2.5rem;
    color: white;
    border-radius: 50%;
    background: #2f855a;
    font-weight: 900;
}

.low-stock-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .75rem;
    height: 100%;
    padding: .9rem;
    border: 1px solid var(--gray-200);
    border-radius: .8rem;
    background: #fafafa;
}

.low-stock-item strong,
.low-stock-item small {
    display: block;
}

.low-stock-item strong {
    font-size: .84rem;
}

.low-stock-item small {
    margin-top: .15rem;
    color: var(--gray-600);
    font-size: .72rem;
}

.stock-count {
    display: grid;
    place-items: center;
    flex: 0 0 2.2rem;
    width: 2.2rem;
    height: 2.2rem;
    color: #8a4b08;
    border-radius: 50%;
    background: #fff0c7;
    font-weight: 900;
}

.stock-count.out {
    color: white;
    background: var(--danger-color);
}

@media (max-width: 767.98px) {
    .admin-dashboard-hero,
    .dashboard-section-heading {
        align-items: stretch;
        flex-direction: column;
    }

    .admin-dashboard-hero {
        padding: 1.4rem;
    }

    .admin-dashboard-hero .btn {
        flex: 1 1 auto;
    }

    .dashboard-section {
        padding: 1rem;
    }

    .pending-order-facts {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .pending-order-card .btn {
        flex: 1 1 auto;
    }
}

img {
    image-orientation: from-image;
}

.product-gallery-thumbs,
.admin-image-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(88px, 1fr));
    gap: .75rem;
}

.gallery-thumb,
.admin-image-tile {
    padding: .35rem;
    border: 2px solid #e1e5e8;
    border-radius: .75rem;
    background: #fff;
}

.gallery-thumb.active,
.admin-image-tile.primary {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(126, 69, 30, .12);
}

.gallery-thumb img,
.admin-image-tile img {
    width: 100%;
    height: 82px;
    object-fit: contain;
}

.variant-editor-row {
    display: grid;
    grid-template-columns: 2fr 1.4fr 1.1fr .8fr auto auto;
    gap: .5rem;
}

.product-option-flags {
    padding: 1rem 1.75rem;
    border-radius: .75rem;
    background: #f7f4ef;
}

.prime-product-callout {
    display: inline-flex;
    padding: .45rem .8rem;
    border: 1px solid #c89455;
    border-radius: 999px;
    background: #fff5e6;
    color: #754516;
    font-weight: 750;
}

.product-spec-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(135px, 1fr));
    gap: .65rem;
}

.product-spec-grid > div {
    padding: .8rem;
    border-radius: .7rem;
    background: #f3f5f6;
}

.product-spec-grid span,
.product-spec-grid strong {
    display: block;
}

.product-spec-grid span { color: #71808c; font-size: .72rem; text-transform: uppercase; }
.prime-page-hero { padding: 6rem 0; color: #fff; background: linear-gradient(115deg, #151b20, #56351f); }
.prime-page-copy { max-width: 760px; }
.prime-page-copy > span { color: #e6b879; text-transform: uppercase; letter-spacing: .15em; font-weight: 800; }
.prime-page-copy h1 { margin: .5rem 0 1rem; color: #fff; font-size: clamp(2.5rem, 6vw, 4.75rem); }
.prime-card-image { display: grid; place-items: center; height: 260px; overflow: hidden; background: #f2f3f3; font-size: 5rem; }
.prime-card-image img { width: 100%; height: 100%; object-fit: contain; }
.prime-contact-card { padding: 3rem; border-radius: 1rem; background: #f7f1e9; text-align: center; }

.order-timeline { position: relative; }
.order-timeline-item { display: grid; grid-template-columns: 18px 1fr; gap: .75rem; padding-bottom: 1.2rem; }
.order-timeline-item > span { width: 12px; height: 12px; margin-top: .3rem; border-radius: 50%; background: var(--primary-color); box-shadow: 0 0 0 4px rgba(126,69,30,.13); }
.order-timeline-item strong, .order-timeline-item small { display: block; }
.order-timeline-item small { color: #7b8790; }
.order-timeline-item p { margin: .25rem 0 0; }
.audit-detail { max-width: 520px; padding: .75rem; white-space: pre-wrap; overflow-wrap: anywhere; background: #f3f4f5; }

.packing-slip { max-width: 900px; margin: 2rem auto; padding: 2.5rem; background: #fff; color: #111; }
.packing-slip header, .packing-meta { display: flex; justify-content: space-between; gap: 2rem; }
.packing-slip header { padding-bottom: 1.5rem; border-bottom: 3px solid #111; }
.packing-slip header span { display: block; text-align: right; }
.packing-meta { padding: 1.5rem 0; }
.packing-meta > div { width: 50%; }
.packing-slip table { width: 100%; border-collapse: collapse; margin: 1rem 0 3rem; }
.packing-slip th, .packing-slip td { padding: .75rem; border-bottom: 1px solid #bbb; text-align: left; }
.packing-slip footer { text-align: center; }

@media (max-width: 767.98px) {
    .variant-editor-row { grid-template-columns: 1fr; }
}

@media print {
    body { background: #fff !important; }
    .no-print, nav, footer { display: none !important; }
    .packing-slip { max-width: none; margin: 0; padding: 0; box-shadow: none; }
}

@media (max-width: 767.98px) {
    .hero-section {
        border-radius: .75rem;
        min-height: 480px;
    }

    .hero-overlay {
        min-height: 480px;
        padding: 3rem 1rem;
        background: rgba(10, 17, 12, .28);
    }

    .hero-section .display-3 {
        font-size: 2.4rem;
    }

    .hero-logo-panel {
        width: min(100%, 280px);
        padding: .75rem;
    }

    .brand-logo {
        width: 42px;
        height: 53px;
    }

    .table-responsive {
        border-radius: .75rem;
    }
}

/* ===== Loading Spinner ===== */
.spinner-border {
    color: var(--primary-color);
}

/* ===== Alerts ===== */
.alert {
    border-radius: var(--border-radius);
    border: none;
}

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

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

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

/* ===== Tables ===== */
table {
    background: white;
    border-radius: var(--border-radius);
    overflow: hidden;
}

thead {
    background-color: var(--gray-100);
}

/* ===== Animations ===== */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.5s ease-out;
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.slide-in-right {
    animation: slideInRight 0.5s ease-out;
}

/* ===== Utilities ===== */
.text-gradient {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hover-lift {
    transition: var(--transition);
}

.hover-lift:hover {
    transform: translateY(-4px);
}

/* ===== Error Boundary ===== */
.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5OUwyNDAuMzgzIDk5QzIzNy45NjMgOTkgMjM2IDk3LjA2NTEgMjM2IDk0LjY3ODIgMjM2IDk0LjM3OTkgMjM2LjAzMSA5NC4wODg2IDIzNi4wODkgOTMuODA3MkwyMzYuMzM4IDkzLjAxNjIgMjM2Ljg1OCA5Mi4xMzE0IDI1OS40NzMgNTMuNjI5NCAyNTkuOTYxIDUyLjc5ODUgMjYwLjQwNyA1Mi4yNjU4QzI2MS4yIDUxLjQ4MzcgMjYyLjI5NiA1MSAyNjMuNTA2IDUxWk0yNjMuNTg2IDY2LjAxODNDMjYwLjczNyA2Ni4wMTgzIDI1OS4zMTMgNjcuMTI0NSAyNTkuMzEzIDY5LjMzNyAyNTkuMzEzIDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
    border-radius: var(--border-radius);
}

.blazor-error-boundary::after {
    content: "An error has occurred."
}

/* ===== Form Specific ===== */
.darker-border-checkbox.form-check-input {
    border-color: #929292;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}

/* ===== Technical System Health Dashboard ===== */
.system-dashboard {
    --system-navy: #14202b;
    --system-slate: #263746;
    --system-green: #138a59;
    --system-amber: #c57b09;
    --system-red: #c34242;
}

.system-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    padding: 2rem;
    color: #fff;
    border-radius: 1.25rem;
    background:
        radial-gradient(circle at 88% 18%, rgba(255,255,255,.12), transparent 26%),
        linear-gradient(135deg, var(--system-navy), #27435a);
    box-shadow: 0 18px 40px rgba(20, 32, 43, .2);
}

.system-hero h1 {
    margin: .2rem 0 .35rem;
    color: #fff;
    font-size: clamp(2rem, 4vw, 3rem);
}

.system-eyebrow,
.system-kicker {
    color: #cf9b62;
    font-size: .73rem;
    font-weight: 800;
    letter-spacing: .14em;
    text-transform: uppercase;
}

.system-hero-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.system-updated {
    color: rgba(255,255,255,.72);
    font-size: .82rem;
    white-space: nowrap;
}

.system-summary,
.system-stat,
.system-panel {
    border: 1px solid #e3e8ed;
    background: #fff;
    box-shadow: 0 10px 28px rgba(20, 32, 43, .07);
}

.system-summary {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.1rem 1.35rem;
    border-radius: 1rem;
}

.system-summary-mark {
    display: grid;
    place-items: center;
    width: 2.75rem;
    height: 2.75rem;
    flex: 0 0 auto;
    border-radius: .8rem;
    color: #fff;
    font-size: 1.35rem;
    font-weight: 900;
}

.system-summary-mark.healthy { background: var(--system-green); }
.system-summary-mark.danger { background: var(--system-red); }
.system-summary-mark.checking { background: #6c7a86; }
.system-summary-title { font-size: 1.1rem; font-weight: 800; color: var(--system-navy); }

.system-stat {
    height: 100%;
    padding: 1.25rem;
    border-radius: 1rem;
}

.system-stat span,
.system-stat small {
    display: block;
    color: #72808d;
}

.system-stat span {
    margin-bottom: .45rem;
    font-size: .75rem;
    font-weight: 800;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.system-stat strong {
    display: block;
    margin-bottom: .2rem;
    color: var(--system-navy);
    font-size: 1.35rem;
}

.system-stat small {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.system-panel {
    overflow: hidden;
    border-radius: 1.15rem;
}

.system-panel-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.25rem 1.4rem;
    border-bottom: 1px solid #e8ecef;
}

.system-panel-heading h2 {
    margin: .15rem 0 0;
    color: var(--system-navy);
    font-size: 1.25rem;
}

.system-count {
    padding: .3rem .65rem;
    border-radius: 999px;
    background: #eef2f5;
    color: #5e6b76;
    font-size: .75rem;
    font-weight: 700;
}

.system-loading {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: .75rem;
    padding: 4rem 1rem;
    color: #6b7883;
}

.system-check {
    display: flex;
    gap: 1rem;
    padding: 1.2rem 1.4rem;
    border-bottom: 1px solid #edf0f2;
}

.system-check:last-child { border-bottom: 0; }

.system-check-icon {
    display: grid;
    place-items: center;
    width: 2.5rem;
    height: 2.5rem;
    flex: 0 0 auto;
    border-radius: .75rem;
    color: #fff;
    font-size: 1.15rem;
    font-weight: 900;
}

.system-check-icon.healthy { background: var(--system-green); }
.system-check-icon.warning { background: var(--system-amber); }
.system-check-icon.danger { background: var(--system-red); }

.system-check-copy { min-width: 0; flex: 1; }
.system-check-title { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.system-check-copy p { margin: .25rem 0 .15rem; color: #50606d; }
.system-check-copy small { color: #84909a; overflow-wrap: anywhere; }

.system-status {
    padding: .25rem .55rem;
    border-radius: 999px;
    font-size: .7rem;
    font-weight: 800;
}

.system-status.healthy { color: #087044; background: #dff5e9; }
.system-status.warning { color: #8c5600; background: #fff0cf; }
.system-status.danger { color: #a42828; background: #fde4e4; }

.system-detail-list {
    margin: 0;
    padding: .35rem 1.4rem 1rem;
}

.system-detail-list > div {
    padding: .8rem 0;
    border-bottom: 1px solid #edf0f2;
}

.system-detail-list > div:last-child { border-bottom: 0; }
.system-detail-list dt { color: #76838e; font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; }
.system-detail-list dd { margin: .2rem 0 0; color: var(--system-navy); font-weight: 650; overflow-wrap: anywhere; }
.system-panel .d-grid { padding: 1.25rem 1.4rem; }

@media (max-width: 767.98px) {
    .system-hero,
    .system-hero-actions {
        align-items: flex-start;
        flex-direction: column;
    }

    .system-check-title {
        align-items: flex-start;
        flex-direction: column;
        gap: .4rem;
    }
}
