/* Personal portfolio: a navy landing area and cool, readable evidence catalogue. */
.portfolio-landing {
  --display: "Manrope Local", "Avenir Next", sans-serif;
  --surface-radius: 14px;
}

.portfolio-landing .shell { width: min(1320px, calc(100% - 64px)); }
.portfolio-landing h2 { font-size: clamp(2rem, 3.4vw, 3.4rem); line-height: 1.1; }
.portfolio-landing .button svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; }
.action-arrow { display: inline-block; width: 18px; height: 18px; flex-shrink: 0; vertical-align: middle; fill: none; stroke: currentColor; stroke-width: 1.7; }

.landing-hero {
  position: relative;
  isolation: isolate;
  display: block;
  overflow: hidden;
  min-height: 0;
  padding: clamp(32px, 3.5vw, 52px) 0 24px;
  background: #1c3762;
  color: var(--ink);
  --ink: #f7fbfe;
  --muted: #ccdeec;
  --accent: #5ed0ff;
  --focus: #9edfff;
}
.landing-hero .button.primary { background: #00adf1; border-color: #00adf1; color: #102a43; }
.landing-hero .button.primary:hover { background: #6bd2f7; border-color: #6bd2f7; }
.landing-hero .button.ghost { color: #f7fbfe; border-color: #bed0e1; }
.landing-hero .button.ghost:hover { background: #294d75; }
.landing-hero .lede { color: var(--muted); }

.flow-backdrop {
  position: absolute;
  z-index: -1;
  inset: 0;
  width: 100%;
  height: 100%;
  color: var(--accent);
  pointer-events: none;
}
.flow-backdrop path { stroke: currentColor; stroke-width: 1; opacity: .12; }
.flow-backdrop .flow-signal {
  opacity: .5;
  stroke-width: 2;
  stroke-dasharray: 95 2300;
  animation: source-flow 18s linear infinite;
  animation-play-state: paused;
}
[data-background-running="true"] .flow-signal { animation-play-state: running; }
@keyframes source-flow { from { stroke-dashoffset: 2395; } to { stroke-dashoffset: 0; } }

.landing-hero .hero-grid {
  grid-template-columns: minmax(0, .86fr) minmax(0, 1.32fr);
  gap: clamp(32px, 4vw, 64px);
  align-items: center;
}
.landing-hero h1 {
  max-width: none;
  margin-bottom: 28px;
  font-size: clamp(2.5rem, 3.55vw, 3.6rem);
  font-weight: 760;
  letter-spacing: -.04em;
  line-height: 1.12;
}
.landing-hero h1 span { color: var(--accent); }
.landing-hero .lede { max-width: 44ch; font-size: clamp(1rem, 1.2vw, 1.1rem); line-height: 1.75; }
.landing-hero .hero-actions { gap: 10px; margin-top: 30px; }
.hero-bottom { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-top: 24px; }
.hero-bottom > a { font-size: .82rem; font-weight: 700; text-decoration: none; padding-block: 12px; }
.hero-bottom > a:hover { text-decoration: underline; }
.motion-toggle { min-height: 44px; padding: 8px 0 8px 12px; background: transparent; color: var(--muted); border: 0; font-size: .72rem; cursor: pointer; }
.motion-toggle:hover { color: var(--ink); text-decoration: underline; }

.screening-room {
  min-width: 0;
  overflow: hidden;
  border-radius: var(--surface-radius);
  background: #102a43;
  color: #f7fbfe;
  box-shadow: 0 26px 64px rgb(16 42 67 / 19%);
}
.screening-tabs { display: flex; gap: 0; padding: 6px 12px 0; border-bottom: 1px solid #44627c; }
.screening-tabs button {
  position: relative;
  flex: 1;
  min-height: 48px;
  border: 0;
  padding: 12px 8px;
  background: transparent;
  color: #bed0e1;
  font-size: .76rem;
  font-weight: 750;
  cursor: pointer;
}
.screening-tabs button[aria-pressed="true"] { color: #fff; }
.screening-tabs button[aria-pressed="true"]::after { content: ""; position: absolute; bottom: -1px; left: 12px; right: 12px; height: 3px; border-radius: 3px; background: #5ed0ff; }
.screening-tabs button:hover { color: #fff; background: #214966; }
.screening-room :focus-visible { outline-color: #9edfff; outline-offset: -4px; }
.screening-media { position: relative; display: block; aspect-ratio: 16 / 10; padding: 18px 18px 0; overflow: hidden; background: #dce6ef; }
.screening-media img, .screening-media video { width: 100%; height: 100%; object-fit: cover; object-position: top left; border-radius: 6px 6px 0 0; background: #111; }
.screening-media video { object-fit: cover; background: #dce6ef; }
.screening-media:has(video[data-started]) { padding: 0; background: #111; }
.screening-media video[data-started] { object-fit: contain; background: #111; border-radius: 0; }
.screening-play {
  position: absolute;
  inset: auto auto 24px 28px;
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 52px;
  padding: 12px 18px;
  border: 0;
  border-radius: 8px;
  background: #16395d;
  color: #fff;
  box-shadow: 0 6px 22px rgb(0 0 0 / 24%);
  font-size: .85rem;
  font-weight: 750;
  cursor: pointer;
  transition: background-color 180ms, transform 240ms var(--ease-out);
}
.screening-play:hover { background: #16456b; transform: translateY(-3px); }
.screening-play:disabled { cursor: progress; background: #44627c; transform: none; }
.screening-play svg { width: 20px; height: 20px; fill: currentColor; }
.screening-caption { display: flex; justify-content: space-between; align-items: center; gap: 20px; min-height: 94px; padding: 20px 24px; }
.screening-caption strong { display: block; font-size: .88rem; line-height: 1.5; font-weight: 700; }
.screening-caption div > span { display: block; margin-top: 5px; color: #bed0e1; font-size: .71rem; }
.screening-caption a { flex-shrink: 0; display: flex; align-items: center; min-height: 44px; gap: 8px; font-size: .75rem; text-decoration: none; }
.screening-caption a:hover { text-decoration: underline; }
.video-transcript { border-top: 1px solid #44627c; padding: 0 24px; }
.video-transcript summary { min-height: 44px; padding: 12px 0; cursor: pointer; color: #bed0e1; font-size: .71rem; }
.video-transcript p { padding-bottom: 4px; font-size: .8rem; line-height: 1.7; color: #eee; }
.screening-error { padding: 20px; color: #fff; font-size: .85rem; }

.portfolio-landing .selected-work { padding-block: 62px 78px; border-top: 1px solid var(--line); }
.portfolio-landing .section-intro--stacked { display: flex; max-width: none; align-items: end; justify-content: space-between; gap: 44px; margin-bottom: 32px; }
.portfolio-landing .section-intro h2 { flex-shrink: 0; max-width: 15ch; margin-bottom: 0; }
.portfolio-landing .section-intro p { max-width: 50ch; font-size: .95rem; }
.portfolio-landing .selected-grid--shelf { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; max-width: none; }
.portfolio-landing .selected-card { border: 0; border-radius: 0; background: transparent; overflow: visible; }
.portfolio-landing .selected-card-content { display: flex; height: 100%; flex-direction: column; }
.portfolio-landing .selected-grid--shelf .project-media { border: 0; border-radius: var(--surface-radius); padding: 24px 16px 0; aspect-ratio: 1.48; }
.portfolio-landing .project-media img { border: 0; border-radius: 7px 7px 0 0; transition: transform 650ms var(--ease-out); }
.portfolio-landing .selected-grid--shelf .project-copy { padding: 22px 0 0; flex: 1; }
.portfolio-landing .project-title-line h3 { font-size: clamp(1.4rem, 2vw, 2rem); font-weight: 780; }
.portfolio-landing .project-audience { color: var(--muted); font-size: .78rem; margin-top: 14px; }
.portfolio-landing .project-summary { font-size: .92rem; line-height: 1.65; }
.portfolio-landing .selected-grid--shelf .project-proof { margin: 18px 0 8px; }
.portfolio-landing .project-proof > div { display: grid; grid-template-columns: 80px 1fr; gap: 10px; }
.portfolio-landing .project-proof dt { font-size: .68rem; font-weight: 650; }
.portfolio-landing .project-proof dd { line-height: 1.5; font-weight: 600; }
.project-technology { margin: 10px 0 18px; font-size: .68rem; color: var(--muted); }
.project-actions { display:flex; flex-wrap:wrap; align-items:center; gap:4px 22px; margin-top:auto; }
.portfolio-landing .project-link, .project-capture-link { color:var(--accent); font-size:.8rem; text-underline-offset:4px; }
.project-capture-link { display:inline-flex; align-items:center; min-height:44px; padding-block:10px; font-weight:650; }
.portfolio-landing .project-actions .project-link { margin-top:0; }
.portfolio-landing .selected-card:hover { transform: none; box-shadow: none; }
.portfolio-landing .decision-contract { padding-block: 76px; }
.portfolio-landing .contract-intro { max-width: none; display: grid; grid-template-columns: .9fr 1.1fr; align-items: start; gap: 40px; }
.portfolio-landing .contract-intro h2 { max-width: 13ch; }
.portfolio-landing .contract-intro p { font-size: .95rem; }
.portfolio-landing .contract-workbench { margin-top: 30px; border: 0; border-radius: var(--surface-radius); }
.portfolio-landing .contract-node { border-radius: 10px; }
.portfolio-landing .capability-store { padding-block: 72px; }
.portfolio-landing .capability-routes strong { font-size: 1.45rem; }
.portfolio-landing .capability-routes a { min-height: 102px; }
.portfolio-landing .capability-routes span { font-size: .9rem; }
.portfolio-landing .closing { padding-block: 64px; }
.portfolio-landing .closing h2 { max-width: none; }
.portfolio-landing .closing p { max-width: 67ch; font-size: .95rem; }
.about-background { display: grid; grid-template-columns: 1.2fr 1fr; gap: 26px; margin: 26px 0 0; padding-top: 20px; border-top: 1px solid var(--line); }
.about-background dt { margin-bottom: 6px; color: var(--muted); font-size: .75rem; font-weight: 700; }
.about-background dd { margin: 0; font-size: .8rem; line-height: 1.7; }
.portfolio-landing .all-work-link { margin-bottom: 0; }

@media (min-width: 981px) {
  .screening-media { aspect-ratio: auto; height: clamp(270px, 24vw, 355px); }
  .screening-caption { min-height: 78px; padding-block: 14px; }
  .portfolio-landing .selected-card-content .project-copy { display: flex; flex-direction: column; }
  .portfolio-landing .project-audience { min-height: 2.9em; }
  .portfolio-landing .project-summary { min-height: 4.95em; }
  .portfolio-landing .project-link { margin-top: auto; }
}
@media (max-width: 1100px) and (min-width: 981px) {
  .landing-hero .hero-grid { grid-template-columns: .9fr 1.1fr; gap: 26px; }
  .landing-hero h1 { font-size: 2.5rem; }
  .screening-caption { padding: 16px; gap: 12px; }
}
@media (max-width: 980px) {
  .landing-hero { padding-top: 52px; }
  .landing-hero .hero-grid { grid-template-columns: 1fr; gap: 36px; }
  .landing-hero .hero-copy { max-width: 670px; }
  .landing-hero h1 { font-size: clamp(2.6rem, 6vw, 3.6rem); }
  .landing-hero .lede { max-width: 60ch; }
  .screening-room { max-width: 780px; width: 100%; }
  .portfolio-landing .selected-grid--shelf { grid-template-columns: 1fr; gap: 34px; }
  .portfolio-landing .selected-card-content { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 30px; }
  .portfolio-landing .selected-grid--shelf .project-copy { padding: 0; }
  .portfolio-landing .contract-intro { grid-template-columns: 1fr; gap: 8px; }
}
@media (max-width: 720px) {
  .portfolio-landing .topbar { gap:12px; }
  .portfolio-landing .nav-links { gap:10px; }
  .portfolio-landing .nav-links a { font-size:.75rem; white-space:nowrap; }
  .portfolio-landing .nav-links a:nth-child(3) { display:inline-flex; }
}
@media (max-width: 640px) {
  .portfolio-landing .shell { width: calc(100% - 32px); }
  .landing-hero { padding-top: 40px; }
  .landing-hero h1 { font-size: clamp(2rem, 7.7vw, 3rem); letter-spacing: -.035em; margin-bottom: 22px; }
  .landing-hero .lede { font-size: .98rem; line-height: 1.7; }
  .landing-hero .hero-actions { flex-wrap: wrap; gap: 8px; }
  .landing-hero .hero-actions { flex-direction: row; }
  .landing-hero .hero-actions .button { width: auto; min-width: 0; flex: 1; padding-inline: 10px; font-size: .78rem; }
  .hero-bottom { margin-top: 24px; display: block; }
  .hero-bottom > a { display: block; }
  .motion-toggle { padding-left: 0; }
  .screening-tabs { padding-inline: 5px; }
  .screening-tabs button { font-size: .69rem; padding-inline: 5px; }
  .screening-media { padding: 10px 10px 0; }
  .screening-play { inset: auto auto 16px 16px; min-height: 46px; padding: 10px 12px; font-size: .74rem; }
  .screening-caption { display: block; padding: 18px 18px 8px; min-height: 122px; }
  .screening-caption strong { font-size: .82rem; }
  .screening-caption div > span { font-size: .67rem; }
  .screening-caption a { font-size: .72rem; }
  .video-transcript { padding-inline: 18px; }
  .portfolio-landing .section-intro--stacked { display: block; margin-bottom: 28px; }
  .portfolio-landing .section-intro h2 { margin-bottom: 14px; }
  .portfolio-landing .selected-work { padding-block: 44px 54px; }
  .portfolio-landing .selected-card-content { display: flex; gap: 0; }
  .portfolio-landing .selected-grid--shelf .project-copy { padding-top: 20px; }
  .portfolio-landing .selected-grid--shelf .project-media { aspect-ratio: 1.55; width: 100%; }
  .portfolio-landing .project-title-line h3 { font-size: 1.65rem; }
  .portfolio-landing .decision-contract, .portfolio-landing .capability-store { padding-block: 52px; }
  .portfolio-landing .contract-intro h2 { max-width: none; }
  .about-background { grid-template-columns: 1fr; gap: 16px; }
  .portfolio-landing .capability-routes a { grid-template-columns: 1fr; gap: 10px; padding-block: 22px; }
  .portfolio-landing .capability-routes small { grid-column: 1; }
}
@media (prefers-reduced-motion: reduce) {
  .flow-backdrop .flow-signal { animation: none; stroke-dasharray: none; opacity: .12; }
  .portfolio-landing *, .portfolio-landing *::after { transition-duration: 0s !important; }
}
@media print {
  .landing-hero { background: transparent; --ink: #152b47; --muted: #506278; --accent: #006b95; }
  .flow-backdrop, .hero-bottom, .screening-play, .screening-tabs { display: none; }
  .landing-hero .hero-grid { display: block; }
  .screening-room { box-shadow: none; break-inside: avoid; }
}
