/* Desktop sizes are px on a 1180px grid .
   main.js scales the grid to the window with --z. Mobile rules are at the end. */
:root {
  --primary: #3b0f4f;
  --secondary: #6a1b9a;
  --accent: #a970d3;
  --bg: #f8f6f1;
  --text: #2e2e2e;
  --night: #220d38;
  --lilac: #f4eefb;
  --ink: #2c0c4a;
  --violet: #7422b8;
  --z: 1;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: Alexandria, "Segoe UI", Tahoma, sans-serif; background: var(--lilac); color: var(--ink); overflow-x: hidden; zoom: var(--z); }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
ul { list-style: none; }
.wrap { position: relative; width: 1180px; max-width: 100%; margin: 0 auto; height: 100%; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 14px; border-radius: 99px; font-size: 16px; font-weight: 600; transition: transform .25s, box-shadow .25s; }
.btn svg { width: 19px; height: 19px; }
.btn:hover { transform: translateY(-3px); box-shadow: 0 12px 28px rgba(106, 27, 154, .35); }
.btn-light { background: #fbf8ff; color: var(--ink); width: 218px; height: 62px; }
.btn-outline { border: 2px solid var(--violet); color: var(--violet); width: 236px; height: 62px; font-size: 15px; }

/* ===== Hero ===== */
.hero { position: relative; height: 880px; color: #fff; overflow: hidden;
  background: radial-gradient(ellipse at 22% 52%, #7a25bd 0, transparent 46%), linear-gradient(180deg, #210d36 0, #2c1050 45%, #34115c 100%); }
.hero-city { position: absolute; inset: 120px 0 90px; isolation: isolate;
  -webkit-mask-image: linear-gradient(to bottom, transparent, #000 22%, #000 82%, transparent);
  mask-image: linear-gradient(to bottom, transparent, #000 22%, #000 82%, transparent); }
.hero-city::before { content: ""; position: absolute; inset: 0; background: url("../img/riyadh-skyline.jpg") calc(50% + 27px) -300px / 1900px auto no-repeat; filter: grayscale(.45) brightness(1.2) contrast(1.15); }
.hero-city::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, #2a0f4b 8%, transparent 30%), linear-gradient(90deg, rgba(150, 70, 215, .25), rgba(120, 55, 190, 0) 48%, rgba(50, 18, 88, .75) 78%, #2a0f4b), linear-gradient(0deg, transparent, transparent), #9a55e6; mix-blend-mode: multiply; }
.hero-fade { position: absolute; left: 0; right: 0; top: 660px; height: 220px; background: linear-gradient(transparent, #2f1058 38%); }
.hero .wrap { z-index: 2; }

.nav { position: absolute; inset: 0 0 auto; height: 132px; z-index: 20; }
.brand { position: absolute; right: 52px; top: 30px; width: 200px; }
.menu { position: absolute; right: 328px; top: 52px; display: flex; gap: 60px; font-size: 15px; font-weight: 500; white-space: nowrap; }
.menu a { position: relative; padding-bottom: 13px; }
.menu a::after { content: ""; position: absolute; bottom: 0; right: -8px; left: -8px; height: 3px; border-radius: 3px; background: #b06ae8; transform: scaleX(0); transition: transform .25s; }
.menu a.active::after, .menu a:hover::after { transform: scaleX(1); }
.chev { display: inline-block; width: 7px; height: 7px; margin-right: 5px; border: solid currentColor; border-width: 0 1.5px 1.5px 0; transform: translateY(-3px) rotate(45deg); }
.burger { position: absolute; left: 270px; top: 51px; width: 30px; height: 30px; background: none; border: 0; cursor: pointer; display: none; flex-direction: column; justify-content: center; gap: 5px; padding: 0 3px; }
.burger span { height: 2px; background: #fff; border-radius: 2px; }
.quote { position: absolute; left: 57px; top: 40px; width: 176px; height: 52px; display: flex; align-items: center; justify-content: center; gap: 9px; border-radius: 99px; font-size: 13px; font-weight: 600; background: linear-gradient(90deg, #a52fd0, #641aa6); box-shadow: 0 6px 20px rgba(150, 45, 215, .35); }
.quote svg { width: 17px; height: 17px; }

.hero-copy { position: absolute; right: 63px; top: 248px; width: 460px; z-index: 5; }
.eyebrow { font-size: 34px; font-weight: 600; color: #c687f5; line-height: 1.4; }
.hero-copy h1 { margin: 10px 0 18px; font-size: 55px; font-weight: 800; line-height: 1.6; letter-spacing: -.5px; }
.hero-copy h1 span { display: block; white-space: nowrap; }
.hero-copy .accent { color: #cf8cf8; }
.lead { font-size: 17px; font-weight: 300; line-height: 2.2; color: #efe6fa; margin-bottom: 33px; }

.hero-art { position: absolute; left: 0; top: 160px; width: 700px; height: 600px; }
.ribbon { position: absolute; inset: 0; width: 100%; height: 100%; filter: drop-shadow(0 0 14px rgba(185, 100, 255, .75)); }
.ribbon-back { z-index: 1; }
.ribbon-front { z-index: 4; pointer-events: none; translate: 0 108px; }
.phone { position: absolute; z-index: 2; left: 190px; top: 46px; width: 262px; height: 528px; padding: 9px; border-radius: 46px; transform: rotate(-12deg);
  background: linear-gradient(115deg, #d9c4f2, #38205a 12%, #12071f 55%, #6f4a9c 96%, #e6d4fa);
  box-shadow: -14px 18px 0 -5px #1a0a2c, 0 40px 60px rgba(8, 0, 20, .65), 0 0 45px rgba(157, 71, 235, .45); }
.screen { position: relative; height: 100%; border-radius: 38px; display: flex; flex-direction: column; align-items: center; justify-content: center; background: radial-gradient(ellipse at 20% 100%, #8b2fd0, transparent 55%), linear-gradient(160deg, #1c0830, #37105c 60%, #25093f); }
.notch { position: absolute; top: 10px; width: 100px; height: 25px; border-radius: 20px; background: #07020d; }
.phone-mark { width: 112px; margin-bottom: 24px; }
.screen b { font-size: 21px; font-weight: 600; }
.screen small { font-size: 13px; font-weight: 300; margin-top: 6px; }
.tile { position: absolute; z-index: 3; display: grid; place-items: center; border-radius: 17px; color: #fff; border: 1px solid rgba(235, 205, 255, .65);
  background: linear-gradient(140deg, rgba(190, 112, 250, .92), rgba(92, 29, 160, .85)); box-shadow: -7px 8px 0 rgba(58, 13, 105, .8), 0 0 28px rgba(171, 85, 246, .65); animation: float 5s ease-in-out infinite; }
.tile svg { width: 52%; height: 52%; }
.t1 { left: 76px; top: 190px; width: 95px; height: 95px; rotate: 6deg; }
.t2 { left: 418px; top: 122px; width: 84px; height: 84px; rotate: 9deg; animation-delay: -1.7s; }
.t3 { left: 491px; top: 266px; width: 86px; height: 86px; rotate: 8deg; animation-delay: -3.2s; }
.target { position: absolute; z-index: 3; left: 482px; top: 382px; width: 166px; filter: drop-shadow(0 0 18px rgba(171, 85, 246, .75)); animation: float 6s ease-in-out -2s infinite; }
@keyframes float { 50% { translate: 0 -11px; } }

.scroll-hint { position: absolute; right: 140px; top: 766px; z-index: 5; display: flex; flex-direction: column; align-items: center; gap: 10px; font-size: 13px; }
.mouse { position: relative; width: 27px; height: 42px; border: 2px solid #fff; border-radius: 15px; }
.mouse::after { content: ""; position: absolute; top: 7px; left: 50%; width: 3px; height: 8px; margin-left: -1.5px; border-radius: 3px; background: #fff; animation: scroll 1.8s infinite; }
@keyframes scroll { 70% { opacity: 0; translate: 0 10px; } }

.wave { position: absolute; display: block; width: 100%; }
.hero-wave { bottom: -1px; left: 0; height: 200px; z-index: 1; }

/* ===== Light area ===== */
.light { position: relative; background: radial-gradient(ellipse at 85% 18%, #fff 0, transparent 34%), linear-gradient(180deg, #f4eefb 0, #f8f4fd 28%, #e6d3f6 62%, #f4eefb 78%); }
.section-tag { display: flex; align-items: center; gap: 12px; font-size: 22px; font-weight: 700; color: var(--violet); }
.section-tag::after { content: ""; width: 34px; height: 3px; border-radius: 3px; background: currentColor; }
.section-tag.centered { justify-content: center; }
.section-tag.centered::before { content: ""; width: 34px; height: 3px; border-radius: 3px; background: currentColor; }

.services { position: relative; z-index: 3; height: 524px; text-align: center; }
.services .section-tag { padding-top: 7px; }
.services h2 { font-size: 34px; font-weight: 700; line-height: 1.5; margin-top: 4px; }
.sub { font-size: 16px; line-height: 1.8; }
.cards { display: grid; grid-template-columns: repeat(3, 336px); justify-content: center; gap: 25px; margin-top: 35px; }
.card { display: flex; align-items: center; gap: 20px; height: 122px; padding: 0 22px; text-align: right; border-radius: 28px; border: 1px solid #fff;
  background: linear-gradient(135deg, #fdfbff, #f0e7fa); box-shadow: 0 12px 26px rgba(96, 40, 150, .13); transition: transform .3s, box-shadow .3s; }
.card:focus-visible { outline: 3px solid var(--violet); outline-offset: 3px; }
.card:hover { transform: translateY(-6px); box-shadow: 0 20px 36px rgba(96, 40, 150, .24); }
.card .ico { flex: none; display: grid; place-items: center; width: 74px; height: 74px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #fff, #eee3f9); box-shadow: 0 5px 16px rgba(96, 40, 150, .13); }
.card .ico svg { width: 46px; height: 46px; color: var(--violet); }
.card div { flex: 1; text-align: right; }
.card h3 { font-size: 15.5px; font-weight: 700; line-height: 1.8; white-space: nowrap; }
.card p { font-size: 13px; color: #55346f; line-height: 1.9; }

/* ===== Works ===== */
.works { height: 497px; }
.works-copy { position: absolute; right: 63px; top: 38px; width: 450px; }
.works-copy h2 { margin: 24px 0 24px; font-size: 33px; font-weight: 700; line-height: 1.6; }
.works-copy > p:not(.section-tag) { font-size: 15px; line-height: 2.3; margin-bottom: 40px; }

.collage { position: absolute; left: 0; top: 0; width: 690px; height: 480px; }
.shot { position: absolute; overflow: hidden; border: 5px solid #fff; border-radius: 18px; box-shadow: 0 22px 36px rgba(55, 12, 95, .3); }
.shot-small { z-index: 1; left: 56px; top: 244px; width: 140px; height: 172px; rotate: -12deg; background: linear-gradient(150deg, #ddc9f0, #7b48ab); }
.shot-small i { position: absolute; right: -12px; bottom: -18px; width: 110px; height: 90px; border-radius: 40% 40% 8px 8px; background: #3d1263; rotate: -12deg; }
.shot-small i + i { right: 62px; bottom: -34px; background: #8e55c2; }
.shot-small img { width: 38px; margin: 30px auto; }
.shot-laptop { z-index: 2; left: 90px; top: 124px; width: 252px; height: 258px; overflow: visible; border: 0; border-radius: 0; box-shadow: none; rotate: -10deg; }
.lid { height: 180px; padding: 9px; border-radius: 12px 12px 3px 3px; background: #14081f; border: 2px solid #8d7aa8; box-shadow: 0 20px 30px rgba(40, 6, 75, .4); }
.dash { display: grid; grid-template-columns: 26px 1.5fr 1fr; grid-template-rows: 1fr 1fr; gap: 6px; height: 100%; padding: 6px; background: #1d0a33; }
.side { grid-row: 1 / 3; display: flex; flex-direction: column; gap: 9px; padding-top: 4px; }
.side i { height: 5px; border-radius: 3px; background: #6b3a99; }
.panel { position: relative; border-radius: 4px; background: #2e1250; overflow: hidden; }
.bars { display: flex; align-items: flex-end; gap: 5px; padding: 7px; }
.bars i { flex: 1; height: 40%; background: linear-gradient(#d58cff, #6a1b9a); }
.bars i:nth-child(2n) { height: 65%; } .bars i:nth-child(3n) { height: 90%; }
.donut::after { content: ""; position: absolute; inset: 0; margin: auto; width: 50px; height: 50px; border-radius: 50%; background: conic-gradient(#e879f9 0 38%, #8b5cf6 0 70%, #38bdf8 0 82%, #4c1d75 0); -webkit-mask: radial-gradient(circle, transparent 13px, #000 14px); mask: radial-gradient(circle, transparent 13px, #000 14px); }
.donut.alt::after { rotate: 140deg; }
.line svg { width: 100%; height: 100%; padding: 8px; }
.deck { width: 116%; height: 21px; margin-right: -8%; border-radius: 3px 3px 22px 22px; background: linear-gradient(#b9a8d0, #483163 45%, #1c0b2e); box-shadow: 0 18px 24px rgba(40, 6, 75, .35); }
.shot-bag { z-index: 2; left: 514px; top: 91px; width: 172px; height: 262px; rotate: 11deg; display: flex; align-items: flex-end; justify-content: center; background: linear-gradient(160deg, #eadcf8, #8b55bd); }
.shot-bag svg { width: 148px; margin-bottom: 20px; filter: drop-shadow(0 10px 12px rgba(25, 3, 45, .45)); }
.shot-main { z-index: 3; left: 268px; top: 52px; width: 310px; height: 378px; rotate: -7deg; }
.poster { position: relative; isolation: isolate; height: 100%; display: flex; flex-direction: column; align-items: center; padding-top: 48px; color: #fff; text-align: center; background: #2b0a48; }
.poster::before { content: ""; position: absolute; z-index: -2; inset: 38% 0 0; background: url("../img/riyadh-skyline.jpg") 45% 70% / auto 140%; filter: grayscale(.6) brightness(.85); }
.poster::after { content: ""; position: absolute; z-index: -1; inset: 0; background: linear-gradient(180deg, #2b0a48 38%, rgba(123, 47, 208, .55) 68%, rgba(60, 12, 105, .75)); }
.poster-mark { width: 88px; margin-bottom: 18px; }
.poster b { font-size: 22px; font-weight: 600; }
.poster small { font-size: 13px; margin-top: 5px; }

/* ===== Stats ===== */
.stats-section { height: 197px; padding-top: 21px; }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); align-items: center; width: 1100px; height: 152px; margin: 0 auto; padding: 0 20px; border-radius: 26px; color: #fff;
  background: radial-gradient(ellipse at 100% 40%, #9b35d4, transparent 40%), linear-gradient(90deg, #35104f, #290a43 55%, #571892); box-shadow: 0 18px 36px rgba(60, 15, 105, .28); }
.stats li { display: flex; align-items: center; justify-content: center; gap: 24px; height: 80px; }
.stats li + li { border-right: 1px solid rgba(190, 135, 240, .35); }
.stats svg { flex: none; width: 40px; height: 40px; color: #c685f7; filter: drop-shadow(0 0 7px rgba(190, 105, 255, .8)); }
.stats b { display: block; font-size: 20px; font-weight: 700; line-height: 1.7; white-space: nowrap; }
.stats small { display: block; font-size: 13px; font-weight: 300; color: #e6d8f6; }

/* ===== CTA ===== */
.cta { position: relative; height: 378px; color: #fff; }
.cta-bg { position: absolute; inset: 0; width: 100%; height: 100%; }
.plane { position: absolute; left: 30px; top: 96px; width: 360px; filter: drop-shadow(0 0 16px rgba(180, 90, 255, .7)); }
.cta-copy { position: absolute; right: 137px; top: 112px; width: 540px; text-align: right; }
.cta-copy p { font-size: 20px; font-weight: 600; color: #c687f5; }
.cta-copy h2 { margin: 16px 0 33px; font-size: 27px; font-weight: 700; line-height: 1.8; white-space: nowrap; }
.cta-copy .btn { margin-right: 106px; width: 200px; }

/* ===== Footer ===== */
.footer { padding-bottom: 14px; }
.footer .wrap { height: 100px; }
.footer img { position: absolute; right: 60px; top: 18px; width: 182px; }
.footer .wrap p { position: absolute; left: 0; right: 0; top: 43px; text-align: center; font-size: 14px; color: #4a2170; }
.social { position: absolute; left: 66px; top: 39px; display: flex; gap: 25px; color: var(--secondary); }
.social svg { display: block; width: 23px; height: 23px; }
.social a:hover { color: var(--accent); }
.credit { text-align: center; font-size: 9px; color: #7d6592; }
.credit a { text-decoration: underline; }

.whatsapp { position: fixed; z-index: 50; right: 10px; bottom: 24px; display: grid; place-items: center; width: 50px; height: 50px; border-radius: 50%; color: #fff; background: #25d366; box-shadow: 0 10px 26px rgba(15, 120, 60, .4); transition: transform .25s; }
.whatsapp:hover { transform: scale(1.08); }
.whatsapp svg { width: 28px; height: 28px; }

.cf-box { display: contents; }

/* ===== Mobile and small tablets ===== */
@media (max-width: 899px) {
  .wrap { width: 100%; }
  .btn { font-size: 14px; }
  .btn-light, .btn-outline { height: 52px; }

  .hero { height: auto; padding-bottom: 66px; }
  .hero-city { inset: 200px 0 20px; }
  .hero-city::before { background-position: 45% 70%; background-size: cover; }
  .nav { position: relative; height: 86px; }
  .brand { right: 18px; top: 20px; width: 140px; }
  .quote { display: none; }
  .burger { display: flex; left: 14px; top: 26px; width: 40px; height: 36px; }
  /* Menu stays in the layout and is hidden with visibility, so it can animate both ways.
     The first transition values apply while closing, the .open ones while opening. */
  .menu { position: absolute; top: 78px; right: 14px; left: 14px; z-index: 30; display: flex; flex-direction: column; gap: 0; padding: 10px 24px; border-radius: 20px; background: #210a37; box-shadow: 0 20px 40px rgba(0, 0, 0, .4);
    visibility: hidden; opacity: 0; translate: 0 -14px; scale: .94; transform-origin: top left; clip-path: inset(0 0 100% 0 round 20px);
    transition: opacity .3s ease .08s, translate .35s ease .08s, scale .35s ease .08s, clip-path .38s cubic-bezier(.4, 0, .2, 1) .06s, visibility 0s .46s; }
  .menu.open { visibility: visible; opacity: 1; translate: 0 0; scale: 1; clip-path: inset(0 0 0 0 round 20px);
    transition: opacity .25s ease, translate .4s cubic-bezier(.2, .8, .2, 1), scale .4s cubic-bezier(.2, .8, .2, 1), clip-path .5s cubic-bezier(.2, .8, .2, 1), visibility 0s; }
  .menu a { padding: 13px 0; opacity: 0; translate: 28px 0; transition: opacity .2s ease, translate .25s ease; }
  .menu.open a { opacity: 1; translate: 0 0; transition: opacity .35s ease, translate .45s cubic-bezier(.2, .8, .2, 1); }
  .menu.open a:nth-of-type(1) { transition-delay: .1s; }
  .menu.open a:nth-of-type(2) { transition-delay: .16s; }
  .menu.open a:nth-of-type(3) { transition-delay: .22s; }
  .menu.open a:nth-of-type(4) { transition-delay: .28s; }
  .menu.open a:nth-of-type(5) { transition-delay: .34s; }

  /* Menu button turns into a close (X) icon */
  .burger span { transition: translate .3s ease, rotate .3s ease, opacity .2s ease; }
  .burger[aria-expanded="true"] span:nth-child(1) { translate: 0 7px; rotate: 45deg; }
  .burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .burger[aria-expanded="true"] span:nth-child(3) { translate: 0 -7px; rotate: -45deg; }
  .menu a::after { display: none; }

  .hero-copy { position: relative; right: auto; top: auto; width: auto; padding: 24px 22px 0; text-align: center; }
  .eyebrow { font-size: 22px; }
  .hero-copy h1 { font-size: clamp(30px, 9.4vw, 54px); margin: 6px 0 10px; }
  .lead { font-size: 14px; margin-bottom: 22px; }
  .lead br, .works-copy br:not(h2 br) { display: none; }

  /* The 700x600 artwork is scaled as one unit */
  .hero-art { position: relative; top: 0; left: auto; margin: 10px calc(50% - 350px) -280px; transform: scale(.52); transform-origin: top center; }
  .scroll-hint { display: none; }
  .hero-fade { top: auto; bottom: 0; height: 190px; }
  .hero-wave { height: 80px; }

  .services { height: auto; padding: 0 18px 40px; }
  .services h2 { font-size: 24px; }
  .sub { font-size: 14px; }
  .cards { grid-template-columns: minmax(0, 420px); gap: 16px; margin-top: 24px; }
  /* Long service names wrap inside the card instead of running to its edge */
  .card { height: auto; min-height: 108px; gap: 14px; padding: 16px 18px; }
  .card div { min-width: 0; }
  .card h3 { white-space: normal; font-size: clamp(13px, 4vw, 15.5px); line-height: 1.7; }
  .card p { font-size: clamp(12px, 3.5vw, 13px); }
  .card .ico { width: clamp(56px, 17vw, 74px); height: clamp(56px, 17vw, 74px); }
  .card .ico svg { width: 62%; height: 62%; }

  .works { height: auto; padding: 10px 0 30px; overflow: hidden; }
  .works .wrap { display: flex; flex-direction: column; align-items: center; }
  .works-copy { position: static; width: auto; padding: 0 22px; text-align: center; }
  .works-copy .section-tag { justify-content: center; }
  .works-copy h2 { font-size: 24px; margin: 12px 0; }
  .works-copy > p:not(.section-tag) { font-size: 13.5px; margin-bottom: 20px; }
  /* The collage is scaled to the screen by main.js (fitCollage) */
  .cf-box { display: block; position: relative; align-self: stretch; margin-top: 24px; }
  .cf-box .collage { position: absolute; top: 0; left: 0; transform-origin: 0 0; direction: rtl; }

  .stats-section { height: auto; padding: 10px 18px 36px; }
  .stats { grid-template-columns: 1fr 1fr; width: 100%; height: auto; max-width: 480px; padding: 14px 6px; row-gap: 8px; }
  .stats li { gap: 10px; flex-direction: column; height: auto; padding: 10px 0; text-align: center; }
  .stats li:nth-child(3) { border-right: 0; }
  .stats b { font-size: 17px; }

  .cta { height: auto; padding: 128px 20px 100px; }
  .plane { display: none; }
  .cta-copy { position: static; width: auto; text-align: center; }
  .cta-copy p { font-size: 16px; }
  .cta-copy h2 { font-size: 22px; white-space: normal; margin: 10px 0 22px; }
  .cta-copy .btn { margin: 0; }

  .footer .wrap { height: auto; display: flex; flex-direction: column; align-items: center; gap: 16px; padding: 18px 16px; }
  .footer img { position: static; width: 160px; }
  .footer .wrap p { position: static; font-size: 12px; }
  .social { position: static; }
  .footer { padding-bottom: 90px; }
  .credit { padding: 0 16px; }
  .whatsapp { width: 48px; height: 48px; right: 14px; bottom: 16px; }
  .whatsapp svg { width: 27px; height: 27px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* Sliding animations must never widen the page (that makes phones shake sideways) */
.light { overflow-x: clip; }

/* Phones: section titles stay on one line; their size and dashes shrink with the screen */
@media (max-width: 899px) {
  .section-tag { white-space: nowrap; gap: clamp(7px, 2.4vw, 12px); font-size: clamp(16px, 5.4vw, 22px); }
  .section-tag::after, .section-tag.centered::before { flex: none; width: clamp(18px, 7.5vw, 34px); }
  /* The FAQ section already has side padding, so its heading doesn't need a second layer */
  .s-faq .s-head { padding-left: 0; padding-right: 0; }
}
