:root {
    --navy: #5B2E91;
    --teal: #003DA5;
    --bg: #E6E6FA;
    --surface: #E1EFFF;
    --border: #BDBDBD;
    --text: #2e1854;
    --text-muted: #6e6488;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: 'Barlow', 'Helvetica', 'Arial', sans-serif;
    background: var(--bg);
    color: var(--text);
}

h1:focus { outline: none; }

/* ── Nav ───────────────────────────────────── */
.app-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    height: 56px;
    background: var(--navy);
    color: #fff;
}
.app-nav .brand {
    font-family: 'Barlow Condensed', sans-serif;
    font-weight: 700;
    font-size: 1.4rem;
    color: #E6E6FA;
    text-decoration: none;
}
.app-nav .nav-links { display: flex; gap: 20px; align-items: center; }
.app-nav .nav-links a {
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.15s;
}
.app-nav .nav-links a:hover { color: #fff; }
.app-nav .logout-link { color: rgba(255,255,255,0.5) !important; }

/* ── Page Container ────────────────────────── */
.page-container {
    max-width: 960px;
    margin: 0 auto;
    padding: 32px 24px;
}

/* ── Auth Card ─────────────────────────────── */
.auth-card {
    max-width: 440px;
    margin: 48px auto;
    background: var(--surface);
    border-radius: 12px;
    padding: 40px 36px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
}
.auth-card h1 {
    font-family: 'Barlow Condensed', sans-serif;
    font-size: 1.8rem;
    margin: 0 0 4px;
    color: var(--navy);
}

/* ── Hero ──────────────────────────────────── */
.hero {
    text-align: center;
    padding: 80px 24px;
    background: url('images/hero-banner.svg') center/cover no-repeat;
    color: #fff;
    min-height: 420px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}
.hero h1 {
    font-family: 'Barlow Condensed', sans-serif;
    font-size: 2.8rem;
    margin: 0 0 16px;
    color: #fff;
}
.hero p { font-size: 1.1rem; max-width: 600px; margin: 0 auto; color: rgba(255,255,255,0.8); }
.hero-cta {
    display: inline-block;
    margin-top: 24px;
    padding: 14px 32px;
    background: var(--teal);
    color: #fff;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 700;
    font-size: 1rem;
    transition: background 0.2s;
}
.hero-cta:hover { background: #002d7a; }

/* ── Pricing ───────────────────────────────── */
.pricing-section { padding: 48px 24px; text-align: center; }
.pricing-section h2 {
    font-family: 'Barlow Condensed', sans-serif;
    margin-bottom: 32px;
    color: var(--navy);
}
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    max-width: 900px;
    margin: 0 auto;
}
.price-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 24px;
    text-align: center;
}
.price-card .size-label {
    font-weight: 600;
    font-size: 1.1rem;
    color: var(--navy);
    margin-bottom: 8px;
}
.price-card .price {
    font-family: 'Barlow Condensed', sans-serif;
    font-size: 2.4rem;
    font-weight: 700;
    color: var(--teal);
}
.price-card .per-month { color: var(--text-muted); font-size: 0.9rem; }

/* ── Steps ─────────────────────────────────── */
.steps-section {
    padding: 48px 24px;
    background: var(--bg);
    text-align: center;
}
.steps-section h2 {
    font-family: 'Barlow Condensed', sans-serif;
    margin-bottom: 32px;
    color: var(--navy);
}
.steps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 24px;
    max-width: 900px;
    margin: 0 auto;
}
.step-card {
    background: var(--surface);
    border-radius: 12px;
    padding: 28px;
    box-shadow: 0 1px 6px rgba(0,0,0,0.04);
}
.step-number {
    width: 40px; height: 40px;
    border-radius: 50%;
    background: var(--teal);
    color: #fff;
    font-weight: 700;
    font-size: 1.1rem;
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto 16px;
}

/* ── Stat Cards ────────────────────────────── */
.stat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}
.stat-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 20px;
    text-align: center;
}
.stat-card .stat-label {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 4px;
}
.stat-card .stat-value {
    font-family: 'Barlow Condensed', sans-serif;
    font-size: 2rem;
    font-weight: 700;
    color: var(--teal);
}

/* ── Status Badges ─────────────────────────── */
.badge { display: inline-block; padding: 4px 10px; border-radius: 20px; font-size: 0.78rem; font-weight: 600; }
.badge-pending { background: #fff3cd; color: #856404; }
.badge-confirmed { background: #d1ecf1; color: #0c5460; }
.badge-stored, .badge-instorage { background: #d4edda; color: #155724; }
.badge-retrieval { background: #f8d7da; color: #721c24; }
.badge-delivered, .badge-returned { background: #e2e3e5; color: #383d41; }
.badge-cancelled { background: #f5c6cb; color: #721c24; }
.badge-pickup { background: #cce5ff; color: #004085; }
.badge-outfordelivery { background: #fff3cd; color: #856404; }

/* ── Footer ────────────────────────────────── */
.footer {
    text-align: center;
    padding: 32px 24px;
    color: var(--text-muted);
    font-size: 0.85rem;
    border-top: 1px solid var(--border);
    margin-top: 48px;
}
.footer a { color: var(--teal); }
.footer p { margin: 4px 0; }

/* ── Warehouse Grid ────────────────────────── */
.wh-grid { display: grid; gap: 6px; }
.wh-slot {
    aspect-ratio: 1;
    border: 2px solid var(--border);
    border-radius: 6px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.15s;
}
.wh-slot:hover { border-color: var(--teal); }
.wh-slot.occupied { background: #d4dbf5; border-color: var(--teal); }
.wh-slot.empty { background: var(--surface); }
.wh-slot .slot-label { font-weight: 600; color: var(--navy); }
.wh-slot .slot-info { font-size: 0.65rem; color: var(--text-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 90%; }

/* ── Responsive ────────────────────────────── */
@media (max-width: 768px) {
    .app-nav { flex-wrap: wrap; height: auto; padding: 12px 16px; gap: 8px; }
    .app-nav .nav-links { flex-wrap: wrap; gap: 12px; }
    .hero h1 { font-size: 2rem; }
    .page-container { padding: 20px 16px; }
}

/* ── Blazor Defaults ───────────────────────── */
.blazor-error-boundary { background: #b32121; padding: 1rem; color: white; }
.blazor-error-boundary::after { content: "An error has occurred."; }
.valid.modified:not([type=checkbox]) { outline: 1px solid #26b050; }
.invalid { outline: 1px solid #e50000; }
.validation-message { color: #e50000; }
