:root {
  --navy: #123e4a;
  --deep: #0c303a;
  --teal: #20b8b0;
  --mint: #e7f7f6;
  --sand: #f4f8f9;
  --ink: #1a2433;
  --muted: #5b6b7c;
  --danger: #c0392b;
  --ok: #1f8a70;
  --radius: 18px;
  --shadow: 0 24px 60px rgba(12, 48, 58, 0.28);
  font-family: Manrope, system-ui, sans-serif;
  color: var(--ink);
  background: radial-gradient(1200px 600px at 10% -10%, #1a5a66 0%, transparent 55%),
    radial-gradient(900px 500px at 90% 0%, #20b8b033 0%, transparent 50%),
    linear-gradient(160deg, #0c303a 0%, #123e4a 42%, #0a242c 100%);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  min-height: 100vh;
}

button,
input {
  font: inherit;
}

.stage {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 48px;
  align-items: center;
  justify-content: center;
  padding: 40px 32px;
}

.stage-copy {
  max-width: 420px;
  color: #f4f8f9;
}

.eyebrow {
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-size: 12px;
  font-weight: 700;
  color: var(--teal);
  margin: 0 0 14px;
}

.stage-copy h1 {
  margin: 0;
  font-size: clamp(2rem, 3vw, 3.2rem);
  line-height: 1.05;
  font-weight: 800;
}

.lede {
  margin: 18px 0 0;
  color: rgba(244, 248, 249, 0.78);
  line-height: 1.55;
  font-size: 1.02rem;
}

.phone-shell {
  width: min(390px, 100%);
  height: min(820px, calc(100vh - 64px));
  background: #07161c;
  border-radius: 42px;
  padding: 12px;
  box-shadow: var(--shadow), inset 0 0 0 2px rgba(255, 255, 255, 0.08);
  position: relative;
}

.phone-notch {
  position: absolute;
  top: 18px;
  left: 50%;
  transform: translateX(-50%);
  width: 118px;
  height: 28px;
  background: #050d11;
  border-radius: 20px;
  z-index: 5;
}

.phone-screen {
  height: 100%;
  border-radius: 32px;
  overflow: hidden;
  background: var(--sand);
  position: relative;
}

.boot {
  height: 100%;
  display: grid;
  place-content: center;
  gap: 10px;
  text-align: center;
  background: linear-gradient(180deg, var(--navy), var(--deep));
  color: white;
}

.boot-mark {
  font-weight: 800;
  letter-spacing: 0.12em;
  font-size: 1.4rem;
}

.app-root {
  height: 100%;
  display: flex;
  flex-direction: column;
  background: var(--sand);
}

.screen {
  flex: 1;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
}

.hero-login {
  min-height: 100%;
  display: flex;
  flex-direction: column;
  background:
    linear-gradient(180deg, rgba(12, 48, 58, 0.55), rgba(12, 48, 58, 0.88)),
    radial-gradient(circle at 70% 18%, #20b8b066, transparent 42%),
    linear-gradient(165deg, #123e4a, #0c303a 60%, #07161c);
  color: white;
  padding: 72px 22px 28px;
}

.brand-lockup {
  font-size: 1.55rem;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.brand-sub {
  margin: 8px 0 0;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.95rem;
}

.login-card {
  margin-top: auto;
  background: white;
  color: var(--ink);
  border-radius: 28px 28px 22px 22px;
  padding: 22px 18px 18px;
  box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.18);
}

.login-card h2 {
  margin: 0;
  font-size: 1.25rem;
}

.login-card p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.field {
  display: grid;
  gap: 6px;
  margin-top: 14px;
}

.field span {
  font-size: 0.82rem;
  font-weight: 600;
  color: #334155;
}

.field input,
.field select,
.field textarea {
  border: 1px solid #d7e0e7;
  background: var(--sand);
  border-radius: 14px;
  padding: 13px 14px;
  width: 100%;
  resize: vertical;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: 2px solid color-mix(in srgb, var(--teal) 45%, white);
  border-color: var(--teal);
}

.hint {
  display: block;
  margin-top: 6px;
  font-size: 0.75rem;
  color: var(--muted);
}

.hint.warn {
  color: #9a5b00;
}

.info-box {
  margin-top: 12px;
  background: var(--mint);
  color: var(--navy);
  border-radius: 16px;
  padding: 12px 14px;
  font-size: 0.88rem;
  line-height: 1.45;
}

.info-box.ok {
  background: #e4f7ef;
  color: var(--ok);
}

.preview-box {
  margin-top: 8px;
  border: 1px solid color-mix(in srgb, var(--teal) 35%, white);
  background: color-mix(in srgb, var(--mint) 80%, white);
  border-radius: 18px;
  padding: 14px;
}

.preview-qty {
  margin-top: 4px;
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--navy);
}

.recap-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 12px;
  font-size: 0.88rem;
}

.recap-grid strong {
  display: block;
  margin-top: 2px;
  color: var(--navy);
}

.recap-list {
  margin: 0;
  padding: 14px;
  list-style: none;
  background: var(--sand);
  border-radius: 16px;
  font-size: 0.9rem;
  line-height: 1.55;
}

.wizard-steps {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  list-style: none;
  margin: 0 0 14px;
  padding: 0 0 4px;
}

.wizard-step {
  flex: 0 0 auto;
  white-space: nowrap;
  border-radius: 999px;
  padding: 7px 10px;
  font-size: 0.68rem;
  font-weight: 700;
  background: white;
  color: var(--muted);
  box-shadow: 0 4px 12px rgba(18, 62, 74, 0.06);
}

.wizard-step.active {
  background: var(--navy);
  color: white;
}

.wizard-step.done {
  background: var(--mint);
  color: var(--navy);
}

.wizard-actions {
  display: flex;
  gap: 8px;
  margin-top: 14px;
  align-items: center;
}

.wizard-actions .btn-primary,
.wizard-actions .btn-ghost {
  flex: 1;
}

.wizard-submit-row {
  display: flex;
  gap: 8px;
  width: 100%;
}

.wizard-submit-row .btn {
  flex: 1;
}

.leave-wizard .field {
  margin-top: 12px;
}

.btn {
  appearance: none;
  border: 0;
  border-radius: 999px;
  padding: 13px 16px;
  font-weight: 700;
  cursor: pointer;
}

.btn-primary {
  width: 100%;
  margin-top: 16px;
  background: linear-gradient(135deg, var(--teal), #149992);
  color: white;
}

.btn-primary:disabled {
  opacity: 0.65;
  cursor: wait;
}

.btn-ghost {
  background: transparent;
  color: var(--navy);
  padding: 8px 10px;
}

.error {
  margin-top: 12px;
  color: var(--danger);
  font-size: 0.88rem;
  font-weight: 600;
}

.topbar {
  padding: 54px 18px 14px;
  background: linear-gradient(180deg, var(--navy), var(--deep));
  color: white;
}

.topbar-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.topbar h1 {
  margin: 0;
  font-size: 1.15rem;
}

.topbar .muted {
  margin: 4px 0 0;
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.82rem;
}

.content {
  padding: 16px 16px 100px;
}

.card {
  background: white;
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: 0 10px 28px rgba(18, 62, 74, 0.08);
}

.card + .card {
  margin-top: 12px;
}

.kpi-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 14px;
}

.kpi {
  background: var(--mint);
  border-radius: 16px;
  padding: 14px;
}

.kpi strong {
  display: block;
  font-size: 1.35rem;
  color: var(--navy);
}

.kpi span {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 600;
}

.list-item {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 0;
  border-bottom: 1px solid #e8eef2;
}

.list-item:last-child {
  border-bottom: 0;
}

.badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 0.72rem;
  font-weight: 700;
  background: var(--mint);
  color: var(--navy);
}

.badge.pending {
  background: #fff4df;
  color: #9a5b00;
}
.badge.approved {
  background: #e4f7ef;
  color: var(--ok);
}
.badge.rejected {
  background: #fde8e6;
  color: var(--danger);
}

.tabbar {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 12px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid #e2ebf0;
  border-radius: 22px;
  padding: 8px;
  backdrop-filter: blur(10px);
}

.tabbar-5 {
  grid-template-columns: repeat(5, 1fr);
  gap: 2px;
  padding: 6px;
}

.tabbar-5 .tab {
  font-size: 0.68rem;
  padding: 8px 2px;
}

.tab {
  border: 0;
  background: transparent;
  border-radius: 16px;
  padding: 10px 6px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
}

.tab.active {
  background: var(--mint);
  color: var(--navy);
}

.empty {
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.45;
}

@media (max-width: 900px) {
  .stage {
    grid-template-columns: 1fr;
    padding: 0;
    gap: 0;
  }

  .stage-copy {
    display: none;
  }

  .phone-shell {
    width: 100%;
    height: 100vh;
    height: 100dvh;
    border-radius: 0;
    padding: 0;
    box-shadow: none;
  }

  .phone-notch {
    display: none;
  }

  .phone-screen {
    border-radius: 0;
  }

  .tabbar {
    left: 10px;
    right: 10px;
    bottom: max(10px, env(safe-area-inset-bottom));
  }
}
