/* ============================================================
   DSR Media Portfolio — styles.css
   Structure: Reset → Tokens → Base → Nav → Sections → Utilities
   ============================================================ */

@import url('https://api.fontshare.com/v2/css?f[]=clash-display@600&f[]=satoshi@400,500,700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500&display=swap');

/* ------------------------------------------------------------
   1. RESET
------------------------------------------------------------ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

/* ------------------------------------------------------------
   2. DESIGN TOKENS
------------------------------------------------------------ */
:root {
  --color-bg:          #F7F4EF;
  --color-surface:     #EDEAE4;
  --color-border:      #D8D4CC;
  --color-text:        #232323;
  --color-muted:       #7A7570;
  --color-accent:      #B1121A;
  --color-accent-dim:  #8A0D14;
  --color-on-accent:   #F7F4EF;

  --font-display: 'Clash Display', 'Helvetica Neue', sans-serif;
  --font-heading: 'Satoshi', 'Helvetica Neue', sans-serif;
  --font-body:    'Inter', system-ui, -apple-system, sans-serif;

  --text-xs:   0.75rem;
  --text-sm:   0.875rem;
  --text-base: 1rem;
  --text-lg:   1.125rem;
  --text-xl:   1.25rem;
  --text-2xl:  1.5rem;
  --text-3xl:  2.25rem;
  --text-4xl:  3rem;
  --text-5xl:  4.5rem;
  --text-6xl:  6rem;

  --weight-regular:  400;
  --weight-medium:   500;
  --weight-semibold: 600;
  --weight-bold:     700;

  --leading-tight:   1.0;
  --leading-snug:    1.2;
  --leading-normal:  1.65;
  --leading-relaxed: 1.85;

  --space-xs:  0.5rem;
  --space-sm:  1rem;
  --space-md:  2rem;
  --space-lg:  4rem;
  --space-xl:  8rem;
  --space-2xl: 14rem;

  --max-width:     1200px;
  --content-width: 860px;
  --nav-height:    72px;

  --ease-out:       cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out:    cubic-bezier(0.4, 0, 0.2, 1);
  --duration-fast:  200ms;
  --duration-base:  500ms;
  --duration-slow:  900ms;
  --duration-xslow: 1200ms;
}

/* ------------------------------------------------------------
   3. BASE
------------------------------------------------------------ */
html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--nav-height);
  font-size: 16px;
}

body {
  background-color: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: var(--leading-normal);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }

/* ------------------------------------------------------------
   4. LAYOUT UTILITY
------------------------------------------------------------ */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin-inline: auto;
  padding-inline: var(--space-md);
}

/* ------------------------------------------------------------
   5. NAVIGATION
------------------------------------------------------------ */
#site-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: var(--nav-height);
  background-color: transparent;
  transition: background-color var(--duration-base) var(--ease-out),
              border-bottom var(--duration-base) var(--ease-out);
}

#site-nav.scrolled {
  background-color: rgba(247, 244, 239, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--color-border);
}

#site-nav nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  max-width: var(--max-width);
  margin-inline: auto;
  padding-inline: var(--space-md);
}

.nav-logo { display: flex; align-items: center; }
.nav-logo img { height: 52px; width: auto; display: block; }

.nav-links {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.nav-links a {
  font-family: var(--font-heading);
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  color: var(--color-muted);
  letter-spacing: 0.04em;
  transition: color var(--duration-fast) ease;
}

.nav-links a:hover,
.nav-links a.active-nav { color: var(--color-text); }

.nav-links .nav-cta {
  color: var(--color-accent);
  border: 1px solid var(--color-accent);
  padding: 0.45rem 1.2rem;
  border-radius: 2px;
  transition: background-color var(--duration-fast) ease, color var(--duration-fast) ease;
}

.nav-links .nav-cta:hover {
  background-color: var(--color-accent);
  color: var(--color-on-accent);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 24px; height: 18px;
  background: none; border: none;
  cursor: pointer; padding: 0;
}

.nav-toggle span {
  display: block;
  width: 100%; height: 2px;
  background-color: var(--color-text);
  transition: transform var(--duration-base) var(--ease-out),
              opacity var(--duration-base) ease;
}

.nav-toggle.open span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* ------------------------------------------------------------
   6. SECTION RHYTHM
------------------------------------------------------------ */
section { padding-block: var(--space-xl); }

section:nth-child(even) { background-color: var(--color-surface); }

/* Editorial section label — small caps with red accent rule above */
.section-label {
  display: block;
  font-family: var(--font-heading);
  font-size: clamp(var(--text-2xl), 3vw, var(--text-3xl));
  font-weight: var(--weight-bold);
  letter-spacing: -0.02em;
  color: var(--color-text);
  margin-bottom: var(--space-md);
}

.about-label {
  display: block;
  font-family: var(--font-heading);
  font-size: clamp(var(--text-2xl), 3vw, var(--text-3xl));
  font-weight: var(--weight-bold);
  letter-spacing: -0.02em;
  color: var(--color-text);
  margin-bottom: var(--space-md);
}

.section-title {
  font-family: var(--font-heading);
  font-size: clamp(var(--text-3xl), 4.5vw, var(--text-5xl));
  font-weight: var(--weight-bold);
  line-height: var(--leading-tight);
  margin-bottom: var(--space-md);
  letter-spacing: -0.035em;
  color: var(--color-text);
}

.section-rule {
  display: block;
  width: 48px; height: 2px;
  background-color: var(--color-accent);
  margin-bottom: var(--space-md);
}

/* Accent rule — thin red line used as editorial separator */
.section-divider {
  width: 100%; height: 1px;
  background-color: var(--color-border);
  margin-block: var(--space-lg);
}

/* ------------------------------------------------------------
   6b. IMAGE PLACEHOLDER
------------------------------------------------------------ */
.img-placeholder {
  position: relative;
  overflow: hidden;
  background-color: var(--color-border);
  background-image: repeating-linear-gradient(
    -45deg,
    rgba(35,35,35,.05), rgba(35,35,35,.05) 1px,
    transparent 1px, transparent 12px
  );
  color: var(--color-muted);
  font-family: var(--font-heading);
  font-size: var(--text-xs);
  font-weight: var(--weight-medium);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color var(--duration-base) ease;
}

/* ------------------------------------------------------------
   7. HERO
------------------------------------------------------------ */
#hero {
  position: relative;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  padding-top: var(--nav-height);
  overflow: hidden;
}

#hero .container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-lg);
  align-items: center;
}

.hero-text {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  z-index: 1;
}

.hero-image {
  height: 88vh;
  max-height: 860px;
  overflow: hidden;
  will-change: transform;
}

.hero-image img {
  width: 100%;
  height: 115%;
  object-fit: cover;
  object-position: center top;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  font-family: var(--font-heading);
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: var(--space-xs);
}

.hero-eyebrow::before {
  content: '';
  display: inline-block;
  width: 36px; height: 1px;
  background-color: var(--color-accent);
}

#hero h1 {
  font-family: var(--font-display);
  font-size: clamp(var(--text-4xl), 7vw, var(--text-6xl));
  font-weight: var(--weight-semibold);
  line-height: var(--leading-tight);
  letter-spacing: -0.04em;
  color: var(--color-text);
}

#hero p {
  font-family: var(--font-heading);
  font-size: clamp(var(--text-2xl), 3vw, var(--text-3xl));
  font-weight: var(--weight-bold);
  color: var(--color-text);
  max-width: 560px;
  line-height: var(--leading-snug);
  letter-spacing: -0.02em;
  margin-top: var(--space-xs);
}

/* Animated scroll indicator */
.hero-scroll-cue {
  position: absolute;
  bottom: var(--space-md);
  left: 50%;
  transform: translateX(-50%);
  width: 1px; height: 56px;
  overflow: hidden;
}

.hero-scroll-cue span {
  display: block;
  width: 1px; height: 100%;
  background-color: var(--color-text);
  animation: scroll-cue 2s var(--ease-out) infinite;
}

@keyframes scroll-cue {
  0%   { transform: translateY(-100%); }
  60%  { transform: translateY(100%); }
  100% { transform: translateY(100%); }
}

/* ------------------------------------------------------------
   8. BUTTONS
------------------------------------------------------------ */
.btn {
  display: inline-block;
  padding: 0.9rem 2.25rem;
  background-color: var(--color-accent);
  color: var(--color-on-accent);
  font-family: var(--font-heading);
  font-size: var(--text-sm);
  font-weight: var(--weight-bold);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border: none;
  border-radius: 1px;
  cursor: pointer;
  transition: background-color var(--duration-fast) ease,
              box-shadow var(--duration-base) var(--ease-out);
  margin-top: var(--space-sm);
}

.btn:hover {
  background-color: var(--color-accent-dim);
  box-shadow: 0 8px 32px rgba(177, 18, 26, 0.3);
}

.btn-outline {
  background-color: transparent;
  color: var(--color-text);
  border: 1.5px solid var(--color-text);
}

.btn-outline:hover {
  background-color: var(--color-text);
  color: var(--color-bg);
}

.btn-large { padding: 1.15rem 3rem; font-size: var(--text-base); }

/* ------------------------------------------------------------
   9. ABOUT
------------------------------------------------------------ */
#about {
  background-color: var(--color-bg);
  padding-block: var(--space-xl);
}

#about .container {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: var(--space-2xl);
  align-items: start;
}

.about-statement {
  position: sticky;
  top: calc(var(--nav-height) + var(--space-lg));
}

.about-pull {
  font-family: var(--font-heading);
  font-size: clamp(var(--text-2xl), 3vw, var(--text-3xl));
  font-weight: var(--weight-bold);
  line-height: var(--leading-snug);
  letter-spacing: -0.03em;
  color: var(--color-text);
}

.about-body {
  padding-top: 3.5rem;
}

.about-body p {
  font-family: var(--font-body);
  font-size: var(--text-xl);
  line-height: var(--leading-relaxed);
  color: var(--color-muted);
  max-width: 560px;
}

/* ------------------------------------------------------------
   10. WHAT WE DO
------------------------------------------------------------ */
#what-we-do { background-color: var(--color-surface); }

.services-header { margin-bottom: var(--space-lg); }
.services-header .section-title { margin-bottom: 0; }

.services-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background-color: var(--color-border);
  border: 1px solid var(--color-border);
}

.service-card {
  background-color: var(--color-surface);
  padding: var(--space-lg) var(--space-md);
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  position: relative;
  overflow: hidden;
  transition: background-color var(--duration-base) var(--ease-out);
}

.service-card::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0;
  width: 0; height: 2px;
  background-color: var(--color-accent);
  transition: width var(--duration-slow) var(--ease-out);
}

.service-card:hover { background-color: var(--color-bg); }
.service-card:hover::after { width: 100%; }

.service-name {
  font-family: var(--font-heading);
  font-size: var(--text-2xl);
  font-weight: var(--weight-bold);
  letter-spacing: -0.025em;
  line-height: var(--leading-snug);
  color: var(--color-text);
}

.service-results {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  margin-top: var(--space-xs);
}

.service-results li {
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--color-muted);
  line-height: var(--leading-normal);
  padding-left: 1.25rem;
  position: relative;
}

.service-results li::before {
  content: '—';
  position: absolute;
  left: 0;
  color: var(--color-accent);
  font-size: var(--text-xs);
  top: 0.2em;
}

/* ------------------------------------------------------------
   11. WHY CHOOSE US
------------------------------------------------------------ */
#why-us { background-color: var(--color-bg); }

.why-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  margin-top: var(--space-lg);
  border-top: 1px solid var(--color-border);
}

.why-stat {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: var(--space-lg) var(--space-md);
  border-right: 1px solid var(--color-border);
  position: relative;
  overflow: hidden;
  transition: background-color var(--duration-base) var(--ease-out);
}

.why-stat:last-child { border-right: none; }

.why-stat:hover { background-color: var(--color-surface); }

.why-stat__number {
  font-family: var(--font-display);
  font-size: clamp(var(--text-3xl), 4vw, var(--text-5xl));
  font-weight: var(--weight-semibold);
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--color-accent);
  display: block;
}

.why-stat__label {
  font-family: var(--font-heading);
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--color-muted);
}

.reasons-list { display: none; }

/* ------------------------------------------------------------
   12. PAST CLIENTS
------------------------------------------------------------ */
.clients-block { margin-top: var(--space-lg); }

.clients-block__label {
  font-family: var(--font-heading);
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--color-muted);
  margin-bottom: var(--space-md);
  padding-bottom: var(--space-xs);
  border-bottom: 1px solid var(--color-border);
}

.clients-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: var(--space-sm);
}

.client-tile {
  aspect-ratio: 1 / 1;
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 4px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color var(--duration-base) ease,
              box-shadow var(--duration-base) ease;
}

.client-tile:hover {
  border-color: var(--color-muted);
  box-shadow: 0 6px 24px rgba(35,35,35,0.08);
}

.client-tile img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform var(--duration-slow) var(--ease-out);
}

.client-tile:hover img { transform: scale(1.05); }

/* ------------------------------------------------------------
   13. CLIENT TRANSFORMATIONS
------------------------------------------------------------ */
#transformations { background-color: var(--color-surface); }

#transformations > .container > .animate-on-scroll { margin-bottom: var(--space-lg); }
#transformations .section-title { margin-bottom: 0; }

.case-study {
  display: grid;
  grid-template-columns: 2fr 3fr;
  gap: var(--space-lg);
  align-items: start;
  padding-block: var(--space-xl);
  border-top: 1px solid var(--color-border);
}

.case-study:last-of-type { border-bottom: 1px solid var(--color-border); }

.case-study__meta {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-bottom: var(--space-lg);
}

.case-study__client {
  font-family: var(--font-heading);
  font-size: var(--text-3xl);
  font-weight: var(--weight-bold);
  color: var(--color-text);
  letter-spacing: -0.02em;
  line-height: var(--leading-tight);
}

.case-study__niche {
  font-family: var(--font-body);
  font-size: var(--text-lg);
  color: var(--color-muted);
  line-height: var(--leading-normal);
}

.case-study__headline {
  font-family: var(--font-display);
  font-size: clamp(var(--text-2xl), 3vw, var(--text-4xl));
  font-weight: var(--weight-semibold);
  line-height: var(--leading-tight);
  letter-spacing: -0.03em;
  color: var(--color-text);
  margin-bottom: var(--space-md);
}

.case-study__breakdown {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.case-study__block h4 {
  font-family: var(--font-heading);
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: 0.6rem;
}

.case-study__block p,
.case-study__block ul {
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--color-muted);
  line-height: var(--leading-normal);
}

.case-study__block ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.case-study__block ul li {
  padding-left: 1.2rem;
  position: relative;
}

.case-study__block ul li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--color-accent);
  font-size: var(--text-xs);
  top: 0.15em;
}

.case-study__visual {
  position: sticky;
  top: calc(var(--nav-height) + var(--space-md));
}

.case-study__img-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-xs);
}

.case-study__img-grid img {
  width: 100%;
  height: 240px;
  object-fit: contain;
  object-position: center;
  background-color: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: 3px;
  display: block;
  transition: transform var(--duration-slow) var(--ease-out),
              box-shadow var(--duration-slow) var(--ease-out);
}

.case-study__img-grid img:hover {
  transform: scale(1.02);
  box-shadow: 0 12px 40px rgba(35,35,35,0.1);
}

.case-study__img-grid img.full {
  grid-column: 1 / -1;
  height: 300px;
}

.case-study__before-after {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-xs);
}

.case-study__before-after figure {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.case-study__before-after img {
  width: 100%;
  height: 220px;
  object-fit: contain;
  object-position: top;
  background-color: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: 3px;
  display: block;
  transition: transform var(--duration-slow) var(--ease-out);
}

.case-study__before-after img:hover { transform: scale(1.02); }

.case-study__before-after figcaption {
  font-family: var(--font-heading);
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-muted);
  text-align: center;
}

/* ------------------------------------------------------------
   14. PROOF
------------------------------------------------------------ */
.proof-block { margin-top: var(--space-lg); }

.proof-block h3 {
  font-family: var(--font-heading);
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: var(--space-md);
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
}

.proof-block h3::before {
  content: '';
  display: inline-block;
  width: 36px; height: 1px;
  background-color: var(--color-accent);
}

/* Gallery — contain so full screenshot is always visible */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: var(--space-sm);
}

.gallery-img {
  width: 100%;
  height: 320px;
  object-fit: contain;
  object-position: top center;
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 3px;
  display: block;
  transition: transform var(--duration-slow) var(--ease-out),
              box-shadow var(--duration-slow) var(--ease-out);
}

.gallery-img:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 48px rgba(35,35,35,0.1);
}

/* ------------------------------------------------------------
   15. CREATIVE WORK — tabbed
------------------------------------------------------------ */
.creative-tabs {
  display: flex;
  gap: var(--space-xs);
  margin-bottom: var(--space-md);
  border-bottom: 1px solid var(--color-border);
  padding-bottom: var(--space-xs);
}

.tab-btn {
  background: none;
  border: none;
  color: var(--color-muted);
  font-family: var(--font-heading);
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.5rem 1rem;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: color var(--duration-fast) ease, border-color var(--duration-fast) ease;
}

.tab-btn:hover { color: var(--color-text); }
.tab-btn.active { color: var(--color-accent); border-bottom-color: var(--color-accent); }

.tab-panel { display: none; }
.tab-panel.active { display: block; }

.creative-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: var(--space-sm);
}

.creative-item {
  aspect-ratio: 4 / 5;
  border-radius: 4px;
  overflow: hidden;
  position: relative;
  background-color: var(--color-border);
}

.creative-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform var(--duration-xslow) var(--ease-out);
}

.creative-item:hover img { transform: scale(1.06); }

/* ------------------------------------------------------------
   16. CLOSING CTA
------------------------------------------------------------ */
#cta {
  text-align: center;
  background-color: var(--color-surface);
}

#cta .container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
}

#cta .section-title { font-size: clamp(var(--text-2xl), 4vw, var(--text-4xl)); max-width: 700px; }

.cta-contact {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-lg);
  margin-top: var(--space-sm);
}

.cta-contact__item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  transition: opacity var(--duration-fast) ease;
}

.cta-contact__item:hover { opacity: 0.65; }

.cta-contact__label {
  font-family: var(--font-heading);
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--color-accent);
}

.cta-contact__value {
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--color-text);
}

/* ------------------------------------------------------------
   17. FOOTER
------------------------------------------------------------ */
#site-footer {
  padding-block: var(--space-lg);
  border-top: 1px solid var(--color-border);
  text-align: center;
  font-size: var(--text-sm);
  color: var(--color-muted);
}

.footer-logo {
  height: 100px;
  width: auto;
  margin-inline: auto;
  margin-bottom: var(--space-md);
  display: block;
}

/* ------------------------------------------------------------
   18. SCROLL ANIMATIONS
------------------------------------------------------------ */
.animate-on-scroll {
  opacity: 0;
  transition: opacity var(--duration-slow) var(--ease-out),
              transform var(--duration-slow) var(--ease-out);
}

.fade-up    { transform: translateY(40px); }
.fade-in    { transform: none; }
.slide-left { transform: translateX(-40px); }
.slide-right{ transform: translateX(40px); }

.animate-on-scroll.is-visible { opacity: 1; transform: none; }

.delay-1 { transition-delay: 100ms; }
.delay-2 { transition-delay: 220ms; }
.delay-3 { transition-delay: 340ms; }
.delay-4 { transition-delay: 460ms; }

/* Staggered grid children — set by JS */
.stagger-child {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity var(--duration-slow) var(--ease-out),
              transform var(--duration-slow) var(--ease-out);
}

.stagger-child.stagger-visible { opacity: 1; transform: none; }

/* ------------------------------------------------------------
   19. RESPONSIVE
------------------------------------------------------------ */
@media (max-width: 900px) {
  .why-stats { grid-template-columns: repeat(2, 1fr); }
  .why-stat  { border-bottom: 1px solid var(--color-border); }
}

@media (max-width: 768px) {
  :root {
    --space-xl:  5rem;
    --space-2xl: 7rem;
    --space-lg:  2.5rem;
  }

  .nav-toggle { display: flex; }

  .nav-links {
    display: none;
    position: fixed;
    inset: var(--nav-height) 0 0 0;
    flex-direction: column;
    justify-content: flex-start;
    align-items: flex-start;
    padding: var(--space-md);
    gap: var(--space-md);
    background-color: var(--color-bg);
    border-top: 1px solid var(--color-border);
  }

  .nav-links.open { display: flex; }
  .nav-links a { font-size: var(--text-lg); }

  #hero .container { grid-template-columns: 1fr; gap: 0; }

  .hero-image { height: 60vw; max-height: 420px; order: -1; }
  .hero-text  { padding-top: var(--space-md); }

  #about .container { grid-template-columns: 1fr; gap: var(--space-lg); }

  .about-statement { position: static; }
  .about-body { padding-top: 0; }
  .about-body p { max-width: none; }

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

  .why-stats { grid-template-columns: repeat(2, 1fr); gap: 0; }

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

  .case-study { grid-template-columns: 1fr; gap: var(--space-md); }
  .case-study__visual { position: static; order: -1; }

  .creative-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 480px) {
  .why-stats { grid-template-columns: 1fr 1fr; }
  .clients-grid { grid-template-columns: repeat(2, 1fr); }

  .cta-contact {
    flex-direction: column;
    gap: var(--space-md);
  }

  .case-study__img-grid { grid-template-columns: 1fr; }
  .case-study__before-after { grid-template-columns: 1fr; }
}
