/* Art-direction pass: the same lab, a more deliberate hierarchy and rhythm. */

.site-header { border-bottom-color: var(--line); background: var(--bg); }
.identity-sub { font-size: 11px; }
.desktop-nav { gap: 38px; }
.button { border-radius: 3px; }
.button.primary { padding: 17px 23px; }
.button.primary span { transition: transform .35s var(--ease); }
.button.primary:hover span { transform: translate(3px,-3px); }
.text-link { border-bottom: 1px solid transparent; transition: border-color .25s; }
.text-link:hover { border-bottom-color: currentColor; }

/* Signal sculpture: a reserved stage, a reading lane, and a clear resting frame. */
.hero-stage { padding-bottom: 32px; }
.hero-copy, .hero-enhanced .hero-copy { width: 57%; }
.hero h1, .hero h2 { font-weight: 650; }
.intro-name { color: var(--text); }
.hero-description { max-width: 40ch; }
.core-visual { width: 67%; right: -6%; }
.core-visual:before { opacity: .8; }
.core-fallback { opacity: .95; }
.canvas-ready .core-fallback { opacity: 0; }
.label-a { top: 19%; left: 32%; }
.label-b { bottom: 17%; right: 25%; }
.hero-calibration { position: absolute; right: 30px; top: 30%; display: flex; flex-direction: column; align-items: center; gap: 15px; color: var(--dim); font: 8px/1.5 var(--mono); letter-spacing: .12em; z-index: 2; }
.hero-calibration span { writing-mode: vertical-rl; }
.hero-calibration i { width: 1px; height: 34px; background: var(--line); }
.phase-track { gap: 8px; }
.phase-track>span { width: 36px; }
.hero-footer { padding-top: 18px; border-top: 1px solid var(--line); }
.hero-topline { letter-spacing: .1em; }

/* The project index is navigation, not another set of project cards. */
.work-section { padding-top: 100px; }
.section-intro { margin-bottom: 44px; }
.section-intro h2 { font-size: clamp(48px,5.8vw,80px); }
.muted-heading { color: var(--text); }
.project-index { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin-bottom: 70px; }
.project-index a { min-height: 104px; display: flex; align-items: center; gap: 16px; padding: 20px 24px 20px 0; transition: color .25s; }
.project-index a+a { padding-left: 24px; border-left: 1px solid var(--line); }
.project-index a>span:nth-child(2) { font-size: 17px; font-weight: 600; }
.project-index small { display: block; margin-top: 5px; font-size: 12px; font-weight: 400; color: var(--muted); }
.index-symbol { font: 31px/1 Georgia,serif; color: var(--cyan); }
.index-arrow { color: var(--dim); margin-left: auto; transition: transform .3s var(--ease),color .3s; }
.project-index a:hover, .project-index a:focus-visible { color: var(--pink); }
.project-index a:hover .index-arrow { color: var(--pink); transform: translate(2px,-2px); }
.project { padding-top: 0; border-top: 0; margin-bottom: 100px; scroll-margin-top: 20px; }
.project-caption { font-size: 10px; letter-spacing: .05em; padding: 0 0 22px; }
.project-caption>span:first-child { color: var(--text); }
.project h3 { font-size: clamp(42px,4.9vw,70px); }
.project-title-line { color: var(--text); }
.project-outcome { font-size: 22px; line-height: 1.45; }
.project-body { font-size: 17px; }
.machinery { margin-top: 25px; }
.machinery summary { padding: 21px 0; font-size: 14px; }
.machinery summary>span { transition: transform .3s var(--ease); }
.machinery[open] summary>span { transform: rotate(45deg); }

/* NAGS: a cyan calibration bench. The dark puzzle remains the instrument. */
.nags-layout { padding: clamp(28px,3.9vw,56px); grid-template-columns: .9fr 1.1fr; gap: 45px; background: var(--cyan); border-radius: 8px; }
.project-nags h3 { font-size: clamp(65px,7vw,96px); }
.nags-layout .project-copy { color: var(--deep); }
.nags-layout .project-copy :is(.project-status,.project-subtitle,.project-body,.evidence strong,.evidence>span,.evidence a,.source-note,.text-link span) { color: var(--deep); }
.nags-layout .project-copy .evidence { border-color: var(--deep); }
.nags-layout .project-status .status-dot { background: var(--deep); }
.nags-layout .project-copy a:focus-visible { outline-color: var(--deep); }
.nags-layout .project-outcome { max-width: 27ch; }
.nags-layout .evidence { margin: 28px 0 16px; padding: 18px 0; }
.nags-layout .evidence strong { font-size: 40px; }
.nags-layout .evidence a { margin-left: 0; }
.nags-layout .source-note { font-size: 11px; }
.nags-layout .project-links { gap: 10px 18px; }
.chess-instrument { background: var(--bg); border: 0; border-radius: 5px; padding: 25px 22px 16px; box-shadow: 14px 20px 0 color-mix(in oklch,var(--deep) 15%,transparent); }
.chess-stage { margin-top: 28px; transform: perspective(1000px) rotateX(14deg) rotateZ(-7deg); transition: transform .8s var(--ease); }
.chess-board { transform: none; }
.chess-instrument:hover .chess-stage,.chess-stage:focus-within { transform: none; }
.board-coordinates { line-height: 1; }
.board-files { display: flex; justify-content: space-around; word-spacing: normal; }
.chess-square { background: var(--raised); }
.chess-square.dark { background: var(--deep); }
.chess-square:hover { background: var(--line); }
.chess-square.selected { background: var(--pink-dark); }
.chess-square.solved { background: oklch(.42 .06 215); }

/* BlackJack: open, oversized cards with a curriculum ring driven by the demo. */
.blackjack-layout { padding: 30px 0 10px; grid-template-columns: 1.1fr .9fr; gap: 80px; }
.policy-instrument { position: relative; background: none; border: 0; padding: 18px 28px 22px; overflow: hidden; isolation: isolate; }
.curriculum-ring { position: absolute; width: 89%; left: 5.5%; top: 55px; z-index: -1; fill: none; stroke: var(--line); stroke-width: 1; transform: rotate(-90deg); }
.curriculum-ticks { stroke: var(--border); stroke-dasharray: 1 13; }
.curriculum-progress { stroke: var(--pink); stroke-width: 2; stroke-dasharray: 100; stroke-dashoffset: calc(100 * (1 - var(--training,0))); opacity: .85; }
.playing-cards { height: 380px; }
.playing-card { top: 50%; left: 50%; width: 170px; height: 242px; border-radius: 8px; }
.playing-card>b { font-size: 96px; }
.card-one { transform: translate(-76%,-50%) rotate(-17deg); }
.card-two { transform: translate(-8%,-44%) rotate(16deg); }
.card-orbit { opacity: .3; }
.policy-bars { height: 74px; gap: 5px; }
.policy-bars span { border-radius: 1px 1px 0 0; }
.training-control { margin-top: 26px; }
.training-control .button { border-color: var(--pink); }
.policy-instrument.training .card-one { transform: translate(-76%,-53%) rotate(-12deg); }
.policy-instrument.training .card-two { transform: translate(-8%,-47%) rotate(12deg); }
.policy-instrument .demo-note { margin-top: 18px; }

/* The product study gets the scale and depth of a real working surface. */
.dashboard-heading { padding-top: 20px; }
.dashboard-heading>div { max-width: 370px; }
.dashboard-stage { position: relative; padding: 54px 40px 62px; border-radius: 8px; background: var(--raised); overflow: hidden; }
.dashboard-stage:before { content: ''; position: absolute; inset: 26px; border: 1px solid var(--border); border-radius: 5px; }
.dashboard-demo { position: relative; transform: perspective(1800px) rotateY(-5deg) rotateX(4deg); transition: transform .8s var(--ease); }
.dashboard-stage:hover .dashboard-demo,.dashboard-stage:focus-within .dashboard-demo { transform: perspective(1800px) rotateY(0) rotateX(0); }
.dashboard-wordmark { font-family: var(--display); font-size: 25px; }
.dashboard-greeting { margin: 32px 0; }
.dashboard-greeting h4 { font-size: 25px; }
.widget { padding: 20px; }
.widget h5 { font-size: 13px; }
.dashboard-evidence { padding: 26px 0 0; }

/* Research: give the decision boundary the full visual weight of the question. */
.heart-layout { padding: 26px 0 10px; gap: 70px; }
.threshold-instrument { border-radius: 0; border: 0; border-top: 1px solid var(--cyan); background: none; padding: 28px 0 10px; }
.threshold-instrument h4 { font-size: 26px; }
.threshold-chart { height: 230px; margin-top: 36px; }
.threshold-readouts { margin-top: 28px; padding: 22px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.threshold-readouts strong { font-size: 36px; }
.sample-bar { position: absolute; bottom: 0; left: var(--score); width: 2.6%; max-width: 16px; transform: translateX(-50%); border-radius: 1px 1px 0 0; }

/* Quieter supporting sections have a different density and silhouette. */
.orbit-section { padding-bottom: 110px; }
.orbit-row { padding-top: 28px; padding-bottom: 28px; }
.capabilities-section { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; padding-top: 95px; padding-bottom: 95px; }
.capability-intro h2 { font-size: clamp(38px,4.2vw,58px); }
.capability-intro h2 br { display: none; }
.capability-intro>p:last-child { font-size: 18px; max-width: 35ch; }
.capability-intro>p:last-child br { display: none; }
.capability-board { display: block; margin-top: 0; }
.capability { font-size: 19px; padding: 20px 0; }
.capability-detail { margin-top: 28px; }
.capability-diagram { display: none; }
.capability-detail>p { min-height: 0; font-size: 16px; }
#capability-projects { margin-top: 20px; }
.about-section { gap: 100px; padding-top: 115px; padding-bottom: 115px; }
.about-copy h2 { font-size: clamp(46px,5.5vw,76px); }
.about-art { padding: 24px; background: var(--surface); border-radius: 8px; }
.about-art svg { opacity: .9; }
.about-art svg path { stroke: var(--pink); stroke-width: 2.5; }
.about-lead { font-size: 27px; }

/* The final invitation is the second deliberate colour moment. */
.contact-section { position: relative; background: var(--pink); color: var(--deep); max-width: none; border: 0; padding-top: 64px; padding-bottom: 60px; }
.contact-section> * { position: relative; max-width: calc(1440px - var(--gutter) * 2); margin-left: auto; margin-right: auto; }
.contact-prelude,.contact-section .contact-prelude>span { color: var(--deep); }
.contact-prelude .status-dot { background: var(--deep); }
.contact-section h2 { font-size: clamp(52px,7vw,96px); line-height: 1.08; margin-top: 48px; margin-bottom: 42px; }
.contact-section .pink { color: var(--deep); }
.contact-section .contact-bottom>p { color: var(--deep); }
.contact-email { border-bottom-color: var(--deep); gap: 8px; }
.contact-section .contact-email>span,.contact-email strong,.contact-email .email-arrow { color: var(--deep); }
.contact-email .email-arrow { transition: transform .4s var(--ease); }
.contact-email:hover .email-arrow { transform: translate(6px,-6px); }
.contact-tools .quiet-button { color: var(--deep); }
.contact-section :is(a,button):focus-visible { outline-color: var(--deep); }
.site-footer { border-top: 0; padding-top: 25px; padding-bottom: 25px; }

/* Distinct entrances preserve an already-visible default. */
.project-nags .project-copy.reveal-in { animation-name: bench-enter; }
.project-blackjack .project-copy.reveal-in { animation-name: policy-enter; }
.dashboard-heading.reveal-in { animation-name: product-enter; }
.project-heart .project-copy.reveal-in { animation-name: evidence-enter; }
@keyframes bench-enter { from { transform: translateX(-18px); opacity: .5; } to { transform: translateX(0); opacity: 1; } }
@keyframes policy-enter { from { transform: translateY(18px); opacity: .5; } to { transform: translateY(0); opacity: 1; } }
@keyframes product-enter { from { opacity: .45; } to { opacity: 1; } }
@keyframes evidence-enter { from { transform: translateX(-12px); opacity: .5; } to { transform: translateX(0); opacity: 1; } }
.motion-off .dashboard-demo { transform: none; }
.motion-off .chess-stage { transform: none; }

@media(max-width:1100px) {
  .project-index a { gap: 10px; padding-right: 12px; }
  .project-index a+a { padding-left: 15px; }
  .project-index a>span:nth-child(2) { font-size: 15px; }
  .project-index small { font-size: 10px; }
  .index-symbol { font-size: 27px; }
  .nags-layout { gap: 28px; padding: 32px; }
  .nags-layout .project-outcome { font-size: 20px; }
  .nags-layout .project-body { font-size: 15px; }
  .nags-layout .evidence strong { font-size: 34px; }
  .nags-layout .source-note { display: block; }
  .blackjack-layout,.heart-layout { gap: 44px; }
  .playing-card { width: 145px; height: 210px; }
  .playing-cards { height: 335px; }
  .curriculum-ring { top: 66px; }
  .policy-instrument { padding-left: 12px; padding-right: 12px; }
  .dashboard-stage { padding: 38px 22px; }
  .dashboard-demo { padding: 22px; }
  .dashboard-stage:before { inset: 14px; }
  .widget { padding: 14px; }
  .capabilities-section { gap: 50px; }
  .about-section { gap: 65px; }
}

@media(max-width:800px) {
  .hero-copy,.hero-enhanced .hero-copy { width: 100%; }
  .hero-description { max-width: 39ch; }
  .hero-calibration { display: none; }
  .core-visual { width: 115%; max-width: 650px; right: -6%; }
  .label-a { top: 22%; left: 25%; }
  .label-b { bottom: 22%; right: 20%; }
  .hero-footer { padding-top: 13px; }
  .work-section { padding-top: 75px; }
  .section-intro h2 { font-size: 48px; }
  .project-index { grid-template-columns: repeat(2,minmax(0,1fr)); margin-bottom: 48px; }
  .project-index a { min-height: 88px; }
  .project-index a+a { padding-left: 18px; }
  .project-index a:nth-child(3) { border-left: 0; padding-left: 0; }
  .project-index a:nth-child(n+3) { border-top: 1px solid var(--line); }
  .project { margin-bottom: 75px; }
  .project h3 { font-size: 48px; }
  .project-caption { font-size: 9px; padding-bottom: 20px; }
  .nags-layout { grid-template-columns: 1fr; padding: 34px; gap: 35px; }
  .nags-layout .project-outcome { max-width: 37ch; font-size: 23px; }
  .nags-layout .project-body { font-size: 17px; }
  .project-nags h3 { font-size: 80px; }
  .chess-instrument { max-width: none; box-shadow: 8px 10px 0 color-mix(in oklch,var(--deep) 15%,transparent); }
  .blackjack-layout { grid-template-columns: 1fr; gap: 30px; padding-top: 20px; }
  .policy-instrument { max-width: 550px; justify-self: center; padding: 15px 24px; }
  .playing-cards { height: 380px; }
  .playing-card { width: 170px; height: 240px; }
  .curriculum-ring { top: 40px; }
  .dashboard-stage { padding: 25px 20px; }
  .dashboard-stage:before { display: none; }
  .dashboard-demo { padding: 20px; transform: none; }
  .dashboard-heading h3 { font-size: 48px; }
  .dashboard-greeting h4 { font-size: 22px; }
  .widget { padding: 18px; }
  .heart-layout { grid-template-columns: 1fr; gap: 35px; }
  .threshold-chart { height: 220px; }
  .threshold-instrument { max-width: none; }
  .threshold-readouts strong { font-size: 30px; }
  .orbit-section { padding-bottom: 70px; }
  .capabilities-section { display: block; padding-top: 68px; padding-bottom: 68px; }
  .capability-intro h2 { max-width: 17ch; font-size: 47px; }
  .capability-board { margin-top: 35px; }
  .capability-intro>p:last-child { max-width: 50ch; }
  .about-section { gap: 35px; padding-top: 80px; padding-bottom: 80px; }
  .about-art { padding: 12px; }
  .about-copy h2 { font-size: 46px; }
  .about-lead { font-size: 23px; }
  .contact-section { padding-top: 45px; padding-bottom: 40px; }
  .contact-section h2 { font-size: clamp(44px,8vw,64px); margin-top: 34px; margin-bottom: 30px; }
  .contact-section> * { max-width: 100%; }
}

@media(max-width:480px) {
  .hero-stage { min-height: 860px; }
  .hero h1 { font-size: clamp(40px,11.4vw,54px); }
  .hero-description { max-width: 31ch; }
  .button.primary { padding: 15px 17px; }
  .core-visual { width: 132%; max-width: none; right: -17%; bottom: 45px; }
  .hero-footer { font-size: 8px; }
  .hero-actions { gap: 18px; }
  .section-intro h2 { font-size: 45px; }
  .project-index a { gap: 9px; padding-right: 10px; }
  .project-index a+a { padding-left: 13px; }
  .project-index a>span:nth-child(2) { font-size: 14px; }
  .project-index small { font-size: 11px; max-width: 12ch; line-height: 1.35; }
  .index-symbol { font-size: 25px; }
  .index-arrow { display: none; }
  .project-caption { font-size: 8px; }
  .nags-layout { padding: 28px var(--gutter); gap: 30px; margin-left: calc(var(--gutter) * -1); margin-right: calc(var(--gutter) * -1); border-radius: 0; }
  .nags-layout .project-body { font-size: 16px; }
  .nags-layout .project-outcome { font-size: 21px; }
  .project-nags h3 { font-size: 70px; }
  .project-nags .project-subtitle { font-size: 13px; }
  .nags-layout .evidence { gap: 10px; }
  .nags-layout .evidence strong { font-size: 31px; }
  .chess-instrument { padding: 18px 10px 10px; }
  .chess-stage { margin-top: 20px; }
  .chess-square { font-size: 25px; }
  .board-files { word-spacing: normal; }
  .board-coordinates { line-height: 1; }
  .instrument-bottom { flex-wrap: wrap; }
  .instrument-bottom p { max-width: none; font-size: 12px; }
  .project h3 { font-size: 44px; }
  .project-nags h3 { font-size: 70px; }
  .blackjack-layout { gap: 25px; }
  .policy-instrument { padding: 15px 0; }
  .playing-cards { height: 305px; }
  .playing-card { width: 132px; height: 191px; }
  .playing-card>b { font-size: 72px; }
  .curriculum-ring { width: 100%; left: 0; top: 28px; }
  .training-control p { font-size: 7px; }
  .policy-bars { height: 60px; gap: 4px; }
  .dashboard-stage { padding: 0; background: transparent; overflow: visible; }
  .dashboard-demo { padding: 18px 12px; }
  .dashboard-greeting h4 { font-size: 21px; }
  .dashboard-heading h3 { font-size: 44px; }
  .dashboard-wordmark { font-size: 23px; }
  .widget { padding: 18px; }
  .widget h5 { font-size: 13px; }
  .threshold-instrument h4 { font-size: 24px; }
  .threshold-chart { height: 200px; }
  .threshold-readouts strong { font-size: 27px; }
  .threshold-readouts span { font-size: 11px; }
  .capability-intro h2 { font-size: 41px; }
  .about-art { max-width: none; width: 100%; padding: 24px; }
  .about-copy h2 { font-size: 49px; }
  .about-lead { font-size: 25px; }
  .contact-section h2 { font-size: 44px; }
  .contact-email strong { font-size: 21px; }
  .contact-bottom { gap: 25px; }
  .contact-tools { column-gap: 18px; row-gap: 0; }
}

@media(max-height:620px) and (min-width:801px) {
  .hero-calibration { display: none; }
  .hero h1,.hero h2 { font-size: 50px; }
  .hero-footer { padding-top: 9px; }
}
@media(pointer:coarse) { .chess-stage { transform: none; transition: none; } }
@media(prefers-reduced-motion:reduce) { .dashboard-demo,.chess-stage { transform: none; } }
@media print {
  .project-index,.hero-calibration,.curriculum-ring,.dashboard-stage { display: none!important; }
  .nags-layout,.contact-section,.about-art { background: transparent; color: black; padding: 12px 0; box-shadow: none; }
  .capabilities-section { display: block; }
  .project { margin: 0; padding: 18px 0; }
  .section-intro { margin-bottom: 20px; }
  .project h3,.section-intro h2,.capability-intro h2,.about-copy h2,.contact-section h2 { font-size: 28px; }
  .project-caption { padding-bottom: 8px; font-size: 8px; }
  .project-outcome { margin: 10px 0; font-size: 16px; }
  .project-body { font-size: 12px; }
  .blackjack-layout,.heart-layout,.dashboard-heading { padding: 10px 0; }
  .about-section,.capabilities-section { padding: 18px 20px; }
  .contact-section h2 { margin-top: 12px; margin-bottom: 16px; }
  .work-section { padding-top: 20px; }
  .work-section:before { content: 'Alex Halliday / Selected project profile'; display: block; font: 600 24px/1.3 var(--display); margin-bottom: 18px; }
}
