/* ── Reset & Base ─────────────────────────────── */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --bg: #000000;
  --bg-alt: #0a0a0a;
  --bg-dark: #121212;
  --fg: #FAFAF8;
  --fg-muted: #a1a1aa;
  --fg-faint: #52525b;
  --border: rgba(255, 255, 255, 0.12);
  --border-strong: rgba(255, 255, 255, 0.22);
  --accent: #FAFAF8;
  --accent-fg: #000000;
  --green: #22c55e;
  --radius: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --font: 'Poppins', system-ui, sans-serif;
  --max-w: 1100px;
  --nav-h: 64px;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--fg);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  position: relative;
}

body::before,
body::after {
  content: '';
  position: fixed;
  inset: auto;
  pointer-events: none;
  z-index: 0;
  opacity: 0;
  transition: opacity 0.9s ease, transform 1.2s cubic-bezier(0.22, 1, 0.36, 1);
}

body::before {
  top: 140px;
  left: -180px;
  width: 420px;
  height: 420px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.06) 0%, rgba(255, 255, 255, 0.02) 42%, transparent 74%);
  filter: blur(20px);
  transform: translate3d(-10px, 8px, 0) scale(0.94);
}

body::after {
  top: 120px;
  right: -100px;
  width: 420px;
  height: 420px;
  background: radial-gradient(circle, rgba(34, 197, 94, 0.12) 0%, rgba(34, 197, 94, 0.04) 40%, transparent 72%);
  filter: blur(18px);
  transform: translate3d(20px, 18px, 0) scale(0.94);
}

body.site-loaded::before,
body.site-loaded::after {
  opacity: 1;
  transform: translate3d(0, 0, 0) scale(1);
}

body.preload .nav {
  opacity: 0;
  transform: translateY(-16px);
}

body.preload .hero {
  opacity: 0;
  transform: translateY(26px) scale(0.985);
}

body.preload .stats-strip {
  opacity: 0;
  transform: translateY(28px);
}

body.preload .stat {
  opacity: 0;
  transform: translateY(18px);
}

body.preload .section-header {
  opacity: 0;
  transform: translateY(18px);
}

body.preload .nav,
body.preload .hero,
body.preload .stats-strip,
body.preload .stat,
body.preload .section-header {
  transition: opacity 0.8s ease, transform 0.9s cubic-bezier(0.22, 1, 0.36, 1);
}

body.site-loaded .nav,
body.site-loaded .hero,
body.site-loaded .stats-strip,
body.site-loaded .stat,
body.site-loaded .section-header {
  opacity: 1;
  transform: none;
}

body.site-loaded .nav {
  transition-delay: 0.05s;
}

body.site-loaded .hero {
  transition-delay: 0.12s;
}

body.site-loaded .stats-strip {
  transition-delay: 0.28s;
}

body.site-loaded .stat:nth-child(1) {
  transition-delay: 0.36s;
}

body.site-loaded .stat:nth-child(3) {
  transition-delay: 0.44s;
}

body.site-loaded .stat:nth-child(5) {
  transition-delay: 0.52s;
}

body.site-loaded .stat:nth-child(7) {
  transition-delay: 0.6s;
}

/* ── Nav ──────────────────────────────────────── */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2rem;
  background: rgba(10, 10, 10, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  z-index: 100;
  transition: box-shadow 0.3s;
}

.nav.scrolled {
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.06);
}

.nav-logo {
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--fg);
  text-decoration: none;
}

.nav-links {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav-links a {
  text-decoration: none;
  color: var(--fg-muted);
  font-size: 0.875rem;
  font-weight: 400;
  transition: color 0.2s;
}

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

.nav-links .nav-cta {
  color: var(--fg);
  border: 1px solid var(--border-strong);
  padding: 0.4rem 1.1rem;
  border-radius: 7px;
  font-weight: 500;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
}

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

.nav-hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.nav-hamburger span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: var(--fg);
  transition: transform 0.2s, opacity 0.2s;
}

.mobile-menu {
  display: none;
  position: fixed;
  top: var(--nav-h);
  left: 0;
  right: 0;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  flex-direction: column;
  padding: 1.5rem 2rem;
  gap: 1.25rem;
  z-index: 99;
}

.mobile-menu.open {
  display: flex;
}

.mobile-menu a {
  text-decoration: none;
  color: var(--fg);
  font-size: 1rem;
  font-weight: 400;
}

/* ── Hero ─────────────────────────────────────── */
.hero {
  padding: calc(var(--nav-h) + 5rem) 2rem 5rem;
  max-width: var(--max-w);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 4rem;
  align-items: center;
  min-height: calc(100vh - var(--nav-h));
}

.hero-inner {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--fg-muted);
  border: 1px solid var(--border-strong);
  padding: 0.32rem 0.85rem;
  border-radius: 100px;
  margin-bottom: 2rem;
  width: fit-content;
  animation: fadeUp 0.6s ease both;
}

.hero-pill-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
  flex-shrink: 0;
}

.hero-heading {
  font-size: clamp(2.4rem, 4.5vw, 3.8rem);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.025em;
  color: var(--fg);
  max-width: 640px;
  margin-bottom: 1.5rem;
  animation: fadeUp 0.6s 0.1s ease both;
}

.hero-heading em {
  font-style: italic;
  font-weight: 300;
  color: var(--fg-muted);
}

.hero-sub {
  font-size: 1rem;
  color: var(--fg-muted);
  max-width: 480px;
  margin-bottom: 2.5rem;
  line-height: 1.75;
  animation: fadeUp 0.6s 0.2s ease both;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  animation: fadeUp 0.6s 0.3s ease both;
}

/* ── Hero Visual Card ─────────────────────────── */
.hero-visual {
  animation: fadeUp 0.7s 0.25s ease both;
}

.hero-card {
  background: var(--bg-dark);
  border-radius: var(--radius-xl);
  padding: 2rem;
  color: #fff;
  display: flex;
  flex-direction: column;
  gap: 0;
  position: relative;
  overflow: hidden;
}

.hero-card::before {
  content: '';
  position: absolute;
  top: -60px;
  right: -60px;
  width: 200px;
  height: 200px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.04) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.hc-label {
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.35);
  margin-bottom: 1.25rem;
}

.hc-brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.65);
  margin-bottom: 1rem;
}

.hc-brand-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--green);
}

.hc-number {
  font-size: 3.4rem;
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.04em;
  color: #fff;
  margin-bottom: 0.2rem;
}

.hc-unit {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.4);
  margin-bottom: 1.5rem;
}

.hc-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 1.75rem;
}

.hc-tags span {
  font-size: 0.72rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  padding: 0.25rem 0.65rem;
  border-radius: 100px;
  color: rgba(255, 255, 255, 0.5);
}

.hc-bar-wrap {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 1.25rem;
}

.hc-bar-label {
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.3);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 0.85rem;
}

.hc-bars {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.hc-bar-row {
  display: grid;
  grid-template-columns: 90px 1fr 38px;
  align-items: center;
  gap: 0.65rem;
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.45);
}

.hc-bar {
  background: rgba(255, 255, 255, 0.07);
  border-radius: 100px;
  height: 5px;
  overflow: hidden;
}

.hc-bar-fill {
  height: 100%;
  border-radius: 100px;
  transition: width 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.hc-bar-avg {
  background: rgba(255, 255, 255, 0.25);
  width: 0;
  --target-w: 25%;
}

.hc-bar-mine {
  background: var(--green);
  width: 0;
  --target-w: 100%;
}

.hc-bar-fill.animated {
  width: var(--target-w);
}

.hc-pct {
  font-weight: 500;
  color: rgba(255, 255, 255, 0.55);
  text-align: right;
}

.hc-pct-hi {
  color: var(--green);
}

/* ── Buttons ──────────────────────────────────── */
.btn-primary {
  display: inline-block;
  background: var(--fg);
  color: var(--accent-fg);
  text-decoration: none;
  padding: 0.72rem 1.5rem;
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-weight: 500;
  font-family: var(--font);
  border: none;
  cursor: pointer;
  transition: opacity 0.2s, transform 0.15s;
}

.btn-primary:hover {
  opacity: 0.82;
  transform: translateY(-1px);
}

.btn-ghost {
  display: inline-block;
  text-decoration: none;
  color: var(--fg-muted);
  font-size: 0.9rem;
  padding: 0.72rem 0;
  transition: color 0.2s;
}

.btn-ghost:hover {
  color: var(--fg);
}

.btn-submit {
  width: 100%;
  background: var(--fg);
  color: var(--bg);
  border: none;
  border-radius: var(--radius);
  padding: 0.8rem 1.5rem;
  font-family: var(--font);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: opacity 0.2s, transform 0.15s;
  text-align: center;
}

.btn-submit:hover {
  opacity: 0.88;
  transform: translateY(-1px);
}

.btn-submit:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

/* ── Stats Strip ──────────────────────────────── */
.stats-strip {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  padding: 2.5rem 2rem;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  flex-wrap: wrap;
}

.stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0 3rem;
  gap: 0.2rem;
}

.stat-num {
  font-size: 2rem;
  font-weight: 400;
  line-height: 1;
  letter-spacing: -0.025em;
}

.stat-label {
  font-size: 0.75rem;
  color: var(--fg-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.stat-div {
  width: 1px;
  height: 36px;
  background: var(--border-strong);
}

/* ── Section Base ─────────────────────────────── */
.section {
  padding: 5.5rem 2rem;
}

.section-wrap {
  max-width: var(--max-w);
  margin: 0 auto;
}

.section-alt {
  background: var(--bg-alt);
}

.section-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 2.5rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.section-title {
  font-size: clamp(1.6rem, 2.8vw, 2.1rem);
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.15;
}

/* ── Case Study ───────────────────────────────── */
.case-study {
  background: var(--bg-dark);
  color: #fff;
  padding: 5.5rem 2rem;
}

.cs-inner {
  max-width: var(--max-w);
  margin: 0 auto;
}

.cs-eyebrow {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.35);
  margin-bottom: 2.5rem;
}

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

.cs-big {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  margin-bottom: 2rem;
}

.cs-number {
  font-size: clamp(3.5rem, 6.5vw, 5.5rem);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.04em;
  color: #fff;
}

.cs-unit {
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.4);
  letter-spacing: 0.02em;
  margin-bottom: 0.5rem;
}

.cs-body {
  font-size: 0.93rem;
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.8;
  margin-bottom: 0.75rem;
}

.cs-body strong {
  color: #fff;
  font-weight: 500;
}

.cs-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1rem;
}

.cs-tag {
  font-size: 0.73rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  padding: 0.28rem 0.75rem;
  border-radius: 100px;
  color: rgba(255, 255, 255, 0.45);
}

/* ── Proof Grid ───────────────────────────────── */
.proof-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: auto auto;
  gap: 0.85rem;
}

.proof-slot {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: border-color 0.2s;
}

.proof-slot:hover {
  border-color: rgba(255, 255, 255, 0.18);
}

.proof-slot-wide {
  grid-column: 1 / -1;
}

.proof-has-img img {
  width: 100%;
  display: block;
  object-fit: cover;
  max-height: 400px;
}

.proof-slot-wide.proof-has-img img {
  max-height: 320px;
  width: auto;
  max-width: 100%;
  margin: 0 auto;
  object-fit: contain;
  background: rgba(255, 255, 255, 0.03);
  display: block;
}

.proof-caption {
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.35);
  padding: 0.6rem 0.9rem;
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  letter-spacing: 0.02em;
}

/* ── Filter Tabs ──────────────────────────────── */
.filter-tabs {
  display: flex;
  gap: 0.4rem;
}

.filter-btn {
  background: none;
  border: 1px solid var(--border-strong);
  padding: 0.3rem 0.9rem;
  border-radius: 100px;
  font-size: 0.8rem;
  color: var(--fg-muted);
  cursor: pointer;
  font-family: var(--font);
  transition: all 0.2s;
}

.filter-btn:hover {
  color: var(--fg);
  border-color: var(--fg);
}

.filter-btn.active {
  background: var(--fg);
  color: var(--bg);
  border-color: var(--fg);
}

/* ── Portfolio Grid ───────────────────────────── */
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.1rem;
}

.portfolio-card {
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--bg);
  cursor: pointer;
  transition: transform 0.25s, box-shadow 0.25s;
}

.portfolio-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.09);
}

.portfolio-card.hidden {
  display: none;
}

.card-thumb {
  position: relative;
  aspect-ratio: 9/14;
  overflow: hidden;
}

.card-thumb-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.45s, opacity 0.45s;
  position: relative;
  z-index: 0;
}

.card-preview-vid {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.4s ease;
  z-index: 1;
}

.portfolio-card:hover .card-thumb-img {
  transform: scale(1.04);
}

.card-play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 44px;
  height: 44px;
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  color: #ffffff;
  z-index: 2;
  transition: transform 0.2s, background 0.2s;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.15);
}

.card-play span {
  transform: translateX(1px);
  display: block;
}

.portfolio-card:hover .card-play {
  transform: translate(-50%, -50%) scale(1.12);
  background: rgba(255, 255, 255, 0.35);
  color: #fff;
}

.card-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 0.85rem 0.9rem;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.4), transparent);
  z-index: 2;
}

.card-type {
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.88);
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.card-info {
  padding: 0.9rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.18rem;
}

.card-brand {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--fg);
}

.card-desc {
  font-size: 0.76rem;
  color: var(--fg-muted);
}

/* ── Services ─────────────────────────────────── */
.services-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.1rem;
}

.service-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  transition: box-shadow 0.25s, transform 0.25s;
}

.service-card:hover {
  box-shadow: 0 6px 30px rgba(0, 0, 0, 0.07);
  transform: translateY(-2px);
}

.service-icon {
  font-size: 1.35rem;
}

.service-name {
  font-size: 1rem;
  font-weight: 500;
  letter-spacing: -0.01em;
}

.service-desc {
  font-size: 0.875rem;
  color: var(--fg-muted);
  line-height: 1.65;
}

.service-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  margin-top: 0.15rem;
}

.service-list li {
  font-size: 0.82rem;
  color: var(--fg-muted);
  padding-left: 1rem;
  position: relative;
}

.service-list li::before {
  content: '—';
  position: absolute;
  left: 0;
  color: var(--fg-faint);
}

.service-time {
  font-size: 0.75rem;
  color: var(--fg-faint);
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-top: auto;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border);
}

/* ── About ────────────────────────────────────── */
.about-wrap {
  display: grid;
  grid-template-columns: 420px 1fr;
  gap: 4rem;
  align-items: center;
}

.about-visual {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  position: sticky;
  top: calc(var(--nav-h) + 2rem);
}

.about-img-wrap {
  width: 100%;
  margin-top: -2rem;
  /* Pull up to align with text due to transparent PNG padding */
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: none;
  background: transparent;
  -webkit-mask-image: linear-gradient(to bottom, #000 70%, transparent 100%);
  mask-image: linear-gradient(to bottom, #000 70%, transparent 100%);
}

.about-photo {
  width: 100%;
  height: auto;
  object-fit: contain;
  display: block;
  transition: transform 0.5s ease;
  filter: drop-shadow(0 10px 30px rgba(0, 0, 0, 0.15));
}

.about-img-wrap:hover .about-photo {
  transform: scale(1.03);
}

.about-badge {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.78rem;
  color: var(--fg-muted);
  border: 1px solid var(--border-strong);
  padding: 0.35rem 0.85rem;
  border-radius: 100px;
  animation: floatBadge 4s ease-in-out infinite;
}

.badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
  animation: pulseDot 2s infinite;
}

.about-text {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.about-text .section-title {
  margin-bottom: 0.5rem;
}

.about-text p {
  font-size: 0.95rem;
  color: var(--fg-muted);
  line-height: 1.8;
}

.about-niches {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.niche-tag {
  font-size: 0.78rem;
  border: 1px solid var(--border-strong);
  padding: 0.3rem 0.8rem;
  border-radius: 100px;
  color: var(--fg-muted);
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), background 0.3s, border-color 0.3s, color 0.3s, box-shadow 0.3s;
}

.niche-tag:hover {
  transform: translateY(-3px) scale(1.05) rotate(-1.5deg);
  background: rgba(34, 197, 94, 0.1);
  border-color: rgba(34, 197, 94, 0.4);
  color: var(--green);
  box-shadow: 0 4px 12px rgba(34, 197, 94, 0.15);
  cursor: default;
}

.niche-tag:nth-child(even):hover {
  transform: translateY(-3px) scale(1.05) rotate(1.5deg);
}

/* ── Enthusiastic Animations ────────────────────── */
@keyframes wave {
  0% {
    transform: rotate(0deg);
  }

  10% {
    transform: rotate(14deg);
  }

  20% {
    transform: rotate(-8deg);
  }

  30% {
    transform: rotate(14deg);
  }

  40% {
    transform: rotate(-4deg);
  }

  50% {
    transform: rotate(10deg);
  }

  60% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(0deg);
  }
}

.wave {
  display: inline-block;
  animation: wave 2.5s infinite;
  transform-origin: 70% 70%;
}

@keyframes floatBadge {
  0% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-4px);
  }

  100% {
    transform: translateY(0);
  }
}

@keyframes pulseDot {
  0% {
    box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.4);
  }

  70% {
    box-shadow: 0 0 0 6px rgba(34, 197, 94, 0);
  }

  100% {
    box-shadow: 0 0 0 0 rgba(34, 197, 94, 0);
  }
}

/* ── Contact ──────────────────────────────────── */
.contact-section {
  background: var(--bg-dark);
  color: #fff;
  padding: 5.5rem 2rem;
}

.contact-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  max-width: var(--max-w);
  margin: 0 auto;
  align-items: start;
}

.contact-heading {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 400;
  letter-spacing: -0.025em;
  line-height: 1.1;
  margin-bottom: 1rem;
  color: #fff;
}

.contact-heading em {
  font-style: italic;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.4);
}

.contact-sub {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.45);
  margin-bottom: 2rem;
  line-height: 1.7;
}

.contact-links {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.contact-link {
  text-decoration: none;
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.6);
  display: flex;
  align-items: center;
  gap: 0.6rem;
  transition: color 0.2s;
}

.contact-link:hover {
  color: #fff;
}

.cl-icon {
  font-size: 0.8rem;
  opacity: 0.5;
}

/* ── Contact Form ─────────────────────────────── */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.form-group label {
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.4);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.form-group input,
.form-group textarea {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius);
  padding: 0.72rem 1rem;
  font-family: var(--font);
  font-size: 0.9rem;
  color: #fff;
  outline: none;
  transition: border-color 0.3s cubic-bezier(0.4, 0, 0.2, 1), background 0.3s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  resize: none;
}

.form-group input:hover,
.form-group textarea:hover {
  border-color: rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.06);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: rgba(255, 255, 255, 0.2);
  transition: color 0.3s;
}

.form-group input:focus::placeholder,
.form-group textarea:focus::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.08);
}

.form-group input:-webkit-autofill,
.form-group input:-webkit-autofill:hover,
.form-group input:-webkit-autofill:focus,
.form-group textarea:-webkit-autofill,
.form-group textarea:-webkit-autofill:hover,
.form-group textarea:-webkit-autofill:focus {
  -webkit-text-fill-color: #fff;
  transition: background-color 5000s ease-in-out 0s;
}

.form-note {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.45);
  text-align: center;
  min-height: 1.2rem;
}

/* ── Footer ───────────────────────────────────── */
.footer {
  padding: 1.75rem 2rem;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.76rem;
  color: var(--fg-faint);
}

.footer-name {
  font-weight: 500;
  color: var(--fg-muted);
}

/* ── Reveal animation ─────────────────────────── */
.reveal {
  opacity: 0;
  transform: perspective(1800px) translate3d(0, 56px, -180px) rotateX(-18deg) rotateY(0deg) scale(0.93);
  transform-origin: 50% 50%;
  filter: blur(14px) saturate(0.88);
  transition:
    opacity 1s cubic-bezier(0.16, 1, 0.3, 1),
    transform 1.15s cubic-bezier(0.16, 1, 0.3, 1),
    filter 1s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 1s ease;
  will-change: opacity, transform, filter;
  transform-style: preserve-3d;
  backface-visibility: hidden;
}

.reveal-left {
  transform: perspective(1800px) translate3d(-76px, 34px, -140px) rotateY(18deg) rotateX(-12deg) scale(0.94);
}

.reveal-right {
  transform: perspective(1800px) translate3d(76px, 34px, -140px) rotateY(-18deg) rotateX(-12deg) scale(0.94);
}

.reveal-scale {
  transform: perspective(1800px) translate3d(0, 34px, -240px) rotateX(-20deg) scale(0.86);
}

.reveal-soft {
  transform: perspective(1800px) translate3d(0, 40px, -100px) rotateX(-14deg) scale(0.95);
}

.reveal.out-up {
  transform: perspective(1800px) translate3d(0, -56px, -180px) rotateX(18deg) rotateY(0deg) scale(0.93);
}

.reveal-left.out-up {
  transform: perspective(1800px) translate3d(-76px, -34px, -140px) rotateY(18deg) rotateX(12deg) scale(0.94);
}

.reveal-right.out-up {
  transform: perspective(1800px) translate3d(76px, -34px, -140px) rotateY(-18deg) rotateX(12deg) scale(0.94);
}

.reveal-scale.out-up {
  transform: perspective(1800px) translate3d(0, -34px, -240px) rotateX(20deg) scale(0.86);
}

.reveal-soft.out-up {
  transform: perspective(1800px) translate3d(0, -40px, -100px) rotateX(14deg) scale(0.95);
}

.reveal.in-view {
  opacity: 1;
  transform: perspective(1800px) translate3d(0, 0, 0) rotateX(0deg) rotateY(0deg) scale(1);
  filter: blur(0) saturate(1);
}

.case-study.reveal.in-view,
.contact-section.reveal.in-view {
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.proof-grid .proof-slot.reveal:nth-child(2) {
  transition-delay: 0.12s;
}

.services-grid .service-card.reveal:nth-child(1) {
  transition-delay: 0.02s;
}

.services-grid .service-card.reveal:nth-child(2) {
  transition-delay: 0.12s;
}

.services-grid .service-card.reveal:nth-child(3) {
  transition-delay: 0.2s;
}

.services-grid .service-card.reveal:nth-child(4) {
  transition-delay: 0.28s;
}

.contact-links .contact-link {
  opacity: 0;
  transform: translateX(-18px);
  transition: opacity 0.65s ease, transform 0.75s cubic-bezier(0.22, 1, 0.36, 1), color 0.2s;
}

.contact-left.in-view .contact-link {
  opacity: 1;
  transform: translateX(0);
}

.contact-left.in-view .contact-link:nth-child(1) {
  transition-delay: 0.08s;
}

.contact-left.in-view .contact-link:nth-child(2) {
  transition-delay: 0.16s;
}

/* ── Keyframes ────────────────────────────────── */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(16px);
  }

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

@media (prefers-reduced-motion: reduce) {
  body::before,
  body::after {
    display: none;
  }

  body.preload .nav,
  body.preload .hero,
  body.preload .stats-strip,
  body.preload .stat,
  body.preload .section-header {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .hero-pill,
  .hero-heading,
  .hero-sub,
  .hero-actions,
  .hero-visual {
    animation: none;
  }

  .reveal,
  .reveal-left,
  .reveal-right,
  .reveal-scale,
  .reveal-soft,
  .contact-links .contact-link {
    opacity: 1;
    transform: none;
    filter: none;
    transition: none;
  }
}

/* ── Responsive ───────────────────────────────── */
@media (max-width: 1024px) {
  .hero {
    grid-template-columns: 1fr;
    gap: 3rem;
    min-height: auto;
  }

  .hero-visual {
    max-width: 420px;
  }

  .hero-heading {
    max-width: 100%;
  }

  .cs-grid {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
}

@media (max-width: 900px) {
  .portfolio-grid {
    grid-template-columns: repeat(2, 1fr);
  }

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

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

  .about-wrap {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  .about-visual {
    flex-direction: column;
    align-items: center;
    position: static;
  }

  .about-img-wrap {
    max-width: 280px;
    margin-top: 0;
    /* reset negative margin scaled for desktop */
    -webkit-mask-image: linear-gradient(to bottom, #000 75%, transparent 100%);
    mask-image: linear-gradient(to bottom, #000 75%, transparent 100%);
  }

  .about-img-placeholder {
    display: none;
  }

  .contact-inner {
    grid-template-columns: 1fr;
    gap: 3rem;
  }

  .stat {
    padding: 0.75rem 1.5rem;
  }

  .stat-div {
    display: none;
  }
}

@media (max-width: 640px) {
  .nav-links {
    display: none;
  }

  .nav-hamburger {
    display: flex;
  }

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

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

  .section {
    padding: 4rem 1.25rem;
  }

  .case-study {
    padding: 4rem 1.25rem;
  }

  .contact-section {
    padding: 4rem 1.25rem;
  }

  .hero {
    padding: calc(var(--nav-h) + 3rem) 1.25rem 3.5rem;
  }

  .filter-tabs {
    flex-wrap: wrap;
  }

  .footer {
    flex-direction: column;
    gap: 0.35rem;
    text-align: center;
  }

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

  .proof-slot-wide {
    grid-column: 1;
  }
}

/* ── Grid Note ────────────────────────────────── */
.grid-note {
  text-align: center;
  margin-top: 2rem;
  font-size: 0.82rem;
  color: var(--fg-faint);
}

.grid-note a {
  color: var(--fg-muted);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.2s;
}

.grid-note a:hover {
  color: var(--fg);
}

/* ── Video Modal ──────────────────────────────── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.modal-overlay.open {
  opacity: 1;
  pointer-events: all;
}

.modal-box {
  background: #1a1a18;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 420px;
  position: relative;
  overflow: hidden;
  transform: scale(0.95) translateY(10px);
  transition: transform 0.25s ease;
}

.modal-overlay.open .modal-box {
  transform: scale(1) translateY(0);
}

.modal-close {
  position: absolute;
  top: 0.85rem;
  right: 0.85rem;
  width: 30px;
  height: 30px;
  background: rgba(255, 255, 255, 0.1);
  border: none;
  border-radius: 50%;
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.8rem;
  cursor: pointer;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}

.modal-close:hover {
  background: rgba(255, 255, 255, 0.18);
}

.modal-video-wrap {
  width: 100%;
  aspect-ratio: 9/16;
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-video-wrap video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.modal-video-wrap iframe {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}

.modal-drive-link {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: 3rem 2rem;
  text-align: center;
  width: 100%;
  height: 100%;
}

.modal-drive-link p {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
  line-height: 1.6;
}

.modal-drive-link a {
  display: inline-block;
  background: #fff;
  color: #111;
  text-decoration: none;
  padding: 0.65rem 1.4rem;
  border-radius: var(--radius);
  font-size: 0.88rem;
  font-weight: 500;
  transition: opacity 0.2s;
}

.modal-drive-link a:hover {
  opacity: 0.85;
}

.modal-info {
  padding: 1rem 1.25rem;
  border-top: 1px solid rgba(255, 255, 255, 0.07);
}

.modal-info-title {
  font-size: 0.92rem;
  font-weight: 500;
  color: #fff;
  margin-bottom: 0.2rem;
}

.modal-info-desc {
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.45);
}
