/* Agent spend site (31 Oct 2026): the campaign builder's Lifestyle look. Phone first - one
   column, 44px tap targets, 16px inputs so iOS doesn't zoom - and comfortable on a desktop. */
@font-face { font-family: "Manrope"; src: url("../assets/fonts/Manrope-Regular.ttf") format("truetype"); font-weight: 400; }
@font-face { font-family: "Manrope"; src: url("../assets/fonts/Manrope-SemiBold.ttf") format("truetype"); font-weight: 600; }
@font-face { font-family: "Manrope"; src: url("../assets/fonts/Manrope-Bold.ttf") format("truetype"); font-weight: 700; }
@font-face { font-family: "Manrope"; src: url("../assets/fonts/Manrope-ExtraBold.ttf") format("truetype"); font-weight: 800; }

:root {
  --navy: #03223b;
  --navy-soft: #24425c;
  --cream: #f1f1ef;
  --sand: #ebe6df;
  --white: #ffffff;
  --line: #ddd7ce;
  --ok-bg: #e3f3e8; --ok: #1d5c35;
  --no-bg: #fbe7e5; --no: #8c1d16;
  --wait-bg: #fdf1dc; --wait: #7a4d00;
}

* { box-sizing: border-box; }
html, body { min-height: 100%; }
body { margin: 0; font-family: "Manrope", system-ui, sans-serif; color: var(--navy); background: var(--cream); }
.hidden { display: none !important; }
a { color: var(--navy); }

/* ---------- sign-in gate ---------- */
.gate { min-height: 100vh; display: flex; align-items: center; justify-content: center; background: var(--sand); padding: 16px; }
.gate-card { background: var(--white); padding: 40px 32px; border-radius: 14px; max-width: 460px; width: 100%; text-align: center; box-shadow: 0 18px 60px rgba(3, 34, 59, 0.12); }
.gate-logo { width: 180px; max-width: 70%; margin-bottom: 18px; }
.gate-card h1 { font-size: 22px; font-weight: 800; margin: 0 0 10px; }
.gate-card p { font-size: 14px; color: var(--navy-soft); margin: 0 0 24px; }
.gate-status { font-size: 13px; color: var(--navy-soft); margin: 10px 0 0 !important; }
.build-stamp { font-size: 11px; color: var(--navy-soft); opacity: 0.6; margin: 16px 0 0 !important; }

/* ---------- buttons ---------- */
.btn { font-family: inherit; font-size: 14px; font-weight: 700; border: 1.5px solid var(--navy); background: var(--white); color: var(--navy);
  padding: 10px 22px; border-radius: 999px; cursor: pointer; transition: background 0.15s ease; min-height: 44px; }
.btn:hover { background: var(--sand); }
.btn.primary { background: var(--navy); color: var(--white); }
.btn.primary:hover { background: #0a3354; }
.btn.small { font-size: 13px; padding: 6px 14px; min-height: 36px; }
.btn:disabled { opacity: 0.5; cursor: default; }

/* ---------- top bar ---------- */
.topbar { display: flex; align-items: center; gap: 12px; background: var(--white); border-bottom: 1px solid var(--line); padding: 10px 16px; flex-wrap: wrap; }
.topbar-mark { height: 30px; width: 30px; border-radius: 7px; }
.topbar-title { font-weight: 800; font-size: 15px; }
.topbar-link { font-size: 14px; font-weight: 600; }
.spacer { flex: 1; }
.user-name { font-size: 13px; color: var(--navy-soft); }

/* ---------- page ---------- */
.sp-main { max-width: 760px; margin: 0 auto; padding: 16px 16px 48px; display: flex; flex-direction: column; gap: 16px; }
.sp-head h1 { margin: 4px 0 4px; font-size: 24px; }
.sp-sub { margin: 0; font-size: 14px; color: var(--navy-soft); }
.sp-h2 { margin: 8px 0 8px; font-size: 13px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--navy-soft); display: flex; align-items: center; gap: 8px; }
.sp-count { background: var(--navy); color: var(--white); border-radius: 999px; padding: 1px 8px; font-size: 12px; letter-spacing: 0; }
.sp-count:empty { display: none; }
.sp-empty { margin: 0; padding: 16px; background: var(--white); border: 1.5px solid var(--line); border-radius: 12px; font-size: 15px; color: var(--navy-soft); }
.sp-flash { margin: 0; padding: 12px 14px; border-radius: 10px; font-size: 15px; background: var(--sand); }
.sp-flash.ok { background: var(--ok-bg); color: var(--ok); }
.sp-flash.no { background: var(--no-bg); color: var(--no); }
.status { font-size: 14px; margin: 0; min-height: 18px; color: var(--navy-soft); }
.status.err, .error { color: #b3261e; }
.error { font-size: 14px; margin: 0; }

/* ---------- what's left ---------- */
.sp-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 10px; }
.sp-tile { background: var(--white); border: 1.5px solid var(--line); border-radius: 12px; padding: 14px 16px; display: flex; flex-direction: column; gap: 2px; }
.sp-tile-label { font-size: 12px; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; color: var(--navy-soft); }
.sp-tile-value { font-size: 26px; font-weight: 800; font-variant-numeric: tabular-nums; }
.sp-tile-value.neg { color: #b3261e; }
.sp-tile-note { font-size: 13px; color: var(--navy-soft); }

/* ---------- the form ---------- */
.sp-card { background: var(--white); border: 1.5px solid var(--line); border-radius: 12px; padding: 16px; display: flex; flex-direction: column; gap: 14px; }
.sp-field { display: flex; flex-direction: column; gap: 6px; }
.sp-label { font-size: 14px; font-weight: 700; }
.sp-hint { font-size: 13px; color: var(--navy-soft); font-weight: 400; }
.sp-input, .sp-select, .sp-text { font: inherit; font-size: 16px; padding: 10px 12px; border: 1.5px solid var(--line); border-radius: 8px; background: var(--white); color: var(--navy); width: 100%; min-height: 44px; }
.sp-input:focus, .sp-select:focus, .sp-text:focus, .sp-kind input:focus-visible + span { outline: 2px solid var(--navy); outline-offset: 1px; }
.sp-text { resize: vertical; }
.sp-money { display: flex; align-items: center; gap: 8px; }
.sp-money span { font-size: 18px; font-weight: 700; }
.sp-money .sp-input { max-width: 220px; font-variant-numeric: tabular-nums; }
.sp-kinds { display: flex; flex-direction: column; gap: 8px; border: 0; margin: 0; padding: 0; }
.sp-kind { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: 10px; cursor: pointer; min-height: 44px; }
.sp-kind input { margin: 3px 0 0; width: 18px; height: 18px; accent-color: var(--navy); flex: none; }
.sp-kind:has(input:checked) { border-color: var(--navy); background: var(--cream); }
.sp-kind strong { display: block; font-size: 15px; }
.sp-kind small { display: block; font-size: 13px; color: var(--navy-soft); margin-top: 2px; }
.sp-quote { margin: 0; padding: 10px 12px; border-radius: 8px; background: var(--cream); font-size: 14px; }
.sp-quote.warn { background: var(--wait-bg); color: var(--wait); }
.sp-actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }

/* ---------- lists and cards ---------- */
.sp-list { list-style: none; margin: 0; padding: 0; background: var(--white); border: 1.5px solid var(--line); border-radius: 12px; }
.sp-row { display: flex; justify-content: space-between; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.sp-row:last-child { border-bottom: 0; }
.sp-row-left { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.sp-row-right { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; flex: none; }
.sp-desc { font-size: 15px; font-weight: 600; overflow-wrap: anywhere; }
.sp-meta { font-size: 13px; color: var(--navy-soft); overflow-wrap: anywhere; }
.sp-amt { font-size: 16px; font-weight: 700; white-space: nowrap; font-variant-numeric: tabular-nums; }
.sp-pill { font-size: 12px; font-weight: 600; padding: 2px 9px; border-radius: 999px; background: var(--sand); white-space: nowrap; }
.sp-pill.ok { background: var(--ok-bg); color: var(--ok); }
.sp-pill.no { background: var(--no-bg); color: var(--no); }
.sp-pill.wait { background: var(--wait-bg); color: var(--wait); }
.sp-reason { font-size: 13px; color: var(--no); overflow-wrap: anywhere; }

.sp-cards { display: flex; flex-direction: column; gap: 10px; }
.sp-acard { background: var(--white); border: 1.5px solid var(--line); border-radius: 12px; overflow: hidden; }
.sp-acard-head { width: 100%; display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; padding: 14px 16px; min-height: 44px;
  background: none; border: 0; text-align: left; font: inherit; color: inherit; cursor: pointer; }
.sp-acard-head:focus-visible { outline: 2px solid var(--navy); outline-offset: -2px; }
.sp-agent { font-size: 12px; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; color: var(--navy-soft); }
.sp-big { font-size: 20px; font-weight: 700; white-space: nowrap; font-variant-numeric: tabular-nums; }
.sp-acard-body { padding: 12px 16px 16px; display: flex; flex-direction: column; gap: 12px; border-top: 1px solid var(--line); }
.sp-table { width: 100%; border-collapse: collapse; font-size: 15px; font-variant-numeric: tabular-nums; }
.sp-table th { text-align: left; font-weight: 400; padding: 7px 0; border-bottom: 1px solid var(--line); }
.sp-table td { text-align: right; padding: 7px 0; border-bottom: 1px solid var(--line); }
.sp-table .strong th, .sp-table .strong td { font-weight: 700; }
.sp-table .neg td { color: #b3261e; font-weight: 700; }
.sp-hist { background: var(--cream); border-radius: 10px; padding: 12px; display: flex; flex-direction: column; gap: 6px; }
.sp-hist h3 { margin: 0; font-size: 14px; }
.sp-hist .sp-list { background: transparent; border: 0; }
.sp-hist .sp-row { padding: 8px 0; }
.sp-buttons { display: flex; gap: 10px; }
.sp-buttons .btn { flex: 1; min-height: 48px; font-size: 16px; }

@media (min-width: 720px) {
  .sp-main { padding-top: 28px; }
  .sp-buttons .btn { flex: 0 1 200px; }
}
