/* app.creatorsure.co: the customer's application. CreatorSure's look (creatorsure.co/public/styles.css):
   dark ground, one cyan accent for actions. The app's content policy allows only its own origin, so
   no web fonts: the system font stands in for Inter and Bricolage Grotesque.
   Colour jobs: cyan = an action or the current place; amber = something to check (warnings, refused,
   failed); the notice tint = something about the person (signed out, offline), never red. */
:root {
  --bg: #0B0B12; --bg2: #12121C; --card: #171725; --field: #0E0E17;
  --line: rgba(255,255,255,.09); --line2: rgba(255,255,255,.16);
  --text: #F4F3FA; --muted: #A9A7BD; --cyan: #3DE0FF; --cyan-t: rgba(61,224,255,.12); --ink: #06141A;
  --amber: #F2B84B; --amber-t: rgba(242,184,75,.12);
  --r: 18px; --touch: 48px;
  --display: ui-rounded, system-ui, -apple-system, "Segoe UI", sans-serif;
  --body: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { background: var(--bg); color: var(--text); font: 17px/1.55 var(--body); -webkit-font-smoothing: antialiased; min-height: 100vh; }
a { color: var(--cyan); }
:focus-visible { outline: 3px solid var(--cyan); outline-offset: 2px; border-radius: 6px; }
h1:focus, h2:focus { outline: none; }

.wrap { width: min(760px, 100% - 32px); margin-inline: auto; padding: 28px 0 64px; }
h1, h2 { font-family: var(--display); letter-spacing: -.02em; line-height: 1.15; }
h1 { font-size: clamp(30px, 6vw, 42px); font-weight: 800; margin-bottom: 14px; }
h2 { font-size: clamp(22px, 4.2vw, 28px); font-weight: 750; margin: 6px 0 12px; }
p + p { margin-top: 12px; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.lede { font-size: 19px; color: #D6D4E6; margin: 12px 0; max-width: 60ch; }

/* top bar */
.top { position: sticky; top: 0; z-index: 10; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 10px max(16px, calc((100% - 760px) / 2)); padding-top: max(10px, env(safe-area-inset-top));
  background: rgba(11,11,18,.88); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.logo { display: flex; align-items: center; gap: 10px; min-height: var(--touch); text-decoration: none; color: var(--text);
  font-family: var(--display); font-weight: 800; font-size: 19px; letter-spacing: -.02em; }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: var(--touch); padding: 12px 24px;
  border-radius: 999px; background: var(--cyan); color: var(--ink); font: 700 17px/1.2 var(--body); text-decoration: none;
  border: 0; cursor: pointer; text-align: center; }
.btn:hover { box-shadow: 0 8px 26px -10px rgba(61,224,255,.6); }
.btn:disabled { opacity: .45; cursor: default; box-shadow: none; }
.btn-ghost { background: transparent; color: var(--text); border: 1.5px solid var(--line2); }
.btn-ghost:hover { border-color: var(--text); box-shadow: none; }
.btn-sm { padding: 8px 16px; font-size: 15px; min-height: 44px; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; align-items: center; }
.page-actions { justify-content: space-between; }
.page-actions .btn:last-child { flex: 1 1 auto; max-width: 320px; margin-left: auto; }
.actions.minor { margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--line); gap: 10px; }

/* lines about state */
.status-line { font-size: 19px; font-weight: 600; padding: 14px 16px; border-radius: 14px; background: var(--cyan-t);
  border-left: 4px solid var(--cyan); margin: 14px 0; }
.notice, .banner, .notice-block { background: rgba(255,255,255,.06); border-left: 4px solid var(--muted); border-radius: 12px; padding: 12px 16px; margin: 14px 0; }
.banner { margin: 0; border-radius: 0; border-left: 0; border-bottom: 1px solid var(--line); text-align: center; padding: 10px 16px; }
.notice-block { width: min(760px, 100% - 32px); margin: 18px auto 0; padding: 18px; }
.notice-block h2 { margin-top: 0; }
/* job S14: a screen left open when its session ends, set aside under the notice that says so. The page makes it inert
   (no tap, no key); here it is drawn set back, so nothing in it looks as if it could be pressed. pointer-events is for
   a browser from before `inert`. */
#view[data-set-aside] { opacity: .5; pointer-events: none; }
.warn { background: var(--amber-t); border-left: 4px solid var(--amber); border-radius: 12px; padding: 12px 16px; margin: 14px 0; }
.error { color: var(--amber); font-weight: 600; margin: 12px 0; }

/* progress */
.progress p { font-size: 15px; }
.bar { list-style: none; display: flex; gap: 6px; margin: 10px 0 18px; }
.bar li { flex: 1; height: 6px; border-radius: 3px; background: var(--line2); }
.bar li.full { background: rgba(61,224,255,.45); }
.bar li.here { background: var(--cyan); box-shadow: 0 0 0 2px var(--bg), 0 0 0 3px var(--cyan); }
h2.section { font-size: clamp(22px, 4.6vw, 30px); }
.section-note { color: #D6D4E6; margin-bottom: 8px; }

/* sections list */
.sections { list-style: none; display: grid; gap: 10px; margin: 20px 0 6px; counter-reset: s; }
.section-link { display: flex; justify-content: space-between; align-items: center; gap: 12px; min-height: 56px; padding: 12px 16px;
  border-radius: 14px; background: var(--card); border: 1px solid var(--line); color: var(--text); text-decoration: none; }
.section-link:hover { border-color: rgba(61,224,255,.5); }
.section-title { font-weight: 600; }
.count { color: var(--muted); font-size: 15px; white-space: nowrap; }
.done { color: var(--cyan); font-size: 15px; font-weight: 700; white-space: nowrap; }

/* questions */
.questions { display: grid; gap: 18px; margin-top: 8px; }
.q, .group { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 18px; min-width: 0; }
.group > .q { background: transparent; border: 0; padding: 0; margin-top: 16px; }
.group > .q:first-of-type { margin-top: 10px; }
fieldset { border: 0; min-width: 0; }
fieldset.group { border: 1px solid var(--line); }
.qhead { display: flex; gap: 10px; align-items: flex-start; }
.tag { flex: none; display: inline-block; padding: 2px 9px; border-radius: 999px; background: var(--cyan-t); color: var(--cyan);
  font-size: 14px; font-weight: 700; line-height: 1.6; }
.tag.ours { background: rgba(255,255,255,.08); color: var(--text); border: 1px dashed var(--line2); }
.qhead:has(.ours) { flex-direction: column; gap: 8px; }
.prompt { display: block; font-weight: 600; font-size: 17px; line-height: 1.45; overflow-wrap: anywhere; }
.label { display: block; margin-top: 10px; margin-bottom: 6px; color: #D6D4E6; font-size: 15.5px; font-weight: 500; overflow-wrap: anywhere; }
.qhead + .label { margin-top: 12px; }
input, textarea, select { display: block; width: 100%; min-height: var(--touch); margin-top: 8px; font: 400 17px/1.4 var(--body); color: var(--text);
  background: var(--field); border: 1.5px solid rgba(255,255,255,.14); border-radius: 12px; padding: 12px 14px; outline: none; }
input:focus, textarea:focus, select:focus { border-color: var(--cyan); }
input[aria-invalid=true] { border-color: var(--amber); }
textarea { resize: vertical; min-height: 120px; }
input[type=date] { -webkit-appearance: none; appearance: none; color-scheme: dark; }
.label + input, .label + textarea, .label + select, .label + .affix input, .label + .yesno { margin-top: 0; }
.affix { position: relative; }
.affix.money input { padding-left: 30px; }
.affix.percent input { padding-right: 34px; }
.affix.money::before, .affix.percent::after { position: absolute; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; font-size: 17px; }
.affix.money::before { content: "$"; left: 14px; margin-top: 4px; }
.affix.percent::after { content: "%"; right: 14px; margin-top: 4px; }
.label + .affix.money::before, .label + .affix.percent::after { margin-top: 0; }

.yesno { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 12px; max-width: 360px; }
.choice { min-height: var(--touch); border-radius: 12px; border: 1.5px solid rgba(255,255,255,.18); background: var(--field); color: var(--text);
  font: 600 17px/1 var(--body); cursor: pointer; }
.choice[aria-checked=true] { background: var(--cyan); color: var(--ink); border-color: var(--cyan); }
.choice:hover { border-color: var(--cyan); }

.hint { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 10px; padding: 10px 12px; border-radius: 12px;
  border: 1px dashed rgba(61,224,255,.45); background: var(--cyan-t); font-size: 15.5px; }
.hint span { flex: 1 1 200px; }

.save { min-height: 22px; margin-top: 8px; font-size: 14.5px; color: var(--muted); }
.save.saved::before { content: "\2713  "; color: var(--cyan); }
.save.failed, .save.refused { color: var(--amber); font-weight: 600; }
.save.failed .btn { margin-left: 4px; color: var(--text); }
.q[data-save=refused] input, .q[data-save=refused] textarea, .q[data-save=failed] input, .q[data-save=failed] textarea { border-color: var(--amber); }
.q[data-save=conflict] input, .q[data-save=conflict] textarea { border-color: var(--amber); }
.actions.tight { margin-top: 10px; gap: 10px; }
.prefill { margin-top: 8px; }
/* Both answers, when one was saved somewhere else (ruling B1): something to check, so amber. */
.choose { margin-top: 4px; padding: 12px 14px; border-radius: 12px; background: var(--amber-t); border-left: 4px solid var(--amber);
  color: var(--text); font-weight: 400; font-size: 15.5px; }
.choose-title { font-weight: 700; color: var(--amber); }
.choose p + p { margin-top: 6px; }
.choose [data-theirs], .choose [data-mine] { overflow-wrap: anywhere; }
/* Asked before signing out with unsaved typing (ruling M2): about the person, so the notice look. */
.ask { border-left-color: var(--amber); }

/* tables */
.colheads { display: none; }
.rows { display: grid; gap: 12px; margin-top: 12px; }
.row { border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px 14px; background: var(--bg2); }
.row legend { font-size: 14px; padding: 0 4px; }
.cells { display: grid; gap: 4px 12px; }
.field { display: block; margin-top: 8px; }
.field .label { margin: 0 0 6px; }
.row .remove { margin-top: 12px; }
.table > .btn { margin-top: 12px; }

/* 1.5 revenue: a card per year */
.years { display: grid; gap: 14px; margin-top: 14px; }
.year { border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px 16px; background: var(--bg2); }
.year legend { font-weight: 700; padding: 0 4px; }
.q.cell { background: transparent; border: 0; padding: 0; margin-top: 8px; }
.q.cell .label { margin: 4px 0 6px; }
.q.cell .save { min-height: 18px; margin-top: 2px; font-size: 13.5px; }
.total { margin-top: 8px; padding: 10px 12px; border-radius: 12px; background: var(--cyan-t); }
.total .label { margin: 0; color: var(--text); font-weight: 600; }
.total-note { margin-top: 10px; }
.total output { display: block; font-size: 20px; font-weight: 700; min-height: 28px; }

/* review */
.missing { background: var(--amber-t); border-left: 4px solid var(--amber); border-radius: 14px; padding: 16px 18px; margin: 18px 0; }
.missing h2 { margin-top: 0; }
.missing ul { list-style: none; display: grid; gap: 4px; margin-top: 10px; }
.missing a { display: flex; gap: 10px; align-items: baseline; min-height: 44px; padding: 10px 0; color: var(--text); text-decoration: underline;
  text-underline-offset: 3px; overflow-wrap: anywhere; }
.missing a .tag { text-decoration: none; }
/* A page's own "unfinished here" line (way A; job S9): about the person's own progress, so the notice look, never amber. */
.left-here { background: rgba(255,255,255,.06); border-left: 4px solid var(--muted); border-radius: 12px; padding: 12px 16px; margin: 14px 0; }
.left-here-title { font-weight: 600; }
.left-here ul { list-style: none; display: grid; gap: 2px; margin-top: 6px; }
.left-here a { display: flex; gap: 10px; align-items: baseline; min-height: 44px; padding: 10px 0; color: var(--text); text-decoration: underline;
  text-underline-offset: 3px; overflow-wrap: anywhere; }
.left-here a .tag { text-decoration: none; }
.pdf { margin-top: 22px; }
.pdf-bar { position: sticky; top: 69px; z-index: 5; display: flex; flex-wrap: wrap; gap: 8px; padding: 10px 0; background: var(--bg); }
.pdf-pages { overflow: auto; -webkit-overflow-scrolling: touch; border-radius: 12px; background: #2A2A3A; padding: 8px 0; max-width: 100%; }
.pdf-page { margin: 0 auto 12px; width: max-content; padding: 0 1px; }
.pdf-page canvas { display: block; background: #fff; box-shadow: 0 6px 24px -8px rgba(0,0,0,.6); }
.pdf-page figcaption { text-align: center; font-size: 13.5px; padding-top: 6px; }

/* sign */
.carrier-notice { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; margin: 16px 0; }
.carrier-notice h2 { font-size: 20px; margin-top: 0; }
form.sign, .linkform { margin-top: 18px; max-width: 520px; }
.other-signer { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line); }
/* Job S12: the road to changing an answer while a signature is awaited. Ruled off from the main action, as the other
   quiet way on (someone else will sign) is; the sentence, then the control it names. */
.change-road { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line); }
.change-road p { margin: 0; }
.change-road .error { margin-top: 10px; }
.change-road .actions { margin-top: 14px; }
/* On the wait for a named signer the sentence stands alone above the controls that were there: nearer to them than
   to the lines above it, so it reads as theirs. */
.wrap > .change-note { margin-top: 22px; }
.change-note + .actions { margin-top: 14px; }
/* Job S13: what the cancel costs a signature already made (Herald's waiting.cancel.note and its named form). Part of
   the cancel control: close under the road's sentence, the control close under it. Calm: the page's own text colour
   where the sentence above it is muted, so it is read before the press, and no ground, rule or mark of its own.
   Where the refusal line stands in for the road's sentence (the wait for a named signer), it takes that sentence's
   place above the controls. The two rules after it come later on purpose: they must win at equal weight.
   Its lines are balanced where the browser can (seen on an iPad: the last line was two words, "won't count."). */
.cancel-note { max-width: 62ch; text-wrap: balance; }
.wrap > .cancel-note { margin-top: 22px; }
.change-road .cancel-note, .change-note + .cancel-note { margin-top: 8px; }
.cancel-note + .actions { margin-top: 14px; }
/* A notice that opens with a title (welcome back): the title on its own line. */
.notice .notice-title { display: block; font-weight: 600; }
.linkform .btn { margin-top: 16px; }

/* the stand-in signer page (tests and local runs only) keeps working on this sheet */
label { display: block; }
main > form#f input { margin-bottom: 12px; }
main > form#f button { min-height: var(--touch); padding: 12px 24px; border-radius: 999px; border: 0; background: var(--cyan); color: var(--ink); font-weight: 700; }

/* iPad and wider */
@media (min-width: 700px) {
  .wrap { padding-top: 40px; }
  .q, .group { padding: 22px 24px; }
  .years { grid-template-columns: repeat(3, 1fr); }
  .cells { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
  .page-actions .btn:last-child { flex: 0 0 auto; min-width: 200px; }
}
@media (min-width: 1100px) {
  .wrap { width: min(820px, 100% - 64px); }
}

/* job S7: words the team typed (a question, a reopen's reason), drawn as typed, line breaks kept */
.typed { white-space: pre-wrap; overflow-wrap: anywhere; font-weight: 600; margin: 8px 0 12px; }
.reply .actions { margin-top: 14px; }
.reply .muted { margin-top: 8px; }
.btn[aria-disabled="true"] { opacity: .45; cursor: default; box-shadow: none; }
/* the team's question and the reopened block sit inside the page's column, aligned with the home line above them */
.wrap .question-block, .wrap .reopened, .wrap .hold { width: auto; margin: 18px 0 0; }
.question-block { border-left-color: var(--cyan); }

/* Job S10: Herald's explanation behind a small "i" (Chris's note 1, Aaron's ruling 1). The button is the touch floor;
   the drawn circle is small. The box opens under the answer box, in the quiet card tint: not an action (cyan), not
   something to check (amber), not a mark of whose words these are. */
.info { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; margin: -10px -10px -10px auto;
  padding: 0; border: 0; border-radius: 999px; background: transparent; color: var(--muted); cursor: pointer; }
.info:hover, .info[aria-expanded=true] { color: var(--cyan); }
.info-icon { display: block; }
.lhead { display: flex; align-items: flex-start; gap: 8px; }
.lhead > .label { flex: 1 1 auto; min-width: 0; }
.lhead .info { margin: -2px -10px 0 auto; }
.qhead + .lhead > .label { margin-top: 12px; }
.lhead + input, .lhead + textarea, .lhead + .affix input, .lhead + .yesno { margin-top: 0; }
.info-box { margin-top: 12px; padding: 12px 14px; border-radius: 12px; background: rgba(255,255,255,.05); border: 1px solid var(--line);
  color: #D6D4E6; font-size: 15.5px; line-height: 1.5; }
.info-box:focus { outline: none; }
.info-box:focus-visible { outline: 3px solid var(--cyan); outline-offset: 2px; }
.info-box .btn { margin-top: 10px; }
.section-intro { color: #D6D4E6; margin: -4px 0 10px; max-width: 60ch; }
/* Job S10 (Chris's note 6): the rest of the application, on a page review sent the person to. */
.elsewhere.under { margin-top: 6px; padding-top: 10px; border-top: 1px solid var(--line); }
.elsewhere > .btn { margin-bottom: 6px; }
.elsewhere ul { list-style: none; display: grid; gap: 2px; margin-top: 6px; }
.elsewhere a { display: flex; gap: 10px; align-items: baseline; min-height: 44px; padding: 10px 0; color: var(--text); text-decoration: underline;
  text-underline-offset: 3px; overflow-wrap: anywhere; }
.elsewhere a .tag { text-decoration: none; }
.pdf-show { margin-top: 22px; }

/* Job S11: a list to choose from (the state, job K21) looks like the other boxes: our own ground and border, a small
   arrow drawn here (the content policy allows no outside image), and a dark list where the browser draws its own. */
select { -webkit-appearance: none; appearance: none; color-scheme: dark; padding-right: 44px; cursor: pointer; text-overflow: ellipsis;
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: right 21px top 50%, right 15px top 50%; background-size: 6px 6px; background-repeat: no-repeat; }

/* Job S11: the boxes of one answer (the address, job K21) stand as one group under the insurer's label: closer together
   than separate questions, and from iPad width the city, state and ZIP code share a line, as an address is written.
   On a phone each box keeps the full width (a state's name and a save line both need it). */
.boxes { margin-top: 16px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 0 12px; }
.boxes > .label { grid-column: 1 / -1; margin: 0 0 2px; }
.boxes > .q { background: transparent; border: 0; padding: 0; margin-top: 8px; grid-column: 1 / -1; }
.boxes > .q .label { margin-top: 0; font-size: 14.5px; color: var(--muted); }
.boxes > .q .save { min-height: 18px; margin-top: 4px; font-size: 13.5px; }
@media (min-width: 700px) {
  .boxes { grid-template-columns: minmax(0, 2fr) minmax(0, 1.5fr) minmax(0, 1fr); }
  .boxes > .q[data-box="address.city"] { grid-column: 1; }
  .boxes > .q[data-box="address.state"] { grid-column: 2; }
  .boxes > .q[data-box="address.zip"] { grid-column: 3; }
}

/* Job S11: the one-tap answer (job K21). The tap sits under the answer box, a quiet button of its own line. Once
   tapped, the stated answer stands where the box was, in the box's own ground, with Undo beside it (under it on a
   phone when the line is long): it reads as the answer given, not as a notice. */
.q > [data-offer] { margin-top: 12px; }
.offer-done { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; margin-top: 12px;
  padding: 12px 14px; border-radius: 12px; background: var(--field); border: 1.5px solid rgba(255,255,255,.14); }
.offer-done p { flex: 1 1 260px; min-width: 0; }
.offer-done .btn { flex: none; }
