/* ==========================================================================
   STUDIIO.CO — homepage prototype
   Monochrome system, one accent. Work carries the colour.
   ========================================================================== */

:root {
  --paper: #EEECE6;
  --paper-2: #E2DFD7;
  --ink: #0E0E0D;
  --ink-2: #1B1B19;
  --muted: #6E6A62;
  --line: rgba(14, 14, 13, .16);
  --line-dark: rgba(238, 236, 230, .18);
  --accent: #FF4B1F;

  --gutter: clamp(16px, 2.2vw, 32px);
  --radius: 6px;

  --f-display: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --f-body: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --f-serif: "Fraunces", Georgia, serif;
  --f-mono: "IBM Plex Mono", ui-monospace, Menlo, monospace;
  --track-tight: -.035em;
  --track-label: .06em;

  --ease: cubic-bezier(.2, .7, .1, 1);
}

html[lang="ar"] {
  --f-display: "Alexandria", "IBM Plex Sans Arabic", Tahoma, sans-serif;
  --f-body: "IBM Plex Sans Arabic", Tahoma, sans-serif;
  --f-serif: "Noto Naskh Arabic", serif;
  --f-mono: "IBM Plex Sans Arabic", Tahoma, sans-serif;
  --track-tight: 0;
  --track-label: 0;
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--f-body);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
figure { margin: 0; }
::selection { background: var(--accent); color: #fff; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip {
  position: fixed; top: 8px; inset-inline-start: 8px; z-index: 200;
  background: var(--ink); color: var(--paper); padding: 10px 14px; border-radius: 999px;
  transform: translateY(-160%); transition: transform .2s;
}
.skip:focus { transform: none; }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

/* ---------- Type helpers ---------- */

.label {
  font-family: var(--f-mono);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: var(--track-label);
  text-transform: uppercase;
  margin: 0;
}
html[lang="ar"] .label { font-size: 13px; text-transform: none; }

.section-label { color: var(--muted); margin-bottom: 18px; }
.services .section-label, .contact .section-label { color: rgba(238, 236, 230, .55); }

.section-title {
  font-family: var(--f-display);
  font-weight: 700;
  font-size: clamp(38px, 5.4vw, 88px);
  line-height: .95;
  letter-spacing: var(--track-tight);
  margin: 0;
}
html[lang="ar"] .section-title { line-height: 1.2; font-weight: 700; }

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px 48px;
  margin-bottom: clamp(36px, 5vw, 80px);
}
.section-aside { max-width: 34ch; margin: 0; color: rgba(238, 236, 230, .7); font-size: 17px; }

.arrow { display: inline-block; transition: transform .35s var(--ease); }
html[dir="rtl"] .arrow { transform: scaleX(-1); }

.link-arrow {
  display: inline-flex; align-items: center; gap: .5em;
  font-family: var(--f-mono); font-size: 13px; font-weight: 500;
  letter-spacing: var(--track-label); text-transform: uppercase;
  padding-bottom: 4px; border-bottom: 1px solid currentColor; white-space: nowrap;
}
html[lang="ar"] .link-arrow { text-transform: none; font-size: 15px; }
.link-arrow:hover .arrow { transform: translateX(6px); }
html[dir="rtl"] .link-arrow:hover .arrow { transform: scaleX(-1) translateX(6px); }

/* ---------- Pills ---------- */

.pill {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  height: 36px; padding: 0 16px;
  border: 1px solid var(--ink); border-radius: 999px;
  background: transparent; color: var(--ink);
  font-family: var(--f-mono); font-size: 12px; font-weight: 500;
  letter-spacing: .04em; text-transform: uppercase; white-space: nowrap;
  cursor: pointer;
  transition: background-color .2s, color .2s, border-color .2s;
}
html[lang="ar"] .pill { text-transform: none; letter-spacing: 0; font-size: 14px; }
.pill:hover { background: var(--ink); color: var(--paper); }
.pill--solid { background: var(--ink); color: var(--paper); }
.pill--solid:hover { background: var(--accent); border-color: var(--accent); color: #fff; }
.pill--light { border-color: rgba(238, 236, 230, .5); color: var(--paper); }
.pill--light:hover { background: var(--paper); color: var(--ink); border-color: var(--paper); }
.pill--accent { background: var(--accent); border-color: var(--accent); color: #fff; height: 48px; padding: 0 24px; }
.pill--accent:hover { background: var(--paper); border-color: var(--paper); color: var(--ink); }
.lang-toggle { font-family: "IBM Plex Sans Arabic", var(--f-mono); font-size: 14px; letter-spacing: 0; text-transform: none; }
.lang-toggle[lang="en"] { font-family: var(--f-mono); font-size: 12px; text-transform: uppercase; letter-spacing: .04em; }

/* ==========================================================================
   Header
   ========================================================================== */

.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 16px;
  padding: 14px var(--gutter);
  transition: background-color .3s, backdrop-filter .3s;
}
.site-header.is-scrolled {
  background: rgba(238, 236, 230, .82);
  -webkit-backdrop-filter: blur(12px) saturate(1.2);
  backdrop-filter: blur(12px) saturate(1.2);
}
.site-header.on-dark { color: var(--paper); }
.site-header.on-dark.is-scrolled { background: rgba(14, 14, 13, .78); }
.site-header.on-dark .pill { border-color: rgba(238, 236, 230, .45); color: var(--paper); }
.site-header.on-dark .pill:hover { background: var(--paper); color: var(--ink); }
.site-header.on-dark .pill--solid { background: var(--paper); color: var(--ink); border-color: var(--paper); }
.site-header.on-dark .pill--solid:hover { background: var(--accent); border-color: var(--accent); color: #fff; }
.site-header.on-dark .header-note { color: rgba(238, 236, 230, .6); }
.nav-group { display: flex; align-items: center; gap: 6px; }
.nav-actions { justify-content: flex-end; }

.header-center { position: relative; display: grid; place-items: center; min-height: 36px; }
.header-note, .header-logo { grid-area: 1 / 1; transition: opacity .35s, transform .45s var(--ease); }
.header-note { color: var(--muted); }
.header-logo { opacity: 0; transform: translateY(8px); pointer-events: none; }
.header-logo svg { height: 15px; width: auto; }
.site-header.show-logo .header-logo { opacity: 1; transform: none; pointer-events: auto; }
.site-header.show-logo .header-note { opacity: 0; transform: translateY(-8px); }

.menu-btn { display: none; }

.mobile-menu {
  position: fixed; inset: 0; z-index: 45;
  background: var(--ink); color: var(--paper);
  display: flex; flex-direction: column; justify-content: space-between;
  padding: 96px var(--gutter) 32px;
}
.mobile-menu[hidden] { display: none; }
.mobile-menu nav { display: flex; flex-direction: column; }
.mobile-menu nav a {
  font-family: var(--f-display); font-weight: 700; font-size: clamp(40px, 11vw, 72px);
  line-height: 1.05; letter-spacing: var(--track-tight);
  padding: 6px 0; border-bottom: 1px solid var(--line-dark);
}
html[lang="ar"] .mobile-menu nav a { line-height: 1.4; }
.mobile-menu-foot { display: flex; align-items: center; justify-content: space-between; color: rgba(238, 236, 230, .6); }
body.menu-open { overflow: hidden; }
body.menu-open .site-header { background: transparent; backdrop-filter: none; color: var(--paper); }
body.menu-open .site-header .pill { border-color: rgba(238, 236, 230, .5); color: var(--paper); }
body.menu-open .site-header .pill--solid { background: var(--paper); color: var(--ink); }

/* ==========================================================================
   Hero
   ========================================================================== */

.hero { padding: 92px var(--gutter) 0; }

/* Official STUDIIO.CO logo, rebuilt as SVG so it scales to the full width */
.wordmark { margin: 0; line-height: 0; }
.wordmark svg, .header-logo svg { display: block; fill: currentColor; overflow: hidden; }
.wordmark svg { width: 100%; height: auto; }
.wordmark .dot, .header-logo .dot { fill: var(--accent); }
.hero .wordmark { margin-top: clamp(28px, 4vw, 64px); }
html.js .hero .wordmark .g {
  transform-box: fill-box;
  transform: translateY(135%);
  animation: rise 1.1s var(--ease) forwards;
  animation-delay: calc(120ms + var(--i) * 50ms);
}
@keyframes rise { to { transform: translateY(0); } }

.hero-meta {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: 24px 48px;
  align-items: end;
  margin-top: clamp(28px, 3.4vw, 56px);
}
.hero-lede {
  margin: 0;
  font-family: var(--f-display);
  font-weight: 500;
  font-size: clamp(22px, 2.3vw, 36px);
  line-height: 1.12;
  letter-spacing: -.02em;
  max-width: 24ch;
}
html[lang="ar"] .hero-lede { line-height: 1.5; letter-spacing: 0; font-weight: 500; }

.hero-side { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; }
.hero-services { list-style: none; padding: 0; margin: 0; display: grid; gap: 4px; }
.hero-services .idx { color: var(--accent); margin-inline-end: 8px; }
.play-btn { height: 44px; padding: 0 20px 0 14px; }
.play-ico {
  width: 0; height: 0; border-style: solid; border-width: 5px 0 5px 8px;
  border-color: transparent transparent transparent currentColor;
}

/* Film strip */
.strip {
  position: relative;
  margin: clamp(32px, 4vw, 56px) calc(var(--gutter) * -1) 0;
  overflow: hidden;
  touch-action: pan-y;            /* sideways swipes move the strip, vertical swipes still scroll the page */
  -webkit-user-select: none; user-select: none;
}
.strip-track {
  display: flex; gap: 10px; width: max-content;
  padding-inline: 5px;
  will-change: transform;         /* moved by main.js: auto drift + drag/swipe */
}
.strip-item img { -webkit-user-drag: none; }
.strip.is-dragging .strip-item { cursor: grabbing; }
@keyframes marquee { to { transform: translateX(-50%); } }
@keyframes marquee-rtl { to { transform: translateX(50%); } }

.strip-item {
  position: relative; flex: none;
  height: clamp(320px, 50vh, 600px); aspect-ratio: 4 / 5;
  overflow: hidden; border-radius: var(--radius);
  background: var(--paper-2);
  cursor: pointer;
}
.strip-item img { width: 100%; height: 100%; object-fit: cover; transition: transform 1s var(--ease), filter .5s; }
.strip-item:hover img { transform: scale(1.035); }
.strip-item figcaption {
  position: absolute; inset: auto 0 0 0; padding: 40px 14px 12px;
  color: #fff; background: linear-gradient(to top, rgba(0,0,0,.55), transparent);
  opacity: 0; transform: translateY(6px); transition: opacity .3s, transform .4s var(--ease);
}
.strip-item:hover figcaption { opacity: 1; transform: none; }

@media (hover: hover) and (pointer: fine) {
  .strip, .strip-item { cursor: none; }
}

.cursor {
  --x: -200px; --y: -200px; --s: 0;
  position: fixed; left: 0; top: 0; z-index: 60;
  width: 108px; height: 108px; border-radius: 50%;
  display: grid; place-items: center; text-align: center;
  background: var(--accent); color: #fff;
  font-family: var(--f-mono); font-size: 12px; font-weight: 500;
  letter-spacing: .06em; text-transform: uppercase;
  pointer-events: none;
  transform: translate3d(calc(var(--x) - 50%), calc(var(--y) - 50%), 0) scale(var(--s));
  transition: transform .25s var(--ease);
}
html[lang="ar"] .cursor { font-family: var(--f-body); font-size: 14px; letter-spacing: 0; text-transform: none; }
.cursor.on { --s: 1; }
.cursor.on.pressed { --s: .8; }

/* ==========================================================================
   Statement
   ========================================================================== */

.statement { padding: clamp(110px, 13vw, 220px) var(--gutter) clamp(80px, 9vw, 150px); }
.statement-text {
  margin: 0;
  font-family: var(--f-display);
  font-weight: 600;
  font-size: clamp(36px, 5.6vw, 96px);
  line-height: 1;
  letter-spacing: -.04em;
  max-width: 17ch;
}
.statement-text em, .contact-title em {
  font-family: var(--f-serif); font-style: italic; font-weight: 400;
  letter-spacing: -.02em;
}
html[lang="ar"] .statement-text { line-height: 1.35; letter-spacing: 0; font-weight: 700; max-width: 20ch; }
html[lang="ar"] .statement-text em, html[lang="ar"] .contact-title em {
  font-style: normal; font-weight: 600; color: var(--accent); letter-spacing: 0;
}

/* About: the two i's — Ideas and Impact */
.about-intro {
  margin: clamp(28px, 3vw, 48px) 0 0; max-width: 54ch;
  font-size: clamp(19px, 1.55vw, 24px); line-height: 1.45; letter-spacing: -.005em;
}
html[lang="ar"] .about-intro { line-height: 1.85; letter-spacing: 0; }
.ii { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px clamp(24px, 4vw, 72px); margin-top: clamp(56px, 7vw, 112px); }
.ii-card {
  display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: clamp(18px, 2.2vw, 32px); align-content: start;
  padding-top: 26px; border-top: 1px solid var(--line);
}
.ii-bar {
  grid-row: 1 / span 3; align-self: start;
  width: clamp(16px, 1.7vw, 24px); height: clamp(64px, 6.6vw, 96px); /* the logo's I */
  background: var(--ink); transform-origin: bottom; transition: background-color .3s;
}
.ii-card:hover .ii-bar { background: var(--accent); }
html.js .ii-card.reveal .ii-bar { transform: scaleY(0); transition: transform 1s var(--ease) .15s, background-color .3s; }
html.js .ii-card.reveal.in .ii-bar { transform: none; }
.ii-card .label { color: var(--muted); }
.label .lc { text-transform: none; }
.ii-title {
  margin: 6px 0 16px; font-family: var(--f-display); font-weight: 700;
  font-size: clamp(44px, 5.4vw, 92px); line-height: .92; letter-spacing: -.045em;
}
html[lang="ar"] .ii-title { line-height: 1.2; letter-spacing: 0; }
.ii-body { margin: 0; max-width: 38ch; font-size: clamp(17px, 1.3vw, 20px); line-height: 1.5; }
html[lang="ar"] .ii-body { line-height: 1.85; }
.about-both {
  margin: clamp(64px, 8vw, 128px) 0 0; max-width: 22ch;
  font-family: var(--f-display); font-weight: 600;
  font-size: clamp(30px, 3.9vw, 64px); line-height: 1.04; letter-spacing: -.035em;
}
.about-both em { font-family: var(--f-serif); font-style: italic; font-weight: 400; color: var(--accent); letter-spacing: -.02em; }
html[lang="ar"] .about-both { line-height: 1.45; letter-spacing: 0; font-weight: 700; }
html[lang="ar"] .about-both em { font-style: normal; font-weight: 600; letter-spacing: 0; }

.statement-foot {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 32px;
  margin-top: clamp(40px, 5vw, 80px);
  padding-top: 24px; border-top: 1px solid var(--line);
}
.statement-foot p { margin: 0; max-width: 46ch; font-size: clamp(17px, 1.3vw, 20px); line-height: 1.45; }
html[lang="ar"] .statement-foot p { line-height: 1.8; }

/* ==========================================================================
   Services
   ========================================================================== */

.services { background: var(--ink); color: var(--paper); padding: clamp(90px, 10vw, 170px) var(--gutter); }

.svc { border-top: 1px solid var(--line-dark); }
.svc:last-child { border-bottom: 1px solid var(--line-dark); }
.svc summary {
  position: relative; z-index: 41; /* titles stay above the floating hover preview */
  list-style: none; cursor: pointer;
  display: grid; grid-template-columns: clamp(48px, 7vw, 120px) minmax(0, 1fr) auto;
  align-items: center; gap: 16px;
  padding: clamp(22px, 2.4vw, 34px) 0;
}
.svc summary::-webkit-details-marker { display: none; }
.svc-num { font-family: var(--f-mono); font-size: 13px; color: rgba(238, 236, 230, .5); transition: color .3s; }
.svc-title {
  font-family: var(--f-display); font-weight: 600;
  font-size: clamp(26px, 3.9vw, 62px); line-height: 1; letter-spacing: -.035em;
  transition: transform .5s var(--ease), color .3s;
}
html[lang="ar"] .svc-title { line-height: 1.3; letter-spacing: 0; }
.svc-icon {
  position: relative; width: 44px; height: 44px; border-radius: 50%;
  border: 1px solid rgba(238, 236, 230, .35); transition: background .3s, border-color .3s, transform .45s var(--ease);
}
.svc-icon::before, .svc-icon::after {
  content: ""; position: absolute; left: 50%; top: 50%; width: 14px; height: 1.5px;
  background: currentColor; transform: translate(-50%, -50%);
}
.svc-icon::after { transform: translate(-50%, -50%) rotate(90deg); }
.svc summary:hover .svc-num, .svc[open] .svc-num { color: var(--accent); }
.svc summary:hover .svc-title { transform: translateX(14px); }
html[dir="rtl"] .svc summary:hover .svc-title { transform: translateX(-14px); }
.svc summary:hover .svc-icon { background: var(--paper); color: var(--ink); border-color: var(--paper); }
.svc[open] .svc-icon { transform: rotate(45deg); background: var(--accent); border-color: var(--accent); color: #fff; }

.svc-body {
  display: grid; grid-template-columns: clamp(48px, 7vw, 120px) minmax(0, 1.15fr) minmax(0, 1fr);
  gap: 16px 40px; padding: 0 0 clamp(32px, 4vw, 56px);
  animation: fadeUp .6s var(--ease);
}
.svc-body > :first-child { grid-column: 2; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(12px); } }
.svc-lead {
  margin: 0 0 24px; font-family: var(--f-display); font-weight: 500;
  font-size: clamp(20px, 1.8vw, 28px); line-height: 1.2; letter-spacing: -.015em; max-width: 30ch;
}
html[lang="ar"] .svc-lead { line-height: 1.6; letter-spacing: 0; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 0; }
.tag {
  border: 1px solid rgba(238, 236, 230, .28); border-radius: 999px; padding: 7px 13px;
  font-family: var(--f-mono); font-size: 12px; line-height: 1.2; color: rgba(238, 236, 230, .85);
}
html[lang="ar"] .tag { font-size: 14px; }
.svc-media { border-radius: var(--radius); overflow: hidden; aspect-ratio: 4 / 3; background: var(--ink-2); }
.svc-media img { width: 100%; height: 100%; object-fit: cover; }

/* Browser mock for the web service */
.browser { display: flex; flex-direction: column; background: #f4f3ef; padding: 0; }
.browser-bar { display: flex; align-items: center; gap: 6px; padding: 10px 12px; background: #e3e1da; }
.browser-bar i { width: 9px; height: 9px; border-radius: 50%; background: #c9c6bd; }
.browser-bar i:first-child { background: var(--accent); }
.browser-bar span { margin-inline-start: 10px; flex: 1; height: 18px; border-radius: 999px; background: #f4f3ef; font: 500 10px/18px var(--f-mono); color: #8a867d; padding-inline: 10px; direction: ltr; text-align: left; }
.browser-page { position: relative; flex: 1; overflow: hidden; }
.browser-page img { position: absolute; inset: 0; }
.browser-page b {
  position: absolute; inset: auto 0 0 0; padding: 10px 14px; color: #fff; direction: ltr; text-align: left;
  font-family: "Archivo", sans-serif; font-weight: 800; font-size: clamp(22px, 3.4vw, 46px); letter-spacing: -.05em; line-height: .9;
  font-variation-settings: "wdth" 112; background: linear-gradient(to top, rgba(0,0,0,.45), transparent);
}

.svc-preview {
  --x: -400px; --y: -400px; --s: .6; --o: 0;
  position: fixed; left: 0; top: 0; z-index: 40; pointer-events: none;
  width: clamp(200px, 18vw, 300px); aspect-ratio: 4 / 5; border-radius: var(--radius); overflow: hidden;
  opacity: var(--o);
  transform: translate3d(calc(var(--x) + 28px), calc(var(--y) - 50%), 0) scale(var(--s));
  transition: opacity .25s, transform .45s var(--ease);
}
html[dir="rtl"] .svc-preview { transform: translate3d(calc(var(--x) - 100% - 28px), calc(var(--y) - 50%), 0) scale(var(--s)); }
.svc-preview.on { --o: 1; --s: 1; }
.svc-preview img { width: 100%; height: 100%; object-fit: cover; }

/* ==========================================================================
   Work
   ========================================================================== */

.work { padding: clamp(90px, 10vw, 170px) var(--gutter); }
.work .section-head { color: var(--ink); }

.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: clamp(28px, 3vw, 44px); }
.filter[aria-pressed="true"] { background: var(--ink); color: var(--paper); }

.grid {
  display: grid; grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: clamp(28px, 3vw, 48px) clamp(12px, 1.4vw, 20px);
}
.tile { grid-column: span 2; animation: fadeUp .6s var(--ease) both; }
.tile[data-size="3"] { grid-column: span 3; }
.tile a { display: block; }
.tile-media { position: relative; overflow: hidden; border-radius: var(--radius); aspect-ratio: 4 / 5; background: var(--paper-2); }
.tile[data-size="3"] .tile-media { aspect-ratio: 1 / 1; }
.tile-media img { width: 100%; height: 100%; object-fit: cover; transition: transform 1s var(--ease); }
.tile:hover .tile-media img { transform: scale(1.045); }
.tile-media::after {
  content: "↗"; position: absolute; top: 14px; inset-inline-end: 14px;
  width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center;
  background: var(--paper); color: var(--ink); font-size: 18px;
  opacity: 0; transform: scale(.6); transition: opacity .3s, transform .4s var(--ease);
}
html[dir="rtl"] .tile-media::after { content: "↖"; }
.tile:hover .tile-media::after { opacity: 1; transform: none; }
.tile-info { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; padding-top: 14px; }
.tile-title { margin: 0; font-family: var(--f-display); font-weight: 700; font-size: clamp(17px, 1.35vw, 21px); letter-spacing: -.015em; line-height: 1.2; }
html[lang="ar"] .tile-title { letter-spacing: 0; }
.tile-sub { margin: 2px 0 0; color: var(--muted); font-size: 15px; }
.tile-tags { color: var(--muted); text-align: end; display: grid; gap: 2px; flex: none; }

.empty {
  grid-column: 1 / -1; display: grid; justify-items: center; gap: 20px; text-align: center;
  padding: clamp(56px, 8vw, 120px) 24px; border: 1px dashed rgba(14, 14, 13, .3); border-radius: var(--radius);
  animation: fadeUp .6s var(--ease) both;
}
.empty p { margin: 0; max-width: 40ch; font-family: var(--f-display); font-weight: 500; font-size: clamp(20px, 2vw, 28px); line-height: 1.25; letter-spacing: -.015em; }
html[lang="ar"] .empty p { line-height: 1.6; letter-spacing: 0; }

/* ==========================================================================
   Proof: numbers + client marquee
   ========================================================================== */

.proof { padding-top: clamp(20px, 3vw, 40px); }
.proof-label { padding: 0 var(--gutter); }
.numbers { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid var(--line); }
.num { display: flex; flex-direction: column; justify-content: space-between; gap: 40px; padding: 28px var(--gutter) 32px; border-inline-start: 1px solid var(--line); }
.num:first-child { border-inline-start: 0; }
.num-value {
  font-family: "Archivo", sans-serif; font-weight: 700; font-variation-settings: "wdth" 105;
  font-size: clamp(52px, 7.4vw, 128px); line-height: .85; letter-spacing: -.055em;
  unicode-bidi: isolate; text-align: start;
}
.num .label { color: var(--muted); }

.clients { border-block: 1px solid var(--line); padding: 28px 0 36px; }
.clients-label { color: var(--muted); padding: 0 var(--gutter); margin-bottom: 22px; }

/* Client logos: two rows sliding in opposite directions */
.logo-marquee {
  --logo-scale: 1;
  display: grid; gap: clamp(10px, 1.6vw, 22px);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
}
.logo-row { overflow: hidden; }
.logo-track { display: flex; align-items: center; width: max-content; animation: marquee 70s linear infinite; }
.logo-row--rev .logo-track { animation-direction: reverse; animation-duration: 64s; }
html[dir="rtl"] .logo-track { animation-name: marquee-rtl; }
.logo-marquee:hover .logo-track { animation-play-state: paused; }
.client-logo { flex: none; display: grid; place-items: center; height: 88px; padding-inline: clamp(24px, 3.2vw, 52px); }
.client-logo img {
  display: block; width: auto; max-width: none;
  height: calc(var(--h) * var(--logo-scale) * 1px);
  transition: transform .4s var(--ease);
}
.client-logo:hover img { transform: scale(1.06); }

/* ==========================================================================
   studiio.ai
   ========================================================================== */

.ai {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(40px, 5vw, 96px); align-items: center;
  padding: clamp(100px, 11vw, 190px) var(--gutter);
}
.ai-title {
  margin: 0 0 clamp(20px, 2.4vw, 36px);
  font-family: "Archivo", sans-serif; font-weight: 800; font-variation-settings: "wdth" 112;
  font-size: clamp(64px, 10vw, 172px); line-height: .82; letter-spacing: -.06em;
}
html[dir="rtl"] .ai-title { text-align: right; }
.ai-title span { color: var(--accent); }
.ai-body { margin: 0 0 32px; max-width: 42ch; font-size: clamp(17px, 1.3vw, 20px); line-height: 1.5; }
html[lang="ar"] .ai-body { line-height: 1.8; }
.ai-cta { height: 46px; padding: 0 20px; }
.ai-cta:hover .arrow--up { transform: translate(3px, -3px); }
.ai-media { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.ai-media figure { border-radius: var(--radius); overflow: hidden; aspect-ratio: 4 / 5; background: var(--paper-2); }
.ai-media figure:last-child { margin-top: clamp(40px, 6vw, 100px); }
.ai-media img { width: 100%; height: 100%; object-fit: cover; }

/* ==========================================================================
   Thinking
   ========================================================================== */

.thinking { padding: 0 var(--gutter) clamp(100px, 11vw, 190px); }
.article {
  display: grid; grid-template-columns: clamp(110px, 14vw, 220px) minmax(0, 1fr) auto;
  align-items: center; gap: clamp(16px, 2.5vw, 40px);
  padding: clamp(18px, 2vw, 26px) 0; border-top: 1px solid var(--line);
}
.article:last-child { border-bottom: 1px solid var(--line); }
.article-thumb { border-radius: 4px; overflow: hidden; aspect-ratio: 4 / 3; background: var(--paper-2); }
.article-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.article:hover .article-thumb img { transform: scale(1.06); }
.article-meta { color: var(--muted); margin-bottom: 10px; display: flex; gap: 14px; }
.article-meta .cat { color: var(--accent); }
.article-title {
  margin: 0; font-family: var(--f-display); font-weight: 600;
  font-size: clamp(21px, 2.5vw, 40px); line-height: 1.08; letter-spacing: -.025em; max-width: 30ch;
}
html[lang="ar"] .article-title { line-height: 1.45; letter-spacing: 0; }
.article-go {
  width: 52px; height: 52px; border-radius: 50%; border: 1px solid var(--ink);
  display: grid; place-items: center; font-size: 20px; transition: background .25s, color .25s;
}
.article:hover .article-go { background: var(--ink); color: var(--paper); }
.article:hover .article-go .arrow { transform: translateX(3px); }
html[dir="rtl"] .article:hover .article-go .arrow { transform: scaleX(-1) translateX(3px); }

/* ==========================================================================
   Contact + footer
   ========================================================================== */

.contact { background: var(--ink); color: var(--paper); padding: clamp(100px, 11vw, 180px) var(--gutter) clamp(80px, 8vw, 120px); }
.contact-title {
  margin: 0 0 clamp(48px, 6vw, 100px);
  font-family: var(--f-display); font-weight: 800;
  font-size: clamp(60px, 12vw, 210px); line-height: .84; letter-spacing: -.055em;
}
.contact-title em { color: var(--accent); }
html[lang="ar"] .contact-title { line-height: 1.15; letter-spacing: 0; }

.contact-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: clamp(40px, 6vw, 120px); }
.contact-lede { margin: 0 0 40px; max-width: 30ch; font-family: var(--f-display); font-weight: 500; font-size: clamp(21px, 1.9vw, 30px); line-height: 1.2; letter-spacing: -.015em; }
html[lang="ar"] .contact-lede { line-height: 1.6; letter-spacing: 0; }
.contact-info dl { margin: 0; display: grid; gap: 0; }
.contact-info dl > div { display: grid; grid-template-columns: 120px 1fr; gap: 16px; padding: 14px 0; border-top: 1px solid var(--line-dark); }
.contact-info dt { color: rgba(238, 236, 230, .5); padding-top: 3px; }
.contact-info dd { margin: 0; font-size: 18px; }
.contact-info dd a { border-bottom: 1px solid transparent; transition: border-color .2s; unicode-bidi: isolate; }
.contact-info dd a:hover { border-color: var(--accent); }

.contact-form { display: grid; gap: 26px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 26px; }
.field { display: grid; gap: 6px; }
.field .label { color: rgba(238, 236, 230, .55); }
.field input, .field select, .field textarea {
  width: 100%; background: transparent; color: var(--paper);
  border: 0; border-bottom: 1px solid rgba(238, 236, 230, .3); border-radius: 0;
  padding: 10px 0 12px; font-family: var(--f-body); font-size: 19px;
  transition: border-color .2s; -webkit-appearance: none; appearance: none;
}
.field textarea { resize: vertical; min-height: 110px; }
.field select {
  cursor: pointer; padding-inline-end: 28px;
  background-image: linear-gradient(45deg, transparent 50%, var(--paper) 50%), linear-gradient(135deg, var(--paper) 50%, transparent 50%);
  background-position: calc(100% - 12px) 55%, calc(100% - 6px) 55%;
  background-size: 6px 6px; background-repeat: no-repeat;
}
html[dir="rtl"] .field select { background-position: 6px 55%, 12px 55%; }
.field select option { color: var(--ink); background: var(--paper); }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--accent); }
.form-foot { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; margin-top: 8px; }
.form-note { color: rgba(238, 236, 230, .45); }
.form-note.sent { color: var(--accent); }
.form-note.error { color: #FF8A6B; }
.contact-form button[disabled] { opacity: .6; cursor: progress; }
.field [aria-invalid="true"] { border-color: #FF8A6B; }
/* Honeypot: invisible without off-screen offsets (a big left offset creates sideways scrolling in Arabic/RTL) */
.hp { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0; }

.site-footer { background: var(--ink); color: var(--paper); padding: 0 var(--gutter) 24px; overflow: hidden; }
.wordmark--footer { color: var(--paper); padding-top: clamp(28px, 4vw, 64px); border-top: 1px solid var(--line-dark); }
.footer-bar { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 22px; color: rgba(238, 236, 230, .55); }
.footer-links { display: flex; gap: 22px; }
.footer-links a:hover { color: var(--paper); }

/* ==========================================================================
   Reel lightbox
   ========================================================================== */

.reel {
  position: fixed; inset: 0; z-index: 100; background: #050505; color: var(--paper);
  display: grid; grid-template-rows: auto 1fr auto; padding: 18px var(--gutter);
}
.reel[hidden] { display: none; }
.reel-progress { position: absolute; inset: 0 0 auto 0; height: 2px; background: rgba(255,255,255,.1); }
.reel-progress span { display: block; height: 100%; width: 0; background: var(--accent); }
.reel-progress span.run { animation: progress var(--dur, 2600ms) linear forwards; }
@keyframes progress { to { width: 100%; } }
.reel-top, .reel-bottom { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.reel-img { justify-self: center; align-self: center; max-height: calc(100vh - 160px); max-width: 100%; width: auto; object-fit: contain; border-radius: 4px; animation: reelIn .6s var(--ease); }
@keyframes reelIn { from { opacity: 0; transform: scale(.985); } }
.reel-cap { font-family: var(--f-display); font-weight: 600; font-size: clamp(20px, 2vw, 30px); letter-spacing: -.02em; }
.reel-nav { display: flex; gap: 8px; }
body.reel-open { overflow: hidden; }

/* ==========================================================================
   Scroll reveal
   ========================================================================== */

html.js .reveal { opacity: 0; transform: translateY(26px); transition: opacity 1s var(--ease), transform 1s var(--ease); }
html.js .reveal.in { opacity: 1; transform: none; }

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 1180px) {
  .header-note { display: none; }
}

@media (max-width: 960px) {
  .nav-main, .nav-cta { display: none; }
  .menu-btn { display: inline-flex; }
  .site-header { grid-template-columns: auto 1fr auto; }
  .header-center { order: -1; justify-items: start; }
  .nav-actions { grid-column: 3; }

  .hero { padding-top: 84px; }
  .hero-meta { grid-template-columns: 1fr; }
  .hero-side { align-items: center; }

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

  .svc summary { grid-template-columns: 40px minmax(0, 1fr) auto; }
  .svc-body { grid-template-columns: 1fr; padding-inline-start: 56px; }
  .svc-body > :first-child { grid-column: auto; }
  .svc-icon { width: 38px; height: 38px; }

  .ai { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .numbers { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .num:nth-child(3) { border-inline-start: 0; }
  .num:nth-child(n+3) { border-top: 1px solid var(--line); }
}

@media (max-width: 640px) {
  .hero-side { flex-direction: column; align-items: flex-start; }
  .strip-item { height: 62vw; min-height: 260px; }
  .statement-foot { flex-direction: column; align-items: flex-start; }
  .ii { grid-template-columns: 1fr; }

  .svc-body { padding-inline-start: 0; }

  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 10px; }
  .tile, .tile[data-size="3"] { grid-column: span 1; }
  .tile[data-size="3"] .tile-media { aspect-ratio: 4 / 5; }
  .tile.is-wide { grid-column: span 2; }
  .tile.is-wide .tile-media { aspect-ratio: 1 / 1; }
  .tile-info { flex-direction: column; gap: 6px; }
  .tile-tags { text-align: start; display: flex; gap: 10px; }
  .tile-sub { font-size: 14px; }

  .article { grid-template-columns: minmax(0, 1fr) auto; }
  .article-thumb { display: none; }
  .article-go { width: 42px; height: 42px; }

  .logo-marquee { --logo-scale: .68; }
  .client-logo { height: 64px; padding-inline: 20px; }

  .field-row { grid-template-columns: 1fr; }
  .contact-info dl > div { grid-template-columns: 96px 1fr; }
  .footer-bar { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
  html.js .hero .wordmark .g { transform: none; }
  .logo-marquee { -webkit-mask-image: none; mask-image: none; }
  .logo-track { animation: none !important; width: auto; flex-wrap: wrap; justify-content: center; }
  .client-logo.dup { display: none; }
  html.js .reveal { opacity: 1; transform: none; }
}
