/* VastoraTech — editorial portfolio */

:root {
  --bg: #ffffff;
  --bg-elevated: #f5f5f3;
  --bg-soft: #eeeeec;
  --bg-line: #e2e2de;
  --text: #111111;
  --text-muted: #5a5a56;
  --text-dim: #8c8c86;
  --accent: #2474d4;
  --accent-ink: #ffffff;
  --logo-blue: #2474d4;

  --font-display: "Syne", sans-serif;
  --font-body: "Epilogue", sans-serif;

  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 1.75rem;
  --space-lg: 3.5rem;
  --space-xl: 6rem;
  --space-2xl: 9rem;

  --header-h: 4.5rem;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --radius: 2px;
}

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

html {
  scroll-behavior: smooth;
  scrollbar-width: thin;
  scrollbar-color: var(--accent) var(--bg);
}

body {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--text);
  background:
    radial-gradient(
      ellipse 80% 50% at 10% -10%,
      rgba(52, 133, 225, 0.07),
      transparent 50%
    ),
    radial-gradient(
      ellipse 60% 40% at 90% 20%,
      rgba(36, 116, 212, 0.08),
      transparent 45%
    ),
    linear-gradient(180deg, #ffffff 0%, var(--bg) 35%, #f7f7f5 100%);
  background-attachment: fixed;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

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

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

button,
input,
textarea {
  font: inherit;
  color: inherit;
}

::selection {
  background: var(--accent);
  color: var(--accent-ink);
}

.noise {
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: 9998;
  opacity: 0.025;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  mix-blend-mode: multiply;
}

.cursor-glow {
  pointer-events: none;
  position: fixed;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(36, 116, 212, 0.12),
    transparent 65%
  );
  transform: translate(-50%, -50%);
  left: -999px;
  top: -999px;
  z-index: 1;
  transition: opacity 0.4s var(--ease);
  opacity: 0;
}

@media (pointer: fine) {
  .cursor-glow.is-on {
    opacity: 1;
  }
}

/* ——— Header ——— */

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(1.25rem, 4vw, 3.5rem);
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition:
    border-color 0.4s var(--ease),
    background 0.4s var(--ease);
  overflow: hidden;
}

.site-header.is-scrolled {
  border-bottom-color: var(--bg-line);
  background: rgba(255, 255, 255, 0.94);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  z-index: 2;
}

.brand__mark {
  width: 64px;
  height: 64px;
  object-fit: cover;
  border-radius: 50%;
  flex-shrink: 0;
}

.site-header .brand__mark {
  width: 64px;
  height: 64px;
}

.brand__name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.18rem;
  letter-spacing: -0.02em;
  line-height: 1;
}

.nav {
  display: none;
  align-items: center;
  gap: 2rem;
}

.nav a {
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--text-muted);
  transition: color 0.25s var(--ease);
}

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

.nav__cta {
  color: var(--accent-ink) !important;
  background: var(--accent);
  padding: 0.55rem 1.1rem;
  font-weight: 600 !important;
  font-size: 0.92rem !important;
  border-radius: var(--radius);
  line-height: 1.2;
}

.nav__cta:hover {
  color: var(--accent-ink) !important;
  filter: brightness(1.05);
}

.nav-toggle {
  width: 44px;
  height: 44px;
  border: 0;
  background: transparent;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 7px;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  height: 1.5px;
  width: 22px;
  background: var(--text);
  transition:
    transform 0.35s var(--ease),
    opacity 0.25s;
}

.nav-toggle[aria-expanded="true"] span:first-child {
  transform: translateY(4.25px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:last-child {
  transform: translateY(-4.25px) rotate(-45deg);
}

.mobile-nav {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: rgba(255, 255, 255, 0.98);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 6rem 2rem;
  gap: 1.5rem;
}

.mobile-nav[hidden] {
  display: none;
}

.mobile-nav a {
  font-family: var(--font-display);
  font-size: clamp(2rem, 8vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.03em;
}

.mobile-nav a:last-child {
  color: var(--accent);
  margin-top: 1rem;
}

@media (min-width: 880px) {
  .nav {
    display: flex;
  }
  .nav-toggle {
    display: none;
  }
}

/* ——— Shared ——— */

.eyebrow {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.section-index {
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.08em;
}

.section-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.4rem, 5.5vw, 4.25rem);
  line-height: 1.05;
  letter-spacing: -0.04em;
  margin-top: 0.5rem;
}

.section-lede {
  max-width: 28ch;
  color: var(--text-muted);
  font-size: 1rem;
  font-weight: 400;
}

.section-head {
  display: grid;
  gap: 1.5rem;
  margin-bottom: clamp(2.5rem, 6vw, 4.5rem);
  padding: 0 clamp(1.25rem, 4vw, 3.5rem);
}

@media (min-width: 800px) {
  .section-head {
    grid-template-columns: 1.4fr 1fr;
    align-items: end;
  }
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.95rem 1.5rem;
  font-size: 0.9rem;
  font-weight: 600;
  border-radius: var(--radius);
  border: 1px solid transparent;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition:
    transform 0.35s var(--ease),
    background 0.25s,
    border-color 0.25s,
    color 0.25s;
  will-change: transform;
}

.btn--primary::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    120deg,
    transparent 30%,
    rgba(255, 255, 255, 0.28),
    transparent 70%
  );
  transform: translateX(-120%);
  transition: transform 0.6s var(--ease);
}

.btn--primary:hover::before {
  transform: translateX(120%);
}

.btn--primary {
  background: var(--accent);
  color: var(--accent-ink);
}

.btn--primary:hover {
  filter: brightness(1.06);
}

.btn--ghost {
  background: transparent;
  border-color: var(--bg-line);
  color: var(--text);
}

.btn--ghost:hover {
  border-color: var(--text-muted);
}

/* Reveal */

.reveal {
  opacity: 0;
  transform: translateY(32px);
  filter: blur(4px);
  transition:
    opacity 0.85s var(--ease),
    transform 0.85s var(--ease),
    filter 0.85s var(--ease);
  transition-delay: var(--delay, 0ms);
}

.reveal.is-in {
  opacity: 1;
  transform: none;
  filter: none;
}

.clients__grid .reveal:nth-child(1) { --delay: 0ms; }
.clients__grid .reveal:nth-child(2) { --delay: 70ms; }
.clients__grid .reveal:nth-child(3) { --delay: 140ms; }
.clients__grid .reveal:nth-child(4) { --delay: 210ms; }
.clients__grid .reveal:nth-child(5) { --delay: 280ms; }

.service-list .reveal:nth-child(1) { --delay: 0ms; }
.service-list .reveal:nth-child(2) { --delay: 50ms; }
.service-list .reveal:nth-child(3) { --delay: 100ms; }
.service-list .reveal:nth-child(4) { --delay: 150ms; }
.service-list .reveal:nth-child(5) { --delay: 200ms; }
.service-list .reveal:nth-child(6) { --delay: 250ms; }
.service-list .reveal:nth-child(7) { --delay: 300ms; }
.service-list .reveal:nth-child(8) { --delay: 350ms; }

.timeline .reveal:nth-child(1) { --delay: 0ms; }
.timeline .reveal:nth-child(2) { --delay: 90ms; }
.timeline .reveal:nth-child(3) { --delay: 180ms; }
.timeline .reveal:nth-child(4) { --delay: 270ms; }

.why__grid .reveal:nth-child(1) { --delay: 0ms; }
.why__grid .reveal:nth-child(2) { --delay: 100ms; }
.why__grid .reveal:nth-child(3) { --delay: 200ms; }

/* Scroll progress */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 2px;
  width: 0%;
  z-index: 200;
  background: var(--accent);
  pointer-events: none;
}

/* ——— Hero ——— */

.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: calc(var(--header-h) + 2rem) clamp(1.25rem, 4vw, 3.5rem) 2.5rem;
  overflow: hidden;
}

.hero__grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(0, 0, 0, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 0, 0, 0.045) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: radial-gradient(
    ellipse 70% 60% at 60% 40%,
    black 20%,
    transparent 75%
  );
  pointer-events: none;
  transform: translateY(var(--parallax-y, 0));
}

.hero__inner {
  position: relative;
  z-index: 2;
  max-width: 1200px;
  width: 100%;
  padding-bottom: 2rem;
  min-width: 0;
}

.hero__heading {
  margin: 1rem 0 2.5rem;
  max-width: 100%;
  min-width: 0;
}

.hero__brand {
  display: block;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.55rem, 8.2vw, 6.5rem);
  line-height: 0.95;
  letter-spacing: -0.045em;
  color: var(--text);
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: clip;
}

.hero.is-ready .hero__brand {
  animation: brand-in 1.05s var(--ease) both;
}

@keyframes brand-in {
  from {
    opacity: 0;
    letter-spacing: 0.04em;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    letter-spacing: -0.05em;
    transform: none;
  }
}

.hero__title {
  display: block;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.25rem, 3.6vw, 2.35rem);
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin-top: 0.85rem;
  max-width: 28ch;
  color: var(--text-muted);
}

.hero__title .line {
  display: block;
  overflow: hidden;
}

.hero__title .line > span {
  display: block;
  transform: translateY(110%);
  transition: transform 1.1s var(--ease);
}

.hero.is-ready .hero__title .line > span {
  transform: none;
}

.hero__title .line:nth-child(2) > span {
  transition-delay: 0.1s;
}

.hero__title .line:nth-child(3) > span {
  transition-delay: 0.2s;
}

.line--accent {
  color: var(--accent);
}

.hero__foot {
  display: grid;
  gap: 1.75rem;
  max-width: 920px;
}

@media (min-width: 800px) {
  .hero__foot {
    grid-template-columns: 1.3fr 1fr;
    align-items: end;
  }
}

.hero__lede {
  color: var(--text-muted);
  max-width: 38ch;
  font-size: 1.05rem;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.hero__meta {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  padding-top: 3rem;
  border-top: 1px solid var(--bg-line);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-dim);
}

/* ——— About ——— */

.about {
  padding: var(--space-2xl) clamp(1.25rem, 4vw, 3.5rem);
  display: grid;
  gap: 2.5rem;
  border-top: 1px solid var(--bg-line);
}

@media (min-width: 900px) {
  .about {
    grid-template-columns: 140px 1fr;
    grid-template-rows: auto auto;
    column-gap: 3rem;
  }

  .about__label {
    grid-row: 1 / 3;
  }

  .about__manifesto {
    max-width: 18ch;
  }

  .about__points {
    grid-column: 2;
    justify-self: end;
    width: min(100%, 420px);
  }
}

.about__label {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.about__manifesto {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.65rem, 3.8vw, 2.85rem);
  line-height: 1.2;
  letter-spacing: -0.03em;
  max-width: 22ch;
}

.about__points {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0;
  border-top: 1px solid var(--bg-line);
}

.about__points li {
  padding: 1.1rem 0;
  border-bottom: 1px solid var(--bg-line);
  font-size: 1rem;
  color: var(--text-muted);
}

.about__points li span {
  position: relative;
  padding-left: 1.25rem;
}

.about__points li span::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 6px;
  height: 6px;
  background: var(--accent);
}

/* ——— Clients ——— */

.clients {
  padding: var(--space-2xl) clamp(1.25rem, 4vw, 3.5rem);
  border-top: 1px solid var(--bg-line);
  background:
    radial-gradient(
      ellipse 70% 50% at 50% 0%,
      rgba(36, 116, 212, 0.06),
      transparent 55%
    ),
    var(--bg);
}

.clients__head {
  max-width: 640px;
  margin-bottom: clamp(2.5rem, 6vw, 4rem);
}

.clients__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2rem, 4.5vw, 3.5rem);
  line-height: 1.05;
  letter-spacing: -0.04em;
  margin: 0.5rem 0 1rem;
}

.clients__lede {
  color: var(--text-muted);
  max-width: 42ch;
}

.clients__grid {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}

@media (min-width: 720px) {
  .clients__grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
  }
}

@media (min-width: 1100px) {
  .clients__grid {
    grid-template-columns: repeat(5, 1fr);
  }
}

.client-tile {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.client-tile__logo {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 120px;
  padding: 1.25rem 1.35rem;
  background: #ffffff;
  border: 1px solid var(--bg-line);
  border-radius: var(--radius);
  transition:
    border-color 0.35s var(--ease),
    transform 0.45s var(--ease),
    box-shadow 0.35s var(--ease);
  overflow: hidden;
}

.client-tile__logo--pad {
  padding: 0.65rem;
}

.client-tile__logo img {
  max-width: 100%;
  max-height: 72px;
  width: auto;
  height: auto;
  object-fit: contain;
  transition: transform 0.45s var(--ease);
}

.client-tile:hover .client-tile__logo {
  border-color: rgba(36, 116, 212, 0.45);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.08);
  transform: translateY(-3px);
}

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

@media (min-width: 720px) {
  .client-tile__logo {
    height: 132px;
  }

  .client-tile__logo img {
    max-height: 80px;
  }
}

/* ——— Services ——— */

.services {
  padding: var(--space-2xl) 0;
  border-top: 1px solid var(--bg-line);
}

.service-list {
  border-top: 1px solid var(--bg-line);
}

.service {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 1rem 1.5rem;
  align-items: start;
  padding: 1.5rem clamp(1.25rem, 4vw, 3.5rem);
  border-bottom: 1px solid var(--bg-line);
  cursor: pointer;
  transition: background 0.35s var(--ease);
}

.service:hover,
.service:focus-visible,
.service.is-open {
  background: var(--bg-elevated);
  outline: none;
}

.service__num {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--accent);
  padding-top: 0.45rem;
}

.service__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.35rem, 3vw, 2.15rem);
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.service__detail {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  color: var(--text-muted);
  max-width: 52ch;
  margin-top: 0;
  transition:
    max-height 0.5s var(--ease),
    opacity 0.4s var(--ease),
    margin 0.4s var(--ease);
}

.service:hover .service__detail,
.service:focus-visible .service__detail,
.service.is-open .service__detail {
  max-height: 160px;
  opacity: 1;
  margin-top: 0.85rem;
}

.service__hint {
  font-size: 1.5rem;
  color: var(--text-dim);
  transition:
    transform 0.4s var(--ease),
    color 0.3s;
  line-height: 1;
  padding-top: 0.2rem;
}

.service:hover .service__hint,
.service.is-open .service__hint {
  transform: rotate(45deg);
  color: var(--accent);
}

/* ——— Work ——— */

.work {
  padding: var(--space-2xl) 0;
  border-top: 1px solid var(--bg-line);
}

.section-head--work {
  margin-bottom: clamp(3rem, 8vw, 5.5rem);
}

.case {
  display: grid;
  gap: 1.75rem;
  margin-bottom: clamp(4rem, 10vw, 7rem);
  padding: 0 clamp(1.25rem, 4vw, 3.5rem);
}

@media (min-width: 960px) {
  .case {
    grid-template-columns: 1.35fr 0.85fr;
    gap: 3rem;
    align-items: center;
  }

  .case--right .case__visual {
    order: 2;
  }

  .case--right .case__caption {
    order: 1;
    justify-self: start;
    text-align: left;
    padding-right: 0;
    padding-left: 0;
  }

  .case--left .case__caption {
    padding-left: 1rem;
  }
}

.case__visual {
  display: block;
  position: relative;
}

.case__frame {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--bg-soft);
  border: 1px solid var(--bg-line);
  border-radius: var(--radius);
  clip-path: inset(6% 6% 6% 6%);
  transition: clip-path 1.05s var(--ease);
}

.case__visual.reveal.is-in .case__frame {
  clip-path: inset(0 0 0 0);
}

.case__frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  transition: transform 0.9s var(--ease);
  will-change: transform;
  transform: translate3d(0, var(--case-shift, 0px), 0) scale(1.04);
}

.case__frame--app img {
  object-position: center top;
}

.case__visual:hover .case__frame img {
  transform: translate3d(0, var(--case-shift, 0px), 0) scale(1.08);
}

.case__fallback {
  position: absolute;
  inset: 0;
  display: none;
  align-items: flex-end;
  padding: 2rem;
  background: linear-gradient(145deg, #e8eef8 0%, #f3f3f1 50%, #e8f2e4 100%);
}

.case__fallback--b {
  background: linear-gradient(145deg, #f3ebe3 0%, #f5f5f3 55%, #e9f1e4 100%);
}

.case__fallback--c {
  background: linear-gradient(145deg, #e6edf4 0%, #f4f4f2 50%, #efe8e8 100%);
}

.case__frame.is-fallback .case__fallback,
.case__frame:not(:has(img)) .case__fallback {
  display: flex;
}

.case__fallback span {
  font-family: var(--font-display);
  font-size: clamp(1.2rem, 2.5vw, 1.75rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
}

.case__fallback span::after {
  content: "";
  display: block;
  width: 48px;
  height: 3px;
  background: var(--accent);
  margin-top: 1rem;
}

.case__label {
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: 0.85rem;
}

.case__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.75rem, 3.5vw, 2.75rem);
  letter-spacing: -0.035em;
  line-height: 1.1;
  margin-bottom: 1rem;
}

.case__result {
  color: var(--text-muted);
  max-width: 36ch;
  margin-bottom: 1.35rem;
}

.case__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.75rem;
}

.case__tags span {
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  border: 1px solid var(--bg-line);
  padding: 0.35rem 0.7rem;
  border-radius: var(--radius);
}

.case__link {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--accent);
  border-bottom: 1px solid transparent;
  padding-bottom: 2px;
  transition: border-color 0.25s;
}

.case__link:hover {
  border-bottom-color: var(--accent);
}

/* ——— Process ——— */

.process {
  padding: var(--space-2xl) 0;
  border-top: 1px solid var(--bg-line);
}

.timeline {
  list-style: none;
  display: grid;
  gap: 0;
  padding: 0 clamp(1.25rem, 4vw, 3.5rem);
  border-top: 1px solid var(--bg-line);
}

@media (min-width: 900px) {
  .timeline {
    grid-template-columns: repeat(4, 1fr);
  }
}

.timeline__item {
  padding: 2rem 1.25rem 2rem 0;
  border-bottom: 1px solid var(--bg-line);
  position: relative;
}

@media (min-width: 900px) {
  .timeline__item {
    border-bottom: 0;
    border-right: 1px solid var(--bg-line);
    padding: 2.5rem 1.75rem 1rem 0;
    min-height: 280px;
  }

  .timeline__item:last-child {
    border-right: 0;
    padding-right: 0;
  }
}

.timeline__step {
  display: block;
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 1.25rem;
  letter-spacing: 0.08em;
}

.timeline__item h3 {
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 0.85rem;
}

.timeline__item p {
  color: var(--text-muted);
  font-size: 0.95rem;
  max-width: 28ch;
}

/* ——— Stack marquee ——— */

.stack {
  padding: 3.5rem 0;
  border-top: 1px solid var(--bg-line);
  border-bottom: 1px solid var(--bg-line);
  overflow: hidden;
  background: var(--bg-elevated);
}

.stack__label {
  text-align: center;
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: 1.5rem;
}

.marquee {
  overflow: hidden;
  mask-image: linear-gradient(
    90deg,
    transparent,
    black 8%,
    black 92%,
    transparent
  );
}

.marquee__track {
  display: flex;
  width: max-content;
  gap: 3.5rem;
  animation: marquee 36s linear infinite;
}

.marquee__track span {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.5rem, 3.5vw, 2.35rem);
  letter-spacing: -0.03em;
  color: var(--text);
  white-space: nowrap;
  opacity: 0.55;
}

.marquee__track span:nth-child(odd) {
  color: var(--accent);
  opacity: 0.9;
}

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

/* ——— Why ——— */

.why {
  padding: var(--space-2xl) 0;
}

.why__grid {
  display: grid;
  gap: 0;
  padding: 0 clamp(1.25rem, 4vw, 3.5rem);
  border-top: 1px solid var(--bg-line);
}

@media (min-width: 900px) {
  .why__grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.why__item {
  padding: 2.25rem 1.5rem 2.25rem 0;
  border-bottom: 1px solid var(--bg-line);
}

@media (min-width: 900px) {
  .why__item {
    border-bottom: 0;
    border-right: 1px solid var(--bg-line);
    padding: 2.75rem 2rem 1rem 0;
  }

  .why__item:last-child {
    border-right: 0;
    padding-right: 0;
  }
}

.why__num {
  font-family: var(--font-display);
  font-size: 0.8rem;
  color: var(--accent);
  font-weight: 600;
  display: block;
  margin-bottom: 1.5rem;
}

.why__item h3 {
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 0.85rem;
  line-height: 1.2;
}

.why__item p {
  color: var(--text-muted);
  font-size: 0.95rem;
  max-width: 32ch;
}

/* ——— Reviews ——— */

.reviews {
  padding: var(--space-2xl) 0;
  border-top: 1px solid var(--bg-line);
}

.reviews__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  padding: 0 clamp(1.25rem, 4vw, 3.5rem);
}

@media (min-width: 760px) {
  .reviews__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.25rem;
  }

  .review--featured {
    grid-column: 1 / -1;
  }
}

@media (min-width: 1100px) {
  .reviews__grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 1.35rem;
  }

  .review--featured {
    grid-column: 1 / -1;
  }

  .review:not(.review--featured) {
    grid-column: span 3;
  }
}

.review {
  margin: 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  padding: 1.5rem 1.35rem 1.4rem;
  background: var(--bg-elevated);
  border: 1px solid var(--bg-line);
  border-radius: var(--radius);
  border-top: 2px solid var(--accent);
  transition:
    transform 0.4s var(--ease),
    border-color 0.35s var(--ease),
    box-shadow 0.4s var(--ease);
}

.review:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 36px rgba(17, 17, 17, 0.06);
  border-color: rgba(36, 116, 212, 0.28);
  border-top-color: var(--accent);
}

.review--featured {
  padding: clamp(1.6rem, 3vw, 2.4rem);
  gap: 1.5rem;
  background:
    radial-gradient(ellipse 70% 80% at 100% 0%, rgba(36, 116, 212, 0.06), transparent 55%),
    var(--bg-elevated);
}

@media (min-width: 900px) {
  .review--featured {
    display: grid;
    grid-template-columns: auto 1fr auto;
    grid-template-areas:
      "num quote quote"
      "num meta meta";
    column-gap: 2rem;
    align-items: start;
  }

  .review--featured .review__num {
    grid-area: num;
    padding-top: 0.35rem;
  }

  .review--featured .review__quote {
    grid-area: quote;
    max-width: 48ch;
    font-size: clamp(1.45rem, 2.4vw, 2rem);
  }

  .review--featured .review__meta {
    grid-area: meta;
    margin-top: 0.25rem;
  }
}

.review__num {
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--accent);
}

.review__quote {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.05rem, 2vw, 1.28rem);
  line-height: 1.45;
  letter-spacing: -0.02em;
  color: var(--text);
  margin: 0;
  flex: 1;
}

.review__quote::before {
  content: "“";
  color: var(--accent);
  font-weight: 700;
  margin-right: 0.12em;
}

.review__meta {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px solid var(--bg-line);
  min-width: 0;
}

.review__avatar {
  flex-shrink: 0;
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.review__who {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
}

.review__name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.98rem;
  letter-spacing: -0.02em;
  color: var(--text);
}

.review__org {
  font-size: 0.85rem;
  color: var(--text-muted);
  overflow-wrap: anywhere;
}

a.review__org {
  color: var(--accent);
  width: fit-content;
  border-bottom: 1px solid transparent;
  transition: border-color 0.25s;
}

a.review__org:hover {
  border-bottom-color: var(--accent);
}

.reviews__grid .reveal:nth-child(1) { --delay: 0ms; }
.reviews__grid .reveal:nth-child(2) { --delay: 70ms; }
.reviews__grid .reveal:nth-child(3) { --delay: 140ms; }
.reviews__grid .reveal:nth-child(4) { --delay: 70ms; }
.reviews__grid .reveal:nth-child(5) { --delay: 140ms; }

@media (max-width: 759px) {
  .review {
    padding: 1.25rem 1.1rem 1.2rem;
  }

  .review__quote {
    font-size: 1.05rem;
  }
}

/* ——— Contact ——— */

.contact {
  padding: var(--space-2xl) clamp(1.25rem, 4vw, 3.5rem);
  border-top: 1px solid var(--bg-line);
  display: grid;
  gap: 3rem;
  background:
    radial-gradient(
      ellipse 50% 60% at 100% 100%,
      rgba(36, 116, 212, 0.08),
      transparent 55%
    ),
    var(--bg);
}

@media (min-width: 900px) {
  .contact {
    grid-template-columns: 1.1fr 0.9fr;
    gap: 4rem;
    align-items: start;
  }
}

.contact__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.2rem, 5vw, 3.75rem);
  line-height: 1.05;
  letter-spacing: -0.04em;
  margin: 0.75rem 0 1.25rem;
  max-width: 14ch;
}

.contact__lede {
  color: var(--text-muted);
  max-width: 38ch;
  margin-bottom: 2rem;
}

.contact__meta {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  font-size: 0.95rem;
}

.contact__meta a {
  color: var(--accent);
  font-weight: 600;
  width: fit-content;
  border-bottom: 1px solid transparent;
  transition: border-color 0.25s;
}

.contact__meta a:hover {
  border-bottom-color: var(--accent);
}

.contact__meta span {
  color: var(--text-dim);
}

.contact__form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem 1rem;
  padding: 2rem;
  background: var(--bg-elevated);
  border: 1px solid var(--bg-line);
  border-radius: var(--radius);
}

.field {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.field--full {
  grid-column: 1 / -1;
}

.field label {
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.field input,
.field textarea {
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--bg-line);
  padding: 0.75rem 0;
  border-radius: 0;
  outline: none;
  transition: border-color 0.25s;
  resize: vertical;
}

.field input:focus,
.field textarea:focus {
  border-bottom-color: var(--accent);
}

.field input::placeholder,
.field textarea::placeholder {
  color: var(--text-dim);
}

.contact__form .btn {
  grid-column: 1 / -1;
  justify-self: start;
  margin-top: 0.5rem;
}

.form-status {
  grid-column: 1 / -1;
  font-size: 0.9rem;
  color: var(--accent);
  min-height: 1.25em;
}

@media (max-width: 560px) {
  .contact__form {
    grid-template-columns: 1fr;
    padding: 1.5rem;
  }
}

/* ——— Footer ——— */

.site-footer {
  padding: 3rem clamp(1.25rem, 4vw, 3.5rem) 2rem;
  border-top: 1px solid var(--bg-line);
}

.footer__top {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}

.footer__nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.footer__nav a {
  font-size: 0.9rem;
  color: var(--text-muted);
  transition: color 0.25s;
}

.footer__nav a:hover {
  color: var(--text);
}

.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--bg-line);
  font-size: 0.8rem;
  color: var(--text-dim);
}

.footer__socials {
  display: flex;
  gap: 1.25rem;
}

.footer__socials a {
  color: var(--text-muted);
  transition: color 0.25s;
}

.footer__socials a:hover {
  color: var(--accent);
}

.nav a:not(.nav__cta) {
  position: relative;
}

.nav a:not(.nav__cta)::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 100%;
  height: 1px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s var(--ease);
}

.nav a:not(.nav__cta):hover::after {
  transform: scaleX(1);
}

/* Reduced motion */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .reveal {
    opacity: 1;
    transform: none;
    filter: none;
    transition: none;
  }

  .hero__title .line > span {
    transform: none;
  }

  .hero.is-ready .hero__brand {
    animation: none;
  }

  .marquee__track {
    animation: none;
  }

  .cursor-glow,
  .scroll-progress {
    display: none;
  }

  .case__frame {
    clip-path: none;
  }

  .btn--primary::before {
    display: none;
  }
}

/* ——— Responsive polish ——— */

img,
svg,
video {
  max-width: 100%;
}

.client-tile__logo img {
  max-width: 100%;
  height: auto;
}

@media (max-width: 1100px) {
  .clients__grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 879px) {
  .hero {
    min-height: auto;
    padding-top: calc(var(--header-h) + 1.25rem);
    padding-bottom: 1.75rem;
  }

  .hero__brand {
    font-size: clamp(1.5rem, 9vw, 3.5rem);
    letter-spacing: -0.04em;
  }

  .hero__heading {
    margin-bottom: 1.75rem;
  }

  .hero__actions {
    width: 100%;
  }

  .hero__actions .btn {
    flex: 1 1 auto;
    min-width: min(100%, 148px);
  }

  .service {
    grid-template-columns: auto 1fr auto;
    gap: 0.75rem 1rem;
    padding-block: 1.25rem;
  }

  .service__title {
    font-size: clamp(1.1rem, 4.8vw, 1.55rem);
  }

  .service:hover .service__detail,
  .service:focus-visible .service__detail,
  .service.is-open .service__detail {
    max-height: 220px;
  }

  .case {
    margin-bottom: 3.25rem;
  }

  .case__caption {
    min-width: 0;
  }

  .contact__title {
    max-width: none;
  }

  .footer__bottom {
    flex-direction: column;
    align-items: flex-start;
  }

  .timeline__item p,
  .why__item p,
  .case__result,
  .section-lede {
    max-width: none;
  }
}

@media (max-width: 640px) {
  :root {
    --space-2xl: 5rem;
    --header-h: 4.25rem;
  }

  .site-header .brand__mark,
  .brand__mark {
    width: 52px;
    height: 52px;
  }

  .brand__name {
    font-size: 1.05rem;
  }

  .section-title,
  .clients__title {
    font-size: clamp(1.85rem, 8.5vw, 2.6rem);
  }

  .about__manifesto {
    font-size: clamp(1.25rem, 6vw, 1.7rem);
    max-width: none;
  }

  .clients__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
  }

  .client-tile__logo {
    height: 92px;
    padding: 0.75rem;
  }

  .client-tile__logo img {
    max-height: 52px;
  }

  .hero__brand {
    font-size: clamp(1.45rem, 8.5vw, 2.6rem);
  }

  .hero__title {
    font-size: clamp(1.1rem, 4.8vw, 1.45rem);
    max-width: none;
  }

  .hero__meta {
    flex-direction: column;
    gap: 0.5rem;
    align-items: flex-start;
  }

  .btn {
    padding: 0.85rem 1.15rem;
  }

  .contact__form {
    padding: 1.25rem;
  }

  .marquee__track {
    gap: 2rem;
  }

  .marquee__track span {
    font-size: 1.25rem;
  }

  .site-footer,
  .contact,
  .about,
  .clients,
  .work,
  .process,
  .why,
  .reviews,
  .services,
  .stack,
  .hero {
    overflow-x: clip;
  }
}

@media (max-width: 480px) {
  .hero__actions {
    flex-direction: column;
  }

  .hero__actions .btn {
    width: 100%;
  }

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

  .service__hint {
    display: none;
  }

  .case__tags {
    gap: 0.4rem;
  }

  .footer__nav,
  .footer__socials {
    gap: 1rem;
    flex-wrap: wrap;
  }
}

@media (max-width: 400px) {
  .brand__name {
    font-size: 0.98rem;
  }

  .site-header .brand__mark,
  .brand__mark {
    width: 46px;
    height: 46px;
  }
}
