/* Shared Rulefinch brand refinements and the homepage workflow story. */
.home {
  --max: 1200px;
  --scene: oklch(24% 0.028 162);
  --scene-line: oklch(43% 0.025 160);
  --scene-muted: oklch(80% 0.018 140);
  --paper: oklch(98% 0.006 120);
  --warm-note: oklch(84% 0.09 78);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}
.home h1, .home h2, .home h3 { text-wrap: balance; }
.home h2 { font-size: clamp(1.9rem, 3.5vw, 2.75rem); line-height: 1.13; letter-spacing: -.04em; }
.home h3 { letter-spacing: -.025em; }
.home p { text-wrap: pretty; }
.home .site-header { background: var(--bg); backdrop-filter: none; border-bottom: 1px solid var(--line); }
.home .header-inner { min-height: 84px; }
.home .btn { min-height: 48px; border-radius: 8px; gap: 1.25rem; }
.home .btn-nav { min-height: 44px; }
.text-link { display: inline-flex; align-items: center; gap: 1.2rem; min-height: 44px; font-weight: 600; font-size: .9375rem; text-decoration: underline; text-underline-offset: 5px; text-decoration-color: var(--line); }
.text-link:hover { text-decoration-color: currentColor; }
.home-intro { padding: 4.5rem 0 3rem; }
.intro-grid { display: grid; grid-template-columns: 1.15fr 1fr; gap: 3rem; align-items: center; }
.intro-copy { min-width: 0; }
.intro-art { align-self: center; }
.intro-art img { width: 100%; height: auto; }
.home-intro h1 { margin: 0; font-size: clamp(2.4rem, 4.3vw, 4rem); line-height: 1.075; letter-spacing: -.055em; font-weight: 600; }
.home-intro h1 span { text-decoration: underline; text-decoration-color: var(--lime); text-decoration-thickness: .095em; text-underline-offset: .1em; }
.intro-support > p:first-child { color: var(--muted); font-size: 1.125rem; line-height: 1.6; margin: 1.5rem 0; max-width: 51ch; }
.intro-actions { display: flex; gap: 1.75rem; align-items: center; flex-wrap: wrap; }
.intro-note { margin: 1.25rem 0 0; color: var(--muted); font-size: .875rem; max-width: 38ch; }
.workflow-section { padding-block: 3.5rem 4rem; }
.workflow-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; margin: 0 0 1rem; }
.home .workflow-heading h2 { font-size: 1.0625rem; font-weight: 600; letter-spacing: -.015em; margin: 0; }
.illustration-label { color: var(--muted); font-size: .75rem; white-space: nowrap; }
.workflow-story { background: var(--scene); border-radius: 14px; color: var(--paper); overflow: hidden; }
.story-controls { display: flex; align-items: stretch; justify-content: space-between; gap: 1rem; padding: 0 2rem; border-bottom: 1px solid var(--scene-line); }
.stage-tabs { display: flex; flex: 1; justify-content: space-between; max-width: 850px; }
.stage-tabs button { display: inline-flex; align-items: center; justify-content: center; gap: .6rem; min-height: 64px; min-width: 44px; padding: 0 .75rem; color: var(--scene-muted); background: transparent; border: 0; border-bottom: 3px solid transparent; margin-bottom: -1px; font-size: 1rem; font-weight: 500; cursor: pointer; white-space: nowrap; }
.stage-tabs button > span { font-size: .75rem; opacity: .8; }
.stage-tabs button:hover { color: var(--paper); }
.stage-tabs button[aria-selected="true"] { color: var(--lime); border-bottom-color: var(--lime); }
.story-play { display: inline-flex; align-items: center; gap: .6rem; background: transparent; border: 0; color: var(--scene-muted); font-size: .8125rem; padding: .5rem 0 .5rem 1rem; min-height: 44px; min-width: 138px; justify-content: flex-end; cursor: pointer; }
.story-play:hover { color: var(--lime); }
.play-icon { font-size: .75rem; width: 1rem; text-align: center; }
.workflow-story :focus-visible { outline-color: var(--lime); outline-offset: -4px; }
.workflow-board { padding: 1.75rem 2.5rem 1.5rem; }
.board-topline { display: flex; justify-content: space-between; align-items: center; gap: 1rem; margin-bottom: 1.75rem; }
.cycle-label { display: inline-flex; gap: .65rem; align-items: center; font-weight: 600; font-size: .875rem; }
.cycle-mark { display: grid; place-items: center; width: 28px; height: 28px; border: 1px solid var(--scene-line); border-radius: 50%; color: var(--lime); font-size: 1.1rem; }
.run-status { font-size: .75rem; color: var(--scene-muted); text-align: right; }
.team-lanes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2rem; }
.team-lane { position: relative; min-width: 0; }
.team-name { display: flex; gap: .75rem; align-items: center; font-size: 1rem; font-weight: 500; margin-bottom: 1rem; }
.team-symbol { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: oklch(35% .028 160); color: var(--scene-muted); font-size: .75rem; }
.lane-content { min-height: 146px; padding: 1.15rem 1.25rem; border: 1px solid var(--scene-line); border-radius: 7px; background: oklch(28% .028 160); transition: background 240ms var(--ease-out), border-color 240ms var(--ease-out); }
.lane-status { display: block; font-size: .75rem; line-height: 1.4; color: var(--lime); margin-bottom: .75rem; }
.lane-content strong { display: block; font-size: 1.0625rem; font-weight: 600; letter-spacing: -.02em; line-height: 1.25; }
.lane-content p { font-size: .875rem; line-height: 1.45; margin: .5rem 0 0; color: var(--scene-muted); }
.lane-connection { position: absolute; left: 100%; width: 2rem; top: 125px; display: flex; align-items: center; color: var(--lime); }
.lane-connection span { height: 1px; background: var(--scene-line); flex: 1; }
.lane-connection i { font-size: 1rem; font-style: normal; }
.team-lane:last-child .lane-connection { display: none; }
.shared-spine { display: flex; align-items: center; gap: 1rem; margin-top: 1.5rem; color: var(--scene-muted); font-size: .8125rem; }
.spine-label { color: var(--lime); font-weight: 500; }
.spine-line { height: 1px; background: var(--scene-line); flex: 1; position: relative; }
.spine-line::before, .spine-line::after { content: ''; position: absolute; top: -2px; width: 5px; height: 5px; border-radius: 50%; background: var(--lime); }
.spine-line::after { right: 0; }
.decision-note { display: flex; align-items: center; justify-content: center; gap: .7rem; min-height: 48px; margin-top: 1rem; padding: .6rem 1rem; border-radius: 6px; color: var(--scene-muted); background: oklch(28% .028 160); font-size: .875rem; text-align: center; }
.decision-symbol { color: var(--lime); font-size: 1.3rem; }
.workflow-board[data-current-stage="run"] .team-lane:nth-child(2) .lane-content,
.workflow-board[data-current-stage="handoff"] .team-lane:nth-child(3) .lane-content { border-color: var(--lime); background: oklch(32% .04 150); }
.workflow-board[data-current-stage="own"] .team-lane:nth-child(2) .lane-content { background: var(--warm-note); border-color: var(--warm-note); color: var(--ink); }
.workflow-board[data-current-stage="own"] .team-lane:nth-child(2) .lane-status,
.workflow-board[data-current-stage="own"] .team-lane:nth-child(2) .lane-content p { color: var(--ink); }
.workflow-board[data-current-stage="own"] .decision-note { color: var(--warm-note); }
.workflow-board[data-current-stage="own"] .decision-symbol { color: var(--warm-note); }
.workflow-board[data-current-stage="build"] .lane-content { border-color: oklch(65% .08 130); }
.story-explanations { background: var(--paper); color: var(--ink); }
.story-explanation { display: grid; grid-template-columns: 95px .95fr 1fr; gap: 1.5rem; align-items: center; padding: 1.75rem 2.5rem; border-bottom: 1px solid var(--line); }
.workflow-story .story-explanation:focus-visible { outline-color: var(--ink); }
.story-explanation:last-child { border-bottom: 0; }
.story-explanation .stage-kicker { margin: 0; color: var(--muted); font-size: .75rem; text-transform: uppercase; letter-spacing: .07em; }
.story-explanation h3 { margin: 0; font-size: 1.375rem; line-height: 1.2; font-weight: 600; }
.story-explanation > p:last-child { margin: 0; font-size: 1rem; line-height: 1.5; color: var(--muted); }
.is-interactive .story-explanations { min-height: 135px; display: grid; }
.workflow-footnote { color: var(--muted); margin: 1rem 0 0; text-align: center; font-size: .875rem; }
.ownership-section { padding: 5rem 0; background: var(--bg-warm); }
.ownership-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 7rem; }
.section-intro h2 { margin: 0 0 1.5rem; }
.section-intro > p:last-child { color: var(--muted); margin: 0; max-width: 38ch; }
.ownership-details { padding-top: .25rem; }
.ownership-details article { display: grid; grid-template-columns: 30px 1fr; gap: 1.25rem; padding: 1.5rem 0; border-top: 1px solid var(--line); }
.ownership-details article:first-child { padding-top: 0; border-top: 0; }
.detail-index { color: var(--muted); font-size: .75rem; padding-top: .2rem; }
.ownership-details h3 { margin: 0 0 .5rem; font-size: 1.1875rem; font-weight: 600; }
.ownership-details p { margin: 0; color: var(--muted); font-size: 1rem; max-width: 44ch; }
.handoff-section { display: grid; grid-template-columns: 1fr 1fr; gap: 6rem; padding-block: 5rem; align-items: center; }
.handoff-copy h2 { margin: 0 0 1.5rem; }
.handoff-copy > p:not(.eyebrow) { color: var(--muted); max-width: 42ch; }
.handoff-copy .fit-note { margin-top: 1.5rem; padding-top: 1.25rem; border-top: 1px solid var(--line); font-size: .875rem; }
.handoff-illustration { padding: 2rem; background: oklch(94.81% .01353 134.9); border-radius: 10px; }
.handoff-art { width: 260px; height: auto; margin: -1rem auto 1.5rem; }
.handoff-people { display: flex; justify-content: space-between; align-items: center; gap: .5rem; margin-bottom: 1.5rem; font-size: .875rem; font-weight: 500; }
.handoff-people > span:not(.handoff-arrow) { display: flex; align-items: center; gap: .5rem; }
.handoff-people i { display: grid; place-items: center; width: 32px; height: 32px; border: 1px solid var(--line); background: var(--paper); border-radius: 50%; font-size: .75rem; font-style: normal; }
.handoff-arrow { font-size: 1.5rem; color: var(--muted); }
.handoff-bundle { background: var(--paper); padding: 1.5rem; border-radius: 6px; transform: rotate(-1.5deg); border: 1px solid var(--line); }
.bundle-title { display: flex; justify-content: space-between; gap: .5rem; margin: 0; font-size: 1rem; font-weight: 600; }
.handoff-bundle ul { list-style: none; padding: 1.25rem 0; margin: 0; }
.handoff-bundle li { display: flex; gap: .75rem; align-items: center; padding: .5rem 0; font-size: .9375rem; }
.handoff-bundle li span { width: 20px; height: 20px; border-radius: 50%; background: var(--lime); display: grid; place-items: center; font-size: .75rem; }
.bundle-end { border-top: 1px solid var(--line); padding-top: 1rem; margin: 0; color: var(--muted); font-size: .8125rem; }
.home-proof { background: var(--scene); color: var(--paper); padding: 3.5rem 0; }
.proof-layout { display: grid; grid-template-columns: .9fr 1fr; gap: 7rem; align-items: center; }
.home-proof .eyebrow { color: var(--lime); }
.home-proof h2 { margin: 0; font-size: clamp(1.9rem, 3vw, 2.5rem); }
.pilot-review { color: var(--scene-muted); font-size: .875rem; margin: 0 0 1rem; }
.pilot-sequence { display: flex; flex-wrap: wrap; gap: .65rem 0; list-style: none; padding: 0; margin: 1.5rem 0 0; color: var(--scene-muted); font-size: .8125rem; }
.pilot-sequence li:not(:last-child)::after { content: "→"; color: var(--lime); padding-inline: .6rem; }
.proof-copy > p:first-child { margin: 0 0 1rem; color: var(--scene-muted); font-size: 1rem; }
.home-proof .text-link { color: var(--lime); text-decoration-color: var(--scene-line); }
.evidence-note { color: var(--scene-muted); font-size: .75rem; margin: 1rem 0 0; max-width: 58ch; }
.home-setup { padding-block: 5rem; }
.setup-intro { max-width: 620px; }
.setup-intro h2 { margin: 0 0 1.25rem; }
.setup-intro > p:last-child { color: var(--muted); margin: 0; }
.setup-sequence { list-style: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2.5rem; padding: 2.5rem 0; margin: 0; }
.setup-sequence li { display: flex; gap: 1rem; border-top: 1px solid var(--line); padding-top: 1.25rem; }
.setup-sequence li > span { font-size: .75rem; color: var(--muted); padding-top: .25rem; }
.setup-sequence h3 { margin: 0 0 .5rem; font-size: 1.0625rem; line-height: 1.3; font-weight: 600; }
.setup-sequence p { margin: 0; font-size: .9375rem; color: var(--muted); }
.setup-invitation { display: flex; align-items: center; justify-content: space-between; gap: 2rem; padding: 2rem; background: var(--lime); border-radius: 8px; }
.setup-invitation strong { font-size: 1.125rem; letter-spacing: -.02em; }
.setup-invitation p { font-size: .875rem; margin: .35rem 0 0; max-width: 45ch; }
.setup-invitation .text-link { text-decoration-color: var(--ink); }
.setup-invitation .intro-actions { flex-shrink: 0; }
.home .site-footer { padding: 2rem 0; }
@media (max-width: 1100px) {
  .intro-grid { gap: 3rem; }
  .ownership-layout, .handoff-section, .proof-layout { gap: 3rem; }
  .story-controls { padding-inline: 1.25rem; }
  .stage-tabs button { padding-inline: .45rem; }
  .workflow-board { padding-inline: 1.75rem; }
  .story-explanation { grid-template-columns: 75px .8fr 1fr; padding-inline: 1.75rem; gap: 1rem; }
  .setup-invitation { flex-wrap: wrap; }
}
@media (max-width: 800px) {
  .home-intro { padding-top: 3rem; }
  .intro-grid { grid-template-columns: 1fr; gap: 1.75rem; }
  .intro-art { width: min(100%, 400px); justify-self: center; }
  .home-intro h1 { max-width: 20ch; }
  .intro-support > p:first-child { max-width: 55ch; margin: 1.5rem 0 1.25rem; }
  .intro-note { max-width: none; margin-top: 1rem; }
  .workflow-heading { align-items: flex-start; }
  .story-controls { flex-wrap: wrap; gap: 0; padding-inline: 1rem; }
  .stage-tabs { flex-basis: 100%; }
  .story-play { margin-left: auto; min-height: 44px; padding: .5rem 0; }
  .stage-tabs button { min-height: 56px; }
  .workflow-board { padding: 1.25rem; }
  .team-lanes { gap: 1rem; }
  .lane-content { padding: 1rem; min-height: 165px; }
  .lane-connection { width: 1rem; }
  .shared-spine { gap: .65rem; }
  .story-explanation { grid-template-columns: 1fr 1.1fr; padding: 1.5rem; gap: .5rem 1.5rem; }
  .story-explanation .stage-kicker { grid-column: 1; }
  .story-explanation h3 { grid-column: 1; grid-row: 2; }
  .story-explanation > p:last-child { grid-column: 2; grid-row: 1 / 3; }
  .ownership-layout, .handoff-section { grid-template-columns: 1fr; gap: 2.5rem; }
  .ownership-section, .handoff-section, .home-setup { padding-block: 3.5rem; }
  .section-intro > p:last-child, .handoff-copy > p:not(.eyebrow) { max-width: 55ch; }
  .ownership-details p { max-width: 60ch; }
  .handoff-illustration { max-width: 560px; width: 100%; justify-self: center; }
  .proof-layout { grid-template-columns: 1fr; gap: 1.5rem; }
  .home-proof { padding-block: 3rem; }
  .setup-sequence { grid-template-columns: 1fr; gap: 1.25rem; padding-block: 2rem; }
}
@media (max-width: 560px) {
  .home .container { width: calc(100% - 2rem); }
  .home .header-inner { min-height: 72px; }
  .home-intro { padding: 2.5rem 0 2rem; }
  .home-intro .eyebrow { font-size: .6875rem; margin-bottom: 1rem; }
  .home-intro h1 { font-size: clamp(2.125rem, 8.2vw, 2.75rem); line-height: 1.1; }
  .intro-support > p:first-child { font-size: 1rem; line-height: 1.6; }
  .intro-actions { gap: 1rem; }
  .home .intro-actions .btn { width: auto; }
  .intro-note { font-size: .8125rem; }
  .intro-art { width: min(100%, 300px); }
  .handoff-art { width: 220px; margin-top: 0; }
  .workflow-heading { display: block; }
  .home .workflow-heading h2 { font-size: 1rem; }
  .illustration-label { display: block; margin-top: .4rem; }
  .workflow-section { padding-bottom: 2.5rem; }
  .workflow-story { border-radius: 10px; }
  .story-controls { padding-inline: .5rem; }
  .stage-tabs button { flex: 1; min-width: 0; font-size: .8125rem; padding-inline: .3rem; min-height: 64px; flex-direction: column; gap: .25rem; }
  .stage-tabs button > span { font-size: .625rem; }
  .story-play { font-size: .75rem; padding-right: .5rem; }
  .workflow-board { padding: .9rem 1rem 1rem; }
  .board-topline { margin-bottom: 1.25rem; gap: .5rem; }
  .cycle-label { font-size: .75rem; gap: .4rem; }
  .cycle-mark { width: 24px; height: 24px; }
  .run-status { font-size: .6875rem; max-width: 14ch; }
  .team-lanes { grid-template-columns: 1fr; gap: .875rem; }
  .team-lane { display: grid; grid-template-columns: 86px minmax(0, 1fr); gap: .75rem; align-items: center; }
  .team-name { display: flex; flex-direction: column; align-items: flex-start; gap: .4rem; margin: 0; font-size: .75rem; }
  .team-symbol { width: 26px; height: 26px; font-size: .6875rem; }
  .lane-content { padding: .85rem; min-height: 94px; }
  .lane-status { font-size: .6875rem; margin-bottom: .45rem; }
  .lane-content strong { font-size: .9375rem; line-height: 1.25; }
  .lane-content p { display: none; }
  .lane-connection { left: 12px; top: auto; bottom: -.875rem; width: 1px; height: .875rem; }
  .lane-connection span { width: 1px; height: 100%; }
  .lane-connection i { display: none; }
  .shared-spine { align-items: flex-start; flex-wrap: wrap; margin-top: 1.25rem; font-size: .75rem; gap: .35rem; }
  .spine-label { flex-basis: 100%; }
  .spine-line { display: none; }
  .decision-note { font-size: .8125rem; text-align: left; padding: .65rem .75rem; line-height: 1.45; min-height: 64px; }
  .decision-symbol { flex-shrink: 0; }
  .story-explanation { display: block; padding: 1.25rem; }
  .story-explanation h3 { font-size: 1.375rem; margin: .5rem 0 .75rem; }
  .story-explanation > p:last-child { font-size: .9375rem; }
  .is-interactive .story-explanations { min-height: 205px; }
  .workflow-footnote { font-size: .8125rem; text-align: left; }
  .home h2 { font-size: 2rem; }
  .ownership-section, .handoff-section, .home-setup { padding-block: 3rem; }
  .ownership-details article { gap: .75rem; grid-template-columns: 24px 1fr; }
  .handoff-illustration { padding: 1.25rem; }
  .handoff-people { font-size: .75rem; }
  .handoff-people i { width: 26px; height: 26px; }
  .handoff-bundle { padding: 1.15rem; }
  .bundle-title { font-size: .9375rem; }
  .handoff-bundle li { font-size: .875rem; }
  .home-proof h2 { font-size: 1.875rem; }
  .setup-invitation { padding: 1.5rem; gap: 1.25rem; }
  .setup-invitation .intro-actions { flex-shrink: 1; }
}
@media (prefers-reduced-motion: reduce) {
  .home *, .home *::before, .home *::after { animation: none !important; transition: none !important; }
  .handoff-bundle { transform: none; }
}

.home-proof :focus-visible { outline-color: var(--lime); }

.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
