/* ============================================
   Anna Quintero — Product Designer Portfolio
   Style guide: Nordic Forest —
   Deep Pine / Forest Moss / Sage Mist / Warm Stone /
   Linen / Snow / White. Newsreader + Work Sans.
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Newsreader:ital,wght@0,400;0,500;0,600;1,400;1,500&family=Work+Sans:wght@300;400;500;600;700&display=swap');

:root {
  /* Nordic Forest palette */
  --color-deep-pine: #051211;
  --color-forest-moss: #34564D;
  --color-sage-mist: #A8B8A0;
  --color-warm-stone: #B8A58D;
  --color-linen: #E8E1D5;
  --color-snow: #F7F5EF;
  --color-white: #FFFFFF;
  --color-muted: #6E7C74;
  --color-ui-purple: #6848F8;
  --color-ui-blue: #2850D0;
  --color-ui-steel-blue: #5E90B5;

  /* Semantic aliases */
  --bg: var(--color-snow);
  --alt-bg: var(--color-linen);
  --surface: var(--color-white);
  --primary: var(--color-deep-pine);
  --primary-hover: var(--color-forest-moss);
  --secondary-text: var(--color-forest-moss);
  --accent-on-dark: var(--color-sage-mist);
  --tag-accent: var(--color-warm-stone);
  --text: var(--color-deep-pine);
  --border: rgba(18, 43, 42, 0.12);

  --font-display: 'Newsreader', Georgia, serif;
  --font-body: 'Work Sans', -apple-system, BlinkMacSystemFont, sans-serif;

  --measure: 64ch;
  --section-pad: clamp(4rem, 9vw, 8rem);
  --gutter: clamp(1.5rem, 5vw, 4rem);

  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 28px;
  --radius-pill: 999px;

  --shadow-sm: 0 1px 2px rgba(18, 43, 42, 0.06);
  --shadow-md: 0 8px 24px rgba(18, 43, 42, 0.08);
  --shadow-lg: 0 24px 48px rgba(18, 43, 42, 0.12);

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in: cubic-bezier(0.7, 0, 0.84, 0);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
}

@keyframes reveal-up {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  margin: 0;
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--secondary-text);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }

a {
  color: var(--primary);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
  transition: color .18s var(--ease-out);
}
a:hover { color: var(--secondary-text); }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-style: normal;
  color: var(--text);
  margin: 0;
  line-height: 1.15;
  font-weight: 500;
}

p { margin: 0 0 1em; }

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -3rem;
  background: var(--primary);
  color: var(--color-snow);
  padding: .75rem 1.25rem;
  border-radius: var(--radius-pill);
  font-weight: 600;
  z-index: 100;
  transition: top .2s var(--ease-out);
}
.skip-link:focus { top: 1rem; }

:focus-visible {
  outline: 3px solid var(--color-forest-moss);
  outline-offset: 3px;
}

/* ---------- Layout helpers ---------- */
.wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--secondary-text);
  margin-bottom: 0.9rem;
}

.eyebrow::before {
  content: "";
  display: inline-block;
  width: 20px;
  height: 1px;
  background: currentColor;
  flex-shrink: 0;
}

/* ---------- Nav ---------- */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 40;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.site-nav .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 1.1rem;
  padding-bottom: 1.1rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.3rem;
  color: var(--text);
  text-decoration: none;
  letter-spacing: 0.005em;
  transition: color .18s var(--ease-out);
}

.brand:hover { color: var(--secondary-text); }

.nav-links {
  display: flex;
  align-items: center;
  gap: clamp(1.25rem, 3vw, 2.25rem);
  list-style: none;
  margin: 0;
  padding: 0;
  font-weight: 500;
  font-size: 0.95rem;
}

.nav-links a {
  text-decoration: none;
  color: var(--secondary-text);
  padding: 0.4rem 0.1rem;
  border-bottom: 2px solid transparent;
  transition: color .18s var(--ease-out), border-bottom-color .18s var(--ease-out);
}

.nav-links a:hover,
.nav-links a[aria-current="page"] {
  color: var(--primary);
  border-bottom-color: var(--color-warm-stone);
}

.nav-toggle { display: none; }
.nav-backdrop { display: none; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.96rem;
  padding: 0.85rem 1.75rem;
  border-radius: var(--radius-pill);
  border: 1.5px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: background .18s var(--ease-out), border-color .18s var(--ease-out);
}

.btn-primary {
  background: var(--primary);
  color: var(--color-snow);
}
.btn-primary:hover { background: var(--primary-hover); color: var(--color-snow); }

.btn-outline {
  background: transparent;
  border-color: var(--primary);
  color: var(--primary);
}
.btn-outline:hover { background: color-mix(in srgb, var(--primary) 6%, transparent); color: var(--primary); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  background: var(--bg);
  color: var(--text);
  padding: clamp(4.5rem, 12vw, 7.5rem) 0 clamp(4rem, 9vw, 6rem);
}

.hero-inner {
  position: relative;
  z-index: 1;
  max-width: 760px;
}

.hero-inner > * {
  animation: reveal-up .7s var(--ease-out) both;
}
.hero-inner > *:nth-child(1) { animation-delay: 0ms; }
.hero-inner > *:nth-child(2) { animation-delay: 80ms; }
.hero-inner > *:nth-child(3) { animation-delay: 160ms; }
.hero-inner > *:nth-child(4) { animation-delay: 240ms; }
.hero-inner > *:nth-child(5) { animation-delay: 320ms; }

.hero h1 {
  color: var(--text);
  font-size: clamp(2.4rem, 5.6vw, 4.75rem);
  font-weight: 500;
}

.hero h1 em {
  font-style: italic;
  font-weight: 400;
  color: var(--text);
  transition: color .18s var(--ease-out);
}

.hero h1 em:hover {
  color: #5D7871;
}

.hero-sub {
  margin-top: 1.5rem;
  font-size: clamp(1.05rem, 2vw, 1.19rem);
  color: var(--color-muted);
  max-width: 52ch;
}

.hero-tags-wrap {
  margin-top: 2rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.marquee-viewport {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  border-radius: var(--radius-pill);
  -webkit-mask-image: linear-gradient(to right, transparent 0, black 28px, black calc(100% - 28px), transparent 100%);
  mask-image: linear-gradient(to right, transparent 0, black 28px, black calc(100% - 28px), transparent 100%);
}

.marquee-track {
  display: flex;
  flex-wrap: nowrap;
  width: max-content;
  animation: marquee 64s linear infinite;
  animation-play-state: running;
}

.marquee-viewport:hover .marquee-track,
.marquee-viewport:focus-within .marquee-track,
.marquee-viewport.is-paused .marquee-track {
  animation-play-state: paused;
}

.marquee-toggle {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--color-white);
  color: var(--secondary-text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  cursor: pointer;
  transition: color .18s var(--ease-out), border-color .18s var(--ease-out);
}
.marquee-toggle:hover { color: var(--primary); border-color: var(--primary); }
.marquee-toggle svg { width: 11px; height: 11px; }
.marquee-toggle .icon-play { display: none; }
.marquee-toggle[aria-pressed="true"] .icon-pause { display: none; }
.marquee-toggle[aria-pressed="true"] .icon-play { display: block; }

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

.hero-tags {
  display: flex;
  flex-wrap: nowrap;
  gap: 0.6rem;
  font-size: 0.85rem;
  font-weight: 500;
  margin: 0;
  padding: 0;
  padding-right: 0.6rem;
}

.hero-tags li {
  list-style: none;
  background: var(--color-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  padding: 0.5rem 1rem;
  color: var(--secondary-text);
  white-space: nowrap;
  flex-shrink: 0;
  box-shadow: var(--shadow-sm);
}

.hero-actions {
  margin-top: 2.75rem;
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

/* ---------- Work section ---------- */
#work {
  background: var(--alt-bg);
}

.section-head {
  padding-top: var(--section-pad);
  padding-bottom: clamp(2rem, 4vw, 3rem);
}

.section-head > * {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity .6s var(--ease-out), transform .6s var(--ease-out);
}
.section-head.is-visible > * { opacity: 1; transform: translateY(0); }
.section-head > *:nth-child(1) { transition-delay: 0ms; }
.section-head > *:nth-child(2) { transition-delay: 90ms; }

.section-head h2 {
  font-size: clamp(1.9rem, 4vw, 2.75rem);
  max-width: 20ch;
}

.section-head p {
  margin-top: 1rem;
  max-width: 56ch;
  font-size: 1.05rem;
  color: var(--color-muted);
}

.projects {
  display: flex;
  flex-direction: column;
  gap: clamp(1.5rem, 3vw, 2rem);
  padding-bottom: var(--section-pad);
}

.project-card {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  align-items: stretch;
  border-radius: var(--radius-lg);
  overflow: hidden;
  min-height: 420px;
  background: var(--surface);
  border: none;
  box-shadow: var(--shadow-md);
  color: var(--text);
  opacity: 0;
  transform: translateY(20px);
  transition: opacity .6s var(--ease-out), transform .6s var(--ease-out), box-shadow .2s var(--ease-out);
}
.project-card.is-visible { opacity: 1; transform: translateY(0); }
.project-card.is-visible:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }

.project-info {
  padding: clamp(2rem, 4vw, 3.25rem);
  display: flex;
  flex-direction: column;
  justify-content: center;
  cursor: pointer;
}

.project-index {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.2rem;
  color: var(--tag-accent);
  margin-bottom: 0.75rem;
  display: block;
}

.project-tags {
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--secondary-text);
  margin-bottom: 1.1rem;
}

.project-info h3 {
  font-size: clamp(1.8rem, 3.4vw, 2.6rem);
  color: inherit;
  margin-bottom: 1rem;
}

.project-info p {
  font-size: 1.02rem;
  max-width: 42ch;
  color: var(--color-muted);
}

.project-link {
  margin-top: 1.5rem;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  color: var(--primary);
  text-decoration: underline;
  text-underline-offset: 4px;
  width: fit-content;
  transition: color .18s var(--ease-out);
}
.project-link:hover { color: var(--secondary-text); }

.project-visual {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  background: var(--color-linen);
}

.project-visual--accent {
  background: var(--color-ui-purple);
}

.project-visual--accent-blue {
  background: var(--color-ui-blue);
}

.project-visual--accent-steel-blue {
  background: var(--color-ui-steel-blue);
}

.project-visual .placeholder-frame {
  width: 100%;
  max-width: 320px;
  aspect-ratio: 3 / 4;
  border: 1.5px dashed var(--border);
  border-radius: var(--radius-md);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  text-align: center;
  padding: 1.5rem;
  background: var(--color-white);
  color: var(--color-muted);
}

.placeholder-frame .frame-icon {
  width: 42px;
  height: 42px;
  opacity: 0.7;
}

.placeholder-frame span {
  font-size: 0.85rem;
  font-weight: 600;
  opacity: 0.85;
}

.laptop-mock {
  width: 100%;
  max-width: 420px;
  margin: 0 auto;
}

.laptop-screen {
  position: relative;
  background: #1c1c1e;
  border-radius: 13px;
  padding: 9px 9px 5px;
  box-shadow: var(--shadow-lg);
}

.laptop-screen::before {
  content: "";
  position: absolute;
  top: 4px;
  left: 50%;
  transform: translateX(-50%);
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #3a3a3c;
}

.laptop-screen img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  object-position: top;
  border-radius: 3px;
}

.laptop-base {
  position: relative;
  height: 13px;
  background: linear-gradient(180deg, #ececee, #cfcfd2);
  border-radius: 0 0 9px 9px;
}

.laptop-base::after {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 70px;
  height: 5px;
  background: #b6b6ba;
  border-radius: 0 0 5px 5px;
}

/* ---------- Closing / contact (the one dark, full-bleed moment) ---------- */
.closing {
  background:
    linear-gradient(100deg, rgba(18,43,42,0.90), rgba(18,43,42,0.74)),
    url('../images/closing-bg.jpg');
  background-size: cover;
  background-position: center;
  color: var(--color-snow);
  padding: var(--section-pad) 0;
  position: relative;
}

.closing .wrap {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 3rem;
  flex-wrap: wrap;
}

.closing-copy { max-width: 640px; }

.closing-copy > * {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity .6s var(--ease-out), transform .6s var(--ease-out);
}
.closing-copy.is-visible > * { opacity: 1; transform: translateY(0); }
.closing-copy > *:nth-child(1) { transition-delay: 0ms; }
.closing-copy > *:nth-child(2) { transition-delay: 90ms; }
.closing-copy > *:nth-child(3) { transition-delay: 180ms; }

.closing h2 {
  font-size: clamp(1.9rem, 3.6vw, 2.6rem);
  color: var(--color-snow);
  line-height: 1.3;
  max-width: 22ch;
}

.closing p {
  margin-top: 1.25rem;
  max-width: 48ch;
  font-size: 1.05rem;
  color: color-mix(in srgb, var(--color-snow) 82%, transparent);
}

.closing-actions {
  margin-top: 2rem;
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.closing .btn-primary {
  background: var(--color-snow);
  color: var(--primary);
}
.closing .btn-primary:hover { background: var(--color-linen); color: var(--primary); }

.closing .btn-outline {
  border-color: var(--color-snow);
  color: var(--color-snow);
}
.closing .btn-outline:hover { background: color-mix(in srgb, var(--color-snow) 12%, transparent); color: var(--color-snow); }

.closing :focus-visible {
  outline-color: var(--color-sage-mist);
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--color-linen);
  color: var(--secondary-text);
  padding: 2.25rem 0;
  font-size: 0.9rem;
  border-top: 1px solid var(--border);
}

.site-footer .wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.site-footer .brand { color: var(--text); }

.footer-links {
  display: flex;
  gap: 1.5rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.footer-links a {
  text-decoration: none;
  color: var(--secondary-text);
  transition: color .18s var(--ease-out);
}
.footer-links a:hover { color: var(--primary); }

/* ---------- About page ---------- */
.about-hero {
  padding: clamp(3.5rem, 8vw, 6rem) 0 clamp(3rem, 6vw, 4.5rem);
}

.about-hero .wrap {
  display: grid;
  grid-template-columns: 0.9fr 1.4fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
}

.about-hero .wrap > .about-photo-wrap,
.about-hero .wrap > div:last-child > * {
  animation: reveal-up .7s var(--ease-out) both;
}
.about-hero .wrap > .about-photo-wrap { animation-delay: 0ms; position: sticky; top: 6.5rem; }
.about-hero .wrap > div:last-child > *:nth-child(1) { animation-delay: 100ms; }
.about-hero .wrap > div:last-child > *:nth-child(2) { animation-delay: 150ms; }
.about-hero .wrap > div:last-child > *:nth-child(3) { animation-delay: 200ms; }
.about-hero .wrap > div:last-child > *:nth-child(4) { animation-delay: 250ms; }
.about-hero .wrap > div:last-child > *:nth-child(5) { animation-delay: 300ms; }
.about-hero .wrap > div:last-child > *:nth-child(6) { animation-delay: 350ms; }

.about-photo-wrap {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
}

.about-photo-wrap img {
  border-radius: var(--radius-lg);
  width: 100%;
  object-fit: cover;
  aspect-ratio: 4 / 5;
}

.about-hero h1 {
  font-size: clamp(2.2rem, 5vw, 3.4rem);
}

.about-hero .intro {
  margin-top: 1.25rem;
  font-size: 1.15rem;
  color: var(--color-muted);
  max-width: 60ch;
}

.about-highlights {
  display: flex;
  flex-wrap: wrap;
  gap: 1.75rem;
  margin-top: 1.5rem;
  padding: 1.1rem 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.highlight-item {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.highlight-item strong {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 400;
  font-size: 1.35rem;
  color: var(--primary);
  line-height: 1;
}

.highlight-item span {
  font-size: 0.82rem;
  color: var(--color-muted);
}

.about-hero .about-body {
  margin-top: 1.1rem;
  font-size: 1.05rem;
  color: var(--secondary-text);
  max-width: 60ch;
}

.about-label {
  display: block;
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 0.35rem;
}

.about-hero .about-body em {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--primary);
}

/* ---------- Resume page ---------- */
.resume-section {
  padding: clamp(2.5rem, 6vw, 4rem) 0 var(--section-pad);
}

.resume-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
  margin-bottom: clamp(1.5rem, 4vw, 2.5rem);
}

.resume-head .eyebrow { margin-bottom: 0.6rem; }

.resume-head h1 {
  font-size: clamp(1.9rem, 4vw, 2.5rem);
}

.resume-embed {
  width: 100%;
  height: 85vh;
  border: none;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  background: var(--color-white);
}

.resume-hint {
  margin-top: 1rem;
  text-align: center;
  font-size: 0.92rem;
  color: var(--color-muted);
}

/* ---------- Case study page ---------- */
.case-hero {
  padding: clamp(3rem, 7vw, 5rem) 0 clamp(2.5rem, 5vw, 3.5rem);
}

.case-back {
  display: flex;
  width: fit-content;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--secondary-text);
  text-decoration: none;
  margin-bottom: 1.75rem;
  transition: color .18s var(--ease-out);
}
.case-back:hover { color: var(--primary); }

.case-hero .eyebrow { margin-bottom: 0.6rem; }

.case-hero h1 {
  font-size: clamp(2.2rem, 5vw, 3.4rem);
}

.case-hero-sub {
  margin-top: 1.1rem;
  font-size: 1.12rem;
  color: var(--color-muted);
  max-width: 64ch;
}

.case-meta {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  margin-top: 2.25rem;
  padding-top: 1.75rem;
  border-top: 1px solid var(--border);
}

.case-meta-item strong {
  display: block;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 0.4rem;
}

.case-meta-item span {
  font-size: 0.95rem;
  color: var(--secondary-text);
}

.case-jumpnav {
  position: sticky;
  top: 65px;
  z-index: 30;
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}

.case-jumpnav-inner {
  display: flex;
  gap: clamp(1.1rem, 3vw, 2rem);
  overflow-x: auto;
  padding-top: 0.9rem;
  padding-bottom: 0.9rem;
  scrollbar-width: none;
}
.case-jumpnav-inner::-webkit-scrollbar { display: none; }

.case-jumpnav a {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--secondary-text);
  text-decoration: none;
  white-space: nowrap;
  padding: 0.3rem 0.1rem;
  border-bottom: 2px solid transparent;
  transition: color .18s var(--ease-out), border-color .18s var(--ease-out);
}
.case-jumpnav a:hover { color: var(--primary); border-bottom-color: var(--color-warm-stone); }

.case-hero,
.case-section {
  scroll-margin-top: 8.5rem;
}

.case-media { padding: 0 0 var(--section-pad); }

.case-diagram-embed {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border);
}

.case-diagram-embed iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.laptop-mock--lg {
  max-width: 720px;
  margin: 0 auto;
}

.case-cover-panel {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-ui-purple);
  border-radius: var(--radius-lg);
  padding: clamp(2.5rem, 6vw, 4rem);
  margin-bottom: clamp(2.5rem, 6vw, 3.5rem);
}

.case-cover-panel--blue {
  background: var(--color-ui-blue);
}

.case-cover-panel--steel-blue {
  background: var(--color-ui-steel-blue);
}

.case-section--cover {
  padding-top: 0;
  border-top: none;
}

.zoomable {
  cursor: zoom-in;
}
.zoomable:focus-visible {
  outline: 3px solid var(--color-forest-moss);
  outline-offset: 4px;
  border-radius: 13px;
}

.lightbox-overlay {
  position: fixed;
  inset: 0;
  background: rgba(5, 18, 17, 0.88);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(1.5rem, 5vw, 3rem);
  z-index: 200;
  opacity: 0;
  overflow: auto;
  transition: opacity .2s var(--ease-out);
}
.lightbox-overlay[hidden] { display: none; }
.lightbox-overlay.is-open { opacity: 1; }

.lightbox-overlay img {
  max-width: 92vw;
  max-height: 88vh;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  display: block;
  margin: auto;
  cursor: zoom-in;
}

.lightbox-overlay.is-zoomed {
  align-items: flex-start;
  justify-content: flex-start;
}

.lightbox-overlay.is-zoomed img {
  max-width: none;
  max-height: none;
  cursor: zoom-out;
}

.lightbox-close {
  position: absolute;
  top: clamp(1rem, 4vw, 1.75rem);
  right: clamp(1rem, 4vw, 1.75rem);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--color-white);
  color: var(--text);
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: var(--shadow-md);
  transition: background .18s var(--ease-out);
}
.lightbox-close:hover { background: var(--color-linen); }
.lightbox-close svg { width: 20px; height: 20px; }

.photo-spot {
  border: 1.5px dashed var(--border);
  border-radius: var(--radius-lg);
  background: var(--color-white);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  color: var(--color-muted);
  text-align: center;
  padding: 3rem 1.5rem;
  aspect-ratio: 16 / 9;
}
.photo-spot .frame-icon { width: 44px; height: 44px; opacity: 0.6; }
.photo-spot span { font-size: 0.9rem; font-weight: 600; max-width: 32ch; }

.case-compare {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(1rem, 3vw, 1.5rem);
}

.case-compare--steel-blue {
  --case-accent: var(--color-ui-steel-blue);
}

.case-compare--blue {
  --case-accent: var(--color-ui-blue);
}

.case-compare-item {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.case-compare-label {
  margin: 0;
  text-align: center;
  font-size: 0.85rem;
  color: var(--color-muted);
}

.case-compare-label strong {
  font-weight: 600;
}

.case-compare-caption {
  margin: 0;
  font-size: 0.85rem;
  color: var(--color-muted);
  line-height: 1.5;
  text-align: center;
  max-width: none;
}

.case-compare-item .zoomable {
  display: block;
  cursor: zoom-in;
  background: var(--case-accent, var(--color-ui-steel-blue));
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  box-shadow: var(--shadow-sm);
}

.case-compare-item img {
  width: 100%;
  display: block;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
}

.case-gallery {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: start;
  gap: clamp(1rem, 3vw, 1.5rem);
}

.case-gallery--flow {
  grid-template-columns: repeat(3, 1fr);
}

.case-gallery-item-wrap {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.case-gallery-item-label {
  margin: 0;
  text-align: center;
  font-size: 0.85rem;
  color: var(--color-muted);
}

.case-gallery-item {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 3 / 2;
  cursor: zoom-in;
  border-radius: var(--radius-lg);
  background: var(--color-ui-steel-blue);
  padding: 1rem;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.case-gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.case-section {
  padding: var(--section-pad) 0;
  border-top: 1px solid var(--border);
}

.case-section-inner { max-width: 70ch; }

.case-section h2 {
  font-size: clamp(1.6rem, 3vw, 2.1rem);
  margin-bottom: 1.5rem;
}

.case-subhead {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--primary);
  margin: 2.25rem 0 0.85rem;
}
.case-subhead:first-of-type { margin-top: 0; }

.case-section p {
  font-size: 1.02rem;
  color: var(--secondary-text);
  max-width: 68ch;
}

.case-section ul,
.case-section ol {
  margin: 0 0 1.25rem;
  padding-left: 1.25rem;
  color: var(--secondary-text);
  font-size: 1.02rem;
}
.case-section li { margin-bottom: 0.6rem; }
.case-section li:last-child { margin-bottom: 0; }
.case-section li strong { color: var(--text); }

.case-callout {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  padding: clamp(1.75rem, 4vw, 2.5rem);
  box-shadow: var(--shadow-sm);
  font-size: 1.1rem;
  color: var(--text);
  max-width: none;
}
.case-callout p { max-width: none; }
.case-callout p:last-child { margin-bottom: 0; }

.case-status {
  background: var(--alt-bg);
  border-left: 3px solid var(--tag-accent);
  border-radius: var(--radius-sm);
  padding: 1.5rem 1.75rem;
  margin-top: 1.5rem;
}
.case-status p { margin-bottom: 0; max-width: none; }
.case-status p:not(:last-child) { margin-bottom: 0.85rem; }

.case-status-cite {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--color-muted);
}

/* ---------- DC mockup: live evidence-request modal recreation ---------- */
.dc-mock {
  font-family: 'Public Sans', sans-serif;
  background: #fffefc;
  border-radius: 24px;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

.dc-mock-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 28px 36px;
  border-bottom: 1px solid #ece9f7;
  background: linear-gradient(180deg, #fbfaff, #ffffff);
}
.dc-mock-header-left { display: flex; align-items: center; gap: 16px; min-width: 0; }
.dc-mock-icon {
  width: 44px; height: 44px;
  border-radius: 12px;
  background: rgba(29, 78, 216, 0.1);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.dc-mock-eyebrow {
  font-family: 'Manrope', sans-serif;
  font-weight: 600;
  font-size: 12px;
  letter-spacing: 0.08em;
  color: #1D4ED8;
  text-transform: uppercase;
  margin-bottom: 2px;
}
.dc-mock-title {
  font-family: 'Manrope', sans-serif;
  font-weight: 700;
  font-size: 22px;
  color: #221f3d;
}
.dc-mock-close {
  width: 36px; height: 36px;
  border-radius: 10px;
  border: none;
  background: #f4f2fb;
  color: #6b6690;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  transition: background .15s var(--ease-out), color .15s var(--ease-out);
}
.dc-mock-close:hover { background: #eae6f9; color: #221f3d; }

.dc-mock-body { display: flex; }
.dc-mock-main { flex: 1; min-width: 0; padding: 28px 36px; max-height: 640px; overflow-y: auto; }
.dc-mock-intro { margin: 0 0 24px; font-size: 14px; color: #726d94; line-height: 1.6; }

.dc-mock-card {
  border: 1px solid #ece9f7;
  border-radius: 16px;
  padding: 22px 24px;
  margin-bottom: 20px;
  background: #fdfcff;
}
.dc-mock-card-head { display: flex; align-items: center; justify-content: space-between; gap: .75rem; margin-bottom: 16px; }
.dc-mock-card-head-left { display: flex; align-items: center; gap: 8px; }
.dc-mock-card-title { font-family: 'Manrope', sans-serif; font-weight: 700; font-size: 16px; color: #221f3d; }
.dc-mock-meta { font-size: 12px; color: #a29fc0; white-space: nowrap; }

.dc-mock-q-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: 16px; }
.dc-mock-q { border: 1px solid #f1eff8; border-radius: 12px; overflow: hidden; }
.dc-mock-q-row {
  display: flex; align-items: center; gap: 10px;
  width: 100%;
  padding: 13px 16px;
  background: #fff;
  border: none;
  text-align: left;
  font: inherit;
  color: inherit;
}
.dc-mock-q-row.is-toggle { cursor: pointer; }
.dc-mock-chevron { width: 14px; flex-shrink: 0; color: #a29fc0; display: flex; transition: transform .15s var(--ease-out); }
.dc-mock-chevron.is-hidden { opacity: 0; }
.dc-mock-chevron.is-open { transform: rotate(90deg); }
.dc-mock-q-text { flex: 1; font-size: 13.5px; font-weight: 700; color: #3d3a57; }
.dc-mock-badge { font-size: 11.5px; font-weight: 700; padding: 4px 10px; border-radius: 100px; white-space: nowrap; }
.dc-mock-q-body { display: none; padding: 0 16px 16px 40px; background: #fff; }
.dc-mock-q.is-open .dc-mock-q-body { display: block; }
.dc-mock-q-body p { margin: 0; font-size: 13px; color: #726d94; line-height: 1.65; }

.dc-mock-persys { display: flex; flex-direction: column; gap: 10px; }
.dc-mock-persys-item { border: 1px solid #f1eff8; border-radius: 10px; padding: 11px 14px; }
.dc-mock-persys-head { display: flex; align-items: center; gap: 8px; margin-bottom: 4px; }
.dc-mock-persys-icon { flex-shrink: 0; width: 24px; height: 24px; border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.dc-mock-persys-name { font-size: 13px; font-weight: 700; color: #3d3a57; }
.dc-mock-persys-item p { margin: 0; font-size: 12.5px; color: #726d94; line-height: 1.6; }

.dc-mock-rerun {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: inherit; font-size: 13px; font-weight: 600; color: #5c5780;
  background: none; border: none; padding: 0; cursor: pointer;
}

.dc-mock-scope-desc { margin: 0 0 16px; font-size: 13.5px; color: #726d94; line-height: 1.6; }
.dc-mock-scope-row { display: flex; align-items: center; gap: 10px; padding: 10px 2px; border-bottom: 1px solid #f1eff8; }
.dc-mock-dot { width: 6px; height: 6px; border-radius: 50%; flex-shrink: 0; }
.dc-mock-scope-name { font-size: 13.5px; font-weight: 600; color: #3d3a57; flex: 1; }
.dc-mock-scope-count { font-size: 12.5px; color: #a29fc0; font-weight: 600; }
.dc-mock-scope-row.is-out .dc-mock-scope-name,
.dc-mock-scope-row.is-out .dc-mock-scope-count { color: #b23a3a; }
.dc-mock-oos-tag { font-weight: 500; color: #c47a7a; }
.dc-mock-oos-icon { flex-shrink: 0; color: #b23a3a; display: flex; }

.dc-mock-dropzone {
  display: flex; align-items: center; gap: 10px;
  padding: 14px 16px;
  border: 1.5px dashed #1D4ED8;
  border-radius: 12px;
  background: rgba(29, 78, 216, 0.1);
  margin-bottom: 14px;
}
.dc-mock-dropzone span { font-size: 13.5px; font-weight: 600; color: #1D4ED8; }

.dc-mock-file { display: flex; align-items: center; gap: 12px; padding: 11px 4px; border-bottom: 1px solid #f1eff8; }
.dc-mock-file-icon { flex-shrink: 0; }
.dc-mock-file-name { flex: 1; font-size: 13.5px; color: #3d3a57; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dc-mock-file-tag-wrap {
  position: relative;
  display: inline-flex;
  flex-shrink: 0;
  border-radius: 100px;
  padding: 1.5px;
  background: linear-gradient(90deg, #7C3AED, #2563EB);
}
.dc-mock-file-select {
  appearance: none;
  font-family: 'Public Sans', sans-serif;
  font-size: 11px;
  font-weight: 700;
  color: #1D4ED8;
  background: #eef2ff;
  border: none;
  padding: 4px 22px 4px 9px;
  border-radius: 100px;
  white-space: nowrap;
  cursor: pointer;
}
.dc-mock-file-select.is-oos { color: #b23a3a; background: #fbe4e4; }
.dc-mock-file-edit-icon {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  color: #1D4ED8;
  opacity: 0;
  transition: opacity .15s var(--ease-out);
}
.dc-mock-file-select.is-oos ~ .dc-mock-file-edit-icon { color: #b23a3a; }
.dc-mock-file-tag-wrap:hover .dc-mock-file-edit-icon,
.dc-mock-file-tag-wrap:focus-within .dc-mock-file-edit-icon {
  opacity: 1;
}
.dc-mock-file-date { font-size: 12px; color: #a29fc0; white-space: nowrap; }
.dc-mock-file-trash { cursor: pointer; flex-shrink: 0; color: #c7c3dd; }

.dc-mock-notes-label { font-family: 'Manrope', sans-serif; font-weight: 700; font-size: 14px; color: #221f3d; margin-bottom: 8px; }
.dc-mock-textarea {
  width: 100%; min-height: 76px;
  border: 1px solid #ece9f7; border-radius: 12px;
  padding: 12px 14px;
  font-family: 'Public Sans', sans-serif; font-size: 13.5px; color: #3d3a57;
  resize: vertical;
  background: #fdfcff;
}

.dc-mock-sidebar { width: 380px; flex-shrink: 0; border-left: 1px solid #ece9f7; background: #fbfaff; padding: 28px 30px; max-height: 640px; overflow-y: auto; }
.dc-mock-tabs { display: flex; gap: 24px; margin-bottom: 26px; border-bottom: 1px solid #ece9f7; }
.dc-mock-tab { font-family: 'Manrope', sans-serif; font-weight: 600; font-size: 13.5px; color: #a29fc0; padding-bottom: 12px; background: none; border: none; cursor: default; }
.dc-mock-tab.is-active { font-weight: 700; color: #1D4ED8; border-bottom: 2px solid #1D4ED8; }

.dc-mock-side-block { margin-bottom: 22px; }
.dc-mock-side-label { font-size: 12px; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; color: #a29fc0; margin-bottom: 8px; }
.dc-mock-assignee { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border: 1px solid #ece9f7; border-radius: 10px; background: #fff; }
.dc-mock-avatar { width: 26px; height: 26px; border-radius: 50%; background: #1D4ED8; color: #fff; font-size: 12px; font-weight: 700; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.dc-mock-assignee-name { font-size: 13.5px; font-weight: 600; color: #221f3d; flex: 1; }
.dc-mock-chevron-down { color: #c7c3dd; display: flex; flex-shrink: 0; }

.dc-mock-status-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.dc-mock-status-pill { font-size: 12.5px; font-weight: 700; padding: 5px 12px; border-radius: 100px; }
.dc-mock-status-sub { font-size: 12.5px; color: #a29fc0; font-weight: 600; }

.dc-mock-divider { height: 1px; background: #ece9f7; margin: 22px 0; }

.dc-mock-side-title { font-family: 'Manrope', sans-serif; font-weight: 700; font-size: 13.5px; color: #221f3d; margin-bottom: 6px; }
.dc-mock-side-title.gap8 { margin-bottom: 8px; }
.dc-mock-side-p { margin: 0; font-size: 13px; color: #726d94; line-height: 1.65; }

.dc-mock-guidance-item { display: flex; gap: 8px; margin-bottom: 10px; }
.dc-mock-guidance-dot { width: 5px; height: 5px; border-radius: 50%; background: #1D4ED8; margin-top: 7px; flex-shrink: 0; }
.dc-mock-guidance-item p { margin: 0; font-size: 13px; color: #726d94; line-height: 1.6; }
.dc-mock-guidance-item strong { color: #3d3a57; }

.dc-mock-controls { display: flex; flex-wrap: wrap; gap: 8px; }
.dc-mock-control-tag { font-size: 12px; font-weight: 600; color: #5c5780; background: #f4f2fb; padding: 5px 10px; border-radius: 8px; }

.dc-mock-footer { display: flex; justify-content: flex-end; gap: 12px; padding: 20px 36px; border-top: 1px solid #ece9f7; background: #fff; flex-wrap: wrap; }
.dc-mock-btn {
  display: flex; align-items: center; gap: 8px;
  padding: 11px 20px;
  border-radius: 11px;
  font-family: 'Manrope', sans-serif; font-weight: 600; font-size: 13.5px;
  cursor: pointer;
  border: 1px solid #ece9f7;
  background: #fdfcff;
  color: #3d3a57;
  transition: background .15s var(--ease-out);
}
.dc-mock-btn:hover { background: #f4f2fb; }
.dc-mock-btn-primary { border: none; background: #1D4ED8; color: #fff; font-weight: 700; transition: opacity .15s var(--ease-out); }
.dc-mock-btn-primary:hover { opacity: .92; background: #1D4ED8; }

.case-media-caption {
  margin: 1rem 0 0;
  text-align: center;
  font-size: 0.85rem;
  color: var(--color-muted);
}

@media (max-width: 860px) {
  .dc-mock-header { padding: 20px; }
  .dc-mock-body { flex-direction: column; }
  .dc-mock-main { padding: 20px; max-height: none; }
  .dc-mock-sidebar { width: 100%; border-left: none; border-top: 1px solid #ece9f7; max-height: none; padding: 20px; }
  .dc-mock-footer { padding: 16px 20px; }
}

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .about-hero .wrap {
    grid-template-columns: 1fr;
  }
  .about-photo-wrap {
    max-width: 320px;
    margin: 0 auto;
    position: static;
  }
  .project-card {
    grid-template-columns: 1fr;
    min-height: 0;
  }
  .project-visual { order: -1; padding: 2.5rem 2rem 0; }
  .closing .wrap { text-align: center; justify-content: center; }
  .closing-copy { max-width: 100%; }
  .closing-actions { justify-content: center; }
  .case-meta { grid-template-columns: repeat(2, 1fr); }
  .photo-spot { aspect-ratio: 4 / 3; }
  .case-compare { grid-template-columns: 1fr; }
  .case-gallery { grid-template-columns: 1fr; }
  .case-gallery--flow { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
  .nav-links {
    position: fixed;
    inset: 0 0 auto auto;
    top: 68px;
    right: 0;
    background: var(--bg);
    flex-direction: column;
    align-items: flex-start;
    padding: 1.5rem var(--gutter) 2rem;
    width: min(78vw, 320px);
    box-shadow: var(--shadow-lg);
    transform: translateX(calc(100% + 40px));
    transition: transform .2s var(--ease-in), visibility .2s;
    border-bottom-left-radius: var(--radius-md);
    visibility: hidden;
    z-index: 51;
  }
  .nav-links.open {
    transform: translateX(0);
    visibility: visible;
    transition: transform .3s var(--ease-out), visibility .3s;
  }
  .nav-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    background: color-mix(in srgb, var(--color-deep-pine) 40%, transparent);
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s var(--ease-in);
    z-index: 50;
  }
  .nav-backdrop.open {
    opacity: 1;
    pointer-events: auto;
    transition: opacity .3s var(--ease-out);
  }
  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: 1px solid var(--border);
    background: transparent;
    color: var(--text);
  }
  .nav-toggle svg { width: 20px; height: 20px; }
  .nav-toggle .icon-close { display: none; }
  .nav-toggle[aria-expanded="true"] .icon-menu { display: none; }
  .nav-toggle[aria-expanded="true"] .icon-close { display: block; }
  .footer-links { gap: 1.1rem; }
  .site-footer .wrap { flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .marquee-track {
    animation: none !important;
  }
}
