/* Consistent reading sizes across every viewport. Small type is reserved for labels. */
:root {
  --text-body: 1rem;
  --text-small: .875rem;
  --text-label: .75rem;
  --motion-ease: cubic-bezier(.2, .7, .2, 1);
}

body { font-size: 17px; }
main { overflow-x: clip; }
.main-nav a { font-size: 15px; }
.hero-title { font-size: var(--text-body); line-height: 1.8; }
.hero-description { font-size: 18px; line-height: 1.8; }
.about-copy p,
.section-heading > p,
.service-card p,
.project-copy p,
.timeline-card ul,
.timeline-card li,
.skills-intro > p,
.contact-copy > p { font-size: var(--text-body); line-height: 1.8; }.hero-location,.hero-bottom > a,.chip,.stats > div > span,.company,.timeline-card .company,.timeline-date > span + span,.text-link,.learning-note,.skill-tabs button,.contact-form label,.form-status,.footer-top > p,.button,.hero-buttons .button,.contact-form .button{ font-size: var(--text-small); }.eyebrow,.section-label,.section-label > span + span:not(.tiny-star),.hero-bottom > span,.affiliation-strip > .container > span,.affiliation-strip > .container > span:first-child,.affiliation small,.interests > span:first-child,.card-tags,.item-type,.timeline-date,.draft-label,.location-small,.contact-detail > div > span:first-child,.project-tags span,.content-note,.about > .content-note,.skills-panel .content-note,.footer-top > p > span,.footer-bottom{ font-size: var(--text-label); }
.eyebrow { letter-spacing: 1px; }
.card-tags { font-size: 11px; }
.affiliation strong { font-size: 20px; }
.affiliation small { letter-spacing: .2px; }
.affiliation-strip > .container > span:first-child { max-width: 210px; }
.affiliation-strip > .container { gap: 35px; }
.interests > span:first-child { flex-basis: 100%; margin-bottom: 6px; }
.chip { padding: 9px 15px; }
.chip .icon { width: 17px; height: 17px; }
.stats > div { padding-inline: 18px; }
.stats > div > span { display: block; margin-top: 9px; line-height: 1.5; }
.stats strong { font-size: 54px; }
.hero-location { flex-wrap: wrap; }
.hero-bottom { gap: 24px; }
.hero-bottom > span { text-align: right; }
.service-card h3 { font-size: 21px; }
.service-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.service-card { padding: 30px; display: flex; flex-direction: column; }
.service-card p { margin-bottom: 25px; }
.card-tags { margin-top: auto; }
.project-copy h3 { font-size: 28px; }
.project-copy { padding: 27px; }
.project-tags span { padding: 4px 8px; }
.timeline-item { margin-top: 46px; }
.timeline-card { padding: 32px; }
.timeline-card h3 { font-size: 23px; line-height: 1.4; }
.timeline-card li { margin-block: 10px; }
.timeline-date { gap: 10px; }
.timeline-date > span + span { line-height: 1.6; }
.skills-intro > p { max-width: 410px; }
.contact-detail > div > span + span,
.contact-detail a,
input,
textarea,
input::placeholder,
textarea::placeholder { font-size: var(--text-body); }
.form-note { font-size: var(--text-small); line-height: 1.7; }
.form-row > div { min-width: 0; }
.footer-top > p { font-size: 16px; }
.footer-top > p > span { font-size: 14px; }
.icon-link,
.header-actions .icon-link,
.footer-socials .icon-link { width: 44px; height: 44px; }
.section-heading > p { max-width: 420px; }
.section-label { gap: 24px; }
.section-label > span + span:not(.tiny-star) { text-align: right; }

/* Entrance choreography, scroll-linked timeline, and small ambient details. */
.motion-ready .hero[data-gated]:not(.is-ready) .hero-copy > *,
.motion-ready .hero[data-gated]:not(.is-ready) .avatar { opacity: 0; }
.motion-ready .hero.is-ready .hero-copy > * {
  animation: hero-enter .8s var(--motion-ease) both;
  animation-delay: calc(var(--intro-order, 0) * 95ms);
}
.motion-ready .hero.is-ready .avatar { animation: avatar-enter 1s var(--motion-ease) .25s both; }
.hero-copy > :nth-child(2) { --intro-order: 1; }
.hero-copy > :nth-child(3) { --intro-order: 2; }
.hero-copy > :nth-child(4) { --intro-order: 3; }
.hero-copy > :nth-child(5) { --intro-order: 4; }
.hero-copy > :nth-child(6) { --intro-order: 5; }
.motion-ready .scroll-pill .icon { animation: scroll-hint 2.5s ease-in-out 3; }
.motion-ready .reveal {
  transform: translateY(32px);
  transition: opacity .8s var(--motion-ease), transform .8s var(--motion-ease);
  transition-delay: var(--stagger, 0ms);
}
.motion-ready .reveal.visible { transform: none; }
.motion-ready .interests:not(.visible) .chip,
.motion-ready .stats:not(.visible) > div { opacity: 0; transform: translateY(18px); }
.interests .chip,
.stats > div {
  transition: opacity .6s var(--motion-ease), transform .6s var(--motion-ease);
  transition-delay: var(--stagger, 0ms);
}
.service-card .card-top .icon { transition: transform .4s var(--motion-ease); }
.service-card:hover .card-top .icon { transform: translateY(-3px) rotate(-8deg); }
.service-card.reveal.visible:hover,
.project-card.reveal.visible:hover { transform: translateY(-6px); transition-delay: 0ms; }
.project-art > * { transition: translate .5s var(--motion-ease); }
.project-card:hover .project-art > * { translate: 0 -6px; }
.button .icon { transition: transform .25s var(--motion-ease); }
.button:hover .icon { transform: translate(2px, -2px); }

.timeline::before,
.timeline::after { left: calc(50% - 1px); width: 2px; }
.timeline::after {
  content: '';
  position: absolute;
  inset-block: 0;
  background: linear-gradient(var(--caramel), var(--rust));
  transform: scaleY(var(--timeline-progress, 0));
  transform-origin: top;
  pointer-events: none;
}
.timeline-item::before {
  z-index: 2;
  width: 13px;
  height: 13px;
  left: calc(50% - 6.5px);
  background: var(--cream);
  outline-color: #b59b80;
  transition: background .35s, box-shadow .35s, outline-color .35s;
}
.timeline-item.reached::before {
  background: var(--caramel);
  outline-color: var(--caramel);
  box-shadow: 0 0 0 7px #c4813f18;
}
.motion-ready .timeline-item.reveal { opacity: 1; transform: none; transition: none; }
.motion-ready .timeline-item .timeline-card {
  opacity: 0;
  transform: translate(38px, 20px);
  transition: opacity .85s var(--motion-ease), transform .85s var(--motion-ease), border-color .4s, box-shadow .4s;
}
.motion-ready .timeline-item:nth-child(even) .timeline-card { transform: translate(-38px, 20px); }
.motion-ready .timeline-item .timeline-date {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity .6s ease .15s, transform .6s var(--motion-ease) .15s;
}
.motion-ready .timeline-item.visible .timeline-card,
.motion-ready .timeline-item.visible .timeline-date { opacity: 1; transform: none; }
.timeline-item.reached .timeline-card { border-color: #c99e72; box-shadow: 0 8px 28px #8a54280b; }

@keyframes avatar-enter {
  from { opacity: 0; translate: 0 28px; }
  to { opacity: 1; translate: 0 0; }
}
@keyframes hero-enter {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: none; }
}

@keyframes note-float {
  0%, 100% { transform: translateY(0) rotate(-4deg); }
  50% { transform: translateY(-9px) rotate(-2deg); }
}
@keyframes asterisk-turn {
  from { transform: rotate(13deg); }
  to { transform: rotate(373deg); }
}
@keyframes scroll-hint {
  0%, 50%, 100% { transform: translateY(0); }
  25% { transform: translateY(4px); }
}

@media (max-width: 1100px) {
  .hero { grid-template-columns: 1.15fr 1fr; }
  .hero-title { font-size: 15px; }
  .hero-description { font-size: 17px; }
  .hero .desktop-break { display: none; }
  .affiliation-strip > .container { flex-wrap: wrap; gap: 25px; }
  .affiliation-strip > .container > span:first-child { flex-basis: 100%; max-width: none; text-align: center; }
  .project-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .project-card:last-child { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr 1fr; }
  .project-card:last-child .project-art { height: 100%; min-height: 280px; border-bottom: 0; border-right: 1px solid var(--line); }
  .skills-layout, .contact-grid { gap: 6%; }
  .form-row { grid-template-columns: 1fr; gap: 20px; }
}
@media (max-width: 960px) {
  .main-nav a { font-size: 16px; }
  .hero { grid-template-columns: 1fr 1fr; gap: 4%; }
  .hero-title { font-size: 15px; }
  .hero-description { font-size: 16px; }
  .hero-buttons { flex-wrap: wrap; }
  .hero-buttons .button { padding: 12px 18px; }
  .hero-location { font-size: 12px; }
  .hero-visual { align-self: center; margin-top: 0; }
  .eyebrow { font-size: 11px; line-height: 1.7; }
  .about-grid { gap: 6%; }
  .section-heading { align-items: flex-start; }
  .section-heading > p { max-width: 300px; }
  .desktop-break { display: none; }
  .stats > div { padding-inline: 10px; }
  .timeline-card { padding: 25px; }
  .timeline-item { gap: 40px; }
  .skill-tabs { gap: 20px; }
  .skill-tabs button { font-size: 14px; }
}
@media (max-width: 700px) {
  .hero { display: flex; flex-direction: column; }
  .hero-visual { width: 88%; max-width: 390px; margin-top: 45px; }
  .hero-copy { width: 100%; }
  .about-grid, .skills-layout, .contact-grid { grid-template-columns: 1fr; gap: 30px; }
  .section-heading { display: block; }
  .section-heading > p { max-width: none; margin-top: 22px; }
  .section-heading > .text-link { margin-top: 22px; }
  .project-grid { grid-template-columns: 1fr; }
  .project-card:last-child { display: block; grid-column: auto; }
  .project-card:last-child .project-art { height: 245px; min-height: 0; border-right: 0; border-bottom: 1px solid var(--line); }
}
@media (max-width: 640px) {
  .hero-title { font-size: 16px; }
  .hero-description { font-size: 17px; }
  .hero-location { gap: 6px; }
  .hero-location > span { margin: 0 2px; }
  .hero-buttons { gap: 10px; }
  .hero-buttons .button { gap: 13px; padding: 13px 16px; }
  .hero-visual { width: 92%; }
  .hero-bottom { justify-content: center; }
  .eyebrow { font-size: 11px; letter-spacing: .7px; }
  .affiliation-strip > .container { justify-content: flex-start; padding-inline: 14px; gap: 22px; }
  .affiliation-strip .affiliation { flex-basis: 100%; gap: 15px; }
  .affiliation-strip .strip-divider { display: none; }
  .affiliation-strip > .container > span:first-child { text-align: left; font-size: 12px; }
  .affiliation strong { font-size: 20px; }
  .affiliation small { font-size: 12px; }
  .affiliation > .icon, .york-mark { width: 36px; }
  .chip { font-size: 13px; padding: 8px 12px; }
  .stats > div > span { font-size: 13px; }
  .stats strong { font-size: 48px; }
  .service-grid { grid-template-columns: 1fr; }
  .service-card { padding: 27px; }
  .service-card h3 { font-size: 22px; }
  .card-tags { font-size: 12px; }
  .timeline { padding-left: 26px; }
  .timeline::before, .timeline::after { left: 5px; }
  .timeline-item { gap: 17px; }
  .timeline-item::before { left: -26px; }
  .timeline-card { padding: 24px; }
  .timeline-card h3 { font-size: 22px; }
  .timeline-card .company { font-size: 14px; }
  .timeline-card li { font-size: 16px; }
  .motion-ready .timeline-item .timeline-card,
  .motion-ready .timeline-item:nth-child(even) .timeline-card { transform: translateY(26px); }
  .motion-ready .timeline-item.visible .timeline-card { transform: none; }
  .contact-detail a { overflow-wrap: anywhere; }
  .contact-form .button { font-size: 15px; }
  .footer-top { column-gap: 22px; }
  .footer-top > p { font-size: 16px; flex: 1; }
  .footer-top > p > span { display: block; font-size: 14px; }
  .footer-bottom { font-size: 12px; }
}

@media (prefers-reduced-motion: reduce) {.motion-ready .hero-copy > *,.motion-ready .hero[data-gated]:not(.is-ready) .avatar,.motion-ready .hero.is-ready .avatar,.motion-ready .reveal,.motion-ready .interests .chip,.motion-ready .stats > div,.motion-ready .timeline-item .timeline-card,.motion-ready .timeline-item .timeline-date{ opacity: 1; transform: none; }
  .timeline::after { transform: scaleY(1); }
}
@media print {
  .motion-ready .timeline-item .timeline-card,
  .motion-ready .timeline-item .timeline-date,
  .motion-ready .interests .chip,
  .motion-ready .stats > div { opacity: 1; transform: none; }
  .timeline::after { transform: scaleY(1); }
}

/* North star: the one-line aspiration band between About and What I do. */
.north-star { padding-block: 0 96px; }
.north-star-inner { display: grid; grid-template-columns: 1.05fr 1fr; gap: 6%; align-items: center; }
.north-star h2 { font-size: clamp(32px, 3.6vw, 48px); letter-spacing: -1.2px; text-wrap: balance; }
.north-star-copy { border-left: 1px solid var(--line); padding-left: 34px; }
.north-star-copy p { font-size: var(--text-body); line-height: 1.8; color: var(--muted); margin: 0 0 12px; max-width: 44ch; }
.north-star-copy p:last-child { margin: 0; color: var(--espresso); }

/* Skills as a list of where each tool shipped, not bars. */
.skill-group { margin: 0; padding: 0; list-style: none; min-height: 248px; }
.skill { display: flex; justify-content: space-between; align-items: baseline; gap: 24px; margin: 0; padding: 15px 0; border-bottom: 1px solid #5a4434; }
.skill:last-child { border-bottom: 0; }
.skill-name { font-size: var(--text-body); font-weight: 550; color: #f4e9da; }
.skill-where { font-size: var(--text-small); line-height: 1.55; color: #cdb394; text-align: right; max-width: 58%; }

/* Small additions elsewhere. */
.project-links { margin-top: 18px; }
.company-note { font-weight: 400; color: var(--muted); }
.redstone-mark { width: 30px; height: 30px; flex-shrink: 0; }
.affiliation-strip > .container { gap: 30px; }

@media (max-width: 700px) {
  .north-star { padding-block: 0 70px; }
  .north-star-inner { grid-template-columns: 1fr; gap: 22px; }
  .north-star-copy { border-left: 0; padding-left: 0; }
}
@media (max-width: 640px) {
  .skill { flex-direction: column; align-items: flex-start; gap: 4px; padding: 12px 0; }
  .skill-where { text-align: left; max-width: none; }
}

/* Company links in the hero and timeline, and the linked affiliation. */
.hero-title a, .company a { color: inherit; text-decoration: underline; text-decoration-color: #c9ae8f; text-underline-offset: 3px; transition: color .2s, text-decoration-color .2s; }
.hero-title a:hover, .company a:hover { color: var(--rust); text-decoration-color: var(--rust); }
a.affiliation strong { transition: color .2s; }
a.affiliation:hover strong { color: var(--rust); }

/* Project cards: case studies and the smaller repositories. */
.project-note { margin-top: 16px; font-size: var(--text-label); color: var(--muted); }
.case-study { margin-top: 18px; padding-top: 12px; border-top: 1px solid var(--line); }
.case-study summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 32px; list-style: none; cursor: pointer; font-size: var(--text-small); font-weight: 600; }
.case-study summary::-webkit-details-marker { display: none; }
.case-study summary .icon { width: 16px; height: 16px; color: var(--rust); transition: transform .25s var(--motion-ease); }
.case-study[open] summary .icon { transform: rotate(180deg); }
.case-study summary:hover { color: var(--rust); }
.case-study dl { display: grid; grid-template-columns: max-content 1fr; gap: 10px 18px; margin: 12px 0 2px; font-size: var(--text-small); line-height: 1.6; }
.case-study dt { padding-top: 2px; font-size: var(--text-label); font-weight: 600; letter-spacing: .3px; color: var(--rust); }
.case-study dd { margin: 0; color: var(--muted); }
.more-projects { display: grid; grid-template-columns: 180px 1fr; gap: 24px; margin-top: 44px; padding-top: 28px; border-top: 1px solid var(--line); }
.more-projects > span { padding-top: 5px; font-size: var(--text-label); font-weight: 600; letter-spacing: 1.6px; color: var(--muted); }
.more-projects ul { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin: 0; padding: 0; list-style: none; }
.more-projects li { display: flex; flex-direction: column; gap: 6px; }
.more-projects li a { align-self: flex-start; padding-bottom: 2px; border-bottom: 1px solid #bb9473; font-size: var(--text-body); font-weight: 600; transition: color .2s; }
.more-projects li a:hover { color: var(--rust); }
.more-projects li span { font-size: var(--text-small); line-height: 1.6; color: var(--muted); }
@media (max-width: 800px) {
  .more-projects { grid-template-columns: 1fr; gap: 14px; }
  .more-projects ul { grid-template-columns: 1fr; gap: 16px; }
}
@media (max-width: 640px) {
  .case-study dl { grid-template-columns: 1fr; gap: 2px 0; }
  .case-study dd { margin-bottom: 8px; }
}
