/* AIOS Warehouse admin shell and pages (AIOS-1536), built to Ruby's AIOS-1517 mocks. */
:root {
  --wh-navy: #0a2453;
  --wh-navy-2: #0f2f6b;
  --wh-blue: #1463f3;
  --wh-blue-soft: #e8f0fe;
  --wh-ink: #0b1f44;
  --wh-muted: #5b6b86;
  --wh-line: #e3e8f1;
  --wh-bg: #f5f7fb;
  --wh-green: #0f9d58;
  --wh-green-soft: #e7f6ee;
  --wh-red: #d93025;
  --wh-red-soft: #fdecec;
  --wh-amber: #b26a00;
  --wh-amber-soft: #fff4e0;
  --vz-primary: #1463f3;
  --vz-primary-rgb: 20, 99, 243;
  /* System fonts only: no web font download (AIOS-1590 dropped the theme's Google Fonts import). */
  --vz-font-sans-serif: Inter, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --vz-body-font-family: var(--vz-font-sans-serif);
  --vz-btn-font-family: var(--vz-font-sans-serif);
}
:is(.h1, .h2, .h3, .h4, .h5, .h6, h1, h2, h3, h4, h5, h6) { font-family: var(--vz-font-sans-serif); }
body { background: var(--wh-bg); color: var(--wh-ink); font-family: Inter, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; }
.btn-primary { --vz-btn-bg: var(--wh-blue); --vz-btn-border-color: var(--wh-blue); --vz-btn-hover-bg: #0f52cc; --vz-btn-hover-border-color: #0f52cc; --vz-btn-active-bg: #0d47b3; background-color: var(--wh-blue); border-color: var(--wh-blue); }
.btn { border-radius: 8px; font-weight: 500; }
.btn:focus-visible, .form-control:focus, .form-select:focus { box-shadow: 0 0 0 3px rgba(20, 99, 243, .25); }

/* Sidebar */
.wh-sidebar, [data-sidebar=dark] .navbar-menu { background: var(--wh-navy) !important; border-right: 0; }
.wh-sidebar .navbar-brand-box { background: var(--wh-navy); padding: 14px 18px 6px; text-align: left; }
.wh-brand img { filter: brightness(0) invert(1); max-width: 150px; max-height: 56px; }
.wh-brand .logo-sm img { max-height: 32px; }
.wh-sidebar .navbar-nav .nav-link { font-family: var(--vz-font-sans-serif); color: rgba(255,255,255,.82) !important; border-radius: 10px; margin: 4px 12px; padding: 11px 14px !important; font-size: 15px; }
.wh-sidebar .navbar-nav .nav-link i { color: inherit !important; font-size: 20px; margin-right: 6px; }
.wh-sidebar .navbar-nav .nav-link:hover { background: rgba(255,255,255,.08); color: #fff !important; }
.wh-sidebar .navbar-nav .nav-link.active { background: var(--wh-blue) !important; color: #fff !important; }
#page-topbar { background: #fff; border-bottom: 1px solid var(--wh-line); box-shadow: none; }
.wh-topbar-brand { display: inline-flex; align-items: center; text-decoration: none; }
.wh-topbar-brand img { max-height: 30px; width: auto; }
.wh-topbar-brand .wh-wordmark { color: var(--wh-navy); font-size: 19px; }
.wh-topbar-brand .wh-wordmark small { font-size: 14px; }
.wh-avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--wh-navy); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-weight: 600; font-size: 13px; }
.footer { display: none; }

/* Page */
.wh-page { padding: 8px 24px 32px; max-width: 1480px; }
.wh-eyebrow { font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--wh-muted); margin: 0 0 2px; }
.wh-title { font-size: 34px; font-weight: 700; color: var(--wh-ink); margin: 0; line-height: 1.15; }
.wh-sub { color: var(--wh-muted); margin: 6px 0 0; font-size: 15px; }
.wh-head { display: flex; gap: 16px; align-items: flex-start; justify-content: space-between; flex-wrap: wrap; margin: 18px 0 18px; }
.wh-card { background: #fff; border: 1px solid var(--wh-line); border-radius: 14px; padding: 20px 22px; margin-bottom: 18px; }
.wh-card h2, .wh-card .h2 { font-size: 19px; font-weight: 700; margin: 0 0 4px; color: var(--wh-ink); }
.wh-card .wh-hint { color: var(--wh-muted); font-size: 13.5px; margin: 0 0 14px; }
.wh-grid { display: grid; gap: 18px; }
@media (min-width: 992px) {
  .wh-grid-2 { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); }
  .wh-grid-3 { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr) minmax(0, 1fr); }
  .wh-grid-side { grid-template-columns: minmax(0, 1fr) 320px; }
  .wh-grid-groups { grid-template-columns: 280px minmax(0, 1fr) 340px; }
}
.wh-pill { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 600; border-radius: 999px; padding: 3px 11px; white-space: nowrap; }
.wh-pill::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.wh-pill.plain::before { display: none; }
.wh-pill.green { background: var(--wh-green-soft); color: var(--wh-green); }
.wh-pill.red { background: var(--wh-red-soft); color: var(--wh-red); }
.wh-pill.amber { background: var(--wh-amber-soft); color: var(--wh-amber); }
.wh-pill.grey { background: #eef1f6; color: #4a5872; }
.wh-pill.blue { background: var(--wh-blue-soft); color: var(--wh-blue); }
.wh-chip { display: inline-block; background: var(--wh-blue-soft); color: #1a4fb8; border-radius: 6px; padding: 2px 9px; font-size: 12.5px; margin: 2px 4px 2px 0; }
.wh-chip.customer { background: #f1e8fd; color: #6b2fc4; }
code.wh-code, .wh-code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12.5px; color: var(--wh-ink); background: #f1f4f9; border-radius: 5px; padding: 1px 6px; }
.wh-wa { color: var(--wh-green) !important; font-weight: 500; white-space: nowrap; text-decoration: none; }
.wh-wa i { font-size: 17px; vertical-align: -3px; margin-right: 3px; }
.wh-alert { border-radius: 12px; padding: 14px 16px; display: flex; gap: 12px; align-items: flex-start; margin-bottom: 14px; font-size: 14px; }
.wh-alert i { font-size: 22px; line-height: 1; }
.wh-alert.red { background: var(--wh-red-soft); color: #8a1c14; border: 1px solid #f6c7c3; }
.wh-alert.amber { background: var(--wh-amber-soft); color: #7a4a00; border: 1px solid #f3d9a6; }
.wh-alert.blue { background: var(--wh-blue-soft); color: #173f8f; border: 1px solid #c9dafc; }
.wh-alert.green { background: var(--wh-green-soft); color: #0b6b3c; border: 1px solid #bfe6cf; }
.wh-alert strong { display: block; }

/* Forms */
.wh-form .form-label { font-weight: 600; color: var(--wh-ink); margin-bottom: 5px; font-size: 14px; }
.wh-form .req { color: var(--wh-red); margin-left: 2px; }
.wh-form .opt { color: var(--wh-muted); font-weight: 400; margin-left: 4px; font-size: 13px; }
.wh-form .form-control, .wh-form .form-select { border-radius: 8px; border-color: #cfd8e6; min-height: 42px; font-size: 15px; }
.wh-form .help { color: var(--wh-muted); font-size: 12.5px; margin-top: 4px; }
.wh-form .error { color: var(--wh-red); font-size: 12.5px; margin-top: 4px; display: block; }
.wh-form .error[hidden] { display: none; }
.wh-form .invalid, .wh-form .is-invalid { border-color: var(--wh-red) !important; background-color: #fff7f7; }
.wh-form .actions { display: flex; gap: 12px; justify-content: flex-end; margin-top: 18px; flex-wrap: wrap; }
.wh-form .actions .btn { min-width: 130px; min-height: 42px; }
.wh-pw { position: relative; }
.wh-pw .form-control { padding-right: 44px; }
.wh-pw button { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); border: 0; background: none; color: var(--wh-muted); width: 36px; height: 36px; }
.wh-row-field { display: grid; grid-template-columns: 170px minmax(0, 1fr); gap: 6px 16px; align-items: start; margin-bottom: 14px; }
.wh-row-field > label { padding-top: 10px; margin: 0; }
@media (max-width: 767.98px) { .wh-row-field { grid-template-columns: 1fr; } .wh-row-field > label { padding-top: 0; } }

/* Tables */
.wh-table { width: 100%; border-collapse: separate; border-spacing: 0; }
.wh-table th { background: #f3f6fb; color: var(--wh-muted); font-weight: 600; font-size: 13px; padding: 11px 12px; text-align: left; white-space: nowrap; }
.wh-table td { padding: 12px; border-top: 1px solid var(--wh-line); vertical-align: middle; font-size: 14px; }
.wh-table tr:hover td { background: #fafcff; }
.wh-table a.wh-name { color: var(--wh-ink); font-weight: 600; text-decoration: none; }
.wh-table a.wh-name:hover { color: var(--wh-blue); }

/* People cards on handhelds */
.wh-person-card { background: #fff; border: 1px solid var(--wh-line); border-radius: 14px; padding: 14px; margin-bottom: 12px; }
.wh-person-card .top { display: flex; gap: 12px; }
.wh-initials { width: 46px; height: 46px; border-radius: 50%; background: var(--wh-blue-soft); color: #1a4fb8; display: flex; align-items: center; justify-content: center; font-weight: 700; flex: 0 0 46px; }
.wh-person-card .meta { min-width: 0; flex: 1; }
.wh-person-card .meta div { overflow-wrap: anywhere; font-size: 14px; }
.wh-person-card .foot { display: flex; justify-content: space-between; gap: 8px; border-top: 1px solid var(--wh-line); margin-top: 10px; padding-top: 10px; flex-wrap: wrap; }

/* Home */
.wh-banner { background: #fff5f5; border: 1px solid #f5c9c6; border-radius: 16px; padding: 22px; display: flex; gap: 22px; flex-wrap: wrap; }
.wh-banner .lock { width: 64px; height: 64px; border-radius: 50%; background: #fbdedb; color: var(--wh-red); display: flex; align-items: center; justify-content: center; font-size: 30px; flex: 0 0 64px; }
.wh-banner h2 { font-size: 24px; font-weight: 700; margin: 0 0 6px; }
.wh-banner.ok { background: var(--wh-green-soft); border-color: #bfe6cf; }
.wh-banner.ok .lock { background: #cdeedb; color: var(--wh-green); }
.wh-steps { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); margin: 14px 0; }
.wh-step { background: #fff; border: 1px solid var(--wh-line); border-radius: 12px; padding: 16px 14px; text-align: center; position: relative; }
.wh-step .n { position: absolute; left: 12px; top: 10px; width: 26px; height: 26px; border-radius: 50%; background: var(--wh-blue-soft); color: var(--wh-blue); font-weight: 700; font-size: 13px; display: flex; align-items: center; justify-content: center; }
.wh-step i { font-size: 30px; color: var(--wh-navy); display: block; margin: 6px 0 6px; }
.wh-step b { display: block; font-size: 15px; }
.wh-step span { color: var(--wh-muted); font-size: 13px; }
.wh-tiles { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }
.wh-tile { background: #fff; border: 1px solid var(--wh-line); border-radius: 14px; padding: 18px; display: flex; flex-direction: column; gap: 10px; }
.wh-tile.restricted { background: #fff6f6; border-color: #f5c9c6; }
.wh-tile .ti { display: flex; gap: 12px; align-items: flex-start; }
.wh-tile .ti i { font-size: 30px; color: var(--wh-blue); }
.wh-tile.restricted .ti i { color: var(--wh-red); }
.wh-tile h3 { font-size: 17px; font-weight: 700; margin: 0; }
.wh-tile p { color: var(--wh-muted); font-size: 13.5px; margin: 2px 0 0; }
.wh-tile .btn { margin-top: auto; }
a.wh-job { color: inherit; text-decoration: none; }
a.wh-job:hover { border-color: var(--wh-blue); }
.wh-empty { color: var(--wh-muted); font-size: 16px; margin: 8px 0 0; }
.wh-status-row { display: flex; justify-content: space-between; gap: 10px; align-items: center; padding: 9px 0; border-top: 1px solid var(--wh-line); font-size: 14px; }
.wh-status-row:first-child { border-top: 0; }

/* Status column (setup) */
.wh-state { border-radius: 12px; padding: 14px; display: flex; gap: 12px; margin-bottom: 12px; border: 1px solid transparent; }
.wh-state i { font-size: 24px; }
.wh-state.missing, .wh-state.unavailable { background: var(--wh-red-soft); border-color: #f6c7c3; }
.wh-state.missing i, .wh-state.unavailable i { color: var(--wh-red); }
.wh-state.incomplete, .wh-state.attention { background: var(--wh-amber-soft); border-color: #f3d9a6; }
.wh-state.incomplete i, .wh-state.attention i { color: var(--wh-amber); }
.wh-state.recorded, .wh-state.set { background: var(--wh-green-soft); border-color: #bfe6cf; }
.wh-state.recorded i, .wh-state.set i { color: var(--wh-green); }
.wh-state > div { min-width: 0; }
.wh-state .wh-pill { max-width: 100%; white-space: normal; }
.wh-state b { display: block; font-size: 15px; }
.wh-state p { margin: 4px 0 0; font-size: 13px; color: #374767; }

/* Groups */
.wh-group-item { display: block; border: 1px solid var(--wh-line); border-radius: 10px; padding: 11px 12px; margin-bottom: 9px; color: var(--wh-ink); text-decoration: none; background: #fff; }
.wh-group-item:hover { border-color: #b9cbef; }
.wh-group-item.active { border-color: var(--wh-blue); background: #f2f7ff; box-shadow: 0 0 0 1px var(--wh-blue) inset; }
.wh-group-item b { display: block; font-size: 15px; }
.wh-cap-table td, .wh-cap-table th { padding: 8px 10px; font-size: 13.5px; }
.wh-cap-table tr.setup td { background: #fff8e6; }
.wh-member { display: flex; align-items: center; gap: 10px; padding: 7px 0; border-top: 1px solid var(--wh-line); }
.wh-member:first-child { border-top: 0; }
.wh-member .wh-initials { width: 32px; height: 32px; flex-basis: 32px; font-size: 12px; }
.wh-member .who { flex: 1; min-width: 0; overflow-wrap: anywhere; font-size: 14px; }
.wh-iconbtn { border: 0; background: none; color: var(--wh-muted); padding: 4px 8px; border-radius: 6px; }
.wh-iconbtn:hover { background: #f1f4f9; color: var(--wh-red); }

/* Restricted */
.wh-restricted { max-width: 520px; margin: 48px auto; text-align: center; }
.wh-restricted .lock { width: 84px; height: 84px; border-radius: 50%; background: var(--wh-blue-soft); color: var(--wh-blue); display: inline-flex; align-items: center; justify-content: center; font-size: 38px; margin-bottom: 14px; }

/* Bottom nav (handheld) */
.wh-bottom-nav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 1003; background: #fff; border-top: 1px solid var(--wh-line); display: flex; padding: 6px 4px calc(6px + env(safe-area-inset-bottom)); }
.wh-bottom-nav a { flex: 1; text-align: center; color: var(--wh-muted); font-size: 11.5px; text-decoration: none; padding: 4px 2px; border-radius: 10px; }
.wh-bottom-nav a i { display: block; font-size: 22px; line-height: 1.1; }
.wh-bottom-nav a.active { color: var(--wh-blue); background: var(--wh-blue-soft); }
@media (max-width: 767.98px) {
  .main-content .page-content { padding-bottom: 84px !important; }
  .wh-page { padding: 4px 14px 24px; }
  .wh-title { font-size: 28px; }
  .wh-head .btn { width: 100%; }
  .wh-form .actions .btn { flex: 1; min-width: 0; }
}

/* Landing sign-in */
.wh-landing { min-height: 100vh; background: radial-gradient(1200px 700px at 15% 20%, #13306b 0%, #0a1a3d 45%, #060f26 100%); color: #fff; display: grid; grid-template-columns: minmax(0, 1fr) 420px; gap: 32px; padding: 36px 48px; align-items: center; }
.wh-landing .brand img { filter: brightness(0) invert(1); max-height: 60px; }
.wh-landing .brand span { font-size: 26px; font-weight: 600; margin-left: 8px; vertical-align: middle; }
.wh-landing h1 { color: #fff; font-size: 56px; font-weight: 700; line-height: 1.05; margin: 90px 0 18px; }
.wh-landing .lead-text { color: rgba(255,255,255,.78); font-size: 19px; max-width: 520px; }
.wh-signin { background: rgba(13, 22, 44, .92); border: 1px solid rgba(255,255,255,.12); border-radius: 14px; padding: 26px; }
.wh-signin h2 { color: #fff; font-size: 26px; font-weight: 700; margin: 0 0 4px; }
.wh-signin p { color: rgba(255,255,255,.7); }
.wh-signin .form-label { color: #fff; font-weight: 500; }
.wh-signin .form-control { background: #0d1630; border-color: rgba(255,255,255,.22); color: #fff; min-height: 44px; }
.wh-signin .form-control.is-invalid { border-color: #ff6b62 !important; background: #1a1430; }
.wh-signin .error { color: #ff8a82; font-size: 13px; margin-top: 4px; }
.wh-signin .wh-pw button { color: rgba(255,255,255,.7); }
.wh-signin .btn-primary { width: 100%; min-height: 46px; font-size: 16px; }
.wh-signin .notice { border-radius: 10px; padding: 10px 12px; margin-bottom: 14px; font-size: 14px; display: flex; gap: 8px; align-items: center; }
.wh-signin .notice.ok { background: rgba(15,157,88,.15); color: #8ff0bd; border: 1px solid rgba(15,157,88,.4); }
.wh-signin .notice.err { background: rgba(217,48,37,.15); color: #ffb3ad; border: 1px solid rgba(217,48,37,.45); }
@media (max-width: 991.98px) {
  .wh-landing { grid-template-columns: 1fr; padding: 22px 18px; align-content: start; }
  .wh-landing h1 { font-size: 36px; margin: 34px 0 10px; }
}

/* First-run setup */
.wh-setup-wrap { min-height: 100vh; background: var(--wh-bg); }
.wh-setup-top { background: var(--wh-navy); padding: 12px 24px; }
.wh-setup-top img { filter: brightness(0) invert(1); max-height: 40px; }
.wh-setup-body { max-width: 1240px; margin: 0 auto; padding: 26px 20px 40px; display: grid; gap: 22px; }
@media (min-width: 992px) { .wh-setup-body { grid-template-columns: minmax(0, 1fr) 360px; } }
.wh-rail { background: #eef4ff; border: 1px solid #d5e3fb; border-radius: 16px; padding: 22px; }
.wh-rail li { list-style: none; display: flex; gap: 10px; margin-bottom: 14px; }
.wh-rail li i { color: var(--wh-green); font-size: 22px; }
.wh-rail ul { padding: 0; margin: 14px 0 0; }
.wh-rail b { display: block; }
.wh-rail span { color: var(--wh-muted); font-size: 13.5px; }

/* Brand on navy: transparent mark inverted to white plus a text wordmark (the full logo PNG has an opaque background). */
.wh-brand img, .wh-setup-top img, .wh-landing .brand img { filter: brightness(0) invert(1); max-height: 38px; width: auto; vertical-align: middle; }
.wh-wordmark { color: #fff; font-size: 24px; font-weight: 700; letter-spacing: .01em; margin-left: 8px; vertical-align: middle; }
.wh-wordmark small { font-size: 16px; font-weight: 500; opacity: .9; }
.wh-sidebar .logo-lg { display: inline-flex; align-items: center; }
.wh-landing .brand span.wh-wordmark { font-size: 28px; }
/* The inherited libs.html sets h1/h2 to near-white; Warehouse pages use ink headings. */
.wh-page h1, .wh-page h2, .wh-page h3, .wh-setup-body h1, .wh-setup-body h2, .wh-restricted h1, .wh-tile h3 { color: var(--wh-ink); }
.wh-cap-table th:nth-child(3), .wh-cap-table th:nth-child(4), .wh-cap-table td:nth-child(3), .wh-cap-table td:nth-child(4) { width: 56px; }
/* Three narrow columns below 1400px leave no room beside a 170px label: stack label over input there. */
@media (min-width: 992px) and (max-width: 1399.98px) { .wh-grid-3 .wh-row-field { grid-template-columns: 1fr; } .wh-grid-3 .wh-row-field > label { padding-top: 0; } }
/* Same columns: the status icon goes above its text so a "Not configured" badge keeps one line inside its card. */
@media (min-width: 992px) and (max-width: 1399.98px) { .wh-grid-3 .wh-state { flex-direction: column; gap: 6px; } }
@media (min-width: 992px) and (max-width: 1399.98px) { .wh-grid-groups { grid-template-columns: 240px minmax(0, 1fr); } .wh-grid-groups > div:last-child { grid-column: 1 / -1; display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); } }
