/* =========================================================
   Fran Ruiz — Digital Solutions Studio · Bern, CH
   Pastel + bold sans + big colorful mockups
   Light by default · dark toggle
   ========================================================= */

:root {
  /* Light (default) */
  --bg: #f5f2ec;
  --bg-2: #ffffff;
  --surface: #ebe6dc;
  --line: #1a1a1a14;
  --text: #1a1a1a;
  --text-2: #4a4a47;
  --text-mute: #8a8680;
  --accent: #e8624a;        /* terracotta from his Fimed mockup */
  --accent-2: #a3b59a;      /* sage from his portrait wall */
  --accent-3: #b4cfd1;      /* powder blue from My Mediterranean */
  --accent-4: #f4b65c;      /* warm sand */
  --shadow: 0 30px 80px -30px rgba(20, 18, 14, 0.18);
  --shadow-sm: 0 10px 30px -12px rgba(20, 18, 14, 0.12);

  --font-display: "Bricolage Grotesque", "Hanken Grotesk", Arial, sans-serif;
  --font-body:    "Hanken Grotesk", -apple-system, "Segoe UI", Arial, sans-serif;
  --font-mono:    "JetBrains Mono", ui-monospace, monospace;

  --maxw: 1440px;
  --gutter: clamp(20px, 4vw, 64px);
  --r-card: 28px;
}

[data-theme="dark"] {
  --bg: #14130f;
  --bg-2: #1c1b16;
  --surface: #1f1e19;
  --line: #ffffff14;
  --text: #f3ede2;
  --text-2: #c2bdb1;
  --text-mute: #7f7a70;
  --accent: #ec7861;
  --shadow: 0 30px 80px -30px rgba(0,0,0,0.6);
  --shadow-sm: 0 10px 30px -12px rgba(0,0,0,0.4);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
/* Belt-and-braces against horizontal overflow at narrow widths. The
   body keeps the overflow-x:hidden below; here we also pin the html
   so a stray fixed/absolute element can't introduce a phantom scroll
   strip on the right edge in dark mode. */
html { max-width: 100vw; overflow-x: clip; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  transition: background .35s ease, color .35s ease;
}
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
img { display: block; max-width: 100%; }
::selection { background: var(--accent); color: #fff; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.02;
  margin: 0;
}

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 var(--gutter);
}
.section {
  padding: clamp(72px, 10vw, 140px) 0;
  position: relative;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-mute);
  margin-bottom: 28px;
}
.eyebrow::before {
  content: ""; width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent); display: inline-block;
}

/* ---------- NAV ---------- */
.nav {
  position: fixed;
  top: 16px; left: 16px; right: 16px;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px 10px 20px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--bg-2) 75%, transparent);
  backdrop-filter: saturate(160%) blur(18px);
  -webkit-backdrop-filter: saturate(160%) blur(18px);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  max-width: 1320px;
  margin: 0 auto;
}
.nav-logo {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 18px;
  letter-spacing: -0.02em;
}
.nav-logo .mark {
  width: 32px; height: 32px;
  border-radius: 50%;
  background: var(--accent);
  display: flex; align-items: center; justify-content: center;
  color: #fff;
  font-size: 14px;
  font-weight: 800;
}
.nav-links {
  display: flex;
  gap: 8px;
}
.nav-links a {
  padding: 8px 14px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-2);
  border-radius: 999px;
  transition: background .2s, color .2s;
}
.nav-links a:hover { background: var(--surface); color: var(--text); }
.nav-right { display: flex; align-items: center; gap: 8px; }
.lang-pill, .theme-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border: 1px solid var(--line);
  background: transparent;
  cursor: pointer;
  transition: background .2s, color .2s;
}
.lang-pill:hover, .theme-pill:hover { background: var(--surface); }
.lang-menu {
  position: relative;
}
.lang-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 6px;
  box-shadow: var(--shadow);
  min-width: 140px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  opacity: 0;
  transform: translateY(-4px);
  pointer-events: none;
  transition: opacity .2s, transform .2s;
}
.lang-menu.open .lang-dropdown { opacity: 1; transform: translateY(0); pointer-events: auto; }
.lang-dropdown button {
  text-align: left;
  padding: 9px 12px;
  border-radius: 8px;
  font-size: 13px;
  font-family: var(--font-body);
  display: flex; align-items: center; gap: 10px;
}
.lang-dropdown button:hover { background: var(--surface); }
.lang-dropdown button .flag { font-size: 16px; }
.lang-dropdown button.active { color: var(--accent); font-weight: 600; }

.nav-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  background: var(--text);
  color: var(--bg);
  font-size: 13px;
  font-weight: 600;
  border-radius: 999px;
  transition: transform .2s, gap .2s;
}
.nav-cta:hover { transform: scale(1.02); gap: 12px; }
.nav-cta .arr { transition: transform .2s; }
.nav-cta:hover .arr { transform: rotate(-45deg); }

@media (max-width: 900px) {
  .nav-links { display: none; }
  .hide-sm { display: none !important; }
  .hide-sm-flex { display: none !important; }
}
@media (min-width: 901px) {
  .nav-burger { display: none !important; }
}

/* ---------- BURGER ---------- */
.nav-burger {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  width: 40px;
  height: 40px;
  padding: 0 10px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--bg-2);
  cursor: pointer;
  transition: background .2s, border-color .2s;
}
.nav-burger:hover { border-color: var(--accent); }
.nav-burger span {
  display: block;
  height: 2px;
  background: var(--text);
  border-radius: 99px;
  transition: transform .25s, opacity .25s;
}
.nav-burger span:nth-child(1) { width: 18px; }
.nav-burger span:nth-child(2) { width: 14px; margin-left: auto; }
.nav-burger span:nth-child(3) { width: 18px; }

/* ---------- DRAWER ---------- */
.drawer-overlay {
  position: fixed;
  inset: 0;
  background: color-mix(in srgb, var(--text) 50%, transparent);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 70;
  opacity: 0;
  pointer-events: none;
  transition: opacity .3s;
}
.drawer-overlay.open { opacity: 1; pointer-events: auto; }

.drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(420px, 100vw);
  background: var(--bg);
  z-index: 75;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform .4s cubic-bezier(.2,.7,.2,1);
  overflow-y: auto;
  box-shadow: -30px 0 80px -30px rgba(0,0,0,0.25);
}
.drawer.open { transform: translateX(0); }

.drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px;
  border-bottom: 1px solid var(--line);
}
.drawer-close {
  width: 40px; height: 40px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--bg-2);
  color: var(--text);
  font-size: 14px;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background .2s, border-color .2s;
}
.drawer-close:hover { background: var(--surface); border-color: var(--accent); }

.drawer-links {
  display: flex;
  flex-direction: column;
  padding: 16px 0;
  flex: 1;
}
.drawer-links a {
  display: grid;
  grid-template-columns: 60px 1fr 32px;
  align-items: center;
  gap: 16px;
  padding: 22px 28px;
  font-family: var(--font-display);
  border-bottom: 1px solid var(--line);
  text-decoration: none;
  color: var(--text);
  opacity: 0;
  transform: translateY(8px);
  animation: drawer-link-in .5s cubic-bezier(.2,.7,.2,1) forwards;
  transition: padding-left .25s, background .25s;
}
.drawer.open .drawer-links a { opacity: 1; }
@keyframes drawer-link-in {
  to { opacity: 1; transform: translateY(0); }
}
.drawer-links a:hover {
  padding-left: 36px;
  background: var(--surface);
}
.drawer-links a:hover .drawer-arrow { transform: translateX(4px); color: var(--accent); }
.drawer-links .drawer-num {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--text-mute);
}
.drawer-links .drawer-label {
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.drawer-links .drawer-arrow {
  font-size: 18px;
  color: var(--text-mute);
  transition: transform .25s, color .25s;
  text-align: right;
}

.drawer-foot {
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  border-top: 1px solid var(--line);
}
.drawer-section-label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-mute);
}
.drawer-lang {
  display: flex;
  gap: 8px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--bg-2);
}
.drawer-lang button {
  flex: 1;
  padding: 10px 12px;
  border-radius: 999px;
  background: transparent;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-2);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  cursor: pointer;
  transition: background .2s, color .2s;
}
.drawer-lang button.active { background: var(--text); color: var(--bg); }
.drawer-lang .flag { font-size: 14px; }

.drawer-cta {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 20px 24px;
  background: var(--accent);
  color: #fff;
  font-size: 16px;
  font-weight: 600;
  border-radius: 18px;
  text-decoration: none;
  transition: transform .2s, background .2s;
}
.drawer-cta:hover { transform: translateY(-2px); }
.drawer-cta .arr { font-size: 18px; }

.drawer-contact {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 12px;
}
.drawer-contact a {
  color: var(--text-2);
  text-decoration: none;
  transition: color .2s;
}
.drawer-contact a:hover { color: var(--accent); }

/* ---------- HERO ---------- */
.hero {
  padding-top: 140px;
  padding-bottom: 80px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
}
.hero-availability {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 16px;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 13px;
  color: var(--text-2);
  margin-bottom: 32px;
  width: max-content;
}
.hero-availability .led {
  width: 8px; height: 8px;
  background: #4caf50;
  border-radius: 50%;
  box-shadow: 0 0 0 4px #4caf5022;
  animation: pulse 2.4s infinite;
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 0 #4caf5055; }
  50% { box-shadow: 0 0 0 8px #4caf5000; }
}

.hero h1 {
  font-size: clamp(48px, 9vw, 140px);
  line-height: 0.96;
  letter-spacing: -0.035em;
  max-width: 18ch;
}
.hero h1 .ink { color: var(--accent); }
.hero h1 .underline {
  position: relative;
  display: inline-block;
}
.hero h1 .underline::after {
  content: "";
  position: absolute;
  left: 0; right: 0;
  bottom: 6%;
  height: 0.12em;
  background: var(--accent-4);
  z-index: -1;
  border-radius: 99px;
}

.hero-sub {
  margin-top: 32px;
  font-size: clamp(17px, 1.6vw, 22px);
  color: var(--text-2);
  max-width: 56ch;
  text-wrap: pretty;
}

.hero-actions {
  display: flex;
  gap: 14px;
  margin-top: 40px;
  flex-wrap: wrap;
}
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 26px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  transition: transform .2s, background .2s, color .2s, gap .2s;
  cursor: pointer;
}
.btn-primary { background: var(--text); color: var(--bg); }
.btn-primary:hover { transform: scale(1.02); gap: 14px; }
.btn-ghost { background: transparent; color: var(--text); border: 1px solid var(--line); }
.btn-ghost:hover { background: var(--surface); }
.btn .arr { display: inline-block; transition: transform .25s; }
.btn:hover .arr { transform: translateX(4px); }

.hero-meta {
  margin-top: 80px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  padding-top: 32px;
  border-top: 1px solid var(--line);
}
.hero-meta .stat .num {
  font-family: var(--font-display);
  font-size: clamp(36px, 4vw, 56px);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
}
.hero-meta .stat .num em { color: var(--accent); font-style: normal; }
.hero-meta .stat .lbl {
  font-size: 13px;
  color: var(--text-mute);
  margin-top: 4px;
}
/* ---------- MOBILE RESPONSIVE POLISH ---------- */
@media (max-width: 900px) {
  :root { --gutter: 20px; --r-card: 22px; }

  .nav {
    top: 12px; left: 12px; right: 12px;
    padding: 8px 8px 8px 16px;
  }
  .nav-logo .mark { width: 30px; height: 30px; font-size: 12px; }
  .nav-logo { font-size: 16px; }
  .theme-pill { padding: 8px 10px; }

  /* Section vertical padding consistent; horizontal handled by .wrap gutter */
  .section { padding: 72px 0 !important; }
  section.section[style*="padding"] { padding: 72px 20px !important; }
  /* Ensure .wrap gutter takes effect under inline padding overrides */
  .wrap { padding-left: 20px; padding-right: 20px; }

  /* HERO mobile */
  .hero {
    padding-top: 110px;
    padding-bottom: 60px;
    min-height: 88vh;
  }
  .hero h1 {
    font-size: clamp(40px, 11vw, 64px);
    line-height: 1.02;
    letter-spacing: -0.03em;
  }
  .hero-sub { font-size: 16px; margin-top: 24px; }
  .hero-actions { margin-top: 28px; gap: 10px; }
  .hero-actions .btn { padding: 14px 22px; font-size: 13px; }
  .hero-meta { margin-top: 56px; gap: 12px; grid-template-columns: 1fr 1fr 1fr; padding-top: 24px; }
  .hero-meta .stat .num { font-size: clamp(26px, 7vw, 36px); }
  .hero-meta .stat .lbl { font-size: 10px; line-height: 1.3; }
  .hero-availability { padding: 7px 14px; font-size: 12px; }

  /* About mobile */
  .about-grid { gap: 32px; }
  .about-photo { aspect-ratio: 4/4.5; max-width: 100%; position: static; }
  .about-copy h2 { font-size: clamp(32px, 8vw, 48px); }
  .about-copy p { font-size: 16px; }
  .about-cards { grid-template-columns: 1fr; gap: 12px; margin-top: 28px; }

  /* Work head wraps controls below */
  .work-head { flex-direction: column; align-items: flex-start; gap: 24px; }
  .work-head h2 { font-size: clamp(34px, 8vw, 56px) !important; }
  .carousel-controls {
    width: 100%;
    justify-content: space-between;
  }
  .carousel { margin-top: 32px; }
  .carousel-slide .info { left: 14px; right: 14px; bottom: 14px; }
  .carousel-slide .info-left .tags span { font-size: 10px; padding: 4px 8px; }

  /* Services mobile */
  .services-head { display: block; }
  .services-head h2 {
    width: 100% !important;
    font-size: clamp(34px, 8vw, 56px) !important;
  }
  .svc-card { padding: 24px; min-height: 220px; }
  .svc-card h3 { font-size: 20px; }

  /* Tech mobile */
  .tech-head h2 { font-size: clamp(28px, 7vw, 44px); }
  .tech-pill { padding: 18px 10px; }

  /* Pricing mobile */
  .pricing-head h2 { font-size: clamp(32px, 8vw, 48px); }
  .price-card { padding: 28px 22px; }
  .price-card .price-tag { font-size: 38px; }

  /* Testimonials mobile — handled by carousel styles */
  .tests-head h2 { font-size: clamp(28px, 7vw, 44px); }

  /* Clients mobile */
  .clients .client { padding: 24px 8px; font-size: 16px; }

  /* FAQ mobile */
  .faq-grid .faq-intro { position: static; }
  .faq-grid h2 { font-size: clamp(28px, 7vw, 44px); }

  /* Contact mobile */
  .contact-wrap { padding: 32px 24px; border-radius: 24px; }
  .contact-grid h2 { font-size: clamp(34px, 8vw, 56px); }
  .contact-form { padding: 24px; }

  /* Footer mobile */
  .footer .big { font-size: clamp(36px, 10vw, 64px); }
  .footer-bottom { flex-direction: column; align-items: flex-start; gap: 14px; padding-bottom: 24px !important; }
}

@media (max-width: 480px) {
  .hero h1 { font-size: clamp(36px, 11vw, 48px); }
  .hero-availability { font-size: 11px; }
  .work-head h2, .services-head h2, .contact-grid h2 {
    font-size: clamp(30px, 9vw, 44px) !important;
  }
  .carousel-controls { gap: 8px; }
  .carousel-progress { font-size: 11px; }
  .carousel-progress .bar { width: 50px; }
  .carousel-arrows button { width: 38px; height: 38px; font-size: 15px; }
}

/* Floating shapes */
.hero-shape {
  position: absolute;
  border-radius: 50%;
  filter: blur(40px);
  opacity: 0.55;
  pointer-events: none;
  animation: float 9s ease-in-out infinite;
}
.hero-shape.s1 { width: 380px; height: 380px; background: var(--accent-2); top: 10%; right: -120px; }
.hero-shape.s2 { width: 280px; height: 280px; background: var(--accent-4); bottom: 0; left: -100px; animation-delay: -3s; }
.hero-shape.s3 { width: 220px; height: 220px; background: var(--accent-3); top: 30%; right: 24%; animation-delay: -5s; opacity: 0.35; }
@keyframes float {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(20px, -20px); }
}
[data-theme="dark"] .hero-shape { opacity: 0.18; }

/* ---------- MARQUEE ---------- */
.marquee {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 28px 0;
  overflow: hidden;
  background: var(--bg-2);
}
.marquee-track {
  display: flex;
  gap: 56px;
  white-space: nowrap;
  animation: scroll-x 32s linear infinite;
  width: max-content;
}
.marquee-track span {
  font-family: var(--font-display);
  font-size: clamp(22px, 2.4vw, 36px);
  font-weight: 600;
  color: var(--text-2);
  display: inline-flex;
  align-items: center;
  gap: 56px;
}
.marquee-track .dot {
  width: 8px; height: 8px;
  background: var(--accent);
  border-radius: 50%;
}
@keyframes scroll-x {
  to { transform: translateX(-50%); }
}

/* ---------- ABOUT ---------- */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 64px;
  align-items: stretch;
}
@media (max-width: 900px) { .about-grid { grid-template-columns: 1fr; gap: 40px; } }

.about-photo {
  border-radius: var(--r-card);
  overflow: hidden;
  position: relative;
  background: var(--surface);
  box-shadow: var(--shadow);
  min-height: 100%;
}
.about-photo img { width: 100%; height: 100%; object-fit: cover; }
.about-photo .badge {
  position: absolute;
  bottom: 16px; left: 16px;
  background: var(--bg-2);
  border-radius: 999px;
  padding: 10px 16px;
  font-size: 13px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  box-shadow: var(--shadow-sm);
}
.about-photo .badge .moto { font-size: 16px; }

.about-copy h2 {
  font-size: clamp(36px, 5vw, 72px);
  margin-bottom: 28px;
}
.about-copy h2 .ink { color: var(--accent); }
.about-copy p {
  font-size: clamp(16px, 1.3vw, 19px);
  color: var(--text-2);
  margin: 0 0 18px;
  max-width: 60ch;
  text-wrap: pretty;
}
.about-copy p strong { color: var(--text); font-weight: 600; }

.about-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 36px;
}
.about-cards .card {
  padding: 22px;
  border-radius: 20px;
  background: var(--bg-2);
  border: 1px solid var(--line);
}
.about-cards .card .ico {
  width: 38px; height: 38px;
  border-radius: 12px;
  background: var(--accent);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 18px;
  margin-bottom: 14px;
}
.about-cards .card:nth-child(2) .ico { background: var(--accent-2); color: var(--text); }
.about-cards .card h4 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 4px;
}
.about-cards .card p {
  margin: 0;
  font-size: 13px;
  color: var(--text-2);
}

/* ---------- WORK GRID ---------- */
.work-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 40px;
  margin-bottom: 56px;
  flex-wrap: wrap;
}
.work-head h2 { font-size: clamp(40px, 6vw, 86px); max-width: 14ch; }
.work-head h2 .ink { color: var(--accent); }
.work-head .head-meta {
  color: var(--text-2);
  max-width: 36ch;
  font-size: 16px;
}

.work-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
}
@media (max-width: 800px) { .work-grid { grid-template-columns: 1fr; } }

.work-card {
  position: relative;
  border-radius: var(--r-card);
  overflow: hidden;
  cursor: pointer;
  display: block;
  transition: transform .4s ease;
}
.work-card:hover { transform: translateY(-6px); }
.work-card .img-wrap {
  position: relative;
  aspect-ratio: 16/10;
  overflow: hidden;
  background: var(--surface);
}
.work-card .img-wrap img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .8s cubic-bezier(.2,.7,.2,1);
}
.work-card:hover .img-wrap img { transform: scale(1.04); }

.work-card .info {
  position: absolute;
  left: 24px; right: 24px; bottom: 24px;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 16px;
}
.work-card .info-left h3 {
  font-size: clamp(24px, 2.4vw, 32px);
  font-weight: 800;
  color: var(--card-fg, #fff);
  margin: 0 0 4px;
}
.work-card .info-left .tags {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.work-card .info-left .tags span {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 4px 8px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--card-fg, #fff) 18%, transparent);
  color: var(--card-fg, #fff);
  backdrop-filter: blur(6px);
}
.work-card .open {
  width: 44px; height: 44px;
  border-radius: 50%;
  background: var(--card-fg, #fff);
  color: var(--card-bg, #1a1a1a);
  display: flex; align-items: center; justify-content: center;
  font-size: 16px;
  transition: transform .3s;
  flex-shrink: 0;
}
.work-card:hover .open { transform: rotate(-45deg); }

/* ---------- WORK CAROUSEL ---------- */
.carousel-controls {
  display: flex;
  align-items: center;
  gap: 32px;
  flex-shrink: 0;
}
.carousel-progress {
  display: flex;
  align-items: center;
  gap: 14px;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-mute);
  letter-spacing: 0.06em;
}
.carousel-progress .bar {
  width: 120px;
  height: 2px;
  background: var(--line);
  border-radius: 999px;
  position: relative;
  overflow: hidden;
}
.carousel-progress .bar .fill {
  position: absolute;
  inset: 0;
  background: var(--accent);
  transform-origin: left;
  transition: width .6s cubic-bezier(.2,.7,.2,1);
}
.carousel-arrows { display: flex; gap: 8px; }
.carousel-arrows button {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--bg-2);
  color: var(--text);
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background .2s, border-color .2s, transform .2s, opacity .2s, color .2s;
}
.carousel-arrows button:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  transform: translateY(-2px);
}

.carousel { margin-top: 56px; position: relative; }
.carousel-viewport {
  overflow: hidden;
  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
  touch-action: pan-y;
}
.carousel-viewport.peek {
  /* Show a peek of the next slide */
  mask-image: linear-gradient(to right, transparent 0, #000 24px, #000 calc(100% - 48px), transparent 100%);
  -webkit-mask-image: linear-gradient(to right, transparent 0, #000 24px, #000 calc(100% - 48px), transparent 100%);
  padding: 0 12px 0 12px;
  margin: 0 -12px;
}
.carousel-viewport:active { cursor: grabbing; }

.carousel-track {
  display: flex;
  gap: 12px;
  will-change: transform;
  user-select: none;
}
.carousel-track.snap   { transition: transform .7s cubic-bezier(.2,.7,.2,1); }
.carousel-track.nosnap { transition: none; }
.carousel-track.is-dragging { transition: none; }
.carousel-track.is-dragging .carousel-slide { pointer-events: none; }

.carousel-slide {
  position: relative;
  display: block;
  border-radius: var(--r-card);
  overflow: hidden;
  text-decoration: none;
  background: var(--card-bg, var(--surface));
}
.carousel-slide .img-wrap {
  position: relative;
  aspect-ratio: 16/10;
  overflow: hidden;
  background: var(--card-bg);
  display: flex;
  align-items: center;
  justify-content: center;
}
.carousel-slide .img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  transition: transform .9s cubic-bezier(.2,.7,.2,1);
  -webkit-user-drag: none;
  user-drag: none;
  pointer-events: none;
}
.carousel-slide:hover .img-wrap img { transform: scale(1.025); }

.carousel-slide .info {
  position: absolute;
  left: 20px;
  right: 20px;
  bottom: 20px;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 16px;
  pointer-events: none;
}
.carousel-slide .info > * { pointer-events: auto; }
.carousel-slide .info-left .tags { display: flex; gap: 6px; flex-wrap: wrap; }
.carousel-slide .info-left .tags span {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 6px 10px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--card-fg, #fff) 22%, transparent);
  color: var(--card-fg, #fff);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  font-weight: 600;
}
.carousel-slide .open {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: var(--card-fg, #fff);
  color: var(--card-bg, #1a1a1a);
  display: flex; align-items: center; justify-content: center;
  font-size: 14px;
  transition: transform .3s;
  flex-shrink: 0;
}
.carousel-slide:hover .open { transform: rotate(-45deg); }

.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 32px;
}
.carousel-dots button {
  width: 28px;
  height: 4px;
  border-radius: 99px;
  background: var(--line);
  border: 0;
  cursor: pointer;
  transition: background .25s, width .25s;
  padding: 0;
}
.carousel-dots button:hover { background: var(--text-mute); }
.carousel-dots button.active { background: var(--accent); width: 48px; }

.carousel-hint {
  position: absolute;
  right: 0;
  top: -64px;
  display: none;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-mute);
}
.carousel-hint .hint-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--accent);
  animation: hint-pulse 1.6s infinite ease-in-out;
}
@keyframes hint-pulse {
  0%, 100% { transform: scale(1);   opacity: 1; }
  50%      { transform: scale(1.6); opacity: 0.4; }
}

/* Mobile carousel controls (centered toolbar below viewport) */
.carousel-controls.mobile-only { display: none; }
.carousel-controls.desktop-only { display: flex; }

@media (max-width: 900px) {
  .carousel-controls.desktop-only { display: none; }
  .carousel-controls.mobile-only {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-top: 24px;
    padding: 0 4px;
  }
  .carousel-arrow-big {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    border: 1px solid var(--line);
    background: var(--bg-2);
    color: var(--text);
    font-size: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background .2s, border-color .2s, color .2s, transform .15s;
    flex-shrink: 0;
    -webkit-tap-highlight-color: transparent;
  }
  .carousel-arrow-big:active {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
    transform: scale(0.94);
  }
  .carousel-progress-center {
    flex: 1;
    justify-content: center;
  }
  .carousel-progress-center .bar { flex: 1; max-width: 140px; }
  .carousel-hint { display: inline-flex; }
}
.services-head {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  margin-bottom: 56px;
  align-items: end;
}
.services-head h2 { font-size: clamp(40px, 6vw, 86px); }
.services-head h2 .ink { color: var(--accent); }
.services-head p { color: var(--text-2); max-width: 40ch; font-size: 17px; }
@media (max-width: 800px) { .services-head { grid-template-columns: 1fr; } }

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
@media (max-width: 900px) { .services-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .services-grid { grid-template-columns: 1fr; } }

.svc-card {
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  transition: transform .3s, border-color .3s, background .3s;
  min-height: 280px;
}
.svc-card:hover {
  transform: translateY(-4px);
  border-color: var(--accent);
}
.svc-card .num {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-mute);
  letter-spacing: 0.08em;
}
.svc-card .ico {
  width: 56px; height: 56px;
  border-radius: 18px;
  background: var(--svc-bg, var(--accent));
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 24px;
}
.svc-card h3 {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.01em;
}
.svc-card p {
  font-size: 14px;
  color: var(--text-2);
  margin: 0;
}
.svc-card .more {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--accent);
}

/* ---------- TECH ---------- */
.tech-head {
  text-align: center;
  margin-bottom: 48px;
}
.tech-head h2 { font-size: clamp(36px, 4.5vw, 64px); }
.tech-head p { color: var(--text-2); max-width: 50ch; margin: 20px auto 0; }
.tech-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 14px;
}
@media (max-width: 900px) { .tech-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 480px) { .tech-grid { grid-template-columns: repeat(2, 1fr); } }
.tech-pill {
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: center;
  justify-content: center;
  padding: 24px 14px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: var(--bg-2);
  transition: background .25s, transform .25s, border-color .25s;
  text-align: center;
}
.tech-pill:hover {
  background: var(--surface);
  border-color: var(--accent);
  transform: translateY(-2px);
}
.tech-pill .ico {
  width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  font-size: 22px;
}
.tech-pill .name {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-2);
}

/* ---------- PRICING ---------- */
.pricing-head { text-align: center; margin-bottom: 56px; }
.pricing-head h2 { font-size: clamp(40px, 5.5vw, 72px); }
.pricing-head h2 .ink { color: var(--accent); }
.pricing-head p { color: var(--text-2); max-width: 50ch; margin: 18px auto 0; font-size: 17px; }

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  padding-top: 24px; /* room for floating MOST POPULAR ribbon */
}
@media (max-width: 900px) { .pricing-grid { grid-template-columns: 1fr; max-width: 480px; margin: 0 auto; } }

.price-card {
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  padding: 36px 30px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  position: relative;
  transition: transform .3s, border-color .3s;
}
.price-card:hover { transform: translateY(-4px); }
.price-card.featured {
  background: var(--text);
  color: var(--bg);
  border-color: var(--text);
}
.price-card.featured .price-tag { color: var(--bg-2); }
.price-card.featured p { color: color-mix(in srgb, var(--bg) 80%, transparent); }
.price-card.featured .ribbon {
  position: absolute;
  top: -12px; left: 50%; transform: translateX(-50%);
  background: var(--accent);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: 999px;
}
.price-card .tier {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-mute);
}
.price-card.featured .tier { color: color-mix(in srgb, var(--bg) 70%, transparent); }
.price-card h3 {
  font-size: 28px;
  font-weight: 800;
  margin-top: 4px;
}
.price-card .price-tag {
  font-family: var(--font-display);
  font-size: 44px;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1;
  margin-top: 4px;
}
.price-card .price-tag em {
  font-style: normal;
  font-size: 14px;
  color: var(--text-mute);
  font-weight: 500;
  letter-spacing: 0;
}
.price-card.featured .price-tag em { color: color-mix(in srgb, var(--bg) 60%, transparent); }
.price-card p.desc {
  font-size: 14px;
  color: var(--text-2);
  margin: 4px 0 0;
}
.price-card ul {
  list-style: none;
  padding: 0;
  margin: 8px 0 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.price-card li {
  font-size: 14px;
  display: flex;
  gap: 10px;
  align-items: start;
}
.price-card li::before {
  content: "✓";
  color: var(--accent);
  font-weight: 800;
  flex-shrink: 0;
}
.price-card.featured li::before { color: var(--accent-4); }
.price-card .pc-btn {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 20px;
  border-radius: 999px;
  background: var(--text);
  color: var(--bg);
  font-size: 13px;
  font-weight: 600;
  transition: gap .2s;
}
.price-card.featured .pc-btn { background: var(--bg-2); color: var(--text); }
.price-card .pc-btn:hover { gap: 12px; }

/* ---------- TESTIMONIALS ---------- */
.tests-head { text-align: center; margin-bottom: 56px; }
.tests-head h2 { font-size: clamp(36px, 5vw, 64px); }
.tests-head h2 .ink { color: var(--accent); }

/* ── Desktop grid (unchanged) ── */
.tests-grid--desktop {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

/* ── Mobile carousel (hidden on desktop) ── */
.tests-carousel-wrap { display: none; }
.tests-dots          { display: none; }

.test-card {
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.test-card .stars {
  color: var(--accent-4);
  font-size: 14px;
  letter-spacing: 4px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.test-card .stars-num {
  font-size: 13px;
  color: var(--text-mute);
  letter-spacing: 0;
}
.test-card blockquote {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 19px;
  line-height: 1.35;
  color: var(--text);
  letter-spacing: -0.01em;
}
.test-card .who { display: flex; align-items: center; gap: 12px; margin-top: auto; }
.test-card .av {
  width: 44px; height: 44px;
  border-radius: 50%;
  background: var(--surface);
  color: var(--text-2);
  font-weight: 700;
  font-size: 14px;
  display: flex; align-items: center; justify-content: center;
  border: 1px solid var(--line);
  flex-shrink: 0;
}
.test-card .name { font-size: 14px; font-weight: 600; }
.test-card .role { font-size: 12px; color: var(--text-mute); }

/* ── Mobile breakpoint ── */
@media (max-width: 768px) {
  /* hide desktop grid */
  .tests-grid--desktop { display: none; }

  /* show carousel */
  .tests-carousel-wrap {
    display: block;
    position: relative;
    overflow: hidden;
    width: 100%;
    user-select: none;
    -webkit-user-select: none;
  }

  .tests-carousel-track {
    display: flex;
    width: 100%;
    will-change: transform;
    cursor: grab;
  }
  .tests-carousel-track:active { cursor: grabbing; }

  .tests-carousel-slide {
    flex: 0 0 100%;
    width: 100%;
    padding: 0 20px;
    box-sizing: border-box;
  }

  .tests-carousel-slide .test-card {
    width: 100%;
    box-sizing: border-box;
    padding: 28px 24px;
    border-radius: 20px;
    gap: 20px;
    min-height: unset;
  }

  .tests-carousel-slide .test-card blockquote {
    font-size: 18px;
    line-height: 1.4;
  }

  /* Fade edges — only left & right, not top/bottom */
  .tests-fade {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 20px;
    pointer-events: none;
    z-index: 2;
  }
  .tests-fade--left {
    left: 0;
    background: linear-gradient(to right, var(--bg), transparent);
  }
  .tests-fade--right {
    right: 0;
    background: linear-gradient(to left, var(--bg), transparent);
  }

  /* Dots */
  .tests-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 20px;
    padding-bottom: 4px;
  }
  .tests-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--line);
    border: none;
    padding: 0;
    cursor: pointer;
    transition: background 0.25s, transform 0.25s;
  }
  .tests-dot--active {
    background: var(--accent);
    transform: scale(1.3);
  }
}

/* ---------- CLIENTS ---------- */
.clients {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  display: grid;
  grid-template-columns: repeat(6, 1fr);
}
@media (max-width: 900px) { .clients { grid-template-columns: repeat(3, 1fr); } }
.clients .client {
  padding: 32px 12px;
  text-align: center;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 22px;
  color: var(--text-mute);
  letter-spacing: -0.01em;
  border-right: 1px solid var(--line);
  transition: color .25s, background .25s;
}
.clients .client:nth-child(6n) { border-right: 0; }
@media (max-width: 900px) {
  .clients .client { border-right: 1px solid var(--line); }
  .clients .client:nth-child(3n) { border-right: 0; }
}
.clients .client:hover { color: var(--accent); background: var(--surface); }

/* ---------- FAQ ---------- */
.faq-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 64px;
  align-items: start;
}
@media (max-width: 900px) { .faq-grid { grid-template-columns: 1fr; gap: 24px; } }
.faq-grid h2 { font-size: clamp(36px, 5vw, 64px); }
.faq-grid h2 .ink { color: var(--accent); }
.faq-grid .faq-intro {
  position: sticky;
  top: 100px;
}
@media (max-width: 900px) {
  .faq-grid .faq-intro { position: static !important; top: auto !important; }
}
.faq-grid .faq-intro p { color: var(--text-2); margin-top: 18px; max-width: 32ch; }

.faq-list { display: flex; flex-direction: column; gap: 12px; }
.faq-item {
  border-bottom: 1px solid var(--line);
  padding: 20px 0;
  cursor: pointer;
}
.faq-item .q {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  font-family: var(--font-display);
  font-size: clamp(18px, 2vw, 24px);
  font-weight: 700;
  letter-spacing: -0.01em;
}
.faq-item .q .ico {
  width: 32px; height: 32px;
  border-radius: 50%;
  background: var(--surface);
  display: flex; align-items: center; justify-content: center;
  font-size: 18px;
  transition: transform .3s, background .3s, color .3s;
  flex-shrink: 0;
}
.faq-item[open] .q .ico { transform: rotate(45deg); background: var(--accent); color: #fff; }
.faq-item .a {
  padding-top: 16px;
  color: var(--text-2);
  max-width: 60ch;
  font-size: 15px;
  line-height: 1.6;
}

/* ---------- CONTACT ---------- */
.contact-wrap {
  background: var(--text);
  color: var(--bg);
  border-radius: 32px;
  padding: clamp(40px, 6vw, 88px);
  position: relative;
  overflow: hidden;
}
.contact-wrap .blob {
  position: absolute;
  width: 500px; height: 500px;
  background: var(--accent);
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.45;
  top: -200px; right: -150px;
  pointer-events: none;
}
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  position: relative;
}
@media (max-width: 900px) { .contact-grid { grid-template-columns: 1fr; gap: 40px; } }

.contact-grid h2 {
  font-size: clamp(40px, 6vw, 88px);
  color: var(--bg);
}
.contact-grid h2 .ink { color: var(--accent-4); }

.contact-left p {
  color: color-mix(in srgb, var(--bg) 75%, transparent);
  font-size: 17px;
  margin: 24px 0 32px;
  max-width: 40ch;
}
.contact-info {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.contact-info .row {
  display: flex;
  align-items: center;
  gap: 14px;
}
.contact-info .row .ico {
  width: 40px; height: 40px;
  border-radius: 12px;
  background: color-mix(in srgb, var(--bg) 12%, transparent);
  display: flex; align-items: center; justify-content: center;
  font-size: 18px;
  color: var(--accent-4);
  flex-shrink: 0;
}
.contact-info .k {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--bg) 50%, transparent);
}
.contact-info .v { font-size: 15px; font-weight: 500; color: var(--bg); }
.contact-info .v a:hover { color: var(--accent-4); }

.contact-form {
  background: color-mix(in srgb, var(--bg-2) 10%, transparent);
  border: 1px solid color-mix(in srgb, var(--bg) 18%, transparent);
  border-radius: 24px;
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  backdrop-filter: blur(8px);
}
.contact-form label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--bg) 60%, transparent);
  display: block;
  margin-bottom: 6px;
}
.contact-form .field {
  display: flex; flex-direction: column;
}
.contact-form input,
.contact-form textarea,
.contact-form select {
  background: color-mix(in srgb, var(--bg) 8%, transparent);
  border: 1px solid color-mix(in srgb, var(--bg) 14%, transparent);
  color: var(--bg);
  border-radius: 12px;
  padding: 12px 14px;
  font: inherit;
  font-size: 14px;
  transition: border-color .2s, background .2s;
}
.contact-form input::placeholder, .contact-form textarea::placeholder {
  color: color-mix(in srgb, var(--bg) 35%, transparent);
}
.contact-form input:focus, .contact-form textarea:focus, .contact-form select:focus {
  outline: none;
  border-color: var(--accent-4);
  background: color-mix(in srgb, var(--bg) 14%, transparent);
}
.contact-form textarea { min-height: 110px; resize: vertical; font-family: inherit; }
.contact-form .row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 480px) { .contact-form .row-2 { grid-template-columns: 1fr; } }
.contact-form button {
  margin-top: 8px;
  padding: 16px 24px;
  border-radius: 999px;
  background: var(--accent-4);
  color: #1a1a1a;
  font-size: 14px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: gap .2s, background .2s;
}
.contact-form button:hover { gap: 14px; background: #fff; }

/* ---------- FOOTER ---------- */
.footer {
  padding: 48px 0 36px;
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 32px;
  flex-wrap: wrap;
}
.footer-left { display: flex; flex-direction: column; gap: 12px; }
.footer .big {
  font-family: var(--font-display);
  font-size: clamp(40px, 7vw, 100px);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 0.9;
  color: var(--text-mute);
}
.footer .big .ink { color: var(--accent); }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-mute);
  flex-wrap: wrap;
}
.footer-bottom .socials { display: flex; gap: 18px; }
.footer-bottom .socials a:hover { color: var(--accent); }

/* ---------- PROJECT DETAIL PAGE ---------- */
.proj-main { padding-top: 80px; }

.proj-hero {
  padding: 80px 0 56px;
  position: relative;
}
.proj-back {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px;
  border-radius: 999px;
  background: var(--bg-2);
  border: 1px solid var(--line);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 500;
  margin-bottom: 56px;
  transition: background .2s, color .2s, border-color .2s, gap .2s, padding-left .2s;
}
.proj-back:hover {
  background: var(--surface);
  border-color: var(--accent);
  color: var(--accent);
  gap: 14px;
  padding-left: 16px;
}
.proj-back span { font-size: 14px; transition: transform .2s; }
.proj-back:hover span { transform: translateX(-3px); }

.proj-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-mute);
  margin-bottom: 28px;
}
.proj-eyebrow .dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--accent);
}

.proj-title {
  font-family: var(--font-display);
  font-size: clamp(40px, 9vw, 124px);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 0.96;
  margin: 0 0 32px;
  max-width: 18ch;
}

.proj-summary {
  font-size: clamp(18px, 1.6vw, 22px);
  color: var(--text-2);
  max-width: 64ch;
  text-wrap: pretty;
  margin: 0 0 64px;
}

.proj-meta {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  padding-top: 32px;
  border-top: 1px solid var(--line);
}
@media (max-width: 800px) { .proj-meta { grid-template-columns: 1fr 1fr; gap: 28px 20px; } }
@media (max-width: 480px) { .proj-meta { grid-template-columns: 1fr 1fr; } }

.meta-cell .k {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-mute);
  margin-bottom: 10px;
}
.meta-cell .v {
  font-size: 15px;
  font-weight: 500;
  color: var(--text);
  line-height: 1.45;
}
.scope-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.scope-tags span {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 5px 10px;
  border-radius: 999px;
  background: var(--surface);
  color: var(--text-2);
  border: 1px solid var(--line);
}

/* HERO CANVAS */
.proj-canvas-hero {
  position: relative;
  aspect-ratio: 16/9;
  background: var(--card-bg, var(--surface));
  border-radius: 28px;
  overflow: hidden;
  margin: 32px 0 48px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.proj-canvas-hero img {
  width: 100%; height: 100%; object-fit: cover;
}
.canvas-empty.big .canvas-cross {
  font-size: 88px;
}
.canvas-empty.big .canvas-label {
  font-size: clamp(28px, 4vw, 56px);
  font-weight: 800;
  letter-spacing: -0.03em;
}

/* BODY */
.proj-body {
  padding-top: 80px !important;
  padding-bottom: 80px !important;
}
.proj-body-grid {
  display: grid;
  grid-template-columns: 360px 1fr;
  gap: 80px;
  align-items: start;
}
@media (max-width: 900px) { .proj-body-grid { grid-template-columns: 1fr; gap: 32px; } }

.proj-aside {
  position: sticky;
  top: 110px;
}
@media (max-width: 900px) { .proj-aside { position: static; top: auto; } }
.proj-aside .eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
}
.proj-aside h2 {
  font-family: var(--font-display);
  font-size: clamp(28px, 3vw, 40px);
  font-weight: 800;
  letter-spacing: -0.025em;
  margin: 0 0 18px;
}
.proj-aside p {
  font-size: 16px;
  color: var(--text-2);
  line-height: 1.6;
  margin: 0 0 28px;
  max-width: 38ch;
}
.proj-aside-meta {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}
.aside-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
}
.aside-row .k {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-mute);
}
.aside-row .v {
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  text-align: right;
}

.proj-content {
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.proj-content p {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(20px, 1.8vw, 26px);
  line-height: 1.45;
  letter-spacing: -0.01em;
  color: var(--text);
  margin: 0;
  max-width: 38ch;
  text-wrap: pretty;
}

/* GALLERY */
.proj-gallery {
  padding-top: 0 !important;
  padding-bottom: 80px !important;
}
.gallery-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 28px;
}
@media (max-width: 800px) { .gallery-grid { grid-template-columns: 1fr; gap: 20px; } }

.proj-canvas-block {
  position: relative;
  background: var(--card-bg, var(--surface));
  border-radius: 24px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.proj-canvas-block:not(.tall):not(.wide) { aspect-ratio: 4/3; }
.proj-canvas-block.tall { aspect-ratio: 4/5; }
.proj-canvas-block.wide { aspect-ratio: 16/9; }
.proj-canvas-block .canvas-empty .canvas-cross { font-size: 56px; }

/* NEXT PROJECT */
.proj-next {
  display: flex;
  flex-direction: column;
  gap: 24px;
  text-decoration: none;
  color: var(--text);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 56px 0;
  transition: padding 0.4s cubic-bezier(.2,.7,.2,1);
}
.proj-next:hover { padding: 72px 0; }
.next-meta {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-mute);
}
.next-meta .next-num { color: var(--accent); font-weight: 600; }
.next-title {
  font-family: var(--font-display);
  font-size: clamp(48px, 9vw, 124px);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 0.96;
  margin: 0;
  transition: color .35s;
}
.proj-next:hover .next-title { color: var(--accent); }
.next-tags {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.next-tags span:not(.next-arrow) {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--surface);
  color: var(--text-2);
  border: 1px solid var(--line);
}
.next-arrow {
  margin-left: auto;
  width: 56px; height: 56px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 22px;
  transition: transform .35s;
}
.proj-next:hover .next-arrow { transform: translateX(8px) rotate(-15deg); }

@media (max-width: 600px) {
  .proj-hero { padding: 56px 0 40px; }
  .proj-back { margin-bottom: 32px; }
  .proj-summary { margin-bottom: 40px; }
  .proj-canvas-hero { aspect-ratio: 4/5; border-radius: 22px; }
  .proj-body { padding-top: 56px !important; padding-bottom: 56px !important; }
  .proj-next { padding: 36px 0; }
  .proj-next:hover { padding: 36px 0; }
  .next-arrow { width: 44px; height: 44px; font-size: 18px; }
}
/* Reveal animations — content visible by default; only hidden when JS opts in via [data-anim].
   If the animation timeline doesn't advance (some iframes), JS auto-removes [data-anim]
   so content stays visible without the slide-in. */
@keyframes reveal-in {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes reveal-in-left {
  from { opacity: 0; transform: translate(-40px, 30px); }
  to   { opacity: 1; transform: translate(0, 0); }
}
@keyframes reveal-in-right {
  from { opacity: 0; transform: translate(40px, 30px); }
  to   { opacity: 1; transform: translate(0, 0); }
}
.reveal, .reveal-stagger { opacity: 1; }
[data-anim] .reveal:not(.in),
[data-anim] .reveal-stagger:not(.in) { opacity: 0; }
[data-anim] .reveal.in        { animation: reveal-in       .9s cubic-bezier(.2,.7,.2,1) forwards; }
[data-anim] .reveal-stagger.from-left.in  { animation: reveal-in-left  1s cubic-bezier(.2,.7,.2,1) forwards; }
[data-anim] .reveal-stagger.from-right.in { animation: reveal-in-right 1s cubic-bezier(.2,.7,.2,1) forwards; }
[data-anim] .reveal[data-d="100"].in { animation-delay: .08s; }
[data-anim] .reveal[data-d="200"].in { animation-delay: .16s; }
[data-anim] .reveal[data-d="300"].in { animation-delay: .24s; }
[data-anim] .reveal[data-d="400"].in { animation-delay: .32s; }
[data-anim] .reveal[data-d="500"].in { animation-delay: .40s; }

/* ---------- FEATURED WORK GRID (Kurawa-style) ---------- */
.featured-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px 28px;
  margin-top: 64px;
}
@media (max-width: 800px) {
  .featured-grid { grid-template-columns: 1fr; gap: 36px; }
}

.feat-card {
  display: flex;
  flex-direction: column;
  gap: 0;
  text-decoration: none;
  color: inherit;
  border-radius: var(--r-card);
  background: var(--bg-2);
  border: 1px solid var(--line);
  overflow: hidden;
  transition: transform .4s cubic-bezier(.2,.7,.2,1), box-shadow .4s, border-color .4s;
}
.feat-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 30px 80px -30px rgba(20,18,14,0.25), 0 12px 30px -16px rgba(20,18,14,0.12);
  border-color: color-mix(in srgb, var(--accent) 25%, var(--line));
}

.feat-meta-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 24px 14px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-mute);
}
.feat-num { color: var(--accent); font-weight: 600; }

.feat-canvas {
  position: relative;
  aspect-ratio: 16/11;
  background: var(--card-bg, var(--surface));
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 14px;
  border-radius: calc(var(--r-card) - 8px);
}
.feat-canvas img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .8s cubic-bezier(.2,.7,.2,1);
  will-change: transform;
}
.feat-card:hover .feat-canvas img { transform: scale(1.04) translateY(0) !important; }

.feat-canvas .canvas-empty {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: var(--card-fg, var(--text));
  text-align: center;
  padding: 24px;
}
.feat-canvas .canvas-cross {
  font-size: 56px;
  font-weight: 200;
  line-height: 1;
  opacity: 0.4;
  transition: transform .5s, opacity .3s;
}
.feat-card:hover .canvas-cross {
  transform: rotate(90deg) scale(1.1);
  opacity: 0.7;
}
.feat-canvas .canvas-label {
  font-family: var(--font-display);
  font-size: clamp(22px, 2.4vw, 32px);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.1;
  max-width: 16ch;
}
.feat-canvas .canvas-hint {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  opacity: 0.55;
  margin-top: 6px;
}

/* Diagonal stripe pattern overlay for blank canvases */
.feat-canvas .canvas-empty::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: repeating-linear-gradient(
    45deg,
    transparent 0 22px,
    color-mix(in srgb, var(--card-fg, #1a1a1a) 4%, transparent) 22px 23px
  );
  pointer-events: none;
}

/* Hover overlay with "View case" pill */
.feat-canvas-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: end;
  justify-content: end;
  padding: 20px;
  pointer-events: none;
  background: linear-gradient(180deg, transparent 50%, color-mix(in srgb, var(--card-bg, #000) 70%, transparent) 100%);
  opacity: 0;
  transition: opacity .4s;
}
.feat-card:hover .feat-canvas-overlay { opacity: 1; }
.feat-hover {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px;
  border-radius: 999px;
  background: var(--card-fg, #fff);
  color: var(--card-bg, #1a1a1a);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 700;
  transform: translateY(10px);
  transition: transform .4s cubic-bezier(.2,.7,.2,1);
}
.feat-card:hover .feat-hover { transform: translateY(0); }

.feat-foot {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 24px 24px;
}
.feat-foot-left { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.feat-title {
  font-family: var(--font-display);
  font-size: clamp(20px, 1.9vw, 26px);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin: 0;
  color: var(--text);
}
.feat-tags { display: flex; gap: 6px; flex-wrap: wrap; }
.feat-tags span {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 5px 10px;
  border-radius: 999px;
  background: var(--surface);
  color: var(--text-2);
  border: 1px solid var(--line);
}
.feat-arrow {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--surface);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  color: var(--text);
  transition: background .25s, color .25s, transform .25s, border-color .25s;
}
.feat-card:hover .feat-arrow {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
  transform: rotate(-45deg);
}

/* ---- CTA card (4th block) ---- */
.feat-card-cta { background: var(--text); border-color: var(--text); }
.feat-card-cta .feat-meta-top { color: color-mix(in srgb, var(--bg) 50%, transparent); }
.feat-card-cta .feat-num { color: var(--accent); }
.feat-card-cta .feat-title { color: var(--bg); }
.feat-card-cta .feat-tags span {
  background: color-mix(in srgb, var(--bg) 10%, transparent);
  color: var(--bg);
  border-color: color-mix(in srgb, var(--bg) 18%, transparent);
}
.feat-card-cta .feat-arrow {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
.feat-card-cta:hover .feat-arrow {
  background: var(--bg);
  color: var(--text);
}

.feat-canvas-cta {
  background: var(--text);
  border-radius: calc(var(--r-card) - 8px);
}
.feat-canvas-cta .cta-pattern {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  pointer-events: none;
  opacity: 0.08;
}
.feat-canvas-cta .cta-pattern span {
  border-right: 1px solid var(--bg);
}
.feat-canvas-cta .cta-pattern span:last-child { border-right: 0; }

.feat-canvas-cta .cta-content {
  position: relative;
  z-index: 1;
  text-align: left;
  width: 100%;
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  height: 100%;
  justify-content: space-between;
}
.feat-canvas-cta .cta-eyebrow {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-4);
}
.feat-canvas-cta .cta-big {
  font-family: var(--font-display);
  font-size: clamp(32px, 4vw, 48px);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1;
  color: var(--bg);
  margin: 0;
  max-width: 14ch;
}
.feat-canvas-cta .cta-circle {
  align-self: flex-end;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  transition: transform .4s cubic-bezier(.2,.7,.2,1);
}
.feat-card-cta:hover .cta-circle { transform: scale(1.1) rotate(-15deg); }

@media (max-width: 600px) {
  .feat-canvas-cta .cta-big { font-size: 28px; }
  .feat-canvas-cta .cta-content { padding: 22px; }
  .feat-canvas-cta .cta-circle { width: 56px; height: 56px; font-size: 22px; }
  .feat-foot { padding: 18px 18px 20px; }
  .feat-meta-top { padding: 14px 18px 10px; }
  .feat-canvas { margin: 0 10px; }
}

/* ---------- PRICING 3D ---------- */
.pricing-grid { perspective: 1400px; padding-top: 24px; overflow: visible; }

.price-card-3d {
  background: transparent !important;
  border: 0 !important;
  padding: 0 !important;
  transform-style: preserve-3d;
  will-change: transform;
  /* At rest the card is flat. On mouseleave we ease back to this state. */
  transform: perspective(800px) rotateX(0deg) rotateY(0deg);
  /* Two parallel transitions:
       - opacity / filter: smooth fade for the dim-others effect (0.6s
         ease-out, so the surrounding cards melt gently).
       - transform: only the *return* uses a transition (0.45s);
         while the cursor is on the card the :hover override below cuts
         it to 0 so the tilt tracks the cursor 1:1 with no startup pop. */
  transition:
    opacity 0.6s cubic-bezier(0.22, 1, 0.36, 1),
    filter 0.6s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.45s ease;
}
/* :hover (not the React-managed class) controls the transform transition
   so it applies the instant the cursor enters — before React re-renders
   the className. Without this the first onMouseMove fires while the
   transition is still 0.45s and the tilt "jumps" into pose. */
.price-card-3d:hover {
  transition:
    opacity 0.6s cubic-bezier(0.22, 1, 0.36, 1),
    filter 0.6s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0s;
  z-index: 3;
}
/* The .reveal class is intentionally NOT on the price cards (see
   components.jsx). These two !important rules dim the non-hovered
   cards without touching their transform — only opacity + blur shift,
   so a dimmed card stays perfectly still. */
.price-card-3d.is-dimmed {
  opacity: 0.45 !important;
  filter: blur(2px) !important;
}

/* Responsive: disable the 3D tilt + dim effects on narrow viewports
   and touch devices. The inline transform written by onMouseMove is
   force-flattened with `!important`, the dim-others rule is overridden
   to its rest state, and the slow transitions are dropped so taps feel
   immediate. We pair `(max-width: 900px)` with `(hover: none)` to also
   cover desktop touch displays. */
@media (max-width: 900px), (hover: none) {
  .price-card-3d,
  .price-card-3d:hover {
    transform: none !important;
    transition: opacity 0.25s ease, filter 0.25s ease;
  }
  .price-card-3d.is-dimmed {
    opacity: 1 !important;
    filter: none !important;
  }
}
.price-card-inner {
  position: relative;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  padding: 36px 30px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  transform-style: preserve-3d;
  box-shadow: 0 4px 16px -8px rgba(20,18,14,0.08);
  transition: box-shadow .3s, border-color .3s;
  overflow: hidden;
  height: 100%;
}
.price-card-3d:hover .price-card-inner {
  box-shadow: 0 40px 80px -30px rgba(20,18,14,0.35),
              0 20px 40px -20px rgba(20,18,14,0.15);
  border-color: color-mix(in srgb, var(--accent) 30%, var(--line));
}
.price-card-3d.featured .price-card-inner {
  background: var(--text);
  color: var(--bg);
  border-color: var(--text);
}
.price-card-3d.featured .tier { color: color-mix(in srgb, var(--bg) 70%, transparent); }
.price-card-3d.featured p { color: color-mix(in srgb, var(--bg) 80%, transparent); }
.price-card-3d.featured .price-tag em { color: color-mix(in srgb, var(--bg) 60%, transparent); }
.price-card-3d.featured li::before { color: var(--accent-4); }
.price-card-3d.featured .pc-btn { background: var(--bg-2); color: var(--text); }
.price-card-3d.featured .ribbon {
  background: var(--accent);
  color: #fff;
}
.price-card-3d .ribbon {
  position: absolute;
  top: -12px; left: 50%;
  background: var(--accent);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: 999px;
  transform: translate(-50%, 0) translateZ(40px);
  z-index: 4;
}
.price-card-3d .price-card-inner > * { transform: translateZ(20px); }
.price-card-3d .price-card-inner > .ribbon { transform: translate(-50%, 0) translateZ(40px); }
.price-card-3d .pc-btn { transform: translateZ(40px); }

/* Glare effect */
.price-card-glare {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(circle at var(--mx) var(--my), color-mix(in srgb, var(--accent) 20%, transparent) 0%, transparent 45%);
  opacity: 0;
  transition: opacity .3s;
  z-index: 3;
  border-radius: var(--r-card);
  mix-blend-mode: screen;
}
.price-card-3d:hover .price-card-glare { opacity: 1; }
.price-card-3d.featured .price-card-glare { mix-blend-mode: normal; }

@media (hover: none) {
  .price-card-3d:hover {
    transform: none;
  }
}

/* ---------- BRANDS (2 rows × 5 cols, each with own type) ---------- */
.brands-head { text-align: center; margin-bottom: 56px; }

.brands-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
  border-radius: 24px;
  overflow: hidden;
  background: var(--bg-2);
}
.brand-cell {
  position: relative;
  padding: 48px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 4px;
  text-decoration: none;
  color: inherit;
  min-height: 150px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
  transition: background .3s;
}
.brand-cell::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 0%, color-mix(in srgb, var(--accent) 10%, transparent) 100%);
  transform: translateY(100%);
  transition: transform .5s cubic-bezier(.2,.7,.2,1);
  z-index: 0;
}
.brand-cell:hover::before { transform: translateY(0); }
.brand-cell > * { position: relative; z-index: 1; }

.brand-lockup {
  display: inline-flex;
  align-items: center;
  filter: grayscale(0.15);
  transition: filter .35s cubic-bezier(.2,.7,.2,1), transform .35s cubic-bezier(.2,.7,.2,1);
}
.brand-cell:hover .brand-lockup {
  filter: grayscale(0);
  transform: translateY(-2px) scale(1.05);
}
.brand-name { line-height: 1; white-space: nowrap; }
.brand-sub {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-top: 6px;
}

@media (max-width: 1024px) {
  .brand-cell { padding: 36px 14px; min-height: 130px; }
  .brand-name { font-size: 17px !important; }
}

@media (max-width: 720px) {
  .brands-grid { grid-template-columns: repeat(2, 1fr); border-radius: 18px; }
  .brand-cell {
    padding: 32px 14px;
    min-height: 120px;
  }
  .brand-name { font-size: 16px !important; }
}


/* =========================================================
   v2 polish — added by Fran Ruiz refactor 2026-05
   ========================================================= */

/* ---------- WORK HEAD: explicit mobile left alignment ---------- */
.work-head { text-align: left; }
.work-head h2 { text-align: left; }
@media (max-width: 900px) {
  .work-head { width: 100%; align-items: flex-start !important; }
  .work-head h2 {
    max-width: none !important;
    width: 100%;
    align-self: flex-start;
    text-align: left !important;
    margin-left: 0 !important;
    margin-right: auto !important;
  }
  /* Make sure the eyebrow line sits flush left, like the rest of sections */
  #work > .eyebrow { justify-content: flex-start !important; }
}

/* ---------- BRANDS / TRUSTED BY — minimal monochrome ---------- */
.brands-grid {
  background: transparent !important;
  border: 0 !important;
}
.brand-cell {
  border: 0 !important;
  background: transparent !important;
  padding: 36px 20px !important;
  min-height: 120px !important;
}
.brand-cell::before { display: none !important; }
.brand-cell .brand-name {
  color: var(--text) !important;
  background: none !important;
  -webkit-background-clip: initial !important;
          background-clip: initial !important;
  transition: opacity .25s ease, transform .35s cubic-bezier(.2,.7,.2,1);
  opacity: 0.78;
  max-width: 100%;
  display: inline-block;
  text-align: center;
  word-break: break-word;
  line-height: 1.15;
}
.brand-cell:hover .brand-name {
  opacity: 1;
  transform: translateY(-1px);
}
@media (max-width: 1024px) {
  .brand-cell .brand-name { font-size: 17px !important; }
}
@media (max-width: 720px) {
  .brand-cell { padding: 28px 14px !important; min-height: 100px !important; }
  .brand-cell .brand-name { font-size: 16px !important; }
}

/* Hover-dim is now driven by the React-managed `.is-dimmed` class on
   `.price-card-3d` (see top of this file's PRICING 3D section). The
   legacy `:has(:hover)` rules that lived here were re-introducing
   `transform: scale(...)` on the other cards and clobbering the smooth
   tilt of the active one — they're intentionally gone. */

/* Featured card retains its dark visual but no ribbon */
.price-card-3d.featured .price-card-inner {
  position: relative;
  /* Stand a touch taller than the side cards so it reads as the
     "recommended" tier even before hover. */
  margin-top: -16px;
  margin-bottom: -16px;
  padding-top: 52px;
  padding-bottom: 52px;
  border: 0 !important;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}
/* On mobile the pricing grid stacks vertically, so the -16px margins
   on the featured card collapse the gap with its neighbours and the
   first two cards end up touching. Drop the negative margins (and the
   extra vertical padding that compensated for them) below the stacking
   breakpoint so all three cards sit with the same grid gap between
   them. */
@media (max-width: 900px) {
  .price-card-3d.featured .price-card-inner {
    margin-top: 0;
    margin-bottom: 0;
    padding-top: 36px;
    padding-bottom: 36px;
  }
}
.price-card-3d.featured .tier {
  /* Solid accent badge in white text — the "ESTÁNDAR" pill. */
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  width: max-content;
}
/* Inverted CTA: accent fill + white text */
.price-card-3d.featured .pc-btn {
  background: var(--accent) !important;
  color: #fff !important;
}
.price-card-3d.featured .pc-btn:hover { background: var(--accent) !important; }
/* Checks in accent (replaces the previous accent-4 tint) */
.price-card-3d.featured li::before { color: var(--accent) !important; }
/* Dark mode flip: light-text background, dark text */
[data-theme="dark"] .price-card-3d.featured .price-card-inner {
  background: #f3ede2;
  color: #14130f;
}
[data-theme="dark"] .price-card-3d.featured h3,
[data-theme="dark"] .price-card-3d.featured .price-tag {
  color: #14130f;
}
[data-theme="dark"] .price-card-3d.featured p {
  color: color-mix(in srgb, #14130f 75%, transparent);
}

/* ---------- TOOLS CLUSTER (Connected systems) ---------- */
.tools-section { padding-top: 120px !important; padding-bottom: 120px !important; }
.tools-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.1fr);
  gap: clamp(40px, 6vw, 96px);
  align-items: center;
}
@media (max-width: 980px) {
  .tools-grid { grid-template-columns: 1fr; gap: 56px; }
}

.tools-text .eyebrow { margin-bottom: 28px; }
.tools-text h2 {
  font-size: clamp(40px, 5.6vw, 76px);
  letter-spacing: -0.03em;
  line-height: 1;
  max-width: 14ch;
}
.tools-text h2 .ink { color: var(--accent); }
.tools-text p {
  margin-top: 24px;
  font-size: clamp(15px, 1.2vw, 17px);
  color: var(--text-2);
  max-width: 38ch;
  text-wrap: pretty;
}

.tools-bullets {
  margin-top: 36px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}
.tools-bullets .tb {
  display: flex;
  align-items: baseline;
  gap: 16px;
}
.tools-bullets .tb-num {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 32px;
  letter-spacing: -0.02em;
  color: var(--accent);
  min-width: 60px;
  line-height: 1;
}
.tools-bullets .tb-label {
  font-size: 14px;
  color: var(--text-2);
  font-weight: 500;
}

/* The cluster: square area with center + 8 slots placed in circle */
.tools-cluster {
  position: relative;
  width: 100%;
  aspect-ratio: 1;
  max-width: 560px;
  margin: 0 auto;
}
.tools-orbit-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.tools-orbit-bg .tools-ring {
  position: absolute;
  top: 50%; left: 50%;
  border-radius: 50%;
  border: 1px dashed color-mix(in srgb, var(--text) 14%, transparent);
  transform: translate(-50%, -50%);
  animation: orbit-spin 60s linear infinite;
}
.tools-orbit-bg .r1 { width: 38%; height: 38%; animation-duration: 40s; }
.tools-orbit-bg .r2 { width: 70%; height: 70%; animation-duration: 65s; animation-direction: reverse; opacity: 0.6; }
.tools-orbit-bg .r3 { width: 100%; height: 100%; border-style: solid; border-color: color-mix(in srgb, var(--text) 8%, transparent); animation-duration: 90s; opacity: 0.5; }
@keyframes orbit-spin { to { transform: translate(-50%, -50%) rotate(360deg); } }

.tools-center {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 96px; height: 96px;
  border-radius: 50%;
  background: var(--text);
  color: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 28px;
  letter-spacing: -0.02em;
  z-index: 5;
  box-shadow: 0 30px 60px -20px rgba(20,18,14,.4), 0 0 0 6px var(--bg);
}
.tools-center::before {
  content: "";
  position: absolute;
  inset: -10px;
  border-radius: 50%;
  border: 1px solid color-mix(in srgb, var(--accent) 40%, transparent);
  animation: pulse-ring 3.4s ease-out infinite;
}
.tools-center .dot {
  position: absolute;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--accent);
}
.tools-center .d1 { top: -3px; left: 50%; transform: translateX(-50%); }
.tools-center .d2 { right: -3px; top: 50%; transform: translateY(-50%); }
.tools-center .d3 { bottom: -3px; left: 50%; transform: translateX(-50%); }
@keyframes pulse-ring {
  0%   { transform: scale(0.96); opacity: .9; }
  100% { transform: scale(1.6);  opacity: 0;  }
}

/* Slot positions calculated from --x / --y unit vector */
.tool-slot {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(calc(-50% + var(--x) * 38cqi), calc(-50% + var(--y) * 38cqi));
  width: 96px;
  height: 96px;
  z-index: 4;
  container-type: inline-size;
}
.tool-card {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 24px;
  background: var(--bg-2);
  border: 1px solid var(--line);
  box-shadow: 0 12px 24px -16px rgba(20,18,14,0.18);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  transition: transform .35s cubic-bezier(.2,.7,.2,1), box-shadow .35s, border-color .35s;
}
.tool-card:hover {
  transform: translateY(-3px) scale(1.05);
  border-color: color-mix(in srgb, var(--accent) 50%, var(--line));
  box-shadow: 0 24px 50px -20px rgba(20,18,14,0.3);
}
.tool-face {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  opacity: 0;
  transform: scale(0.7) translateY(8px);
  transition: opacity .55s cubic-bezier(.2,.7,.2,1), transform .55s cubic-bezier(.2,.7,.2,1);
  pointer-events: none;
}
.tool-face.on {
  opacity: 1;
  transform: scale(1) translateY(0);
  pointer-events: auto;
}
.tool-face svg { display: block; }
.tool-name {
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-mute);
  margin-top: 0;
}
.tool-line { display: none; } /* not used currently */

/* Mobile: collapse the cluster to a grid */
@media (max-width: 980px) {
  .tools-cluster {
    aspect-ratio: auto;
    max-width: 480px;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
    padding: 20px 0;
  }
  .tools-orbit-bg, .tools-center { display: none; }
  .tool-slot {
    position: relative;
    top: auto; left: auto;
    transform: none;
    width: 100%;
    aspect-ratio: 1;
    height: auto;
  }
}
@media (max-width: 520px) {
  .tools-cluster { grid-template-columns: repeat(3, 1fr); max-width: 360px; }
}

/* ---------- TESTIMONIALS — Shinta-style featured ---------- */
.tests-shinta-wrap {
  position: relative;
  overflow: hidden;
}
.tests-shinta-wrap .ts-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}
.tests-shinta-wrap .ts-bg .ts-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.35;
}
.tests-shinta-wrap .ts-bg .b1 { width: 480px; height: 480px; background: var(--accent-2); top: 10%; left: -120px; }
.tests-shinta-wrap .ts-bg .b2 { width: 380px; height: 380px; background: var(--accent-4); bottom: -10%; right: -100px; opacity: 0.3; }
[data-theme="dark"] .tests-shinta-wrap .ts-bg .ts-blob { opacity: 0.18; }

.tests-shinta-wrap .ts-quote-mark {
  position: absolute;
  top: 8%;
  right: 8%;
  font-family: var(--font-display);
  font-size: clamp(220px, 28vw, 380px);
  line-height: 0.6;
  font-weight: 800;
  color: color-mix(in srgb, var(--accent) 12%, transparent);
  pointer-events: none;
  user-select: none;
}

.ts-head {
  text-align: center;
  margin-bottom: 56px;
  position: relative;
  z-index: 1;
}
.ts-head h2 {
  font-size: clamp(36px, 5vw, 64px);
}
.ts-head .eyebrow { justify-content: center; }

.ts-stage {
  position: relative;
  z-index: 1;
  max-width: 940px;
  margin: 0 auto;
  min-height: 380px;
}
.ts-card {
  position: absolute;
  inset: 0;
  padding: 56px clamp(28px, 4vw, 56px);
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 28px;
  box-shadow: 0 60px 120px -50px rgba(20,18,14,.18), 0 20px 40px -30px rgba(20,18,14,.08);
  display: flex;
  flex-direction: column;
  gap: 28px;
  opacity: 0;
  transform: translateY(20px) scale(0.985);
  pointer-events: none;
  transition: opacity .7s cubic-bezier(.2,.7,.2,1), transform .7s cubic-bezier(.2,.7,.2,1);
}
.ts-card.active {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
  z-index: 2;
}
.ts-stars {
  display: flex;
  align-items: center;
  gap: 16px;
}
.ts-stars .ts-star {
  color: var(--accent-4);
  font-size: 18px;
  letter-spacing: 4px;
}
.ts-stars .ts-meta-sep {
  flex: 1;
  height: 1px;
  background: var(--line);
}
.ts-stars .ts-meta-num {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-mute);
}
.ts-quote {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(22px, 2.6vw, 34px);
  line-height: 1.28;
  letter-spacing: -0.015em;
  color: var(--text);
  text-wrap: pretty;
  position: relative;
}
.ts-quote .ts-mark-open,
.ts-quote .ts-mark-close {
  font-size: 1.4em;
  color: var(--accent);
  line-height: 0;
  vertical-align: -0.15em;
  margin: 0 0.05em;
}
.ts-author {
  display: flex;
  align-items: center;
  gap: 16px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  margin-top: auto;
}
.ts-avatar {
  width: 56px; height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--accent-4));
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 18px;
  letter-spacing: -0.02em;
  flex-shrink: 0;
}
.ts-name {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--text);
}
.ts-role {
  font-size: 13px;
  color: var(--text-mute);
  margin-top: 2px;
}

.ts-controls {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  margin-top: 48px;
}
.ts-arrow {
  width: 48px; height: 48px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--bg-2);
  color: var(--text);
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background .2s, color .2s, border-color .2s, transform .2s;
}
.ts-arrow:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  transform: translateY(-2px);
}
.ts-dots {
  display: flex;
  gap: 8px;
}
.ts-dot {
  width: 28px;
  height: 4px;
  border-radius: 99px;
  background: var(--line);
  border: 0;
  cursor: pointer;
  transition: background .25s, width .25s;
  padding: 0;
}
.ts-dot:hover { background: var(--text-mute); }
.ts-dot.active { background: var(--accent); width: 48px; }

@media (max-width: 700px) {
  .ts-stage { min-height: 460px; }
  .ts-card { padding: 36px 24px; gap: 22px; border-radius: 22px; }
  .ts-quote { font-size: 20px; line-height: 1.35; }
  .ts-author { gap: 12px; }
  .ts-avatar { width: 48px; height: 48px; font-size: 15px; }
  .tests-shinta-wrap .ts-quote-mark { font-size: 180px; right: -2%; top: 4%; }
}

/* ---------- PROJECT PAGE — improvements ---------- */

/* Tighten the back-button → eyebrow spacing on case study pages */
.proj-hero .proj-back { margin-bottom: 28px; margin-right: 24px; }
.proj-hero .proj-eyebrow { margin-bottom: 24px; }

/* The hero canvas section sits in its own .wrap, but the title +
   meta row live inside .proj-hero which strips .wrap's horizontal
   padding (because `.proj-hero { padding: 80px 0 56px }` overrides
   the shorthand). To line the canvas up with the title text, drop
   the wrap gutter on this one canvas section too. */
section.wrap.proj-canvas-section {
  padding-left: 0;
  padding-right: 0;
}

/* Mobile gutter alignment: use the global wrap gutter (20px) like the home page */
@media (max-width: 700px) {
  .proj-hero { padding: 56px 0 36px; }
  .proj-back { margin-bottom: 24px; padding: 9px 16px; font-size: 11px; }
  .proj-eyebrow { font-size: 11px; margin-bottom: 18px; }
  .proj-title { font-size: clamp(40px, 12vw, 60px) !important; margin-bottom: 24px; }
  .proj-summary { font-size: 16px; margin-bottom: 36px; }
  .proj-canvas-hero { margin: 24px 0 36px; border-radius: 18px; }
  .proj-meta { gap: 22px 16px; padding-top: 24px; }
  .meta-cell .v { font-size: 14px; }
  .proj-body { padding-top: 48px !important; padding-bottom: 48px !important; }
  .proj-body-grid { gap: 24px; }
  .proj-content p { font-size: 18px !important; }
  .proj-aside h2 { font-size: 26px; }
  .proj-aside p { font-size: 15px; }
}

/* Kurawa-inspired project gallery */
.proj-gallery-kurawa {
  display: grid;
  gap: 16px;
  margin-top: 48px;
}
.pgk-row {
  display: grid;
  gap: 16px;
}
.pgk-row.cols-1 { grid-template-columns: 1fr; }
.pgk-row.cols-2 { grid-template-columns: 1fr 1fr; }
.pgk-row.cols-2-uneven { grid-template-columns: 1.4fr 1fr; }
.pgk-row.cols-2-uneven-r { grid-template-columns: 1fr 1.4fr; }
.pgk-row.cols-3 { grid-template-columns: 1fr 1fr 1fr; }

.pgk-block {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  background: var(--card-bg, var(--surface));
  aspect-ratio: 4/3;
  display: flex;
  align-items: center;
  justify-content: center;
}
.pgk-block.tall { aspect-ratio: 4/5; }
.pgk-block.wide { aspect-ratio: 16/9; }
.pgk-block.ultra-wide { aspect-ratio: 21/9; }
.pgk-block.square { aspect-ratio: 1; }

.pgk-block .canvas-empty {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: var(--card-fg, #fff);
  opacity: 0.85;
  padding: 24px;
  text-align: center;
}
.pgk-block .canvas-empty::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: repeating-linear-gradient(
    45deg,
    transparent 0 22px,
    color-mix(in srgb, var(--card-fg, #1a1a1a) 4%, transparent) 22px 23px
  );
  pointer-events: none;
}
.pgk-block .canvas-cross {
  font-size: 56px;
  font-weight: 200;
  line-height: 1;
  opacity: 0.5;
}
.pgk-block .canvas-hint {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  opacity: 0.65;
}
.pgk-caption {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 4px 6px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-mute);
  margin-top: -6px;
}

@media (max-width: 700px) {
  .pgk-row.cols-2,
  .pgk-row.cols-2-uneven,
  .pgk-row.cols-2-uneven-r,
  .pgk-row.cols-3 { grid-template-columns: 1fr; }
  .pgk-block { border-radius: 16px; aspect-ratio: 4/3; }
  .pgk-block.tall { aspect-ratio: 4/5; }
}

/* ---------- SCROLL REVEAL — smoother, more orchestrated ---------- */
@keyframes reveal-up-soft {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes reveal-left-soft {
  from { opacity: 0; transform: translate(-32px, 18px); }
  to   { opacity: 1; transform: translate(0, 0); }
}
@keyframes reveal-right-soft {
  from { opacity: 0; transform: translate(32px, 18px); }
  to   { opacity: 1; transform: translate(0, 0); }
}

/* By default content is visible. Animation plays once when .in is added.
   No [data-anim] gating, no aggressive opacity:0 — content never gets stuck
   invisible even if the JS check is late. */
.reveal, .reveal-stagger { opacity: 1; }
[data-anim] .reveal:not(.in),
[data-anim] .reveal-stagger:not(.in) {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity .6s ease, transform .6s ease;
}
[data-anim] .reveal-stagger.from-left:not(.in)  { transform: translate(-32px, 18px); }
[data-anim] .reveal-stagger.from-right:not(.in) { transform: translate(32px, 18px); }

[data-anim] .reveal.in {
  animation: reveal-up-soft .85s cubic-bezier(.2, .7, .2, 1) both;
  animation-delay: calc(var(--d, 0) * 1ms);
}
[data-anim] .reveal-stagger.from-left.in {
  animation: reveal-left-soft 1s cubic-bezier(.2, .7, .2, 1) both;
}
[data-anim] .reveal-stagger.from-right.in {
  animation: reveal-right-soft 1s cubic-bezier(.2, .7, .2, 1) both;
}

/* Use data-d as the delay if present */
.reveal[data-d="100"] { --d: 100; }
.reveal[data-d="200"] { --d: 200; }
.reveal[data-d="300"] { --d: 300; }
.reveal[data-d="400"] { --d: 400; }
.reveal[data-d="500"] { --d: 500; }

/* Safety net: 1.8s after page load, force-show everything still hidden.
   This protects against JS hiccups or off-screen items the IntersectionObserver
   somehow missed. */
@keyframes reveal-safety-show {
  to { opacity: 1; transform: translate(0, 0); }
}
[data-anim] .reveal:not(.in),
[data-anim] .reveal-stagger:not(.in) {
  animation: reveal-safety-show 1s ease 2.4s forwards;
}

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001s !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001s !important;
  }
  .tools-orbit-bg .tools-ring { animation: none !important; }
  .tools-center::before { animation: none !important; }
}


/* =========================================================
   INTEGRATION SECTION (Sanjaya-inspired dark band)
   ========================================================= */
.tools-integration {
  position: relative;
  background: #0a0a0a;
  color: #f3ede2;
  overflow: hidden;
  padding: clamp(80px, 12vw, 160px) 0 clamp(80px, 10vw, 140px) !important;
  border-radius: 0;
  isolation: isolate;
}
.tools-integration::before {
  /* Subtle vignette to give the rows a fade into the section */
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 60% 50% at 50% 30%,
    rgba(232, 98, 74, 0.06) 0%,
    transparent 70%);
  pointer-events: none;
  z-index: 0;
}

.tools-integration .ti-rows {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin: 0 auto clamp(56px, 7vw, 96px);
  width: 100%;
  max-width: 1400px;
  padding: 0 12px;
  /* Edge fade so tiles bleed off-screen */
  -webkit-mask-image: linear-gradient(to right,
    transparent 0%,
    #000 18%,
    #000 82%,
    transparent 100%);
          mask-image: linear-gradient(to right,
    transparent 0%,
    #000 18%,
    #000 82%,
    transparent 100%);
}

.tools-integration .ti-row {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 14px;
}
.tools-integration .ti-row-2 {
  transform: translateX(8%);
}

.tools-integration .ti-tile {
  aspect-ratio: 1 / 1;
  background: #18181a;
  border: 1px solid #ffffff0a;
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #6e6e72;
  /* Initial state — hidden, slightly above and scaled down.
     Stagger reveal kicks in when `.ti-rows` receives `.in`. */
  opacity: 0;
  transform: translateY(-22px) scale(0.96);
  transition:
    opacity 0.55s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.55s cubic-bezier(0.22, 1, 0.36, 1),
    background 0.35s ease,
    color 0.35s ease,
    box-shadow 0.35s ease;
  position: relative;
  overflow: hidden;
}

/* Final state — driven by IntersectionObserver in tools.jsx */
.tools-integration .ti-rows.in .ti-tile {
  opacity: 1;
  transform: none;
}

/* Stagger delays — row 1 */
.tools-integration .ti-rows.in .ti-row:nth-child(1) .ti-tile:nth-child(1) { transition-delay:   0ms; }
.tools-integration .ti-rows.in .ti-row:nth-child(1) .ti-tile:nth-child(2) { transition-delay:  70ms; }
.tools-integration .ti-rows.in .ti-row:nth-child(1) .ti-tile:nth-child(3) { transition-delay: 140ms; }
.tools-integration .ti-rows.in .ti-row:nth-child(1) .ti-tile:nth-child(4) { transition-delay: 210ms; }
.tools-integration .ti-rows.in .ti-row:nth-child(1) .ti-tile:nth-child(5) { transition-delay: 280ms; }
.tools-integration .ti-rows.in .ti-row:nth-child(1) .ti-tile:nth-child(6) { transition-delay: 350ms; }

/* Stagger delays — row 2 (offset to feel like a cascade) */
.tools-integration .ti-rows.in .ti-row:nth-child(2) .ti-tile:nth-child(1) { transition-delay:  80ms; }
.tools-integration .ti-rows.in .ti-row:nth-child(2) .ti-tile:nth-child(2) { transition-delay: 150ms; }
.tools-integration .ti-rows.in .ti-row:nth-child(2) .ti-tile:nth-child(3) { transition-delay: 220ms; }
.tools-integration .ti-rows.in .ti-row:nth-child(2) .ti-tile:nth-child(4) { transition-delay: 290ms; }
.tools-integration .ti-rows.in .ti-row:nth-child(2) .ti-tile:nth-child(5) { transition-delay: 360ms; }
.tools-integration .ti-rows.in .ti-row:nth-child(2) .ti-tile:nth-child(6) { transition-delay: 430ms; }

/* Reduced motion — skip the entry animation entirely */
@media (prefers-reduced-motion: reduce) {
  .tools-integration .ti-tile {
    opacity: 1;
    transform: none;
    transition: background 0.35s ease, color 0.35s ease, box-shadow 0.35s ease;
  }
}
.tools-integration .ti-tile::after {
  /* soft inner highlight */
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, #ffffff08 0%, transparent 40%);
  pointer-events: none;
}
.tools-integration .ti-tile svg {
  width: 38%;
  height: 38%;
  opacity: 0.55;
  transition: opacity .35s ease, transform .35s ease;
}
.tools-integration .ti-tile:hover {
  background: #232325;
  color: var(--accent);
  transform: translateY(-2px);
  box-shadow: 0 0 0 1.5px var(--accent);
}
.tools-integration .ti-tile:hover svg {
  opacity: 1;
  transform: scale(1.06);
}

.tools-integration .ti-content {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 880px;
  margin: 0 auto;
}
.tools-integration .ti-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 18px;
  border-radius: 6px;
  background: #1a1a1a;
  color: #f3ede2;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.22em;
  font-weight: 500;
  /* Checkered border like the reference */
  position: relative;
  margin-bottom: 32px;
}
.tools-integration .ti-pill::before {
  content: "";
  position: absolute;
  inset: -3px;
  border-radius: 8px;
  background-image:
    linear-gradient(45deg, var(--accent) 25%, transparent 25%),
    linear-gradient(-45deg, var(--accent) 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, var(--accent) 75%),
    linear-gradient(-45deg, transparent 75%, var(--accent) 75%);
  background-size: 6px 6px;
  background-position: 0 0, 0 3px, 3px -3px, -3px 0;
  z-index: -1;
  opacity: 0.55;
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
          mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  padding: 3px;
}

.tools-integration .ti-title {
  font-family: var(--font-display);
  font-size: clamp(38px, 5.8vw, 80px);
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.04;
  color: #f3ede2;
  margin: 0;
}
.tools-integration .ti-sub {
  margin: 24px auto 0;
  max-width: 56ch;
  font-size: clamp(15px, 1.3vw, 18px);
  line-height: 1.55;
  color: #9b9a96;
  text-wrap: pretty;
}

@media (max-width: 720px) {
  .tools-integration .ti-row { grid-template-columns: repeat(6, minmax(64px, 1fr)); gap: 10px; }
  .tools-integration .ti-rows { gap: 10px; padding: 0 8px; }
  .tools-integration .ti-tile { border-radius: 14px; }
  .tools-integration .ti-pill { font-size: 10px; letter-spacing: 0.18em; padding: 6px 14px; }
}
@media (max-width: 480px) {
  .tools-integration .ti-row { grid-template-columns: repeat(6, 60px); justify-content: center; }
  .tools-integration .ti-rows {
    overflow-x: visible;
    -webkit-mask-image: linear-gradient(to right, transparent 0%, #000 10%, #000 90%, transparent 100%);
            mask-image: linear-gradient(to right, transparent 0%, #000 10%, #000 90%, transparent 100%);
  }
}

/* =========================================================
   TESTIMONIALS — Shinta-style 5-card grid (blank photos)
   ========================================================= */
.tsh-section {
  background: var(--surface);
  border-radius: 0;
  padding: clamp(80px, 10vw, 140px) var(--gutter) !important;
}
.tsh-head {
  text-align: center;
  margin-bottom: 56px;
}
.tsh-eyebrow {
  display: inline-block;
  background: #f6c9eb;
  color: #2a1430;
  padding: 6px 16px;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-weight: 600;
  margin-bottom: 24px;
}
.tsh-title {
  font-family: var(--font-display);
  font-size: clamp(38px, 6vw, 84px);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.02;
  color: var(--text);
  max-width: 14ch;
  margin: 0 auto;
}

.tsh-grid {
  display: flex;
  flex-direction: column;
  gap: 18px;
  max-width: 1240px;
  margin: 0 auto;
}
.tsh-row {
  display: grid;
  gap: 18px;
}
.tsh-row-top { grid-template-columns: 1.8fr 1fr; }
.tsh-row-bot { grid-template-columns: 1fr 1fr 1fr; }

.tsh-card {
  background: var(--bg-2);
  border-radius: 22px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  min-height: 280px;
  box-shadow: 0 1px 0 var(--line), 0 30px 60px -40px rgba(20,18,14,0.10);
  position: relative;
  transition: transform .35s cubic-bezier(.2,.7,.2,1), box-shadow .35s ease;
}
.tsh-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 1px 0 var(--line), 0 40px 80px -40px rgba(20,18,14,0.18);
}

.tsh-card-lg {
  flex-direction: row;
  align-items: stretch;
  padding: 0;
  overflow: hidden;
}
.tsh-card-lg .tsh-card-body {
  padding: 28px;
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
  justify-content: space-between;
}

.tsh-photo {
  position: relative;
  flex: 0 0 42%;
  background: var(--surface);
  display: flex;
  align-items: center;
  justify-content: center;
  background-image: repeating-linear-gradient(
    45deg,
    transparent 0 22px,
    color-mix(in srgb, var(--text) 4%, transparent) 22px 23px
  );
  border-right: 1px solid var(--line);
}
.tsh-photo-play {
  width: 56px; height: 56px;
  border-radius: 50%;
  background: var(--bg-2);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text);
  font-size: 14px;
  box-shadow: 0 8px 24px -8px rgba(0,0,0,0.18);
}

.tsh-stars {
  display: inline-flex;
  gap: 2px;
  background: #fff5e6;
  padding: 5px 8px;
  border-radius: 6px;
  width: max-content;
}
.tsh-star { color: #f4b65c; font-size: 13px; letter-spacing: 1px; }

.tsh-card .tsh-quote {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 19px;
  letter-spacing: -0.015em;
  line-height: 1.25;
  color: var(--text);
  margin: 0;
  text-wrap: balance;
}
.tsh-card-lg .tsh-quote { font-size: 22px; }
.tsh-card .tsh-body {
  font-size: 14px;
  line-height: 1.55;
  color: var(--text-2);
  margin: 0;
}
.tsh-card-lg .tsh-body { font-size: 15px; }

.tsh-author {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: auto;
  padding-top: 4px;
}
.tsh-avatar {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--surface);
  border: 1px solid var(--line);
  flex-shrink: 0;
  background-image: repeating-linear-gradient(
    45deg,
    transparent 0 6px,
    color-mix(in srgb, var(--text) 6%, transparent) 6px 7px
  );
}
.tsh-card-lg .tsh-author { padding-top: 0; }
.tsh-name {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.2;
}
.tsh-role {
  font-size: 12px;
  color: var(--text-mute);
  margin-top: 2px;
}

@media (max-width: 980px) {
  .tsh-row-top { grid-template-columns: 1fr; }
  .tsh-row-bot { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 700px) {
  .tsh-row-bot { grid-template-columns: 1fr; }
  .tsh-card-lg { flex-direction: column; }
  .tsh-photo { flex: 0 0 220px; min-height: 220px; border-right: 0; border-bottom: 1px solid var(--line); }
  .tsh-card { padding: 24px; min-height: 220px; }
  .tsh-card-lg .tsh-card-body { padding: 24px; }
}

/* =========================================================
   CONTACT — fix budget select (white-on-white)
   ========================================================= */
.contact-form select {
  background: #2a2926 !important;
  color: #f3ede2 !important;
  border: 1px solid color-mix(in srgb, var(--bg) 22%, transparent) !important;
  appearance: none;
  -webkit-appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, #f4b65c 50%),
    linear-gradient(135deg, #f4b65c 50%, transparent 50%) !important;
  background-position:
    calc(100% - 18px) 50%,
    calc(100% - 13px) 50% !important;
  background-size:
    5px 5px,
    5px 5px !important;
  background-repeat: no-repeat !important;
  padding-right: 36px !important;
}
.contact-form select option {
  background: #1a1a1a;
  color: #f3ede2;
}
.contact-form select:focus {
  background-color: #34322e !important;
  border-color: var(--accent-4) !important;
}


/* =========================================================
   MOBILE LATERAL MARGINS — subpages + global polish
   ========================================================= */
@media (max-width: 900px) {
  :root { --gutter: 24px; }
  .proj-hero,
  .proj-body,
  .proj-gallery,
  .proj-main > section.wrap {
    padding-left: 24px;
    padding-right: 24px;
  }
  .proj-canvas-hero { margin-left: 0; margin-right: 0; }
  .proj-gallery-kurawa { gap: 14px; }
  .pgk-row { gap: 14px; }
}

@media (max-width: 600px) {
  :root { --gutter: 22px; }
  .proj-hero,
  .proj-body,
  .proj-gallery,
  .proj-main > section.wrap {
    padding-left: 22px;
    padding-right: 22px;
  }
  .proj-meta { gap: 18px 14px; }
  .proj-content p { font-size: 17px !important; line-height: 1.5; }
}

/* Integration tile sizing on smaller screens — keep them visible but smaller */
@media (max-width: 600px) {
  .tools-integration .ti-row { gap: 8px; }
  .tools-integration .ti-rows { gap: 8px; }
  .tools-integration .ti-tile { border-radius: 12px; }
  .tools-integration .ti-pill { padding: 6px 12px; }
}

/* Testimonials mobile gutter fix */
@media (max-width: 700px) {
  .tsh-section { padding-left: 22px !important; padding-right: 22px !important; }
}
