/* ─────────────────────────────────────────────
   CASE STUDY — Component Stylesheet
   Yun-Chia Lin · 2026
   Import AFTER style.css
   ───────────────────────────────────────────── */


/* ══════════════════════════════════════════════
   IMAGE DEFAULTS
   ══════════════════════════════════════════════ */

img, video { width: 100%; display: block; }


/* ══════════════════════════════════════════════
   HERO
   ══════════════════════════════════════════════ */

.cs-hero {
  min-height: 96vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
  padding-top: 64px;
}

/* Left panel — dark */
.cs-hero__left {
  background: var(--dark);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 5rem 4rem;
  position: relative;
  overflow: hidden;
}
.cs-hero__left::before {
  content: '';
  position: absolute;
  top: -20%; right: -10%;
  width: 60%;
  aspect-ratio: 1;
  background: var(--yellow);
  opacity: 0.08;
  border-radius: 50%;
  filter: blur(80px);
}

/* Right panel — yellow */
.cs-hero__right {
  background: var(--yellow);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 5rem 4rem;
  position: relative;
}

/* Tag above title */
.cs-hero__tag {
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--yellow);
  margin-bottom: 1.5rem;
  font-family: var(--sans);
  font-weight: 500;
}

/* Main title */
.cs-hero__title {
  font-family: var(--serif);
  font-size: clamp(2.8rem, 5vw, 4.5rem);
  line-height: 1.08;
  color: var(--white);
  font-weight: 400;
  margin-bottom: 2rem;
}
.cs-hero__title em {
  font-style: italic;
  color: var(--yellow);
}

/* Metadata row (role / platform / duration) */
.cs-hero__meta {
  display: flex;
  gap: 2.5rem;
  flex-wrap: wrap;
}
.cs-meta-item {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}
.cs-meta-label {
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-on-dark);
}
.cs-meta-value {
  font-size: 0.88rem;
  color: rgba(255,255,255,0.85);
  font-weight: 300;
}

/* HMW challenge on right panel */
.cs-hero__problem { position: relative; z-index: 1; }
.cs-hero__problem-label {
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(0,0,0,0.45);
  margin-bottom: 1rem;
  font-weight: 500;
}
.cs-hero__problem h2 {
  font-family: var(--serif);
  font-size: 1.5rem;
  font-weight: 400;
  line-height: 1.5;
  color: var(--dark);
  max-width: 32ch;
}


/* ══════════════════════════════════════════════
   SECTION VARIANTS — DARK / LIGHT BG
   ══════════════════════════════════════════════ */

/* Dark section: flip label, title, body colours */
.cs-section--dark {
  background: var(--dark);
}
.cs-section--dark .section-label { color: var(--yellow); opacity: 1; }
.cs-section--dark .section-title { color: var(--white); }
.cs-section--dark .body-text     { color: var(--text-on-dark); }
.cs-section--dark .divider       { opacity: 0.15; }

/* White section override */
.cs-section--white { background: var(--white); }


/* ══════════════════════════════════════════════
   TWO-COLUMN LAYOUT
   ══════════════════════════════════════════════ */

.cs-two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  align-items: start;
  margin-top: 3rem;
}
.cs-two-col--2-1 { grid-template-columns: 2fr 1fr; }

.cs-img-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  margin-top: 1.5rem;
  margin-bottom: 1.5rem;
}

.cs-img-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top: 1.5rem;
  margin-bottom: 1.5rem;
}


/* ══════════════════════════════════════════════
   PLACEHOLDER IMAGE
   ══════════════════════════════════════════════ */

.img-placeholder {
  background: #e8e6e0;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(0,0,0,0.25);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-family: var(--sans);
  font-weight: 500;
  position: relative;
  overflow: hidden;
}
.img-placeholder::before {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    45deg,
    transparent, transparent 10px,
    rgba(0,0,0,0.025) 10px, rgba(0,0,0,0.025) 11px
  );
}
.img-placeholder span { position: relative; z-index: 1; }

.cs-fullwidth { width: 100%; }



.cs-method-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-top: 0.5rem;
}
.cs-method-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  background: var(--white);
  border-left: 3px solid var(--yellow);
}
.cs-method-number {
  font-family: var(--serif);
  font-size: 1.1rem;
  color: var(--yellow);
  font-weight: 700;
  min-width: 24px;
}
.cs-method-text {
  font-size: 0.875rem;
  color: var(--mid);
  line-height: 1.5;
}
.cs-method-text strong {
  display: block;
  color: var(--dark);
  font-weight: 500;
  margin-bottom: 0.2rem;
}


/* ══════════════════════════════════════════════
   PERSONA CARD
   ══════════════════════════════════════════════ */

.cs-persona {
  background: var(--white);
  display: grid;
  grid-template-columns: 280px 1fr;
  margin-top: 3rem;
  overflow: hidden;
  border-radius: 4px;
}

/* Left — yellow visual strip */
.cs-persona__visual {
  background: var(--yellow);
  padding: 3rem 2.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}
.cs-persona__avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: rgba(0,0,0,0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
}
.cs-persona__name {
  font-family: var(--serif);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--dark);
}
.cs-persona__attr { display: flex; flex-direction: column; gap: 0.3rem; }
.cs-persona__attr-label {
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(0,0,0,0.4);
}
.cs-persona__attr-value {
  font-size: 0.875rem;
  color: var(--dark);
  font-weight: 400;
}

/* Right — detail grid */
.cs-persona__details {
  padding: 3rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2.5rem;
  align-content: start;
}
.cs-persona__section h4 {
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--mid);
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid rgba(0,0,0,0.08);
}
.cs-persona__list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}
.cs-persona__list li {
  font-size: 0.875rem;
  color: var(--mid);
  padding-left: 1rem;
  position: relative;
  line-height: 1.4;
}
.cs-persona__list li::before {
  content: '—';
  position: absolute;
  left: 0;
  color: var(--yellow);
  font-weight: 700;
}


/* ══════════════════════════════════════════════
   PAIN POINTS — DARK GRID
   ══════════════════════════════════════════════ */

.cs-pain-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5px;
  margin-top: 3rem;
  background: rgba(255,255,255,0.06);
}
.cs-pain-card {
  background: var(--dark-surface);
  padding: 2.5rem;
  position: relative;
  overflow: hidden;
  transition: background 0.3s;
}
.cs-pain-card:hover { background: var(--dark-surface-hover); }
.cs-pain-number {
  font-family: var(--serif);
  font-size: 4rem;
  color: rgba(245,209,37,0.08);
  position: absolute;
  top: 1.5rem; right: 2rem;
  line-height: 1;
  font-weight: 700;
  pointer-events: none;
}
.cs-pain-title {
  font-family: var(--serif);
  font-size: 1.25rem;
  color: var(--white);
  margin-bottom: 0.75rem;
  font-weight: 400;
}
.cs-pain-desc {
  font-size: 0.875rem;
  color: var(--text-on-dark);
  line-height: 1.7;
}
.cs-pain-quote {
  margin-top: 1.25rem;
  padding-left: 1rem;
  border-left: 2px solid var(--yellow);
  font-family: var(--serif);
  font-style: italic;
  font-size: 1rem;
  color: var(--text-on-dark);
}


/* ══════════════════════════════════════════════
   IA / FADED IMAGE
   ══════════════════════════════════════════════ */

.cs-faded-img {
  opacity: 0.75;
  transition: opacity 0.3s ease;
}
.cs-faded-img:hover { opacity: 1; }


/* ══════════════════════════════════════════════
   STRATEGY — STICKY SIDEBAR + CARD LIST
   ══════════════════════════════════════════════ */

.cs-strategy {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 3rem;
  margin-top: 3rem;
  align-items: start;
}
.cs-strategy__intro {
  position: sticky;
  top: 100px;
}
.cs-strategy__cards {
  display: flex;
  flex-direction: column;
  gap: 1px;
  background: rgba(0,0,0,0.08);
}
.cs-strategy__card {
  background: var(--white);
  padding: 2.5rem;
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 1.5rem;
  align-items: start;
  transition: background 0.2s;
}
.cs-strategy__card:hover { background: var(--light); }
.cs-strategy__icon {
  width: 48px;
  height: 48px;
  background: var(--yellow);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  flex-shrink: 0;
}
.cs-strategy__card h3 {
  font-family: var(--serif);
  font-size: 1.15rem;
  color: var(--dark);
  font-weight: 400;
  margin-bottom: 0.5rem;
}


/* ══════════════════════════════════════════════
   DESIGN PRINCIPLES
   ══════════════════════════════════════════════ */

/* Pill tag above each principle */
.cs-tag {
  display: inline-block;
  background: var(--yellow);
  color: var(--dark);
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 0.3rem 0.8rem;
  margin-bottom: 1rem;
  font-weight: 500;
}

/* ══════════════════════════════════════════════
   PARALLAX SECTION
   ══════════════════════════════════════════════ */

.cs-parallax-section {
  position: relative;
  overflow: hidden;
  background: var(--dark);
}
.cs-parallax-bg {
  position: absolute;
  inset: -30% 0;
  width: 100%;
  height: 160%;
  object-fit: cover;
  object-position: center;
  will-change: transform;
  border-radius: 0;
}
.cs-parallax-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  z-index: 1;
}
.cs-parallax-content {
  position: relative;
  z-index: 2;
}


/* Principle block — padded section with top rule */
.cs-principle {
  padding: 3rem 0;
}
.cs-principle__header { display: block; margin-bottom: 3rem; }

/* Large title for each principle */
.cs-principle-title {
  font-family: var(--serif);
  font-size: 1.7rem;
  font-weight: 400;
  color: var(--dark);
  line-height: 1.5;
  margin: 0.5rem 0 1rem;
}

/* Before / After full-width panel */
.cs-ba {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5px;
  background: rgba(0,0,0,0.06);
}
.cs-ba--2-3 { grid-template-columns: 2fr 3fr; }
.cs-ba__col {
  padding: 2rem 3rem;
  background: var(--white);
}
.cs-ba__label {
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--mid);
  margin-bottom: 1rem;
  font-weight: 500;
  opacity: 0.6;
}

/* Dark surface variant (night mode, dark sections) */
.cs-ba--dark { background: rgba(255,255,255,0.04); }
.cs-ba--dark .cs-ba__col { background: var(--dark-surface); }
.cs-ba--dark .cs-ba__label { color: var(--text-on-dark); opacity: 1; }

/* Image constrain helper for before-wrap */
.cs-ba__before-wrap { width: 100%; }


/* ══════════════════════════════════════════════
   FIELD QUOTES — HORIZONTAL TIMELINE
   ══════════════════════════════════════════════ */

.cs-field-quotes {
  margin-top: 1.5rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
}
.cs-fq-track {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  min-width: 800px;
}
.cs-fq-stop {
  padding: 0 1.5rem 0 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.cs-fq-stop:last-child { padding-right: 0; }
.cs-fq-dot-row {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}
.cs-fq-dot-row::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--yellow);
  margin-left: 0.25rem;
}
.cs-fq-stop:last-child .cs-fq-dot-row::after { display: none; }
.cs-fq-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--yellow);
  flex-shrink: 0;
}
.cs-fq-moment {
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 500;
  color: var(--dark);
}
.cs-fq-quote {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1rem;
  color: var(--mid);
  line-height: 1.6;
  margin: 0;
  padding: 0;
  border: none;
}


/* ══════════════════════════════════════════════
   BLOCKQUOTE
   ══════════════════════════════════════════════ */

blockquote {
  border-left: 3px solid var(--yellow);
  padding: 1rem 2rem;
  margin: 2rem 0;
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.1rem;
  color: var(--mid);
  background: var(--white);
}


/* ══════════════════════════════════════════════
   MEDIA GRID (image + video side by side)
   ══════════════════════════════════════════════ */

.cs-media-grid {
  display: grid;
  grid-template-columns: 3fr 1fr;
  gap: 5px;
}
.cs-media-grid__main {
  background: var(--white);
  height: 520px;
}
.cs-media-grid__main img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
}
.cs-media-grid__aside {
  background: var(--white);
  height: 520px;
  display: flex;
  align-items: center;
}
.cs-media-grid__aside video { width: 100%; }


/* ══════════════════════════════════════════════
   NIGHT MODE GRID (text + image 2:1)
   ══════════════════════════════════════════════ */

.cs-night-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 3rem;
  align-items: start;
}


/* ══════════════════════════════════════════════
   TESTIMONIAL
   ══════════════════════════════════════════════ */

.cs-testimonial-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 1rem;
  align-items: stretch;
  margin-top: 3rem;
}
.cs-testimonial {
  padding: 2.5rem;
  border-radius: 4px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.cs-testimonial--light { background: var(--white); }
.cs-testimonial--yellow { background: var(--yellow); }
.cs-testimonial__quote {
  font-family: var(--serif);
  font-size: 1rem;
  line-height: 1.8;
  color: var(--dark);
  margin: 0 0 1.2rem;
  font-weight: 400;
}
.cs-testimonial__quote--large {
  font-size: 1.5rem;
  line-height: 1.5;
}
.cs-testimonial__attr {
  font-size: 0.75rem;
  color: var(--mid);
  margin: 0;
}


/* ══════════════════════════════════════════════
   OUTCOMES GRID
   ══════════════════════════════════════════════ */

.cs-outcomes {
  background: var(--yellow);
  padding: 7rem 0;
}
.cs-outcomes-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin-top: 3rem;
}
.cs-outcome-card {
  background: rgba(0,0,0,0.06);
  padding: 2rem;
  border-radius: 4px;
}
.cs-outcome-card h4 {
  font-family: var(--serif);
  font-size: 1.1rem;
  color: var(--dark);
  margin-bottom: 0.5rem;
  font-weight: 400;
}
.cs-outcome-card p {
  font-size: 0.875rem;
  color: rgba(0,0,0,0.6);
  line-height: 1.6;
}


/* ══════════════════════════════════════════════
   ON-DARK TEXT UTILITIES
   ══════════════════════════════════════════════ */

.cs-text-on-dark  { color: var(--text-on-dark); }
.cs-text-white    { color: var(--white); }
.cs-text-yellow   { color: var(--yellow); }
.cs-strong-white,
.body-text .cs-strong-white { color: var(--white); font-weight: 500; }


/* ══════════════════════════════════════════════
   RESPONSIVE
   ══════════════════════════════════════════════ */

@media (max-width: 900px) {

  /* Hero */
  .cs-hero { grid-template-columns: 1fr; }
  .cs-hero__left  { min-height: 60vh; padding: 4rem 2rem 3rem; }
  .cs-hero__right { padding: 3rem 2rem; }

  /* Layouts */
  .cs-two-col,
  .cs-strategy,
  .cs-testimonial-grid,
  .cs-outcomes-grid,
  .cs-img-grid-2,
  .cs-img-grid-3 { grid-template-columns: 1fr; }

  /* Persona */
  .cs-persona { grid-template-columns: 1fr; }
  .cs-persona__visual { padding: 2rem; }
  .cs-persona__details { grid-template-columns: 1fr; }

  /* Pain grid */
  .cs-pain-grid { grid-template-columns: 1fr; }

  /* Strategy */
  .cs-strategy__intro { position: static; }

  /* Before/after */
  .cs-ba,
  .cs-ba--2-3 { grid-template-columns: 1fr; }
  .cs-ba__col { padding: 1.5rem; }
  .cs-ba__before-wrap { width: 67%; }

  /* Media grid */
  .cs-media-grid { grid-template-columns: 1fr; }
  .cs-media-grid__main { height: auto; }
  .cs-media-grid__main img { height: auto; object-fit: unset; }
  .cs-media-grid__aside { height: auto; justify-content: center; }
  .cs-media-grid__aside video { width: 66%; }

  /* Night mode */
  .cs-night-grid { grid-template-columns: 1fr; }
  .cs-night-img-col { width: 66%; margin: 0 auto; }
}


/* ── MOVED FROM style.css — Case-study base styles ── */

:root {
  --serif: 'Playfair Display', Georgia, serif;
  --sans:  'DM Sans', system-ui, sans-serif;
}

/* Body */
body {
  background: var(--light);
  color: var(--dark);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

/* Nav */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.25rem 3rem;
  background: var(--light);
  border-bottom: 1px solid rgba(0,0,0,0.08);
  backdrop-filter: blur(8px);
  transition: box-shadow 0.3s, transform 0.35s ease;
}
nav.scrolled    { box-shadow: 0 2px 20px rgba(0,0,0,0.06); }
nav.nav--hidden { transform: translateY(-100%); }
.nav-project-title {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--dark);
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.3s ease, transform 0.3s ease;
  pointer-events: none;
}
.nav-project-title.visible {
  opacity: 1;
  transform: translateY(0);
}
.nav-back-top {
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--mid);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s;
}
.nav-back-top:hover { color: var(--dark); }
.nav-logo {
  font-family: 'Source Sans 3', system-ui, sans-serif;
  font-size: 1rem;
  color: var(--dark);
  text-decoration: none;
  letter-spacing: 0.02em;
}
.nav-links {
  display: flex;
  gap: 2rem;
  list-style: none;
}
.nav-links a {
  font-family: 'Source Sans 3', system-ui, sans-serif;
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--mid);
  text-decoration: none;
  transition: color 0.2s;
}
.nav-links a:hover,
.nav-links a[aria-current="page"] { color: var(--dark); }
.nav-links a[aria-current="page"] {
  border-bottom: 2px solid var(--yellow);
  padding-bottom: 2px;
}

/* Project nav */
.project-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-top: 1px solid rgba(0,0,0,0.08);
}
.project-nav__item {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  padding: 1.5rem 3rem;
  text-decoration: none;
  color: var(--dark);
  transition: background 0.2s ease;
}
.project-nav__item:hover { background: var(--light); }
.project-nav__item--next {
  text-align: right;
  border-left: 1px solid rgba(0,0,0,0.08);
}
.project-nav__label {
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--mid);
  font-weight: 500;
  opacity: 0.6;
}
.project-nav__title {
  font-family: var(--sans);
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.8;
  color: var(--dark);
}
.project-nav__arrow {
  font-size: 1.2rem;
  color: var(--mid);
  margin-top: 0.2rem;
}

/* Footer */
footer {
  background: var(--dark);
  padding: 2.5rem 0;
  text-align: center;
}
footer p {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.25);
  letter-spacing: 0.08em;
}
footer a {
  color: var(--yellow);
  text-decoration: none;
}
footer a:hover { text-decoration: underline; }

/* Responsive */
@media (max-width: 900px) {
  nav { padding: 1rem 1.5rem; }
}
@media (max-width: 600px) {
  .nav-links { gap: 1.25rem; }
  .project-nav { grid-template-columns: 1fr; }
  .project-nav__item--next {
    text-align: left;
    border-left: none;
    border-top: 1px solid rgba(0,0,0,0.08);
  }
}
