/* YAKZEN — black, white, and a single red seal */
:root {
  --bg: #0a0a0a;
  --bg-2: #111111;
  --card: #141414;
  --ink: #f3f2ef;
  --mute: #8d8b87;
  --dim: #5a5956;
  --line: rgba(255, 255, 255, .09);
  --line-2: rgba(255, 255, 255, .18);
  --accent: #8b3dff;
  --accent-soft: rgba(139, 61, 255, .14);

  --f-ar: 'Alexandria', 'Manrope', system-ui, sans-serif;
  --f-en: 'Manrope', 'Alexandria', system-ui, sans-serif;
  --f-display: 'Syncopate', 'Manrope', sans-serif;
  --f-jp: 'Noto Serif JP', serif;
  --f-body: var(--f-ar);

  --pad: clamp(16px, 5vw, 72px);
  --max: 1320px;
  --r: 18px;
  --ease: cubic-bezier(.2, .8, .2, 1);
}
html[lang="en"] { --f-body: var(--f-en); }

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--f-body);
  font-size: 16px;
  line-height: 1.7;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
body.is-loading { overflow: hidden; }
img, svg, canvas { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
::selection { background: var(--accent); color: #fff; }

/* grain */
body::after {
  content: ''; position: fixed; inset: 0; pointer-events: none; z-index: 90; opacity: .05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.red { color: var(--accent); }
.muted { color: var(--mute); }
.small { font-size: 14px; }

/* ---------- seal (red kanji stamp) ---------- */
.seal {
  display: inline-flex; flex-direction: column; align-items: center; justify-content: center;
  border: 2px solid var(--accent); color: var(--accent);
  font-family: var(--f-jp); font-weight: 700; line-height: 1.05;
  width: 26px; height: 40px; font-size: 13px; flex: none;
}
.seal--lg { width: 52px; height: 80px; font-size: 26px; border-width: 3px; }

/* ---------- buttons ---------- */
.btn {
  --h: 54px;
  display: inline-flex; align-items: center; justify-content: center; gap: 12px;
  height: var(--h); padding-inline: 28px;
  border-radius: 999px; font-weight: 500; font-size: 15px; white-space: nowrap;
  transition: background .3s, color .3s, border-color .3s, transform .3s var(--ease);
}
.btn--sm { --h: 42px; padding-inline: 20px; font-size: 14px; }
.btn--block { width: 100%; }
.btn--red { background: var(--accent); color: #fff; }
.btn--accent:hover { background: #fff; color: #000; }
.btn--ghost { border: 1px solid var(--line-2); }
.btn--ghost:hover { border-color: var(--ink); background: var(--ink); color: #000; }
.btn:active { transform: scale(.97); }
.arr { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; transition: transform .3s var(--ease); }
[dir="rtl"] .arr { transform: scaleX(-1); }
.btn:hover .arr { transform: translateX(4px); }
[dir="rtl"] .btn:hover .arr { transform: scaleX(-1) translateX(4px); }

/* ---------- logo ---------- */
.yk-logo { display: block; width: 100%; height: auto; overflow: visible; color: var(--ink); }
.yk-logo text { direction: ltr; }
.yk-logo .lg-arabic { direction: rtl; }

/* ---------- intro ---------- */
.intro { position: fixed; inset: 0; z-index: 100; direction: ltr; }
.intro.is-fade { opacity: 0; transition: opacity .6s; }
.intro__half {
  position: absolute; inset: 0; overflow: hidden; will-change: transform;
  background:
    radial-gradient(ellipse 70% 55% at 50% 50%, #161616, transparent 70%),
    repeating-linear-gradient(90deg, rgba(255,255,255,.025) 0 1px, transparent 1px 120px),
    var(--bg);
}
.intro__half--a { clip-path: polygon(0 0, 100% 0, 100% 46.1%, 0 54.5%); }   /* overlaps half b slightly so no seam shows */
.intro__half--b { clip-path: polygon(0 54.2%, 100% 45.8%, 100% 100%, 0 100%); }
.intro__stage { position: absolute; inset: 0; display: grid; place-items: center; }
.intro__logo { width: min(86vw, 1080px); opacity: 0; visibility: hidden; will-change: transform; }
.intro__flash {
  position: absolute; inset: 0; pointer-events: none; opacity: 0; visibility: hidden;
  background: radial-gradient(circle at 30% 50%, rgba(139, 61, 255, .7), transparent 55%);
}
.intro__slash {
  position: absolute; left: 0; top: 54.2%; height: 2px; pointer-events: none; background: #fff;
  transform-origin: 0 50%; transform: scaleX(0);
  box-shadow: 0 0 8px #8b3dff, 0 0 22px #8b3dff, 0 0 48px rgba(139, 61, 255, .6);
}
.intro__hud {
  position: absolute; inset-inline: 28px; bottom: 26px; display: flex; justify-content: space-between; align-items: flex-end;
  font: 400 11px/1 var(--f-display); letter-spacing: .3em; color: var(--mute);
}
.intro__count { font-size: 11px; }
.intro__count b { font: 700 clamp(28px, 4vw, 44px)/1 var(--f-display); color: var(--ink); letter-spacing: .04em; margin-right: 6px; }
.intro__skip {
  position: absolute; top: 22px; right: 24px; padding: 9px 16px; border: 1px solid var(--line-2); border-radius: 999px;
  font: 400 10px/1 var(--f-display); letter-spacing: .3em; color: var(--mute); transition: color .3s, border-color .3s;
}
.intro__skip:hover { color: var(--ink); border-color: var(--ink); }

.intro.gate-on .intro__hud, .intro.gate-on .intro__skip { opacity: 0; visibility: hidden; }
.intro__gate {
  position: absolute; inset: 0; z-index: 5; display: grid; place-content: center; justify-items: center; gap: 26px;
  opacity: 0; visibility: hidden; transition: opacity .8s var(--ease), visibility .8s;
}
.intro__gate.is-on { opacity: 1; visibility: visible; }
.intro__gate-seal {
  display: flex; flex-direction: column; align-items: center; padding: 12px 10px;
  border: 3px solid var(--accent); color: var(--accent); font: 700 34px/1.08 var(--f-jp);
  animation: breathe 2.8s ease-in-out infinite;
}
@keyframes breathe {
  0%, 100% { box-shadow: 0 0 0 rgba(139, 61, 255, 0); transform: scale(1); }
  50% { box-shadow: 0 0 40px rgba(139, 61, 255, .45); transform: scale(1.04); }
}
.intro__enter {
  display: inline-flex; align-items: center; gap: 12px; margin-top: 8px; padding: 15px 30px;
  border: 1px solid var(--accent); border-radius: 999px; color: var(--ink);
  font: 500 15px/1 var(--f-body); letter-spacing: .04em; transition: background .3s, box-shadow .3s;
}
.intro__enter svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.intro__enter:hover, .intro__enter:focus-visible { background: var(--accent); box-shadow: 0 0 40px rgba(139, 61, 255, .45); outline: none; }
.intro__silent { color: var(--mute); font: 400 13px/1 var(--f-body); padding: 8px; transition: color .3s; }
.intro__silent:hover { color: var(--ink); }

@keyframes rise { from { transform: translateY(24px); opacity: 0; } to { transform: none; opacity: 1; } }

/* ---------- sakura layer ---------- */
.petals { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 45; pointer-events: none; }

/* ---------- cursor ---------- */
.cursor {
  position: fixed; top: 0; left: 0; z-index: 95; pointer-events: none;
  width: 10px; height: 10px; border-radius: 50%; background: var(--accent);
  transform: translate(-50%, -50%); transition: width .25s, height .25s, background .25s, border-color .25s, opacity .25s; opacity: 0;
  border: 1.5px solid transparent;
}
.cursor.is-on { opacity: 1; }
.cursor.is-hover { width: 46px; height: 46px; background: rgba(139, 61, 255, .12); border-color: var(--accent); }
@media (hover: none) { .cursor { display: none; } }

/* ---------- header ---------- */
.header {
  position: fixed; inset: 0 0 auto; z-index: 50;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 18px var(--pad);
  transition: background .4s, padding .4s, border-color .4s, transform .7s var(--ease); border-bottom: 1px solid transparent;
}
.header.is-scrolled {
  background: rgba(10, 10, 10, .72); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  padding-block: 12px; border-color: var(--line);
}
.brand { display: flex; align-items: center; }
.brand__logo { display: block; width: 168px; }
.nav { display: flex; gap: 34px; font-size: 15px; }
.nav a { position: relative; color: var(--mute); transition: color .3s; }
.nav a:hover, .nav a.is-active { color: var(--ink); }
.nav a::after {
  content: ''; position: absolute; inset-inline-start: 0; bottom: -6px; width: 100%; height: 1px;
  background: var(--accent); transform: scaleX(0); transform-origin: var(--origin, right); transition: transform .4s var(--ease);
}
[dir="ltr"] .nav a::after { --origin: left; }
.nav a:hover::after, .nav a.is-active::after { transform: scaleX(1); }
.nav__cta-mobile { display: none; }
.header__actions { display: flex; align-items: center; gap: 12px; }
.lang {
  width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--line-2);
  font-weight: 700; font-size: 14px; transition: border-color .3s, background .3s, color .3s;
}
.lang:hover { background: var(--ink); color: #000; }
.burger { display: none; width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--line-2); position: relative; }
.burger i { position: absolute; left: 12px; right: 12px; height: 1.5px; background: var(--ink); transition: transform .35s var(--ease), top .35s var(--ease); }
.burger i:first-child { top: 16px; } .burger i:last-child { top: 24px; }
.burger[aria-expanded="true"] i:first-child { top: 20px; transform: rotate(45deg); }
.burger[aria-expanded="true"] i:last-child { top: 20px; transform: rotate(-45deg); }

/* ---------- hero ---------- */
.hero {
  position: relative; min-height: 100svh; overflow: hidden;
  display: flex; flex-direction: column; justify-content: center;
  padding: 120px var(--pad) 120px;
}
.hero__canvas { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; touch-action: pan-y; }
[data-hero="ryu"] .hero__canvas { display: none; }
/* the site dragon: behind the hero text, raised over everything for the intro pass and the bite */
.ryu { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 1; pointer-events: none; opacity: 0; }
.ryu.is-over { z-index: 108; }
.bite { position: fixed; inset: 0; z-index: 110; pointer-events: none; visibility: hidden; opacity: 0; }
.bite__jaw { position: absolute; left: 0; right: 0; height: 50.5%; display: flex; flex-direction: column; transform: translateY(-100%); }
.bite__jaw--top { top: 0; }
.bite__jaw--bot { bottom: 0; transform: translateY(100%); }
.bite__jaw i { flex: 1; background: radial-gradient(120% 90% at 50% 100%, #3a1260, #12061f 60%, #050208); }
.bite__jaw--bot i { background: radial-gradient(120% 90% at 50% 0%, #3a1260, #12061f 60%, #050208); }
.bite__jaw svg { position: absolute; z-index: 1; left: 0; width: 100%; height: clamp(46px, 9vh, 110px); filter: drop-shadow(0 0 14px rgba(139,61,255,.55)); }
.bite__jaw--top svg { top: 100%; }
.bite__jaw--bot svg { bottom: 100%; }
.hero.is-grab { cursor: grab; }
.hero.is-dragging { cursor: grabbing; user-select: none; }
.hero__fallback {
  position: absolute; z-index: 0; width: min(60vw, 560px); aspect-ratio: 1; border-radius: 50%;
  inset-inline-end: 6%; top: 50%; transform: translateY(-50%);
  background: radial-gradient(circle at 35% 30%, #2a2a2a, #050505 62%), #000;
  box-shadow: inset -30px -20px 80px rgba(139, 61, 255, .35), 0 0 120px rgba(139, 61, 255, .12);
  opacity: 0; transition: opacity .6s;
}
.no-webgl .hero__fallback { opacity: 1; }
.hero::before {
  content: ''; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background:
    linear-gradient(to bottom, transparent 70%, var(--bg)),
    linear-gradient(to var(--fade-dir, left), var(--bg) 0%, rgba(10, 10, 10, .75) 30%, transparent 60%);
}
[dir="ltr"] .hero::before { --fade-dir: right; }
.hero__kanji {
  position: absolute; z-index: 1; inset-inline-start: calc(var(--pad) - 4px); top: 110px;
  writing-mode: vertical-rl; font: 700 14px/1 var(--f-jp); color: var(--accent); letter-spacing: .6em; opacity: .9;
  display: none;
}
.hero__inner { position: relative; z-index: 2; max-width: 720px; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px; margin: 0 0 26px;
  font-size: 13px; letter-spacing: .14em; text-transform: uppercase; color: var(--mute);
}
.sq { width: 8px; height: 8px; background: var(--accent); display: inline-block; }
.hero__title {
  margin: 0 0 28px; font-weight: 700; line-height: 1.05;
  font-size: clamp(46px, 8.4vw, 124px); letter-spacing: -.02em;
}
html[lang="en"] .hero__title { font-size: clamp(40px, 6vw, 92px); letter-spacing: -.035em; }
html[lang="en"] .hero__inner { max-width: 980px; }
@media (min-width: 900px) { .hero__title .line { white-space: nowrap; } }
.hero__title .line { display: block; overflow: hidden; padding-bottom: .06em; }
.hero__title .line > * { display: inline-block; }
.hero__title em { font-style: normal; color: var(--accent); }
.is-ready .hero__title .line > * { animation: up 1.1s var(--ease) both; }
.is-ready .hero__title .line:nth-child(2) > * { animation-delay: .12s; }
@keyframes up { from { transform: translateY(105%); } to { transform: none; } }
.hero__lead { max-width: 520px; margin: 0 0 40px; font-size: clamp(16px, 1.4vw, 19px); color: #c9c7c2; }
.hero__btns { display: flex; flex-wrap: wrap; gap: 14px; }
.is-ready .hero__lead, .is-ready .hero__btns, .is-ready .eyebrow { animation: rise 1s .35s var(--ease) both; }

.hero__foot {
  position: absolute; z-index: 2; bottom: 34px; inset-inline: var(--pad);
  display: flex; align-items: center; gap: 16px; direction: ltr;
  font: 400 12px/1 var(--f-display); letter-spacing: .4em; color: var(--mute);
}
[dir="rtl"] .hero__foot { flex-direction: row-reverse; }
.hero__foot i { width: 6px; height: 6px; background: var(--accent); }
.hero__hint { margin-inline-start: auto; font-family: var(--f-body); letter-spacing: .04em; font-size: 13px; direction: initial; }
[dir="rtl"] .hero__hint { margin-inline-start: 0; margin-inline-end: auto; direction: rtl; }
.scroll-cue {
  position: absolute; z-index: 2; bottom: 28px; left: 50%; transform: translateX(-50%);
  width: 1px; height: 52px; background: var(--line);
}
.scroll-cue span { position: absolute; inset: 0 0 auto; height: 18px; background: var(--accent); animation: cue 2s var(--ease) infinite; }
@keyframes cue { 0% { transform: translateY(0); opacity: 0; } 30% { opacity: 1; } 100% { transform: translateY(40px); opacity: 0; } }

/* ---------- marquee ---------- */
.marquee { border-block: 1px solid var(--line); overflow: hidden; padding: 22px 0; direction: ltr; }
.marquee__track { display: flex; align-items: center; gap: 40px; width: max-content; animation: marq 36s linear infinite; }
.marquee span { font: 700 clamp(18px, 2.4vw, 30px)/1 var(--f-display); letter-spacing: .12em; white-space: nowrap; }
.marquee span:nth-of-type(5n) { font-family: var(--f-jp); color: var(--accent); letter-spacing: .2em; }
.marquee b { width: 10px; height: 10px; background: var(--accent); flex: none; }
@keyframes marq { to { transform: translateX(-50%); } }

/* ---------- sections ---------- */
.section { position: relative; padding: clamp(90px, 12vw, 160px) var(--pad); max-width: calc(var(--max) + var(--pad) * 2); margin-inline: auto; }
.sec-head {
  display: flex; align-items: center; gap: 16px; margin-bottom: 36px;
  font: 400 12px/1 var(--f-display); letter-spacing: .3em; color: var(--mute);
}
.sec-head::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.sec-num {                     /* hanko seal */
  color: var(--accent); border: 1.5px solid var(--accent); padding: 7px 6px 6px 8px; line-height: 1;
  display: inline-block;
}
.h2 { margin: 0 0 24px; font-weight: 700; line-height: 1.1; font-size: clamp(36px, 5.6vw, 76px); letter-spacing: -.02em; }
html[lang="en"] .h2 { letter-spacing: -.035em; }
.lead { font-size: clamp(17px, 1.5vw, 20px); color: #cfcdc8; margin: 0 0 18px; }

/* reveal */
.rv { opacity: 0; transform: translateY(40px); transition: opacity 1s var(--ease), transform 1s var(--ease); }
.rv.is-in { opacity: 1; transform: none; }

/* ---------- studio ---------- */
.studio__grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(40px, 6vw, 100px); align-items: start; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 46px; padding-top: 34px; border-top: 1px solid var(--line); }
.stat { direction: ltr; text-align: start; }
[dir="rtl"] .stat { text-align: right; }
.stat b, .stat > span { font: 700 clamp(34px, 4vw, 56px)/1 var(--f-display); }
.stat > span { color: var(--accent); }
.stat small { display: block; margin-top: 10px; font-size: 13px; color: var(--mute); direction: initial; line-height: 1.5; }
[dir="rtl"] .stat small { direction: rtl; }

.founders { display: grid; gap: 18px; }
.founder {
  position: relative; overflow: hidden; border: 1px solid var(--line); border-radius: var(--r);
  background: var(--card); padding: 30px; display: grid; grid-template-columns: auto 1fr; gap: 24px; align-items: center;
  transition: border-color .4s, transform .5s var(--ease);
}
.founder:hover { border-color: var(--line-2); transform: translateY(-4px); }
.founder__mono {
  width: 96px; height: 96px; border-radius: 50%; display: grid; place-items: center; position: relative;
  font: 700 26px/1 var(--f-display); letter-spacing: .06em;
  background: radial-gradient(circle at 30% 25%, #2b2b2b, #0b0b0b 70%);
  box-shadow: inset 0 0 0 1px var(--line-2);
}
.founder__mono::after { content: ''; position: absolute; inset: -6px; border-radius: 50%; border: 1px solid var(--accent); border-color: var(--accent) transparent transparent; animation: spin 6s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.founder h3 { margin: 0; font-size: 22px; line-height: 1.3; }
.founder__role { margin: 4px 0 14px; color: var(--mute); font-size: 15px; }
.founder__years { position: absolute; inset-block-start: 22px; inset-inline-end: 24px; text-align: center; line-height: 1; }
.founder__years b { display: block; font: 700 30px/1 var(--f-display); color: var(--accent); }
.founder__years small { font-size: 11px; color: var(--mute); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; direction: ltr; }
[dir="rtl"] .chips { justify-content: flex-end; }
.chips span { font-size: 12px; padding: 5px 12px; border: 1px solid var(--line-2); border-radius: 999px; color: #bdbbb6; }

/* ---------- services ---------- */
.services__grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; margin-top: 40px; }
.svc {
  position: relative; overflow: hidden; border: 1px solid var(--line); border-radius: var(--r); background: var(--card);
  padding: clamp(28px, 3vw, 44px); min-height: 300px; display: flex; flex-direction: column;
  transition: border-color .4s, background .4s;
}
.svc::before {
  content: ''; position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity .5s;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 50%), rgba(139, 61, 255, .16), transparent 60%);
}
.svc:hover { border-color: var(--line-2); }
.svc:hover::before { opacity: 1; }
.svc--featured { border-color: rgba(139, 61, 255, .45); background: linear-gradient(160deg, #1a0d0e, var(--card) 55%); }
.svc__top { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: auto; }
.svc__icon { width: 54px; height: 54px; stroke: var(--ink); fill: none; stroke-width: 1.2; }
.svc__icon .r { stroke: var(--accent); }
/* craft icons: each one has its own small idle loop, faster on hover */
.svc__icon * { transform-box: fill-box; transform-origin: center; }
.ic-code { stroke-dasharray: 1; animation: ic-draw 3.2s var(--ease) infinite; }
.ic-blink { animation: ic-blink 1.6s steps(1) infinite; }
.ic-spin { transform-box: view-box; transform-origin: 28px 28px; animation: ic-wobble 5s ease-in-out infinite; }
.ic-edge { stroke-dasharray: 1; animation: ic-draw 4s var(--ease) infinite; }
.ic-beam { animation: ic-beam 2.4s ease-in-out infinite; transform-origin: top; }
.ic-ring { stroke-dasharray: 1; animation: ic-draw 4.5s var(--ease) infinite; transform: rotate(-90deg); }
.ic-stamp { animation: ic-stamp 4.5s var(--ease) infinite; }
.ic-core { animation: ic-pulse 2s ease-in-out infinite; }
.svc:hover .svc__icon * { animation-duration: 1.4s; }
@keyframes ic-draw { 0% { stroke-dashoffset: 1; } 45%, 80% { stroke-dashoffset: 0; } 100% { stroke-dashoffset: -1; } }
@keyframes ic-blink { 50% { opacity: 0; } }
@keyframes ic-wobble { 0%, 100% { transform: rotate(0); } 25% { transform: rotate(-6deg); } 75% { transform: rotate(6deg); } }
@keyframes ic-beam { 0%, 100% { transform: scaleY(1); opacity: 1; } 50% { transform: scaleY(.3); opacity: .4; } }
@keyframes ic-stamp { 0%, 40% { transform: translateY(-6px) scale(1.3); opacity: 0; } 55% { transform: none; opacity: 1; } 60% { transform: scale(.9); } 68%, 100% { transform: none; opacity: 1; } }
@keyframes ic-pulse { 50% { transform: scale(1.12); } }
.svc__num { font: 400 13px/1 var(--f-display); color: var(--dim); letter-spacing: .2em; }
.svc__badge { font-size: 12px; color: var(--accent); border: 1px solid rgba(139, 61, 255, .5); border-radius: 999px; padding: 4px 12px; }
.svc h3 { margin: 50px 0 10px; font-size: clamp(22px, 2.2vw, 30px); line-height: 1.25; }
.svc p { margin: 0 0 22px; color: var(--mute); max-width: 460px; }

/* ---------- work ---------- */
.work__top { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; flex-wrap: wrap; margin-bottom: 40px; }
.work__top .h2 { margin: 0; }
.filters { display: flex; gap: 6px; padding: 5px; border: 1px solid var(--line); border-radius: 999px; }
.filters button { padding: 8px 18px; border-radius: 999px; font-size: 14px; color: var(--mute); transition: background .3s, color .3s; }
.filters button:hover { color: var(--ink); }
.filters button.is-on { background: var(--ink); color: #000; }
.work__grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 18px; }
.proj { grid-column: span 2; cursor: pointer; text-align: start; transition: opacity .45s, transform .45s var(--ease); }
.proj:nth-child(4n + 1), .proj:nth-child(4n + 2) { grid-column: span 3; }
.proj.is-hidden { display: none; }
.proj__art {
  position: relative; overflow: hidden; border-radius: var(--r); border: 1px solid var(--line); aspect-ratio: 4 / 3; background: #0d0d0d;
}
.proj:nth-child(4n + 1) .proj__art, .proj:nth-child(4n + 2) .proj__art { aspect-ratio: 16 / 10; }
.proj__art svg { position: absolute; inset: 0; width: 100%; height: 100%; transition: transform 1.1s var(--ease); }
.proj:hover .proj__art svg { transform: scale(1.06); }
.proj__view {
  position: absolute; inset-block-end: 18px; inset-inline-end: 18px; z-index: 2;
  background: var(--ink); color: #000; border-radius: 999px; padding: 8px 18px; font-size: 13px; font-weight: 500;
  transform: translateY(14px); opacity: 0; transition: transform .45s var(--ease), opacity .45s;
}
.proj:hover .proj__view, .proj:focus-visible .proj__view { transform: none; opacity: 1; }
.proj__tag {
  position: absolute; inset-block-start: 16px; inset-inline-start: 16px; z-index: 2;
  font-size: 11px; letter-spacing: .06em; padding: 4px 10px; border-radius: 999px;
  background: rgba(0, 0, 0, .55); border: 1px solid var(--line-2); color: #cfcdc8; backdrop-filter: blur(6px);
}
.proj__meta { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 16px 4px 0; }
.proj__meta h3 { margin: 0; font-size: 20px; }
.proj__meta p { margin: 0; color: var(--mute); font-size: 14px; }
.proj__meta span { font: 400 12px/1 var(--f-display); color: var(--dim); letter-spacing: .1em; }

/* ---------- process ---------- */
.steps { list-style: none; margin: 50px 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; counter-reset: s; position: relative; }
.steps::before { content: ''; position: absolute; top: 22px; inset-inline: 0; height: 1px; background: var(--line); }
.steps::after {
  content: ''; position: absolute; top: 22px; inset-inline-start: 0; height: 1px; width: 100%; background: var(--accent);
  transform: scaleX(var(--p, 0)); transform-origin: var(--origin, right); transition: transform 1.6s var(--ease);
}
[dir="ltr"] .steps::after { --origin: left; }
.steps.is-in { --p: 1; }
.step { position: relative; padding-inline-end: 28px; counter-increment: s; }
.step__dot {
  position: relative; z-index: 1; width: 45px; height: 45px; border-radius: 50%; background: var(--bg);
  border: 1px solid var(--line-2); display: grid; place-items: center; margin-bottom: 26px;
  font: 400 12px/1 var(--f-display); transition: background .4s, border-color .4s;
}
.steps.is-in .step__dot { border-color: var(--accent); }
.step:hover .step__dot { background: var(--accent); }
.step h3 { margin: 0 0 8px; font-size: 24px; }
.step p { margin: 0; color: var(--mute); font-size: 15px; }

/* ---------- pricing ---------- */
.plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 46px; align-items: stretch; }
.plan {
  position: relative; border: 1px solid var(--line); border-radius: var(--r); background: var(--card);
  padding: 36px 30px 30px; display: flex; flex-direction: column;
}
.plan--featured { border-color: var(--accent); background: linear-gradient(180deg, #1a0c0d, var(--card) 45%); }
.plan__badge {
  position: absolute; top: -13px; inset-inline-start: 28px; background: var(--accent); color: #fff;
  font-size: 12px; padding: 4px 14px; border-radius: 999px;
}
.plan h3 { margin: 0; font: 700 24px/1.2 var(--f-body); }
.plan__en { font: 400 11px/1 var(--f-display); letter-spacing: .25em; color: var(--dim); margin: 8px 0 4px; display: block; }
.plan__sub { color: var(--mute); margin: 0 0 26px; font-size: 15px; }
.plan__price { padding: 22px 0; border-block: 1px solid var(--line); margin-bottom: 24px; }
.plan__price small { display: block; color: var(--mute); font-size: 13px; }
.plan__price b { font: 700 46px/1.1 var(--f-display); direction: ltr; display: inline-block; }
.plan__price b sup { font-size: .45em; color: var(--accent); margin-inline-end: 4px; vertical-align: top; position: relative; top: .5em; }
.plan ul { list-style: none; margin: 0 0 30px; padding: 0; display: grid; gap: 12px; }
.plan li { display: flex; gap: 12px; font-size: 15px; color: #d4d2cd; }
.plan li::before { content: ''; flex: none; width: 6px; height: 6px; background: var(--accent); margin-top: .75em; }
.plan .btn { margin-top: auto; }

/* ---------- contact / booking ---------- */
.contact__grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(40px, 6vw, 90px); align-items: start; }
.channels { list-style: none; margin: 40px 0 0; padding: 0; border-top: 1px solid var(--line); }
.channels a {
  display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 22px 4px; border-bottom: 1px solid var(--line);
  transition: padding .4s var(--ease), color .3s;
}
.channels a:hover { padding-inline-start: 14px; color: var(--accent); }
.channels small { color: var(--mute); font-size: 13px; display: block; }
.channels strong { font-weight: 500; font-size: 18px; direction: ltr; display: inline-block; }
.channels .arr { flex: none; }

.booking {
  position: relative; border: 1px solid var(--line); border-radius: calc(var(--r) + 6px); background: var(--card);
  padding: clamp(22px, 3vw, 36px); display: grid; gap: 30px;
}
.booking__label { display: flex; align-items: center; gap: 12px; margin: 0 0 16px; font-weight: 500; }
.booking__label > span:first-child {
  width: 26px; height: 26px; border-radius: 50%; border: 1px solid var(--accent); color: var(--accent);
  display: grid; place-items: center; font: 400 11px/1 var(--f-display);
}
.booking__label small { color: var(--accent); font-weight: 400; margin-inline-start: auto; font-size: 14px; }

.cal { border: 1px solid var(--line); border-radius: 14px; padding: 16px; }
.cal__head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.cal__nav { width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line); display: grid; place-items: center; transition: background .3s; }
.cal__nav:hover:not(:disabled) { background: var(--ink); color: #000; }
.cal__nav:disabled { opacity: .3; cursor: default; }
.cal__nav svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; }
[dir="rtl"] .cal__nav svg { transform: scaleX(-1); }
.cal__dow, .cal__days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; text-align: center; }
.cal__dow span { font-size: 12px; color: var(--dim); padding: 6px 0; }
.cal__days button {
  height: 42px; border-radius: 10px; font-size: 14px; transition: background .25s, color .25s; font-variant-numeric: tabular-nums;
}
.cal__days button:not(:disabled):hover { background: var(--accent-soft); color: var(--ink); }
.cal__days button:disabled { color: #333; cursor: default; text-decoration: line-through; text-decoration-color: #2a2a2a; }
.cal__days button.is-today { box-shadow: inset 0 0 0 1px var(--line-2); }
.cal__days button.is-sel { background: var(--accent); color: #fff; }

.slots { display: flex; flex-wrap: wrap; gap: 8px; }
.slots button {
  padding: 10px 18px; border: 1px solid var(--line-2); border-radius: 999px; font-size: 14px; direction: ltr;
  transition: background .25s, border-color .25s, color .25s;
}
.slots button:hover { border-color: var(--ink); }
.slots button.is-sel { background: var(--ink); color: #000; border-color: var(--ink); }

.fields { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.field { position: relative; display: block; }
.field--full { grid-column: 1 / -1; }
.field input, .field textarea, .field select {
  width: 100%; background: #0e0e0e; border: 1px solid var(--line); border-radius: 12px;
  padding: 24px 16px 10px; outline: none; transition: border-color .3s; resize: vertical; min-height: 58px;
}
.field select { padding: 0 16px; appearance: none; -webkit-appearance: none; cursor: pointer; }
.field--select::after {
  content: ''; position: absolute; inset-inline-end: 18px; top: 50%; width: 8px; height: 8px; margin-top: -6px;
  border-right: 1.5px solid var(--mute); border-bottom: 1.5px solid var(--mute); transform: rotate(45deg); pointer-events: none;
}
.field input:focus, .field textarea:focus, .field select:focus { border-color: var(--accent); }
.field > span {
  position: absolute; inset-inline-start: 17px; top: 18px; color: var(--mute); pointer-events: none; font-size: 15px;
  transition: top .25s var(--ease), font-size .25s var(--ease), color .25s;
}
.field input:focus + span, .field input:not(:placeholder-shown) + span,
.field textarea:focus + span, .field textarea:not(:placeholder-shown) + span { top: 7px; font-size: 11px; color: var(--accent); }
.field.is-err input, .field.is-err select { border-color: var(--accent); }
.booking__err { margin: -12px 0 -10px; color: var(--accent); font-size: 14px; min-height: 1em; }
.booking__err:empty { display: none; }

.booking__done {
  position: absolute; inset: 0; border-radius: inherit; background: var(--card); z-index: 3;
  display: grid; place-content: center; justify-items: center; text-align: center; gap: 6px; padding: 30px;
  animation: rise .7s var(--ease) both;
}
.booking__done[hidden] { display: none; }
.booking__done h3 { margin: 18px 0 0; font-size: 30px; }
.booking__done p { max-width: 360px; margin: 0 0 18px; }

/* ---------- footer ---------- */
.footer { border-top: 1px solid var(--line); padding: 0 var(--pad) 30px; overflow: hidden; }
.footer__logo { width: min(760px, 100%); margin: clamp(50px, 8vw, 100px) auto clamp(40px, 6vw, 70px); }
.footer__row { display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; font-size: 14px; color: var(--mute); }
.footer__row p { margin: 0; }
.footer__tri { display: flex; align-items: center; gap: 12px; font: 400 11px/1 var(--f-display) !important; letter-spacing: .35em; direction: ltr; }
.footer__tri i { width: 5px; height: 5px; background: var(--accent); }
.footer__top:hover { color: var(--ink); }

/* ---------- modal ---------- */
.modal { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: 16px; }
.modal[hidden] { display: none; }
.modal__backdrop { position: absolute; inset: 0; background: rgba(0, 0, 0, .75); backdrop-filter: blur(8px); animation: fade .4s both; }
.modal__card {
  position: relative; width: min(860px, 100%); max-height: calc(100svh - 32px); overflow: auto;
  overscroll-behavior: contain; -webkit-overflow-scrolling: touch;
  background: var(--bg-2); border: 1px solid var(--line-2); border-radius: 22px; animation: rise .55s var(--ease) both;
}
.modal__art { position: relative; aspect-ratio: 16 / 9; }
.modal__art svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.modal__body { padding: clamp(22px, 4vw, 40px); }
.modal__body h3 { margin: 0 0 12px; font-size: clamp(28px, 4vw, 42px); line-height: 1.15; }
.modal__body .eyebrow { margin-bottom: 14px; }
.modal__meta { display: flex; flex-wrap: wrap; gap: 30px; align-items: center; margin-top: 26px; padding-top: 22px; border-top: 1px solid var(--line); }
.modal__meta small { display: block; color: var(--dim); font-size: 12px; }
.modal__x {
  position: absolute; z-index: 2; top: 14px; inset-inline-end: 14px; width: 42px; height: 42px; border-radius: 50%;
  background: rgba(0, 0, 0, .6); border: 1px solid var(--line-2); font-size: 22px; line-height: 1;
}
.modal__x:hover { background: var(--accent); }
@keyframes fade { from { opacity: 0; } }

/* ---------- motion (js/motion.js) ---------- */
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }
.motion .rv { opacity: 1; transform: none; transition: none; }   /* GSAP drives reveals instead */
.header.is-hidden { transform: translateY(-110%); }

.section { isolation: isolate; }
.sec-kanji {
  position: absolute; z-index: -1; top: clamp(70px, 9vw, 130px); inset-inline-end: calc(var(--pad) * .35);
  writing-mode: vertical-rl; font: 700 clamp(120px, 17vw, 260px)/1 var(--f-jp);
  color: transparent; -webkit-text-stroke: 1px rgba(255, 255, 255, .09); pointer-events: none; user-select: none;
}
.section--light .sec-kanji { -webkit-text-stroke-color: rgba(13, 11, 20, .09); }

.sec-head::after { transform-origin: left; }
[dir="rtl"] .sec-head::after { transform-origin: right; }
.motion .sec-head::after { transform: scaleX(0); transition: transform 1.4s var(--ease); }
.motion .sec-head.is-drawn::after { transform: scaleX(1); }

.h2 { position: relative; width: fit-content; }
.ink-text { display: inline; }
.ink-bar {
  position: absolute; inset: .06em -.12em; z-index: 1; pointer-events: none;
  background: var(--accent); border-radius: 3px; transform: scaleX(0);
}

.shoji {
  position: absolute; top: 0; bottom: 0; width: 50.5%; z-index: 3; pointer-events: none;
  background:
    repeating-linear-gradient(90deg, transparent 0 46px, rgba(255, 255, 255, .06) 46px 48px),
    repeating-linear-gradient(0deg, transparent 0 46px, rgba(255, 255, 255, .06) 46px 48px),
    #131118;
}
.shoji--a { left: 0; border-right: 2px solid rgba(139, 61, 255, .55); }
.shoji--b { right: 0; border-left: 2px solid rgba(139, 61, 255, .55); }

.motion .steps::after { transform: scaleX(var(--sp, 0)); transition: none; }

.enso {
  position: absolute; z-index: -1; width: clamp(260px, 34vw, 520px); top: clamp(40px, 6vw, 90px); inset-inline-end: 4%;
  fill: none; stroke: var(--accent); stroke-width: 7; stroke-linecap: round; opacity: .32; pointer-events: none;
}
.enso path { stroke-dasharray: 1000; stroke-dashoffset: 0; }
.process .sec-kanji { inset-inline-end: auto; inset-inline-start: calc(var(--pad) * .35); }

/* ---------- white sections ---------- */
.section--light {
  --bg: #f6f4fb; --card: #ffffff; --ink: #0d0b14; --mute: #5d5a68; --dim: #9a97a6;
  --line: rgba(13, 11, 20, .08); --line-2: rgba(13, 11, 20, .16);
  --accent: #6d28d9; --accent-soft: rgba(109, 40, 217, .1);
  color: var(--ink); background: var(--bg);
  box-shadow: 0 0 0 100vmax var(--bg); clip-path: inset(0 -100vmax);   /* full-bleed background */
}
.section--light .lead { color: #3b3846; }
.section--light .chips span { color: #4a4757; }
.section--light .plan li { color: #2b2836; }
.section--light .svc, .section--light .plan { box-shadow: 0 1px 2px rgba(13, 11, 20, .04), 0 18px 40px -24px rgba(13, 11, 20, .22); }
.section--light .svc--featured { background: linear-gradient(160deg, #efe7ff, #fff 60%); border-color: rgba(109, 40, 217, .35); }
.section--light .plan--featured { background: linear-gradient(180deg, #f1eaff, #fff 50%); }
.section--light .btn--ghost:hover { background: var(--ink); color: #fff; }

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
  .nav { gap: 22px; }
  .studio__grid, .contact__grid { grid-template-columns: 1fr; }
  .booking { max-width: 640px; }
  .plans { grid-template-columns: 1fr; max-width: 560px; }
  .steps { grid-template-columns: 1fr 1fr; row-gap: 46px; }
  .steps::before, .steps::after { display: none; }
}

@media (max-width: 900px) {
  .burger { display: block; }
  .header__cta { display: none; }
  .nav {
    position: fixed; inset: 0; z-index: -1; background: var(--bg);
    flex-direction: column; justify-content: center; gap: 8px; padding: 100px var(--pad) 40px;
    opacity: 0; visibility: hidden; transition: opacity .4s, visibility .4s;
  }
  .nav a { font-size: 34px; font-weight: 700; color: var(--ink); padding: 6px 0; }
  .nav a::after { display: none; }
  .nav__cta-mobile { display: block; color: var(--accent) !important; margin-top: 18px; }
  .nav.is-open { opacity: 1; visibility: visible; }
  .header.menu-open { background: var(--bg); }

  .hero { justify-content: flex-end; padding-bottom: 110px; }
  .hero::before { background: linear-gradient(to bottom, rgba(10,10,10,.1) 0%, rgba(10,10,10,.35) 40%, var(--bg) 82%); }
  .hero__fallback { width: 78vw; top: 30%; inset-inline-end: 11%; }
  .hero__hint { display: none; }
  .services__grid { grid-template-columns: 1fr; }
  .work__grid { grid-template-columns: 1fr; }
  .proj, .proj:nth-child(4n + 1), .proj:nth-child(4n + 2) { grid-column: auto; }
  .proj__view { opacity: 1; transform: none; }
}

@media (max-width: 600px) {
  .brand__logo { width: 136px; }
  .intro__logo { width: 92vw; }
  .hero__btns .btn { flex: 1 1 100%; }
  .hero__foot { justify-content: center; }
  .scroll-cue { display: none; }
  .stats { grid-template-columns: 1fr 1fr 1fr; gap: 12px; }
  .stat small { font-size: 12px; }
  .founder { grid-template-columns: 1fr; padding: 26px 22px; }
  .founder__mono { width: 76px; height: 76px; font-size: 20px; }
  .steps { grid-template-columns: 1fr; }
  .fields { grid-template-columns: 1fr; }
  .filters { width: 100%; justify-content: space-between; }
  .filters button { padding: 8px 12px; }
  .proj__meta { flex-direction: column; gap: 4px; }
}

/* =========================================================
   v2 — typography, section motion backgrounds, cards, media
   ========================================================= */
:root {
  --f-ar: 'Readex Pro', 'Alexandria', system-ui, sans-serif;
  --f-en: 'Readex Pro', 'Manrope', system-ui, sans-serif;
}
body { line-height: 1.85; letter-spacing: 0; word-spacing: .03em; }
html[lang="ar"] body { font-size: 16.5px; }
.hero__title, html[lang="en"] .hero__title { letter-spacing: -.01em; line-height: 1.12; }
html[lang="ar"] .hero__title { letter-spacing: 0; line-height: 1.3; font-weight: 600; }
.h2, html[lang="en"] .h2 { letter-spacing: -.01em; line-height: 1.2; }
html[lang="ar"] .h2 { letter-spacing: 0; line-height: 1.38; font-weight: 600; }
.lead { line-height: 1.9; }
.founder h3, .svc h3, .plan h3, .step h3, .proj__meta h3 { line-height: 1.45; font-weight: 600; }

/* --- living background in every section: drifting purple light + slow seigaiha waves --- */
.section::before {
  content: ''; position: absolute; z-index: -2; pointer-events: none;
  inset: -10% -20%;
  background:
    radial-gradient(38% 42% at 20% 30%, rgba(139, 61, 255, .16), transparent 70%),
    radial-gradient(30% 36% at 80% 70%, rgba(80, 110, 255, .10), transparent 70%);
  animation: drift 22s ease-in-out infinite alternate;
  will-change: transform;
}
.section::after {
  content: ''; position: absolute; z-index: -2; pointer-events: none;
  left: 0; right: 0; top: -60px; height: calc(100% + 120px);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='80' height='40' viewBox='0 0 80 40'%3E%3Cg fill='none' stroke='%23ffffff' stroke-opacity='.55' stroke-width='1.2'%3E%3Cpath d='M0 40a40 40 0 0 1 80 0M10 40a30 30 0 0 1 60 0M20 40a20 20 0 0 1 40 0M-40 20a40 40 0 0 1 80 0M40 20a40 40 0 0 1 80 0M-30 20a30 30 0 0 1 60 0M50 20a30 30 0 0 1 60 0'/%3E%3C/g%3E%3C/svg%3E");
  /* the waves sit faint everywhere and light up in a soft pool around the cursor (--mx/--my set in main.js) */
  -webkit-mask-image: radial-gradient(circle var(--glow, 0px) at var(--mx, -999px) var(--my, -999px), #000, rgba(0,0,0,.09)), linear-gradient(to bottom, transparent, #000 25%, #000 75%, transparent);
  -webkit-mask-composite: source-in;
  mask-image: radial-gradient(circle var(--glow, 0px) at var(--mx, -999px) var(--my, -999px), #000, rgba(0,0,0,.09)), linear-gradient(to bottom, transparent, #000 25%, #000 75%, transparent);
  mask-composite: intersect;
  transition: --glow .5s ease;
  animation: waves 40s linear infinite;
  will-change: transform;
}
.section--light::before {
  background:
    radial-gradient(38% 42% at 20% 30%, rgba(139, 61, 255, .12), transparent 70%),
    radial-gradient(30% 36% at 80% 70%, rgba(80, 110, 255, .08), transparent 70%);
}
.section--light::after {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='80' height='40' viewBox='0 0 80 40'%3E%3Cg fill='none' stroke='%238b3dff' stroke-opacity='.7' stroke-width='1.2'%3E%3Cpath d='M0 40a40 40 0 0 1 80 0M10 40a30 30 0 0 1 60 0M20 40a20 20 0 0 1 40 0M-40 20a40 40 0 0 1 80 0M40 20a40 40 0 0 1 80 0M-30 20a30 30 0 0 1 60 0M50 20a30 30 0 0 1 60 0'/%3E%3C/g%3E%3C/svg%3E");
}
@property --glow { syntax: '<length>'; initial-value: 0px; inherits: true; }
.section.is-glow { --glow: 240px; }
@keyframes drift {
  0% { transform: translate3d(-4%, -3%, 0) scale(1); }
  50% { transform: translate3d(3%, 4%, 0) scale(1.08); }
  100% { transform: translate3d(5%, -2%, 0) scale(1.02); }
}
@keyframes waves { to { transform: translate3d(-80px, -40px, 0); } }

/* --- text boxes: a light that orbits the border, plus 3D tilt (motion.js) --- */
@property --ang { syntax: '<angle>'; initial-value: 0deg; inherits: false; }
.svc, .plan, .founder, .booking { transform-style: preserve-3d; }
.svc::after, .plan::after, .founder::after, .booking::after {
  content: ''; position: absolute; inset: 0; border-radius: inherit; padding: 1.5px; pointer-events: none; z-index: 2;
  background: conic-gradient(from var(--ang), transparent 0 70%, rgba(139, 61, 255, .9) 82%, rgba(160, 200, 255, .9) 88%, transparent 96%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: 0; transition: opacity .5s;
  animation: orbit 3.2s linear infinite;
}
.svc:hover::after, .plan:hover::after, .founder:hover::after, .booking:focus-within::after,
.plan--featured::after { opacity: 1; }
@keyframes orbit { to { --ang: 360deg; } }
.svc, .plan, .founder { will-change: transform; }

/* --- founder photos --- */
.founder__mono.has-photo { overflow: hidden; padding: 0; }
.founder__mono img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }

/* --- project media --- */
.proj__art img, .proj__art video, .modal__art img, .modal__art video {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 1.1s var(--ease);
}
.proj:hover .proj__art img, .proj:hover .proj__art video { transform: scale(1.06); }
/* cover videos: own GPU layer so the hover zoom doesn't shake, and the cursor never hits the video itself */
/* the frame is its own compositor layer, so the rounded clip doesn't flicker while the media zooms */
.proj__art { isolation: isolate; transform: translateZ(0); contain: paint; }
/* images/art zoom gently; cover videos never scale (scaling a playing video re-rasterises every frame → jank and pixels) */
.proj__art img, .proj__art svg { backface-visibility: hidden; transform: scale(1.001); transition: transform .9s cubic-bezier(.22,1,.36,1); }
.proj__art video { pointer-events: none; transform: none !important; transition: filter .6s ease; filter: brightness(.92); }
.proj:hover .proj__art img, .proj:hover .proj__art svg { transform: scale(1.04); }
.proj:hover .proj__art video { filter: brightness(1.05); }
.proj__new {
  position: absolute; z-index: 2; inset-block-start: 16px; inset-inline-end: 16px;
  font-size: 11px; font-weight: 600; letter-spacing: .06em; padding: 4px 12px; border-radius: 999px;
  background: var(--accent); color: #fff; box-shadow: 0 0 24px rgba(139, 61, 255, .6);
  animation: newPulse 2.4s ease-in-out infinite;
}
@keyframes newPulse { 50% { box-shadow: 0 0 6px rgba(139, 61, 255, .3); } }
.work__empty { padding: 40px 0; text-align: center; }
.modal__gallery { display: grid; gap: 14px; margin-top: 26px; }
.modal__gallery:empty { display: none; }
.modal__gallery .shot__media { position: relative; }
.modal__gallery img { cursor: zoom-in; transition: transform .5s var(--ease), filter .5s; }
.modal__gallery img:hover { transform: scale(1.015); filter: brightness(1.08); }
.shot__open { position: absolute; top: 10px; inset-inline-start: 10px; width: 38px; height: 38px; border-radius: 50%; background: rgba(0,0,0,.6); border: 1px solid var(--line-2); color: #fff; font-size: 18px; cursor: pointer; }
.shot__open:hover { background: var(--accent); }

/* review fixes: dinar price under the dollar price, empty filters gone, thumb-sized touch targets on phones */
.plan__local { display: block; margin-top: 4px; font-style: normal; font-size: 13px; color: var(--dim); }
#filters button[hidden] { display: none; }
@media (max-width: 760px) {
  #filters button, .lang-toggle, #langToggle, .login-btn, .burger, .nav__burger, .modal__x, .shot__open, .cal__nav { min-height: 44px; min-width: 44px; }
  .proj__tags span { padding: 5px 11px; }
}

/* lightbox */
.lb { position: fixed; inset: 0; z-index: 120; background: rgba(5,5,5,.96); display: grid; place-items: center; animation: fade .3s both; }
.lb[hidden] { display: none; }
.lb__stage { position: relative; width: 100%; height: 100%; display: grid; place-items: center; padding: 64px 72px 84px; }
.lb__stage img, .lb__stage video { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 10px; animation: rise .45s var(--ease) both; }
.lb__cap { position: absolute; bottom: 28px; inset-inline: 80px; margin: 0; text-align: center; color: #d4d2cd; font-size: 15px; }
.lb__count { position: absolute; top: 24px; inset-inline-start: 28px; color: var(--dim); font: 500 14px Manrope, sans-serif; letter-spacing: 3px; }
.lb__btn { position: absolute; width: 50px; height: 50px; border-radius: 50%; background: rgba(255,255,255,.08); border: 1px solid var(--line-2); color: #fff; font-size: 30px; line-height: 1; cursor: pointer; transition: background .25s; }
.lb__btn:hover { background: var(--accent); }
.lb__x { top: 16px; inset-inline-end: 16px; font-size: 26px; }
.lb__prev { left: 14px; top: 50%; translate: 0 -50%; }
.lb__next { right: 14px; top: 50%; translate: 0 -50%; }
.lb.is-single .lb__prev, .lb.is-single .lb__next, .lb.is-single .lb__count { display: none; }
@media (max-width: 600px) { .lb__stage { padding: 60px 8px 80px; } .lb__prev, .lb__next { top: auto; bottom: 18px; translate: none; } .lb__cap { inset-inline: 70px; bottom: 30px; } }
.modal__gallery img, .modal__gallery video { width: 100%; height: auto; border-radius: 14px; background: #0d0d0d; }

/* --- social icons --- */
.soc svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; display: block; }
.soc svg .fill { fill: currentColor; stroke: none; }
.channels a { justify-content: flex-start; }
.channels a > span { flex: 1; }
.channels .soc {
  width: 46px; height: 46px; flex: none; display: grid; place-items: center; border-radius: 50%;
  border: 1px solid var(--line-2); color: var(--accent); transition: background .3s, color .3s, border-color .3s;
}
.channels a:hover .soc { background: var(--accent); color: #fff; border-color: var(--accent); }
.footer__social { display: flex; gap: 10px; }
.footer__social .soc {
  width: 42px; height: 42px; display: grid; place-items: center; border-radius: 50%;
  border: 1px solid var(--line-2); color: var(--ink); transition: background .3s, border-color .3s, transform .4s var(--ease);
}
.footer__social .soc:hover { background: var(--accent); border-color: var(--accent); transform: translateY(-3px); }

/* --- sakura layer --- */
.petals { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 45; pointer-events: none; }

/* --- reviews --- */
.reviews__list { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 18px; margin: 40px 0; }
.reviews__list:empty { margin: 20px 0; }
.review { margin: 0; padding: 28px; border: 1px solid var(--line); border-radius: var(--r); background: var(--card); }
.review blockquote { margin: 0 0 16px; font-size: 17px; line-height: 1.8; }
.review figcaption { color: var(--accent); font-size: 14px; }
.reviews__form { max-width: 640px; display: grid; gap: 16px; }

/* discreet dashboard link */
.footer__admin { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; color: var(--dim); opacity: .5; transition: opacity .3s, color .3s; }
.footer__admin:hover { opacity: 1; color: var(--accent); }
.footer__admin svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; }

/* =========================================================
   mobile polish
   ========================================================= */
/* nothing decorative may widen the page (it made phones zoom out and shift sideways) */
html, body { overflow-x: clip; max-width: 100%; }
.section { overflow-x: clip; }
.section--light { overflow-x: visible; }

@media (max-width: 900px) {
  .section::before { inset: -6% 0; }
  .sec-kanji { inset-inline-end: 4px; font-size: clamp(90px, 30vw, 170px); top: 56px; }
  .enso { width: 62vw; inset-inline-end: -6vw; }
  .section { padding-top: 84px; padding-bottom: 84px; }
  .h2 { font-size: clamp(32px, 9vw, 46px); }
  .lead { font-size: 16px; }
  .hero__lead { font-size: 15.5px; }
  .founder__years { position: static; text-align: start; margin-top: 8px; }
  .plans { max-width: none; }
  .booking { padding: 18px; }
  .cal { padding: 10px; }
  .cal__days button { height: 38px; font-size: 13px; }
  .slots button { padding: 9px 14px; }
  .channels strong { font-size: 15px; word-break: break-all; }
  .channels .soc { width: 40px; height: 40px; }
  .footer__row { justify-content: center; text-align: center; }
  .modal__card { border-radius: 16px; }
  .work__top { align-items: flex-start; }
}

@media (max-width: 600px) {
  .hero { padding-top: 96px; }
  .hero__title, html[lang="ar"] .hero__title { font-size: clamp(38px, 11vw, 52px); }
  .stats { grid-template-columns: 1fr 1fr 1fr; }
  .stat b, .stat > span { font-size: 30px; }
  .filters { overflow-x: auto; flex-wrap: nowrap; }
  .filters button { flex: none; }
  .services__grid, .plans { gap: 14px; }
  .svc { min-height: 0; padding: 24px; }
  .svc h3 { margin-top: 28px; }
  .plan { padding: 30px 22px 24px; }
  .plan__price b { font-size: 38px; }
  .footer__logo { width: 100%; }
}

/* touch screens: no hover-only effects, bigger tap targets */
@media (hover: none) {
  .proj__view { opacity: 1; transform: none; }
  .svc::after, .plan::after, .founder::after { display: none; }
  .nav a { min-height: 48px; display: flex; align-items: center; }
}

/* the root must never scroll sideways (stamped section numbers start 2.6x large) */
html { overflow-x: hidden; }
.sec-head { overflow: clip; overflow-clip-margin: 6px; }
.footer__logo { overflow: clip; }
body { overflow-x: hidden; position: relative; }

/* project gallery layouts (chosen per project in the dashboard) */
.modal__gallery.is-grid { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.modal__gallery.is-grid img, .modal__gallery.is-grid video { aspect-ratio: 4 / 3; object-fit: cover; }
.modal__gallery.is-two { grid-template-columns: 1fr 1fr; }
.modal__gallery.is-full { grid-template-columns: 1fr; }
@media (max-width: 600px) { .modal__gallery.is-two, .modal__gallery.is-grid { grid-template-columns: 1fr; } }

/* --- project gallery, write-up, tags --- */
.modal__card { width: min(1000px, 100%); }
.shot { margin: 0; display: grid; gap: 8px; }
.shot__media { position: relative; overflow: hidden; border-radius: 14px; background: #0d0d0d; }
.shot__media img, .shot__media video { display: block; width: 100%; height: auto; }
.shot figcaption { color: var(--mute); font-size: 14px; line-height: 1.7; }
.modal__about { margin-top: 34px; padding-top: 26px; border-top: 1px solid var(--line); }
.modal__about h4 { margin: 0 0 12px; font-size: 20px; font-weight: 600; }
.modal__about p { margin: 0 0 14px; color: #d4d2cd; line-height: 1.95; }
.modal__tags, .proj__tags { display: flex; flex-wrap: wrap; gap: 8px; }
.modal__tags { margin-top: 18px; }
.modal__tags span, .proj__tags span { font-size: 12.5px; color: var(--accent); background: rgba(139, 61, 255, .1); border: 1px solid rgba(139, 61, 255, .3); padding: 3px 11px; border-radius: 999px; }
.proj__tags { margin-top: 8px; }
.proj__tags span { font-size: 11px; padding: 2px 9px; }

/* --- watermark over the work (deters copying; the dashboard can also burn it into uploads) --- */
.wm { position: relative; }
.wm::after {
  content: ''; position: absolute; inset: 0; z-index: 2; pointer-events: none; opacity: .14;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='120' viewBox='0 0 220 120'%3E%3Ctext x='110' y='66' text-anchor='middle' transform='rotate(-24 110 60)' font-family='Arial, sans-serif' font-weight='700' font-size='20' letter-spacing='6' fill='%23ffffff'%3EYAKZEN%3C/text%3E%3C/svg%3E");
  mix-blend-mode: overlay;
}
.shot__media.wm::after { bottom: 46px; }      /* keep video controls clear */
.no-wm .wm::after { display: none; }
.wm img { -webkit-user-drag: none; user-select: none; -webkit-touch-callout: none; }

/* --- background music player --- */
.music {
  position: fixed; z-index: 60; bottom: 22px; inset-inline-start: 22px; display: flex; align-items: center; gap: 10px;
  direction: ltr;
}
.music__toggle {
  width: 50px; height: 50px; border-radius: 50%; display: grid; place-items: center; flex: none;
  background: rgba(20, 18, 26, .8); border: 1px solid rgba(139, 61, 255, .45); backdrop-filter: blur(10px);
  box-shadow: 0 10px 30px -10px rgba(139, 61, 255, .6); transition: transform .3s var(--ease), background .3s;
}
.music__toggle:hover { transform: scale(1.07); background: var(--accent); }
.music__play { width: 20px; height: 20px; fill: #fff; margin-left: 3px; }
.music__bars { display: none; align-items: flex-end; gap: 3px; height: 18px; }
.music__bars i { width: 3px; background: #fff; border-radius: 2px; animation: eq 1s ease-in-out infinite; }
.music__bars i:nth-child(2) { animation-delay: -.3s; } .music__bars i:nth-child(3) { animation-delay: -.6s; } .music__bars i:nth-child(4) { animation-delay: -.15s; }
@keyframes eq { 0%, 100% { height: 4px; } 50% { height: 18px; } }
.music.is-playing .music__bars { display: flex; }
.music.is-playing .music__play { display: none; }
.music__panel {
  display: flex; align-items: center; gap: 10px; padding: 0 14px; height: 42px; border-radius: 999px;
  background: rgba(20, 18, 26, .85); border: 1px solid var(--line-2); backdrop-filter: blur(10px);
  max-width: 0; opacity: 0; overflow: hidden; transition: max-width .5s var(--ease), opacity .3s;
}
.music:hover .music__panel, .music:focus-within .music__panel { max-width: 280px; opacity: 1; }
.music__title { font-size: 12.5px; color: #ddd; white-space: nowrap; max-width: 120px; overflow: hidden; text-overflow: ellipsis; }
.music__vol { width: 110px; accent-color: var(--accent); }
@media (hover: none) { .music .music__panel { max-width: 200px; opacity: 1; } .music__title { display: none; } }
@media (max-width: 600px) { .music { bottom: 16px; inset-inline-start: 16px; } .music__toggle { width: 44px; height: 44px; } .music__vol { width: 90px; } }

/* --- admin edit mode on the live site --- */
.le-bar {
  position: fixed; z-index: 97; bottom: 18px; left: 50%; transform: translateX(-50%);
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap; justify-content: center; max-width: calc(100vw - 24px);
  padding: 8px 10px; border-radius: 999px; background: #fff; color: #111; box-shadow: 0 18px 50px -12px rgba(0, 0, 0, .55);
  font: 500 13.5px/1 var(--f-body);
}
.le-bar button, .le-bar a { padding: 9px 16px; border-radius: 999px; border: 1px solid #e3e1ea; background: #fff; color: #111; cursor: pointer; }
.le-bar .le-toggle { background: var(--accent); color: #fff; border-color: var(--accent); }
.le-bar .le-save { background: #111; color: #fff; border-color: #111; }
.le-dot { width: 8px; height: 8px; border-radius: 50%; background: #3ddc97; margin-inline: 6px 2px; }
.le-hint { color: #6b6875; font-size: 12px; padding-inline: 6px; }
.le-on [contenteditable="true"] { outline: 1.5px dashed rgba(139, 61, 255, .55); outline-offset: 4px; border-radius: 4px; cursor: text; }
.le-on [contenteditable="true"]:hover { outline-color: var(--accent); background: rgba(139, 61, 255, .08); }
.le-on [contenteditable="true"]:focus { outline: 2px solid var(--accent); background: rgba(139, 61, 255, .1); }
.le-handle {
  position: absolute; z-index: 20; top: 14px; inset-inline-start: 50%; transform: translateX(-50%);
  padding: 7px 14px; border-radius: 999px; background: var(--accent); color: #fff; font: 500 12.5px/1 var(--f-body); cursor: grab;
}
[dir="rtl"] .le-handle { transform: translateX(50%); }
.le-dragging { opacity: .45; outline: 2px dashed var(--accent); }
.is-admin .music { bottom: 78px; }

/* --- login button in the header --- */
.login-btn {
  display: inline-flex; align-items: center; gap: 7px; height: 42px; padding: 0 14px; border-radius: 999px;
  border: 1px solid var(--line-2); font-size: 13.5px; color: var(--mute); transition: color .3s, border-color .3s;
}
.login-btn:hover { color: var(--ink); border-color: var(--accent); }
.login-btn svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; }
.is-admin .login-btn { display: none; }
@media (max-width: 600px) { .login-btn span { display: none; } .login-btn { width: 42px; padding: 0; justify-content: center; } }

/* --- Arabic type: IBM Plex Sans Arabic — clean, elegant, very readable --- */
:root { --f-ar: 'IBM Plex Sans Arabic', 'Readex Pro', system-ui, sans-serif; }
html[lang="ar"] body { font-size: 16.5px; line-height: 1.9; }
html[lang="ar"] .hero__title, html[lang="ar"] .h2 { font-weight: 700; }

/* --- performance: off-screen backgrounds stop animating; cards stop being permanent layers --- */
.section:not(.in-view)::before, .section:not(.in-view)::after { animation-play-state: paused; }
.svc, .plan, .founder { will-change: auto; }
.section:not(.in-view) .svc::after, .section:not(.in-view) .plan::after { animation-play-state: paused; }

/* --- katana cut between site and dashboard: the old page splits along the cut, revealing the new one --- */
@view-transition { navigation: auto; }
::view-transition-new(root) { animation: none; }
::view-transition-old(root) {
  z-index: 2;
  -webkit-mask: linear-gradient(175.2deg, #000 50%, transparent 50.05%) 0 0 / 100% 100% no-repeat,
                linear-gradient(175.2deg, transparent 49.95%, #000 50%) 0 0 / 100% 100% no-repeat;
  mask: linear-gradient(175.2deg, #000 50%, transparent 50.05%) 0 0 / 100% 100% no-repeat,
        linear-gradient(175.2deg, transparent 49.95%, #000 50%) 0 0 / 100% 100% no-repeat;
  animation: kc-part 1.1s cubic-bezier(.86, 0, .07, 1) both;
}
@keyframes kc-part {
  0%, 12% { -webkit-mask-position: 0 0, 0 0; mask-position: 0 0, 0 0; }
  100% { -webkit-mask-position: -6vw -110vh, 6vw 110vh; mask-position: -6vw -110vh, 6vw 110vh; }
}

/* --- phones: drop the costly effects so scrolling stays smooth --- */
@media (max-width: 900px), (hover: none) {
  .section::before, .section::after { animation: none; will-change: auto; }
  .section::after { -webkit-mask-image: none; mask-image: none; opacity: .035; }
  .svc::after, .plan::after, .founder::after, .booking::after { display: none; }
  .header.is-scrolled, .music__toggle, .music__panel, .proj__tag, .modal__backdrop { backdrop-filter: none; -webkit-backdrop-filter: none; }
  .header.is-scrolled { background: rgba(10, 10, 10, .94); }
  body::after { display: none; }            /* film grain overlay */
  .proj__new { animation: none; }
}
