/* Fallback styles when Vite build is not available. Run `npm run build` for full Tailwind output. */
html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Option 6 — Noise grain + frosted glass storefront */
.brokie-bg {
    background-color: #0B2545;
    color: rgba(255, 255, 255, 0.9);
    position: relative;
    min-height: 100vh;
}

.brokie-bg::before {
    content: '';
    position: fixed;
    inset: 0;
    z-index: -2;
    pointer-events: none;
    background:
        radial-gradient(ellipse 60% 50% at 20% 30%, rgba(46, 109, 180, 0.35) 0%, transparent 60%),
        radial-gradient(ellipse 50% 40% at 80% 70%, rgba(212, 168, 67, 0.15) 0%, transparent 50%),
        linear-gradient(180deg, #0B2545 0%, #0a1f38 100%);
}

.brokie-bg::after {
    content: '';
    position: fixed;
    inset: 0;
    z-index: -1;
    opacity: 0.04;
    pointer-events: none;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
    background-size: 128px 128px;
}

.brokie-hero-gradient {
    background: linear-gradient(135deg, #0B2545 0%, #1E3A5F 50%, #2E6DB4 100%);
}

.brokie-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 1rem;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.brokie-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.25);
    border-color: rgba(255, 255, 255, 0.25);
}

.brokie-btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.625rem 1.25rem;
    border-radius: 0.5rem;
    font-weight: 500;
    color: #fff;
    background: linear-gradient(135deg, #2E6DB4, #0B2545);
    transition: all 0.2s ease;
    text-decoration: none;
    border: none;
    cursor: pointer;
}

.brokie-btn-primary:hover {
    opacity: 0.95;
    transform: translateY(-1px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.brokie-btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.625rem 1.25rem;
    border-radius: 0.5rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.9);
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.2s ease;
    text-decoration: none;
    cursor: pointer;
}

.brokie-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.14);
    border-color: rgba(212, 168, 67, 0.45);
    color: #fff;
}

.brokie-btn-gold {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.625rem 1.25rem;
    border-radius: 0.5rem;
    font-weight: 500;
    color: #0B2545;
    background: linear-gradient(135deg, #F0D78C, #D4A843);
    transition: all 0.2s ease;
    text-decoration: none;
    border: none;
    cursor: pointer;
}

.brokie-btn-gold:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.text-brokie-navy { color: #0B2545; }
.text-brokie-blue { color: #2E6DB4; }
.text-brokie-gold { color: #D4A843; }
.text-brokie-gold-light { color: #F0D78C; }
.bg-brokie-navy { background-color: #0B2545; }
.border-brokie-blue\/30 { border-color: rgba(46, 109, 180, 0.3); }

/* Scaled live template preview on product cards (1280×720 source) */
.product-card-preview {
    overflow: hidden;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.2);
    outline: 1px solid rgba(255, 255, 255, 0.12);
    outline-offset: -1px;
    min-height: 12rem;
}

.product-card-preview__embed {
    position: absolute;
    inset: 0;
    overflow: hidden;
    z-index: 2;
}

.product-card-preview--pending {
    opacity: 0;
    pointer-events: none;
}

.product-card-preview--loaded {
    opacity: 1;
    background-color: #fff;
    transition: opacity 0.35s ease;
}

.product-card-preview--failed {
    display: none;
}

.product-card-preview__thumb--hidden {
    opacity: 0;
    transition: opacity 0.35s ease;
}

.product-card-preview__iframe {
    pointer-events: none;
    border: 0;
    position: absolute;
    top: 0;
    left: 0;
    width: 1280px;
    height: 720px;
    transform-origin: top left;
    transform: scale(var(--preview-scale, 0.25));
}

/* Product detail hero preview */
.brokie-preview-hero {
    border-bottom: 1px solid #f1f5f9;
    background: #0f172a;
}

.brokie-preview-hero__chrome {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 1rem;
    background: #1e293b;
    border-bottom: 1px solid #334155;
}

.brokie-preview-hero__dot {
    width: 0.75rem;
    height: 0.75rem;
    border-radius: 9999px;
}
.brokie-preview-hero__dot--red { background: #ff5f57; }
.brokie-preview-hero__dot--yellow { background: #febc2e; }
.brokie-preview-hero__dot--green { background: #28c840; }

.brokie-preview-hero__url {
    margin-left: 0.75rem;
    flex: 1;
    font-size: 0.75rem;
    color: #94a3b8;
    font-family: ui-monospace, monospace;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    background: rgba(15, 23, 42, 0.6);
    border-radius: 0.375rem;
    padding: 0.25rem 0.75rem;
}

.brokie-preview-hero__frame {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    min-height: 16rem;
    overflow: hidden;
    background: #fff;
}

.brokie-preview-hero__fallback,
.brokie-preview-hero__thumb {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.brokie-preview-hero__thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top;
    opacity: 0.9;
    transition: opacity 0.35s ease;
}

.brokie-preview-hero__iframe {
    position: absolute;
    top: 0;
    left: 0;
    border: 0;
    z-index: 10;
    width: 100%;
    height: 100%;
    background: #fff;
}

.brokie-preview-hero.is-loaded .brokie-preview-hero__fallback,
.brokie-preview-hero.is-loaded .brokie-preview-hero__thumb {
    opacity: 0;
    pointer-events: none;
}

/* How it works — landing */
.brokie-how-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.25rem;
}
@media (min-width: 768px) {
    .brokie-how-grid { grid-template-columns: repeat(3, 1fr); }
}

.brokie-how-card {
    text-align: left;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 1rem;
    padding: 1.5rem;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
    animation: brokie-how-fade-in 0.6s ease both;
    animation-delay: var(--brokie-how-delay, 0ms);
}
.brokie-how-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.25);
    border-color: rgba(255, 255, 255, 0.25);
}

.brokie-how-card__icon-wrap {
    width: 2.75rem;
    height: 2.75rem;
    border-radius: 0.75rem;
    background: rgba(46, 109, 180, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #F0D78C;
}
.brokie-how-card__icon { width: 1.25rem; height: 1.25rem; }
.brokie-how-card__step {
    margin-top: 1rem;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #D4A843;
}
.brokie-how-card__title {
    margin-top: 0.25rem;
    font-size: 1.125rem;
    font-weight: 600;
    color: #ffffff;
}
.brokie-how-card__text {
    margin-top: 0.5rem;
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.65);
    line-height: 1.625;
}

@keyframes brokie-how-fade-in {
    from { opacity: 0; transform: translateY(12px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Animated hero */
.brokie-hero-animated {
    background: linear-gradient(-45deg, #0B2545, #1E3A5F, #2E6DB4, #4A90D9, #0B2545);
    background-size: 400% 400%;
    animation: brokie-gradient-shift 12s ease infinite;
}
@keyframes brokie-gradient-shift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}
.brokie-float { animation: brokie-float 6s ease-in-out infinite; }
.brokie-float-delayed { animation: brokie-float 7s ease-in-out 1.5s infinite; }
@keyframes brokie-float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-12px); }
}
.brokie-hero-glass {
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.15);
}

/* Checkout / buy modals — dark glass (readable on Option 6 storefront) */
.brokie-modal-panel {
    background: rgba(11, 37, 69, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: rgba(255, 255, 255, 0.9);
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.45);
}

/* Buttons */
.brokie-btn-primary.is-pressed, .brokie-btn-secondary.is-pressed, .brokie-btn-gold.is-pressed {
    transform: translateY(1px) scale(0.98);
}

/* Scroll to top */
#scroll-to-top {
    position: fixed; bottom: 1.5rem; right: 1.5rem; z-index: 50;
    width: 2.75rem; height: 2.75rem; border-radius: 9999px;
    background: linear-gradient(135deg, #0B2545, #2E6DB4);
    color: #fff; box-shadow: 0 10px 15px -3px rgba(0,0,0,0.1);
    display: flex; align-items: center; justify-content: center;
    opacity: 0; pointer-events: none; transition: all 0.3s ease; border: none; cursor: pointer;
}
#scroll-to-top.is-visible { opacity: 1; pointer-events: auto; }
#scroll-to-top:hover { transform: translateY(-2px); }

/* Fade in — visible by default; JS adds .animate-on-scroll for optional reveal */
.fade-in-on-scroll {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.js .fade-in-on-scroll.animate-on-scroll {
    opacity: 0;
    transform: translateY(24px);
}

.js .fade-in-on-scroll.animate-on-scroll.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Dev banner */
.brokie-dev-banner {
    border-bottom: 1px solid rgba(245, 158, 11, 0.35);
    background: linear-gradient(90deg, rgba(251,191,36,0.12), rgba(245,158,11,0.18), rgba(251,191,36,0.12));
    color: #92400e; text-align: center; padding: 0.625rem 1rem; font-size: 0.875rem;
}

/* Category badges */
.brokie-cat-html-templates { background: rgba(2,132,199,0.95); color: #fff; }
.brokie-cat-developer-packs { background: rgba(124,58,237,0.95); color: #fff; }
.brokie-cat-premium-systems { background: rgba(217,119,6,0.95); color: #fff; }
.brokie-cat-default { background: rgba(11,37,69,0.9); color: #fff; }
.brokie-badge-new {
    padding: 0.125rem 0.5rem; font-size: 10px; font-weight: 700;
    text-transform: uppercase; letter-spacing: 0.05em; border-radius: 9999px;
    background: #10b981; color: #fff;
}

/* Stats */
.brokie-stat-card {
    position: relative;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 1rem;
    padding: 1.25rem;
    text-align: center;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}
.brokie-stat-card::before {
    content: ''; position: absolute; top: 0; left: 0; right: 0; height: 4px;
    background: linear-gradient(to right, #2E6DB4, #D4A843); opacity: 0.8;
}

/* Trust, chips, newsletter */
.brokie-trust-badge {
    display: flex; flex-direction: column; align-items: center; gap: 0.5rem;
    padding: 1rem; border-radius: 0.75rem;
    border: 1px solid rgba(255, 255, 255, 0.15);
    background: rgba(255, 255, 255, 0.08);
    transition: all 0.3s ease;
}
.brokie-trust-badge:hover { border-color: rgba(255, 255, 255, 0.28); box-shadow: 0 4px 6px -1px rgba(0,0,0,0.1); transform: translateY(-2px); }
.brokie-chip {
    display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.5rem 1rem;
    border-radius: 9999px; font-size: 0.875rem; font-weight: 500;
    border: 1px solid rgba(255, 255, 255, 0.18);
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none; transition: all 0.2s ease;
}
.brokie-chip:hover { border-color: rgba(212, 168, 67, 0.5); color: #F0D78C; box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2); }
.brokie-newsletter {
    border-radius: 1.5rem; overflow: hidden;
    background: linear-gradient(135deg, #0B2545 0%, #1E3A5F 60%, #2E6DB4 100%);
}

/* Catalog views */
#catalog-grid[data-view="list"] { grid-template-columns: 1fr !important; gap: 1rem !important; }
#catalog-grid[data-view="list"] .brokie-product-card { display: flex; flex-direction: row; }
#catalog-grid[data-view="list"] .brokie-product-card > a:first-child { width: 12rem; flex-shrink: 0; }
.catalog-view-btn {
    padding: 0.5rem; border-radius: 0.5rem;
    border: 1px solid rgba(255, 255, 255, 0.18);
    color: rgba(255, 255, 255, 0.55);
    background: rgba(255, 255, 255, 0.06);
    cursor: pointer; transition: all 0.2s;
}
.catalog-view-btn:hover { color: #fff; border-color: rgba(255, 255, 255, 0.3); }
.catalog-view-btn.is-active {
    background: linear-gradient(135deg, #F0D78C, #D4A843);
    color: #0B2545;
    border-color: transparent;
    font-weight: 600;
}

/* FAQ accordion */
[data-accordion-panel] { max-height: 0; overflow: hidden; opacity: 0; transition: max-height 0.35s ease, opacity 0.3s ease; }
[data-accordion-panel].is-open { max-height: 400px; opacity: 1; }
[data-accordion-item] .accordion-chevron { transition: transform 0.25s ease; }
[data-accordion-item].is-open .accordion-chevron { transform: rotate(180deg); }

/* Nav search */
.brokie-nav-search {
    display: flex; align-items: center; gap: 0.5rem; padding: 0.375rem 0.75rem;
    border-radius: 0.5rem;
    border: 1px solid rgba(255, 255, 255, 0.15);
    background: rgba(255, 255, 255, 0.06);
}
.brokie-nav-search input {
    background: transparent; border: 0; outline: none; font-size: 0.875rem;
    width: 8rem; color: rgba(255, 255, 255, 0.9);
}
.brokie-nav-search input::placeholder { color: rgba(255, 255, 255, 0.45); }
@media (min-width: 640px) { .brokie-nav-search input { width: 11rem; } }

/* Misc */
.brokie-sticky-sidebar { position: sticky; top: 6rem; }
.brokie-payment-badge {
    display: inline-flex; align-items: center; gap: 0.375rem; padding: 0.375rem 0.75rem;
    border-radius: 0.5rem;
    border: 1px solid rgba(255, 255, 255, 0.15);
    background: rgba(255, 255, 255, 0.06);
    font-size: 0.75rem; font-weight: 500; color: rgba(255, 255, 255, 0.7);
}
.brokie-empty-state {
    text-align: center; padding: 3rem;
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 1rem;
}
.brokie-social-link {
    width: 2.25rem; height: 2.25rem; border-radius: 0.5rem;
    border: 1px solid rgba(255, 255, 255, 0.15);
    display: flex; align-items: center; justify-content: center;
    color: rgba(255, 255, 255, 0.55);
    text-decoration: none; transition: all 0.2s;
}
.brokie-social-link:hover { color: #F0D78C; border-color: rgba(212, 168, 67, 0.4); }
.brokie-product-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 1rem;
    transition: all 0.3s ease;
}
.brokie-product-card:hover { transform: translateY(-6px); box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3); border-color: rgba(255, 255, 255, 0.25); }

/* Product card thumbnail — always-loaded (Vite may omit Tailwind aspect utilities) */
.brokie-product-card__media {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    min-height: 12rem;
    overflow: hidden;
    background: rgba(0, 0, 0, 0.25);
}
.brokie-product-card__fallback {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    z-index: 0;
}
.brokie-product-card__fallback-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}
.brokie-product-card__initial {
    font-size: 2.25rem;
    font-weight: 700;
    line-height: 1;
}
.brokie-product-card__category-icon {
    width: 1.75rem;
    height: 1.75rem;
    opacity: 0.85;
}
.brokie-product-card__img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    z-index: 1;
    display: block;
}
#catalog-grid[data-view="list"] .brokie-product-card > a:first-child .brokie-product-card__media {
    aspect-ratio: auto;
    height: 100%;
    min-height: 140px;
}

/* Typography */
.brokie-display {
    font-size: 2.25rem;
    font-weight: 700;
    letter-spacing: -0.025em;
    line-height: 1.08;
}
@media (min-width: 640px) { .brokie-display { font-size: 3rem; } }
@media (min-width: 1024px) { .brokie-display { font-size: 3.75rem; } }

.brokie-heading {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.025em;
}
@media (min-width: 640px) { .brokie-heading { font-size: 1.875rem; } }

.brokie-subheading {
    font-size: 1.125rem;
    color: rgba(255, 255, 255, 0.65);
    line-height: 1.625;
}

/* How it works steps */
.brokie-step-card {
    text-align: center;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 1rem;
    padding: 1.5rem;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}
.brokie-step-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    border-color: rgba(46, 109, 180, 0.3);
}

.brokie-section-divider {
    height: 1px; width: 100%; margin: 3rem 0;
    background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.15), transparent);
}

/* Glass nav + footer */
.brokie-nav {
    background: rgba(255, 255, 255, 0.06);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.brokie-footer {
    background: rgba(255, 255, 255, 0.04);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Buttons + forms */
.brokie-btn-outline {
    text-align: center;
    padding: 0.5rem 0.75rem;
    border-radius: 0.5rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s ease;
}
.brokie-btn-outline:hover {
    border-color: rgba(74, 144, 217, 0.6);
    color: #4A90D9;
}
.brokie-form-label {
    font-size: 0.875rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.8);
}
.brokie-form-input {
    margin-top: 0.25rem;
    width: 100%;
    padding: 0.5rem 0.75rem;
    border-radius: 0.5rem;
    border: 1px solid rgba(255, 255, 255, 0.15);
    background: rgba(255, 255, 255, 0.06);
    color: rgba(255, 255, 255, 0.95);
    outline: none;
    transition: all 0.2s ease;
}
.brokie-form-input::placeholder { color: rgba(255, 255, 255, 0.4); }
.brokie-form-input:focus {
    border-color: rgba(212, 168, 67, 0.5);
    box-shadow: 0 0 0 2px rgba(212, 168, 67, 0.15);
}

/* Dark storefront text overrides */
.brokie-bg .text-brokie-navy { color: #ffffff; }
.brokie-bg .text-brokie-blue { color: #4A90D9; }
.brokie-bg .text-slate-800 { color: rgba(255, 255, 255, 0.92); }
.brokie-bg .text-slate-700 { color: rgba(255, 255, 255, 0.88); }
.brokie-bg .text-slate-600 { color: rgba(255, 255, 255, 0.8); }
.brokie-bg .text-slate-500 { color: rgba(255, 255, 255, 0.7); }
.brokie-bg .text-slate-400 { color: rgba(255, 255, 255, 0.65); }
.brokie-bg .text-slate-300 { color: rgba(255, 255, 255, 0.55); }
.brokie-bg .border-slate-200,
.brokie-bg .border-slate-200\/60,
.brokie-bg .border-slate-200\/80 { border-color: rgba(255, 255, 255, 0.15); }
.brokie-bg .border-slate-100 { border-color: rgba(255, 255, 255, 0.1); }
.brokie-bg .bg-slate-50 { background-color: rgba(255, 255, 255, 0.05); }
.brokie-bg .bg-slate-100 { background-color: rgba(255, 255, 255, 0.08); }
.brokie-bg .hover\:text-brokie-blue:hover { color: #F0D78C; }

/* Admin panel — always loaded (Vite build may omit @apply custom classes) */
.bg-brokie-cream { background-color: #F8F9FC; }

.admin-stat-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}
@media (min-width: 1024px) {
    .admin-stat-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 1280px) {
    .admin-stat-grid { grid-template-columns: repeat(6, 1fr); }
}

.admin-stat-card {
    position: relative;
    overflow: hidden;
    background: #fff;
    border: 1px solid rgba(148, 163, 184, 0.5);
    border-radius: 1rem;
    padding: 1rem 1rem 1rem 1.125rem;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.admin-stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #2E6DB4, #D4A843);
    opacity: 0.85;
}
.admin-stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(11, 37, 69, 0.08);
}

.admin-stat-icon {
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 0.625rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    background: rgba(46, 109, 180, 0.1);
    margin-bottom: 0.625rem;
}

.admin-stat-label {
    font-size: 0.6875rem;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
}

.admin-stat-value {
    margin-top: 0.25rem;
    font-size: 1.5rem;
    font-weight: 800;
    color: #0B2545;
    line-height: 1.2;
}

.admin-stat-meta {
    margin-top: 0.375rem;
    font-size: 0.6875rem;
    color: #94a3b8;
    line-height: 1.4;
}

.admin-table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.admin-table {
    width: 100%;
    font-size: 0.875rem;
    border-collapse: collapse;
}

.admin-table thead tr {
    text-align: left;
    font-size: 0.75rem;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom: 1px solid #f1f5f9;
}

.admin-table th,
.admin-table td {
    padding: 0.625rem 1rem 0.625rem 0;
}

.admin-table tbody tr {
    border-bottom: 1px solid #f8fafc;
}

.admin-badge {
    display: inline-flex;
    padding: 0.125rem 0.5rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 500;
}

.admin-badge--success {
    background: #ecfdf5;
    color: #047857;
}

.admin-badge--muted {
    background: #f1f5f9;
    color: #64748b;
}

.admin-badge--danger {
    background: #fef2f2;
    color: #dc2626;
}

.admin-badge--direct {
    background: #ecfdf5;
    color: #047857;
}

.admin-badge--external {
    background: #eef2ff;
    color: #4338ca;
}

.admin-bar-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.875rem;
}

.admin-bar-label {
    width: 7rem;
    flex-shrink: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #475569;
}

.admin-bar-track {
    flex: 1;
    height: 0.625rem;
    border-radius: 9999px;
    background: #f1f5f9;
    overflow: hidden;
}

.admin-bar-fill {
    height: 100%;
    border-radius: 9999px;
    background: linear-gradient(90deg, #2E6DB4, #D4A843);
    min-width: 2px;
    transition: width 0.4s ease;
}

.admin-bar-value {
    width: 2.5rem;
    text-align: right;
    font-weight: 600;
    color: #0B2545;
    flex-shrink: 0;
}
