:root {
    --ink: #f5f0e8;
    --ink-muted: rgba(245, 240, 232, 0.62);
    --ink-faint: rgba(245, 240, 232, 0.38);
    --midnight: #080b10;
    --midnight-soft: #0d121a;
    --blue: #7fa5c4;
    --champagne: #d7b77a;
    --edge: rgba(245, 240, 232, 0.14);
    --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
    --page-x: clamp(1.25rem, 4.3vw, 5.5rem);
    --page-y: clamp(1.25rem, 3vw, 2.75rem);
    --pointer-x: 0;
    --pointer-y: 0;
}

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

html {
    min-width: 20rem;
    background: var(--midnight);
}

body {
    min-width: 20rem;
    min-height: 100vh;
    min-height: 100svh;
    margin: 0;
    overflow-x: hidden;
    color: var(--ink);
    background: var(--midnight);
    font-family: "Manrope", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-weight: 400;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

::selection {
    color: #0b0e13;
    background: rgba(232, 211, 173, 0.92);
}

.skip-link {
    position: fixed;
    z-index: 100;
    top: 0.75rem;
    left: 0.75rem;
    padding: 0.7rem 1rem;
    color: var(--midnight);
    background: var(--ink);
    border-radius: 0.25rem;
    font-size: 0.8rem;
    font-weight: 600;
    text-decoration: none;
    transform: translateY(-150%);
    transition: transform 180ms ease;
}

.skip-link:focus {
    transform: translateY(0);
}

.scene {
    position: fixed;
    z-index: 0;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
    background:
        radial-gradient(circle at 50% 120%, rgba(32, 53, 71, 0.3), transparent 47%),
        linear-gradient(153deg, #0b1017 0%, #080a0e 45%, #07090d 100%);
}

.js .scene {
    animation: scene-reveal 1.6s ease-out both;
}

.scene__wash {
    position: absolute;
    inset: -25%;
    background:
        radial-gradient(ellipse at 18% 28%, rgba(60, 90, 117, 0.16), transparent 31%),
        radial-gradient(ellipse at 82% 72%, rgba(131, 104, 64, 0.11), transparent 29%);
    animation: wash-drift 20s ease-in-out infinite alternate;
}

.depth {
    position: absolute;
    inset: 0;
    will-change: transform;
}

.depth--far {
    transform: translate3d(calc(var(--pointer-x) * -7px), calc(var(--pointer-y) * -5px), 0);
}

.depth--near {
    transform: translate3d(calc(var(--pointer-x) * 13px), calc(var(--pointer-y) * 9px), 0);
}

.orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(2px);
    will-change: transform, opacity;
}

.orb--blue {
    top: -33vmax;
    left: -26vmax;
    width: 78vmax;
    height: 78vmax;
    background: radial-gradient(circle, rgba(69, 105, 137, 0.2) 0%, rgba(25, 42, 59, 0.07) 43%, transparent 69%);
    animation: orb-blue-drift 17s ease-in-out infinite alternate;
}

.orb--champagne {
    right: -36vmax;
    bottom: -46vmax;
    width: 88vmax;
    height: 88vmax;
    background: radial-gradient(circle, rgba(181, 140, 80, 0.14) 0%, rgba(105, 79, 43, 0.055) 40%, transparent 68%);
    animation: orb-gold-drift 21s ease-in-out infinite alternate;
}

.khotta-mark {
    position: absolute;
    top: 50%;
    left: 50%;
    width: clamp(24rem, 39vw, 43rem);
    height: min(82vh, 52rem);
    opacity: 0.52;
    transform: translate3d(-50%, -50%, 0)
        translate3d(calc(var(--pointer-x) * 6px), calc(var(--pointer-y) * 4px), 0);
    will-change: transform;
}

.khotta-mark::before {
    content: "";
    position: absolute;
    inset: 8% -8% 3%;
    opacity: 0.6;
    border-radius: 50%;
    background: radial-gradient(ellipse at center, rgba(72, 78, 137, 0.11), transparent 66%);
    filter: blur(20px);
}

.khotta-mark__float,
.khotta-mark svg {
    width: 100%;
    height: 100%;
}

.khotta-mark__float {
    animation: khotta-float 12s ease-in-out infinite alternate;
}

.khotta-mark svg {
    display: block;
    overflow: visible;
}

.khotta-mark__art {
    filter:
        drop-shadow(0 0 9px rgba(43, 160, 225, 0.18))
        drop-shadow(0 0 22px rgba(104, 62, 178, 0.12));
}

.khotta-mark__stroke {
    fill: none;
    stroke-width: 24;
    stroke-linecap: round;
}

.khotta-mark__dot {
    filter: drop-shadow(0 0 10px rgba(255, 129, 22, 0.28));
    transform-box: fill-box;
    transform-origin: center;
}

.js .khotta-mark__stroke {
    stroke-dasharray: 1;
    stroke-dashoffset: 1;
    animation: khotta-draw 1.8s var(--ease-out) forwards;
}

.js .khotta-mark__stroke--blue {
    animation-delay: 0.12s;
}

.js .khotta-mark__stroke--purple {
    animation-delay: 0.32s;
}

.js .khotta-mark__dot {
    opacity: 0;
    transform: scale(0.25);
    animation: khotta-dot-in 0.8s 1.15s var(--ease-out) forwards;
}

.beam {
    position: absolute;
    top: -35%;
    width: 1px;
    height: 170%;
    opacity: 0.34;
    transform-origin: center;
    background: linear-gradient(to bottom, transparent, rgba(180, 206, 225, 0.24), transparent 67%);
    box-shadow: 0 0 48px 16px rgba(124, 165, 195, 0.025);
}

.beam--one {
    left: 27%;
    transform: rotate(25deg);
    animation: beam-breathe 9s ease-in-out infinite alternate;
}

.beam--two {
    right: 18%;
    opacity: 0.2;
    transform: rotate(-19deg);
    animation: beam-breathe 12s 2s ease-in-out infinite alternate-reverse;
}

.horizon {
    position: absolute;
    left: 6%;
    right: 6%;
    top: 55%;
    height: 26vh;
    transform: translate3d(0, calc(var(--pointer-y) * 4px), 0);
}

.horizon::before {
    content: "";
    position: absolute;
    inset: 42% 4% auto;
    height: 7rem;
    opacity: 0.62;
    border-radius: 50%;
    background: radial-gradient(ellipse at center, rgba(132, 166, 191, 0.12), rgba(128, 151, 166, 0.025) 45%, transparent 71%);
    filter: blur(16px);
    animation: horizon-breathe 7s ease-in-out infinite alternate;
}

.horizon__core {
    position: absolute;
    top: 48%;
    left: 10%;
    right: 10%;
    height: 1px;
    opacity: 0.65;
    background: linear-gradient(90deg, transparent, rgba(156, 186, 206, 0.08) 14%, rgba(219, 217, 204, 0.26) 50%, rgba(191, 158, 106, 0.08) 86%, transparent);
    box-shadow: 0 0 23px rgba(165, 194, 211, 0.17);
}

.vignette {
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at center, transparent 28%, rgba(3, 5, 8, 0.34) 74%, rgba(3, 4, 7, 0.68) 100%);
}

.grain {
    position: absolute;
    inset: -60%;
    opacity: 0.055;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 220 220' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.92' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.9'/%3E%3C/svg%3E");
    transform: translateZ(0);
    animation: grain-shift 0.24s steps(2) infinite;
}

.page-shell {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-rows: auto 1fr auto;
    width: 100%;
    min-width: 0;
    min-height: 100vh;
    min-height: 100svh;
    padding:
        max(var(--page-y), env(safe-area-inset-top))
        max(var(--page-x), env(safe-area-inset-right))
        max(var(--page-y), env(safe-area-inset-bottom))
        max(var(--page-x), env(safe-area-inset-left));
}

.site-header {
    display: flex;
    min-width: 0;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
}

.wordmark,
.site-footer p,
.language__label,
.status {
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.15em;
}

.wordmark {
    color: rgba(245, 240, 232, 0.86);
    font-size: clamp(0.69rem, 0.72vw, 0.79rem);
    font-weight: 500;
}

.wordmark span {
    color: var(--ink-faint);
}

.status {
    display: flex;
    align-items: center;
    gap: 0.62rem;
    color: var(--ink-muted);
    font-size: 0.62rem;
    font-weight: 500;
    white-space: nowrap;
}

.status__arabic {
    font-family: "IBM Plex Sans Arabic", Tahoma, sans-serif;
    letter-spacing: 0.06em;
}

.status__divider {
    width: 1px;
    height: 0.75rem;
    background: var(--edge);
}

.status__dot {
    position: relative;
    display: grid;
    width: 0.48rem;
    height: 0.48rem;
    place-items: center;
}

.status__dot::before {
    content: "";
    position: absolute;
    inset: -0.24rem;
    border: 1px solid rgba(215, 183, 122, 0.24);
    border-radius: 50%;
    animation: status-ring 2.8s ease-out infinite;
}

.status__dot span {
    width: 0.3rem;
    height: 0.3rem;
    border-radius: 50%;
    background: #cfb27c;
    box-shadow: 0 0 10px rgba(207, 178, 124, 0.54);
}

.hero {
    display: grid;
    min-width: 0;
    align-items: center;
    padding-block: clamp(4rem, 8vh, 7rem);
}

.hero__composition {
    display: grid;
    grid-template-columns: minmax(0, 1fr) clamp(2.5rem, 6vw, 6.75rem) minmax(0, 1fr);
    align-items: center;
    width: min(100%, 100rem);
    min-width: 0;
    margin-inline: auto;
}

.language {
    min-width: 0;
}

.language--english {
    padding-right: clamp(0rem, 2.4vw, 2.75rem);
}

.language--arabic {
    padding-left: clamp(0rem, 2.4vw, 2.75rem);
    font-family: "IBM Plex Sans Arabic", Tahoma, sans-serif;
}

.language__label {
    margin-bottom: clamp(1.25rem, 2.6vh, 2.1rem);
    color: var(--ink-faint);
    font-size: clamp(0.58rem, 0.6vw, 0.68rem);
    font-weight: 500;
}

.language--arabic .language__label {
    letter-spacing: 0.08em;
}

.headline {
    margin: 0;
    color: var(--ink);
    font-size: clamp(2.7rem, 5vw, 6.7rem);
    font-weight: 300;
    line-height: 0.98;
    letter-spacing: -0.055em;
    text-wrap: balance;
}

.headline--arabic {
    font-size: clamp(3.15rem, 5.5vw, 7.2rem);
    font-weight: 300;
    line-height: 1.03;
    letter-spacing: -0.035em;
}

.reveal {
    display: block;
    overflow: hidden;
    padding: 0.08em 0.03em 0.11em;
    margin: -0.08em -0.03em -0.11em;
}

.reveal__inner {
    display: block;
    transform-origin: 50% 100%;
}

.js .reveal__inner {
    opacity: 0;
    filter: blur(12px);
    transform: translate3d(0, 112%, 0) rotate(1.25deg);
    animation: text-rise 1.25s var(--ease-out) forwards;
}

.js .reveal__inner--1 { animation-delay: 0.42s; }
.js .reveal__inner--2 { animation-delay: 0.54s; }
.js .reveal__inner--3 { animation-delay: 0.72s; }
.js .reveal__inner--4 { animation-delay: 0.84s; }

.support {
    max-width: 34rem;
    margin: clamp(1.65rem, 3.6vh, 2.8rem) 0 0;
    color: var(--ink-muted);
    font-size: clamp(0.82rem, 0.93vw, 1rem);
    font-weight: 300;
    line-height: 1.75;
}

.support span {
    display: block;
    color: rgba(245, 240, 232, 0.44);
}

.language--arabic .support {
    margin-right: 0;
    margin-left: auto;
    font-size: clamp(0.9rem, 1vw, 1.06rem);
    line-height: 1.85;
}

.axis {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: clamp(11rem, 29vh, 19rem);
    gap: 0.8rem;
}

.axis__line {
    width: 1px;
    flex: 1;
    background: linear-gradient(to bottom, transparent, rgba(245, 240, 232, 0.16));
}

.axis__line:last-child {
    background: linear-gradient(to bottom, rgba(245, 240, 232, 0.16), transparent);
}

.axis__mark {
    width: 0.38rem;
    height: 0.38rem;
    border: 1px solid rgba(215, 183, 122, 0.48);
    transform: rotate(45deg);
    box-shadow: 0 0 13px rgba(215, 183, 122, 0.16);
}

.site-footer {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 1rem;
    color: var(--ink-faint);
}

.site-footer p {
    flex: 0 0 auto;
    font-size: 0.54rem;
    font-weight: 500;
}

.site-footer__line {
    height: 1px;
    background: var(--edge);
}

.site-footer__line:first-child {
    width: clamp(1.75rem, 5vw, 5.5rem);
}

.site-footer__line:last-child {
    width: min(15rem, 24vw);
    background: linear-gradient(90deg, var(--edge), transparent);
}

.js .entrance {
    opacity: 0;
    transform: translate3d(0, 0.7rem, 0);
    animation: quiet-in 1.05s var(--ease-out) forwards;
}

.js .entrance--label { animation-delay: 0.26s; }
.js .entrance--label-ar { animation-delay: 0.62s; }
.js .entrance--support { animation-delay: 1.08s; }
.js .entrance--support-ar { animation-delay: 1.22s; }
.js .entrance--axis { animation-delay: 0.98s; }
.js .entrance--chrome { animation-delay: 1.35s; }

@keyframes scene-reveal {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes text-rise {
    0% {
        opacity: 0;
        filter: blur(12px);
        transform: translate3d(0, 112%, 0) rotate(1.25deg);
    }
    62% { opacity: 1; }
    100% {
        opacity: 1;
        filter: blur(0);
        transform: translate3d(0, 0, 0) rotate(0);
    }
}

@keyframes quiet-in {
    from {
        opacity: 0;
        transform: translate3d(0, 0.7rem, 0);
    }
    to {
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }
}

@keyframes wash-drift {
    from { transform: translate3d(-1.4%, -0.7%, 0) scale(1); }
    to { transform: translate3d(1.8%, 1.2%, 0) scale(1.045); }
}

@keyframes orb-blue-drift {
    from { opacity: 0.7; transform: translate3d(-1%, -2%, 0) scale(1); }
    to { opacity: 1; transform: translate3d(5%, 3%, 0) scale(1.06); }
}

@keyframes orb-gold-drift {
    from { opacity: 0.72; transform: translate3d(1%, 2%, 0) scale(0.98); }
    to { opacity: 1; transform: translate3d(-4%, -3%, 0) scale(1.045); }
}

@keyframes horizon-breathe {
    from { opacity: 0.48; transform: scaleX(0.94); }
    to { opacity: 0.86; transform: scaleX(1.04); }
}

@keyframes beam-breathe {
    from { opacity: 0.1; }
    to { opacity: 0.38; }
}

@keyframes khotta-draw {
    to { stroke-dashoffset: 0; }
}

@keyframes khotta-dot-in {
    0% {
        opacity: 0;
        transform: scale(0.25);
    }
    68% { opacity: 1; }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes khotta-float {
    from { transform: translate3d(0, -0.7%, 0) rotate(-0.35deg); }
    to { transform: translate3d(0, 0.9%, 0) rotate(0.35deg); }
}

@keyframes status-ring {
    0% { opacity: 0.7; transform: scale(0.55); }
    70%, 100% { opacity: 0; transform: scale(1.45); }
}

@keyframes grain-shift {
    0% { transform: translate3d(-2%, 1%, 0); }
    25% { transform: translate3d(3%, -2%, 0); }
    50% { transform: translate3d(-1%, 3%, 0); }
    75% { transform: translate3d(2%, 2%, 0); }
    100% { transform: translate3d(-3%, -1%, 0); }
}

@media (max-width: 880px) {
    .page-shell {
        min-height: 100svh;
    }

    .hero {
        align-items: center;
        padding-block: clamp(4.5rem, 8vh, 6.5rem);
    }

    .hero__composition {
        grid-template-columns: minmax(0, 1fr);
        align-items: start;
        gap: clamp(2.6rem, 7vh, 4.5rem);
    }

    .language--english,
    .language--arabic {
        width: 100%;
        max-width: 42rem;
        padding: 0;
    }

    .language--arabic {
        justify-self: end;
    }

    .headline {
        font-size: clamp(3rem, 9.5vw, 5.8rem);
    }

    .headline--arabic {
        font-size: clamp(3.35rem, 10.7vw, 6.45rem);
    }

    .support {
        margin-top: 1.35rem;
    }

    .axis {
        position: absolute;
        left: 50%;
        height: 60%;
        opacity: 0.34;
        transform: translateX(-50%);
    }

    .khotta-mark {
        top: 51%;
        width: clamp(21rem, 72vw, 34rem);
        height: min(70vh, 43rem);
        opacity: 0.42;
    }

    .js .entrance--axis {
        transform: translate3d(-50%, 0.7rem, 0);
    }

    .js .entrance--axis {
        animation-name: quiet-in-axis;
    }
}

@keyframes quiet-in-axis {
    from { opacity: 0; transform: translate3d(-50%, 0.7rem, 0); }
    to { opacity: 0.34; transform: translate3d(-50%, 0, 0); }
}

@media (max-width: 560px) {
    :root {
        --page-x: clamp(1.15rem, 6vw, 1.75rem);
        --page-y: clamp(1.15rem, 4vh, 1.65rem);
    }

    .site-header {
        align-items: flex-start;
        gap: 1rem;
    }

    .wordmark {
        padding-top: 0.08rem;
        font-size: 0.62rem;
        letter-spacing: 0.11em;
    }

    .status {
        display: grid;
        grid-template-columns: auto auto;
        gap: 0.2rem 0.45rem;
        font-size: 0.54rem;
        text-align: right;
    }

    .status__dot {
        grid-row: 1 / span 2;
    }

    .status__divider {
        display: none;
    }

    .hero {
        padding-block: clamp(3.75rem, 7.5vh, 5rem);
    }

    .hero__composition {
        gap: clamp(2.65rem, 8vh, 4rem);
    }

    .language__label {
        margin-bottom: 0.9rem;
        font-size: 0.53rem;
    }

    .headline {
        font-size: clamp(2.35rem, 11.25vw, 3.65rem);
        line-height: 1;
    }

    .headline--arabic {
        font-size: clamp(2.7rem, 12.35vw, 4.05rem);
        line-height: 1.04;
    }

    .support,
    .language--arabic .support {
        max-width: 28rem;
        margin-top: 1.1rem;
        font-size: 0.79rem;
        line-height: 1.7;
    }

    .language--arabic .support {
        font-size: 0.86rem;
        line-height: 1.75;
    }

    .site-footer {
        gap: 0.7rem;
    }

    .site-footer__line:last-child {
        flex: 1;
        width: auto;
    }

    .beam--two {
        display: none;
    }

    .khotta-mark {
        top: 51%;
        width: 94vw;
        height: min(66vh, 36rem);
        opacity: 0.38;
    }

    .khotta-mark__stroke {
        stroke-width: 22;
    }

}

@media (max-height: 720px) and (min-width: 881px) {
    .hero {
        padding-block: 2rem;
    }

    .headline {
        font-size: clamp(2.6rem, 4.7vw, 5.4rem);
    }

    .headline--arabic {
        font-size: clamp(3rem, 5.15vw, 6rem);
    }

    .support {
        margin-top: 1.35rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .js .reveal__inner,
    .js .entrance,
    .js .entrance--axis,
    .depth,
    .horizon {
        opacity: 1;
        filter: none;
        transform: none;
    }

    .axis {
        opacity: 0.34;
    }

    .grain {
        animation: none;
    }

    .khotta-mark__float {
        animation: none;
    }

    .js .khotta-mark__stroke {
        stroke-dashoffset: 0;
    }

    .js .khotta-mark__dot {
        opacity: 1;
        transform: none;
    }
}
