/* ============================================================
   Flou Marketing Site — UI Kit support styles
   Loads design tokens from ../../colors_and_type.css
   Adds layout helpers + section-specific styles.
   ============================================================ */

* { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: 88px;
  -webkit-tap-highlight-color: transparent;
}

a { color: inherit; text-decoration: none; }

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

button { font-family: inherit; cursor: pointer; }

a, button, [role="button"] { touch-action: manipulation; }

/* Skip-to-content link, visible only when focused via keyboard. */
.skip-link {
  position: absolute;
  top: -100px;
  left: 16px;
  z-index: 9999;
  background: var(--foreground);
  color: var(--background);
  padding: 12px 20px;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  transition: top 0.15s ease-in-out;
}
.skip-link:focus,
.skip-link:focus-visible {
  top: 16px;
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* Always-visible focus ring for keyboard users on interactive elements
   (overrides any local outline:none in component scopes). */
a:focus-visible,
button:focus-visible,
[role="button"]:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

@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;
  }
}

.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--space-container-x);
}

.container.narrow { max-width: var(--container-narrow); }

.section {
  padding: 80px 0;
}
@media (min-width: 768px) { .section { padding: 112px 0; } }
.section.dark { background: var(--dark-bg); color: #fff; }

/* ---- Eyebrow ---- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  font-weight: 500;
  color: var(--foreground);
}
.eyebrow.on-dark { color: var(--on-dark-70); }
.eyebrow::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 9999px;
  background: var(--accent);
  flex-shrink: 0;
}

.section-title {
  font-size: clamp(32px, 5vw, 48px);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.15;
  color: var(--foreground);
  margin: 16px 0 0;
  text-wrap: balance;
}
.section-title.on-dark { color: #fff; }
.section-title .accent { color: var(--accent); }
.section-subtitle {
  font-size: 16px;
  color: var(--fg-60);
  line-height: 1.6;
  max-width: 640px;
  margin: 16px 0 0;
}

/* ---- Buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 9999px;
  padding: 15px 48px;
  font-size: 15px;
  font-weight: 500;
  line-height: 1;
  cursor: pointer;
  border: none;
  transition: background-color 0.2s var(--ease-out), color 0.2s var(--ease-out), transform 0.2s var(--ease-out), box-shadow 0.2s var(--ease-out);
  text-decoration: none;
  min-height: 48px;
}
.btn.primary { background: var(--foreground); color: #fff; }
.btn.primary:hover { background: #1A1A1A; transform: scale(1.03); }
.btn.secondary {
  background: var(--background);
  color: var(--accent);
  border: 1px solid rgba(15, 15, 15, 0.18);
}
.btn.secondary:hover {
  background: var(--surface);
  border-color: rgba(15, 15, 15, 0.32);
  transform: scale(1.03);
}
.btn.dark-secondary {
  background: rgba(255,255,255,0.04);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.10);
}
.btn.dark-secondary:hover { background: rgba(255,255,255,0.08); }

.btn-row { display: flex; flex-wrap: wrap; gap: 16px; }

/* ---- Section CTA pair (lives under every major section) ---- */
.section-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: center;
  margin-top: 56px;
  padding-top: 8px;
}
.section-cta .btn { min-width: 180px; justify-content: center; }

/* On dark sections, swap the primary fill to coral so it pops off the black,
   and beef up the secondary's contrast. Black-on-black was disappearing. */
.section.dark .section-cta .btn.primary,
.dark .section-cta .btn.primary {
  background: var(--accent);
  color: #fff;
}
.section.dark .section-cta .btn.primary:hover,
.dark .section-cta .btn.primary:hover {
  background: #d94a2a;
  box-shadow: 0 12px 28px -10px rgba(241,85,51,0.5);
}
.section.dark .section-cta .btn.secondary,
.dark .section-cta .btn.secondary {
  background: rgba(255,255,255,0.04);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.14);
}
.section.dark .section-cta .btn.secondary:hover,
.dark .section-cta .btn.secondary:hover { background: rgba(255,255,255,0.08); }
@media (max-width: 640px) {
  .section-cta { flex-direction: column; align-items: stretch; }
  .section-cta .btn { width: 100%; }
}

/* ---- Animate-in (replaces framer-motion) ---- */
.animate-in {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.6s var(--ease-out), transform 0.6s var(--ease-out);
}
.animate-in.in-view { opacity: 1; transform: translateY(0); }

.stagger > * {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.4s var(--ease-out), transform 0.4s var(--ease-out);
}
.stagger.in-view > * { opacity: 1; transform: translateY(0); }
.stagger.in-view > *:nth-child(1) { transition-delay: 0.00s; }
.stagger.in-view > *:nth-child(2) { transition-delay: 0.08s; }
.stagger.in-view > *:nth-child(3) { transition-delay: 0.16s; }
.stagger.in-view > *:nth-child(4) { transition-delay: 0.24s; }
.stagger.in-view > *:nth-child(5) { transition-delay: 0.32s; }
.stagger.in-view > *:nth-child(6) { transition-delay: 0.40s; }
.stagger.in-view > *:nth-child(7) { transition-delay: 0.48s; }
.stagger.in-view > *:nth-child(8) { transition-delay: 0.56s; }

/* ---- Header (glass pill) ---- */
.header-wrap {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  display: flex;
  justify-content: center;
  padding: 12px 12px 0;
}
.header {
  width: 100%;
  max-width: 64rem;
  border-radius: 16px;
  background: rgba(255, 254, 245, 0.92);
  backdrop-filter: blur(20px) saturate(1.6);
  -webkit-backdrop-filter: blur(20px) saturate(1.6);
  border: 1px solid rgba(15, 15, 15, 0.06);
  box-shadow: var(--shadow-glass);
  transition: max-width 0.3s var(--ease-out), background 0.2s var(--ease-out);
}
@supports not (backdrop-filter: blur(1px)) {
  .header { background: rgba(255, 254, 245, 0.98); }
}
.header.scrolled { max-width: 56rem; }
.header nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 48px;
  padding: 0 16px;
}
.header .logo {
  font-size: 20px;
  font-weight: 700;
  color: var(--foreground);
  letter-spacing: -0.01em;
  display: inline-flex;
  align-items: center;
  line-height: 1;
}
.header .logo img {
  display: block;
  height: 26px;
  width: auto;
}
.header .logo .dot { color: var(--accent); }
@media (max-width: 640px) {
  .header .logo img { height: 22px; }
}
.header-links { display: flex; align-items: center; gap: 24px; }
.header-links a {
  font-size: 15px;
  font-weight: 500;
  color: var(--fg-70);
  transition: color 0.2s;
}
.header-links a:hover { color: var(--foreground); }
.header-cta {
  background: var(--foreground);
  color: var(--background);
  font-size: 15px;
  font-weight: 500;
  padding: 6px 20px;
  border-radius: 9999px;
  transition: background 0.2s;
}
.header-cta:hover { background: rgba(15,15,15,0.85); }

/* ---- Hero ---- */
.hero {
  position: relative;
  width: 100%;
  min-height: 100svh;
  overflow: hidden;
  background: var(--background);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: clamp(96px, 14vh, 140px) 24px 0;
}
.hero > .hero-tagline,
.hero > .hero-title,
.hero > .hero-desc,
.hero > .hero-actions { flex: 0 0 auto; }
.hero-tagline {
  display: inline-block;
  font-size: 14px;
  font-weight: 500;
  color: var(--fg-60);
  background: rgba(250,250,250,0.5);
  border: 1px solid var(--border-subtle);
  border-radius: 9999px;
  padding: 6px 16px;
  backdrop-filter: blur(8px);
}
.hero-title {
  margin: 20px 0 0;
  font-size: clamp(40px, 6vw, 68px);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.08;
  max-width: 920px;
  text-wrap: balance;
}
.hero-title .accent { color: var(--accent); }
.hero-desc {
  margin: 20px auto 0;
  font-size: 17px;
  line-height: 1.6;
  color: var(--fg-60);
  max-width: 560px;
  text-wrap: pretty;
}
.hero-actions { margin-top: 32px; display: flex; gap: 16px; flex-wrap: wrap; justify-content: center; position: relative; z-index: 2; }

.hero-marquee-wrap {
  position: relative;
  margin-top: auto;
  padding-top: clamp(40px, 6vh, 72px);
  width: 100%;
  --marquee-duration: 40s;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(to right, transparent 0, black 4%, black 96%, transparent 100%);
          mask-image: linear-gradient(to right, transparent 0, black 4%, black 96%, transparent 100%);
}
.hero-shield {
  display: none;
}
.hero-marquee {
  display: flex;
  align-items: flex-start;
  gap: 18px;
  width: max-content; /* size to content so -50% is exact half */
  animation: hero-marquee var(--marquee-duration, 40s) linear infinite;
  will-change: transform;
}
.hero-marquee:hover,
.hero-marquee:focus-within { animation-play-state: paused; }

.hero-thumb {
  flex-shrink: 0;
  aspect-ratio: 3/4;
  height: clamp(200px, 32vh, 320px);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: var(--shadow-card);
}
@media (max-width: 700px) {
  .hero-thumb { height: clamp(180px, 28vh, 260px); border-radius: 16px; }
  .hero-marquee { gap: 12px; }
  @keyframes hero-marquee {
    0%   { transform: translate3d(0, 0, 0); }
    100% { transform: translate3d(calc(-50% - 6px), 0, 0); }
  }
}
.hero-thumb:nth-child(odd) { transform: rotate(-2deg); }
.hero-thumb:nth-child(even) { transform: rotate(3deg); }
.hero-thumb img { width: 100%; height: 100%; object-fit: cover; object-position: center top; display: block; }

/* Seamless loop: track holds [A..A] (doubled in JS).
   Translate exactly half the track + half the gap so the second copy
   lands where the first started — no visible jump on wrap. */
@keyframes hero-marquee {
  0%   { transform: translate3d(0, 0, 0); }
  100% { transform: translate3d(calc(-50% - 9px), 0, 0); }
}

/* ---- Stats ---- */
.stats-head {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 56px;
  max-width: 900px;
}
.stats-head .section-title { margin: 0; }
.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-left: 1px solid var(--border-subtle);
  border-right: 1px solid var(--border-subtle);
  position: relative;
}
.stats::before, .stats::after {
  content: "";
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  width: 100vw;
  border-top: 1px solid var(--border-subtle);
}
.stats::before { top: -1px; }
.stats::after { bottom: -1px; }

.stat-cell {
  position: relative;
  padding: 56px 24px;
  text-align: center;
  background: var(--background);
}
.stat-cell.alt { background: var(--surface); }
.stat-cell + .stat-cell { border-left: 1px solid var(--border-subtle); }
.stat-num { font-size: 80px; font-weight: 700; line-height: 1; letter-spacing: -0.03em; }
.stat-num .suffix { color: var(--accent); }
.stat-label { margin: 12px 0 4px; font-size: 20px; font-weight: 500; }
.stat-desc  { margin: 0; font-size: 14px; font-weight: 500; color: var(--fg-60); max-width: 220px; margin-inline: auto; }

.corner-plus {
  position: absolute;
  width: 24px;
  height: 24px;
  color: var(--muted);
  z-index: 10;
}

/* ---- Services tabs ---- */
.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 40px;
}
.tabs button {
  border: none;
  border-radius: 10px;
  padding: 12px 24px;
  font-size: 15px;
  font-weight: 500;
  background: var(--fg-05);
  color: var(--foreground);
  transition: all 0.2s;
}
.tabs button:hover { background: var(--fg-10); }
.tabs button.active { background: var(--accent); color: #fff; }

.service-card {
  margin-top: 32px;
  border: 1px solid var(--fg-10);
  border-radius: 20px;
  padding: 48px;
  background: var(--background);
}
.service-card h3 { margin: 0; font-size: 26px; font-weight: 700; line-height: 1.25; }
.service-card p  { margin: 16px 0 0; font-size: 17px; color: var(--fg-70); max-width: 640px; line-height: 1.6; }
.service-card ul { margin: 28px 0 0; padding: 0; list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 12px 32px; }
.service-card ul li { display: flex; align-items: flex-start; gap: 10px; font-size: 15px; line-height: 1.45; }

/* Actions row: tight gap, equal feel between primary/secondary, both look
   like a paired CTA. On mobile they stack flush with no awkward gap. */
.service-card-actions {
  margin-top: 28px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}
.service-card-actions .btn {
  padding: 14px 28px;
  font-size: 15px;
  min-height: 48px;
  min-width: 0;
}
.service-card-actions .btn.secondary {
  padding: 14px 24px;
}
@media (max-width: 640px) {
  .service-card-actions { flex-direction: column; align-items: stretch; gap: 8px; margin-top: 24px; }
  .service-card-actions .btn { width: 100%; }
}
.service-card ul li::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 9999px;
  background: var(--accent);
  flex-shrink: 0;
}
/* (legacy: removed — service-card-actions controls spacing now) */

/* ---- Process steps (dark) ---- */
.process-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
  margin-top: 56px;
}
.process-step .num {
  font-size: 96px;
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.03em;
}
.process-step.first .num { color: #fff; }
.process-step:not(.first) .num { color: var(--accent); }
.process-step h3 { margin: 16px 0 0; font-size: 22px; font-weight: 600; color: #fff; }
.process-step p  { margin: 8px 0 0; font-size: 15px; line-height: 1.6; color: var(--on-dark-70); }

/* ---- Benefits ---- */
.benefits-list { margin-top: 48px; display: flex; flex-direction: column; gap: 16px; max-width: 980px; }

/* ---- Benefits carousel (homepage Why Flou) ----
   Desktop: shows 3 cards side-by-side, arrows top-right.
   Track shifts by (card-width + gap) per index.
   Mobile: 1 card per view, swipe + dots, arrows hidden.
*/
.benefits-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 32px;
  margin-bottom: 40px;
}
.benefits-head { max-width: 720px; }
.benefits-head .section-title { margin-top: 16px; }

.bc-arrows {
  display: flex;
  gap: 12px;
  flex-shrink: 0;
}

.benefits-carousel {
  --bc-card-w: calc((100% - 2 * var(--bc-gap)) / 3); /* 3 cards visible desktop */
  --bc-gap: 20px;
  position: relative;
  margin-top: 8px;
}
.bc-viewport {
  overflow: hidden;
  /* slight side padding so card shadows don't clip */
  margin: -8px;
  padding: 8px;
}
.bc-track {
  display: flex;
  gap: var(--bc-gap);
  transition: transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
}
.bc-card {
  flex: 0 0 var(--bc-card-w);
  background: var(--surface, #FAFAFA);
  border: 1px solid rgba(15,15,15,0.06);
  border-radius: 24px;
  padding: 36px 32px 28px;
  min-height: 460px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 24px;
}
.bc-quote {
  margin: 0;
  font-size: clamp(18px, 1.5vw, 22px);
  font-weight: 500;
  line-height: 1.4;
  color: var(--foreground);
  letter-spacing: -0.005em;
  text-wrap: balance;
}
.bc-illu {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  margin-top: auto;
}
.bc-illu img {
  width: 100%;
  max-width: 260px;
  height: auto;
  display: block;
  mix-blend-mode: multiply;
}

.bc-arrow {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: var(--accent);
  color: #fff;
  border: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s var(--ease-out), transform 0.2s var(--ease-out), box-shadow 0.2s var(--ease-out);
  box-shadow: 0 8px 20px -8px rgba(241,85,51,0.5);
}
.bc-arrow:hover {
  background: #d94a2a;
  transform: scale(1.05);
  box-shadow: 0 12px 26px -8px rgba(241,85,51,0.6);
}
.bc-arrow:active { transform: scale(0.96); }
.bc-arrow:focus-visible { outline: 2px solid var(--foreground); outline-offset: 3px; }

.bc-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 28px;
}
.bc-dot {
  width: 8px;
  height: 8px;
  border-radius: 9999px;
  border: 0;
  background: rgba(15,15,15,0.18);
  cursor: pointer;
  padding: 0;
  transition: background 0.2s, width 0.3s var(--ease-out);
}
.bc-dot:hover { background: rgba(15,15,15,0.36); }
.bc-dot.active {
  background: var(--accent);
  width: 24px;
}

/* Tablet: 2 cards visible */
@media (max-width: 1024px) {
  .benefits-carousel { --bc-card-w: calc((100% - 1 * var(--bc-gap)) / 2); --bc-gap: 16px; }
  .bc-arrow { width: 48px; height: 48px; }
  .bc-card { min-height: 420px; padding: 32px 28px 24px; }
}

/* Mobile: 1 card visible, hide arrows, rely on swipe + dots */
@media (max-width: 640px) {
  .benefits-row { flex-direction: column; align-items: flex-start; gap: 12px; margin-bottom: 24px; }
  .benefits-carousel { --bc-card-w: 100%; --bc-gap: 16px; }
  .bc-arrows { display: none; }
  .bc-card { min-height: auto; padding: 28px 24px 24px; border-radius: 20px; }
  .bc-quote { font-size: clamp(17px, 4.4vw, 20px); line-height: 1.45; }
  .bc-illu img { max-width: 220px; }
  .bc-dots { margin-top: 20px; }
}
.benefit {
  display: flex;
  align-items: flex-start;
  gap: 24px;
  border: 1px solid var(--fg-10);
  border-radius: 12px;
  padding: 24px 32px;
}
.benefit .num { font-size: 32px; font-weight: 600; color: var(--accent); line-height: 1; flex-shrink: 0; }
.benefit p    { margin: 0; font-size: 22px; font-weight: 500; line-height: 1.3; }

/* ---- Comparison ---- */
.compare-row { display: flex; gap: 24px; align-items: flex-start; }
.compare-card { flex: 1; border-radius: 20px; overflow: hidden; }
.compare-card.others { background: #fff; box-shadow: var(--shadow-card); }
.compare-card.flou   { background: var(--dark-bg); transform: translateY(-16px); }
.compare-header { padding: 20px 24px; font-size: 22px; font-weight: 700; }
.compare-card.others .compare-header { color: var(--fg-40); border-bottom: 1px solid var(--fg-05); }
.compare-card.flou   .compare-header { color: #fff; border-bottom: 1px solid var(--on-dark-10); }
.compare-item {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 24px;
  font-size: 15px;
}
.compare-card.others .compare-item { color: var(--fg-60); border-bottom: 1px solid var(--fg-05); font-weight: 500; }
.compare-card.flou   .compare-item { color: #fff; border-bottom: 1px solid var(--on-dark-10); font-weight: 600; }
.compare-card .compare-item:last-child { border-bottom: none; padding-bottom: 24px; }
.compare-card .compare-item:first-of-type { padding-top: 18px; }
.compare-card.others .icon { color: var(--fg-25); }
.compare-card.flou   .icon { color: var(--accent); }

/* ---- FAQ ---- */
.faq-list { max-width: 760px; margin: 48px auto 0; }
.faq-item { border-bottom: 1px solid var(--fg-10); transition: background .25s var(--ease-out); border-radius: 8px; padding: 0 16px; margin: 0 -16px; }
.faq-item:hover { background: rgba(0,0,0,0.02); }
.faq-item.open { background: rgba(241,85,51,0.04); }
.faq-q {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 24px;
  width: 100%; padding: 22px 0; background: none; border: none; text-align: left;
  cursor: pointer;
  font-size: 18px; font-weight: 500; line-height: 1.4; color: var(--foreground);
  min-height: 44px;
}
.faq-q > span:first-child { flex: 1; min-width: 0; }
.faq-toggle {
  flex-shrink: 0;
  position: relative;
  width: 24px; height: 24px;
  margin-top: 2px;
  font-size: 0;
  color: var(--foreground);
}
.faq-toggle::before,
.faq-toggle::after {
  content: "";
  position: absolute;
  left: 50%; top: 50%;
  background: currentColor;
  border-radius: 1px;
  transition: transform 0.3s var(--ease-out), opacity 0.2s var(--ease-out);
}
.faq-toggle::before { width: 14px; height: 1.75px; transform: translate(-50%, -50%); }
.faq-toggle::after  { width: 1.75px; height: 14px; transform: translate(-50%, -50%); }
.faq-item.open .faq-toggle { color: var(--accent); }
.faq-item.open .faq-toggle::after { transform: translate(-50%, -50%) scaleY(0); opacity: 0; }
.faq-item.open .faq-toggle::before { transform: translate(-50%, -50%) rotate(0deg); }
.faq-a {
  max-height: 0; overflow: hidden; transition: max-height 0.3s var(--ease-out), padding 0.3s var(--ease-out);
  font-size: 15px; line-height: 1.6; color: var(--fg-70);
}
.faq-item.open .faq-a { max-height: 400px; padding: 0 0 20px; }

/* ---- Portfolio grid ---- */
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 20px;
  margin-top: 48px;
}
.video-card {
  position: relative;
  aspect-ratio: 9/16;
  border-radius: 20px;
  overflow: hidden;
  background: #111;
  cursor: pointer;
  transition: transform 0.2s;
}
.video-card:hover { transform: translateY(-2px); }
.video-card img {
  width: 100%; height: 100%; object-fit: cover;
  /* Default: anchor toward bottom-center so subjects (people, products) stay framed
     when 16:9 source is cropped into 9:16 card. Per-card overrides below. */
  object-position: 50% 60%;
  transform: scale(1.06);   /* subtle zoom so we always fill nicely */
  transform-origin: center 60%;
  transition: transform 0.7s var(--ease-premium);
}
.video-card:hover img { transform: scale(1.10); }

/* Per-card focal points — tuned to source images */
.video-card[data-focus="aqua-carpatica"] img      { object-position: 35% 50%; }  /* face left-side */
.video-card[data-focus="honda"] img               { object-position: 60% 65%; transform: scale(1.12); }  /* rider lower-right */
.video-card[data-focus="toyota"] img,
.video-card[data-focus="toyota-pres"] img,
.video-card[data-focus="toyota-sud"] img          { object-position: 50% 70%; transform: scale(1.10); } /* people in foreground */
.video-card[data-focus="adidas"] img,
.video-card[data-focus="andrei-mocanu"] img       { object-position: 50% 35%; }  /* portraits — shift up */
.video-card[data-focus="oana-radu"] img           { object-position: 50% 30%; }
.video-card[data-focus="aria-margo"] img          { object-position: 50% 40%; }
.video-card[data-focus="cupio"] img               { object-position: 50% 45%; }
.video-card[data-focus="mallevo"] img             { object-position: 50% 50%; }
.video-card[data-focus="kubbio"] img              { object-position: 50% 50%; }
.video-card[data-focus="guzzu"] img               { object-position: 50% 45%; }
.video-card .top-grad {
  position: absolute; inset: 0 0 auto 0; height: 96px;
  background: linear-gradient(to bottom, rgba(0,0,0,0.6), transparent);
}
.video-card .brand {
  position: absolute; top: 16px; left: 16px;
  font-size: 13px; font-weight: 600; letter-spacing: 0.02em; color: #fff;
}
.video-card .play-btn {
  position: absolute; inset: 0; margin: auto;
  width: 64px; height: 64px; border-radius: 9999px;
  background: var(--accent);
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 18px rgba(0,0,0,0.25);
  transition: transform 0.2s;
}
.video-card:hover .play-btn { transform: scale(1.1); }
.video-card .overlay {
  position: absolute; inset: 0; background: rgba(0,0,0,0.15);
  transition: background 0.3s;
}
.video-card:hover .overlay { background: rgba(0,0,0,0.30); }

/* ---- Logo cloud ---- */
.logo-cloud {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-left: 1px solid var(--border-subtle);
  border-right: 1px solid var(--border-subtle);
  position: relative;
  margin-top: 48px;
}
.logo-cell {
  background: var(--background);
  padding: 36px 24px;
  min-height: 120px;
  display: flex; align-items: center; justify-content: center;
  border-bottom: 1px solid var(--border-subtle);
  border-right: 1px solid var(--border-subtle);
  position: relative;
}
.logo-cell:nth-child(4n) { border-right: none; }
.logo-cell:nth-child(2n+1).alt,
.logo-cell.alt { background: var(--surface); }
.logo-cell img {
  max-height: 36px; max-width: 140px;
  width: auto; height: auto;
  object-fit: contain;
  filter: grayscale(0.15);
  transition: filter .3s ease, transform .35s var(--ease-premium);
}
.logo-cell:hover img { filter: grayscale(0); transform: scale(1.04); }

/* Compact logo strip — single row after hero */
.logo-cloud-section.is-compact .logo-cloud-line {
  font-size: 13px; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--muted); margin-top: 8px; font-weight: 500;
}
.is-compact + * { margin-top: 0; }
.logo-cloud-section.is-compact .logo-cloud {
  grid-template-columns: repeat(5, 1fr);
  border: 1px solid rgba(15,15,15,0.06);
  border-radius: 16px;
  overflow: hidden;
  background: var(--background);
}
.logo-cloud-section.is-compact .logo-cell {
  background: transparent;
  border-right: 1px solid rgba(15,15,15,0.06);
  border-bottom: none;
  padding: 28px 16px;
  min-height: 96px;
}
.logo-cloud-section.is-compact .logo-cell:nth-child(5n) { border-right: none; }
.logo-cloud-section.is-compact .logo-cell.alt { background: rgba(0,0,0,0.015); }
.logo-cloud-section.is-compact .logo-cell img { max-height: 28px; max-width: 110px; }

/* ---- Footer ---- */
.footer {
  position: relative;
  background: var(--dark-bg);
  color: #fff;
  overflow: hidden;
  padding: 0;
}
.footer-aurora {
  position: absolute;
  left: 50%; top: 50%;
  width: 80vw; height: 60vh;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  filter: blur(80px);
  background: radial-gradient(circle at 50% 50%, rgba(241,85,51,0.18) 0%, rgba(241,85,51,0.06) 40%, transparent 70%);
  pointer-events: none;
  z-index: 0;
  animation: footer-breathe 8s ease-in-out infinite alternate;
}
@keyframes footer-breathe {
  0%   { transform: translate(-50%, -50%) scale(1);   opacity: 0.5; }
  100% { transform: translate(-50%, -50%) scale(1.12); opacity: 0.85; }
}
.footer-grid-bg {
  position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background-size: 60px 60px;
  background-image:
    linear-gradient(to right, rgba(255,255,255,0.03) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255,255,255,0.03) 1px, transparent 1px);
  -webkit-mask-image: linear-gradient(to bottom, transparent, black 25%, black 70%, transparent);
          mask-image: linear-gradient(to bottom, transparent, black 25%, black 70%, transparent);
}
.footer-giant {
  position: absolute;
  bottom: -3vh; left: 50%; transform: translateX(-50%);
  font-size: clamp(120px, 26vw, 520px);
  line-height: 0.75;
  font-weight: 900;
  letter-spacing: -0.05em;
  color: transparent;
  -webkit-text-stroke: 1px rgba(255,255,255,0.04);
  background: linear-gradient(180deg, rgba(255,255,255,0.07) 0%, transparent 55%);
  -webkit-background-clip: text;
          background-clip: text;
  user-select: none;
  pointer-events: none;
  white-space: nowrap;
  z-index: 0;
}
.footer-clients {
  position: relative; z-index: 1;
  margin-top: 48px;
  border-top: 1px solid rgba(255,255,255,0.08);
  border-bottom: 1px solid rgba(255,255,255,0.08);
  background: rgba(0,0,0,0.5);
  backdrop-filter: blur(2px);
  padding: 16px 0;
  transform: rotate(-2deg) scale(1.1);
  overflow: hidden;
}
.footer-marquee {
  display: flex; gap: 48px;
  animation: footer-marquee 38s linear infinite;
  white-space: nowrap;
  padding: 8px 24px;
}
.footer-marquee.reverse { animation: footer-marquee 45s linear infinite reverse; }
.footer-marquee img {
  height: 30px; width: auto; flex-shrink: 0;
  mix-blend-mode: lighten;
  filter: invert(1) grayscale(1) contrast(1.1);
  opacity: 0.55;
}
@keyframes footer-marquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

.footer-cta {
  position: relative; z-index: 1;
  padding: 80px 24px 56px;
  text-align: center;
  max-width: 960px;
  margin: 0 auto;
}
.footer-cta h2 {
  margin: 0;
  font-size: clamp(28px, 4.5vw, 56px);
  font-weight: 900;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: #fff;
}
.footer-cta h2 .accent { color: var(--accent); }
.footer-cta-actions { margin-top: 40px; display: flex; gap: 16px; flex-wrap: wrap; justify-content: center; }

.footer-pill {
  padding: 18px 40px;
  border-radius: 9999px;
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;
  transition: all 0.4s var(--ease-out);
  display: inline-flex; align-items: center; gap: 8px;
}
.footer-pill.accent {
  background: rgba(241,85,51,0.10);
  border: 1px solid rgba(241,85,51,0.25);
  color: var(--accent);
  backdrop-filter: blur(16px);
}
.footer-pill.accent:hover {
  background: rgba(241,85,51,0.20);
  border-color: rgba(241,85,51,0.50);
  box-shadow: 0 0 40px rgba(241,85,51,0.15);
}
.footer-pill.glass {
  background: linear-gradient(145deg, rgba(255,255,255,0.03) 0%, rgba(255,255,255,0.01) 100%);
  border: 1px solid rgba(255,255,255,0.08);
  color: var(--on-dark-70);
  box-shadow: var(--shadow-pill-dark);
  backdrop-filter: blur(16px);
}
.footer-pill.glass:hover {
  background: linear-gradient(145deg, rgba(255,255,255,0.08) 0%, rgba(255,255,255,0.02) 100%);
  border-color: rgba(255,255,255,0.20);
  color: #fff;
}

.footer-bottom {
  position: relative; z-index: 2;
  border-top: 1px solid rgba(255,255,255,0.10);
  padding: 24px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 32px;
  flex-wrap: wrap;
}
.footer-brand { display: flex; flex-direction: column; gap: 12px; }
.footer-brand .logo {
  font-size: 24px;
  font-weight: 700;
  line-height: 1;
  display: inline-flex;
  align-items: center;
}
.footer-brand .logo img {
  display: block;
  height: 32px;
  width: auto;
}
.footer-brand .logo .dot { color: var(--accent); }
.footer-brand .copy {
  font-size: 10px; letter-spacing: 0.16em; text-transform: uppercase;
  color: rgba(255,255,255,0.60);
}
.footer-nav { display: flex; flex-direction: column; gap: 14px; }
.footer-nav-row { display: flex; flex-wrap: wrap; gap: 20px; }
.footer-nav-row a {
  font-size: 11px; font-weight: 500; letter-spacing: 0.16em; text-transform: uppercase;
  transition: color 0.2s;
}
.footer-nav-row.primary a { color: rgba(255,255,255,0.50); }
.footer-nav-row.primary a:hover { color: #fff; }
.footer-nav-row.secondary a { color: rgba(255,255,255,0.65); }
.footer-nav-row.secondary a:hover { color: #fff; }
.footer-contact { display: flex; flex-direction: column; gap: 8px; }
.footer-contact-row {
  display: flex; align-items: center; gap: 10px;
  font-size: 12px;
}
.footer-contact-row .label {
  font-size: 9px; font-weight: 500; letter-spacing: 0.16em; text-transform: uppercase;
  color: rgba(255,255,255,0.55);
}
.footer-contact-row .val { color: rgba(255,255,255,0.75); }
.footer-legal-row {
  display: flex; flex-wrap: wrap; gap: 20px; margin-top: 12px;
  font-size: 12px;
}
.footer-legal-row a,
.footer-legal-row .footer-legal-btn {
  color: rgba(255,255,255,0.70);
  background: transparent; border: 0; padding: 0;
  font: inherit; cursor: pointer;
  min-height: 44px; display: inline-flex; align-items: center;
}
.footer-legal-row a:hover,
.footer-legal-row .footer-legal-btn:hover {
  color: #fff;
  text-decoration: underline;
}

/* ---- Filter bar (portfolio page) ---- */
/* ---- Unified page scaffolding (shared by /portfolio, /contact, /about, /services) ---- */
.page,
.portfolio-page, .contact-page, .about-page, .service-page, .services-hub, .case-study-page { padding-top: 88px; }
@media (max-width: 640px) {
  .case-study-page { padding-top: 80px; }
}

/* ---- Case study hero (text + video, side-by-side on desktop) ---- */
.case-hero-split { padding-bottom: 32px; }
.case-hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 56px;
  align-items: center;
}
.case-hero-text { min-width: 0; }
.case-hero-text .section-title { max-width: none; font-size: clamp(34px, 4.4vw, 56px); }
.case-hero-text .section-subtitle { max-width: none; }

.case-hero-media {
  display: block;
  width: 100%;
  position: relative;
  border: 0;
  padding: 0;
  margin: 0;
  background: var(--surface, #FAFAFA);
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 30px 80px -20px rgba(0,0,0,0.30);
  cursor: default;
  aspect-ratio: 1 / 1;
  transition: transform 0.4s var(--ease-premium), box-shadow 0.4s var(--ease-premium);
}
.case-hero-media.is-clickable { cursor: pointer; }
.case-hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s var(--ease-premium);
}
.case-hero-media.is-clickable:hover img { transform: scale(1.04); }
.case-hero-media.is-clickable:hover { box-shadow: 0 40px 100px -20px rgba(0,0,0,0.40); }
.case-hero-play {
  position: absolute;
  inset: 50% auto auto 50%;
  transform: translate(-50%, -50%);
  width: 64px;
  height: 64px;
  border-radius: 9999px;
  background: var(--accent);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 14px 32px -8px rgba(241,85,51,0.55);
  transition: transform 0.3s var(--ease-premium);
  pointer-events: none;
}
.case-hero-media.is-clickable:hover .case-hero-play { transform: translate(-50%, -50%) scale(1.08); }
.case-hero-play svg { margin-left: 3px; }

@media (max-width: 1024px) {
  .case-hero-grid { gap: 40px; grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
  .case-hero-split { padding-bottom: 16px; }
  .case-hero-grid { grid-template-columns: 1fr; gap: 28px; }
  .case-hero-media { border-radius: 18px; aspect-ratio: 4 / 3; max-width: 520px; margin-inline: auto; }
  .case-hero-play { width: 56px; height: 56px; }
  .case-hero-play svg { width: 20px; height: 20px; }
}
@media (max-width: 480px) {
  .case-hero-media { border-radius: 16px; aspect-ratio: 1 / 1; }
  .case-hero-play { width: 52px; height: 52px; }
}

/* ---- Case study final CTA: warm dark surface, not black ---- */
.case-cta {
  background: linear-gradient(180deg, var(--surface, #FAFAFA) 0%, var(--background, #FFFEF5) 100%);
  position: relative;
  isolation: isolate;
}
.case-cta::before {
  content: "";
  position: absolute;
  inset: auto 0 0 50%;
  transform: translateX(-50%);
  width: min(720px, 90%);
  height: 60%;
  background: radial-gradient(ellipse at center bottom, rgba(241,85,51,0.10), transparent 70%);
  pointer-events: none;
  z-index: -1;
}
.page-hero,
.portfolio-hero, .contact-hero { padding: 56px 0 16px; }
.page-hero .section-title { font-size: clamp(40px, 6vw, 64px); max-width: 880px; }
.page-hero .section-subtitle { max-width: 720px; }
.page-body { padding-top: 24px; }
@media (max-width: 640px) {
  .page,
  .portfolio-page, .contact-page, .about-page, .service-page, .services-hub { padding-top: 80px; }
  .page-hero,
  .portfolio-hero, .contact-hero { padding: 32px 0 8px; }
  .page-hero .section-title { font-size: clamp(30px, 9vw, 40px); }
  .page-body { padding-top: 20px; }
}

.portfolio-grid.wide { grid-template-columns: repeat(4, 1fr); gap: 20px; }
@media (max-width: 1100px) { .portfolio-grid.wide { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 700px) { .portfolio-grid.wide { grid-template-columns: 1fr 1fr; gap: 14px; } }

.filter-bar {
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 16px;
  margin-bottom: 32px;
}
@media (max-width: 640px) {
  .filter-bar { flex-direction: column; align-items: stretch; gap: 10px; margin-bottom: 20px; }
  .filter-tabs { justify-content: flex-start; }
  .result-count { text-align: left; }
}
.filter-tabs { display: flex; gap: 8px; flex-wrap: wrap; }
.filter-tab {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--fg-05); color: var(--foreground);
  border: none; border-radius: 9999px;
  padding: 10px 20px;
  font-size: 14px; font-weight: 500;
  transition: background 0.2s, color 0.2s;
}
.filter-tab:hover { background: var(--fg-10); }
.filter-tab.active { background: var(--foreground); color: #fff; }
.filter-tab .count {
  font-size: 11px; font-weight: 600;
  padding: 2px 8px; border-radius: 9999px;
  background: var(--fg-10); color: var(--fg-60);
}
.filter-tab.active .count { background: rgba(255,255,255,0.15); color: rgba(255,255,255,0.85); }
.result-count { font-size: 13px; color: var(--fg-60); }

/* ---- Lightbox ---- */
.lightbox {
  position: fixed; inset: 0; z-index: 100;
  background: rgba(10,10,10,0.85); backdrop-filter: blur(8px);
  display: flex; align-items: center; justify-content: center;
  padding: 24px;
  animation: fadeIn 0.2s ease-out;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.lightbox-close {
  position: absolute; top: 20px; right: 24px;
  width: 44px; height: 44px; border-radius: 9999px;
  background: rgba(255,255,255,0.1); border: 1px solid rgba(255,255,255,0.2);
  color: #fff; font-size: 28px; line-height: 1;
}
.lightbox-frame {
  position: relative;
  width: 100%;
  background: #0A0A0A; border-radius: 20px; overflow: hidden;
  box-shadow: var(--shadow-cinematic);
  margin: 0 auto;
}
/* Frame: aspect-ratio + dimensions set inline by VideoLightbox JS, based on real video size from Vimeo SDK */
.lightbox-frame {
  /* outer caps for safety; inline styles drive primary sizing */
  max-height: 90vh;
}
.lightbox-player {
  position: relative;
  width: 100%;
  height: 100%;
  background: #000;
  overflow: hidden;
}
.lightbox-spinner {
  position: absolute; inset: 0; margin: auto;
  width: 36px; height: 36px;
  border-radius: 50%;
  border: 3px solid rgba(255,255,255,0.18);
  border-top-color: var(--coral, #F15533);
  animation: lightbox-spin 0.9s linear infinite;
  z-index: 1;
}
@keyframes lightbox-spin { to { transform: rotate(360deg); } }
.lightbox-player iframe {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  border: 0;
}
.lightbox-meta {
  padding: 14px 20px; color: #fff;
  display: flex; justify-content: space-between; align-items: baseline;
  border-top: 1px solid rgba(255,255,255,0.08);
}
.lightbox-meta .brand { font-size: 18px; font-weight: 600; }
.lightbox-meta .cat { font-size: 12px; color: var(--on-dark-55); letter-spacing: 0.04em; }

/* ---- Contact page ---- */
.contact-page { padding-top: 88px; }
.contact-hero { padding: 56px 0 16px; }
.contact-layout {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 48px;
  align-items: start;
}
@media (max-width: 900px) { .contact-layout { grid-template-columns: 1fr; gap: 32px; } }

.contact-form {
  display: flex; flex-direction: column; gap: 20px;
  background: #fff;
  border: 1px solid var(--fg-10);
  border-radius: 20px;
  padding: 32px;
}
.contact-form .form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 600px) { .contact-form .form-row { grid-template-columns: 1fr; } }

.form-field { display: flex; flex-direction: column; gap: 6px; }
.form-field label,
.form-field .form-label {
  font-size: 13px; font-weight: 500; color: var(--foreground);
}
.form-field label .opt { color: var(--fg-70); font-weight: 400; }
.form-field .field-error {
  font-size: 13px; color: #B91C1C; margin-top: 4px;
}
.form-field input[aria-invalid="true"],
.form-field select[aria-invalid="true"],
.form-field textarea[aria-invalid="true"] {
  border-color: #DC2626;
  box-shadow: 0 0 0 3px rgba(220,38,38,0.12);
}
.form-field input:focus-visible,
.form-field select:focus-visible,
.form-field textarea:focus-visible {
  outline: 2px solid var(--foreground);
  outline-offset: 2px;
}
.form-field input,
.form-field select,
.form-field textarea {
  width: 100%; box-sizing: border-box;
  border: 1px solid var(--fg-10);
  background: #fff;
  border-radius: 12px;
  padding: 14px 14px;
  font-family: inherit; font-size: 16px; color: var(--foreground);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  min-height: 48px;
}
.form-field textarea { resize: vertical; min-height: 120px; line-height: 1.5; }
.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(241,85,51,0.15);
}

.chip-group { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  background: var(--fg-05); color: var(--foreground);
  border: 1px solid transparent;
  border-radius: 9999px;
  padding: 12px 18px;
  font-size: 14px; font-weight: 500;
  min-height: 44px;
  transition: all 0.2s;
}
.chip:hover { background: var(--fg-10); }
.chip.active { background: var(--accent); color: #fff; border-color: var(--accent); }

.form-actions {
  display: flex; align-items: center; gap: 16px;
  flex-wrap: wrap;
  margin-top: 4px;
}
.form-note { font-size: 13px; color: var(--fg-60); }

.contact-success {
  background: #fff;
  border: 1px solid var(--fg-10);
  border-radius: 20px;
  padding: 48px 32px;
  text-align: center;
  display: flex; flex-direction: column; align-items: center; gap: 12px;
}
.contact-success-icon {
  width: 64px; height: 64px; border-radius: 9999px;
  background: rgba(241,85,51,0.10);
  color: var(--accent);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 8px;
}
.contact-success h3 { margin: 0; font-size: 26px; font-weight: 600; }
.contact-success p { margin: 0 0 16px; color: var(--fg-60); max-width: 420px; line-height: 1.5; }

.contact-aside { display: flex; flex-direction: column; gap: 16px; }
.contact-info-card {
  background: var(--surface);
  border: 1px solid var(--fg-10);
  border-radius: 16px;
  padding: 24px;
}
.contact-info-card h4 { margin: 0 0 16px; font-size: 13px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--fg-60); font-weight: 600; }
.contact-link {
  display: flex; flex-direction: column; gap: 2px;
  padding: 10px 0;
  border-bottom: 1px solid var(--fg-05);
  text-decoration: none;
}
.contact-link:last-child { border-bottom: none; }
.contact-link .lbl { font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--fg-40); font-weight: 500; }
.contact-link .val { font-size: 16px; color: var(--foreground); font-weight: 500; }
.contact-link:not(.static):hover .val { color: var(--accent); }

.contact-steps { margin: 0; padding: 0 0 0 20px; display: flex; flex-direction: column; gap: 10px; }
.contact-steps li { font-size: 14px; line-height: 1.5; color: var(--fg-70); }
.contact-steps strong { color: var(--foreground); font-weight: 600; }

/* ---- Header active state ---- */
.header-links a.active { color: var(--foreground); }
.header-links a.active::after {
  content: ""; display: block; height: 2px; width: 16px;
  background: var(--accent); border-radius: 2px; margin: 4px auto 0;
}
@media (max-width: 900px) {
  .header-links { display: none; }
  .stats, .process-grid, .portfolio-grid, .logo-cloud { grid-template-columns: 1fr 1fr; }
  .logo-cloud-section.is-compact .logo-cloud { grid-template-columns: repeat(2, 1fr); }
  .logo-cloud-section.is-compact .logo-cell:nth-child(5n) { border-right: 1px solid rgba(15,15,15,0.06); }
  .logo-cloud-section.is-compact .logo-cell:nth-child(2n) { border-right: none; }
  .compare-row { flex-direction: column; }
  .compare-card.flou { transform: none; }
  .service-card ul { grid-template-columns: 1fr; }
}

/* ============================================================
   /portfolio/ Case Studies section
   1 hero card + 4 grid cards (2x2). Image + overlay text.
   Sits BELOW the video reel grid.

   Layout principle: hero card height equals the height of the
   secondary grid (2 rows + gap), so the row visually balances.
   ============================================================ */
.case-studies-section { padding-top: 24px; padding-bottom: 32px; }
.case-studies-head { text-align: center; margin-bottom: 56px; max-width: 640px; margin-left: auto; margin-right: auto; }
.case-studies-head .eyebrow { justify-content: center; }
@media (max-width: 640px) {
  .case-studies-head { margin-bottom: 32px; }
}

.featured-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  gap: 24px;
  align-items: stretch;
}
@media (max-width: 1000px) {
  .featured-grid { grid-template-columns: 1fr; gap: 20px; }
}

.featured-grid-secondary {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-auto-rows: 1fr;
  gap: 24px;
  min-height: 100%;
}
@media (max-width: 1000px) {
  .featured-grid-secondary { gap: 20px; min-height: 0; }
}
@media (max-width: 640px) {
  .featured-grid-secondary { gap: 12px; }
}

.featured-card {
  position: relative;
  display: block;
  border-radius: 24px;
  overflow: hidden;
  background: var(--surface-dark);
  text-decoration: none;
  color: #fff;
  isolation: isolate;
  transition: transform 280ms cubic-bezier(0.16, 1, 0.3, 1), box-shadow 280ms cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 8px 28px -12px rgba(0,0,0,0.25);
}
.featured-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 24px 48px -16px rgba(0,0,0,0.35);
}

/* Hero spans both rows of the secondary grid, matching its height */
.featured-card-hero {
  grid-row: span 1;
  border-radius: 28px;
  min-height: 580px;
}
.featured-card:not(.featured-card-hero) {
  aspect-ratio: 4 / 5;
}

@media (max-width: 1000px) {
  .featured-card-hero { aspect-ratio: 4 / 3; border-radius: 24px; min-height: 0; }
}
@media (max-width: 640px) {
  .featured-grid { gap: 12px; }
  .featured-card { border-radius: 18px; }
  .featured-card-hero { aspect-ratio: 4 / 5; border-radius: 20px; }
  .featured-card:not(.featured-card-hero) { aspect-ratio: 4 / 5; }
}

.featured-card img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 600ms cubic-bezier(0.16, 1, 0.3, 1);
}
.featured-card:hover img { transform: scale(1.05); }

/* Per-card focal point so faces / product land in frame */
.featured-card[data-focus="aqua-carpatica"] img { object-position: 35% 55%; }
.featured-card[data-focus="honda"] img          { object-position: 55% 50%; }
.featured-card[data-focus="toyota"] img         { object-position: 50% 60%; }
.featured-card[data-focus="aria-margo"] img     { object-position: 50% 22%; }
.featured-card[data-focus="cupio"] img          { object-position: 50% 35%; }

.featured-overlay {
  position: absolute; inset: 0;
  background:
    linear-gradient(to top, rgba(10,10,10,0.85) 0%, rgba(10,10,10,0.40) 40%, rgba(10,10,10,0) 70%),
    linear-gradient(to top, rgba(10,10,10,0.20) 0%, rgba(10,10,10,0) 30%);
  z-index: 1;
  transition: background 280ms ease;
}
.featured-card:hover .featured-overlay {
  background:
    linear-gradient(to top, rgba(10,10,10,0.88) 0%, rgba(10,10,10,0.45) 40%, rgba(10,10,10,0.05) 70%),
    linear-gradient(to top, rgba(10,10,10,0.25) 0%, rgba(10,10,10,0) 30%);
}

.featured-chip {
  position: absolute; top: 20px; left: 20px;
  background: var(--accent); color: #fff;
  font-size: 10px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase;
  padding: 7px 14px;
  border-radius: 9999px;
  z-index: 2;
  box-shadow: 0 4px 12px -2px rgba(241,85,51,0.4);
}
.featured-card-hero .featured-chip { top: 24px; left: 24px; }

.featured-meta {
  position: absolute;
  left: 24px; right: 24px; bottom: 24px;
  z-index: 2;
  color: #fff;
  display: flex; flex-direction: column;
}
.featured-card-hero .featured-meta { left: 32px; right: 32px; bottom: 32px; }
@media (max-width: 600px) {
  .featured-meta { left: 20px; right: 20px; bottom: 20px; }
  .featured-card-hero .featured-meta { left: 24px; right: 24px; bottom: 24px; }
}
@media (max-width: 480px) {
  .featured-card:not(.featured-card-hero) .featured-meta { left: 14px; right: 14px; bottom: 14px; }
  .featured-card:not(.featured-card-hero) .featured-brand { font-size: 18px; line-height: 1.1; }
  .featured-card:not(.featured-card-hero) .featured-metric { font-size: 12px; }
  .featured-card:not(.featured-card-hero) .featured-tag { font-size: 9px; letter-spacing: 0.14em; margin-bottom: 6px; }
  .featured-card:not(.featured-card-hero) .featured-cta { font-size: 11px; margin-top: 12px; }
  .featured-chip { font-size: 9px; padding: 5px 10px; top: 12px; left: 12px; }
  .featured-card-hero .featured-chip { top: 16px; left: 16px; }
}

.featured-tag {
  margin: 0 0 8px;
  font-size: 11px; font-weight: 600;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--accent-light, #FFA587);
}
.featured-brand {
  margin: 0 0 6px;
  font-size: 26px; font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.05;
  color: #fff;
}
.featured-card-hero .featured-brand {
  font-size: clamp(36px, 4vw, 52px);
  margin-bottom: 10px;
}
@media (max-width: 600px) {
  .featured-brand { font-size: 22px; }
  .featured-card-hero .featured-brand { font-size: 30px; }
}

.featured-metric {
  margin: 0;
  font-size: 14px; font-weight: 500;
  color: rgba(255,255,255,0.88);
  line-height: 1.4;
}
.featured-card-hero .featured-metric {
  font-size: 17px;
  font-weight: 500;
}

.featured-blurb {
  margin: 14px 0 0;
  font-size: 15px; line-height: 1.55;
  color: rgba(255,255,255,0.78);
  max-width: 520px;
}
@media (max-width: 600px) {
  .featured-blurb { font-size: 14px; max-width: 100%; }
}

.featured-cta {
  display: inline-flex; align-items: center;
  font-size: 13px; font-weight: 500;
  color: #fff;
  margin-top: 18px;
  align-self: flex-start;
  border-bottom: 1px solid rgba(255,255,255,0.4);
  padding-bottom: 3px;
  transition: color 200ms ease, border-color 200ms ease, transform 200ms ease;
}
.featured-card-hero .featured-cta {
  font-size: 14px;
  margin-top: 22px;
}
.featured-card:hover .featured-cta {
  color: var(--accent-light, #FFA587);
  border-color: var(--accent-light, #FFA587);
}
.featured-card:hover .featured-cta svg { transform: translateX(3px); }
.featured-cta svg { transition: transform 200ms ease; }

/* ============================================================
   Card-load animation (stagger fade-in for case studies grid)
   No IntersectionObserver dependency: fires on mount.
   ============================================================ */
.featured-grid > .featured-card,
.featured-grid-secondary > .featured-card {
  opacity: 0;
  transform: translateY(16px);
  animation: fmcCaseIn 480ms cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.featured-grid > .featured-card-hero { animation-delay: 0ms; }
.featured-grid-secondary > .featured-card:nth-child(1) { animation-delay: 100ms; }
.featured-grid-secondary > .featured-card:nth-child(2) { animation-delay: 180ms; }
.featured-grid-secondary > .featured-card:nth-child(3) { animation-delay: 260ms; }
.featured-grid-secondary > .featured-card:nth-child(4) { animation-delay: 340ms; }

@keyframes fmcCaseIn {
  to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  .featured-grid > .featured-card,
  .featured-grid-secondary > .featured-card {
    opacity: 1; transform: none; animation: none;
  }
}

/* ============================================================
   All Recent Work grid (videos only, on /portfolio/ top section)
   CSS-only fade-in, fires on every mount so filter-switch is smooth.
   ============================================================ */
.all-work-grid > * {
  opacity: 0;
  transform: translateY(12px);
  animation: fmcCardIn 320ms cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.all-work-grid > *:nth-child(1)  { animation-delay: 0ms; }
.all-work-grid > *:nth-child(2)  { animation-delay: 40ms; }
.all-work-grid > *:nth-child(3)  { animation-delay: 80ms; }
.all-work-grid > *:nth-child(4)  { animation-delay: 120ms; }
.all-work-grid > *:nth-child(5)  { animation-delay: 160ms; }
.all-work-grid > *:nth-child(6)  { animation-delay: 200ms; }
.all-work-grid > *:nth-child(7)  { animation-delay: 240ms; }
.all-work-grid > *:nth-child(8)  { animation-delay: 280ms; }
.all-work-grid > *:nth-child(9)  { animation-delay: 320ms; }
.all-work-grid > *:nth-child(10) { animation-delay: 360ms; }
.all-work-grid > *:nth-child(n+11) { animation-delay: 400ms; }

@keyframes fmcCardIn {
  to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  .all-work-grid > * { opacity: 1; transform: none; animation: none; }
}

/* "Case Study" chip kept for homepage PortfolioGrid (mixed mode) */
.video-card .case-chip {
  position: absolute; top: 12px; left: 12px;
  background: var(--accent); color: #fff;
  font-size: 10px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 9999px;
  z-index: 3;
}

/* When .video-card is an <a> (homepage mixed grid), keep button-style look */
a.video-card { text-decoration: none; cursor: pointer; }

/* ============================================================
   Results Marquee — 2 rows of TikTok thumbnails scrolling
   continuously in opposite directions. No text, no captions,
   no pause-on-hover. Images keep native 424x558 ratio (no crop).
   ============================================================ */

.results-section {
  padding-top: 40px;
  padding-bottom: 64px;
  background: var(--background);
  overflow: hidden;
}

.results-marquee-wrap {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 20px;
  --results-marquee-duration: 80s;

  -webkit-mask-image: linear-gradient(to right, transparent 0, black 4%, black 96%, transparent 100%);
          mask-image: linear-gradient(to right, transparent 0, black 4%, black 96%, transparent 100%);
}

.results-marquee {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  width: max-content;
  will-change: transform;
}

.results-marquee-left {
  animation: results-marquee-left var(--results-marquee-duration) linear infinite;
}

.results-marquee-right {
  animation: results-marquee-right var(--results-marquee-duration) linear infinite;
}

/* Continuous scroll — no pause on hover (Vlad explicit). */

.result-thumb {
  flex-shrink: 0;
  height: clamp(280px, 38vh, 380px);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 6px 18px rgba(15, 15, 15, 0.10), 0 2px 6px rgba(15, 15, 15, 0.06);
  background: #000;
}

.result-thumb img {
  display: block;
  height: 100%;
  width: auto;
  object-fit: contain;
  object-position: center;
  user-select: none;
  -webkit-user-drag: none;
}

@keyframes results-marquee-left {
  0%   { transform: translate3d(0, 0, 0); }
  100% { transform: translate3d(calc(-50% - 10px), 0, 0); }
}

@keyframes results-marquee-right {
  0%   { transform: translate3d(calc(-50% - 10px), 0, 0); }
  100% { transform: translate3d(0, 0, 0); }
}

@media (prefers-reduced-motion: reduce) {
  .results-marquee-left,
  .results-marquee-right { animation: none; }
  .results-marquee-wrap {
    -webkit-mask-image: none;
            mask-image: none;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
  }
  .result-thumb { scroll-snap-align: start; }
}

@media (max-width: 700px) {
  .results-section { padding-top: 24px; padding-bottom: 48px; }
  .results-marquee-wrap {
    --results-marquee-duration: 60s;
    gap: 14px;
  }
  .results-marquee { gap: 14px; }
  .result-thumb {
    height: clamp(220px, 36vh, 280px);
    border-radius: 14px;
  }
}
