/* Inner page styles — shared by services, work, about, contact */

.page-hero {
  padding: calc(var(--nav-h) + 96px) var(--pad) 96px;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}
.page-hero__inner { max-width: 1440px; margin: 0 auto; }
.page-hero__brand {
  display: block;
  width: 239px; height: 91px;
  margin-bottom: 56px;
}
.page-hero__eyebrow {
  font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.2em;
  text-transform: uppercase; color: var(--ink-3); margin-bottom: 28px;
  display: inline-flex; align-items: center; gap: 8px;
}
.page-hero__eyebrow::before {
  content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--dva-red);
}
.page-hero__h1 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(48px, 8vw, 144px);
  letter-spacing: -0.045em;
  line-height: 0.92;
  margin: 0 0 32px;
  text-wrap: balance;
  max-width: 14ch;
}
.page-hero__h1 em { font-style: italic; font-weight: 500; color: var(--dva-red); }
.page-hero__sub {
  font-size: clamp(18px, 1.4vw, 24px);
  line-height: 1.45;
  color: var(--ink-2);
  max-width: 56ch;
}

/* Feature row — alternating image/text, Apple's "feature spotlight" pattern */
.feature {
  padding: clamp(80px, 12vh, 140px) var(--pad);
  border-top: 1px solid var(--line);
  background: var(--bg);
}
.feature--alt { background: var(--bg-alt); }
.feature--dark { background: var(--bg-dark); color: #fff; border-color: var(--line-dark); }
.feature__inner {
  max-width: 1440px; margin: 0 auto;
  display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center;
}
@media (max-width: 900px) { .feature__inner { grid-template-columns: 1fr; gap: 32px; } }
.feature__inner.flip { direction: rtl; }
.feature__inner.flip > * { direction: ltr; }
.feature__h {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(32px, 4vw, 64px);
  letter-spacing: -0.04em; line-height: 1; margin: 0 0 20px;
  max-width: 14ch; text-wrap: balance;
}
.feature__h em { font-style: italic; color: var(--dva-red); font-weight: 500; }
.feature__desc { font-size: 17px; line-height: 1.55; color: var(--ink-2); max-width: 52ch; margin: 0 0 24px; }
.feature--dark .feature__desc { color: #b8b8b8; }
.feature__bullets { list-style: none; padding: 0; margin: 0 0 28px; display: grid; gap: 10px; }
.feature__bullets li { display: flex; gap: 10px; font-size: 15px; color: var(--ink-2); }
.feature__bullets li::before { content: "●"; color: var(--dva-red); font-size: 8px; margin-top: 8px; }
.feature--dark .feature__bullets li { color: #ccc; }

.feature__viz {
  border-radius: 24px;
  aspect-ratio: 4/3;
  position: relative;
  overflow: hidden;
  background: var(--bg-alt);
  border: 1px solid var(--line);
  display: grid; place-items: center;
  font-family: var(--font-mono); font-size: 11px; color: var(--ink-3);
  letter-spacing: 0.18em; text-transform: uppercase;
}
.feature--dark .feature__viz { background: #161616; border-color: var(--line-dark); color: #888; }
.feature__viz.viz-dark { background: var(--bg-dark); color: #888; border-color: var(--line-dark); }
.feature__viz.viz-red  { background: var(--dva-red); color: rgba(255,255,255,0.7); border-color: transparent; }

/* Decorative stripe placeholders */
.stripes {
  position: absolute; inset: 0;
  background: repeating-linear-gradient(45deg, transparent 0 18px, rgba(0,0,0,0.04) 18px 19px);
}
.feature--dark .stripes,
.feature__viz.viz-dark .stripes,
.feature__viz.viz-red .stripes { background: repeating-linear-gradient(45deg, transparent 0 18px, rgba(255,255,255,0.06) 18px 19px); }

.placeholder-label {
  position: relative; z-index: 1;
  background: rgba(255,255,255,0.85);
  padding: 6px 12px; border-radius: 999px;
  border: 1px solid var(--line);
}
.feature--dark .placeholder-label,
.viz-dark .placeholder-label,
.viz-red .placeholder-label {
  background: rgba(0,0,0,0.4); color: #fff; border-color: rgba(255,255,255,0.2);
}

/* Product cards — denser grid for SaaS / AI listings */
.product-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px;
  max-width: 1440px; margin: 48px auto 0;
}
@media (max-width: 900px) { .product-grid { grid-template-columns: 1fr; } }
.pcard {
  background: #fff; border: 1px solid var(--line); border-radius: 24px;
  padding: 32px; min-height: 280px;
  display: flex; flex-direction: column; justify-content: space-between;
  transition: transform 250ms var(--ease-out), border-color 200ms ease, box-shadow 300ms ease;
  position: relative; overflow: hidden;
  transform-style: preserve-3d;
  will-change: transform;
}
.pcard::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(
    600px circle at var(--mx, 50%) var(--my, 50%),
    rgba(229,52,60,0.18),
    transparent 40%
  );
  opacity: 0;
  transition: opacity 300ms ease;
  pointer-events: none;
  z-index: 0;
}
.pcard::after {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  padding: 1px;
  background: radial-gradient(
    300px circle at var(--mx, 50%) var(--my, 50%),
    var(--dva-red),
    transparent 50%
  );
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  opacity: 0;
  transition: opacity 300ms ease;
  pointer-events: none;
  z-index: 1;
}
.pcard:hover { transform: translateY(-3px); box-shadow: 0 30px 60px -20px rgba(229,52,60,0.25); }
.pcard:hover::before, .pcard:hover::after { opacity: 1; }
.pcard > * { position: relative; z-index: 2; }

/* Dark variant — stronger glow on dark backgrounds */
.feature--dark .pcard::before,
.pcard[style*="background:#161616"]::before {
  background: radial-gradient(
    600px circle at var(--mx, 50%) var(--my, 50%),
    rgba(229,52,60,0.32),
    transparent 40%
  );
}
.feature--dark .pcard:hover,
.pcard[style*="background:#161616"]:hover {
  box-shadow: 0 30px 80px -20px rgba(229,52,60,0.45);
}
.pcard__icon {
  transition: transform 400ms var(--ease-out), background 300ms ease;
}
.pcard:hover .pcard__icon {
  transform: scale(1.12) rotate(-6deg);
  background: var(--dva-red);
  color: #fff;
}
.pcard__icon {
  width: 44px; height: 44px; border-radius: 12px;
  background: var(--dva-red-soft);
  display: grid; place-items: center;
  margin-bottom: 24px;
  color: var(--dva-red);
  font-family: var(--font-mono); font-weight: 600; font-size: 14px;
}
.pcard__h {
  font-family: var(--font-display);
  font-size: 22px; font-weight: 600; letter-spacing: -0.025em; line-height: 1.1;
  margin: 0 0 8px;
}
.pcard__d { font-size: 14.5px; line-height: 1.5; color: var(--ink-2); margin: 0 0 24px; }
.pcard__foot {
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--ink-3);
}

/* Work / case study list */
.cases {
  max-width: 1440px; margin: 0 auto;
  display: grid; gap: 0;
}
.case {
  display: grid; grid-template-columns: 100px 1.4fr 1fr 1fr auto;
  gap: 32px; align-items: center;
  padding: 32px 0; border-top: 1px solid var(--line);
  position: relative;
  transition: padding 300ms ease;
}
.case:last-child { border-bottom: 1px solid var(--line); }
.case:hover { padding-left: 16px; padding-right: 16px; background: var(--bg-alt); }
@media (max-width: 900px) { .case { grid-template-columns: 1fr; gap: 8px; } }
.case__num { font-family: var(--font-mono); font-size: 13px; color: var(--ink-3); }
.case__client {
  font-family: var(--font-display); font-weight: 600;
  font-size: clamp(22px, 2vw, 34px); letter-spacing: -0.025em; line-height: 1;
}
.case__cat { font-size: 13px; color: var(--ink-2); }
.case__tags { display: flex; flex-wrap: wrap; gap: 6px; }
.case__tag {
  font-size: 11px; padding: 4px 10px;
  border: 1px solid var(--line); border-radius: 999px;
  color: var(--ink-2);
}
.case__arrow {
  width: 36px; height: 36px; border-radius: 50%;
  border: 1px solid var(--line);
  display: grid; place-items: center;
  transition: background 200ms ease, color 200ms ease, border-color 200ms ease;
}
.case:hover .case__arrow { background: var(--dva-red); color: #fff; border-color: var(--dva-red); }

/* About — values blocks */
.values { max-width: 1440px; margin: 0 auto; display: grid; grid-template-columns: repeat(3,1fr); gap: 8px; }
@media (max-width: 900px) { .values { grid-template-columns: 1fr; } }
.value {
  background: var(--bg-alt); border-radius: 24px; padding: 40px;
  min-height: 320px; display: flex; flex-direction: column; justify-content: space-between;
}
.value__num { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.2em; color: var(--ink-3); }
.value__h {
  font-family: var(--font-display); font-weight: 600;
  font-size: clamp(24px, 2.4vw, 36px); letter-spacing: -0.03em; line-height: 1.05;
  margin: 0;
}
.value__d { font-size: 15px; color: var(--ink-2); line-height: 1.5; margin: 0; }

/* Team scroller — horizontal scroll with snap + arrow buttons */
.team-scroller {
  position: relative;
  max-width: 100%;
  margin: 0 auto;
}
.team-scroller__viewport {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding: 8px var(--pad);
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.team-scroller__viewport::-webkit-scrollbar { display: none; }
.team-scroller__viewport .team-card {
  flex: 0 0 clamp(220px, 22vw, 320px);
  scroll-snap-align: start;
}
.team-card {
  aspect-ratio: 3/4; border-radius: 20px; overflow: hidden; position: relative;
  background: var(--bg-alt);
  border: 1px solid var(--line);
  /* Reveal-on-scroll initial state — dramatic */
  opacity: 0;
  transform: translateY(80px) scale(0.85) rotate(-3deg);
  filter: blur(8px);
  transition: opacity 900ms cubic-bezier(0.22, 1, 0.36, 1),
              transform 900ms cubic-bezier(0.34, 1.56, 0.64, 1),
              filter 700ms ease,
              border-color 300ms ease;
  transition-delay: calc(var(--i, 0) * 140ms);
}
.team-card.in {
  opacity: 1;
  transform: translateY(0) scale(1) rotate(0deg);
  filter: blur(0);
  animation: teamCardPulse 2.2s ease-in-out infinite;
  animation-delay: calc(var(--i, 0) * 140ms + 1s);
}
.team-card:hover {
  animation-play-state: paused;
  transform: translateY(-8px) scale(1.03) !important;
  border-color: var(--dva-red);
  z-index: 2;
}
@keyframes teamCardPulse {
  0%, 100% {
    box-shadow:
      0 0 0 0 rgba(225, 53, 39, 0),
      0 4px 12px -4px rgba(0, 0, 0, 0.08);
    border-color: var(--line);
    transform: translateY(0) scale(1);
  }
  50% {
    box-shadow:
      0 0 0 12px rgba(225, 53, 39, 0.08),
      0 20px 50px -10px rgba(225, 53, 39, 0.25);
    border-color: var(--dva-red, #e13527);
    transform: translateY(-6px) scale(1.015);
  }
}
@media (prefers-reduced-motion: reduce) {
  .team-card { transition: none; opacity: 1; transform: none; filter: none; }
  .team-card.in { animation: none; }
}
.team-scroller__nav {
  display: flex; gap: 10px; justify-content: flex-end;
  max-width: 1440px; margin: 24px auto 0; padding: 0 var(--pad);
}
.team-scroller__btn {
  width: 48px; height: 48px; border-radius: 50%;
  border: 1px solid var(--line);
  display: grid; place-items: center;
  background: #fff;
  transition: background 200ms ease, color 200ms ease, border-color 200ms ease, opacity 200ms ease;
}
.team-scroller__btn:hover { background: var(--dva-red); color: #fff; border-color: var(--dva-red); }
.team-scroller__btn:disabled { opacity: 0.3; cursor: not-allowed; }
.team-card__name {
  position: absolute; left: 16px; bottom: 14px; right: 16px; top: auto;
  font-family: var(--font-display); font-weight: 600; font-size: 18px;
  letter-spacing: -0.02em; line-height: 1.1;
}
.team-card__name small { display: block; font-weight: 400; font-size: 12px; color: var(--ink-3); margin-top: 2px; letter-spacing: 0; }

/* Contact form */
.contact-grid {
  max-width: 1440px; margin: 0 auto;
  display: grid; grid-template-columns: 1fr 1.2fr; gap: 80px;
}
@media (max-width: 900px) { .contact-grid { grid-template-columns: 1fr; gap: 40px; } }
.form { display: grid; gap: 18px; }
.form__row { display: grid; gap: 6px; }
.form__row--two { grid-template-columns: 1fr 1fr; gap: 12px; }
.form__row--two > * { display: grid; gap: 6px; }
.form label {
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--ink-3);
}
.form input, .form textarea, .form select {
  font: inherit; font-size: 16px;
  background: transparent; border: 0;
  border-bottom: 1px solid var(--line); padding: 12px 0; color: var(--ink);
  border-radius: 0;
  transition: border-color 200ms ease;
}
.form input:focus, .form textarea:focus, .form select:focus {
  outline: none; border-bottom-color: var(--dva-red);
}
.form textarea { resize: vertical; min-height: 120px; font-family: var(--font-text); }
.form__chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.chip {
  padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line);
  font-size: 13px; cursor: pointer; transition: background 150ms ease, color 150ms ease, border-color 150ms ease;
  background: transparent; color: var(--ink);
}
.chip.is-on { background: var(--ink); color: #fff; border-color: var(--ink); }
.form__submit {
  margin-top: 8px; align-self: start;
}
.contact-aside h3 {
  font-family: var(--font-display); font-weight: 600;
  font-size: clamp(28px, 3vw, 44px); letter-spacing: -0.03em; line-height: 1.05;
  margin: 0 0 12px;
}
.contact-aside p { color: var(--ink-2); line-height: 1.55; margin: 0 0 24px; max-width: 40ch; }
.contact-aside dl { display: grid; gap: 18px; }
.contact-aside dt { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 4px; }
.contact-aside dd { margin: 0; font-size: 16px; color: var(--ink); line-height: 1.5; }

.success {
  background: var(--bg-alt); border-radius: 16px; padding: 18px 20px;
  display: flex; gap: 14px; align-items: center;
  font-size: 15px; color: var(--ink); border: 1px solid var(--line);
  display: none;
}
.success.is-on { display: flex; }
.success__dot { width: 10px; height: 10px; border-radius: 50%; background: var(--dva-red); flex-shrink: 0; }
