/* =============================================================
   Afrobora — brand layer (loaded after site.css / visuals.css)
   Night surfaces lit by the logo's blue and orange; floating
   glass header; photo cards that flip, slide and expand.
   Contrast notes are against --night (#050a18).
   All motion stops under prefers-reduced-motion and pauses
   off-screen (site.js toggles .is-offscreen).
   ============================================================= */

:root {
  --night: #050a18;
  --night-2: #08122a;
  --on-night: #e8ecf5;       /* 16.5:1 */
  --on-night-muted: #a3adc2; /*  8.6:1 */
  --on-night-dim: #7f8aa0;   /*  5.6:1 */
  --glass: rgba(255, 255, 255, .045);
  --glass-line: rgba(255, 255, 255, .1);
  --blue: #2563eb;
  --blue-light: #8fb4ff;     /* 9.5:1 */
  --orange: #f97316;
  --orange-light: #fdba74;   /* 11.6:1 */
  --ease-out: cubic-bezier(.2, .75, .2, 1);
}

body.is-home { background: var(--night); }

/* ---------- Shared bits ---------- */
.dim { color: var(--on-night-dim); }
.pill, .page-intro .eyebrow {
  display: inline-flex; align-items: center; gap: 8px; margin: 0;
  font: 500 12px/1 var(--mono); letter-spacing: .06em; text-transform: uppercase;
  color: #d3dbea; padding: 8px 13px; border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, .13); background: rgba(255, 255, 255, .04);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06);
}
.chip {
  align-self: flex-start; display: inline-flex; align-items: center;
  font: 500 11.5px/1 var(--mono); letter-spacing: .05em; text-transform: uppercase;
  color: #e3e9f5; padding: 7px 10px; border-radius: 999px;
  background: rgba(5, 10, 24, .55); border: 1px solid rgba(255, 255, 255, .16);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.arrow-link { color: var(--orange-light); font-weight: 600; text-decoration: none; display: inline-flex; align-items: center; gap: 6px; }
.arrow-link::after { content: "→"; transition: transform .2s; }
.arrow-link:hover::after { transform: translateX(4px); }
.arrow-link:hover { text-decoration: underline; }

/* Buttons */
.btn-glow {
  position: relative; color: #1a0c02; /* 8.9:1 on the orange */
  background: linear-gradient(180deg, #fb923c, #f97316);
  border-color: rgba(255, 255, 255, .28);
  box-shadow: 0 0 0 1px rgba(249, 115, 22, .35), 0 10px 32px -8px rgba(249, 115, 22, .6), inset 0 1px 0 rgba(255, 255, 255, .45);
  transition: transform .2s var(--ease-out), box-shadow .2s, background .2s;
}
.btn-glow:hover { transform: translateY(-2px); background: linear-gradient(180deg, #fdba74, #fb923c); box-shadow: 0 0 0 1px rgba(249, 115, 22, .5), 0 16px 40px -8px rgba(249, 115, 22, .75), inset 0 1px 0 rgba(255, 255, 255, .5); }
.btn-glass {
  color: #fff; background: rgba(255, 255, 255, .06); border-color: rgba(255, 255, 255, .18);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); transition: background .2s, border-color .2s, transform .2s var(--ease-out);
}
.btn-glass:hover { background: rgba(255, 255, 255, .12); border-color: rgba(255, 255, 255, .35); transform: translateY(-2px); }
.btn-sm { min-height: 40px; padding: 8px 16px; font-size: 14px; }
.has-arrow::after { content: "→"; display: inline-block; transition: transform .2s var(--ease-out); }
.has-arrow:hover::after { transform: translateX(4px); }
.dark :focus-visible, .hero-x :focus-visible, .page-intro :focus-visible, .site-header :focus-visible,
.site-footer :focus-visible, .cta-band :focus-visible { outline-color: var(--orange-light); }

/* ---------- Header: floating glass bar ---------- */
.site-header { position: fixed; top: 0; left: 0; right: 0; z-index: 60; padding: 14px var(--gutter); pointer-events: none; }
.header-shell {
  pointer-events: auto; position: relative; max-width: var(--max); margin: 0 auto;
  display: flex; align-items: center; gap: var(--s4); min-height: 60px; padding: 8px 8px 8px 20px;
  border-radius: 999px; background: rgba(8, 13, 28, .58);
  border: 1px solid rgba(255, 255, 255, .09);
  box-shadow: 0 14px 40px -16px rgba(0, 0, 0, .7), inset 0 1px 0 rgba(255, 255, 255, .06);
  transition: background .3s, max-width .4s var(--ease-out), box-shadow .3s;
}
.is-scrolled .header-shell { background: rgba(6, 10, 22, .86); max-width: 1120px; box-shadow: 0 18px 50px -14px rgba(0, 0, 0, .8), inset 0 1px 0 rgba(255, 255, 255, .06); }
.brand { flex: none; display: block; }
.brand img { width: 128px; height: auto; }
.site-nav { display: flex; align-items: center; gap: var(--s4); flex: 1; }
.nav-pill {
  position: relative; margin: 0 auto; padding: 4px; border-radius: 999px;
  background: rgba(255, 255, 255, .035); border: 1px solid rgba(255, 255, 255, .07);
}
.nav-pill ul { position: relative; z-index: 1; display: flex; gap: 2px; list-style: none; margin: 0; padding: 0; }
.nav-pill a {
  position: relative; display: block; padding: 8px 14px; border-radius: 999px;
  font: 500 14px/1.2 var(--font); color: #b9c2d4; text-decoration: none; transition: color .2s;
}
.nav-pill a:hover { color: #fff; }
.nav-pill a[aria-current="page"] { color: #fff; background: rgba(255, 255, 255, .08); }
.nav-pill a[aria-current="page"]::after {
  content: ""; position: absolute; left: 50%; bottom: 2px; width: 4px; height: 4px; margin-left: -2px;
  border-radius: 50%; background: var(--orange); box-shadow: 0 0 8px var(--orange);
}
.nav-glider {
  position: absolute; top: 4px; bottom: 4px; left: 0; width: var(--gw, 0); border-radius: 999px;
  transform: translateX(var(--gx, 0)); opacity: var(--go, 0);
  background: linear-gradient(180deg, rgba(143, 180, 255, .2), rgba(37, 99, 235, .14));
  box-shadow: inset 0 0 0 1px rgba(143, 180, 255, .25);
  transition: transform .35s var(--ease-out), width .35s var(--ease-out), opacity .25s;
}
.nav-cta { flex: none; min-height: 44px; padding: 10px 18px; font-size: 14.5px; }
.nav-toggle, .nav-contact { display: none; }

@media (min-width: 1024px) {
  .header-shell { -webkit-backdrop-filter: blur(16px) saturate(140%); backdrop-filter: blur(16px) saturate(140%); }
}
@media (max-width: 1180px) and (min-width: 1024px) {
  .nav-pill a { padding: 8px 11px; }
}
@media (max-width: 1023px) {
  .site-header { padding: 10px var(--gutter); }
  .header-shell { min-height: 56px; padding: 6px 6px 6px 16px; background: rgba(6, 10, 22, .92); }
  .brand { position: relative; z-index: 2; }
  .brand img { width: 112px; }
  .nav-toggle {
    position: relative; z-index: 2; display: inline-flex; align-items: center; gap: 10px; margin-left: auto;
    min-height: 44px; padding: 8px 16px; border-radius: 999px; cursor: pointer;
    background: rgba(255, 255, 255, .08); color: #fff; border: 1px solid rgba(255, 255, 255, .16); font: 600 14px var(--font);
  }
  .nav-toggle-bars, .nav-toggle-bars::before, .nav-toggle-bars::after {
    display: block; width: 18px; height: 2px; background: currentColor; position: relative; border-radius: 2px; transition: transform .3s, background .3s;
  }
  .nav-toggle-bars::before, .nav-toggle-bars::after { content: ""; position: absolute; left: 0; }
  .nav-toggle-bars::before { top: -6px; }
  .nav-toggle-bars::after { top: 6px; }
  .nav-toggle[aria-expanded="true"] .nav-toggle-bars { background: transparent; }
  .nav-toggle[aria-expanded="true"] .nav-toggle-bars::before { top: 0; transform: rotate(45deg); }
  .nav-toggle[aria-expanded="true"] .nav-toggle-bars::after { top: 0; transform: rotate(-45deg); }

  .site-nav {
    position: fixed; inset: 0; z-index: 1; flex-direction: column; align-items: stretch; gap: var(--s6);
    padding: 104px calc(var(--gutter) + 8px) 32px; overflow-y: auto;
    background:
      radial-gradient(70% 45% at 100% 0%, rgba(249, 115, 22, .2), transparent 70%),
      radial-gradient(80% 50% at 0% 100%, rgba(37, 99, 235, .3), transparent 70%),
      var(--night);
  }
  .js .site-nav { opacity: 0; visibility: hidden; transition: opacity .3s, visibility 0s linear .3s; }
  .js .site-nav.is-open { opacity: 1; visibility: visible; transition: opacity .3s; }
  .nav-pill { margin: 0; padding: 0; background: none; border: 0; }
  .nav-pill ul { flex-direction: column; gap: 0; }
  .nav-pill a {
    padding: 14px 0; border-radius: 0; border-bottom: 1px solid rgba(255, 255, 255, .08);
    font: 600 30px/1.15 var(--display); letter-spacing: -0.03em; color: #fff;
  }
  .nav-pill a[aria-current="page"] { background: none; color: var(--orange-light); }
  .nav-pill a[aria-current="page"]::after { display: none; }
  .js .site-nav.is-open .nav-pill li { animation: menu-in .55s var(--ease-out) both; }
  .js .site-nav.is-open .nav-pill li:nth-child(2) { animation-delay: .04s; }
  .js .site-nav.is-open .nav-pill li:nth-child(3) { animation-delay: .08s; }
  .js .site-nav.is-open .nav-pill li:nth-child(4) { animation-delay: .12s; }
  .js .site-nav.is-open .nav-pill li:nth-child(5) { animation-delay: .16s; }
  .js .site-nav.is-open .nav-pill li:nth-child(6) { animation-delay: .2s; }
  .js .site-nav.is-open .nav-pill li:nth-child(7) { animation-delay: .24s; }
  .nav-glider { display: none; }
  .nav-cta { align-self: flex-start; min-height: 52px; padding: 12px 24px; font-size: 16px; }
  .nav-contact { display: flex; flex-direction: column; gap: 4px; margin-top: auto; color: var(--on-night-muted); font-size: 15px; }
  .nav-contact a { color: #fff; font-weight: 600; font-size: 18px; text-decoration: none; }
  .nav-open, .nav-open body { overflow: hidden; }

  .no-js .header-shell { flex-wrap: wrap; border-radius: 24px; }
  .no-js .nav-toggle { display: none; }
  .no-js .site-nav { position: static; padding: 8px 0 16px; background: none; flex-basis: 100%; }
}
@keyframes menu-in { from { opacity: 0; transform: translateY(16px); } }

/* ---------- Aurora backdrop (hero + page intros) ---------- */
.aurora { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.aurora i { position: absolute; border-radius: 50%; animation: aurora 22s ease-in-out infinite alternate; }
.aurora i:nth-child(1) { width: 70vw; height: 60vw; left: -18vw; top: -32vw; background: radial-gradient(closest-side, rgba(37, 99, 235, .55), transparent); }
.aurora i:nth-child(2) { width: 46vw; height: 40vw; right: -14vw; top: -6vw; background: radial-gradient(closest-side, rgba(249, 115, 22, .32), transparent); animation-duration: 26s; animation-direction: alternate-reverse; }
.aurora i:nth-child(3) { width: 60vw; height: 36vw; left: 20vw; bottom: -24vw; background: radial-gradient(closest-side, rgba(14, 116, 233, .3), transparent); animation-duration: 30s; }
@keyframes aurora { 50% { transform: translate(6vw, 3vw) scale(1.08); } 100% { transform: translate(-4vw, 5vw) scale(.94); } }

/* ---------- Hero ---------- */
.hero-x { position: relative; overflow: hidden; background: var(--night); color: var(--on-night-muted); padding: 176px 0 var(--s6); isolation: isolate; }
.hero-lines {
  position: absolute; inset: 0; pointer-events: none; z-index: -1;
  background-image: linear-gradient(rgba(255, 255, 255, .055) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, .055) 1px, transparent 1px);
  background-size: 72px 72px; background-position: center top;
  -webkit-mask-image: radial-gradient(ellipse 55% 45% at 50% 32%, #000 20%, transparent 75%);
  mask-image: radial-gradient(ellipse 55% 45% at 50% 32%, #000 20%, transparent 75%);
}
.hero-spot {
  position: absolute; inset: 0; pointer-events: none; z-index: -1;
  background: radial-gradient(520px circle at var(--mx, 50%) var(--my, 30%), rgba(143, 180, 255, .14), transparent 60%);
  transition: background .2s;
}
.hero-x .aurora { z-index: -2; }
.hero-center { position: relative; display: flex; flex-direction: column; align-items: center; text-align: center; }
.hero-x .hero-title {
  margin-top: var(--s5); max-width: 16ch; color: #fff;
  font-size: clamp(40px, 7.4vw, 96px); line-height: 1.02; letter-spacing: -0.035em;
  animation: rise 1s var(--ease-out) both .1s;
}
.hero-x .lead { margin: var(--s5) auto 0; max-width: 58ch; color: #bcc5d6; animation: rise 1s var(--ease-out) both .25s; }
.hero-x .actions { justify-content: center; animation: rise 1s var(--ease-out) both .4s; }
.hero-x .pill { animation: rise 1s var(--ease-out) both; }
@keyframes rise { from { opacity: 0; transform: translateY(22px); filter: blur(6px); } }

/* Rotating word */
.rotator { display: inline-grid; vertical-align: bottom; }
.rotator-words { display: inline-grid; justify-items: center; }
.rotator-words span {
  grid-area: 1 / 1; padding: 0 .04em .1em;
  background: linear-gradient(95deg, var(--blue-light), #60a5fa 35%, var(--orange) 75%, var(--orange-light));
  -webkit-background-clip: text; background-clip: text; color: transparent;
  opacity: 0; animation: rot 12.5s var(--ease-out) infinite;
}
.rotator-words span:nth-child(2) { animation-delay: 2.5s; }
.rotator-words span:nth-child(3) { animation-delay: 5s; }
.rotator-words span:nth-child(4) { animation-delay: 7.5s; }
.rotator-words span:nth-child(5) { animation-delay: 10s; }
.hero-l2 { display: block; }
.rotator-words.is-js { grid-template-columns: 100%; transition: width .7s var(--ease-out); }
.rotator-words span { white-space: nowrap; justify-self: center; }
.rotator-words span[data-word]::before { content: attr(data-word); }
.rotator-words.is-js span { animation: none; transform: translateY(.45em) rotateX(-60deg); filter: blur(8px); transition: opacity .5s, transform .8s var(--ease-out), filter .6s; }
.rotator-words.is-js span.is-on { opacity: 1; transform: none; filter: none; }
.rotator-words.is-js span.is-off { transform: translateY(-.45em) rotateX(60deg); }
@keyframes rot {
  0% { opacity: 0; transform: translateY(.45em) rotateX(-60deg); filter: blur(8px); }
  4%, 17% { opacity: 1; transform: none; filter: none; }
  21%, 100% { opacity: 0; transform: translateY(-.45em) rotateX(60deg); filter: blur(8px); }
}

/* Photo ribbon */
.ribbon {
  position: relative; margin-top: 72px; padding: 24px 0;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
  animation: rise 1.2s var(--ease-out) both .55s;
}
.ribbon-track { display: flex; width: max-content; animation: ribbon 70s linear infinite; }
.ribbon:hover .ribbon-track { animation-play-state: paused; }
.ribbon-tile {
  position: relative; flex: none; margin: 0 20px 0 0; width: 290px; aspect-ratio: 4 / 3;
  border-radius: 22px; overflow: hidden; border: 1px solid rgba(255, 255, 255, .12);
  box-shadow: 0 30px 60px -30px rgba(0, 0, 0, .9);
  transform: translateY(14px) rotate(-2.5deg); transition: transform .5s var(--ease-out), box-shadow .5s;
}
.ribbon-tile:nth-child(even) { transform: translateY(-14px) rotate(2.5deg); }
.ribbon-tile:hover { transform: translateY(-4px) rotate(0) scale(1.05); box-shadow: 0 30px 70px -20px rgba(37, 99, 235, .6); z-index: 1; }
.ribbon-tile img { width: 100%; height: 100%; object-fit: cover; }
.ribbon-tile::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(5, 10, 24, .7), transparent 50%); }
.ribbon-tile figcaption {
  position: absolute; left: 12px; bottom: 12px; z-index: 1;
  font: 500 11px/1 var(--mono); letter-spacing: .05em; text-transform: uppercase; color: #fff;
  padding: 7px 10px; border-radius: 999px; background: rgba(5, 10, 24, .55); border: 1px solid rgba(255, 255, 255, .18);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
@keyframes ribbon { to { transform: translateX(-50%); } }

/* Service index under the hero */
.hero-x .hero-index { margin-top: var(--s7); border-top: 1px solid rgba(255, 255, 255, .1); }
.hero-x .hero-index h2 { font: 500 12px/1 var(--mono); letter-spacing: .06em; color: var(--on-night-dim); padding: var(--s5) 0 var(--s3); }
.hero-x .hero-index ol { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s3); }
.hero-x .hero-index li { border: 0; }
.hero-x .hero-index a {
  display: grid; grid-template-columns: 32px 1fr auto; align-items: center; gap: var(--s2);
  padding: 16px 18px; border-radius: 16px; color: #fff; text-decoration: none; font-weight: 500;
  background: var(--glass); border: 1px solid var(--glass-line); transition: background .25s, border-color .25s, transform .25s var(--ease-out);
}
.hero-x .hero-index a span:first-child { font: 500 12px var(--mono); color: var(--orange-light); }
.hero-x .hero-index a span:last-child { color: var(--on-night-dim); transition: transform .25s var(--ease-out), color .25s; }
.hero-x .hero-index a:hover { background: rgba(255, 255, 255, .08); border-color: rgba(143, 180, 255, .35); transform: translateY(-2px); }
.hero-x .hero-index a:hover span:nth-child(2) { text-decoration: none; }
.hero-x .hero-index a:hover span:last-child { color: var(--orange-light); transform: translate(2px, -2px); }
@media (max-width: 960px) {
  .hero-x { padding-top: 140px; }
  .hero-x .hero-index ol { grid-template-columns: 1fr 1fr; }
  .ribbon { margin-top: 48px; }
  .ribbon-tile { width: 210px; border-radius: 18px; margin-right: 14px; }
}
@media (max-width: 560px) { .hero-x .hero-index ol { grid-template-columns: 1fr; } }

/* ---------- Dark sections ---------- */
.section.dark { position: relative; background: var(--night); color: var(--on-night-muted); border: 0; }
.section.dark + .section, .section + .section.dark { border-top: 0; }
.dark-2 { background: linear-gradient(180deg, var(--night), #071027 50%, var(--night)) !important; }
.dark h2, .dark h3 { color: #fff; }
.dark .h2 { max-width: 20ch; }
.dark .lead { color: #bcc5d6; }
.dark .note { color: var(--on-night-dim); }
.dark a:not(.btn):not(.arrow-link) { color: var(--blue-light); }
.horizon { position: absolute; top: 0; left: 50%; width: min(1100px, 92%); height: 1px; transform: translateX(-50%); pointer-events: none;
  background: linear-gradient(90deg, transparent, rgba(143, 180, 255, .55) 30%, rgba(249, 115, 22, .5) 70%, transparent); }
.horizon::after { content: ""; position: absolute; left: 15%; right: 15%; top: 0; height: 120px;
  background: radial-gradient(50% 100% at 50% 0%, rgba(59, 130, 246, .16), transparent); }

.head-center { max-width: 780px; margin: 0 auto var(--s8); text-align: center; display: flex; flex-direction: column; align-items: center; }
.head-center .h2 { margin-top: var(--s4); max-width: 22ch; }
.head-center p:not(.pill) { margin-top: var(--s4); max-width: 60ch; color: var(--on-night-muted); }
.head-split { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: var(--s5) var(--s8); align-items: end; margin-bottom: var(--s7); }
.head-split .h2 { margin-top: var(--s4); }
.head-split > p { color: var(--on-night-muted); max-width: 52ch; }
@media (max-width: 860px) { .head-split { grid-template-columns: 1fr; } .head-center { margin-bottom: var(--s7); } }

/* ---------- Bento (about) ---------- */
.bento { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); grid-auto-rows: 240px; gap: 16px; }
.tile {
  position: relative; isolation: isolate; overflow: hidden; display: flex; flex-direction: column; gap: var(--s3);
  padding: 26px; border-radius: 26px; color: var(--on-night-muted); text-decoration: none;
  background: linear-gradient(180deg, rgba(255, 255, 255, .055), rgba(255, 255, 255, .015));
  border: 1px solid var(--glass-line); transition: border-color .3s, transform .4s var(--ease-out);
}
.tile::before {
  content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; opacity: 0; transition: opacity .35s;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 50%), rgba(143, 180, 255, .16), transparent 45%);
}
.tile:hover::before { opacity: 1; }
.tile:hover { border-color: rgba(143, 180, 255, .3); }
.tile h3 { font-size: 23px; line-height: 1.2; letter-spacing: -0.025em; max-width: 22ch; }
.tile-a { grid-column: 1 / 3; grid-row: 1 / 3; }
.tile-a h3 { font-size: clamp(26px, 2.6vw, 36px); }
.tile-b { grid-column: 3 / 5; }
.tile-photo { padding: 26px; }
.tile-img { position: absolute; inset: 0; z-index: -3; width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease-out); }
.tile-photo::after { content: ""; position: absolute; inset: 0; z-index: -2; background: linear-gradient(to top, rgba(5, 10, 24, .95) 8%, rgba(5, 10, 24, .45) 55%, rgba(5, 10, 24, .1)); }
.tile-photo:hover .tile-img { transform: scale(1.06); }
.tile-body { margin-top: auto; display: flex; flex-direction: column; gap: var(--s3); }
.tile-body p { color: #c9d1e0; }
.tile-photo .chip { margin-bottom: auto; }
.tile-photo .tile-body .chip { margin-bottom: 0; }

.flow { margin-top: auto; display: flex; align-items: flex-start; gap: 6px; }
.flow-node { display: flex; flex-direction: column; align-items: center; gap: 10px; font: 500 13px var(--font); color: #dbe3f2; }
.flow-node .icon { width: 52px; height: 52px; padding: 13px; border-radius: 16px; color: var(--blue-light); background: rgba(37, 99, 235, .16); border: 1px solid rgba(143, 180, 255, .3); }
.flow-node:nth-child(3) .icon { color: var(--orange-light); background: rgba(249, 115, 22, .14); border-color: rgba(249, 115, 22, .4); }
.flow-line { flex: 1; position: relative; height: 2px; margin-top: 25px; border-radius: 2px; overflow: hidden; background: rgba(255, 255, 255, .1); }
.flow-line i { position: absolute; top: 0; bottom: 0; width: 45%; background: linear-gradient(90deg, transparent, var(--blue-light), var(--orange), transparent); animation: travel 2.6s linear infinite; }
.flow-line:nth-of-type(4) i { animation-delay: 1.3s; }
@keyframes travel { from { transform: translateX(-110%); } to { transform: translateX(260%); } }

.tile-d { background: radial-gradient(120% 100% at 100% 0%, rgba(249, 115, 22, .4), transparent 60%), linear-gradient(160deg, #1b1209, #0a0f1e); border-color: rgba(249, 115, 22, .32); }
.tile-d h3 { font-size: 21px; }
.tile-go { margin-top: auto; align-self: flex-end; display: grid; place-items: center; width: 46px; height: 46px; border-radius: 50%; font-size: 20px; color: #1a0c02; background: var(--orange); box-shadow: 0 8px 24px -6px rgba(249, 115, 22, .7); transition: transform .35s var(--ease-out); }
.tile-d:hover .tile-go { transform: rotate(-45deg) scale(1.08); }
.tile-d:hover { border-color: rgba(249, 115, 22, .6); }
@media (max-width: 960px) {
  .bento { grid-template-columns: 1fr 1fr; grid-auto-rows: minmax(220px, auto); }
  .tile-a { grid-column: 1 / -1; grid-row: span 2; }
  .tile-b { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
  .bento { grid-template-columns: 1fr; }
  .tile-a { grid-row: span 1; min-height: 360px; }
  .flow-node { font-size: 12px; }
  .flow-node .icon { width: 44px; height: 44px; padding: 11px; }
  .flow-line { margin-top: 21px; }
}

/* ---------- Flip cards (services) ---------- */
.flip-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
.flip { height: 470px; perspective: 1600px; }
.flip-inner { position: relative; height: 100%; transform-style: preserve-3d; transition: transform .9s var(--ease-out); }
.flip-face {
  position: absolute; inset: 0; overflow: hidden; border-radius: 26px; isolation: isolate;
  border: 1px solid rgba(255, 255, 255, .12); -webkit-backface-visibility: hidden; backface-visibility: hidden;
}
.flip-back { transform: rotateY(180deg); pointer-events: none; }
.flip:focus-within .flip-inner, .flip.is-flipped .flip-inner { transform: rotateY(180deg); }
.flip:focus-within .flip-back, .flip.is-flipped .flip-back { pointer-events: auto; }
@media (hover: hover) {
  .flip:hover .flip-inner { transform: rotateY(180deg); }
  .flip:hover .flip-back { pointer-events: auto; }
}
.flip-img { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; }
.flip-front .flip-img { transition: transform 1.2s var(--ease-out); }
.flip:hover .flip-front .flip-img { transform: scale(1.08); }
.flip-shade { position: absolute; inset: 0; z-index: -1; background: linear-gradient(to top, rgba(5, 10, 24, .96) 12%, rgba(5, 10, 24, .35) 55%, rgba(5, 10, 24, .15)); }
.flip-top { position: absolute; top: 18px; left: 18px; right: 18px; display: flex; justify-content: space-between; align-items: center; }
.flip-num { font: 500 12px/1 var(--mono); letter-spacing: .05em; color: rgba(255, 255, 255, .8); }
.flip-bottom { position: absolute; left: 22px; right: 22px; bottom: 22px; }
.flip-bottom h3 { font-size: 27px; line-height: 1.1; letter-spacing: -0.03em; }
.flip-bottom p { margin-top: var(--s2); color: #d4dbe8; }
.flip-hint { margin-top: var(--s4); display: inline-flex; align-items: center; gap: 7px; font: 500 11.5px/1 var(--mono); letter-spacing: .05em; text-transform: uppercase; color: var(--orange-light); }
.flip-hint svg { animation: spin-hint 4s var(--ease-out) infinite; }
@keyframes spin-hint { 0%, 70% { transform: rotate(0); } 100% { transform: rotate(360deg); } }
.hint-touch { display: none; }
@media (hover: none) { .hint-touch { display: inline; } .hint-hover { display: none; } }

.flip-img-back { filter: blur(3px) saturate(.8); transform: scale(1.12); }
.flip-back::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(90% 60% at 100% 100%, rgba(249, 115, 22, .32), transparent 70%),
    linear-gradient(165deg, rgba(29, 78, 216, .82), rgba(5, 10, 24, .95) 48%, rgba(5, 10, 24, .97));
}
.flip-back-body { position: relative; height: 100%; display: flex; flex-direction: column; gap: var(--s3); padding: 24px; color: #dbe2f0; font-size: 15px; line-height: 1.55; }
.flip-back-title { font-size: 23px; letter-spacing: -0.025em; }
.flip-back ul { list-style: none; margin: 0; padding: var(--s3) 0 0; display: grid; gap: 7px; border-top: 1px solid rgba(255, 255, 255, .12); font-size: 14px; color: #fff; }
.flip-back li { display: flex; align-items: baseline; gap: 9px; }
.flip-back li::before { content: ""; flex: none; width: 6px; height: 6px; border-radius: 50%; background: var(--orange); box-shadow: 0 0 8px var(--orange); transform: translateY(-2px); }
.flip-actions { margin-top: auto; display: flex; flex-wrap: wrap; gap: 10px; }
.flip-grid > [data-reveal]:nth-child(2) { transition-delay: .1s; }
.flip-grid > [data-reveal]:nth-child(3) { transition-delay: .2s; }
.flip-grid > [data-reveal]:nth-child(4) { transition-delay: .3s; }
@media (max-width: 1180px) { .flip-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .flip-grid { grid-template-columns: 1fr; } .flip { height: 440px; } }

/* ---------- Work: photo cards with sliding detail ---------- */
.work-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); grid-auto-rows: 310px; gap: 18px; }
.reveal-card {
  position: relative; isolation: isolate; overflow: hidden; display: flex; align-items: flex-end;
  border-radius: 26px; border: 1px solid rgba(255, 255, 255, .12); transition: border-color .3s;
}
.reveal-card.is-big { grid-row: span 2; }
.reveal-img { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease-out); }
.reveal-shade { position: absolute; inset: 0; z-index: -1; background: linear-gradient(to top, rgba(5, 10, 24, .96) 10%, rgba(5, 10, 24, .35) 60%, rgba(5, 10, 24, .08)); transition: background-color .5s; }
.reveal-body { width: 100%; padding: 26px; display: flex; flex-direction: column; gap: var(--s3); }
.reveal-body h3 { font-size: 25px; letter-spacing: -0.03em; max-width: 24ch; }
.is-big .reveal-body h3 { font-size: clamp(28px, 3vw, 38px); }
.reveal-more { display: grid; grid-template-rows: 0fr; opacity: 0; transition: grid-template-rows .6s var(--ease-out), opacity .4s; }
.reveal-more > div { min-height: 0; overflow: hidden; display: flex; flex-direction: column; gap: var(--s3); }
.reveal-more p { color: #d4dbe8; max-width: 56ch; }
.reveal-card:hover .reveal-more, .reveal-card:focus-within .reveal-more { grid-template-rows: 1fr; opacity: 1; }
.reveal-card:hover .reveal-img, .reveal-card:focus-within .reveal-img { transform: scale(1.07); }
.reveal-card:hover .reveal-shade, .reveal-card:focus-within .reveal-shade { background-color: rgba(5, 10, 24, .45); }
.reveal-card:hover { border-color: rgba(143, 180, 255, .35); }
.reveal-card .tags { display: flex; flex-wrap: wrap; gap: var(--s2); list-style: none; padding: 0; margin: 0; }
.reveal-card .tags li { font-size: 13px; padding: 4px 10px; border-radius: 999px; color: #e3e9f5; border: 1px solid rgba(255, 255, 255, .22); background: rgba(5, 10, 24, .4); }
.work-grid > [data-reveal]:nth-child(2) { transition-delay: .12s; }
.work-grid > [data-reveal]:nth-child(3) { transition-delay: .24s; }
@media (hover: none) { .reveal-more { grid-template-rows: 1fr; opacity: 1; } }
@media (max-width: 860px) {
  .work-grid { grid-template-columns: 1fr; grid-auto-rows: minmax(360px, auto); }
  .reveal-card.is-big { grid-row: auto; min-height: 440px; }
  .reveal-more { grid-template-rows: 1fr; opacity: 1; }
}

/* ---------- Industries: expanding panels ---------- */
.panels { display: flex; gap: 14px; height: 500px; }
.panel {
  position: relative; isolation: isolate; overflow: hidden; flex: 1 1 0; min-width: 0;
  border-radius: 26px; border: 1px solid rgba(255, 255, 255, .12); transition: flex-grow .8s var(--ease-out), border-color .3s;
}
.panel-img { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; transform: scale(1.06); transition: transform 1.2s var(--ease-out), filter .6s; filter: saturate(.6) brightness(.8); }
.panel-shade { position: absolute; inset: 0; z-index: -1; background: linear-gradient(to top, rgba(5, 10, 24, .97) 8%, rgba(5, 10, 24, .45) 60%, rgba(5, 10, 24, .25)); }
.panel-tab {
  position: absolute; left: 22px; bottom: 26px; writing-mode: vertical-rl; transform: rotate(180deg);
  display: flex; align-items: center; gap: 14px; font: 600 26px/1 var(--display); letter-spacing: -0.02em; color: #fff;
  transition: opacity .35s;
}
.panel-tab b { font: 500 12px/1 var(--mono); color: var(--orange-light); }
.panel-body {
  position: absolute; left: 28px; bottom: 28px; width: min(440px, calc(100% - 56px));
  display: flex; flex-direction: column; gap: var(--s3); color: #d4dbe8;
  opacity: 0; transform: translateY(18px); transition: opacity .35s, transform .5s var(--ease-out);
}
.panel-body h3 { font-size: clamp(24px, 2.4vw, 32px); letter-spacing: -0.03em; }
.panel-body .flip-actions { margin-top: var(--s2); }
.panels:not(:hover):not(:focus-within) .panel.is-open, .panel:hover, .panel:focus-within { flex-grow: 3.2; border-color: rgba(143, 180, 255, .3); }
.panels:not(:hover):not(:focus-within) .panel.is-open .panel-body, .panel:hover .panel-body, .panel:focus-within .panel-body { opacity: 1; transform: none; transition-delay: .25s; }
.panels:not(:hover):not(:focus-within) .panel.is-open .panel-tab, .panel:hover .panel-tab, .panel:focus-within .panel-tab { opacity: 0; }
.panels:not(:hover):not(:focus-within) .panel.is-open .panel-img, .panel:hover .panel-img, .panel:focus-within .panel-img { transform: scale(1); filter: none; }
@media (max-width: 860px) {
  .panels { flex-direction: column; height: auto; }
  .panel { flex: none; min-height: 400px; }
  .panel-tab { display: none; }
  .panel .panel-body { opacity: 1; transform: none; }
  .panel .panel-img { filter: none; transform: none; }
}

/* ---------- Process steps ---------- */
.steps { position: relative; list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: var(--s5); }
.steps::before, .steps::after { content: ""; position: absolute; top: 23px; left: 23px; right: 23px; height: 1px; background: rgba(255, 255, 255, .12); }
.steps::after { height: 2px; top: 22px; background: linear-gradient(90deg, var(--blue), var(--blue-light) 60%, var(--orange)); transform: scaleX(0); transform-origin: left; transition: transform 1.8s cubic-bezier(.4, 0, .2, 1) .2s; box-shadow: 0 0 12px rgba(59, 130, 246, .6); }
.steps.is-visible::after, .no-js .steps::after { transform: none; }
.steps li { position: relative; padding-top: 72px; }
.step-n {
  position: absolute; top: 0; left: 0; z-index: 1; display: grid; place-items: center; width: 46px; height: 46px; border-radius: 50%;
  font: 500 13px/1 var(--mono); color: #fff; background: #0b1328; border: 1px solid rgba(255, 255, 255, .16);
  transition: background .5s, border-color .5s, box-shadow .5s;
}
.steps.is-visible .step-n { background: linear-gradient(135deg, #3b82f6, #1d4ed8); border-color: var(--blue-light); box-shadow: 0 0 0 6px rgba(37, 99, 235, .14), 0 0 26px rgba(59, 130, 246, .55); }
.steps.is-visible li:last-child .step-n { background: linear-gradient(135deg, #fb923c, #ea580c); border-color: var(--orange-light); color: #1a0c02; box-shadow: 0 0 0 6px rgba(249, 115, 22, .14), 0 0 26px rgba(249, 115, 22, .55); }
.steps.is-visible li:nth-child(2) .step-n { transition-delay: .45s; }
.steps.is-visible li:nth-child(3) .step-n { transition-delay: .8s; }
.steps.is-visible li:nth-child(4) .step-n { transition-delay: 1.15s; }
.steps.is-visible li:nth-child(5) .step-n { transition-delay: 1.5s; }
.steps h3 { font-size: 18px; }
.steps p { margin-top: var(--s2); font-size: 15px; color: var(--on-night-muted); }
@media (max-width: 1023px) {
  .steps { grid-template-columns: 1fr; gap: var(--s5); }
  .steps::before, .steps::after { top: 23px; bottom: 23px; left: 22px; right: auto; width: 1px; height: auto; }
  .steps::after { width: 2px; left: 22px; transform: scaleY(0); transform-origin: top; background: linear-gradient(180deg, var(--blue), var(--blue-light) 60%, var(--orange)); }
  .steps li { padding: 8px 0 0 72px; min-height: 46px; }
}

/* ---------- Partnerships ---------- */
.split-x { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: var(--s8); align-items: center; }
.split-x .h2 { margin-top: var(--s4); }
.split-x .ticks { list-style: none; margin: var(--s6) 0 0; padding: 0; display: grid; gap: var(--s4); }
.ticks li { position: relative; padding-left: 40px; color: var(--on-night-muted); }
.ticks li strong { display: block; color: #fff; font-weight: 600; }
.ticks li::before { content: ""; position: absolute; left: 0; top: 1px; width: 26px; height: 26px; border-radius: 50%; background: rgba(249, 115, 22, .14); border: 1px solid rgba(249, 115, 22, .5); }
.ticks li::after { content: ""; position: absolute; left: 9px; top: 9px; width: 9px; height: 5px; border-left: 2px solid var(--orange-light); border-bottom: 2px solid var(--orange-light); transform: rotate(-45deg); }
.photo-stack { position: relative; height: 500px; }
.ps-main, .ps-side { position: absolute; overflow: hidden; border-radius: 26px; border: 1px solid rgba(255, 255, 255, .12); }
.ps-main { inset: 0 18% 16% 0; }
.ps-side { right: 0; bottom: 0; width: 50%; height: 50%; border: 5px solid var(--night); box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .8); }
.ps-main img, .ps-side img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease-out); }
.photo-stack:hover .ps-main img { transform: scale(1.05); }
.ps-chip {
  position: absolute; display: inline-flex; align-items: center; gap: 8px; padding: 10px 14px; border-radius: 999px;
  font: 500 13px/1 var(--font); color: #fff; background: rgba(8, 13, 28, .7); border: 1px solid rgba(255, 255, 255, .16);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); box-shadow: 0 16px 40px -12px rgba(0, 0, 0, .7);
  animation: bob 6s ease-in-out infinite;
}
.ps-chip i { width: 8px; height: 8px; border-radius: 50%; background: var(--orange); box-shadow: 0 0 10px var(--orange); }
.ps-chip-1 { top: 7%; right: 4%; }
.ps-chip-2 { left: -3%; bottom: 30%; animation-delay: -3s; }
.ps-chip-2 i { background: var(--blue-light); box-shadow: 0 0 10px var(--blue-light); }
@keyframes bob { 50% { transform: translateY(-10px); } }
@media (max-width: 960px) {
  .split-x { grid-template-columns: 1fr; gap: var(--s7); }
  .photo-stack { height: 380px; }
  .ps-chip-2 { left: 4%; }
}

/* ---------- Page intro (interior pages) ---------- */
.page-intro { position: relative; overflow: hidden; isolation: isolate; background: var(--night); color: var(--on-night-muted); padding: 168px 0 var(--s8); border-bottom: 0; }
.page-intro .aurora { z-index: -1; }
.page-intro .aurora i:nth-child(1) { top: -40vw; }
.page-intro .display { color: #fff; margin-top: var(--s5); max-width: 20ch; }
.page-intro .lead { color: #bcc5d6; }
.page-intro .crumbs ol { color: var(--on-night-dim); }
.page-intro .crumbs a { color: var(--on-night-muted); }
.page-intro .crumbs [aria-current] { color: #fff; }
.page-intro .crumbs li + li::before { color: rgba(255, 255, 255, .3); }
.page-intro a:not(.btn) { color: var(--blue-light); }
@media (max-width: 960px) { .page-intro { padding-top: 132px; } }

/* ---------- CTA band ---------- */
.cta-band { background: var(--night); color: var(--on-night-muted); padding: var(--s8) 0 var(--s9); }
.cta-card {
  position: relative; isolation: isolate; overflow: hidden; text-align: center;
  padding: clamp(64px, 9vw, 112px) var(--s5); border-radius: 34px;
  background: radial-gradient(80% 70% at 50% 120%, rgba(37, 99, 235, .4), transparent 70%), #071026;
  border: 1px solid rgba(255, 255, 255, .1);
}
.cta-arc {
  position: absolute; z-index: -1; left: 50%; top: 74%; width: 130%; aspect-ratio: 1; transform: translateX(-50%); border-radius: 50%;
  border-top: 1px solid rgba(143, 180, 255, .7);
  box-shadow: 0 -24px 90px -16px rgba(59, 130, 246, .55), inset 0 40px 90px -40px rgba(249, 115, 22, .35);
  background: radial-gradient(60% 30% at 50% 0%, rgba(59, 130, 246, .22), transparent);
}
.cta-card h2 { margin: var(--s5) auto 0; max-width: 18ch; color: #fff; font-size: clamp(34px, 5vw, 64px); line-height: 1.02; letter-spacing: -0.04em; }
.cta-card > p:not(.pill) { margin: var(--s4) auto 0; max-width: 54ch; color: #bcc5d6; }
.cta-card .cta-actions { justify-content: center; margin-top: var(--s6); gap: var(--s3); }

/* ---------- Footer ---------- */
.site-footer { position: relative; overflow: hidden; background: var(--night); color: var(--on-night-muted); border-top: 1px solid rgba(255, 255, 255, .07); padding: var(--s8) 0 var(--s5); }
.site-footer::before { content: ""; position: absolute; left: 50%; top: 0; width: 60%; height: 1px; transform: translateX(-50%); background: linear-gradient(90deg, transparent, rgba(249, 115, 22, .6), transparent); }
.footer-brand img { width: 150px; }
.footer-brand p { color: var(--on-night-muted); }
.footer-brand .btn { margin-top: var(--s5); }
.footer-h { font: 500 12px/1 var(--mono); letter-spacing: .06em; color: var(--on-night-dim); margin-bottom: var(--s4); }
.site-footer a:not(.btn) { color: #cfd6e3; }
.site-footer a:not(.btn):hover { color: var(--orange-light); }
.site-footer address { color: #cfd6e3; }
.footer-word {
  margin: var(--s7) 0 calc(-1 * var(--s4)); text-align: center; user-select: none; pointer-events: none;
  font: 700 clamp(72px, 19vw, 270px)/.82 var(--display); letter-spacing: -0.065em;
  background: linear-gradient(180deg, rgba(143, 180, 255, .2), rgba(249, 115, 22, .08) 55%, transparent 90%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.footer-base { margin-top: 0; border-top: 1px solid rgba(255, 255, 255, .08); color: var(--on-night-dim); position: relative; }

/* ---------- Motion off ---------- */
@media (prefers-reduced-motion: reduce) {
  .rotator-words span { animation: none; }
  .rotator-words span:first-child { opacity: 1; }
  .ribbon-track { animation: none; }
  .ribbon { overflow-x: auto; }
  .hero-x .hero-title, .hero-x .lead, .hero-x .actions, .hero-x .pill, .ribbon { animation: none; }
  .flip-inner { transition: none; }
  .flip:hover .flip-inner, .flip:focus-within .flip-inner, .flip.is-flipped .flip-inner { transform: none; }
  .flip-back { transform: none; opacity: 0; transition: opacity .01ms; }
  .flip:hover .flip-back, .flip:focus-within .flip-back, .flip.is-flipped .flip-back { opacity: 1; }
  .steps::after { transform: none; }
  .ps-chip, .aurora i, .flow-line i, .flip-hint svg { animation: none; }
}

/* Three-up variant (About) */
@media (min-width: 961px) { .flip-grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1181px) { .flip-grid-3 .flip { height: 500px; } }
.flip-top .flip-num { padding: 7px 10px; border-radius: 999px; background: rgba(5, 10, 24, .55); border: 1px solid rgba(255, 255, 255, .16); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }

/* Page intro with a photo */
.page-intro.has-photo .wrap { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: var(--s8); align-items: center; }
.intro-photo {
  position: relative; aspect-ratio: 4 / 3.4; border-radius: 28px; overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .14); box-shadow: 0 40px 80px -30px rgba(0, 0, 0, .9), 0 0 0 8px rgba(255, 255, 255, .025);
  transform: rotate(1.5deg); animation: rise 1s var(--ease-out) both .2s;
}
.intro-photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(160deg, rgba(37, 99, 235, .18), transparent 40%, rgba(249, 115, 22, .16)); }
.intro-photo img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 960px) {
  .page-intro.has-photo .wrap { grid-template-columns: 1fr; gap: var(--s6); }
  .intro-photo { aspect-ratio: 16 / 10; transform: none; }
}

/* Vertical steps (narrow columns) */
.steps-v { grid-template-columns: 1fr; }
.steps-v::before, .steps-v::after { top: 23px; bottom: 23px; left: 22px; right: auto; width: 1px; height: auto; }
.steps-v::after { width: 2px; transform: scaleY(0); transform-origin: top; background: linear-gradient(180deg, var(--blue), var(--blue-light) 60%, var(--orange)); }
.steps-v.is-visible::after { transform: none; }
.steps-v li { padding: 8px 0 0 72px; min-height: 46px; }

/* Interior content on dark */
.section-paper { background: var(--paper); border-color: rgba(255, 255, 255, .06); }
.detail aside { padding: var(--s5); border: 1px solid var(--line); border-radius: 22px; background: linear-gradient(180deg, rgba(37, 99, 235, .12), rgba(255, 255, 255, .02)); }
.callout { border-radius: 0 16px 16px 0; border-left-color: var(--orange); background: rgba(255, 255, 255, .04); }
.list-check li::before { border-color: var(--orange-light); }
.card-icon, .cap-icon { border-radius: 14px; }

/* Contact: email / call cards */
.reach { display: grid; gap: var(--s3); }
.reach-card {
  display: flex; flex-direction: column; gap: 6px; padding: 18px 20px; border-radius: 18px; text-decoration: none;
  background: linear-gradient(180deg, rgba(255, 255, 255, .06), rgba(255, 255, 255, .02)); border: 1px solid var(--line);
  transition: border-color .25s, transform .25s var(--ease-out);
}
.reach-card:hover { border-color: rgba(249, 115, 22, .55); transform: translateY(-2px); }
.reach-card strong { color: #fff; font: 600 19px/1.3 var(--display); letter-spacing: -0.01em; word-break: break-word; }
.reach-card span:not(.chip) { color: var(--muted); font-size: 14px; }
.contact-aside .reach-card { margin-top: 0; }

/* =============================================================
   Responsive pass — phones get app-like swipe rows instead of
   tall stacked desktop grids; tablets get real 2-up layouts.
   ============================================================= */
.swipe-hint { display: none; }

/* Tablet: 701–1023 */
@media (min-width: 701px) and (max-width: 1023px) {
  .flip { height: 420px; }
  .work-grid { grid-template-columns: 1fr 1fr; grid-auto-rows: minmax(360px, auto); }
  .reveal-card.is-big { grid-column: 1 / -1; grid-row: auto; min-height: 0; }
  .reveal-more { grid-template-rows: 1fr; opacity: 1; }
  .panels { flex-direction: row; height: 440px; }
  .panel { flex: 1 1 0; min-height: 0; }
  .panel-tab { display: flex; }
  .panel .panel-body { opacity: 0; transform: translateY(18px); }
  .panels:not(:hover):not(:focus-within) .panel.is-open .panel-body, .panel:hover .panel-body, .panel:focus-within .panel-body { opacity: 1; transform: none; }
  .panel-body { width: min(380px, calc(100% - 48px)); left: 24px; bottom: 24px; }
  .photo-stack { height: 420px; max-width: 620px; }
}

/* Phones: ≤700 */
@media (max-width: 700px) {
  /* Swipe rows */
  .flip-grid, .work-grid, .panels {
    display: flex; flex-direction: row; gap: 14px; height: auto;
    overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scroll-padding-inline: var(--gutter);
    margin-inline: calc(-1 * var(--gutter)); padding: 4px var(--gutter) 8px;
    scrollbar-width: none; -webkit-overflow-scrolling: touch;
  }
  .flip-grid::-webkit-scrollbar, .work-grid::-webkit-scrollbar, .panels::-webkit-scrollbar { display: none; }
  .flip-grid > *, .work-grid > *, .panels > * { flex: 0 0 84%; scroll-snap-align: start; }
  .flip { height: 430px; }
  .reveal-card, .reveal-card.is-big { min-height: 400px; grid-row: auto; }
  .reveal-body h3, .is-big .reveal-body h3 { font-size: 22px; }
  .panel { flex: 0 0 84%; min-height: 440px; }
  .js .flip-grid > [data-reveal], .js .work-grid > [data-reveal] { transition-delay: 0s; }
  .swipe-hint {
    display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: var(--s3);
    font: 500 11px/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--on-night-dim);
  }
  .swipe-hint::after { content: "→"; color: var(--orange-light); animation: nudge 1.6s ease-in-out infinite; }

  /* Hero */
  .hero-x { padding: 112px 0 var(--s5); }
  .hero-x .hero-title { font-size: clamp(34px, 10vw, 42px); letter-spacing: -0.03em; }
  .hero-x .lead { font-size: 16px; margin-top: var(--s4); }
  .hero-x .actions { flex-direction: column; align-items: stretch; width: 100%; max-width: 360px; margin-top: var(--s5); }
  .ribbon { margin-top: var(--s6); padding: 12px 0; }
  .ribbon-tile { width: 168px; border-radius: 16px; margin-right: 12px; }
  .ribbon-tile figcaption { font-size: 9.5px; padding: 5px 8px; left: 8px; bottom: 8px; }
  .hero-x .hero-index { margin-top: var(--s5); }
  .hero-x .hero-index ol {
    display: flex; gap: 10px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none;
    margin-inline: calc(-1 * var(--gutter)); padding: 0 var(--gutter) 4px;
  }
  .hero-x .hero-index ol::-webkit-scrollbar { display: none; }
  .hero-x .hero-index li { flex: none; scroll-snap-align: start; }
  .hero-x .hero-index a { grid-template-columns: auto auto; gap: 8px; padding: 12px 14px; border-radius: 999px; white-space: nowrap; font-size: 14px; }
  .hero-x .hero-index a span:last-child { display: none; }

  /* Headings & spacing */
  .h2, .dark .h2 { font-size: clamp(27px, 7.6vw, 34px); }
  .head-center, .head-split { margin-bottom: var(--s6); }
  .head-center p:not(.pill), .head-split > p { font-size: 15.5px; }
  .lead, .dark .lead { font-size: 16.5px; }

  /* Bento: compact 2-up */
  .bento { grid-template-columns: 1fr 1fr; grid-auto-rows: auto; gap: 12px; }
  .tile { padding: 18px; border-radius: 20px; gap: 10px; }
  .tile-a { grid-column: 1 / -1; grid-row: auto; min-height: 280px; }
  .tile-a h3 { font-size: 24px; }
  .tile-b { grid-column: 1 / -1; }
  .tile-c, .tile-d { min-height: 200px; }
  .tile-c h3, .tile-d h3, .tile-b h3 { font-size: 17px; }
  .tile-d .tile-go { width: 38px; height: 38px; font-size: 17px; }

  /* Steps */
  .steps { gap: var(--s4); }
  .steps li { padding-left: 64px; }
  .steps p { font-size: 14.5px; }

  /* Partnerships */
  .photo-stack { height: 300px; }
  .ps-chip { font-size: 12px; padding: 8px 11px; }
  .split-x .ticks { gap: var(--s3); margin-top: var(--s5); }

  /* CTA */
  .cta-band { padding: var(--s6) 0 var(--s7); }
  .cta-card { padding: 56px 20px 64px; border-radius: 26px; }
  .cta-card h2 { font-size: clamp(28px, 8.4vw, 36px); }
  .cta-card .cta-actions { flex-direction: column; align-items: stretch; }
  .cta-card .cta-actions .btn { white-space: normal; text-align: center; }

  /* Interior pages */
  .page-intro { padding: 112px 0 var(--s6); }
  .page-intro .display { font-size: clamp(32px, 9.4vw, 40px); }
  .page-intro .lead { font-size: 16px; }
  .intro-photo { aspect-ratio: 16 / 9; border-radius: 20px; }
  .detail aside { padding: var(--s4); }
  .detail h2.sub { font-size: 24px; margin: var(--s6) 0 var(--s4); }

  /* Footer */
  .site-footer { padding-top: var(--s7); }
  .footer-brand p { font-size: 14.5px; }
  .footer-word { font-size: 25vw; margin-top: var(--s6); }
  .footer-base { flex-direction: column; gap: var(--s3); }
}
@keyframes nudge { 50% { transform: translateX(5px); } }
@media (prefers-reduced-motion: reduce) { .swipe-hint::after { animation: none; } }
