@layer layout {
  .hero {
    padding-block: clamp(48px, 6.5vw, 88px) clamp(52px, 6.5vw, 88px);
  }

  @media (min-width: 981px) {
    .hero {
      min-height: min(calc(100svh - 77px), 920px);
      display: flex;
      align-items: center;
    }
  }

  .hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 0.86fr) minmax(0, 1.14fr);
    gap: clamp(28px, 3.8vw, 60px);
    align-items: center;
  }

  .hero-grid > *,
  .section-intro > *,
  .scope-meta > *,
  .proof-header > *,
  .proof-showcase > *,
  .deliverable-stack > *,
  .deliverable-visuals > *,
  .specimen-thumbs > *,
  .intake-grid > *,
  .form-row-2 > *,
  .audience-grid > *,
  .audience-row > *,
  .faq-grid > *,
  .sample-detail > *,
  .job-meta-row > * {
    min-width: 0;
  }

  .hero h1 {
    font-size: clamp(2.45rem, 4.6vw, 4rem);
    line-height: 1.03;
    font-weight: 850;
    letter-spacing: -0.04em;
    max-width: 15ch;
    margin-bottom: clamp(18px, 2.2vw, 26px);
  }

  .hero-copy {
    font-size: clamp(1.0625rem, 1.45vw, 1.25rem);
    line-height: 1.56;
    color: var(--text);
    max-width: 54ch;
    margin-bottom: 28px;
  }

  .actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px 16px;
  }

  /* Interactive hero finding specimen */
  .hero-specimen {
    background: var(--paper);
    border: 1px solid var(--line);
    box-shadow: 0 18px 40px rgba(19, 37, 48, 0.08);
  }

  .specimen-topbar {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: baseline;
    gap: 8px 16px;
    padding: 14px 20px;
    border-bottom: 1px solid var(--line);
    background: var(--surface-subtle);
  }

  .specimen-brand {
    font-size: 0.9375rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--brand);
  }

  .specimen-brand-tld {
    color: var(--muted);
    font-weight: 600;
  }

  .specimen-context {
    font-size: 0.875rem;
    color: var(--muted);
  }

  .specimen-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 20px;
    padding-inline: 20px;
    border-bottom: 1px solid var(--line);
    background: var(--paper);
  }

  .specimen-tabs [role="tab"] {
    position: relative;
    border: 0;
    border-bottom: 2px solid transparent;
    background: none;
    padding: 11px 0;
    margin-bottom: -1px;
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--muted);
    cursor: pointer;
    transition: color 0.15s ease, border-color 0.15s ease;
  }

  .specimen-tabs [role="tab"]:hover {
    color: var(--ink);
  }

  .specimen-tabs [role="tab"][aria-selected="true"] {
    color: var(--brand);
    border-bottom-color: var(--brand);
  }

  .specimen-body {
    padding: 20px;
    min-height: 348px;
  }

  .specimen-title {
    font-size: 1.0625rem;
    font-weight: 800;
    letter-spacing: -0.015em;
    color: var(--ink);
    margin-bottom: 12px;
  }

  .specimen-meta {
    margin: 0 0 14px;
    display: grid;
    gap: 6px;
    border-top: 1px solid var(--line);
    padding-top: 10px;
  }

  .specimen-meta div {
    display: grid;
    grid-template-columns: 92px minmax(0, 1fr);
    gap: 10px;
    font-size: 0.875rem;
    line-height: 1.4;
  }

  .specimen-meta dt {
    color: var(--muted);
    font-weight: 600;
  }

  .specimen-meta dd {
    margin: 0;
    color: var(--ink);
  }

  .status-exception {
    font-weight: 700;
    color: var(--error);
  }

  .status-decision {
    font-weight: 700;
    color: var(--action);
  }

  .status-pass {
    font-weight: 700;
    color: var(--brand);
  }

  .specimen-table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin-bottom: 14px;
  }

  .specimen-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
    line-height: 1.35;
    font-variant-numeric: tabular-nums;
  }

  .specimen-table th,
  .specimen-table td {
    padding: 7px 4px;
    text-align: left;
    border-bottom: 1px solid var(--line);
  }

  .specimen-table thead th {
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--muted);
    border-bottom: 1px solid var(--line-strong);
    white-space: nowrap;
  }

  .specimen-table th:not(:first-child),
  .specimen-table td.num {
    text-align: right;
    white-space: nowrap;
  }

  .specimen-table td.num {
    font-family: var(--font-mono);
    font-size: 0.875rem;
  }

  .specimen-callout,
  .specimen-formula {
    padding: 12px 14px;
    background: var(--surface-subtle);
    border: 1px solid var(--line);
    font-size: 0.9375rem;
    line-height: 1.5;
    color: var(--ink);
    margin-bottom: 14px;
  }

  .specimen-formula code {
    font-family: var(--font-mono);
    font-size: 0.875rem;
    overflow-wrap: anywhere;
  }

  .specimen-foot {
    padding-top: 10px;
    border-top: 1px solid var(--line);
    display: grid;
    gap: 4px;
    font-size: 0.875rem;
    line-height: 1.45;
    color: var(--text);
  }

  .specimen-foot p {
    margin: 0;
  }

  /* What we check, and what stays with you */
  .capabilities {
    border-top: 1px solid var(--line);
    padding-block: clamp(64px, 7.5vw, 108px);
  }

  .section-intro {
    display: grid;
    grid-template-columns: minmax(0, 0.78fr) minmax(0, 1.22fr);
    gap: clamp(20px, 4vw, 64px);
    align-items: end;
    margin-bottom: clamp(32px, 4vw, 48px);
  }

  .section-intro h2,
  .intake-intro h2,
  .audience-intro h2,
  .faq-intro h2 {
    font-size: clamp(2rem, 3.5vw, 3rem);
    line-height: 1.07;
    font-weight: 800;
    letter-spacing: -0.035em;
    margin-bottom: 0;
  }

  .section-intro p {
    font-size: clamp(1rem, 1.25vw, 1.125rem);
    line-height: 1.6;
    color: var(--text);
    max-width: 62ch;
    margin-bottom: 0;
  }

  .scope-table {
    width: 100%;
    border-collapse: collapse;
    border-top: 1px solid var(--line-strong);
  }

  .scope-table thead th {
    padding: 12px 18px 12px 0;
    text-align: left;
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--muted);
    border-bottom: 1px solid var(--line-strong);
  }

  .scope-table tbody tr {
    border-bottom: 1px solid var(--line);
  }

  .scope-table tbody th,
  .scope-table tbody td {
    padding: 22px 24px 22px 0;
    text-align: left;
    vertical-align: top;
    font-size: 1rem;
    line-height: 1.58;
  }

  .scope-table tbody th {
    width: 22%;
    color: var(--ink);
  }

  .stage-num {
    display: block;
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--brand);
    margin-bottom: 2px;
  }

  .stage-name {
    display: block;
    font-size: 1.125rem;
    font-weight: 800;
    letter-spacing: -0.015em;
    color: var(--ink);
    line-height: 1.25;
  }

  .scope-table tbody td:first-of-type {
    width: 50%;
    color: var(--text);
  }

  .scope-table tbody td:last-of-type {
    width: 28%;
    padding-inline-end: 0;
    color: var(--ink);
  }

  .check-grid {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px 24px;
  }

  .check-grid li {
    position: relative;
    padding-inline-start: 14px;
    font-size: 0.9375rem;
    line-height: 1.45;
    color: var(--text);
  }

  .check-grid li::before {
    content: "";
    position: absolute;
    inset-inline-start: 0;
    top: 0.52em;
    width: 5px;
    height: 5px;
    background: var(--brand);
  }

  .scope-meta {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(20px, 3vw, 44px);
    padding-top: 28px;
    margin-top: 4px;
  }

  .scope-meta h3 {
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--ink);
    margin-bottom: 6px;
  }

  .scope-meta p {
    font-size: 0.9375rem;
    line-height: 1.55;
    color: var(--text);
    margin: 0;
  }

  /* What comes back (Dark band) */
  .proof-band {
    background: var(--surface-dark);
    color: #ffffff;
    padding-block: clamp(64px, 8vw, 108px);
  }

  .proof-band h2,
  .proof-band h3 {
    color: #ffffff;
  }

  .proof-header {
    display: grid;
    grid-template-columns: minmax(0, 0.62fr) minmax(0, 1.38fr);
    gap: clamp(20px, 4vw, 60px);
    align-items: end;
    margin-bottom: clamp(32px, 4vw, 52px);
  }

  .proof-header h2 {
    font-size: clamp(2rem, 3.5vw, 3rem);
    line-height: 1.07;
    font-weight: 800;
    letter-spacing: -0.035em;
    margin-bottom: 0;
  }

  .proof-header p {
    color: #d6e1e7;
    font-size: clamp(1rem, 1.25vw, 1.125rem);
    line-height: 1.58;
    max-width: 60ch;
    margin-bottom: 0;
  }

  .proof-showcase {
    display: grid;
    grid-template-columns: minmax(0, 0.62fr) minmax(0, 1.38fr);
    gap: clamp(28px, 4vw, 48px);
    align-items: start;
  }

  .deliverable-stack {
    display: grid;
    gap: 0;
    border-top: 1px solid #2d4756;
  }

  .deliverable-item {
    padding-block: 22px;
    border-bottom: 1px solid #2d4756;
  }

  .deliverable-item h3 {
    font-size: 1.125rem;
    font-weight: 700;
    letter-spacing: -0.015em;
    margin-bottom: 8px;
    color: #ffffff;
  }

  .deliverable-item p {
    font-size: 0.9375rem;
    line-height: 1.58;
    color: #d0dde4;
    margin-bottom: 0;
  }

  .proof-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 22px;
    margin-top: 14px;
  }

  .proof-band a {
    color: #ffffff;
    font-weight: 700;
    font-size: 0.9375rem;
  }

  .proof-band a:hover {
    color: #dce9f0;
  }

  .proof-band .fn-ref {
    display: inline-block;
    margin-inline-start: 3px;
    padding-inline: 3px;
    font-size: 0.78em;
    font-weight: 700;
    line-height: 1;
    vertical-align: super;
    color: #a9d0e4;
    text-decoration: none;
  }

  .proof-band .fn-ref:hover {
    color: #ffffff;
    text-decoration: underline;
  }

  .deliverable-visuals {
    display: grid;
    gap: 20px;
  }

  .specimen-thumbs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
  }

  .thumb-link {
    display: block;
    border: 1px solid #2b4757;
    background: var(--paper);
  }

  .thumb-link img {
    width: 100%;
    height: auto;
  }

  /* Intake section (Condensed 2-column) */
  .intake-section {
    background: var(--surface-subtle);
    border-block: 1px solid var(--line);
    padding-block: clamp(64px, 7.5vw, 108px);
  }

  .intake-grid {
    display: grid;
    grid-template-columns: minmax(240px, 0.78fr) minmax(0, 1.22fr);
    gap: clamp(32px, 5vw, 68px);
    align-items: start;
  }

  .intake-intro {
    position: sticky;
    top: 100px;
  }

  .intake-intro .intro {
    margin-top: 18px;
    font-size: 1.0625rem;
    line-height: 1.58;
    color: var(--text);
    max-width: 44ch;
  }

  .intake-checklist {
    list-style: none;
    padding: 20px 0 0;
    margin: 22px 0 0;
    border-top: 1px solid var(--line);
    display: grid;
    gap: 10px;
  }

  .intake-checklist li {
    position: relative;
    padding-inline-start: 24px;
    font-size: 0.9375rem;
    line-height: 1.5;
    color: var(--ink);
  }

  .intake-checklist li::before {
    content: "";
    position: absolute;
    inset-inline-start: 0;
    top: 0.35em;
    width: 14px;
    height: 12px;
    background-color: var(--brand);
    clip-path: polygon(14% 44%, 0 60%, 42% 100%, 100% 18%, 85% 4%, 40% 72%);
  }

  .intake-privacy-note {
    margin: 22px 0 0;
    padding-top: 20px;
    border-top: 1px solid var(--line);
    font-size: 0.9375rem;
    line-height: 1.58;
    color: var(--text);
    max-width: 46ch;
  }

  .intake-privacy-note a {
    font-weight: 700;
  }

  .intake-card {
    background: var(--paper);
    border: 1px solid var(--line);
    padding: clamp(20px, 3vw, 32px);
  }

  .form-row-2 {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
  }

  /* Built for (3-row editorial strip) */
  .audience-section {
    padding-block: clamp(56px, 6.5vw, 84px);
    border-bottom: 1px solid var(--line);
  }

  .audience-grid {
    display: grid;
    grid-template-columns: minmax(220px, 0.72fr) minmax(0, 1.28fr);
    gap: clamp(28px, 5vw, 68px);
    align-items: start;
  }

  .audience-rows {
    margin: 0;
    border-top: 1px solid var(--line);
  }

  .audience-row {
    display: grid;
    grid-template-columns: minmax(0, 13rem) minmax(0, 1fr);
    gap: 8px 28px;
    align-items: baseline;
    padding-block: 20px;
    border-bottom: 1px solid var(--line);
  }

  .audience-row dt {
    font-size: 1.0625rem;
    font-weight: 700;
    line-height: 1.4;
    color: var(--ink);
  }

  .audience-row dd {
    margin: 0;
    font-size: 1rem;
    line-height: 1.6;
    color: var(--text);
    max-width: 58ch;
  }

  /* Questions / FAQ */
  .faq-section {
    padding-block: clamp(64px, 7.5vw, 100px);
  }

  .faq-grid {
    display: grid;
    grid-template-columns: minmax(220px, 0.72fr) minmax(0, 1.28fr);
    gap: clamp(28px, 5vw, 68px);
    align-items: start;
  }

  /* Apple-style numbered footnotes above footer */
  .site-notes {
    border-top: 1px solid var(--line);
    background: var(--surface-subtle);
    padding-block: 24px;
  }

  .site-notes-inner {
    font-size: 0.875rem;
    line-height: 1.55;
    color: var(--muted);
  }

  .site-footnotes {
    margin: 0;
    padding-inline-start: 20px;
    max-width: 82ch;
    display: grid;
    gap: 8px;
  }

  .fn-back {
    margin-inline-start: 8px;
    font-weight: 700;
    color: var(--action);
  }

  /* Prose, sample & private job pages */
  .prose-page {
    padding-block: clamp(48px, 7vw, 92px);
  }

  .prose-column {
    max-width: 70ch;
  }

  .prose-page h1,
  .job-page h1,
  .sample-page h1 {
    font-size: clamp(2.15rem, 4.2vw, 3.35rem);
    line-height: 1.06;
    font-weight: 850;
    letter-spacing: -0.035em;
    margin-bottom: 18px;
  }

  .prose-page .intro,
  .job-page .intro,
  .sample-page .intro {
    font-size: clamp(1.0625rem, 1.45vw, 1.25rem);
    line-height: 1.55;
    color: var(--text);
    max-width: 62ch;
    margin-bottom: 28px;
  }

  .prose-column h2 {
    font-size: clamp(1.3125rem, 2vw, 1.625rem);
    line-height: 1.22;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin: 40px 0 12px;
    padding-top: 24px;
    border-top: 1px solid var(--line);
  }

  .prose-column p {
    margin-bottom: 14px;
    line-height: 1.65;
  }

  .prose-column ul {
    margin: 0 0 18px;
    padding-inline-start: 20px;
  }

  .prose-column li {
    margin-bottom: 8px;
    line-height: 1.6;
  }

  .version-note {
    margin-top: 36px;
    padding-top: 18px;
    border-top: 1px solid var(--line);
    font-size: 0.875rem;
    color: var(--muted);
  }

  .job-page {
    padding-block: clamp(48px, 7vw, 88px);
    min-height: 68vh;
  }

  .job-column {
    max-width: 820px;
  }

  .sample-page {
    padding-block: clamp(48px, 7vw, 92px);
  }

  .sample-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 14px 24px;
    margin-bottom: 40px;
  }

  .sample-detail {
    display: grid;
    grid-template-columns: minmax(250px, 0.68fr) minmax(0, 1.32fr);
    gap: clamp(28px, 4.5vw, 56px);
    align-items: start;
    padding-block: clamp(40px, 5vw, 60px);
    border-top: 1px solid var(--line);
  }

  .sample-detail h2 {
    font-size: clamp(1.4375rem, 2.4vw, 2rem);
    line-height: 1.15;
    font-weight: 800;
    letter-spacing: -0.025em;
    margin-bottom: 14px;
  }

  .sample-detail p {
    margin-bottom: 12px;
    line-height: 1.6;
  }

  .sample-detail figure {
    margin: 0;
  }

  .sample-detail figure img {
    width: 100%;
    border: 1px solid var(--line);
    background: var(--paper);
  }

  .sample-detail figure figcaption {
    margin-top: 10px;
    font-size: 0.875rem;
    line-height: 1.5;
    color: var(--muted);
  }

  .sample-disclosure {
    margin-top: 36px;
    padding-top: 20px;
    border-top: 1px solid var(--line);
    font-size: 0.875rem;
    line-height: 1.55;
    color: var(--muted);
    max-width: 72ch;
  }

  @media (max-width: 980px) {
    .hero-grid,
    .section-intro,
    .proof-header,
    .proof-showcase,
    .intake-grid,
    .audience-grid,
    .faq-grid,
    .sample-detail {
      grid-template-columns: minmax(0, 1fr);
    }

    .specimen-body {
      min-height: 0;
    }

    .scope-meta {
      grid-template-columns: minmax(0, 1fr);
      gap: 18px;
    }

    .intake-intro {
      position: static;
    }
  }

  @media (max-width: 780px) {
    .scope-table thead {
      display: none;
    }

    .scope-table tbody,
    .scope-table tr,
    .scope-table th,
    .scope-table td {
      display: block;
      width: 100% !important;
      padding-inline: 0;
    }

    .scope-table tr {
      padding-block: 18px;
    }

    .scope-table tbody th,
    .scope-table tbody td {
      padding-block: 0;
    }

    .scope-table tbody td {
      margin-top: 10px;
    }

    .scope-table tbody td::before {
      content: attr(data-label);
      display: block;
      font-size: 0.875rem;
      font-weight: 700;
      color: var(--muted);
      margin-bottom: 2px;
    }
  }

  @media (max-width: 680px) {
    .check-grid {
      grid-template-columns: minmax(0, 1fr);
      gap: 6px;
    }

    .form-row-2 {
      grid-template-columns: minmax(0, 1fr);
    }

    .specimen-thumbs {
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 10px;
    }

    .specimen-meta div {
      grid-template-columns: minmax(0, 1fr);
      gap: 2px;
    }
  }
}

@layer components {
  .button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 50px;
    padding: 12px 18px;
    background: var(--brand);
    border: 1.5px solid var(--brand);
    border-radius: 0;
    color: #ffffff;
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.25;
    text-decoration: none;
    cursor: pointer;
  }

  .button:hover:not(:disabled) {
    background: var(--brand-hover);
    border-color: var(--brand-hover);
    color: #ffffff;
  }

  .button:active:not(:disabled) {
    background: var(--ink);
    border-color: var(--ink);
    color: #ffffff;
  }

  .button:disabled {
    opacity: 0.52;
    cursor: not-allowed;
  }

  .button.secondary {
    background: var(--paper);
    color: var(--ink);
    border-color: var(--line-strong);
  }

  .button.secondary:hover:not(:disabled) {
    background: var(--surface-subtle);
    border-color: var(--ink);
    color: var(--ink);
  }

  .button.secondary[aria-pressed="true"] {
    background: var(--ink);
    border-color: var(--ink);
    color: #ffffff;
  }

  .text-link {
    font-weight: 700;
    font-size: 0.96875rem;
    color: var(--action);
    text-underline-offset: 0.22em;
  }

  .text-button {
    border: 0;
    padding: 0;
    min-height: 28px;
    background: none;
    color: var(--action);
    font-weight: 700;
    font-size: 0.9375rem;
    text-decoration: underline;
    text-underline-offset: 0.2em;
    cursor: pointer;
  }

  .text-button:hover:not(:disabled) {
    color: var(--brand-hover);
    text-decoration-thickness: 2px;
  }

  .text-button:active:not(:disabled) {
    color: var(--ink);
  }

  .text-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
  }

  /* Workbook semantic spreadsheet preview */
  .workbook-preview {
    max-width: 100%;
    background: var(--paper);
    color: var(--text);
    border: 1px solid #2b4757;
    overflow: hidden;
  }

  .workbook-preview.light-ground {
    border-color: var(--line);
  }

  .workbook-topbar {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: baseline;
    gap: 8px 16px;
    padding: 13px 16px;
    border-bottom: 1px solid var(--line);
    background: var(--paper);
  }

  .workbook-title {
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--ink);
  }

  .workbook-subtitle {
    font-size: 0.875rem;
    color: var(--muted);
  }

  .workbook-scroll {
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .workbook-table {
    width: 100%;
    min-width: 640px;
    border-collapse: collapse;
    font-size: 0.875rem;
    line-height: 1.38;
    font-variant-numeric: tabular-nums;
  }

  .workbook-table th,
  .workbook-table td {
    padding: 8px 6px;
    text-align: left;
    vertical-align: top;
    border-bottom: 1px solid var(--line);
    border-inline-end: 1px solid #edf1f3;
  }

  .workbook-table tbody tr:hover {
    background: #f9fbfc;
  }

  .workbook-table th:last-child,
  .workbook-table td:last-child {
    border-inline-end: 0;
  }

  .workbook-table thead th {
    font-size: 0.8125rem;
    line-height: 1.25;
    font-weight: 700;
    color: var(--ink);
    background: var(--surface-subtle);
    border-bottom: 1px solid var(--line-strong);
  }

  .workbook-table thead th.col-ldr {
    color: var(--brand);
    background: #eef4f7;
  }

  .workbook-table thead th.col-validator {
    color: #ffffff;
    background: var(--action);
    border-inline-end-color: #206d91;
  }

  .workbook-table td.num {
    font-family: var(--font-mono);
    font-size: 0.875rem;
    white-space: nowrap;
  }

  .workbook-table td.cell-blank {
    background: #f7fafc;
    color: var(--muted);
    font-family: var(--font-mono);
    font-size: 0.875rem;
  }

  .workbook-table td .flag-exception {
    color: var(--error);
    font-weight: 700;
  }

  .workbook-table td .flag-decision {
    color: var(--action);
    font-weight: 700;
  }

  .workbook-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0;
    border-top: 1px solid var(--line);
    background: var(--surface-subtle);
    font-size: 0.875rem;
  }

  .workbook-tabs span {
    padding: 7px 11px;
    color: var(--muted);
    border-inline-end: 1px solid var(--line);
  }

  .workbook-tabs span.tab-active {
    background: var(--paper);
    color: var(--ink);
    font-weight: 700;
  }

  .workbook-legend {
    padding: 11px 16px;
    border-top: 1px solid var(--line);
    font-size: 0.875rem;
    line-height: 1.5;
    color: var(--muted);
    background: var(--paper);
  }

  /* Intake form and validation */
  .form {
    display: grid;
    gap: 18px;
    min-width: 0;
  }

  .intake-controls {
    border: 0;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 18px;
    min-width: 0;
  }

  .intake-controls:disabled {
    opacity: 0.72;
  }

  .field {
    display: grid;
    gap: 5px;
    min-width: 0;
    align-content: start;
  }

  .field label {
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--ink);
  }

  .field label .label-meta {
    font-weight: 400;
    font-size: 0.875rem;
    color: var(--muted);
    margin-inline-start: 6px;
  }

  .field-hint {
    display: block;
    font-size: 0.875rem;
    line-height: 1.45;
    color: var(--muted);
    margin-bottom: 2px;
  }

  .field input[type="text"],
  .field input[type="email"],
  .field textarea,
  .field select {
    width: 100%;
    min-height: 48px;
    padding: 10px 12px;
    border: 1.5px solid var(--line-strong);
    border-radius: 0;
    background: var(--paper);
    color: var(--ink);
    font: inherit;
    font-size: max(1rem, 1em);
  }

  .field textarea {
    min-height: 112px;
    resize: vertical;
  }

  .field :is(input[type="text"], input[type="email"], textarea, select):focus {
    outline: none;
    border-color: var(--action);
    box-shadow: inset 0 0 0 1px var(--action);
  }

  .field-error {
    display: none;
    color: var(--error);
    font-size: 0.875rem;
    font-weight: 600;
    line-height: 1.4;
    margin-top: 2px;
  }

  .field :is(:user-invalid, .user-invalid-fallback) {
    border-color: var(--error);
    background: #fdf6f3;
  }

  .field :is(:user-invalid, .user-invalid-fallback) + .field-error,
  .field-error.is-visible {
    display: block;
  }

  .email-suggestion {
    font-size: 0.875rem;
    color: var(--ink);
    padding-top: 4px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
  }

  /* Structured additive file slots (dashed interactive dropzones + popover limits) */
  .upload-fieldset {
    border: 0;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 0;
    min-width: 0;
  }

  .upload-fieldset-header {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: baseline;
    gap: 6px 14px;
    margin-bottom: 8px;
  }

  .upload-fieldset-title {
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--ink);
  }

  .limits-inline {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 10px;
  }

  .limits-summary {
    font-size: 0.875rem;
    color: var(--muted);
    font-variant-numeric: tabular-nums;
  }

  .info-trigger {
    border: 1px solid var(--line-strong);
    border-radius: 0;
    background: var(--paper);
    color: var(--ink);
    padding: 3px 9px;
    min-height: 28px;
    font-size: 0.875rem;
    font-weight: 700;
    line-height: 1.2;
    cursor: pointer;
    anchor-name: --limits-trigger;
  }

  .info-trigger:hover {
    border-color: var(--ink);
    background: var(--surface-subtle);
  }

  .limits-popover[popover] {
    margin: auto;
    max-width: min(440px, calc(100vw - 32px));
    padding: 18px 20px;
    background: var(--paper);
    color: var(--text);
    border: 1.5px solid var(--ink);
    box-shadow: 0 18px 42px rgba(19, 37, 48, 0.18);
    font-size: 0.9375rem;
    line-height: 1.55;
  }

  @supports (position-anchor: --limits-trigger) {
    .limits-popover[popover] {
      position-anchor: --limits-trigger;
      inset: auto;
      margin: 0;
      inset-block-start: anchor(bottom);
      inset-inline-end: anchor(right);
      margin-top: 8px;
      position-try-fallbacks: flip-block, flip-inline;
    }
  }

  .limits-popover::backdrop {
    background: rgba(19, 37, 48, 0.18);
  }

  .limits-popover-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 16px;
    margin-bottom: 10px;
    color: var(--ink);
  }

  .limits-popover p {
    margin: 0 0 8px;
  }

  .limits-popover p:last-child {
    margin-bottom: 0;
  }

  .upload-slot {
    padding-block: 14px;
    border-top: 1px solid var(--line);
    display: grid;
    gap: 7px;
  }

  .upload-slot:last-of-type {
    border-bottom: 1px solid var(--line);
  }

  .upload-slot-header {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: baseline;
    gap: 6px 14px;
  }

  .upload-slot-title {
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--ink);
  }

  .upload-slot-tag {
    font-size: 0.875rem;
    color: var(--muted);
  }

  .upload-dropzone {
    width: 100%;
    min-height: 52px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 6px 16px;
    padding: 12px 16px;
    border: 1.5px dashed var(--line-strong);
    border-radius: 0;
    background: var(--paper);
    color: var(--ink);
    font: inherit;
    text-align: left;
    cursor: pointer;
    transition: background-color 0.15s ease, border-color 0.15s ease;
  }

  .upload-dropzone:hover:not(:disabled) {
    border-color: var(--ink);
    background: #eef3f5;
  }

  .upload-dropzone.is-dragover {
    border-style: solid;
    border-color: var(--action);
    background: #e6f0f5;
  }

  .upload-dropzone.is-invalid {
    border-style: solid;
    border-color: var(--error);
    background: #fdf6f3;
  }

  .upload-dropzone:disabled {
    opacity: 0.6;
    cursor: not-allowed;
  }

  .upload-action {
    color: var(--action);
    font-size: 0.9375rem;
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 0.2em;
  }

  .upload-dropzone:hover:not(:disabled) .upload-action {
    color: var(--brand-hover);
  }

  .upload-drop-note {
    font-size: 0.875rem;
    color: var(--muted);
  }

  .file-list {
    display: grid;
    gap: 0;
  }

  .file-entry {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 12px;
    padding-block: 8px;
    border-top: 1px solid var(--line);
    font-size: 0.9375rem;
  }

  .file-entry:first-child {
    border-top: 0;
  }

  .file-details {
    display: grid;
    gap: 2px;
    min-width: 0;
    overflow-wrap: anywhere;
  }

  .file-name {
    color: var(--ink);
    font-weight: 600;
    font-variant-numeric: tabular-nums;
  }

  .file-state {
    font-size: 0.875rem;
    color: var(--muted);
    font-variant-numeric: tabular-nums;
  }

  .processing-terms {
    min-width: 0;
    margin: 0;
    padding: 14px 0 0;
    border: 0;
    display: grid;
    gap: 12px;
  }

  .terms-accept {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    font-size: 0.9375rem;
    line-height: 1.5;
    font-weight: 600;
    color: var(--ink);
    cursor: pointer;
  }

  .terms-accept input[type="checkbox"] {
    flex: 0 0 20px;
    width: 20px;
    height: 20px;
    margin: 2px 0 0;
    accent-color: var(--brand);
    cursor: pointer;
  }

  .terms-accept > span {
    min-width: 0;
    overflow-wrap: anywhere;
  }

  /* Unboxed status and error lines (zero left-accent borders, zero cards) */
  .availability-status,
  .notice,
  .error {
    margin: 0;
    padding-block: 12px;
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    font-size: 0.9375rem;
    line-height: 1.55;
  }

  .availability-status,
  .notice {
    color: var(--ink);
  }

  .error {
    color: var(--error);
    border-color: #d9b2a4;
    font-weight: 600;
  }

  .upload-state {
    display: grid;
    gap: 10px;
    padding-block: 16px;
    border-top: 1px solid var(--line-strong);
    border-bottom: 1px solid var(--line);
    font-variant-numeric: tabular-nums;
  }

  .upload-step {
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--ink);
  }

  .upload-state progress,
  .job-progress {
    width: 100%;
    height: 10px;
    accent-color: var(--brand);
  }

  .upload-label {
    font-size: 0.875rem;
    color: var(--muted);
  }

  .created-job {
    display: grid;
    gap: 8px;
    padding-block: 16px;
    border-top: 1px solid var(--error);
    border-bottom: 1px solid var(--line);
    overflow-wrap: anywhere;
  }

  .created-job p {
    margin: 0;
    font-size: 0.9375rem;
    line-height: 1.55;
  }

  .recovery-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px 20px;
    margin-top: 4px;
  }

  @supports not (accent-color: var(--brand)) {
    .terms-accept input[type="checkbox"] {
      appearance: none;
      border: 1.5px solid var(--line-strong);
      background: var(--paper);
      position: relative;
    }

    .terms-accept input[type="checkbox"]:checked {
      background: var(--brand);
      border-color: var(--brand);
    }

    .terms-accept input[type="checkbox"]:checked::after {
      content: "";
      position: absolute;
      inset-inline-start: 5px;
      top: 2px;
      width: 5px;
      height: 10px;
      border: solid #ffffff;
      border-width: 0 2px 2px 0;
      transform: rotate(45deg);
    }

    progress {
      appearance: none;
      border: 0;
      background: var(--line);
    }

    progress::-webkit-progress-bar {
      background: var(--line);
    }

    progress::-webkit-progress-value {
      background: var(--brand);
    }

    progress::-moz-progress-bar {
      background: var(--brand);
    }
  }

  /* Questions Accordion (+ / - toggle, progressive slide animation) */
  .faq-list {
    border-top: 1px solid var(--line);
  }

  .faq-list details {
    border-bottom: 1px solid var(--line);
  }

  .faq-list summary {
    list-style: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding-block: 18px;
    font-size: 1.0625rem;
    font-weight: 700;
    color: var(--ink);
    cursor: pointer;
  }

  .faq-list summary::-webkit-details-marker {
    display: none;
  }

  .faq-list summary::after {
    content: "+";
    font-size: 1.25rem;
    font-weight: 400;
    line-height: 1;
    color: var(--brand);
    flex-shrink: 0;
  }

  .faq-list details[open] > summary::after {
    content: "-";
  }

  .faq-list details p {
    margin: 0 0 20px;
    color: var(--text);
    font-size: 1rem;
    line-height: 1.6;
    max-width: 64ch;
  }

  details::details-content {
    interpolate-size: allow-keywords;
    overflow: clip;
    contain: layout;
  }

  details:not([open])::details-content {
    block-size: 0;
  }

  /* Private job route */
  .job-summary {
    border-top: 1px solid var(--line-strong);
    padding-top: 24px;
    display: grid;
    gap: 20px;
  }

  .job-lead {
    font-size: 1.0625rem;
    line-height: 1.6;
    color: var(--text);
    margin: 0;
  }

  .job-meta {
    margin: 0;
    border-top: 1px solid var(--line);
  }

  .job-meta-row {
    display: grid;
    grid-template-columns: 160px minmax(0, 1fr);
    gap: 8px 24px;
    padding-block: 11px;
    border-bottom: 1px solid var(--line);
    font-size: 0.9375rem;
  }

  .job-meta-row dt {
    font-weight: 700;
    color: var(--muted);
  }

  .job-meta-row dd {
    margin: 0;
    color: var(--ink);
    overflow-wrap: anywhere;
  }

  .job-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 18px;
    align-items: center;
  }

  .job-downloads {
    margin-top: 10px;
    border-top: 1px solid var(--line-strong);
  }

  .download-row {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 12px 24px;
    padding-block: 16px;
    border-bottom: 1px solid var(--line);
  }

  .download-info {
    display: grid;
    gap: 3px;
    min-width: 0;
  }

  .download-title {
    font-weight: 700;
    color: var(--ink);
    font-size: 1rem;
  }

  .download-desc {
    font-size: 0.875rem;
    color: var(--muted);
  }

  .job-guidance {
    margin: 0;
    padding-block: 14px;
    border-top: 1px solid var(--line);
    font-size: 0.96875rem;
    line-height: 1.6;
    color: var(--text);
  }

  .requested-list {
    margin: 8px 0 16px;
    padding-inline-start: 20px;
  }

  .feedback-section {
    margin-top: 48px;
    padding-top: 32px;
    border-top: 1px solid var(--line);
  }

  .feedback-section h2 {
    font-size: 1.375rem;
    font-weight: 800;
    margin-bottom: 16px;
  }

  .feedback-status {
    margin-top: 14px;
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--ink);
  }

  .form-small {
    margin-top: 12px;
    font-size: 0.875rem;
    color: var(--muted);
  }

  /* Opt-in purposeful motion only when motion is preferred */
  @media (prefers-reduced-motion: no-preference) {
    @keyframes specimen-in {
      from {
        opacity: 0;
        translate: 0 4px;
      }
      to {
        opacity: 1;
        translate: 0 0;
      }
    }

    .specimen-panel:not([hidden]) {
      animation: specimen-in 0.18s ease-out;
    }

    .thumb-link {
      transition: transform 0.18s ease, border-color 0.18s ease;
    }

    .thumb-link:hover {
      transform: translateY(-2px);
      border-color: #7ea3b8;
    }

    .file-entry {
      transition: opacity 0.2s ease, translate 0.2s ease;
      @starting-style {
        opacity: 0;
        translate: 0 -4px;
      }
    }

    details::details-content {
      transition: block-size 0.28s ease-in-out, content-visibility 0.28s ease-in-out, display 0.28s ease-in-out;
      transition-behavior: allow-discrete;
    }
  }

  @media (pointer: coarse) {
    .field input[type="text"],
    .field input[type="email"],
    .field textarea,
    .field select {
      min-height: 52px;
    }
  }

  @media (max-width: 680px) {
    .audience-row {
      grid-template-columns: minmax(0, 1fr);
      gap: 6px;
      padding-block: 16px;
    }

    .job-meta-row {
      grid-template-columns: minmax(0, 1fr);
      gap: 4px;
    }

    .download-row {
      flex-direction: column;
      align-items: flex-start;
    }

    .download-row .button {
      width: 100%;
    }
  }
}
