/* =====================================================================
   STYLE — الشكل والتقسيم. الألوان والخطوط في theme.css
   ===================================================================== */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
body {
  font-family: var(--font-sans);
  background: var(--bg-dark);
  color: var(--text-on-dark);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
:lang(ar), [dir="rtl"] { font-family: var(--font-arabic); }
img, video, canvas, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
ul { list-style: none; }
:focus-visible { outline: 2px solid var(--steel); outline-offset: 3px; border-radius: 4px; }
.light :focus-visible { outline-color: var(--tech); }

.container { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }
.center { text-align: center; }
.dark  { background: var(--bg-dark);  color: var(--text-on-dark); }
.light { background: var(--bg-light); color: var(--text-on-light); }
/* الأقسام اللي بنفس اللون بتركب على بعض 1px عشان ميبانش خط رفيع بينهم */
.light + .light, .dark + .dark { margin-top: -1px; }

/* ---------- Typography ---------- */
.label {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase;
  color: var(--muted-on-dark); margin-bottom: 22px;
}
.light .label { color: var(--muted-on-light); }
.label--center { justify-content: center; }
.label .chev { width: 11px; height: 11px; }
.h2 { font-size: clamp(32px, 4vw, 58px); font-weight: 500; line-height: 1.05; letter-spacing: -.025em; }
.lead { max-width: 560px; margin-top: 20px; color: var(--muted-on-dark); font-size: 15px; }
.star { color: var(--accent); }
.dark .star { color: var(--steel); }
.accent-note { margin-top: 12px; font-family: var(--font-mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--accent); }

/* split words (لـ animation العناوين) */
.w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .08em; margin-bottom: -.08em; }
.w > span { display: inline-block; will-change: transform; }

/* ---------- Buttons (النص بيلف لفوق) ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 12px;
  height: 40px; padding: 0 14px 0 16px; border-radius: 8px;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase;
  transition: transform .4s var(--ease-out), background-color .3s;
  cursor: pointer;
}
.btn--dark  { background: var(--navy); color: var(--white); }
.btn--light { background: var(--white); color: var(--navy); }
.btn--blue  { background: var(--tech); color: var(--on-accent); }
.dark .btn--dark, .hero .btn--dark { background: rgba(var(--steel-rgb), .08); border: 1px solid var(--navy-line); backdrop-filter: blur(8px); }
.btn .arrow { width: 14px; height: 14px; transition: transform .5s var(--ease-out); }
.btn:hover .arrow { transform: translateX(3px); }
.btn:active { transform: scale(.97); }
.btn__roll, .roll { position: relative; display: inline-block; overflow: hidden; line-height: 1.25; }
.btn__roll > span, .roll > span { display: block; transition: transform .6s var(--ease-out); }
.btn__roll::after, .roll::after {
  content: attr(data-text); position: absolute; left: 0; top: 100%;
  transition: transform .6s var(--ease-out);
}
.btn:hover .btn__roll > span, .btn:hover .btn__roll::after,
.nav__link:hover .roll > span, .nav__link:hover .roll::after { transform: translateY(-100%); }

/* ---------- NAV ---------- */
.nav {
  position: fixed; z-index: 50; top: 16px; left: var(--gutter); right: var(--gutter);
  max-width: calc(var(--max) - 2 * var(--gutter)); margin-inline: auto;
  background: rgba(var(--navy-rgb), .55);
  backdrop-filter: blur(18px) saturate(140%); -webkit-backdrop-filter: blur(18px) saturate(140%);
  border: 1px solid var(--navy-line); border-radius: 14px;
  transition: transform .7s var(--ease-out), background-color .4s;
  overflow: hidden;
}
.nav.is-hidden { transform: translateY(calc(-100% - 24px)); }
.nav.is-open { background: rgba(1, 8, 20, .92); }
.nav__bar { display: flex; align-items: center; justify-content: space-between; height: 58px; padding: 0 18px; }
.nav__logo { display: flex; align-items: center; gap: 8px; font-size: 21px; font-weight: 500; letter-spacing: -.02em; }
.nav__logo .mark { width: 24px; height: 24px; --mark-core: transparent; }
.nav__logo:hover .mark { transform: rotateY(180deg); }
.mark { transition: transform .8s var(--ease-out); }
.nav__toggle { width: 44px; height: 44px; display: grid; place-content: center; gap: 6px; margin-right: -10px; }
.nav__toggle span { display: block; width: 18px; height: 1.5px; background: currentColor; transition: transform .5s var(--ease-out); }
.nav.is-open .nav__toggle span:first-child { transform: translateY(3.75px) rotate(45deg); }
.nav.is-open .nav__toggle span:last-child  { transform: translateY(-3.75px) rotate(-45deg); }
.nav__panel { height: 0; overflow: hidden; }
.nav__links { padding: 12px 18px 0; }
.nav__link { display: flex; align-items: baseline; gap: 14px; padding: 10px 0; border-top: 1px solid var(--navy-line); font-size: clamp(28px, 4vw, 48px); font-weight: 500; letter-spacing: -.02em; line-height: 1.1; }
.nav__num { font-family: var(--font-mono); font-size: 11px; color: var(--muted-on-dark); }
.nav__foot { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; padding: 18px; font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted-on-dark); }
.nav__foot a:hover { color: var(--white); }

/* ---------- HERO ---------- */
.hero {
  position: relative; height: 100vh; min-height: 680px; overflow: hidden;
  background: var(--gradient-hero);
}
.hero__inner { position: relative; z-index: 3; padding-top: clamp(120px, 20vh, 190px); text-align: center; padding-inline: var(--gutter); }
.hero__title {
  font-size: clamp(40px, 6.2vw, 100px); font-weight: 500; line-height: .98; letter-spacing: -.035em; text-transform: uppercase;
}
.hero__main { display: block; margin-bottom: .14em; font-size: .42em; font-weight: 400; letter-spacing: .02em; color: rgba(255, 255, 255, .78); }
/* اسمك بتدرج فضي/أزرق زي عنوان غلاف البورتفوليو */
.hero__accent { display: block; font-weight: 500; letter-spacing: -.04em; }
/* GASSER بالأبيض و MAHMOUD. بالسيان الفاتح */
.hero__accent { color: var(--white); }
.hero__accent em { font-style: normal; }
.hero__accent em .w > span {
  background: linear-gradient(180deg, #B8EEFF 10%, #6FD6F8 55%, #2DBBEE 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ---------- الهيرو بصورتك: الاسم فوق في النص، صورتك كبيرة في النص، والكلام والزراير تحت ---------- */
.has-hero-photo .hero__inner {
  display: flex; flex-direction: column; align-items: center; height: 100%;
  padding: clamp(92px, 12vh, 120px) var(--gutter) clamp(28px, 5vh, 48px); text-align: center;
}
.has-hero-photo .hero__title { font-size: clamp(42px, 7vw, 116px); line-height: .92; }
.has-hero-photo .hero__main { font-size: .3em; margin-bottom: .3em; letter-spacing: .08em; }
.has-hero-photo .hero__text { margin: auto auto 0; max-width: 460px; font-size: 15px; text-shadow: 0 2px 18px rgba(var(--navy-rgb), .9); }
.has-hero-photo .hero__buttons { margin-top: 22px; }
.hero__meta { display: flex; flex-wrap: wrap; justify-content: center; row-gap: 8px; margin-top: 22px; font-family: var(--font-mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted-on-dark); }
.hero__meta li { padding: 0 16px; }
.hero__meta li + li { border-left: 1px solid rgba(var(--steel-rgb), .25); }
.hero__meta b { color: var(--white); font-weight: 500; }
.hero__meta:empty { display: none; }
.has-hero-photo .hero__canvas { display: none; }

/* صورتك في النص كبيرة */
.hero__photo { position: absolute; z-index: 2; bottom: 0; left: 0; right: 0; margin-inline: auto; width: calc(min(76vh, 900px) * 1.011); transform-origin: 50% 100%; pointer-events: none; }
.hero__photo img { position: relative; z-index: 1; width: 100%; height: auto; filter: drop-shadow(0 -6px 40px rgba(var(--cyan-rgb), .22)); }
/* غمقان تحت عشان الكلام والزراير يتقروا فوق التيشيرت */
.hero__photo::after { content: ""; position: absolute; z-index: 2; left: -100vw; right: -100vw; bottom: 0; height: 42%; background: linear-gradient(0deg, rgba(var(--navy-rgb), .92), rgba(var(--navy-rgb), 0)); }
/* النور السيان اللي ورا راسك */
.hero__photo::before {
  content: ""; position: absolute; left: 14%; right: 14%; top: -6%; height: 80%; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(var(--cyan-rgb), .7), rgba(var(--azure-rgb), .32) 50%, rgba(var(--azure-rgb), 0));
  filter: blur(36px);
}
.hero__text { max-width: 470px; margin: 18px auto 0; font-size: 15px; line-height: 1.45; color: rgba(255, 255, 255, .82); }
.hero__buttons { display: flex; justify-content: center; gap: 10px; margin-top: 28px; }
.hero__canvas { position: absolute; z-index: 1; left: 0; bottom: 0; width: 100%; height: 78%; }
.hero__grain {
  position: absolute; inset: 0; z-index: 4; pointer-events: none; opacity: .14; mix-blend-mode: overlay;
  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='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---------- CLIENTS marquee ---------- */
.clients { padding: 56px 0 40px; }
.clients__rows { display: grid; gap: clamp(22px, 3vw, 36px); }
.marquee { display: flex; overflow: hidden; -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); }
.marquee__track { display: flex; flex-shrink: 0; align-items: center; gap: clamp(40px, 6vw, 90px); padding-right: clamp(40px, 6vw, 90px); will-change: transform; }
.logo-item { display: flex; align-items: center; gap: 8px; height: 60px; font-size: clamp(20px, 2.2vw, 30px); font-weight: 700; letter-spacing: -.04em; white-space: nowrap; color: var(--navy); }
.logo-item .mark { width: 1em; height: 1em; --mark-core: var(--light-bg); }
.logo-item img { height: var(--h, 32px); width: auto; max-width: none; opacity: .82; transition: opacity .4s; user-select: none; -webkit-user-select: none; }
.logo-item:hover img { opacity: 1; }

/* ---------- WORK stacked cards ---------- */
.work { padding-top: 100px; padding-bottom: 14vh; }
.section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; margin-bottom: 48px; }
.stack { display: flex; flex-direction: column; gap: 10vh; max-width: 1080px; margin: 0 auto; }
.stack__card {
  position: sticky; top: 13vh;
  display: block; height: min(76vh, 680px); border-radius: var(--radius-lg); overflow: hidden;
  transform-origin: 50% 0%; will-change: transform;
  box-shadow: 0 -10px 40px rgba(var(--navy-rgb), .12);
}
.stack__media, .stack__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.stack__img { transition: transform 1.2s var(--ease-out); }
.stack__card:hover .stack__img, .stack__card:hover .ph__art { transform: scale(1.04); }
.stack__card::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, rgba(1, 6, 17, .65), transparent 35%); pointer-events: none; }
.stack__caption { position: absolute; z-index: 2; left: 24px; bottom: 22px; color: var(--white); }
.stack__caption h3 { font-size: clamp(20px, 1.8vw, 26px); font-weight: 500; letter-spacing: -.01em; margin-bottom: 10px; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tags li { padding: 5px 10px; border-radius: 6px; font-size: 11px; background: rgba(var(--navy-rgb), .55); backdrop-filter: blur(6px); }
.stack__media { background: var(--navy); }
.stack__view {
  position: absolute; z-index: 2; right: 22px; bottom: 22px; display: inline-flex; align-items: center; gap: 10px;
  height: 38px; padding: 0 14px; border-radius: 8px; background: var(--white); color: var(--navy);
  font-family: var(--font-mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase;
  transition: transform .6s var(--ease-out), background-color .3s, color .3s;
}
.stack__view > span { padding-right: 10px; border-right: 1px solid var(--light-line); color: var(--muted-on-light); }
.stack__view .arrow { width: 13px; height: 13px; transition: transform .5s var(--ease-out); }
.stack__card:hover .stack__view { background: var(--tech); color: var(--on-accent); }
.stack__card:hover .stack__view > span { color: rgba(var(--navy-rgb), .65); border-color: rgba(var(--navy-rgb), .2); }
.stack__card:hover .stack__view .arrow { transform: translateX(3px); }

/* ---------- PROJECT INDEX (كل المشاريع) ---------- */
.index { padding-top: 40px; padding-bottom: 140px; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin: -16px 0 36px; }
.chip {
  display: inline-flex; align-items: flex-start; gap: 4px; height: 38px; padding: 0 14px; align-items: center;
  border: 1px solid var(--light-line); border-radius: 8px; background: rgba(255, 255, 255, .6);
  font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted-on-light);
  transition: background-color .35s, color .35s, border-color .35s, transform .4s var(--ease-out);
}
.chip sup { font-size: 9px; transform: translateY(-4px); opacity: .7; }
.chip:hover { color: var(--navy); border-color: rgba(var(--navy-rgb), .25); }
.chip:active { transform: scale(.96); }
.chip.is-active { background: var(--navy); border-color: var(--navy); color: var(--white); }
.grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px 16px; }
.tile { display: block; }
.tile[hidden] { display: none !important; }
.tile__media {
  position: relative; overflow: hidden; aspect-ratio: 16 / 10; border-radius: var(--radius-lg);
  background: radial-gradient(120% 90% at 50% 0%, var(--white), #D8E7F5 70%, var(--steel));
  transform: translateZ(0);
}
.tile__img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease-out), filter .6s; }
.tile__media--contain .tile__img { object-fit: contain; padding: 6%; }
.tile:hover .tile__img { transform: scale(1.05); }
.tile__view {
  position: absolute; left: 14px; bottom: 14px; display: inline-flex; align-items: center; gap: 8px; height: 34px; padding: 0 12px;
  border-radius: 8px; background: var(--white); color: var(--navy); font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .1em; text-transform: uppercase;
  opacity: 0; transform: translateY(12px); transition: opacity .4s, transform .6s var(--ease-out);
  box-shadow: 0 10px 30px rgba(var(--navy-rgb), .18);
}
.tile__view .arrow { width: 12px; height: 12px; }
.tile:hover .tile__view, .tile:focus-visible .tile__view { opacity: 1; transform: none; }
.tile__meta { display: grid; grid-template-columns: auto 1fr; align-items: baseline; gap: 2px 12px; padding: 14px 4px 0; }
.tile__num { grid-row: span 2; font-family: var(--font-mono); font-size: 11px; color: var(--muted-on-light); }
.tile__meta h3 { font-size: 18px; font-weight: 500; letter-spacing: -.01em; line-height: 1.2; }
.tile__industry { font-size: 12.5px; color: var(--muted-on-light); }

/* placeholder بألوانك لما مفيش صورة */
.ph { display: grid; place-items: center; }
.ph--0 { background: radial-gradient(90% 90% at 20% 90%, var(--tech), transparent 60%), linear-gradient(135deg, #04182E, var(--navy)); }
.ph--1 { background: radial-gradient(70% 80% at 80% 20%, var(--white), transparent 60%), linear-gradient(160deg, var(--steel), #7DB3E0); }
.ph--2 { background: radial-gradient(60% 70% at 50% 110%, var(--tech), transparent 70%), var(--navy); }
.ph--3 { background: radial-gradient(70% 70% at 30% 20%, #4FA3E3, transparent 60%), var(--tech); }
.ph--4 { background: linear-gradient(200deg, var(--white), var(--steel) 45%, var(--tech)); }
.ph__art { position: relative; display: grid; place-items: center; width: 100%; height: 100%; transition: transform 1.2s var(--ease-out); }
.ph__art span { position: relative; z-index: 1; font-size: clamp(56px, 11vw, 170px); font-weight: 600; letter-spacing: -.05em; color: var(--white); }
.ph--1 .ph__art span, .ph--4 .ph__art span { color: var(--navy); }
.ph__art .mark { position: absolute; width: 46%; height: auto; opacity: .12; color: var(--white); --mark-core: transparent; animation: spin 40s linear infinite; }

/* ---------- SERVICES accordion ---------- */
.services { padding: 120px 0 60px; }
.accordion { display: flex; gap: 12px; height: 540px; margin-top: 64px; }
.acc {
  position: relative; flex: 0 0 76px; overflow: hidden; cursor: pointer;
  border: 1px solid var(--navy-line); border-radius: var(--radius-lg); background: rgba(6, 26, 48, .55);
  transition: flex-grow .9s var(--ease-out), flex-basis .9s var(--ease-out), background-color .4s;
}
.acc:hover { background: rgba(6, 26, 48, .9); }
.acc.is-open { flex: 1 1 0; cursor: default; }
.acc__vertical {
  position: absolute; right: 22px; bottom: 26px; writing-mode: vertical-rl; transform: rotate(180deg);
  font-size: 26px; font-weight: 400; letter-spacing: -.01em; white-space: nowrap; transition: opacity .4s;
}
.acc:nth-child(3n) .acc__vertical { color: var(--steel); }
.acc.is-open .acc__vertical { opacity: 0; }
.acc__body {
  position: absolute; inset: 0; min-width: 760px; display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 24px; padding: 40px;
  opacity: 0; transform: translateY(16px); transition: opacity .4s, transform .6s var(--ease-out); pointer-events: none;
}
.acc.is-open .acc__body { opacity: 1; transform: none; transition-delay: .35s; pointer-events: auto; }
.acc__text h3 { font-size: 22px; font-weight: 500; margin-bottom: 10px; }
.acc__text p { color: var(--muted-on-dark); font-size: 14px; max-width: 320px; }
.acc__text ul { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 20px; margin-top: 26px; font-size: 12px; color: var(--muted-on-dark); }
.acc__text li { display: flex; align-items: center; gap: 6px; }
.acc__text li .arrow { width: 11px; height: 11px; color: var(--steel); }
.acc__visual { display: grid; place-items: center; height: 100%; min-height: 0; }
.acc__visual img { width: 100%; max-height: 100%; aspect-ratio: 16 / 10; border-radius: var(--radius-md); object-fit: cover; box-shadow: 0 30px 60px rgba(0, 0, 0, .35); transform: scale(.94); opacity: .6; transition: transform 1.2s var(--ease-out), opacity .8s; }
.acc.is-open .acc__visual img { transform: none; opacity: 1; transition-delay: .3s; }

/* keycaps 3D */
.keys { display: grid; grid-template-columns: repeat(2, 92px); gap: 10px; padding: 16px; border-radius: 14px; background: var(--navy-deep);
  transform: rotateX(52deg) rotateZ(-38deg); transform-style: preserve-3d; box-shadow: 0 30px 0 -6px #00030c, 0 50px 60px rgba(0, 0, 0, .5); }
.keys span { height: 92px; border-radius: 12px; transform: translateZ(18px); transition: transform .35s var(--ease-out);
  box-shadow: 0 18px 0 -2px var(--sh), inset 0 2px 0 rgba(255, 255, 255, .5); }
.keys span:nth-child(1) { background: var(--white); --sh: #8FAAC2; }
.keys span:nth-child(2) { background: var(--steel); --sh: #789DBE; }
.keys span:nth-child(3) { background: var(--tech); --sh: #0B5F86; }
.keys span:nth-child(4) { background: rgba(var(--steel-rgb), .25); --sh: rgba(var(--deep-rgb), .5); backdrop-filter: blur(4px); }
.keys.k1 span:nth-child(1) { background: var(--tech); --sh: #0B5F86; } .keys.k1 span:nth-child(3) { background: var(--white); --sh: #8FAAC2; }
.keys.k2 span:nth-child(2) { background: var(--tech); --sh: #0B5F86; } .keys.k2 span:nth-child(3) { background: var(--steel); --sh: #789DBE; }
.keys span:hover, .keys span.is-down { transform: translateZ(4px); box-shadow: 0 4px 0 -2px var(--sh), inset 0 2px 0 rgba(255, 255, 255, .5); }

/* ---------- ABOUT bento ---------- */
.about { padding: 60px 0 120px; }
.bento { display: grid; gap: 12px; }
.card { position: relative; overflow: hidden; border: 1px solid var(--navy-line); border-radius: var(--radius-lg); background: var(--navy-card); }
.card--globe { height: clamp(460px, 62vw, 640px); }
.globe__head { position: absolute; z-index: 2; top: 34px; left: 0; right: 0; text-align: center; }
.globe__city { font-size: 15px; }
.pill-status { display: inline-flex; align-items: center; gap: 8px; margin-top: 8px; font-family: var(--font-mono); font-size: 10px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted-on-dark); }
.pill-status i { width: 8px; height: 8px; border-radius: 50%; background: #4ade80; box-shadow: 0 0 0 4px rgba(74, 222, 128, .18); animation: pulse 2s infinite; }
.globe { position: absolute; left: 0; right: 0; bottom: 0; width: 100%; height: 100%; }
.bento__row { display: grid; gap: 12px; }
.bento__row--2 { grid-template-columns: 1fr 1fr; }
.bento__row--3 { grid-template-columns: repeat(3, 1fr); }
.bento__row--stats { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.hl { height: 440px; display: grid; place-items: center; perspective: 900px; }
/* اللوجوهات الزجاج 3D (js/glass.js) */
.glass3d { position: absolute; inset: 0; }
.glass3d::before {
  content: ""; position: absolute; left: 50%; top: 46%; width: 62%; aspect-ratio: 1; transform: translate(-50%, -50%); border-radius: 50%;
  background: radial-gradient(closest-side, rgba(var(--cyan-rgb), .4), rgba(var(--azure-rgb), .18) 55%, rgba(var(--azure-rgb), 0));
  filter: blur(18px); transition: transform 1s var(--ease-out), opacity .6s; opacity: .85;
}
.hl:hover .glass3d::before { transform: translate(-50%, -50%) scale(1.15); opacity: 1; }
.glass3d.is-ready::before { display: none; } /* النور بيترسم جوه الـ 3D */
.glass3d canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.glass3d__fallback { position: absolute; left: 50%; top: 46%; width: 34%; transform: translate(-50%, -50%); color: rgba(255, 255, 255, .85); }
.glass3d.is-ready .glass3d__fallback { display: none; }
.hl__foot { position: absolute; left: 22px; bottom: 20px; font-size: 13px; }
.hl__foot a { display: inline-flex; align-items: center; gap: 4px; margin-top: 2px; color: var(--muted-on-dark); font-size: 12px; }
.hl__foot a .arrow { width: 11px; height: 11px; }
.hl__foot a:hover { color: var(--white); }

/* شكل 3D مصنوع من طبقات */
.extrude { position: relative; width: 150px; height: 190px; transform-style: preserve-3d; animation: sway 7s ease-in-out infinite; }
.extrude i { position: absolute; inset: 0; transform: translateZ(calc(var(--z) * 2.2px - 15px));
  background: linear-gradient(135deg, #12406A, #03101F); }
.extrude i:nth-last-child(1) { background: linear-gradient(135deg, var(--white) 0%, var(--steel) 22%, #4A9EE0 45%, var(--tech) 62%, #03142A 100%); }
.extrude i:nth-child(1) { background: #010812; }
.extrude--bolt i { clip-path: polygon(28% 0, 100% 0, 62% 38%, 92% 38%, 14% 100%, 40% 54%, 6% 54%); }
.extrude--arch i { clip-path: path("M0 190 V75 A75 75 0 0 1 150 75 V190 H104 V80 A29 29 0 0 0 46 80 V190 Z"); }
.extrude--ring i { clip-path: circle(48% at 50% 50%); -webkit-mask: radial-gradient(circle, transparent 30%, #000 31%); mask: radial-gradient(circle, transparent 30%, #000 31%); }
.extrude--adobe i { clip-path: path("M55.5 28.6H0V161.4ZM94.5 28.6H150V161.4ZM87.3 161.4L76.7 134.6H50.8L75.1 77.5L110.5 161.4Z"); }

.stat { padding: 46px 20px; text-align: center; }
.stat__num { font-size: clamp(34px, 3.6vw, 52px); font-weight: 400; letter-spacing: -.03em; line-height: 1; }
.stat__label { margin-top: 12px; font-size: 12px; color: var(--muted-on-dark); }

.founder { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 32px; padding: 14px; }
.founder__photo { position: relative; overflow: hidden; border-radius: var(--radius-md); aspect-ratio: 4 / 5; }
.founder__photo img, .founder__ph { position: absolute; inset: -8% 0; width: 100%; height: 116%; object-fit: cover; }
.founder__ph { display: grid; place-items: center; background: radial-gradient(80% 60% at 50% 30%, var(--azure), var(--tech) 45%, var(--navy) 100%); }
.founder__ph span { font-size: clamp(80px, 12vw, 180px); font-weight: 600; letter-spacing: -.05em; color: rgba(255, 255, 255, .9); }
.founder__id { position: absolute; left: 20px; bottom: 18px; z-index: 1; }
.founder__id p { font-size: 18px; }
.founder__id span { font-family: var(--font-mono); font-size: 10px; letter-spacing: .1em; text-transform: uppercase; color: rgba(255, 255, 255, .7); }
.founder__photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, rgba(1, 6, 17, .7), transparent 40%); }
.founder__bio { display: flex; flex-direction: column; padding: 24px 24px 18px 0; font-size: 14px; color: var(--muted-on-dark); }
.founder__bio h3 { font-size: 20px; font-weight: 500; color: var(--white); margin-bottom: 14px; }
.founder__bio p + p { margin-top: 14px; }
.founder__foot { margin-top: auto; padding-top: 24px; display: flex; flex-direction: column; gap: 22px; }
.founder__foot .mark { width: 22px; height: 22px; color: var(--white); animation: spinY 6s var(--ease-out) infinite; }
.founder__foot a { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; }
.founder__foot a .arrow { width: 12px; height: 12px; }

.toolbox { display: flex; align-items: center; gap: 32px; padding: 22px 24px; }
.toolbox__head { flex-shrink: 0; width: 170px; font-size: 13px; }
.toolbox__head span { color: var(--muted-on-dark); }
.skills { flex: 1; display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; }
.skill { display: flex; align-items: center; gap: 12px; padding: 10px; border-radius: 14px; background: rgba(1, 6, 17, .45); border: 1px solid var(--navy-line); transition: transform .5s var(--ease-out), border-color .3s; }
.skill:hover { transform: translateY(-4px); border-color: rgba(var(--steel-rgb), .3); }
.skill__info { flex: 1; min-width: 0; }
.skill__info p { display: flex; justify-content: space-between; gap: 8px; font-size: 13px; white-space: nowrap; }
.skill__info b { font-weight: 500; color: var(--steel); font-variant-numeric: tabular-nums; }
.skill__bar { height: 3px; margin-top: 10px; border-radius: 3px; background: rgba(var(--steel-rgb), .12); overflow: hidden; }
.skill__bar i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--tech), var(--steel)); transform-origin: 0 50%; transform: scaleX(var(--v)); }
.tool { display: grid; place-items: center; flex-shrink: 0; width: 52px; height: 52px; border-radius: 12px; background: var(--navy-deep); border: 1px solid var(--navy-line);
  font-size: 18px; font-weight: 600; color: var(--steel); }
.skill:nth-child(odd) .tool { background: var(--tech); color: var(--on-accent); border-color: transparent; }
.tool img { width: 60%; }

/* ---------- COLLAB (Adobe Photoshop reels) ---------- */
.collab { padding: 130px 0 120px; overflow: hidden; }
.carousel { margin-top: 64px; cursor: grab; touch-action: pan-y; user-select: none; -webkit-user-select: none; }
.carousel.is-drag { cursor: grabbing; }
.carousel__track { display: flex; align-items: flex-start; gap: 16px; width: max-content; padding-bottom: 24px; will-change: transform; }
.reel {
  display: flex; flex-direction: column; width: clamp(230px, 21vw, 290px); padding: 10px;
  border-radius: var(--radius-lg); background: var(--navy); color: var(--white);
  transition: transform .6s var(--ease-out);
}
.reel:nth-child(odd) { transform: translateY(22px); }
.reel:hover { transform: translateY(-6px) rotate(-1deg); }
.reel--accent { background: linear-gradient(170deg, var(--tech) 0%, var(--deep) 70%); }
.reel__media { position: relative; overflow: hidden; border-radius: 12px; aspect-ratio: 9 / 16; background: var(--navy-deep); }
.reel__media img { width: 100%; height: 100%; object-fit: cover; pointer-events: none; }
.reel__play { position: absolute; top: 12px; right: 12px; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: rgba(0, 0, 0, .35); backdrop-filter: blur(8px); color: var(--white); }
.reel__play svg { width: 16px; height: 16px; }
.reel figcaption { display: flex; gap: 10px; padding: 14px 6px 6px; }
.reel figcaption b { display: flex; align-items: center; gap: 5px; font-weight: 500; font-size: 13px; }
.reel figcaption small { display: block; margin-top: 4px; font-size: 12px; line-height: 1.4; color: rgba(255, 255, 255, .7); }
.verified { width: 13px; height: 13px; flex-shrink: 0; }
.reel__avatar {
  display: grid; place-items: center; width: 34px; height: 34px; flex-shrink: 0; border-radius: 50%;
  background: #001e36; color: #31a8ff; font-weight: 700; font-size: 13px;
  box-shadow: 0 0 0 2px var(--navy), 0 0 0 3.5px #f9a03f;
}
.reel--accent .reel__avatar { box-shadow: 0 0 0 2px var(--tech), 0 0 0 3.5px #f9a03f; }

/* ---------- AWARDS / RESUME ---------- */
.awards { padding: 60px 0 140px; }
.accent-note--left { margin-bottom: 64px; }
.table { border-top: 1px solid var(--light-line); }
.row {
  position: relative; display: grid; grid-template-columns: 1.1fr 1.1fr 1.1fr .3fr; gap: 16px; padding: 12px 14px;
  border-bottom: 1px solid var(--light-line); font-size: 13px; color: var(--muted-on-light); isolation: isolate; border-radius: 6px;
  transition: color .35s;
}
.row span:last-child { text-align: right; }
.row::before { content: ""; position: absolute; inset: 0; z-index: -1; border-radius: 6px; background: var(--tech); transform: scaleY(0); transform-origin: 50% 100%; transition: transform .45s var(--ease-out); }
.row:hover { color: var(--on-accent); }
.row:hover::before { transform: scaleY(1); }
.table--exp .row { grid-template-columns: 1fr 1.1fr 1.5fr minmax(120px, auto); padding: 18px 14px; font-size: 14px; }
.table--exp .row span:first-child { color: var(--navy); font-weight: 500; transition: color .35s; }
.table--exp .row:hover span:first-child { color: var(--on-accent); }
.table--exp .row span:last-child { font-family: var(--font-mono); font-size: 11.5px; letter-spacing: .06em; white-space: nowrap; }

/* ---------- CTA ---------- */
.cta { position: relative; padding: 60px var(--gutter) 160px; text-align: center; isolation: isolate; }
/* النور الأزرق اللي تحت زي السلايدز البيضا في البورتفوليو */
.cta::before { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 75%; z-index: -1; background: var(--gradient-haze); pointer-events: none; }
.cta__title { font-size: clamp(54px, 12vw, 210px); font-weight: 500; line-height: .92; letter-spacing: -.045em; text-transform: uppercase; }
.cta__line { display: block; overflow: hidden; padding-bottom: .04em; }
.cta__line .c { display: inline-block; will-change: transform; }
.cta__mark { display: inline-block; width: .62em; margin-left: .06em; vertical-align: baseline; color: var(--tech); }
.cta__mark .mark { width: 100%; height: auto; animation: spinY 5s cubic-bezier(.65, 0, .35, 1) infinite; }
.cta__btn { margin-top: 36px; }

/* ---------- FOOTER ---------- */
.footer { position: relative; overflow: hidden; min-height: max(640px, 92vh); background: var(--navy-deep); color: var(--white); display: flex; flex-direction: column; }
.footer__inner, .footer__copy { position: relative; z-index: 2; pointer-events: none; }
.footer__inner a { pointer-events: auto; }
.footer__inner { display: grid; grid-template-columns: 1.2fr 1fr; gap: 40px; padding-top: 48px; }
.footer__name { font-size: clamp(28px, 3.2vw, 44px); font-weight: 400; letter-spacing: -.02em; }
.footer__meta { margin-top: 10px; font-size: 13px; color: var(--muted-on-dark); }
.footer__meta a:hover { color: var(--white); }
.footer__cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 24px; }
.footer__title { font-size: 13px; margin-bottom: 18px; }
.footer__cols li + li { margin-top: 12px; }
.footer__cols a { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--muted-on-dark); transition: color .3s; }
.footer__cols a:hover { color: var(--white); }
.footer__cols .arrow { width: 11px; height: 11px; }
.footer__balls { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 1; cursor: grab; }
.footer__copy { margin-top: auto; padding-bottom: 24px; font-size: 12px; color: var(--muted-on-dark); }

/* ---------- CASE (صفحة المشروع) ---------- */
html.case-open, html.case-open body { overflow: hidden; }
.case { position: fixed; inset: 0; z-index: 80; background: var(--bg-light); color: var(--text-on-light); }
.case[hidden] { display: none; }
.case .label { color: var(--muted-on-light); }
.case__scroll { position: absolute; inset: 0; overflow-y: auto; overflow-x: hidden; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
.case__bar {
  position: sticky; top: 0; z-index: 5; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 16px;
  height: 72px; padding: 0 var(--gutter);
  background: rgba(241, 245, 251, .78); backdrop-filter: blur(18px) saturate(140%); -webkit-backdrop-filter: blur(18px) saturate(140%);
  border-bottom: 1px solid var(--light-line);
}
.case__brand { display: inline-flex; align-items: center; gap: 8px; justify-self: start; font-size: 19px; font-weight: 500; letter-spacing: -.02em; }
.case__brand .mark { width: 22px; height: 22px; --mark-core: transparent; }
.case__brand:hover .mark { transform: rotateY(180deg); }
.case__counter { font-family: var(--font-mono); font-size: 11px; letter-spacing: .12em; color: var(--muted-on-light); }
.case__close {
  justify-self: end; display: inline-flex; align-items: center; gap: 12px; height: 40px; padding: 0 12px 0 16px; border-radius: 8px;
  background: var(--navy); color: var(--white); font-family: var(--font-mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase;
  transition: background-color .3s;
}
.case__close:hover { background: var(--tech); color: var(--on-accent); }
.case__close:hover .btn__roll > span, .case__close:hover .btn__roll::after { transform: translateY(-100%); }
.case__close:active { transform: scale(.96); }
.case__close i, .lightbox__close i { position: relative; width: 14px; height: 14px; transition: transform .6s var(--ease-out); }
.case__close i::before, .case__close i::after, .lightbox__close i::before, .lightbox__close i::after {
  content: ""; position: absolute; left: 50%; top: 50%; width: 15px; height: 1.6px; border-radius: 2px; background: currentColor;
}
.case__close i::before, .lightbox__close i::before { transform: translate(-50%, -50%) rotate(45deg); }
.case__close i::after, .lightbox__close i::after { transform: translate(-50%, -50%) rotate(-45deg); }
.case__close:hover i, .lightbox__close:hover i { transform: rotate(90deg); }

.case__body { width: 100%; max-width: calc(1280px + 2 * var(--gutter)); margin: 0 auto; padding: 0 var(--gutter) 40px; }
.case__intro { padding: clamp(48px, 9vh, 110px) 0 clamp(40px, 7vh, 80px); }
.case__logo { display: flex; align-items: flex-end; height: clamp(52px, 7vw, 84px); margin-bottom: 28px; }
.case__logo img { height: 100%; width: auto; max-width: min(340px, 70vw); object-fit: contain; object-position: left bottom; }
.case__title { font-size: clamp(46px, 8.4vw, 132px); font-weight: 500; line-height: .95; letter-spacing: -.045em; }
.case__info { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: clamp(28px, 6vw, 96px); margin-top: clamp(32px, 5vw, 64px); padding-top: 28px; border-top: 1px solid var(--light-line); }
.case__about { max-width: 620px; font-size: clamp(16px, 1.35vw, 19px); line-height: 1.5; letter-spacing: -.005em; color: rgba(var(--navy-rgb), .78); }
.case__meta { display: grid; grid-template-columns: 1fr 1fr; gap: 20px 24px; align-content: start; }
.case__meta dt { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted-on-light); margin-bottom: 6px; }
.case__meta dd { font-size: 14px; }

.case__gallery { display: grid; gap: clamp(12px, 1.4vw, 20px); }
.g-row { display: grid; gap: clamp(12px, 1.4vw, 20px); opacity: 0; transform: translateY(60px); transition: opacity 1s, transform 1.4s var(--ease-out); }
.g-row.is-in { opacity: 1; transform: none; }
.g-row--2, .g-row--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g-row--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g-item {
  position: relative; display: block; width: 100%; overflow: hidden; border-radius: var(--radius-md); cursor: zoom-in;
  background: linear-gradient(110deg, #E2EDF7 30%, #F4F8FC 50%, #E2EDF7 70%); background-size: 250% 100%; animation: shimmer 1.6s linear infinite;
}
.g-item.is-loaded { animation: none; background: transparent; }
.g-item img { width: 100%; height: auto; opacity: 0; transform: scale(1.03); transition: opacity .9s, transform 1.4s var(--ease-out); }
.g-item.is-loaded img { opacity: 1; transform: none; }
.g-item::after {
  content: ""; position: absolute; right: 14px; top: 14px; width: 36px; height: 36px; border-radius: 50%;
  background: rgba(255, 255, 255, .92) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M9.5 3H13v3.5M13 3L8.8 7.2M6.5 13H3V9.5M3 13l4.2-4.2' fill='none' stroke='%23000E29' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 15px no-repeat;
  opacity: 0; transform: scale(.7); transition: opacity .35s, transform .5s var(--ease-out);
}
.g-item:hover::after, .g-item:focus-visible::after { opacity: 1; transform: none; }

.case__next { display: block; margin-top: clamp(60px, 10vh, 120px); padding-top: 28px; border-top: 1px solid var(--light-line); opacity: 0; transform: translateY(60px); transition: opacity 1s, transform 1.4s var(--ease-out); }
.case__next.is-in { opacity: 1; transform: none; }
.case__next .label { margin-bottom: 14px; }
.case__next-title { display: flex; align-items: center; gap: .25em; font-size: clamp(38px, 6.4vw, 96px); font-weight: 500; line-height: 1; letter-spacing: -.04em; }
.case__next-title .arrow { width: .5em; height: .5em; color: var(--tech); transition: transform .6s var(--ease-out); }
.case__next:hover .case__next-title .arrow { transform: translateX(10px); }
.case__next-media { position: relative; display: block; margin-top: 28px; aspect-ratio: 21 / 9; overflow: hidden; border-radius: var(--radius-lg); background: radial-gradient(120% 90% at 50% 0%, var(--white), #D8E7F5 70%, var(--steel)); }
.case__next-media img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.4s var(--ease-out), opacity .9s; opacity: 0; }
.case__next-media.is-loaded img { opacity: 1; }
.case__next-media.is-contain img { object-fit: contain; padding: 4%; }
.case__next:hover .case__next-media img { transform: scale(1.04); }

/* ---------- LIGHTBOX ---------- */
.lightbox { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; background: rgba(1, 6, 17, .94); backdrop-filter: blur(10px); color: var(--white); touch-action: pan-y; }
.lightbox[hidden] { display: none; }
.lightbox__stage { display: grid; place-items: center; width: 100%; height: 100%; padding: 70px clamp(16px, 7vw, 110px); }
.lightbox__stage img { max-width: 100%; max-height: 100%; width: auto; height: auto; border-radius: 10px; box-shadow: 0 40px 100px rgba(0, 0, 0, .5); user-select: none; -webkit-user-select: none; }
.lightbox__btn, .lightbox__close {
  position: absolute; display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%;
  background: rgba(var(--steel-rgb), .1); border: 1px solid var(--navy-line); color: var(--white);
  transition: background-color .3s, transform .4s var(--ease-out);
}
.lightbox__btn:hover, .lightbox__close:hover { background: var(--tech); color: var(--on-accent); }
.lightbox__btn svg { width: 18px; height: 18px; }
.lightbox__btn--prev { left: clamp(10px, 2vw, 32px); top: 50%; transform: translateY(-50%); }
.lightbox__btn--next { right: clamp(10px, 2vw, 32px); top: 50%; transform: translateY(-50%); }
.lightbox.is-single .lightbox__btn { display: none; }
.lightbox__close { top: 16px; right: 16px; }
.lightbox__count { position: absolute; left: 50%; bottom: 22px; transform: translateX(-50%); font-family: var(--font-mono); font-size: 11px; letter-spacing: .14em; color: var(--muted-on-dark); }

/* ---------- Keyframes ---------- */
@keyframes shimmer { to { background-position: -150% 0; } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes spinY { 0%, 30% { transform: rotateY(0); } 70%, 100% { transform: rotateY(360deg); } } /* الأيقونة بتلف زي العملة */
@keyframes pulse { 50% { box-shadow: 0 0 0 7px rgba(74, 222, 128, 0); } }
@keyframes sway { 0%, 100% { transform: rotateY(-32deg) rotateX(8deg); } 50% { transform: rotateY(32deg) rotateX(-6deg); } }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px 14px; }
  .toolbox { flex-direction: column; align-items: stretch; gap: 18px; }
  .toolbox__head { width: auto; }
}
@media (max-width: 900px) {
  .case__info { grid-template-columns: 1fr; }
  .table--exp .row { grid-template-columns: 1fr 1fr minmax(110px, auto); }
  .table--exp .row span:nth-child(3) { display: none; }
  .accordion { flex-direction: column; height: auto; }
  .acc { flex: 0 0 68px; min-height: 68px; transition: min-height .8s var(--ease-out); }
  .acc.is-open { flex: 0 0 auto; min-height: 640px; }
  .acc__vertical { writing-mode: horizontal-tb; transform: none; right: auto; left: 22px; bottom: auto; top: 18px; font-size: 22px; }
  .acc__body { min-width: 0; grid-template-columns: 1fr; padding: 24px; align-content: start; }
  .acc__visual { height: 260px; }
  .founder { grid-template-columns: 1fr; }
  .founder__bio { padding: 6px 10px 12px; }
  .footer__inner { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .section-head { flex-direction: column; align-items: flex-start; }
  .bento__row--2, .bento__row--3 { grid-template-columns: 1fr; }
  .hl { height: 340px; }
  .stack { gap: 6vh; }
  .stack__card { height: auto; aspect-ratio: 16 / 11; top: 16vh; }
  .stack__caption .tags { display: none; }
  .stack__caption h3 { margin-bottom: 0; font-size: 18px; }
  .row { grid-template-columns: 1fr 1fr; font-size: 12px; }
  .row span:nth-child(3) { display: none; }
  .toolbox { flex-direction: column; align-items: flex-start; padding: 20px 0 20px 20px; }
  .hero__buttons { flex-wrap: wrap; }
  .hero__canvas { height: 46%; }
  .has-hero-photo .hero__inner { padding-top: 100px; }
  .has-hero-photo .hero__title { font-size: 13vw; }
  .has-hero-photo .hero__text { font-size: 13px; max-width: 320px; }
  .has-hero-photo .hero__buttons { margin-top: 16px; flex-wrap: nowrap; }
  .has-hero-photo .hero__buttons .btn { height: 38px; padding: 0 12px; gap: 8px; }
  .hero__meta { display: none; }
  .hero__photo { width: calc(min(66vh, 150vw) * 1.011); left: 50%; right: auto; margin: 0; translate: -50% 0; }
  .keys { grid-template-columns: repeat(2, 70px); } .keys span { height: 70px; }

  .logo-item { height: 48px; }
  .logo-item img { height: calc(var(--h, 32px) * .78); }
  .stack__view { right: 14px; bottom: 14px; height: 34px; padding: 0 10px; }
  .stack__view > span { display: none; }
  .stack__caption { left: 16px; bottom: 18px; right: 130px; }
  .grid { grid-template-columns: 1fr; gap: 28px; }
  .filters { flex-wrap: nowrap; overflow-x: auto; margin-inline: calc(-1 * var(--gutter)); padding-inline: var(--gutter); scrollbar-width: none; }
  .filters::-webkit-scrollbar { display: none; }
  .chip { flex-shrink: 0; }
  .bento__row--stats { grid-template-columns: 1fr 1fr; }
  .stat { padding: 34px 14px; }
  .skills { grid-template-columns: 1fr; }
  .table--exp .row { grid-template-columns: 1fr auto; gap: 4px 12px; padding: 14px 10px; }
  .table--exp .row span:nth-child(2) { grid-column: 1; grid-row: 2; font-size: 12.5px; }
  .table--exp .row span:nth-child(4) { grid-column: 2; grid-row: 1; }

  .case__bar { height: 62px; grid-template-columns: 1fr auto; }
  .case__counter { display: none; }
  .case__meta { grid-template-columns: 1fr 1fr; }
  .g-row--2, .g-row--4 { grid-template-columns: 1fr; }
  /* صفوف البوستات (3 صور) بتتسحب بالعرض على الموبايل */
  .g-row--3 {
    display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none;
    margin-inline: calc(-1 * var(--gutter)); padding-inline: var(--gutter); scroll-padding-inline: var(--gutter);
  }
  .g-row--3::-webkit-scrollbar { display: none; }
  .g-row--3 .g-item { flex: 0 0 82%; scroll-snap-align: start; }
  .case__next-media { aspect-ratio: 16 / 10; }
  .lightbox__btn { width: 40px; height: 40px; top: auto; bottom: 12px; transform: none; }
  .lightbox__stage { padding: 64px 12px 70px; }
}

/* احترام إعداد تقليل الحركة */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .stack__card { position: relative; top: 0; }
  .g-row, .case__next, .g-item img, .case__next-media img { opacity: 1; transform: none; }
}
