/* Critical Arabic & Latin woff2 subsets (remaining weights/subsets in css/fonts-deferred.css) */
@font-face {
  font-family: "Readex Pro";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("../assets/fonts/readex-pro-600-arabic.woff2") format("woff2");
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}
@font-face {
  font-family: "Readex Pro Fallback";
  font-style: normal;
  font-weight: 100 900;
  src: local("Noto Sans Arabic"), local("Geeza Pro"), local("Arial"), local("Segoe UI"), local("Tahoma"), local("DejaVu Sans");
  size-adjust: 115.5%;
  ascent-override: 86.6%;
  descent-override: 21.6%;
  line-gap-override: 0%;
}

@font-face {
  font-family: "IBM Plex Sans Arabic";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../assets/fonts/ibm-plex-sans-arabic-400-arabic.woff2") format("woff2");
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}
@font-face {
  font-family: "IBM Plex Sans Arabic";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("../assets/fonts/ibm-plex-sans-arabic-500-arabic.woff2") format("woff2");
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}
@font-face {
  font-family: "IBM Plex Sans Arabic";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("../assets/fonts/ibm-plex-sans-arabic-600-arabic.woff2") format("woff2");
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}
@font-face {
  font-family: "IBM Plex Sans Arabic";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../assets/fonts/ibm-plex-sans-arabic-700-arabic.woff2") format("woff2");
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}
/* R5-STEP-3 */
@media (min-width: 601px) {
  @font-face {
    font-family: "IBM Plex Sans Arabic";
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url("../assets/fonts/ibm-plex-sans-arabic-700-latin.woff2") format("woff2");
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2122, U+2190-2193, U+FEFF, U+FFFD;
  }
}
/* /R5-STEP-3 */
@font-face {
  font-family: "IBM Plex Sans Arabic Fallback";
  font-style: normal;
  font-weight: 400;
  src: local("Noto Sans Arabic"), local("Geeza Pro"), local("Arial"), local("Segoe UI"), local("Tahoma"), local("DejaVu Sans");
  size-adjust: 92.5%;
  ascent-override: 117.8%;
  descent-override: 45.4%;
  line-gap-override: 0%;
}
@font-face {
  font-family: "IBM Plex Sans Arabic Fallback";
  font-style: normal;
  font-weight: 500;
  src: local("Noto Sans Arabic"), local("Geeza Pro"), local("Arial"), local("Segoe UI"), local("Tahoma"), local("DejaVu Sans");
  size-adjust: 103.4%;
  ascent-override: 105.4%;
  descent-override: 40.6%;
  line-gap-override: 0%;
}
@font-face {
  font-family: "IBM Plex Sans Arabic Fallback";
  font-style: normal;
  font-weight: 600 700;
  src: local("Noto Sans Arabic"), local("Geeza Pro"), local("Arial"), local("Segoe UI"), local("Tahoma"), local("DejaVu Sans");
  size-adjust: 99.5%;
  ascent-override: 109.5%;
  descent-override: 42.2%;
  line-gap-override: 0%;
}

/* Colour tokens & fluid rem scaling */
:root {
  --void: #a81613;
  --navy: #7a0d0b;
  --paper: #ffffff;
  --mute: #fff4f3;
  --struck: #f5c4c2;
  --hair: rgba(255, 255, 255, 0.22);
  --card-dark: #87110e;
  --key: #ffffff;
  --key-shadow: #c7c7c7;
  --ticket: #ffffff;
  --ink: #171717;
  --sheet: #fbf6f4;
  --stamp: #a81613;
  --panel: #5a0a0e;
  --dot: #c9565c;
  --line: #f3d9db;
  --loose: #f1b9bc;
  --bloom: #f5c9cb;
  --spark: #7a0d12;
  --about-pt: 0rem;
  --about-pb: 0rem;
  --services-pt: 2.75rem;
  --services-pb: 2rem;
  --readers-pt: 2.75rem;
  --readers-pb: 2.75rem;
  --review-card-pt: 2.25rem;
  --review-card-pb: 2.25rem;
  --review-text-pt: 4.5rem;
  --review-text-pb: 4.5rem;
  --contact-pt: 1rem;
  --contact-pb: 1rem;
}

html {
  font-size: calc(100vw / 90);
  overflow-x: clip;
}

@media (max-width: 991px) {
  html {
    font-size: calc(100vw / 60);
  }
}

@media (max-width: 600px) {
  html {
    font-size: calc(100vw / 24.375);
  }
}

html.lenis,
html.lenis body {
  height: auto;
}

.lenis.lenis-smooth {
  scroll-behavior: auto !important;
}

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

a {
  color: inherit;
  text-decoration: none;
}

img,
video {
  display: block;
}

button,
input,
textarea {
  font: inherit;
}

body {
  background-color: var(--void);
  color: var(--paper);
  font-family: "IBM Plex Sans Arabic", "IBM Plex Sans Arabic Fallback", "Readex Pro", "Readex Pro Fallback", sans-serif;
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
}

/* Fallback reveal visibility */
html[data-reveal-fallback] [data-reveal] {
  visibility: visible !important;
}

html.no-js .hero-headline-ghost,
html[data-reveal-fallback] .hero-headline-ghost {
  visibility: visible !important;
}

html.no-js .hero-headline-live {
  display: none !important;
}

html.no-js .hero-paragraph-wrap,
html[data-reveal-fallback] .hero-paragraph-wrap,
html.no-js .hero-cta,
html[data-reveal-fallback] .hero-cta {
  opacity: 1 !important;
  visibility: visible !important;
  pointer-events: auto !important;
  transform: none !important;
}

main {
  position: relative;
  z-index: 1;
  background-color: var(--void);
}

main:focus {
  outline: none;
}

/* SplitText line clipping shield for Arabic descenders */
.line {
  padding-bottom: 0.14em;
  margin-bottom: -0.14em;
}

/* Global Fixed Layers */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--paper);
  transform-origin: left;
  transform: scaleX(0);
  z-index: 60;
  pointer-events: none;
}

.grain-overlay {
  position: fixed;
  inset: -140px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='g'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23g)' opacity='1'/%3E%3C/svg%3E");
  background-size: 220px 220px;
  opacity: 0.055;
  pointer-events: none;
  z-index: 90;
}

.scroll-progress.is-on-light {
  background: var(--void);
}

/* Shared Typography & Components */
.eyebrow-index {
  font-family: "IBM Plex Sans Arabic", "IBM Plex Sans Arabic Fallback", sans-serif;
  font-weight: 400;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  color: var(--mute);
  direction: rtl;
}

.section-headline {
  font-family: "Readex Pro", "Readex Pro Fallback", sans-serif;
  font-weight: 700;
  font-size: 5.5rem;
  line-height: 1.08;
  letter-spacing: 0;
  color: var(--paper);
}

.body-copy {
  font-family: "IBM Plex Sans Arabic", "IBM Plex Sans Arabic Fallback", sans-serif;
  font-weight: 400;
  font-size: 1.2rem;
  line-height: 1.75;
  color: var(--mute);
  max-width: 31rem;
}

.mono-small {
  font-family: "IBM Plex Sans Arabic", "IBM Plex Sans Arabic Fallback", sans-serif;
  font-weight: 700;
  font-size: 0.7rem;
  letter-spacing: 0.08em;
}

.link-underline {
  position: relative;
  display: inline-block;
}

.link-underline::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -0.22em;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.35s cubic-bezier(0.65, 0.05, 0, 1);
}

.link-underline:hover::after {
  transform: scaleX(1);
  transform-origin: left;
}

.keycap-btn {
  width: 12.4rem;
  height: 3.6rem;
  background: var(--key);
  color: var(--ink);
  font-family: "IBM Plex Sans Arabic", "IBM Plex Sans Arabic Fallback", sans-serif;
  font-weight: 600;
  font-size: 0.8rem;
  border: none;
  border-radius: 2px;
  box-shadow: inset 2px 2px 0 rgba(255, 255, 255, 0.95),
    inset -2px -2px 0 var(--key-shadow);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.08s ease, box-shadow 0.08s ease, background-color 0.15s ease;
}

.keycap-btn:hover {
  background: #f5ebeb;
}

.keycap-btn:active {
  transform: translateY(1px);
  box-shadow: inset -2px -2px 0 rgba(255, 255, 255, 0.95),
    inset 2px 2px 0 var(--key-shadow);
}

.keycap-btn:disabled {
  opacity: 0.85;
  cursor: default;
}

.keycap-btn:focus-visible,
.nav-link:focus-visible,
.ticket-btn:focus-visible,
.nav-wordmark:focus-visible,
.top-btn:focus-visible {
  outline: 2px solid var(--paper);
  outline-offset: 4px;
}

/* Header Nav (stays strictly in the top header, LTR flex with RTL labels) */
.site-nav {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  padding: 2.2rem 3.8rem 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 50;
  direction: ltr;
  pointer-events: none;
}

.site-nav > * {
  pointer-events: auto;
}

.nav-wordmark {
  display: inline-flex;
  align-items: center;
  height: 2.6rem;
  flex-shrink: 0;
}

.nav-wordmark-img {
  height: 4.25rem;
  width: auto;
  aspect-ratio: 280 / 234;
  display: block;
  object-fit: contain;
  pointer-events: none;
}

.nav-center {
  position: absolute;
  left: 50%;
  top: 2.2rem;
  height: 2.6rem;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 3rem;
  direction: rtl;
}

.nav-right {
  order: -1;
  display: flex;
  flex-direction: row-reverse;
  align-items: center;
  gap: 2.4rem;
}

.nav-link {
  position: relative;
  font-family: "IBM Plex Sans Arabic", "IBM Plex Sans Arabic Fallback", sans-serif;
  font-weight: 500;
  font-size: 1.05rem;
  color: var(--mute);
  white-space: nowrap;
  direction: rtl;
  transition: color 0.3s cubic-bezier(0.65, 0.05, 0, 1);
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -0.45em;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s cubic-bezier(0.65, 0.05, 0, 1);
}

.nav-link:hover {
  color: var(--paper);
}

.nav-link:hover::after {
  transform: scaleX(1);
}

.ticket-btn {
  position: relative;
  background: var(--ticket);
  height: 2.6rem;
  padding: 0 1.4rem;
  color: var(--ink);
  font-family: "IBM Plex Sans Arabic", "IBM Plex Sans Arabic Fallback", sans-serif;
  font-weight: 600;
  font-size: 0.8rem;
  border: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
  direction: rtl;
  cursor: pointer;
}

.ticket-btn::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -3px;
  height: 3px;
  background-image: radial-gradient(circle, #e2b4b3 1px, transparent 1px);
  background-size: 4px 3px;
  background-repeat: repeat-x;
  pointer-events: none;
}

@media (max-width: 991px) {
  :root {
    --review-text-pt: 2rem;
    --review-text-pb: 2rem;
  }

  .section-headline {
    font-size: 3.8rem;
  }

  .body-copy {
    font-size: 1.15rem;
  }
}

@media (max-width: 600px) {
  .site-nav {
    padding: 1.4rem 1.5rem 0;
  }

  .nav-center,
  .nav-contact {
    display: none;
  }

  .keycap-btn {
    width: 10.5rem;
    height: 3.2rem;
    font-size: 0.78rem;
  }

  /* R5-STEP-1 */
  .keycap-btn,
  .ticket-btn {
    font-weight: 700;
  }
  /* /R5-STEP-1 */

  /* R7-C */
  .grain-overlay {
    background-image: url("../assets/grain-tile-phone.webp");
    background-size: 96px 96px;
  }
  /* /R7-C */

  .section-headline {
    font-size: 3rem;
  }

  .body-copy {
    font-size: 0.95rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .caret,
  .grain-overlay {
    display: none !important;
    animation: none !important;
  }
}

@media (max-width: 768px) {
  :root {
    --section-space: 3.5rem;
    --section-inner-gap: 2rem;
  }

  .site-nav .ticket-btn {
    min-height: max(44px, 2.75rem);
    height: auto;
    width: auto;
    padding: 0.6rem 1.25rem;
    font-size: 0.9rem;
  }
}
