/* Medhal – medhal.app · a scroll-driven story. Brand navy from the logo, gold from the arena light. */
:root {
  --night: #081633; --navy: #12306b; --navy-2: #1e3a7b; --sky-l: #eef2fa;
  --gold: #d6b47a; --gold-d: #a9844b; --sand: #e8d3ae; --cream: #faf6ee;
  --ink: #142038; --ink-2: #4a5570; --line: #e6e9f0;
  --r: 24px; --ease: cubic-bezier(.2, .8, .2, 1);
  --f-ar: "IBM Plex Sans Arabic", system-ui, -apple-system, "Segoe UI", Tahoma, sans-serif;
  --f-ar-d: "Reem Kufi", "IBM Plex Sans Arabic", sans-serif;
  --f-en: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --f-en-d: "Playfair Display", Georgia, serif;
  --vh: 1vh;
}
@supports (height: 1svh) { :root { --vh: 1svh; } }
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; background: var(--night); }
body { margin: 0; font-family: var(--f-en); color: var(--ink); background: #fff; line-height: 1.65; font-size: 17px; -webkit-font-smoothing: antialiased; overflow-x: clip; }
body.lang-ar { font-family: var(--f-ar); font-size: 17.5px; line-height: 1.85; }
img, video { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { margin: 0; line-height: 1.15; }
h2 { font-size: clamp(32px, 4.6vw, 60px); font-weight: 700; letter-spacing: -.015em; margin-bottom: 18px; }
.lang-en h2 { font-family: var(--f-en-d); }
.lang-ar h2 { font-family: var(--f-ar-d); letter-spacing: 0; line-height: 1.35; font-weight: 600; }
p { margin: 0 0 1em; }
.wrap { width: min(1200px, calc(100% - 40px)); margin-inline: auto; }
.narrow { width: min(820px, calc(100% - 40px)); }
.center { text-align: center; }
.ic { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.skip { position: absolute; inset-inline-start: -999px; top: 8px; background: var(--navy); color: #fff; padding: 8px 14px; border-radius: 8px; z-index: 200; }
.skip:focus { inset-inline-start: 8px; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; border-radius: 6px; }

/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; padding: 14px 24px; border-radius: 999px; font-weight: 600; font-size: 16px; text-decoration: none; border: 1.5px solid transparent; cursor: pointer; transition: transform .3s var(--ease), box-shadow .3s, background .3s; font-family: inherit; white-space: nowrap; }
.btn:hover { transform: translateY(-2px); }
.btn-gold { background: linear-gradient(135deg, #e5c68e, var(--gold-d)); color: #1c1407; box-shadow: 0 10px 28px rgba(169, 132, 75, .4); }
.btn-line { border-color: rgba(18, 48, 107, .25); color: var(--navy); }
.btn-line:hover { background: var(--sky-l); }
.btn-glass { background: rgba(255, 255, 255, .12); border-color: rgba(255, 255, 255, .35); color: #fff; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.btn-sm { padding: 9px 16px; font-size: 14px; }
.btn-lg { padding: 17px 30px; font-size: 17px; }
.btn-block { width: 100%; }

/* ---------- Chrome: progress, header, chapter dots ---------- */
.progress { position: fixed; inset: 0 0 auto; height: 3px; z-index: 100; }
.progress i { display: block; height: 100%; background: linear-gradient(90deg, var(--gold), #f3dcb0); transform-origin: left; transform: scaleX(var(--prog, 0)); }
[dir=rtl] .progress i { transform-origin: right; }
.hdr { position: fixed; top: 14px; inset-inline: 16px; z-index: 90; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 8px 8px 14px; border-radius: 999px; background: rgba(8, 22, 51, .55); backdrop-filter: blur(16px) saturate(1.4); -webkit-backdrop-filter: blur(16px) saturate(1.4); border: 1px solid rgba(255, 255, 255, .1); color: #fff; transition: transform .5s var(--ease); }
[dir=rtl] .hdr { padding: 8px 14px 8px 8px; }
.hdr.hide { transform: translateY(-140%); }
.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.logo img { width: 40px; height: 40px; border-radius: 50%; background: #fff; }
.logo span { display: grid; line-height: 1.15; }
.logo b { font-size: 17px; }
.logo small { font-size: 12px; color: var(--gold); transition: opacity .3s; }
.hdr-end { display: flex; align-items: center; gap: 8px; }
.lang { text-decoration: none; font-size: 14px; font-weight: 600; padding: 8px 14px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .25); }
.lang:hover { background: rgba(255, 255, 255, .1); }
.dots { position: fixed; inset-inline-end: 18px; top: 50%; transform: translateY(-50%); z-index: 80; display: grid; gap: 14px; }
.dots a { display: flex; align-items: center; gap: 10px; flex-direction: row-reverse; text-decoration: none; }
.dots i { width: 10px; height: 10px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .7); background: transparent; box-shadow: 0 0 0 3px rgba(8, 22, 51, .25); transition: all .35s var(--ease); }
.dots span { font-size: 12.5px; font-weight: 600; color: #fff; background: rgba(8, 22, 51, .7); padding: 3px 10px; border-radius: 99px; opacity: 0; transform: translateX(8px); transition: all .3s var(--ease); pointer-events: none; white-space: nowrap; }
[dir=rtl] .dots span { transform: translateX(-8px); }
.dots a:hover span, .dots a.on span { opacity: 1; transform: none; }
.dots a.on i { background: var(--gold); border-color: var(--gold); transform: scale(1.35); }
.dots.light i { border-color: rgba(18, 48, 107, .5); box-shadow: none; }

/* ---------- Scroll scenes ---------- */
.scene { position: relative; height: calc(var(--h) * var(--vh)); }
.pin { position: sticky; top: 0; height: calc(100 * var(--vh)); overflow: hidden; }
.chap-tag { display: inline-flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 600; color: var(--gold); margin-bottom: 14px; }
.chap-tag span { font-size: 12px; letter-spacing: .14em; text-transform: uppercase; padding: 4px 10px; border-radius: 99px; border: 1px solid currentColor; opacity: .85; }
.lang-ar .chap-tag span { letter-spacing: 0; }

/* Prologue */
.s-intro .pin { background: var(--night); color: #fff; display: grid; place-items: center; }
.sky, .sky i { position: absolute; inset: 0; }
.sky .night { background: radial-gradient(900px 500px at 70% 20%, rgba(80, 120, 210, .35), transparent 60%), radial-gradient(800px 600px at 10% 90%, rgba(30, 58, 123, .6), transparent 60%), linear-gradient(180deg, #050d22, #0b2150 70%, #14306a); }
.sky .dawn { background: linear-gradient(180deg, #0b2150 0%, #45417a 38%, #c98b6b 66%, #f1c98b 82%, #f7dcae 100%); opacity: calc(var(--p, 0) * 1.25); }
.sky .sun { inset: auto; left: 50%; top: 52%; width: 34vmin; height: 34vmin; border-radius: 50%; translate: -50% calc((1 - var(--p, 0)) * 40vh); background: radial-gradient(circle, #fff4dd 0%, #f6d79e 35%, rgba(246, 215, 158, 0) 70%); opacity: calc(.25 + var(--p, 0) * .9); filter: blur(2px); }
.dust { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.ground { position: absolute; inset: auto 0 0; height: 32%; perspective: 420px; perspective-origin: 50% 0%; overflow: hidden; -webkit-mask-image: linear-gradient(180deg, transparent, #000 55%); mask-image: linear-gradient(180deg, transparent, #000 55%); }
.ground i { position: absolute; inset: 0 -60%; transform-origin: 50% 0; transform: rotateX(62deg); background:
  repeating-linear-gradient(0deg, rgba(255, 255, 255, .0) 0 46px, rgba(255, 240, 210, .18) 46px 48px),
  linear-gradient(180deg, #2a3567 0%, #8a6a55 45%, #d9b583 100%); background-position: 0 calc(var(--p, 0) * 900px), 0 0; }
.ground::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, var(--night) 0%, transparent 45%); opacity: calc(1 - var(--p, 0)); }
.leap { position: absolute; left: 0; top: 0; width: clamp(240px, 36vw, 560px); will-change: transform, opacity; z-index: 3; pointer-events: none; }
.leap img { width: 100%; filter: drop-shadow(0 18px 40px rgba(214, 180, 122, .35)); animation: gallop 1.1s ease-in-out infinite alternate; }
@keyframes gallop { from { transform: rotate(-2deg) translateY(0); } to { transform: rotate(2deg) translateY(-10px); } }
.intro-text { position: relative; z-index: 4; text-align: center; padding: 0 20px; transform: translateY(calc(var(--p, 0) * -28vh)); opacity: calc(1 - var(--p, 0) * 2.4); }
.s-intro .kicker { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 600; color: var(--gold); background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .14); padding: 6px 14px; border-radius: 999px; margin-bottom: 10px; animation: fadeUp 1s .2s both; }
.s-intro .kicker .ic { width: 16px; height: 16px; }
h1 { font-size: clamp(76px, 15vw, 210px); font-weight: 700; line-height: 1.05; margin: 0 0 6px; }
.lang-en h1 { font-family: var(--f-en-d); letter-spacing: -.03em; }
.lang-ar h1 { font-family: var(--f-ar-d); }
.word span { display: inline-block; background: linear-gradient(180deg, #fff 30%, #f0d6a6 100%); -webkit-background-clip: text; background-clip: text; color: transparent; animation: letter 1.1s var(--ease) both; animation-delay: calc(.35s + var(--i) * .07s); }
.lang-ar .word span { animation-delay: .35s; }
@keyframes letter { from { opacity: 0; transform: translateY(.5em) rotateX(-70deg); filter: blur(8px); } to { opacity: 1; transform: none; filter: none; } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: none; } }
.s-intro .line { font-size: clamp(19px, 2.3vw, 28px); font-weight: 600; margin: 0 0 6px; animation: fadeUp 1s .9s both; }
.s-intro .sub { color: rgba(255, 255, 255, .7); animation: fadeUp 1s 1.1s both; }
.lang-en .s-intro .sub { font-family: var(--f-en-d); font-style: italic; font-size: 20px; }
.cue { position: absolute; bottom: 4vh; left: 50%; transform: translateX(-50%); z-index: 4; display: grid; justify-items: center; gap: 10px; font-size: 13px; color: rgba(255, 255, 255, .75); opacity: calc(1 - var(--p, 0) * 6); animation: cueIn 1.2s 1.4s both; }
@keyframes cueIn { from { translate: 0 24px; filter: blur(6px); } }
.mouse { width: 26px; height: 40px; border: 2px solid rgba(255, 255, 255, .6); border-radius: 14px; position: relative; }
.mouse i { position: absolute; left: 50%; top: 7px; width: 4px; height: 8px; margin-left: -2px; border-radius: 2px; background: var(--gold); animation: wheel 1.6s ease-in-out infinite; }
@keyframes wheel { 0% { transform: translateY(0); opacity: 1; } 70% { transform: translateY(12px); opacity: 0; } 100% { opacity: 0; } }

/* Chapter 1 – the photo grows from a circle into the whole screen */
.s-meet .pin { background: radial-gradient(800px 500px at 50% 55%, #16336f, var(--night)); color: #fff; }
.s-meet .pin::before { content: "01"; position: absolute; inset: 0; display: grid; place-items: center; font-family: var(--f-en-d); font-size: 40vmin; color: rgba(255, 255, 255, .03); }
.meet-media { position: absolute; inset: 0; --g: min(1, calc(var(--p, 0) * 1.7)); overflow: hidden; transform: scale(calc(.34 + var(--g) * .66)) rotate(calc((1 - var(--g)) * -4deg)); border-radius: calc((1 - var(--g)) * 46vmin); box-shadow: 0 40px 120px rgba(0, 0, 0, calc((1 - var(--g)) * .6)); will-change: transform, border-radius; }
.meet-media img, .meet-media video { width: 100%; height: 100%; object-fit: cover; object-position: 55% 30%; transform: scale(calc(1.15 - var(--g) * .15)); }
.meet-shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(8, 22, 51, .1) 30%, rgba(8, 22, 51, .88) 100%); opacity: min(1, calc(var(--p, 0) * 2)); }
.meet-text { position: absolute; inset: auto 0 9vh; width: min(980px, calc(100% - 40px)); margin-inline: auto; }
.meet-text h2 { color: #fff; opacity: clamp(0, calc((var(--p, 0) - .14) * 6), 1); transform: translateY(calc((1 - clamp(0, calc((var(--p, 0) - .14) * 6), 1)) * 40px)); }
.meet-text .chap-tag { opacity: clamp(0, calc((var(--p, 0) - .05) * 8), 1); }
.mline { --v: clamp(0, calc((var(--p, 0) - var(--a)) * 7), 1); font-size: clamp(18px, 2.1vw, 26px); color: rgba(255, 255, 255, .9); margin: 0 0 .5em; opacity: var(--v); transform: translateY(calc((1 - var(--v)) * 26px)); filter: blur(calc((1 - var(--v)) * 6px)); }
.mline:last-child { font-size: clamp(16px, 1.5vw, 19px); color: rgba(255, 255, 255, .7); max-width: 640px; }

/* Chapter 2 – horizontal 3D track */
.s-learn .pin { background: linear-gradient(180deg, var(--cream), #fff); display: flex; flex-direction: column; justify-content: center; gap: 4vh; }
.learn-head { width: min(1200px, calc(100% - 40px)); margin-inline: auto; padding-top: 70px; }
.learn-head p { color: var(--ink-2); font-size: 18px; max-width: 560px; margin: 0; }
.learn-head h2 { color: var(--night); }
.track-wrap { perspective: 1400px; perspective-origin: 50% 50%; }
.track { display: flex; gap: 28px; padding-inline: max(20px, calc((100vw - 1200px) / 2)); width: max-content; will-change: transform; transform-style: preserve-3d; }
.lcard { width: min(400px, 76vw); min-height: min(46vh, 380px); padding: 34px 30px; border-radius: 28px; background: #fff; border: 1px solid var(--line); box-shadow: 0 30px 60px rgba(11, 31, 71, .1); display: flex; flex-direction: column; justify-content: flex-end; position: relative; overflow: hidden; will-change: transform; transform-style: preserve-3d; }
.lcard::before { content: ""; position: absolute; inset: auto -30% -40% auto; width: 260px; height: 260px; border-radius: 50%; background: radial-gradient(circle, rgba(214, 180, 122, .25), transparent 70%); }
.lcard .n { position: absolute; top: 22px; inset-inline-start: 28px; font-family: var(--f-en-d); font-size: 84px; line-height: 1; color: rgba(18, 48, 107, .12); }
.lcard h3 { font-size: 24px; color: var(--night); margin-bottom: 10px; }
.lang-ar .lcard h3 { font-family: var(--f-ar-d); font-weight: 600; }
.lcard p { color: var(--ink-2); margin: 0; }
.lcard.is-big { background: linear-gradient(160deg, var(--navy), var(--night)); color: #fff; border: 0; }
.lcard.is-big .n { position: static; color: var(--gold); font-size: 120px; margin-bottom: auto; }
.lcard.is-big .n small { font-size: 26px; margin-inline-start: 10px; font-family: var(--f-en); color: #fff; }
.lang-ar .lcard.is-big .n small { font-family: var(--f-ar); }
.lcard.is-big h3 { color: #fff; }
.lcard.is-big p { color: rgba(255, 255, 255, .75); }
.track-bar { width: min(1200px, calc(100% - 40px)); margin-inline: auto; height: 3px; border-radius: 3px; background: var(--line); overflow: hidden; }
.track-bar i { display: block; height: 100%; width: 100%; background: var(--gold); transform-origin: left; transform: scaleX(var(--p, 0)); }
[dir=rtl] .track-bar i { transform-origin: right; }

/* Chapter 3 – a 3D arena, poles rushing at you */
.s-jump .pin { background: radial-gradient(1200px 700px at 50% 0%, #1f3f86, var(--night) 70%); color: #fff; }
.arena { position: absolute; inset: 0; perspective: 700px; perspective-origin: 50% 30%; overflow: hidden; }
.floor { position: absolute; left: -60%; right: -60%; bottom: -10%; height: 90%; transform-origin: 50% 100%; transform: rotateX(80deg); background:
  repeating-linear-gradient(0deg, transparent 0 70px, rgba(255, 235, 200, .16) 70px 72px),
  radial-gradient(60% 100% at 50% 100%, #e7c896, #b78a5b 55%, #2a2f5a 100%); background-position: 0 calc(var(--p, 0) * 2600px), 0 0; }
.fence { position: absolute; left: 50%; bottom: 22%; width: 460px; height: 150px; margin-left: -230px; will-change: transform, opacity; transform-origin: 50% 100%; }
.fence i { position: absolute; left: 4%; right: 4%; height: 13px; border-radius: 8px; background: repeating-linear-gradient(90deg, #fff 0 42px, var(--navy-2) 42px 84px); box-shadow: 0 8px 20px rgba(0, 0, 0, .35); }
.fence i:nth-child(1) { top: 20%; } .fence i:nth-child(2) { top: 45%; } .fence i:nth-child(3) { top: 70%; }
.fence b { position: absolute; bottom: 0; width: 18px; height: 100%; border-radius: 4px; background: linear-gradient(90deg, #f6f1e6, #d9cfbb); }
.fence b:nth-of-type(1) { left: 0; } .fence b:nth-of-type(2) { right: 0; }
.flyover { position: absolute; left: 0; top: 0; width: clamp(200px, 30vw, 460px); opacity: 0; z-index: 2; will-change: transform, opacity; filter: drop-shadow(0 20px 40px rgba(0, 0, 0, .4)); pointer-events: none; }
.jump-grid { position: relative; z-index: 3; height: 100%; width: min(1200px, calc(100% - 40px)); margin-inline: auto; display: grid; grid-template-columns: 1fr 1fr; gap: 90px; align-items: center; }
.jump-text { opacity: clamp(0, calc((var(--p, 0) - .04) * 5), 1); transform: translateY(calc((1 - clamp(0, calc((var(--p, 0) - .04) * 5), 1)) * 40px)); text-shadow: 0 2px 24px rgba(8, 22, 51, .6); }
.jump-text { padding: 30px 32px; border-radius: 28px; background: linear-gradient(160deg, rgba(8, 22, 51, .72), rgba(8, 22, 51, .45)); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border: 1px solid rgba(255, 255, 255, .08); }
.jump-text p { font-size: 19px; color: rgba(255, 255, 255, .85); max-width: 520px; }
.jstats { display: flex; flex-wrap: wrap; gap: 30px; margin-top: 28px; }
.jstats div { display: grid; }
.jstats b { font-family: var(--f-en-d); font-size: clamp(40px, 5vw, 64px); line-height: 1; color: var(--gold); font-variant-numeric: tabular-nums; }
.jstats small { font-size: 14px; color: rgba(255, 255, 255, .7); }
.jump-card { justify-self: center; width: min(440px, 100%); aspect-ratio: 4 / 5; border-radius: 220px 220px 30px 30px; overflow: hidden; border: 6px solid rgba(255, 255, 255, .12); box-shadow: 0 50px 100px rgba(0, 0, 0, .5); transform: perspective(1000px) rotateY(calc((1 - min(1, calc(var(--p, 0) * 1.6))) * -28deg)) translateY(calc((1 - min(1, calc(var(--p, 0) * 1.6))) * 18vh)) scale(calc(.82 + min(1, calc(var(--p, 0) * 1.6)) * .18)); will-change: transform; }
[dir=rtl] .jump-card { transform: perspective(1000px) rotateY(calc((1 - min(1, calc(var(--p, 0) * 1.6))) * 28deg)) translateY(calc((1 - min(1, calc(var(--p, 0) * 1.6))) * 18vh)) scale(calc(.82 + min(1, calc(var(--p, 0) * 1.6)) * .18)); }
.jump-card img, .jump-card video { width: 100%; height: 100%; object-fit: cover; object-position: 40% 50%; }

/* Chapter 4 – boarding packages fan out like a deck */
.s-home .pin { background: radial-gradient(900px 500px at 80% 0%, #fff, var(--cream)); display: flex; flex-direction: column; justify-content: center; gap: 3vh; }
.home-head { width: min(1200px, calc(100% - 40px)); margin-inline: auto; padding-top: 60px; }
.home-head h2 { color: var(--night); }
.home-head p { color: var(--ink-2); max-width: 720px; font-size: 17px; margin: 0; }
.deck { width: min(1200px, calc(100% - 40px)); margin-inline: auto; display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; --e: 0; }
.price-card { position: relative; background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 26px 22px; display: flex; flex-direction: column; gap: 12px; box-shadow: 0 24px 50px rgba(11, 31, 71, .1); transform: translate3d(calc(var(--dx, 0px) * (1 - var(--e))), calc(var(--dy, 0px) * (1 - var(--e))), 0) rotate(calc((var(--i) - 1.5) * 7deg * (1 - var(--e)))); will-change: transform; z-index: calc(4 - var(--i)); }
.price-card.is-full { background: linear-gradient(165deg, var(--navy), var(--night)); color: #fff; border: 0; }
.price-card h3 { font-size: 19px; }
.pkg { font-size: 14px; font-weight: 600; color: var(--gold-d); }
.is-full .pkg { color: var(--gold); }
.amount { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.amount b { font-size: 38px; line-height: 1; font-family: var(--f-en-d); }
.amount span { font-size: 13.5px; opacity: .7; }
.incl { list-style: none; padding: 0; margin: 0 0 auto; display: grid; gap: 8px; font-size: 14.5px; }
.incl li { display: flex; gap: 8px; align-items: flex-start; line-height: 1.5; }
.incl .ic { width: 17px; height: 17px; color: var(--gold); margin-top: 3px; }
.tag { position: absolute; top: -12px; inset-inline-end: 16px; background: linear-gradient(135deg, #e5c68e, var(--gold-d)); color: #1c1407; font-size: 12.5px; font-weight: 700; padding: 5px 12px; border-radius: 999px; }
.fine { font-size: 13.5px; color: var(--ink-2); text-align: center; margin: 0; }

/* Chapter 5 – coffee */
.s-coffee { background: linear-gradient(135deg, #3b2616, #5c3b22 55%, #7a5232); color: #fff; padding: clamp(80px, 12vw, 150px) 0; overflow: hidden; }
.coffee { display: grid; grid-template-columns: .8fr 1.2fr; gap: 60px; align-items: center; }
.cup { position: relative; justify-self: center; width: min(300px, 60vw); aspect-ratio: 1; border-radius: 50%; display: grid; place-items: center; background: radial-gradient(circle at 50% 60%, rgba(255, 220, 170, .18), transparent 65%); }
.cup > .ic { width: 62%; height: 62%; stroke-width: 1.1; color: #f3dcb0; }
.steam { position: absolute; top: 4%; width: 10px; height: 90px; border-radius: 10px; background: linear-gradient(180deg, transparent, rgba(255, 255, 255, .35)); filter: blur(4px); animation: steam 3.2s ease-in-out infinite; }
.steam.s1 { left: 36%; } .steam.s2 { left: 47%; animation-delay: .8s; } .steam.s3 { left: 58%; animation-delay: 1.6s; }
@keyframes steam { 0% { transform: translateY(40px) scaleY(.6); opacity: 0; } 40% { opacity: 1; } 100% { transform: translateY(-50px) scaleY(1.2) translateX(10px); opacity: 0; } }
.coffee-text p { font-size: 19px; color: rgba(255, 255, 255, .85); }
.s-coffee .chap-tag { color: #f3dcb0; }
.tags { list-style: none; padding: 0; margin: 20px 0 0; display: flex; flex-wrap: wrap; gap: 10px; }
.tags li { padding: 8px 16px; border-radius: 999px; background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .18); font-size: 14.5px; }

/* Chapter 6 – the app, a 3D phone */
.s-app .pin { background: radial-gradient(900px 600px at 20% 30%, var(--sky-l), #fff 70%); display: grid; align-items: center; }
.app { display: grid; grid-template-columns: 1.05fr .95fr; gap: 50px; align-items: center; }
.app-text { opacity: clamp(0, calc(var(--p, 0) * 4), 1); transform: translateY(calc((1 - clamp(0, calc(var(--p, 0) * 4), 1)) * 40px)); }
.app-text h2 { color: var(--night); }
.app-text > p { color: var(--ink-2); font-size: 18px; }
.ticks { list-style: none; padding: 0; margin: 0 0 30px; display: grid; gap: 10px; }
.ticks li { display: flex; gap: 10px; align-items: center; font-weight: 500; }
.ticks .ic { color: #fff; background: var(--navy); border-radius: 50%; padding: 4px; width: 26px; height: 26px; }
.stores { display: flex; flex-wrap: wrap; gap: 12px; }
.store { display: inline-flex; align-items: center; gap: 12px; background: var(--night); color: #fff; padding: 11px 22px 11px 18px; border-radius: 16px; text-decoration: none; transition: transform .3s var(--ease), background .3s; min-width: 190px; }
.store:hover { transform: translateY(-3px); background: var(--navy-2); }
.store .ic { width: 30px; height: 30px; }
.store span { display: grid; line-height: 1.15; }
.store small { font-size: 12px; opacity: .8; }
.store b { font-size: 19px; font-family: var(--f-en); }
.stage { position: relative; height: min(70vh, 620px); perspective: 1300px; display: grid; place-items: center; }
.phone { width: min(290px, 62vw); aspect-ratio: 9 / 18.5; border-radius: 46px; padding: 12px; background: linear-gradient(160deg, #1b2c52, #0a1531); box-shadow: 0 60px 100px rgba(11, 31, 71, .35), inset 0 0 0 2px rgba(255, 255, 255, .08); transform: rotateY(calc((1 - var(--p, 0)) * 42deg - 10deg)) rotateX(calc((1 - var(--p, 0)) * 14deg)) translateZ(calc(var(--p, 0) * 40px)); transform-style: preserve-3d; will-change: transform; }
[dir=rtl] .phone { transform: rotateY(calc((1 - var(--p, 0)) * -42deg + 10deg)) rotateX(calc((1 - var(--p, 0)) * 14deg)) translateZ(calc(var(--p, 0) * 40px)); }
.screen { height: 100%; border-radius: 36px; background: var(--cream); padding: 22px 16px; display: flex; flex-direction: column; gap: 12px; overflow: hidden; }
.ph-top { display: flex; align-items: center; gap: 8px; }
.ph-top img { width: 30px; height: 30px; border-radius: 50%; }
.ph-top b { color: var(--night); }
.ph-hero { border-radius: 20px; overflow: hidden; aspect-ratio: 4 / 3; }
.ph-hero img { width: 100%; height: 100%; object-fit: cover; }
.ph-row { display: flex; align-items: center; justify-content: space-between; background: #fff; border-radius: 14px; padding: 12px 14px; font-size: 13.5px; font-weight: 600; box-shadow: 0 4px 14px rgba(11, 31, 71, .06); }
.ph-row i { font-style: normal; color: var(--ink-2); font-weight: 500; }
.ph-row.on { background: var(--navy); color: #fff; margin-top: auto; }
[dir=rtl] .ph-row .ic { transform: scaleX(-1); }
.chip { position: absolute; display: flex; align-items: center; gap: 8px; background: #fff; padding: 10px 16px; border-radius: 14px; box-shadow: 0 20px 40px rgba(11, 31, 71, .15); font-size: 14px; font-weight: 600; color: var(--navy); white-space: nowrap; will-change: transform; }
.chip .ic { width: 18px; height: 18px; color: var(--gold-d); }
.chip.c1 { top: 16%; inset-inline-start: 0; transform: translateY(calc((1 - var(--p, 0)) * 80px)); opacity: clamp(0, calc((var(--p, 0) - .2) * 4), 1); }
.chip.c2 { bottom: 18%; inset-inline-end: 0; transform: translateY(calc((1 - var(--p, 0)) * -80px)); opacity: clamp(0, calc((var(--p, 0) - .35) * 4), 1); }
.chip-horse { position: absolute; width: 120px; bottom: 4%; inset-inline-start: 6%; opacity: .14; transform: translateX(calc(var(--p, 0) * 60px)); }

/* Gallery (photos dropped into src/gallery) */
.gallery { background: #fff; }
.masonry { columns: 3 280px; column-gap: 16px; margin-top: 30px; }
.masonry figure { margin: 0 0 16px; break-inside: avoid; border-radius: 18px; overflow: hidden; }
.masonry img { width: 100%; transition: transform 1s var(--ease); }
.masonry figure:hover img { transform: scale(1.05); }

/* Finale */
.s-end { position: relative; min-height: calc(100 * var(--vh)); display: grid; place-items: center; color: #fff; text-align: center; overflow: hidden; }
.end-bg { position: absolute; inset: 0; }
.end-bg img, .end-bg video { width: 100%; height: 100%; object-fit: cover; animation: kenburns 24s ease-in-out infinite alternate; }
@keyframes kenburns { from { transform: scale(1.05) translate(0, 0); } to { transform: scale(1.22) translate(-3%, -2%); } }
.s-end::after { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at 50% 50%, rgba(8, 22, 51, .55), rgba(8, 22, 51, .9)); }
.end-in { position: relative; z-index: 1; display: grid; justify-items: center; gap: 8px; padding: 120px 0; }
.end-logo { width: 180px; animation: gallop 1.1s ease-in-out infinite alternate; margin-bottom: 10px; }
.s-end h2 { font-size: clamp(40px, 6.5vw, 84px); }
.s-end p { font-size: clamp(18px, 2vw, 22px); color: rgba(255, 255, 255, .85); }
.end-cta { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin-top: 18px; }

/* FAQ & contact */
.sec { padding: clamp(80px, 10vw, 130px) 0; background: #fff; }
.sec-cream { background: var(--cream); }
.sec h2 { color: var(--night); }
.qa { display: grid; gap: 12px; margin-top: 34px; }
details { background: #fff; border: 1px solid var(--line); border-radius: 16px; transition: box-shadow .3s, border-color .3s; }
details[open] { box-shadow: 0 14px 40px rgba(11, 31, 71, .08); border-color: #d9e0ee; }
summary { list-style: none; cursor: pointer; padding: 20px 22px; font-weight: 600; font-size: 17px; display: flex; align-items: center; gap: 16px; color: var(--night); }
summary::-webkit-details-marker { display: none; }
.pm { margin-inline-start: auto; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: var(--sky-l); color: var(--navy); flex: none; transition: transform .35s var(--ease), background .3s; }
details[open] .pm { transform: rotate(45deg); background: var(--navy); color: #fff; }
.ans { padding: 0 22px 20px; color: var(--ink-2); }
.ans p { margin: 0; }
.contact { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: start; }
.contact-info > p { color: var(--ink-2); font-size: 18px; }
.info { list-style: none; padding: 0; margin: 26px 0 0; display: grid; gap: 14px; }
.info li { display: flex; gap: 14px; align-items: center; font-size: 16.5px; }
.info .ic { width: 44px; height: 44px; padding: 11px; border-radius: 14px; background: #fff; color: var(--navy); box-shadow: 0 6px 16px rgba(11, 31, 71, .06); }
.info a { color: var(--navy); font-weight: 600; text-decoration: none; }
.info a:hover { text-decoration: underline; }
.form { background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 30px; box-shadow: 0 24px 60px rgba(11, 31, 71, .08); display: grid; gap: 16px; }
.form label { display: grid; gap: 6px; font-weight: 600; font-size: 15px; color: var(--night); }
.form input, .form textarea { font: inherit; font-weight: 400; font-size: 16px; padding: 13px 15px; border: 1.5px solid var(--line); border-radius: 12px; background: #fbfcfe; color: var(--ink); transition: border-color .2s, box-shadow .2s; }
.form input:focus, .form textarea:focus { outline: none; border-color: var(--navy-2); box-shadow: 0 0 0 4px rgba(30, 58, 123, .12); }
.form .invalid { border-color: #cf4436; }
fieldset { border: 0; padding: 0; margin: 0; }
legend { font-weight: 600; font-size: 15px; color: var(--night); margin-bottom: 8px; }
.opts { display: flex; flex-wrap: wrap; gap: 8px; }
.opt { position: relative; }
.opt input { position: absolute; opacity: 0; pointer-events: none; }
.opt span { display: inline-block; padding: 9px 15px; border-radius: 999px; border: 1.5px solid var(--line); font-weight: 500; font-size: 14.5px; cursor: pointer; transition: all .2s; color: var(--ink-2); }
.opt input:checked + span { background: var(--navy); border-color: var(--navy); color: #fff; }
.opt input:focus-visible + span { outline: 3px solid var(--gold); outline-offset: 2px; }
.form .fine { text-align: start; }

/* Footer & floating WhatsApp */
.ftr { background: var(--night); color: rgba(255, 255, 255, .75); padding: 56px 0 24px; }
.ftr-in { display: flex; justify-content: space-between; gap: 30px; flex-wrap: wrap; align-items: center; }
.ftr-brand { display: flex; gap: 14px; align-items: center; }
.ftr-brand img { border-radius: 50%; background: #fff; }
.ftr-brand b { color: #fff; font-size: 17px; }
.ftr-brand p { margin: 4px 0 0; font-size: 14.5px; }
.ftr-links { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px 22px; font-size: 15px; }
.ftr a { text-decoration: none; } .ftr a:hover { color: #fff; }
.ftr-bot { margin-top: 36px; padding-top: 18px; border-top: 1px solid rgba(255, 255, 255, .1); display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; font-size: 13.5px; }
.ftr-bot a { opacity: .65; }
.wa-fab { position: fixed; inset-inline-start: 20px; bottom: 20px; z-index: 85; width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; background: #25d366; color: #fff; box-shadow: 0 12px 28px rgba(37, 211, 102, .4); transition: transform .3s var(--ease), opacity .3s; opacity: 0; transform: scale(.7); pointer-events: none; }
.wa-fab.show { opacity: 1; transform: scale(1); pointer-events: auto; }
.wa-fab .ic { width: 28px; height: 28px; }

/* Reveal for the normal sections */
.js .reveal { opacity: 0; transform: translateY(30px); transition: opacity .9s var(--ease), transform .9s var(--ease); transition-delay: var(--d, 0ms); }
.js .reveal.in { opacity: 1; transform: none; }

/* 404 */
.nf-body { background: var(--night); color: #fff; }
.nf { min-height: 100vh; display: grid; place-content: center; justify-items: center; text-align: center; gap: 12px; padding: 24px; }
.nf h1 { font-size: 40px; font-family: var(--f-ar-d); }
.nf .en { font-family: var(--f-en); opacity: .7; margin-top: 18px; }

/* ---------- Responsive ---------- */
@media (max-width: 1000px) {
  .deck { grid-template-columns: repeat(2, 1fr); }
  .s-home .pin { gap: 2vh; }
  .incl { font-size: 13.5px; }
  .price-card { padding: 20px 18px; gap: 8px; }
  .price-card .incl li:nth-child(n+3) { display: none; }
  .amount b { font-size: 30px; }
}
@media (max-width: 860px) {
  .dots { display: none; }
  .scene { height: calc(var(--h) * .8 * var(--vh)); }
  .jump-grid { grid-template-columns: 1fr; align-content: center; gap: 16px; padding-top: 64px; }
  .jump-card { width: min(190px, 48vw); order: -1; }
  .jump-text { padding: 20px 18px; }
  .jump-text h2 { font-size: 30px; margin-bottom: 10px; }
  .jstats { flex-wrap: nowrap; gap: 14px; margin-top: 14px; }
  .jstats b { font-size: 34px; }
  .jstats small { font-size: 12px; }
  .jump-text { text-align: center; }
  .jstats { justify-content: center; gap: 22px; }
  .jump-text p { margin: 0 auto; font-size: 15.5px; }
  .coffee, .app, .contact { grid-template-columns: 1fr; gap: 36px; }
  .app { padding-top: 70px; }
  .stage { height: 46vh; }
  .phone { width: min(200px, 50vw); border-radius: 34px; padding: 9px; }
  .screen { border-radius: 26px; padding: 14px 10px; gap: 8px; }
  .ph-row { padding: 8px 10px; font-size: 11.5px; }
  .app-text h2 { margin-bottom: 8px; }
  .app-text > p { font-size: 16px; }
  .ticks { display: none; }
  .chip { font-size: 12px; padding: 7px 11px; }
}
@media (max-width: 760px) {
  /* Boarding becomes a normal scrolling list on phones */
  .s-home { height: auto !important; }
  .s-home .pin { position: relative; height: auto; overflow: visible; padding: 90px 0 60px; }
  .deck { grid-template-columns: 1fr; --e: 1 !important; }
  .price-card { transform: none; }
  .price-card .incl li:nth-child(n+3) { display: flex; }
  .amount b { font-size: 36px; }
}
@media (max-width: 560px) {
  body { font-size: 16px; } body.lang-ar { font-size: 16.5px; }
  .hdr { top: 10px; inset-inline: 10px; }
  .hide-s { display: none; }
  .hdr .btn-sm { padding: 10px; }
  .lcard { min-height: 300px; padding: 26px 22px; }
  .lcard .n { font-size: 64px; }
  .lcard.is-big .n { font-size: 90px; }
  .learn-head p { font-size: 16px; }
  .fence { width: 300px; margin-left: -150px; height: 110px; }
  .store { flex: 1 1 100%; }
  .end-cta .btn { flex: 1 1 100%; }
  .form { padding: 22px; }
}
/* Reduced motion: no pinning, everything shown in its final state */
.rm .scene { height: auto !important; }
.rm .pin { position: relative; height: auto; min-height: calc(100 * var(--vh)); padding: 100px 0 60px; }
.rm .track-wrap { overflow-x: auto; }
.rm .leap, .rm .flyover, .rm .dust { display: none; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
.leap .enter { animation: enter 1.9s var(--ease) both .15s; }
@keyframes enter { from { transform: translate(-60vw, 25vh) scale(.5) rotate(-12deg); opacity: 0; } to { transform: none; opacity: 1; } }
