/* MBK editorial extensions. Existing semantic tokens remain the source of truth. */
:root {
  --signature-gap: clamp(28px, 5vw, 76px);
  --signature-section: clamp(50px, 7vw, 100px);
}

/* A quieter portrait treatment, with the signature label outside the photograph. */
.portfolio-home .hero {
  grid-template-columns: 1.15fr 1fr;
  gap: var(--signature-gap);
  padding-top: 62px;
  padding-bottom: 74px;
}
.portfolio-home .hero h1 {
  font-size: clamp(56px, 6.1vw, 86px);
  letter-spacing: -.052em;
  line-height: 1.09;
  margin-block: 27px;
}
.portfolio-home .hero h1 em { letter-spacing: -.055em; }
.portfolio-home .hero-intro { font-size: 14px; max-width: 440px; line-height: 1.9; }
.portfolio-home .hero-visual { max-width: 490px; padding-bottom: 28px; width: 100%; justify-self: end; }
.portfolio-home .portrait-frame { aspect-ratio: 1; }
.portfolio-home .portrait-frame > img { object-fit: contain; filter: none; }
.portfolio-home .portrait-bottom > span { font-size: 17px; letter-spacing: -.5px; }
.portfolio-home .portrait-bottom small { font-size: 6px; }
.portfolio-home .build-label {
  left: -18px;
  bottom: 12px;
  padding: 10px 14px;
  gap: 10px;
  font-size: 9px;
  transform: rotate(-3deg);
  box-shadow: none;
}
.portfolio-home .build-label .code-glyph { font-size: 19px; padding-right: 10px; }
.portfolio-home .build-label .label-dot { width: 4px; height: 4px; margin-left: 6px; }
.portfolio-home .portrait-coordinate { margin-top: 18px; justify-content: end; }
.portfolio-home .portrait-coordinate > span { display: none; }
.portfolio-home .share-feedback { bottom: -5px; }
.portfolio-home .work-section { padding-top: 72px; }
.ticker-caption { padding: 13px 20px; }
.ticker-caption .motion-toggle { border: 0; min-height: 36px; }
.ticker-set > span { font-size: 13px; padding-right: 46px; gap: 46px; }
.service-ticker { min-height: 68px; }
.shared-archive-window { touch-action: pan-y; }
.shared-archive.is-paused .shared-archive-window { touch-action: auto; }

/* A fine rule travels with the invitation, not with every block of text. */
.conversation-line {
  width: 89%;
  max-width: 1280px;
  margin: auto;
  padding-block: 43px;
  position: relative;
}
.conversation-line::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 1px;
  background: var(--line);
}
.conversation-line::before {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 12%;
  height: 1px;
  z-index: 1;
  background: var(--accent);
  transition: width .8s var(--ease);
}
.conversation-line:hover::before, .conversation-line:focus-within::before { width: 100%; }
.conversation-line > span { display: block; font: 8px/1.6 var(--sans); letter-spacing: 1.3px; color: var(--muted); margin-bottom: 18px; }
.conversation-line > a {
  display: flex;
  align-items: center;
  gap: 12px;
  font: 500 clamp(21px, 2.8vw, 39px)/1.4 var(--display);
  letter-spacing: -1px;
}
.conversation-line em { color: var(--accent); font-family: var(--serif); font-weight: 400; }
.conversation-line svg { margin-left: auto; width: 32px; height: 32px; transition: transform .4s var(--ease); }
.conversation-line a:hover svg { transform: translate(4px, -4px); }
.academy-main > .conversation-line { width: 100%; margin-block: 25px; }

.home-process { display: grid; grid-template-columns: 1fr 1fr; gap: var(--signature-gap); align-items: start; }
.home-process h2 { font: 500 clamp(30px, 3.4vw, 46px)/1.2 var(--display); letter-spacing: -1.8px; margin-top: 24px; }
.home-process p:not(.section-index) { font-size: 13px; line-height: 1.9; max-width: 390px; margin: 24px 0; }
.home-process ol { padding: 0; margin: 0; list-style: none; }
.home-process li { padding: 18px 0; border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 26px; font-size: 15px; }
.home-process li:first-child { border-top: 1px solid var(--line); }
.home-process li > span { color: var(--accent); font: 9px var(--sans); }
.home-process li > svg { margin-left: auto; width: 14px; color: var(--muted); }

/* Rectangular brand orbit: text moves along a path; the photograph never rotates. */
.profile-opening { gap: clamp(35px, 7vw, 100px) !important; }
.profile-opening > .brand-orbit-frame {
  position: relative;
  padding: 34px !important;
  margin: 12px 0 !important;
  background: transparent !important;
  border: 0 !important;
  overflow: visible;
  box-shadow: none;
}
.brand-orbit-frame > img {
  display: block;
  width: 100% !important;
  height: auto !important;
  max-height: none !important;
  aspect-ratio: 1073 / 1600 !important;
  object-fit: contain !important;
  border-radius: var(--radius);
}
.brand-orbit-frame > figcaption {
  margin-top: 14px;
  padding: 0 !important;
  background: transparent !important;
  font: 8px/1.7 var(--sans) !important;
  letter-spacing: .8px;
}
.brand-orbit {
  position: absolute;
  inset: 0;
  width: 100%;
  height: calc(100% - 22px);
  pointer-events: none;
  overflow: visible;
}
.brand-orbit text { fill: var(--accent); font: 500 10px var(--display); letter-spacing: 2px; }
.brand-orbit .orbit-rule { fill: none; stroke: var(--line); stroke-width: .6; }
.orbit-control {
  display: flex;
  margin: 5px 34px 0 auto;
  gap: 10px;
  border: 0;
  background: transparent;
  color: var(--muted);
  font: 9px/1.7 var(--sans);
  cursor: pointer;
}
.orbit-control:hover { color: var(--accent); }

/* Expertise as connected disciplines, not another grid of identical cards. */
.expertise-atlas { padding-block: 25px var(--signature-section); }
.atlas-heading { display: flex; justify-content: space-between; gap: 30px; align-items: end; margin-bottom: 42px; }
.atlas-heading h2 { font: 500 clamp(32px, 4vw, 52px)/1.2 var(--display); letter-spacing: -2px; max-width: 640px; }
.atlas-heading p { font-size: 12px; max-width: 260px; line-height: 1.9; }
.atlas-chapter { display: grid; grid-template-columns: 65px 1fr 1.2fr; gap: 35px; padding-block: 37px; border-top: 1px solid var(--line); position: relative; }
.atlas-index { color: var(--accent); font: 11px/1.5 var(--sans); padding-top: 10px; }
.atlas-chapter h3 { font: 500 clamp(26px, 3vw, 39px)/1.25 var(--display); letter-spacing: -1.4px; margin: 0 0 15px; }
.atlas-chapter h3 em { display: block; font-family: var(--serif); color: var(--accent); font-weight: 400; }
.atlas-chapter p { font-size: 13px; line-height: 1.9; max-width: 350px; }
.atlas-links { display: grid; align-content: start; }
.atlas-links a { padding: 14px 0; border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; align-items: center; gap: 15px; font-size: 13px; transition: color .25s, padding .25s; }
.atlas-links a:first-child { padding-top: 5px; }
.atlas-links a:hover { color: var(--accent); padding-left: 8px; }
.atlas-links svg { width: 15px; height: 15px; color: var(--accent); }
.expertise-details { margin: 35px 0; padding: 22px 0; border-block: 1px solid var(--line); }
.expertise-details > summary { cursor: pointer; font-size: 14px; color: var(--accent); }
.expertise-details .service-grid { margin-top: 30px; }

/* Evidence-led experience: no invented dates or employers. */
.experience-ledger { padding-block: 20px 65px; }
.ledger-opening { display: grid; grid-template-columns: 1.1fr 1fr; gap: var(--signature-gap); margin: 20px 0 45px; align-items: start; }
.ledger-opening h2 { font: 500 clamp(32px, 4.6vw, 59px)/1.15 var(--display); letter-spacing: -2px; margin: 0; }
.ledger-opening h2 em { font-family: var(--serif); font-weight: 400; color: var(--accent); }
.ledger-opening p { font-size: 14px; line-height: 1.9; margin: 0; }
.ledger-entry { display: grid; grid-template-columns: 90px .85fr 1.2fr; gap: 30px; border-top: 1px solid var(--line); padding: 32px 0; position: relative; }
.ledger-entry::before { content: ""; width: 5px; height: 5px; border: 1px solid var(--accent); border-radius: 50%; position: absolute; top: 41px; left: 52px; }
.ledger-entry .ledger-number { font: 10px/2 var(--sans); color: var(--accent); }
.ledger-entry h3 { font-size: 24px; letter-spacing: -.8px; margin: 0 0 10px; }
.ledger-entry .ledger-context { font: 8px/1.8 var(--sans); letter-spacing: 1px; color: var(--muted); }
.ledger-entry p { font-size: 13px; line-height: 1.9; margin: 0 0 18px; max-width: 540px; }
.ledger-entry a { font-size: 11px; color: var(--accent); display: inline-flex; gap: 20px; align-items: center; }
.ledger-entry a svg { width: 14px; height: 14px; }
.experience-skills { display: flex; flex-wrap: wrap; gap: 10px; margin-block: 25px; }
.experience-skills span { font-size: 11px; padding: 8px 13px; border: 1px solid var(--line); border-radius: var(--radius); color: var(--muted); }
.experience-note { display: grid; grid-template-columns: 1fr 1.5fr; gap: 40px; padding: 30px; background: var(--sage); border-left: 1px solid var(--accent); }
.experience-note h3 { font-size: 21px; margin: 0; }
.experience-note p { font-size: 12px; line-height: 1.9; margin: 0; }
.experience-actions { display: flex; gap: 20px; align-items: center; flex-wrap: wrap; margin-top: 30px; }
.experience-actions button { padding: 12px 18px; border: 1px solid var(--line); border-radius: var(--radius); background: transparent; font-size: 12px; }

/* A sticky index and continuous rule tie seven meaningful stages together. */
.process-journey { display: grid; grid-template-columns: .7fr 1.5fr; gap: var(--signature-gap); margin: 30px 0 70px; align-items: start; }
.process-rail { position: sticky; top: 35px; padding-top: 24px; }
.process-rail > p { font: 8px/1.8 var(--sans); letter-spacing: 1px; margin-bottom: 25px; }
.process-rail nav { display: grid; gap: 5px; }
.process-rail a { padding: 10px 0; display: flex; gap: 18px; align-items: center; font-size: 12px; color: var(--muted); transition: color .3s; }
.process-rail a > span { font: 9px var(--sans); }
.process-rail a[aria-current], .process-rail a:hover { color: var(--accent); }
.process-stages { border-left: 1px solid var(--line); padding-left: 40px; }
.process-stage { padding: 26px 0 40px; position: relative; border-top: 1px solid var(--line); scroll-margin-top: 25px; }
.process-stage::before { content: ""; position: absolute; left: -45px; top: 31px; width: 9px; height: 9px; border-radius: 50%; background: var(--paper); border: 1px solid var(--accent); transition: background .3s; }
.process-stage:hover::before { background: var(--accent); }
.process-stage .stage-kicker { font: 9px/1.7 var(--sans); letter-spacing: 1px; color: var(--accent); }
.process-stage h2 { font: 500 clamp(27px, 3.5vw, 43px)/1.3 var(--display); letter-spacing: -1.3px; margin: 15px 0; }
.process-stage p { font-size: 14px; line-height: 1.95; max-width: 600px; }
.stage-output { font: 9px/1.8 var(--sans); letter-spacing: .4px; color: var(--accent); margin-top: 22px; display: flex; align-items: center; gap: 13px; }
.stage-output::before { content: ""; width: 22px; height: 1px; background: var(--accent); }
.portfolio-facts { display: flex; align-items: center; gap: 60px; border-block: 1px solid var(--line); padding-block: 28px; margin: 30px 0 45px; }
.portfolio-facts > div { display: flex; align-items: center; gap: 18px; }
.portfolio-facts strong { font: 500 38px/1 var(--display); letter-spacing: -1.5px; color: var(--accent); }
.portfolio-facts span { font: 8px/1.8 var(--sans); text-transform: uppercase; letter-spacing: .8px; max-width: 150px; }
.portfolio-facts > p { font-size: 11px; line-height: 1.8; max-width: 290px; margin-left: auto; }
.reveal-ready { opacity: 0; transform: translateY(14px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal-ready.is-revealed { opacity: 1; transform: none; }

@media (max-width: 1000px) {
  .portfolio-home .hero { gap: 35px; }
  .portfolio-home .hero h1 { font-size: clamp(50px, 6.8vw, 68px); }
  .portfolio-home .hero-intro { font-size: 12px; }
  .atlas-chapter { grid-template-columns: 35px 1fr 1.1fr; gap: 22px; }
  .ledger-entry { grid-template-columns: 65px 1fr 1.2fr; gap: 22px; }
  .ledger-entry::before { left: 40px; }
  .process-journey { grid-template-columns: .65fr 1.3fr; gap: 35px; }
  .portfolio-facts { gap: 30px; flex-wrap: wrap; }
}
@media (max-width: 700px) {
  .portfolio-home .hero { grid-template-columns: 1fr; padding-top: 35px; padding-bottom: 45px; gap: 45px; }
  .portfolio-home .hero h1 { font-size: clamp(49px, 12.7vw, 78px); }
  .portfolio-home .hero-intro { font-size: 14px; }
  .portfolio-home .hero-visual { width: 94%; max-width: 440px; padding-right: 15px; padding-bottom: 29px; }
  .portfolio-home .portrait-frame { aspect-ratio: 1; }
  .portfolio-home .portrait-bottom > span { font-size: 16px; }
  .portfolio-home .portrait-bottom small { font-size: 5px; }
  .portfolio-home .build-label { left: -15px; bottom: 12px; padding: 8px 11px; font-size: 8px; }
  .portfolio-home .build-label .code-glyph { font-size: 16px; }
  .portfolio-home .work-section { padding-top: 50px; }
  .ticker-caption { padding: 10px 8px; }
  .conversation-line { width: 88%; padding-block: 32px; }
  .conversation-line > a { flex-wrap: wrap; gap: 2px 8px; letter-spacing: -.7px; padding-right: 35px; position: relative; }
  .conversation-line svg { position: absolute; right: 0; width: 23px; height: 23px; }
  .home-process { grid-template-columns: 1fr; gap: 30px; }
  .home-process h2 { font-size: 34px; }
  .home-process li { font-size: 14px; padding-block: 16px; }
  .profile-opening > .brand-orbit-frame { padding: 27px !important; width: 100%; max-width: 460px; margin: 24px auto 0 !important; }
  .brand-orbit-frame > figcaption { font-size: 7px !important; }
  .profile-opening h1 { font-size: clamp(48px, 12vw, 58px) !important; }
  .profile-opening > * { min-width: 0; }
  .atlas-heading, .ledger-opening { display: block; }
  .atlas-heading h2 { font-size: 35px; }
  .atlas-heading p { margin-top: 20px; max-width: 350px; }
  .atlas-chapter { grid-template-columns: 25px 1fr; gap: 18px; padding-block: 28px; }
  .atlas-chapter h3 { font-size: 32px; }
  .atlas-links { grid-column: 2; margin-top: 0; }
  .atlas-links a { font-size: 13px; }
  .ledger-opening h2 { font-size: 43px; margin-bottom: 25px; }
  .ledger-opening p { font-size: 13px; }
  .ledger-entry { grid-template-columns: 25px 1fr; gap: 15px; }
  .ledger-entry::before { display: none; }
  .ledger-entry > div:last-child { grid-column: 2; }
  .ledger-entry h3 { font-size: 24px; }
  .experience-note { grid-template-columns: 1fr; gap: 18px; padding: 23px; }
  .experience-skills { gap: 7px; }
  .experience-skills span { font-size: 10px; padding: 7px 10px; }
  .process-journey { grid-template-columns: 1fr; gap: 25px; }
  .process-rail { position: static; border-block: 1px solid var(--line); padding-block: 20px; }
  .process-rail > p { margin-top: 0; margin-bottom: 10px; }
  .process-rail nav { grid-template-columns: 1fr 1fr; gap: 3px 15px; }
  .process-rail a { font-size: 10px; gap: 10px; min-height: 42px; }
  .process-stages { margin-left: 5px; padding-left: 24px; }
  .process-stage::before { left: -29px; }
  .process-stage h2 { font-size: 31px; }
  .process-stage p { font-size: 13px; }
  .stage-output { font-size: 8px; }
  .portfolio-facts { gap: 25px; }
  .portfolio-facts > div { gap: 12px; }
  .portfolio-facts strong { font-size: 33px; }
  .portfolio-facts span { font-size: 7px; max-width: 90px; }
  .portfolio-facts > p { margin: 0; max-width: none; }
}
@media (prefers-reduced-motion: reduce) {
  .reveal-ready { opacity: 1; transform: none; }
  .brand-orbit { display: none; }
  .orbit-control { display: none; }
}
@media print {
  .global-header, .global-footer, .shared-archive, .service-ticker, .conversation-line, .personal-supplied-image, .motion-toggle, .experience-actions button { display: none !important; }
  body.academy { background: white !important; color: black !important; }
  .experience-ledger p, .ledger-entry .ledger-context, .experience-skills span { color: #333 !important; }
  .reveal-ready { opacity: 1; transform: none; }
  .ledger-entry { break-inside: avoid; }
}
