/* ═══════════════════════════════════════════════════════
   Quantum Crystal Technologies — design system
   Brand: indigo #352E80 · violet #6A5CFF · ink #05070C · Inter
   ═══════════════════════════════════════════════════════ */

:root {
    --bg: #05070c;
    --bg-raised: #0b0e1a;
    --bg-card: rgba(255, 255, 255, 0.03);
    --indigo: #352e80;
    --violet: #6a5cff;
    --violet-soft: #9a8fff;
    --text: #f2f4f8;
    --muted: #c6ccd6;
    --dim: #8a93a6;
    --line: rgba(255, 255, 255, 0.1);
    --line-soft: rgba(255, 255, 255, 0.06);
    --glow: rgba(106, 92, 255, 0.35);
    --radius: 16px;
    --container: 1180px;
    --header-h: 76px;
    --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

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

/* clip (not hidden): kills sideways panning/wobble from off-screen
   reveal elements without creating a scroll container — iOS included */
html, body { overflow-x: clip; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

/* keyboard focus — visible for all interactive elements */
:focus-visible {
    outline: 2px solid var(--violet-soft);
    outline-offset: 2px;
    border-radius: 4px;
}
:focus:not(:focus-visible) { outline: none; }

/* Arabic first-paint gate: hide translatable text only for stored-AR visitors
   until I18n.apply() removes .i18n-pending (a failsafe timer clears it too) */
.i18n-pending [data-i18n],
.i18n-pending [data-i18n-html] { visibility: hidden; }

/* film grain — 2026 texture, barely-there */
body::after {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 3000;
    opacity: 0.04;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.55'/%3E%3C/svg%3E");
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--muted);
    font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-weight: 300;
    font-size: 1.0625rem;
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}

/* height:auto keeps natural aspect ratio even when width/height attrs are set */
img { max-width: 100%; height: auto; display: block; }

h1, h2, h3, h4 { color: var(--text); font-weight: 300; line-height: 1.2; margin: 0 0 1rem; letter-spacing: -0.02em; }

h1 { font-size: clamp(2.3rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.7rem, 3.4vw, 2.5rem); }
h3 { font-size: 1.3rem; font-weight: 400; letter-spacing: -0.01em; }

p { margin: 0 0 1.1rem; }
p:last-child { margin-bottom: 0; }

a { color: var(--violet-soft); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--text); }

::selection { background: var(--indigo); color: #fff; }

.container { max-width: var(--container); margin: 0 auto; padding: 0 24px; }

/* ─── Eyebrow / labels ─── */

.eyebrow {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 500;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--violet-soft);
    margin-bottom: 1.1rem;
}

.lede { font-size: 1.18rem; color: var(--muted); max-width: 46em; }

.text-gradient {
    background: linear-gradient(100deg, #ffffff 10%, var(--violet-soft) 40%, var(--violet) 55%, #ffffff 85%);
    background-size: 220% auto;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: shimmer 8s ease-in-out infinite alternate;
}

@keyframes shimmer {
    from { background-position: 0% center; }
    to { background-position: 100% center; }
}

/* ─── Buttons ─── */

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.85rem 1.7rem;
    border-radius: 100px;
    border: 1px solid transparent;
    font: 500 0.95rem/1 "Inter", sans-serif;
    letter-spacing: 0.01em;
    cursor: pointer;
    transition: transform 0.25s var(--ease), box-shadow 0.25s, background 0.25s, border-color 0.25s;
    white-space: nowrap;
}

.btn-primary {
    background: linear-gradient(120deg, var(--indigo), var(--violet));
    color: #fff;
    box-shadow: 0 4px 24px rgba(106, 92, 255, 0.28);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 32px var(--glow); color: #fff; }

.btn-ghost { border-color: var(--line); color: var(--text); background: rgba(255, 255, 255, 0.02); }
.btn-ghost:hover { border-color: var(--violet); background: rgba(106, 92, 255, 0.08); color: #fff; }

.btn-small { padding: 0.6rem 1.25rem; font-size: 0.88rem; }

.btn .arrow { transition: transform 0.25s var(--ease); }
.btn:hover .arrow { transform: translateX(3px); }

/* ─── Header — floating glass pill ─── */

.site-header {
    position: fixed;
    inset: 0 0 auto;
    padding-top: 14px;
    z-index: 1000;
}

.header-inner {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 62px;
    gap: 2rem;
    padding: 0 12px 0 22px;
    border-radius: 100px;
    border: 1px solid var(--line-soft);
    box-shadow: 0 12px 40px -18px rgba(0, 0, 0, 0.7), inset 0 1px 0 rgba(255, 255, 255, 0.07);
    transition: border-color 0.35s, box-shadow 0.35s;
}
/* glass lives on a pseudo-element: backdrop-filter on an ancestor of the
   fixed mobile nav would create a containing block and trap it in the pill */
.header-inner::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(120deg, rgba(20, 24, 44, 0.5), rgba(9, 11, 20, 0.42) 55%, rgba(38, 32, 92, 0.28));
    -webkit-backdrop-filter: blur(22px) saturate(160%);
    backdrop-filter: blur(22px) saturate(160%);
    pointer-events: none;
    z-index: -1;
    transition: background 0.35s, opacity 0.3s;
}
.site-header.scrolled .header-inner {
    border-color: rgba(106, 92, 255, 0.22);
    box-shadow: 0 16px 44px -18px rgba(0, 0, 0, 0.85), 0 0 34px -16px var(--glow), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}
.site-header.scrolled .header-inner::before {
    background: linear-gradient(120deg, rgba(16, 19, 36, 0.72), rgba(7, 9, 16, 0.66) 55%, rgba(33, 28, 82, 0.5));
}

/* open mobile menu: pill chrome steps aside, logo + toggle stay on top */
.site-header.nav-open .header-inner { border-color: transparent; box-shadow: none; }
.site-header.nav-open .header-inner::before,
.site-header.nav-open .header-inner::after { opacity: 0; }

/* progress ring — the pill border lights up clockwise from top as you scroll */
.header-inner::after {
    content: "";
    position: absolute;
    inset: -1px;
    border-radius: inherit;
    padding: 1.5px;
    background: conic-gradient(from -90deg,
        var(--indigo),
        var(--violet) calc(var(--scroll-progress, 0%) * 0.6),
        #b7aeff calc(var(--scroll-progress, 0%) - 0.5%),
        transparent var(--scroll-progress, 0%));
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    mask-composite: exclude;
    filter: drop-shadow(0 0 5px rgba(106, 92, 255, 0.5));
    pointer-events: none;
    transition: opacity 0.3s;
}

/* near-invisible breathing glow on the pill */
@keyframes pill-breathe {
    from { box-shadow: 0 0 26px -12px rgba(106, 92, 255, 0.12); }
    to { box-shadow: 0 0 30px -10px rgba(106, 92, 255, 0.3); }
}
.header-inner::before { animation: pill-breathe 6.5s ease-in-out infinite alternate; }

.brand { display: flex; align-items: center; flex-shrink: 0; }
.brand-logo { height: 40px; width: auto; }

.site-nav { display: flex; align-items: center; gap: 1.9rem; }
.nav-foot { display: none; }
.site-nav a:not(.btn) {
    color: var(--muted);
    font-size: 0.94rem;
    font-weight: 400;
    position: relative;
    padding: 0.3rem 0;
}
.site-nav a:not(.btn):hover { color: #fff; }
.site-nav a:not(.btn)::after {
    content: "";
    position: absolute;
    left: 0; right: 100%; bottom: 0;
    height: 1px;
    background: var(--violet);
    transition: right 0.3s var(--ease);
}
.site-nav a:not(.btn):hover::after, .site-nav a.active::after { right: 0; }
.site-nav a.active { color: #fff; }

/* ─── Language switch (segmented EN / AR) ─── */
.lang-switch {
    display: inline-flex;
    align-items: center;
    border: 1px solid var(--line);
    border-radius: 100px;
    overflow: hidden;
    flex-shrink: 0;
}
.lang-switch button {
    appearance: none;
    background: transparent;
    border: 0;
    color: var(--dim);
    font: 500 0.8rem/1 "Inter", sans-serif;
    letter-spacing: 0.04em;
    padding: 0.5rem 0.72rem;
    min-width: 40px;
    cursor: pointer;
    transition: background 0.25s, color 0.25s;
}
.lang-switch button.active {
    background: linear-gradient(120deg, var(--indigo), var(--violet));
    color: #fff;
}
.lang-switch button:not(.active):hover { color: #fff; }
/* the ع glyph needs an Arabic-capable face */
.lang-switch button[data-set-lang="ar"] { font-family: "Noto Sans Arabic", "Inter", sans-serif; font-size: 0.95rem; }

/* header-bar language switch — desktop uses the in-nav one, so hide this until mobile */
.header-lang { display: none; }

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: 0;
    padding: 10px;
    cursor: pointer;
    z-index: 1001;
}
.nav-toggle span { width: 22px; height: 1.5px; background: var(--text); transition: transform 0.3s var(--ease), opacity 0.3s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* ─── Hero (home) ─── */

.hero {
    position: relative;
    min-height: 92vh;
    /* svh: stable during mobile URL-bar collapse — no layout jumps while scrolling */
    min-height: 92svh;
    display: flex;
    align-items: center;
    padding: calc(var(--header-h) + 60px) 0 80px;
    overflow: hidden;
}

.hero-lattice { position: absolute; inset: 0; z-index: 0; opacity: 0.55; }

.hero::before {
    content: "";
    position: absolute;
    width: 900px; height: 900px;
    top: -300px; right: -200px;
    background: radial-gradient(circle, rgba(106, 92, 255, 0.16) 0%, transparent 65%);
    pointer-events: none;
    animation: aurora-a 22s ease-in-out infinite alternate;
}
.hero::after {
    content: "";
    position: absolute;
    width: 700px; height: 700px;
    bottom: -350px; left: -250px;
    background: radial-gradient(circle, rgba(53, 46, 128, 0.22) 0%, transparent 65%);
    pointer-events: none;
    animation: aurora-b 26s ease-in-out infinite alternate;
}

/* slow-drifting aurora glows */
@keyframes aurora-a {
    from { transform: translate(0, 0) scale(1); }
    50% { transform: translate(-120px, 70px) scale(1.12); }
    to { transform: translate(60px, -50px) scale(0.94); }
}
@keyframes aurora-b {
    from { transform: translate(0, 0) scale(1); }
    50% { transform: translate(110px, -60px) scale(1.15); }
    to { transform: translate(-60px, 40px) scale(0.92); }
}

.hero-grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1.05fr 0.95fr;
    gap: 4rem;
    align-items: center;
}

.hero-copy h1 { margin-bottom: 1.4rem; }
.hero-copy .lede { margin-bottom: 2.2rem; }
.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; }

.hero-visual { position: relative; }
.hero-visual img {
    border-radius: var(--radius);
    border: 1px solid var(--line);
    box-shadow: 0 40px 90px -30px rgba(0, 0, 0, 0.8), 0 0 80px -20px var(--glow);
}
.hero-visual::before {
    content: "";
    position: absolute;
    inset: -1px;
    border-radius: var(--radius);
    background: linear-gradient(140deg, rgba(106, 92, 255, 0.4), transparent 40%, transparent 70%, rgba(106, 92, 255, 0.2));
    z-index: -1;
    filter: blur(14px);
    opacity: 0.6;
}

.hero-stats {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1px;
    background: var(--line-soft);
    border: 1px solid var(--line-soft);
    border-radius: var(--radius);
    overflow: hidden;
    margin-top: 4.5rem;
}
.hero-stat { background: rgba(5, 7, 12, 0.72); padding: 1.5rem 1.75rem; }
.hero-stat strong { display: block; font-size: 1.65rem; font-weight: 300; color: var(--text); letter-spacing: -0.02em; }
.hero-stat span { font-size: 0.85rem; color: var(--dim); }

/* ─── Page hero (subpages) ─── */

.page-hero {
    position: relative;
    padding: calc(var(--header-h) + 110px) 0 90px;
    overflow: hidden;
    border-bottom: 1px solid var(--line-soft);
}
.page-hero::before {
    content: "";
    position: absolute;
    width: 800px; height: 800px;
    top: -400px; right: -150px;
    background: radial-gradient(circle, rgba(106, 92, 255, 0.14) 0%, transparent 65%);
    pointer-events: none;
    animation: aurora-a 24s ease-in-out infinite alternate;
}
.page-hero .lattice-canvas { position: absolute; inset: 0; opacity: 0.35; }
.page-hero .container { position: relative; z-index: 1; }
.page-hero h1 { max-width: 18em; }
.page-hero .lede { margin-top: 1.2rem; }
.page-hero .hero-actions { margin-top: 2.2rem; display: flex; gap: 1rem; flex-wrap: wrap; }

/* ─── Sections ─── */

.section { padding: 110px 0; position: relative; }
.section-alt { background: var(--bg-raised); border-top: 1px solid var(--line-soft); border-bottom: 1px solid var(--line-soft); }

.section-head { max-width: 720px; margin-bottom: 3.5rem; }
.section-head.centered { margin-left: auto; margin-right: auto; text-align: center; }

.split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4.5rem;
    align-items: center;
}
.split.reverse > .split-media { order: 2; }
.split-media img {
    border-radius: var(--radius);
    border: 1px solid var(--line);
    width: 100%;
    box-shadow: 0 30px 70px -30px rgba(0, 0, 0, 0.7);
}

/* ─── Cards ─── */

.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.5rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }

.card {
    position: relative;
    background: var(--bg-card);
    border: 1px solid var(--line-soft);
    border-radius: var(--radius);
    overflow: hidden;
    transition: transform 0.35s var(--ease), border-color 0.35s, box-shadow 0.35s;
}
.card:hover {
    transform: translateY(-5px);
    border-color: rgba(106, 92, 255, 0.45);
    box-shadow: 0 24px 50px -20px rgba(0, 0, 0, 0.65), 0 0 40px -14px var(--glow);
}
/* light sweep across the card on hover */
.card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(105deg, transparent 42%, rgba(255, 255, 255, 0.055) 50%, transparent 58%);
    transform: translateX(-130%);
    pointer-events: none;
}
.card:hover::after { transition: transform 0.85s var(--ease); transform: translateX(130%); }

/* natural image ratio — no forced crop */
.card-media { overflow: hidden; }
.card-media img { width: 100%; transition: transform 0.6s var(--ease); }
.card:hover .card-media img { transform: scale(1.045); }
.card-body { padding: 1.6rem 1.75rem 1.85rem; }
.card-body h3 { margin-bottom: 0.6rem; }
.card-body p { font-size: 0.98rem; color: var(--dim); }

.card-plain { padding: 1.9rem 1.85rem; }
.card-plain .card-icon {
    width: 44px; height: 44px;
    border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, rgba(106, 92, 255, 0.22), rgba(53, 46, 128, 0.3));
    border: 1px solid rgba(106, 92, 255, 0.35);
    margin-bottom: 1.25rem;
    color: var(--violet-soft);
}

/* ─── Numbered steps (lifecycle) ─── */

.steps { counter-reset: step; display: grid; gap: 1rem; }
.step {
    counter-increment: step;
    display: grid;
    grid-template-columns: 64px 1fr;
    gap: 1.5rem;
    padding: 1.6rem 1.75rem;
    background: var(--bg-card);
    border: 1px solid var(--line-soft);
    border-radius: var(--radius);
    transition: border-color 0.3s, background 0.3s;
    align-items: start;
}
.step:hover { border-color: rgba(106, 92, 255, 0.4); background: rgba(106, 92, 255, 0.045); }
.step::before {
    content: "0" counter(step);
    font-size: 1.5rem;
    font-weight: 200;
    color: var(--violet-soft);
    border-right: 1px solid var(--line-soft);
    padding-right: 1.25rem;
    line-height: 1.3;
}
.step h3 { margin-bottom: 0.35rem; font-size: 1.15rem; }
.step p { font-size: 0.97rem; color: var(--dim); margin: 0; }

/* ─── Feature points (GaN benefits) ─── */

.points { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.75rem; margin: 1.6rem 0; }
.point {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    font-size: 0.95rem;
    color: var(--muted);
    padding: 0.75rem 1.05rem;
    border: 1px solid var(--line-soft);
    border-radius: 10px;
    background: var(--bg-card);
}
.point::before { content: "◆"; color: var(--violet-soft); font-size: 0.65rem; flex-shrink: 0; }

/* ─── Sector chips ─── */

.sector-grid { display: flex; flex-wrap: wrap; gap: 0.7rem; }
.sector-chip {
    padding: 0.55rem 1.1rem;
    border: 1px solid var(--line);
    border-radius: 100px;
    font-size: 0.92rem;
    color: var(--muted);
    background: var(--bg-card);
    transition: border-color 0.3s, color 0.3s, background 0.3s;
    cursor: default;
}
.sector-chip:hover { border-color: rgba(106, 92, 255, 0.55); color: #fff; background: rgba(106, 92, 255, 0.09); }

/* ─── Thermal conductivity chart ─── */

.chart { display: grid; gap: 1.15rem; margin-top: 2.5rem; }
.chart-row { display: grid; grid-template-columns: 190px 1fr 90px; align-items: center; gap: 1.25rem; }
.chart-label { font-size: 0.95rem; color: var(--muted); text-align: right; }
.chart-track { background: rgba(255, 255, 255, 0.05); border-radius: 100px; height: 14px; overflow: hidden; }
.chart-bar {
    height: 100%;
    width: 0;
    border-radius: 100px;
    background: linear-gradient(90deg, var(--indigo), var(--violet));
    transition: width 1.4s var(--ease);
}
.chart-row.highlight .chart-bar { background: linear-gradient(90deg, var(--violet), #b7aeff); box-shadow: 0 0 18px var(--glow); }
.chart-value { font-size: 0.92rem; color: var(--text); font-weight: 400; white-space: nowrap; }
.chart-note { margin-top: 1.5rem; font-size: 0.85rem; color: var(--dim); }

/* ─── CTA band ─── */

.cta-band {
    position: relative;
    border: 1px solid var(--line);
    border-radius: 24px;
    padding: 4.5rem 3rem;
    text-align: center;
    overflow: hidden;
    background:
        radial-gradient(600px 300px at 50% -60%, rgba(106, 92, 255, 0.28), transparent),
        var(--bg-raised);
}
.cta-band h2 { max-width: 22em; margin: 0 auto 1rem; }
.cta-band p { max-width: 40em; margin: 0 auto 2.2rem; }

/* ─── Contact ─── */

.contact-grid { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 4rem; align-items: start; }

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.15rem; }
.form-field { display: flex; flex-direction: column; gap: 0.45rem; }
.form-field.full { grid-column: 1 / -1; }
.form-field label { font-size: 0.85rem; font-weight: 500; color: var(--text); letter-spacing: 0.02em; }
.form-field input, .form-field select, .form-field textarea {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--line);
    border-radius: 10px;
    color: var(--text);
    font: 300 1rem/1.5 "Inter", sans-serif;
    padding: 0.8rem 1rem;
    transition: border-color 0.25s, box-shadow 0.25s;
    width: 100%;
}
.form-field select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%238a93a6' stroke-width='1.5' fill='none'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 1rem center; }
.form-field select option { background: var(--bg-raised); }
.form-field input:focus, .form-field select:focus, .form-field textarea:focus {
    outline: none;
    border-color: var(--violet);
    box-shadow: 0 0 0 3px rgba(106, 92, 255, 0.18);
}
.form-field textarea { min-height: 140px; resize: vertical; }
.hp-field { position: absolute; left: -9999px; opacity: 0; pointer-events: none; }

.form-status { margin-top: 1.1rem; font-size: 0.95rem; display: none; }
.form-status.success { display: block; color: #7ee2a8; }
.form-status.error { display: block; color: #ff8f8f; }

.contact-aside { display: grid; gap: 1.25rem; }
.contact-aside .card-plain h3 { font-size: 1.05rem; margin-bottom: 0.3rem; }
.contact-aside .card-plain p { font-size: 0.97rem; margin: 0; }

/* ─── Footer ─── */

.site-footer {
    position: relative;
    border-top: 1px solid var(--line-soft);
    padding: 72px 0 36px;
    background: var(--bg-raised);
    overflow: hidden;
}
/* gradient hairline + soft centre glow */
.site-footer::before {
    content: "";
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent 10%, rgba(106, 92, 255, 0.5), transparent 90%);
}
.site-footer::after {
    content: "";
    position: absolute;
    width: 720px; height: 340px;
    top: -190px; left: 50%;
    translate: -50% 0;
    background: radial-gradient(closest-side, rgba(106, 92, 255, 0.09), transparent);
    pointer-events: none;
}
.site-footer .container { position: relative; z-index: 1; }

.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 3rem; margin-bottom: 3.5rem; }
.footer-brand img { height: 68px; width: auto; margin-bottom: 1.2rem; }
.footer-brand p { font-size: 0.93rem; color: var(--dim); max-width: 26em; line-height: 1.75; }
.footer-col h4 { font-size: 0.78rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--violet-soft); font-weight: 500; margin: 0.35rem 0 1.3rem; }
.footer-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.4rem; }
.footer-col a, .footer-col li { color: var(--muted); font-size: 0.95rem; }
.footer-col a { display: inline-block; padding: 0.2rem 0; }
.footer-col a:hover { color: #fff; }
.footer-bottom {
    border-top: 1px solid var(--line-soft);
    padding-top: 1.8rem;
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 1rem;
    flex-wrap: wrap;
    font-size: 0.84rem;
    color: var(--dim);
}
.app-version { color: var(--dim); }

/* ─── Hero visual tilt ─── */

.hero-visual { perspective: 1000px; }
.hero-visual img { will-change: transform; transition: transform 0.25s ease-out; }

/* ─── Reconstruction reveals — pieces assemble as you scroll ───
   uses translate/scale (not transform) so hover lifts, tilt and
   parallax transforms compose instead of colliding */

.reveal {
    opacity: 0;
    filter: blur(7px);
    translate: 0 30px;
    /* superset list: reveal props carry the stagger delay, hover props (transform,
       border, shadow, background) keep their own timing with zero delay */
    transition:
        opacity 0.8s var(--ease) var(--reveal-delay, 0s),
        translate 0.8s var(--ease) var(--reveal-delay, 0s),
        scale 0.8s var(--ease) var(--reveal-delay, 0s),
        filter 0.8s ease var(--reveal-delay, 0s),
        transform 0.35s var(--ease),
        border-color 0.35s,
        box-shadow 0.35s,
        background 0.3s;
}
.reveal[data-reveal="left"] { translate: -48px 0; }
.reveal[data-reveal="right"] { translate: 48px 0; }
.reveal[data-reveal="zoom"] { translate: 0 14px; scale: 0.9; }
.reveal.visible { opacity: 1; translate: 0 0; scale: 1; filter: blur(0); }

/* ─── Scroll-linked parallax — native CSS scroll-driven animations ─── */

@supports (animation-timeline: view()) {
    @media (prefers-reduced-motion: no-preference) {
        .split-media img {
            animation: parallax-drift linear both;
            animation-timeline: view();
            animation-range: entry 0% exit 100%;
        }
        .cta-band {
            animation: parallax-rise linear both;
            animation-timeline: view();
            animation-range: entry 0% cover 55%;
        }
    }
}
@keyframes parallax-drift {
    from { transform: translateY(30px); }
    to { transform: translateY(-30px); }
}
@keyframes parallax-rise {
    from { transform: translateY(44px) scale(0.985); }
    to { transform: translateY(0) scale(1); }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .reveal { opacity: 1; translate: none; scale: none; filter: none; transition: none; }
    .split-media img, .cta-band { animation: none; }
    .chart-bar { transition: none; }
    .text-gradient, .hero::before, .hero::after, .page-hero::before { animation: none; }
    .card::after { display: none; }
    .header-inner::before { animation: none; }
    .site-nav, .site-nav > a:not(.btn), .site-nav .btn, .nav-foot { transition: none; filter: none; }
}

/* ─── Arabic / RTL ─── */

html[lang="ar"] body {
    font-family: "Noto Sans Arabic", "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
}
html[lang="ar"] .eyebrow { letter-spacing: 0.08em; }

/* keep latin/technical tokens rendering left-to-right inside RTL */
[dir="rtl"] .hero-stat strong,
[dir="rtl"] .chart-value,
[dir="rtl"] .app-version,
[dir="rtl"] .footer-bottom span,
[dir="rtl"] .nav-foot a,
[dir="rtl"] .contact-aside a { unicode-bidi: plaintext; }
[dir="rtl"] .brand { direction: ltr; }

/* nav underline grows from the reading side */
[dir="rtl"] .site-nav a:not(.btn)::after { left: 100%; right: 0; }
[dir="rtl"] .site-nav a:not(.btn):hover::after,
[dir="rtl"] .site-nav a.active::after { left: 0; }

/* directional arrows point with the text */
[dir="rtl"] .btn .arrow { display: inline-block; transform: scaleX(-1); }
[dir="rtl"] .btn:hover .arrow { transform: scaleX(-1) translateX(3px); }

/* numbered step divider flips to the inline-start */
[dir="rtl"] .step::before {
    border-right: 0;
    border-left: 1px solid var(--line-soft);
    padding-right: 0;
    padding-left: 1.25rem;
}

/* thermal chart in RTL: label hugs the bar, fill grows from the right */
[dir="rtl"] .chart-label { text-align: left; }
[dir="rtl"] .chart-bar { background: linear-gradient(270deg, var(--indigo), var(--violet)); }
[dir="rtl"] .chart-row.highlight .chart-bar { background: linear-gradient(270deg, var(--violet), #b7aeff); }

/* mobile numbered-menu counter sits on the reading side */
[dir="rtl"] .site-nav > a:not(.btn) { flex-direction: row; }

/* ─── Version update banner ─── */

.version-update-bar {
    position: fixed;
    top: 0; left: 0; right: 0;
    background: var(--violet);
    color: #fff;
    padding: 12px;
    text-align: center;
    z-index: 99999;
    cursor: pointer;
    font: 400 0.92rem/1.4 "Inter", sans-serif;
    transform: translateY(-100%);
    transition: transform 0.3s ease;
}
.version-update-bar.visible { transform: translateY(0); }

/* ─── 404 ─── */

.error-page { min-height: 100vh; display: flex; align-items: center; text-align: center; }
.error-page .container { position: relative; z-index: 1; }
.error-code { font-size: clamp(5rem, 14vw, 9rem); font-weight: 200; color: transparent; -webkit-text-stroke: 1px rgba(106, 92, 255, 0.6); line-height: 1; margin-bottom: 1rem; }
.error-lang { position: fixed; top: 22px; right: 22px; z-index: 1000; background: rgba(11, 14, 26, 0.6); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); }
[dir="rtl"] .error-lang { right: auto; left: 22px; }

/* ─── Responsive ─── */

@media (max-width: 1020px) {
    .hero-grid, .split, .split.reverse { grid-template-columns: 1fr; gap: 2.75rem; }
    .split.reverse > .split-media { order: 0; }
    .grid-3 { grid-template-columns: repeat(2, 1fr); }
    .hero-stats { grid-template-columns: repeat(2, 1fr); }
    .contact-grid { grid-template-columns: 1fr; gap: 3rem; }
    .footer-grid { grid-template-columns: 1fr 1fr 1.2fr; gap: 2.5rem; }
    .footer-brand { grid-column: 1 / -1; }
    .hero { min-height: 0; }
}

@media (max-width: 720px) {
    .section { padding: 78px 0; }
    .grid-2, .grid-3 { grid-template-columns: 1fr; }
    .hero-stats { grid-template-columns: 1fr; }
    .points { grid-template-columns: 1fr; }

    /* gentler assembly slides on small screens — nothing pokes past the edge */
    .reveal[data-reveal="left"]:not(.visible) { translate: -24px 0; }
    .reveal[data-reveal="right"]:not(.visible) { translate: 24px 0; }

    /* footer: brand full-width, Explore | Engage paired, Connect full-width */
    .site-footer { padding-top: 56px; }
    .footer-grid { grid-template-columns: 1fr 1fr; gap: 2rem 1.5rem; margin-bottom: 2.75rem; }
    .footer-brand { grid-column: 1 / -1; padding-bottom: 0.5rem; border-bottom: 1px solid var(--line-soft); margin-bottom: 0.5rem; }
    .footer-brand img { height: 60px; }
    .footer-brand p { padding-bottom: 1.5rem; }
    .footer-col:last-child { grid-column: 1 / -1; padding-top: 1rem; border-top: 1px solid var(--line-soft); }
    .footer-bottom { flex-direction: column; align-items: center; text-align: center; gap: 0.4rem; }

    .chart-row { grid-template-columns: 110px 1fr 78px; gap: 0.8rem; }
    .chart-label { font-size: 0.82rem; }
    .form-grid { grid-template-columns: 1fr; }
    .step { grid-template-columns: 48px 1fr; gap: 1rem; padding: 1.3rem 1.25rem; }
    .cta-band { padding: 3.25rem 1.5rem; }

    .nav-toggle { display: flex; }
    .brand { position: relative; z-index: 1001; }

    /* language switch lives in the top bar next to the burger — always visible,
       stays above the open menu overlay so it's one tap away at any time */
    .header-inner { gap: 0.6rem; }
    .header-lang { display: inline-flex; position: relative; z-index: 1001; margin-inline-start: auto; }
    .site-nav .lang-switch { display: none; }   /* the in-menu duplicate is redundant on mobile */

    /* ─── 2026 mobile menu — glass sheet, numbered links, cascading entrance ─── */
    .site-nav {
        position: fixed;
        inset: 0;
        bottom: auto;
        /* lvh: tallest possible viewport — sheet extends behind the browser's
           collapsing URL bar, so no content peeks through during bar moves */
        height: 100vh;
        height: 100lvh;
        overscroll-behavior: contain;
        flex-direction: column;
        align-items: stretch;
        justify-content: flex-start;
        gap: 0;
        padding: calc(var(--header-h) + 34px) 26px calc(34px + env(safe-area-inset-bottom, 0px));
        background:
            radial-gradient(480px 380px at 88% 4%, rgba(106, 92, 255, 0.17), transparent 65%),
            radial-gradient(420px 340px at 6% 98%, rgba(53, 46, 128, 0.22), transparent 65%),
            rgba(6, 8, 14, 0.82);
        -webkit-backdrop-filter: blur(28px) saturate(150%);
        backdrop-filter: blur(28px) saturate(150%);
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.35s var(--ease);
        counter-reset: navitem;
        overflow-y: auto;
    }
    .site-nav.open { opacity: 1; pointer-events: auto; }

    .site-nav > a:not(.btn) {
        display: flex;
        align-items: baseline;
        gap: 1.1rem;
        font-size: 1.5rem;
        font-weight: 300;
        letter-spacing: -0.01em;
        padding: 1.05rem 0.2rem;
        border-bottom: 1px solid var(--line-soft);
        counter-increment: navitem;
        opacity: 0;
        translate: 0 24px;
        filter: blur(5px);
        transition: opacity 0.5s var(--ease), translate 0.5s var(--ease), filter 0.5s ease, color 0.2s;
    }
    .site-nav > a:not(.btn)::before {
        content: "0" counter(navitem);
        font-size: 0.72rem;
        font-weight: 500;
        letter-spacing: 0.14em;
        color: var(--violet-soft);
        min-width: 1.7rem;
    }
    .site-nav a.active { color: #fff; }

    .site-nav .btn {
        margin-top: 2.4rem;
        justify-content: center;
        padding: 1.05rem 1.7rem;
        font-size: 1rem;
        opacity: 0;
        translate: 0 24px;
        transition: opacity 0.5s var(--ease), translate 0.5s var(--ease), transform 0.25s var(--ease), box-shadow 0.25s;
    }

    .site-nav .lang-switch {
        align-self: center;
        margin-top: 1.6rem;
        opacity: 0;
        translate: 0 24px;
        transition: opacity 0.5s var(--ease), translate 0.5s var(--ease);
    }
    .site-nav .lang-switch button { padding: 0.7rem 1.3rem; font-size: 0.95rem; min-width: 60px; }

    .nav-foot {
        display: flex;
        justify-content: space-between;
        align-items: baseline;
        gap: 1rem;
        margin-top: auto;
        padding-top: 2rem;
        font-size: 0.86rem;
        color: var(--dim);
        opacity: 0;
        translate: 0 24px;
        transition: opacity 0.5s var(--ease), translate 0.5s var(--ease);
    }
    .nav-foot a { color: var(--muted); }

    /* cascade: items build in one after another; closing snaps back instantly */
    .site-nav.open > a:not(.btn), .site-nav.open .btn, .site-nav.open .lang-switch, .site-nav.open .nav-foot {
        opacity: 1;
        translate: 0 0;
        filter: blur(0);
    }
    .site-nav.open > *:nth-child(1) { transition-delay: 0.06s; }
    .site-nav.open > *:nth-child(2) { transition-delay: 0.11s; }
    .site-nav.open > *:nth-child(3) { transition-delay: 0.16s; }
    .site-nav.open > *:nth-child(4) { transition-delay: 0.21s; }
    .site-nav.open > *:nth-child(5) { transition-delay: 0.26s; }
    .site-nav.open > *:nth-child(6) { transition-delay: 0.31s; }
    .site-nav.open > *:nth-child(7) { transition-delay: 0.38s; }
    .site-nav.open > *:nth-child(8) { transition-delay: 0.43s; }
    .site-nav.open > *:nth-child(9) { transition-delay: 0.48s; }
}
