/* ============================================================
   Benedikt Faber — Portfolio
   styles.css — page-specific styles only.
   Nav, footer, variables, reset and base live in shared.css.
   ============================================================ */

/* ============================================================
   GENERIC LAYOUT
   ============================================================ */

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 48px;
}

.section-label {
  display: block;
  font-family: 'DM Sans', sans-serif;
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--color-muted);
}

.section-label.accent {
  color: var(--color-accent);
}

.section-label.on-dark {
  color: var(--color-footer-muted);
}

/* On dark/inverted sections the vermilion accent fails WCAG AA against
   the navy surface. Promote primary labels to the cream surface color. */
.cs-section.bg-dark .section-label.accent {
  color: var(--color-footer-text);
}

h1, h2, h3 {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
}

/* ============================================================
   PLACEHOLDER (shared pattern)
   ============================================================ */

.placeholder {
  background: var(--color-bg-tinted);
  background-image: repeating-linear-gradient(
    45deg,
    var(--color-border) 0px,
    var(--color-border) 1px,
    transparent 1px,
    transparent 8px
  );
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
}

.placeholder-label {
  font-family: 'DM Sans', sans-serif;
  font-weight: 500;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-muted);
  padding: 16px;
  text-align: center;
}

/* When a placeholder holds an actual image, the img fills the wrapper
   edge-to-edge and inherits the 4px corner radius. */
.placeholder > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: inherit;
}

.placeholder.aspect-16-9 { aspect-ratio: 16 / 9; }
.placeholder.aspect-16-8 { aspect-ratio: 16 / 8; }
.placeholder.aspect-16-7 { aspect-ratio: 16 / 7; }
.placeholder.aspect-4-3  { aspect-ratio: 4 / 3; }
.placeholder.aspect-3-4  { aspect-ratio: 3 / 4; }

.placeholder.on-dark {
  background-color: var(--color-dark-border);
  background-image: repeating-linear-gradient(
    45deg,
    #2A3B5C 0px,
    #2A3B5C 1px,
    transparent 1px,
    transparent 8px
  );
}

.placeholder.on-dark .placeholder-label {
  color: var(--color-footer-muted);
  font-weight: 300;
}

/* ============================================================
   HERO (index)
   ============================================================ */

.hero {
  background: var(--color-dark);
  min-height: auto;
  position: relative;
}

.hero-inner {
  position: relative;
  /* No overflow set — the marquee track is clipped by its own wrapper.
     The illustration's right bleed is contained by body { overflow-x: hidden }
     in shared.css, allowing its bottom to extend visually past the hero. */
  display: flow-root;
}

.marquee-wrapper {
  overflow: hidden;
  position: relative;
  z-index: 1;
  width: 100%;
  margin-top: 100px;
}

.marquee-track {
  display: flex;
  width: max-content;
  animation: marquee-scroll 35s linear infinite;
}

.marquee-content {
  font-family: 'Syne', sans-serif;
  font-weight: 800;
  font-size: clamp(64px, 9vw, 120px);
  color: var(--color-footer-text);
  white-space: nowrap;
  padding-right: 80px;
  line-height: 1;
}

@keyframes marquee-scroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

.hero-row {
  max-width: 1200px;
  margin: 0 auto;
  padding: 80px 48px;
  position: relative;
  z-index: 1;
}

.hero-text {
  width: 100%;
}

.hero-h1 {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: clamp(34px, 4.6vw, 56px);
  color: var(--color-footer-text);
  line-height: 1.1;
  letter-spacing: -0.015em;
  max-width: 780px;
}

.hero-sub {
  margin-top: 28px;
  max-width: 640px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: clamp(16px, 1.9vw, 19px);
  color: var(--color-footer-text);
  opacity: 1;
  line-height: 1.7;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-top: 36px;
  padding: 14px 24px;
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: clamp(15px, 1.4vw, 17px);
  letter-spacing: 0.02em;
  color: var(--color-footer-text);
  background: transparent;
  border: 1px solid oklch(96% 0.008 70 / 0.4);
  border-radius: 4px;
  width: fit-content;
  transform-origin: center;
  transition: transform 320ms var(--ease-out-soft),
              color 240ms var(--ease-out-soft),
              background-color 240ms var(--ease-out-soft),
              border-color 240ms var(--ease-out-soft);
}

.hero-cta-label,
.hero-cta-arrow {
  display: inline-block;
  line-height: 1;
}

.hero-cta-arrow {
  transition: transform 240ms var(--ease-out-soft);
}

.hero-cta:hover {
  color: var(--color-footer-text);
  background: transparent;
  border-color: var(--color-accent);
  transform: translateY(-3px) scale(1.1);
}

.hero-cta:hover .hero-cta-arrow {
  transform: translateX(4px);
}

@media (prefers-reduced-motion: reduce) {
  .hero-cta,
  .hero-cta:hover,
  .hero-cta:hover .hero-cta-arrow {
    transform: none;
    transition: color 200ms linear,
                background-color 200ms linear,
                border-color 200ms linear;
  }
}

.faber-def {
  display: inline-block;
  margin-top: 32px;
  border: 1px solid rgba(247, 244, 239, 0.3);
  padding: 14px 18px;
  background: transparent;
}

.faber-def .faber-def-tag {
  display: block;
  font-family: 'DM Sans', sans-serif;
  font-weight: 500;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: rgba(247, 244, 239, 0.6);
}

.faber-def .faber-def-meaning {
  display: block;
  margin-top: 6px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-style: italic;
  font-size: 14px;
  color: var(--color-footer-text);
}

.faber-def .faber-def-meaning .ingenious {
  text-decoration: underline;
  text-decoration-color: rgba(247, 244, 239, 0.5);
  text-underline-offset: 3px;
}

.hero-illustration {
  position: absolute;
  right: 5%;
  top: 15%;
  width: clamp(200px, 25vw, 520px);
  transform: rotate(-2deg);
  z-index: 2;
  display: block;
  height: auto;
}

/* ============================================================
   DESIGN PROCESS
   ============================================================ */

.process {
  /* Fluid sizes — everything in this block scales from these vars,
     so the diagram stays horizontal and legible from 320px up. */
  --circle-size: clamp(56px, 11vw, 110px);
  --icon-size: clamp(22px, 4.4vw, 44px);
  --label-font: clamp(11px, 1.5vw, 18px);
  --label-gap: clamp(10px, 1.5vw, 20px);
  --arrow-max: clamp(20px, 8vw, 100px);
  --iter-overhang: clamp(56px, 8.8vw, 88px);
  --iter-label-font: clamp(9px, 1.2vw, 13px);

  background: var(--color-white);
  /* Top padding compensates for the iterate arrows that overhang the
     diagram, so the gap above matches the gap to the About section. */
  padding: clamp(140px, 18vw, 200px) 0 clamp(80px, 10vw, 120px);
  width: 100%;
}

.process-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 clamp(24px, 4vw, 48px);
}

.process-heading {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: clamp(28px, 4vw, 48px);
  color: var(--color-text);
  line-height: 1.15;
  margin-bottom: clamp(56px, 10vw, 120px);
}

.process-diagram {
  position: relative;
}

/* Wraps the iterate SVG and its HTML labels so they overhang above
   the circles together and scale with --iter-overhang. */
.process-iterate-zone {
  position: absolute;
  top: calc(-1 * var(--iter-overhang) - 8px);
  left: 0;
  width: 100%;
  height: var(--iter-overhang);
  pointer-events: none;
}

.process-iter-label {
  position: absolute;
  top: 0;
  transform: translateX(-50%);
  font-family: 'DM Sans', sans-serif;
  font-weight: 500;
  font-size: var(--iter-label-font);
  letter-spacing: 0.2em;
  color: var(--color-accent);
  text-transform: uppercase;
  white-space: nowrap;
}

.process-iterate {
  position: absolute;
  top: calc(var(--iter-label-font) * 1.4);
  left: 0;
  width: 100%;
  height: calc(100% - var(--iter-label-font) * 1.4);
  color: var(--color-accent);
}

.process-flow {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: clamp(4px, 0.8vw, 8px);
}

.process-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--label-gap);
  flex: 0 0 auto;
  position: relative;
  z-index: 1;
  /* Cap step width so labels can't stretch the column wider than the
     circle itself + a little breathing room. Long labels wrap below. */
  max-width: calc(var(--circle-size) + clamp(8px, 1.4vw, 18px));
}

.process-circle {
  width: var(--circle-size);
  height: var(--circle-size);
  border-radius: 50%;
  background: var(--color-white);
  border: 2px solid var(--color-dark);
  color: var(--color-dark);
  display: flex;
  align-items: center;
  justify-content: center;
}

.process-icon {
  width: var(--icon-size);
  height: var(--icon-size);
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

.process-label {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: var(--label-font);
  color: var(--color-text);
  text-align: center;
  line-height: 1.2;
}

.process-arrow {
  flex: 1;
  max-width: var(--arrow-max);
  height: 2px;
  /* Line + chevron share colour via currentColor so they render at the
     exact same value. */
  color: var(--color-muted);
  background: currentColor;
  border-radius: 1px;
  position: relative;
  /* Center on the circle by going down half the circle's height. */
  margin-top: calc(var(--circle-size) / 2 - 1px);
}

.process-arrow-head {
  position: absolute;
  right: -4px;
  top: 50%;
  width: clamp(9px, 1.4vw, 14px);
  height: clamp(9px, 1.4vw, 14px);
  transform: translateY(-50%);
  overflow: visible;
  color: inherit;
  fill: none;
}

/* ============================================================
   FABER INTERMEZZO
   ============================================================ */

/* Faber etymology occupies the right grid column of the About section:
   sub-headline (centered, smaller than the about h2) + centered făbĕr
   display beneath. No top margin needed — the grid handles placement. */

.about-faber-headline {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: clamp(22px, 2.5vw, 28px);
  color: var(--color-text);
  line-height: 1.3;
  letter-spacing: -0.005em;
  max-width: none;
  text-align: left;
}

.faber-inner {
  max-width: 600px;
  margin: clamp(48px, 8vw, 80px) auto 0;
  text-align: center;
}

.faber-dash {
  display: block;
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: 14px;
  color: var(--color-muted);
  margin-bottom: 32px;
}

.faber-word {
  display: block;
  font-family: 'Syne', sans-serif;
  font-weight: 800;
  font-size: clamp(48px, 8vw, 96px);
  color: var(--color-accent);
  line-height: 1;
}

.faber-latin {
  display: block;
  margin-top: 16px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 500;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--color-muted);
}

.faber-meaning {
  display: block;
  margin-top: 8px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: 24px;
  color: var(--color-text);
}

.faber-meaning .made {
  text-decoration: underline;
  text-decoration-color: var(--color-accent);
  text-underline-offset: 4px;
}

/* ============================================================
   WORK
   ============================================================ */

.work {
  background: var(--color-bg);
  padding: 100px 0 160px;
}

.work-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 48px;
}

.work-label {
  margin-bottom: 48px;
}

.work-heading {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: clamp(32px, 4vw, 48px);
  color: var(--color-text);
  line-height: 1.15;
  letter-spacing: -0.01em;
  margin-top: 20px;
  margin-bottom: 56px;
}

.work-feature {
  display: block;
  margin-bottom: 80px;
  transition: transform 320ms var(--ease-out-soft);
}

.work-feature:hover {
  transform: translateY(-6px);
}

.work-feature:active {
  transform: translateY(-6px) scale(0.995);
  transition: transform 140ms var(--ease-out-soft);
}

.work-feature-meta {
  margin-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  flex-wrap: wrap;
}

.work-feature-title {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 22px;
  color: var(--color-text);
  transition: color 0.25s ease;
}

.work-feature:hover .work-feature-title {
  color: var(--color-accent);
}

.work-feature-desc {
  margin-top: 8px;
  max-width: 520px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: 16px;
  color: var(--color-muted);
  line-height: 1.65;
}

.work-feature-tag {
  font-family: 'DM Sans', sans-serif;
  font-weight: 500;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-muted);
  white-space: nowrap;
}

.work-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(56px, 7vw, 96px) clamp(32px, 4vw, 56px);
  align-items: start;
}

.work-card {
  display: flex;
  flex-direction: column;
  gap: 24px;
  transition: transform 320ms var(--ease-out-soft);
}

.work-card:hover {
  transform: translateY(-6px);
}

.work-card:active {
  transform: translateY(-6px) scale(0.995);
  transition: transform 140ms var(--ease-out-soft);
}

/* Typographic poster tile. Acts as a slot — today it carries display
   type; when a real screenshot is ready, swap the inner content for
   an <img> and the system holds. */
.work-card-tile {
  width: 100%;
  aspect-ratio: 4 / 3;
  background: var(--color-bg-tinted);
  border-radius: 4px;
  padding: clamp(22px, 2.6vw, 36px);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: clamp(8px, 1vw, 12px);
  position: relative;
  overflow: hidden;
  transition: background 320ms var(--ease-out-soft);
}

.work-card-tile-eyebrow {
  font-family: 'DM Sans', sans-serif;
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-accent);
}

.work-card-tile-name {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: clamp(28px, 3.6vw, 52px);
  line-height: 1;
  letter-spacing: -0.01em;
  color: var(--color-text);
  transition: color 240ms var(--ease-out-soft);
}

.work-card:hover .work-card-tile-name {
  color: var(--color-accent);
}

/* Image-led variant: tile becomes a pure image holder. The eyebrow +
   name live below the tile in .work-card-header (tighter than the
   parent's 24px gap so they read as a unit). */
.work-card-tile:has(> img) {
  padding: 0;
}

.work-card-tile > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.work-card-header {
  display: flex;
  flex-direction: column;
  gap: clamp(8px, 1vw, 12px);
}

/* In-progress variant — same dimensions, muted name. When the tile is
   empty, a hairline surround stands in for the missing image; when an
   image is present (.work-card-tile:has(> img)), the outline drops so
   the image reads clean to the corners. The eyebrow + name below carry
   the state label either way. */
.work-card-progress .work-card-tile {
  background: transparent;
  outline: 1px solid var(--color-border);
  outline-offset: -1px;
}

.work-card-progress .work-card-tile:has(> img) {
  outline: none;
}

.work-card-progress .work-card-tile-name {
  color: var(--color-muted);
}

.work-card-progress:hover .work-card-tile-name {
  color: var(--color-text);
}

.work-card-tag {
  font-family: 'DM Sans', sans-serif;
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-muted);
}

.work-card-desc {
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: 16px;
  color: var(--color-text);
  line-height: 1.65;
  max-width: 56ch;
}

/* ============================================================
   QUOTE INTERMEZZO
   ============================================================ */

.quote-section {
  background: var(--color-bg-tinted);
  padding: 100px 48px;
}

.quote-inner {
  max-width: 720px;
  margin: 0 auto;
  text-align: center;
}

.quote-dash {
  display: block;
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: 14px;
  color: var(--color-muted);
  margin-bottom: 24px;
}

.quote-body {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: clamp(24px, 4vw, 42px);
  color: var(--color-text);
  line-height: 1.25;
}

.quote-attr {
  margin-top: 20px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: 13px;
  color: var(--color-muted);
}

/* ============================================================
   ABOUT
   ============================================================ */

.about {
  background: var(--color-white);
  min-height: 75dvh;
  display: flex;
  align-items: center;
}

.about-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 80px 48px clamp(140px, 18vw, 200px);
  width: 100%;
}

.about-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 80px;
  align-items: start;
}

.about-cv-col .about-subheading {
  margin-top: 0;
}

.about-label {
  margin-bottom: 32px;
}

.about-headline {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: clamp(30px, 4vw, 52px);
  color: var(--color-text);
  line-height: 1.15;
  letter-spacing: -0.01em;
  max-width: 680px;
  margin-top: 20px;
  margin-bottom: 56px;
}

.about-body {
  max-width: 640px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.about-body p {
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: 16px;
  line-height: 1.8;
  color: var(--color-text);
}

.about-subheading {
  display: block;
  margin-top: 56px;
  margin-bottom: 20px;
}

/* Achievements row sits below the about-grid as a full-width band.
   Eyebrow + horizontal card grid; mobile stacks to a single column. */
.about-achievements {
  margin-top: clamp(80px, 12vw, 120px);
}

.about-achievements .section-label {
  display: block;
  margin-bottom: 32px;
}

.cv-list {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

/* Hoverable achievement card: transparent fill, muted hairline border,
   vermilion border + lift on hover (matches the .work-card pop). */
.cv-item {
  padding: 24px;
  border: 1px solid var(--color-border);
  border-radius: 4px;
  background: transparent;
  transition: border-color 240ms var(--ease-out-soft),
              transform 320ms var(--ease-out-soft);
}

.cv-item:hover {
  border-color: var(--color-accent);
  transform: translateY(-6px);
}

.cv-item:active {
  transform: translateY(-6px) scale(0.995);
  transition: transform 140ms var(--ease-out-soft);
}

.cv-item-title {
  font-family: 'DM Sans', sans-serif;
  font-weight: 500;
  font-size: 15px;
  color: var(--color-text);
  line-height: 1.4;
}

.cv-item-subtitle {
  margin-top: 4px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: 14px;
  color: var(--color-muted);
  line-height: 1.55;
}

.about-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.tag {
  border: 1px solid var(--color-border);
  padding: 7px 16px;
  border-radius: 100px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.06em;
  color: var(--color-muted);
  background: transparent;
}

/* Nav + footer are owned by shared.css. */

/* ============================================================
   CASE STUDY — shared
   ============================================================ */

.back-link {
  display: block;
  padding: 32px 48px 0;
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: 13px;
  color: var(--color-muted);
  transition: color 0.25s ease;
  max-width: 1200px;
  margin: 0 auto;
}

.back-link:hover {
  color: var(--color-text);
}

/* Case study hero */

.cs-hero {
  background: var(--color-bg);
  width: 100%;
  padding: 100px 0 80px;
}

.cs-hero-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 48px;
}

.cs-tagline {
  max-width: 720px;
}

.cs-hero-grid {
  margin-top: 48px;
  padding-top: 40px;
  border-top: 1px solid var(--color-border);
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: 80px;
  align-items: start;
}

.cs-title {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: clamp(40px, 11vw, 112px);
  color: var(--color-text);
  line-height: 1;
  letter-spacing: -0.01em;
  margin-top: 20px;
  overflow-wrap: anywhere;
}

.cs-tagline {
  margin-top: 16px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: 24px;
  color: var(--color-text);
  line-height: 1.5;
}

.cs-blurb {
  margin-top: 8px;
  max-width: none;
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: 18px;
  color: var(--color-muted);
  line-height: 1.6;
}

.cs-meta {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.cs-meta-item-label {
  display: block;
}

.cs-meta-item-value {
  display: block;
  margin-top: 6px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: 14px;
  color: var(--color-text);
}

.cs-hero-image {
  margin-top: 0;
  width: 100%;
}

.cs-hero-image img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 4px;
}

/* Generic case study section */

.cs-section {
  width: 100%;
  padding: 100px 0;
}

.cs-section-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 48px;
}

.cs-section.bg-white { background: var(--color-white); }
.cs-section.bg-bg { background: var(--color-bg); }
.cs-section.bg-tinted { background: var(--color-bg-tinted); }
.cs-section.bg-dark { background: var(--color-dark); }

.cs-h2 {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: clamp(32px, 5vw, 52px);
  color: var(--color-text);
  line-height: 1.15;
  margin-top: 20px;
}

.cs-h2.on-dark { color: var(--color-footer-text); }

.cs-h3 {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 22px;
  color: var(--color-text);
  line-height: 1.25;
}

.cs-body {
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: 16px;
  color: var(--color-text);
  line-height: 1.8;
}

.cs-body.muted { color: var(--color-muted); }
.cs-body.smaller { font-size: 16px; line-height: 1.8; }

.cs-intro {
  margin-top: 32px;
  max-width: none;
  font-weight: 300;
  font-size: clamp(19px, 2.2vw, 27px);
  line-height: 1.4;
  letter-spacing: -0.005em;
}

/* Section 02 — problem stats + quotes */

.problem-stats {
  margin-top: 56px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px;
  align-items: start;
}

.stat-block {
  border-top: 2px solid var(--color-border);
  padding-top: 24px;
}

.problem-quote {
  margin-top: 48px;
}

.stat-number {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 64px;
  color: var(--color-accent);
  line-height: 1;
}

.stat-text {
  margin-top: 12px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: 16px;
  color: var(--color-muted);
  line-height: 1.55;
}

/* Editorial pull-quote: vermilion display glyph as the leading
   affordance, italic body. No card surround, no side stripe. */
.cs-quote {
  position: relative;
  margin: 40px 0;
  padding: 28px 0 8px 64px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-style: italic;
  font-size: 18px;
  color: var(--color-text);
  line-height: 1.7;
  background: transparent;
  border: none;
  border-radius: 0;
}

.cs-quote::before {
  content: '\201C';
  position: absolute;
  left: 0;
  top: -8px;
  font-family: 'Syne', sans-serif;
  font-weight: 800;
  font-size: 80px;
  line-height: 1;
  color: var(--color-accent);
}

.cs-quote.small {
  margin: 28px 0;
  padding: 22px 0 4px 52px;
  font-size: 16px;
}

.cs-quote.small::before {
  font-size: 60px;
}

/* Dark surface — italic body shifts to cream; vermilion glyph stays. */
.cs-section.bg-dark .cs-quote {
  color: var(--color-footer-text);
}

/* Quote with attribution wrapper. */
.cs-quote-figure {
  margin: 0;
}

.cs-quote-figure .cs-quote {
  margin-bottom: 8px;
}

.cs-quote-attr {
  padding-left: 64px;
  margin-bottom: 32px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-muted);
}

.cs-quote-figure .cs-quote.small + .cs-quote-attr {
  padding-left: 52px;
  margin-bottom: 24px;
}

.cs-section.bg-dark .cs-quote-attr {
  color: var(--color-footer-muted);
}

.problem-close {
  margin-top: 64px;
  padding-top: 40px;
  border-top: 1px solid var(--color-border);
  max-width: none;
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: clamp(19px, 2.2vw, 27px);
  letter-spacing: -0.005em;
  color: var(--color-text);
  line-height: 1.35;
}

/* ============================================================
   PROBLEM FLOW DIAGRAM
   Five-step adoption journey with the two critical moments
   highlighted in vermilion. Continuous hairline connects the
   markers; critical steps gain an eyebrow + detail line beneath.
   ============================================================ */

.problem-flow-section {
  margin-top: 80px;
}

.problem-flow-heading {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: clamp(22px, 2.8vw, 32px);
  color: var(--color-text);
  line-height: 1.25;
  letter-spacing: -0.01em;
  max-width: none;
  margin-bottom: 56px;
}

.problem-flow {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: clamp(12px, 2vw, 32px);
  position: relative;
}

.problem-flow::before {
  content: '';
  position: absolute;
  left: 10%;
  right: 10%;
  top: 11px;
  height: 2px;
  background: var(--color-border);
  z-index: 0;
}

.problem-flow-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 14px;
  position: relative;
  z-index: 1;
}

.problem-flow-node {
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.problem-flow-marker {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--color-border);
  box-shadow: 0 0 0 4px var(--color-white);
}

.problem-flow-step-critical .problem-flow-marker {
  background: var(--color-accent);
  width: 18px;
  height: 18px;
}

.problem-flow-label {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: clamp(14px, 1.4vw, 18px);
  color: var(--color-text);
  line-height: 1.3;
  letter-spacing: -0.005em;
}

.problem-flow-step-critical .problem-flow-label {
  color: var(--color-accent);
}

.problem-flow-eyebrow {
  margin-top: 6px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--color-accent);
}

.problem-flow-detail {
  font-family: 'DM Sans', sans-serif;
  font-weight: 400;
  font-size: clamp(14px, 1.3vw, 16px);
  color: var(--color-text);
  line-height: 1.45;
  max-width: 22ch;
}

/* Mobile: flow rotates into a left-axis vertical timeline. Markers
   sit on a fixed left axis, content (label + eyebrow + detail) flows
   to the right of each marker. The connector is composed of per-step
   segments running from this marker's center to the next, so it
   terminates cleanly at the first and last markers with no stubs. */
@media (max-width: 768px) {
  .problem-flow {
    grid-template-columns: 1fr;
    gap: 36px;
    padding-left: 40px;
  }

  .problem-flow::before {
    display: none;
  }

  .problem-flow-step:not(:last-child)::after {
    content: '';
    position: absolute;
    left: -29px;
    top: 12px;
    height: calc(100% + 36px);
    width: 2px;
    background: var(--color-border);
    z-index: 0;
  }

  .problem-flow-step {
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
    gap: 6px;
    position: relative;
  }

  .problem-flow-node {
    position: absolute;
    left: -40px;
    top: 0;
    width: 24px;
  }

  .problem-flow-eyebrow {
    margin-top: 0;
  }

  .problem-flow-detail {
    max-width: none;
  }
}

/* Section 03 — Decisions */

.decision-block {
  border-top: 1px solid var(--color-border);
  padding: 48px 0;
  display: flex;
  gap: 80px;
  align-items: flex-start;
}

.decision-block:first-of-type {
  margin-top: 64px;
}

.decision-left {
  flex: 0 0 30%;
}

.decision-left .cs-h3 {
  margin-top: 12px;
}

.decision-right {
  flex: 1;
}

.decision-image {
  margin-top: 32px;
}

/* Section 04 — Solution */

.solution-block {
  border-top: 1px solid var(--color-border);
  padding-top: 48px;
  padding-bottom: 48px;
  display: flex;
  gap: 80px;
  align-items: center;
}

.solution-block:first-of-type {
  margin-top: 80px;
}

.solution-text {
  flex: 0 0 40%;
}

.solution-text .cs-h3 {
  margin-top: 12px;
}

.solution-text .cs-body {
  margin-top: 16px;
  color: var(--color-text);
  font-size: 16px;
  line-height: 1.8;
}

.solution-image {
  flex: 1;
}

.extra-screens {
  margin-top: 64px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}

/* Videos in the extra-screens grid sit inside a .video-frame container
   that enforces the 3:4 portrait shape and clips overflow. The whole
   frame lifts on hover — same pop language as the work cards. */
.video-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 3 / 4;
  border-radius: 4px;
  overflow: hidden;
  background: var(--color-border);
  transition: transform 320ms var(--ease-out-soft);
}

.video-frame:hover {
  transform: translateY(-6px);
}

.video-frame:active {
  transform: translateY(-6px) scale(0.995);
  transition: transform 140ms var(--ease-out-soft);
}

.video-frame video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Full-area click button. Dark scrim makes the paused state read as
   "click me"; the "See it in motion" label sits in the top-left corner. */
.video-play-overlay {
  position: absolute;
  inset: 0;
  padding: 0;
  margin: 0;
  background: oklch(15% 0.025 262 / 0.45);
  border: none;
}

.video-frame.is-playing .video-play-overlay {
  display: none;
}

.video-play-label {
  position: absolute;
  top: clamp(20px, 2.5vw, 32px);
  left: clamp(20px, 2.5vw, 32px);
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: clamp(14px, 1.4vw, 17px);
  letter-spacing: 0.02em;
  color: var(--color-footer-text);
  line-height: 1;
}

.proto-link {
  margin-top: 48px;
  display: inline-flex;
  align-items: center;
  gap: 16px;
  border: 1px solid var(--color-border);
  border-radius: 4px;
  padding: 24px 32px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 500;
  font-size: 15px;
  color: var(--color-text);
  transform-origin: center;
  transition: transform 320ms var(--ease-out-soft),
              border-color 240ms var(--ease-out-soft);
}

.proto-link:hover {
  border-color: var(--color-accent);
  transform: translateY(-3px) scale(1.1);
}

.proto-link .arrow {
  color: var(--color-accent);
  display: inline-block;
  transition: transform 240ms var(--ease-out-soft);
}

.proto-link:hover .arrow {
  transform: translateX(4px);
}

@media (prefers-reduced-motion: reduce) {
  .proto-link,
  .proto-link:hover,
  .proto-link:hover .arrow {
    transform: none;
    transition: border-color 200ms linear;
  }
}

/* Section 05 — Testing (inverted) */

.testing-grid {
  margin-top: 64px;
  display: flex;
  gap: 80px;
  align-items: flex-start;
}

.testing-col {
  flex: 1;
}

.testing-body {
  margin-top: 20px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: 16px;
  color: var(--color-text);
  line-height: 1.8;
}

.change-list {
  margin-top: 20px;
}

.change-item {
  border-top: 1px solid var(--color-border);
  padding-top: 20px;
  margin-top: 20px;
}

.change-item:first-child {
  border-top: 0;
  padding-top: 0;
  margin-top: 0;
}

.change-lead {
  font-family: 'DM Sans', sans-serif;
  font-weight: 500;
  font-size: 16px;
  color: var(--color-text);
  line-height: 1.8;
}

.change-rest {
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: 16px;
  color: var(--color-muted);
  line-height: 1.8;
}

.before-after {
  margin-top: 64px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}

.before-after-item .section-label {
  display: block;
  margin-bottom: 16px;
}

/* Section 06 — AI */

.ai-section {
  background: var(--color-white);
  width: 100%;
  padding: 100px 0;
}

/* ============================================================
   DESIGN SECTION
   ============================================================ */

.design-grid {
  margin-top: 56px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px 48px;
}

/* First block (Typography) spans the full grid width as a feature row.
   Remaining four fall into the 2x2 below. */
.design-block-feature {
  grid-column: 1 / -1;
}

.design-block {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.design-block-text {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

@media (max-width: 768px) {
  .design-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
}

.ai-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 48px;
}

.ai-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 80px;
  align-items: start;
}

.ai-text-col {
  max-width: 640px;
}

.ai-image-col {
  width: 100%;
}

.ai-body {
  margin-top: 32px;
  max-width: 640px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.ai-body p {
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: 16px;
  color: var(--color-text);
  line-height: 1.8;
}

/* ============================================================
   PERSONA CARD
   ============================================================ */

.persona-card {
  margin-top: 56px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: start;
}

.persona-profile {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.persona-image-frame {
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 4px;
  background: var(--color-border);
}

.persona-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.persona-meta {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.persona-name {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 32px;
  color: var(--color-text);
  line-height: 1.1;
}

.persona-facts {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: 16px;
  color: var(--color-muted);
  line-height: 1.55;
}

.persona-attrs {
  display: flex;
  flex-direction: column;
  gap: 40px;
}

.persona-attr {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.persona-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: 16px;
  color: var(--color-text);
  line-height: 1.65;
  padding-left: 20px;
}

.persona-list li {
  position: relative;
}

/* Small accent dash bullet */
.persona-list li::before {
  content: '';
  position: absolute;
  left: -20px;
  top: 0.55em;
  width: 10px;
  height: 2px;
  background: var(--color-accent);
}

.persona-list strong {
  font-weight: 500;
  color: var(--color-text);
}

@media (max-width: 768px) {
  .persona-card {
    grid-template-columns: 1fr;
    gap: 40px;
    margin-top: 40px;
  }

  .persona-attrs {
    gap: 32px;
  }
}

/* ============================================================
   IMPRESSUM
   ============================================================ */

.impressum {
  background: var(--color-bg);
  width: 100%;
  padding: clamp(80px, 12vw, 140px) 0 clamp(80px, 10vw, 120px);
}

.impressum-inner {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 clamp(24px, 4vw, 48px);
}

.impressum-title {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: clamp(40px, 6vw, 72px);
  color: var(--color-text);
  line-height: 1.1;
  margin-bottom: clamp(40px, 5vw, 64px);
}

.impressum-section {
  margin-bottom: 40px;
}

.impressum-section:last-child {
  margin-bottom: 0;
}

.impressum-h2 {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 20px;
  color: var(--color-text);
  margin-bottom: 12px;
  line-height: 1.25;
}

.impressum-section p {
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: 16px;
  color: var(--color-text);
  line-height: 1.75;
}

.impressum-section a {
  color: var(--color-text);
  text-decoration: underline;
  text-decoration-color: var(--color-accent);
  text-underline-offset: 3px;
  transition: color 0.25s ease;
}

.impressum-section a:hover {
  color: var(--color-accent);
}

/* Impressum link in the footer-bottom row */
.footer-bottom-link {
  text-decoration: none;
  transition: color 0.25s ease;
}

.footer-bottom-link:hover {
  color: var(--color-accent);
}

/* ============================================================
   PLACEHOLDER PROJECT PAGE
   ============================================================ */

.placeholder-page-body {
  background: var(--color-white);
  width: 100%;
  padding: 180px 0 160px;
}

.placeholder-page-inner {
  max-width: 560px;
  margin: 0 auto;
  text-align: center;
  padding: 0 48px;
}

.placeholder-page-inner .section-label {
  margin-bottom: 24px;
}

.placeholder-page-title {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 32px;
  color: var(--color-text);
}

.placeholder-page-body p {
  margin-top: 16px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: 16px;
  color: var(--color-muted);
  line-height: 1.7;
}

.placeholder-back {
  display: block;
  margin-top: 40px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  font-size: 15px;
  color: var(--color-accent);
}

/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 1024px) {
  .hero-row,
  .work-inner,
  .container,
  .cs-section-inner,
  .cs-hero-inner,
  .ai-inner,
  .placeholder-page-inner {
    padding-left: 32px;
    padding-right: 32px;
  }
  .back-link {
    padding-left: 32px;
    padding-right: 32px;
  }

  /* Hide the bobblehead on viewports too narrow to host it without
     overlapping the text column. Below 1024 the hero is text-only. */
  .hero-illustration {
    display: none;
  }

  .hero-h1 { max-width: 100%; }
  .hero-sub { max-width: 100%; }
}

@media (max-width: 768px) {
  /* Hero — illustration hidden, content row full width */
  .hero-row {
    padding: 48px 24px 56px;
    padding-right: 24px;
  }

  .hero-illustration {
    display: none;
  }

  .hero-h1 { max-width: 100%; }
  .hero-sub { max-width: 100%; }

  /* Faber intermezzo padding now scales via clamp() on the desktop rule;
     no mobile override needed. */

  /* Work */
  .work {
    padding: 80px 0 128px;
  }

  .work-inner {
    padding: 0 24px;
  }

  .work-grid {
    grid-template-columns: 1fr;
  }

  .work-feature-meta {
    flex-direction: column;
    align-items: flex-start;
  }

  /* Quote */
  .quote-section {
    padding: 80px 24px;
  }

  /* About */
  .about-inner {
    padding: 64px 24px clamp(100px, 16vw, 140px);
  }

  .about-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }

  .cv-list {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  /* Case study — vertical padding on section, horizontal on inner */
  .cs-hero,
  .cs-section,
  .ai-section {
    padding: 72px 0;
  }

  .cs-hero-inner,
  .cs-section-inner,
  .ai-inner {
    padding: 0 24px;
  }

  .back-link {
    padding: 24px 24px 0;
  }

  .decision-block,
  .solution-block,
  .testing-grid {
    flex-direction: column;
    gap: 32px;
  }

  .problem-stats {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .ai-grid,
  .cs-hero-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }

  .cs-hero-grid .cs-meta {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 24px 40px;
  }

  .extra-screens,
  .before-after {
    grid-template-columns: 1fr;
  }

  .cs-meta {
    gap: 24px 40px;
  }

  .placeholder-page-body {
    padding: 96px 0;
  }

  .placeholder-page-inner {
    padding: 0 24px;
  }
}
