* {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: "Jost", sans-serif;
    background: #faf7f2;
    color: #1f1b17;
    overflow-x: hidden;
}

body.loading {
    overflow: hidden;
    height: 100vh;
}

.font-serif {
    font-family: "Cormorant Garamond", serif;
}

[dir="rtl"] body {
    font-family: "IBM Plex Sans Arabic", "Jost", sans-serif;
}

[dir="rtl"] .font-serif,
[dir="rtl"] .italic-accent {
    font-family: "Amiri", "Cormorant Garamond", serif;
}

[dir="rtl"] h1.font-serif,
[dir="rtl"] h2.font-serif {
    font-weight: 400;
    line-height: 1.28;
}

.grain::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.4'/%3E%3C/svg%3E");
    opacity: 0.08;
    pointer-events: none;
    z-index: 2;
    mix-blend-mode: overlay;
}

@media (max-width: 768px) {
    .grain::before {
        display: none;
    }
}

#preloader {
    position: fixed;
    inset: 0;
    z-index: 200;
    background: #1f1b17;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    transition:
        opacity 0.8s ease,
        visibility 0.8s ease;
}

#preloader.done {
    opacity: 0;
    visibility: hidden;
}

.pre-line {
    width: 0;
    height: 1px;
    background: #b8946a;
    transition: width 1.6s cubic-bezier(0.7, 0, 0.3, 1);
}

.pre-line.go {
    width: 240px;
}

.pre-brand {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 1.5rem;
    opacity: 0;
    width: 200px;
    height: 72px;
    transition: opacity 1s ease 0.2s;
}

.pre-logo-frame {
    display: flex;
    align-items: center;
    justify-content: center;
    /* min-width: 168px; */
    /* padding: 1rem 1.75rem; */
    /* background: #faf7f2; */
    /* box-shadow: 0 12px 40px rgba(0, 0, 0, 0.22); */
}

.pre-logo {
    display: block;
    max-width: 600px;
    /* max-height: 72px; */
    width: auto;
    height: auto;
    object-fit: contain;
}

.pre-brand-name {
    font-family: "Cormorant Garamond", "Amiri", serif;
    color: #faf7f2;
    font-size: 1.75rem;
    letter-spacing: 0.04em;
    line-height: 1.2;
}

[dir="rtl"] .pre-brand-name {
    letter-spacing: 0;
    width: 100px;
}

.pre-sub {
    opacity: 0;
    transition: opacity 1s ease 0.2s;
}

.cursor-dot {
    position: fixed;
    top: 0;
    left: 0;
    width: 8px;
    height: 8px;
    background: #b8946a;
    border-radius: 50%;
    pointer-events: none;
    z-index: 999;
    transform: translate(-50%, -50%);
    transition:
        width 0.3s,
        height 0.3s,
        background 0.3s;
    mix-blend-mode: difference;
}

.cursor-dot.expand {
    width: 60px;
    height: 60px;
    background: rgba(184, 148, 106, 0.3);
}

@media (max-width: 1024px), (pointer: coarse) {
    .cursor-dot {
        display: none;
    }
}

#navbar {
    padding-top: 1.5rem;
    padding-bottom: 1.5rem;
}

#navbar.is-scrolled {
    background: rgba(250, 247, 242, 0.92);
    backdrop-filter: blur(12px);
    padding-top: 1rem;
    padding-bottom: 1rem;
    box-shadow: 0 1px 0 rgba(31, 27, 23, 0.08);
}

#navbar .nav-ink {
    color: #faf7f2;
    transition: color 0.4s;
}

.nav-logo-frame,
.footer-logo-frame {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    /* background: #faf7f2; */
    padding: 0.4rem 0.7rem;
}

.nav-logo {
    display: block;
    max-height: 42px;
    max-width: min(168px, 42vw);
    width: auto;
    height: auto;
    object-fit: contain;
}

.footer-logo {
    display: block;
    max-height: 56px;
    max-width: 200px;
    width: auto;
    height: auto;
    object-fit: contain;
}

#navbar.is-scrolled .nav-logo-frame {
    box-shadow: 0 1px 0 rgba(31, 27, 23, 0.08);
}

#navbar.is-scrolled .nav-ink {
    color: #1f1b17;
}

.project-filter.is-active {
    background: #1f1b17;
    color: #faf7f2;
}

.project-cell.is-filtered-out {
    display: none;
}

.hero-img {
    transform: scale(1.12);
    transition: transform 8s ease-out;
}

.hero-img.go {
    transform: scale(1);
}

.hero-side-label {
    writing-mode: vertical-rl;
    transform: rotate(180deg);
}

.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition:
        opacity 1.2s cubic-bezier(0.2, 0.6, 0.2, 1),
        transform 1.2s cubic-bezier(0.2, 0.6, 0.2, 1);
}

.reveal.in {
    opacity: 1;
    transform: translateY(0);
}

.reveal-stagger > * {
    opacity: 0;
    transform: translateY(30px);
    transition:
        opacity 0.9s cubic-bezier(0.2, 0.6, 0.2, 1),
        transform 0.9s cubic-bezier(0.2, 0.6, 0.2, 1);
}

.reveal-stagger.in > * {
    opacity: 1;
    transform: translateY(0);
}

.reveal-stagger.in > *:nth-child(1) {
    transition-delay: 0.05s;
}
.reveal-stagger.in > *:nth-child(2) {
    transition-delay: 0.15s;
}
.reveal-stagger.in > *:nth-child(3) {
    transition-delay: 0.25s;
}
.reveal-stagger.in > *:nth-child(4) {
    transition-delay: 0.35s;
}
.reveal-stagger.in > *:nth-child(5) {
    transition-delay: 0.45s;
}
.reveal-stagger.in > *:nth-child(6) {
    transition-delay: 0.55s;
}

.clip-reveal {
    clip-path: inset(0 0 100% 0);
    transition: clip-path 1.4s cubic-bezier(0.7, 0, 0.3, 1);
}

.clip-reveal.in {
    clip-path: inset(0 0 0 0);
}

.clip-reveal-r {
    clip-path: inset(0 100% 0 0);
    transition: clip-path 1.4s cubic-bezier(0.7, 0, 0.3, 1);
}

.clip-reveal-r.in {
    clip-path: inset(0 0 0 0);
}

[dir="rtl"] .clip-reveal-r {
    clip-path: inset(0 0 0 100%);
}

[dir="rtl"] .clip-reveal-r.in {
    clip-path: inset(0 0 0 0);
}

.h-line {
    height: 1px;
    background: currentColor;
    opacity: 0.2;
}

.v-line {
    width: 1px;
    background: currentColor;
    opacity: 0.2;
}

.gold-line {
    background: #b8946a;
}

.btn-primary {
    position: relative;
    overflow: hidden;
    background: #1f1b17;
    color: #faf7f2;
    transition: color 0.5s ease;
}

.btn-primary::before {
    content: "";
    position: absolute;
    inset: 0;
    background: #b8946a;
    transform: translateY(101%);
    transition: transform 0.5s cubic-bezier(0.7, 0, 0.3, 1);
    z-index: 0;
}

.btn-primary:hover::before {
    transform: translateY(0);
}

.btn-primary > * {
    position: relative;
    z-index: 1;
}

.btn-primary .arrow {
    transition: transform 0.4s ease;
}

.btn-primary:hover .arrow {
    transform: translateX(4px);
}

.btn-outline {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(31, 27, 23, 0.3);
    color: #1f1b17;
    transition:
        color 0.5s ease,
        border-color 0.5s ease;
}

.btn-outline::before {
    content: "";
    position: absolute;
    inset: 0;
    background: #1f1b17;
    transform: translateY(101%);
    transition: transform 0.5s cubic-bezier(0.7, 0, 0.3, 1);
    z-index: 0;
}

.btn-outline:hover::before {
    transform: translateY(0);
}

.btn-outline:hover {
    color: #faf7f2;
    border-color: #1f1b17;
}

.btn-outline > * {
    position: relative;
    z-index: 1;
}

.btn-outline .arrow {
    transition: transform 0.4s ease;
}

.btn-outline:hover .arrow {
    transform: translateX(4px);
}

.btn-light-outline {
    border: 1px solid rgba(250, 247, 242, 0.4);
    color: #faf7f2;
    position: relative;
    overflow: hidden;
    transition: color 0.5s ease;
}

.btn-light-outline::before {
    content: "";
    position: absolute;
    inset: 0;
    background: #faf7f2;
    transform: translateY(101%);
    transition: transform 0.5s cubic-bezier(0.7, 0, 0.3, 1);
    z-index: 0;
}

.btn-light-outline:hover::before {
    transform: translateY(0);
}

.btn-light-outline:hover {
    color: #1f1b17;
}

.btn-light-outline > * {
    position: relative;
    z-index: 1;
}

.project-card {
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.project-card img {
    transition: transform 1.2s cubic-bezier(0.2, 0.6, 0.2, 1);
}

.project-card:hover img {
    transform: scale(1.06);
}

.project-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(31, 27, 23, 0) 30%,
        rgba(31, 27, 23, 0.85) 100%
    );
    opacity: 0;
    transition: opacity 0.6s ease;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 2rem;
}

.project-card:hover .project-overlay {
    opacity: 1;
}

.project-info {
    transform: translateY(20px);
    transition: transform 0.6s cubic-bezier(0.7, 0, 0.3, 1);
}

.project-card:hover .project-info {
    transform: translateY(0);
}

.project-arrow {
    transform: translate(-10px, 10px);
    opacity: 0;
    transition: all 0.6s cubic-bezier(0.7, 0, 0.3, 1) 0.1s;
}

.project-card:hover .project-arrow {
    transform: translate(0, 0);
    opacity: 1;
}

.service-card {
    position: relative;
    transition: all 0.5s ease;
}

.service-card .gold-accent {
    width: 0;
    height: 1px;
    background: #b8946a;
    transition: width 0.6s cubic-bezier(0.7, 0, 0.3, 1);
}

.service-card:hover .gold-accent {
    width: 100%;
}

.service-card .svc-img {
    height: 0;
    overflow: hidden;
    transition: height 0.6s cubic-bezier(0.7, 0, 0.3, 1);
}

.service-card:hover .svc-img {
    height: 200px;
}

.service-card .svc-img img {
    transition: transform 1.5s ease;
}

.service-card:hover .svc-img img {
    transform: scale(1.05);
}

.mobile-menu {
    position: fixed;
    inset: 0;
    z-index: 90;
    background: #1f1b17;
    transform: translateY(-100%);
    transition: transform 0.7s cubic-bezier(0.7, 0, 0.3, 1);
}

.mobile-menu.open {
    transform: translateY(0);
}

.mobile-menu a {
    opacity: 0;
    transform: translateY(20px);
    transition:
        opacity 0.5s ease,
        transform 0.5s ease;
}

.mobile-menu.open a {
    opacity: 1;
    transform: translateY(0);
}

.mobile-menu.open a:nth-child(1) {
    transition-delay: 0.2s;
}
.mobile-menu.open a:nth-child(2) {
    transition-delay: 0.28s;
}
.mobile-menu.open a:nth-child(3) {
    transition-delay: 0.36s;
}
.mobile-menu.open a:nth-child(4) {
    transition-delay: 0.44s;
}
.mobile-menu.open a:nth-child(5) {
    transition-delay: 0.52s;
}
.mobile-menu.open a:nth-child(6) {
    transition-delay: 0.6s;
}

@keyframes marquee {
    from {
        transform: translateX(0);
    }
    to {
        transform: translateX(-50%);
    }
}

.marquee-track {
    animation: marquee 40s linear infinite;
}

@keyframes scrollDown {
    0% {
        transform: translateY(-100%);
        opacity: 0;
    }
    30% {
        opacity: 1;
    }
    100% {
        transform: translateY(100%);
        opacity: 0;
    }
}

.scroll-line {
    animation: scrollDown 2.4s ease-in-out infinite;
}

.stat-num {
    font-variant-numeric: tabular-nums;
}

.no-scrollbar::-webkit-scrollbar {
    display: none;
}

.no-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

img {
    display: block;
}

.phil-line {
    width: 0;
    transition: width 1.2s cubic-bezier(0.7, 0, 0.3, 1);
}

.phil-line.in {
    width: 100%;
}

.process-timeline {
    position: relative;
    max-width: 52rem;
    margin-inline: auto;
}

.process-timeline-line {
    position: absolute;
    top: 0.75rem;
    bottom: 0.75rem;
    left: 0.7rem;
    width: 1px;
    background: rgba(31, 27, 23, 0.12);
    overflow: hidden;
    transform: translateX(-50%);
}

.process-line-fill {
    width: 100%;
    height: 100%;
    background: #b8946a;
    transform: scaleY(0);
    transform-origin: top;
    transition: transform 1.5s cubic-bezier(0.7, 0, 0.3, 1);
}

.process-line-fill.in {
    transform: scaleY(1);
}

.process-steps {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 3.5rem;
}

.process-step {
    position: relative;
    padding-left: 2.75rem;
}

.process-dot {
    position: absolute;
    top: 0.85rem;
    left: 0.7rem;
    width: 13px;
    height: 13px;
    border-radius: 50%;
    background: #b8946a;
    border: 3px solid #f5f0e8;
    box-shadow: 0 0 0 1px rgba(184, 148, 106, 0.35);
    transform: translateX(-50%);
    z-index: 1;
}

.process-step-num {
    font-family: "Cormorant Garamond", "Amiri", serif;
    color: #b8946a;
    font-size: 2.75rem;
    font-weight: 300;
    line-height: 1;
    margin-bottom: 0.75rem;
}

.process-step-title {
    font-family: "Cormorant Garamond", "Amiri", serif;
    color: #1f1b17;
    font-size: 1.75rem;
    font-weight: 400;
    line-height: 1.2;
    margin-bottom: 0.65rem;
}

.process-step-body {
    color: rgba(31, 27, 23, 0.7);
    line-height: 1.7;
    font-weight: 300;
    max-width: 28rem;
}

[dir="rtl"] .process-timeline-line,
[dir="rtl"] .process-dot {
    left: auto;
    right: 0.7rem;
    transform: translateX(50%);
}

[dir="rtl"] .process-step {
    padding-left: 0;
    padding-right: 2.75rem;
}

@media (min-width: 768px) {
    .process-timeline-line,
    [dir="rtl"] .process-timeline-line {
        left: 50%;
        right: auto;
        transform: translateX(-50%);
    }

    .process-step,
    [dir="rtl"] .process-step {
        display: grid;
        grid-template-columns: 1fr 1fr;
        column-gap: 4.5rem;
        padding-left: 0;
        padding-right: 0;
        align-items: start;
    }

    .process-dot,
    [dir="rtl"] .process-dot {
        left: 50%;
        right: auto;
        top: 1.1rem;
        transform: translateX(-50%);
    }

    .process-step.is-start .process-step-card {
        grid-column: 1;
        justify-self: end;
        text-align: end;
    }

    .process-step.is-end .process-step-card {
        grid-column: 2;
        justify-self: start;
        text-align: start;
    }
}

::selection {
    background: #b8946a;
    color: #faf7f2;
}

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

    .hero-img {
        transform: scale(1) !important;
    }

    .clip-reveal,
    .clip-reveal-r {
        clip-path: none !important;
    }
}

[x-cloak] {
    display: none !important;
}

.italic-accent {
    font-style: italic;
    font-weight: 400;
    color: #b8946a;
}

.section-pad {
    padding-top: 8rem;
    padding-bottom: 8rem;
}

@media (max-width: 768px) {
    .section-pad {
        padding-top: 5rem;
        padding-bottom: 5rem;
    }
}

.tracking-luxe {
    letter-spacing: 0.3em;
}

.tracking-luxe-sm {
    letter-spacing: 0.2em;
}

[dir="rtl"] .tracking-luxe,
[dir="rtl"] .tracking-luxe-sm {
    letter-spacing: 0.12em;
}

.site-lang {
    position: relative;
}

.site-lang-toggle {
    list-style: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 12px;
    letter-spacing: 0.04em;
}

.site-lang-toggle::-webkit-details-marker {
    display: none;
}

.site-lang-menu {
    position: absolute;
    top: calc(100% + 8px);
    inset-inline-end: 0;
    min-width: 200px;
    background: #faf7f2;
    color: #1f1b17;
    border: 1px solid rgba(31, 27, 23, 0.08);
    box-shadow: 0 16px 40px rgba(31, 27, 23, 0.12);
    padding: 8px;
    z-index: 80;
    max-height: 320px;
    overflow: auto;
}

.site-lang-menu a {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    font-size: 13px;
}

.site-lang-menu a.is-active {
    color: #b8946a;
}

body.gated,
body.needs-gate.loading {
    overflow: hidden;
    height: 100vh;
}

.visitor-gate {
    position: fixed;
    inset: 0;
    z-index: 180;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.7s ease, visibility 0.7s ease;
}

body.needs-gate:not(.loading) .visitor-gate,
.visitor-gate.is-visible {
    opacity: 1;
    visibility: visible;
}

.visitor-gate::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(31, 27, 23, 0.32);
    backdrop-filter: blur(22px) saturate(160%);
    -webkit-backdrop-filter: blur(22px) saturate(160%);
}

.visitor-gate-water {
    position: absolute;
    inset: -25%;
    pointer-events: none;
    background:
        radial-gradient(ellipse at 18% 22%, rgba(184, 148, 106, 0.32), transparent 52%),
        radial-gradient(ellipse at 82% 28%, rgba(250, 247, 242, 0.24), transparent 46%),
        radial-gradient(ellipse at 48% 82%, rgba(126, 168, 186, 0.2), transparent 50%);
    animation: waterDrift 18s ease-in-out infinite alternate;
}

@keyframes waterDrift {
    from { transform: translate(-3%, -2%) scale(1.04); }
    to { transform: translate(4%, 5%) scale(1.12); }
}

.visitor-gate-box {
    position: relative;
    z-index: 1;
    width: min(420px, 100%);
    padding: 2.5rem 2rem 2rem;
    text-align: center;
    background: rgba(250, 247, 242, 0.72);
    border: 1px solid rgba(250, 247, 242, 0.45);
    backdrop-filter: blur(28px) saturate(180%);
    -webkit-backdrop-filter: blur(28px) saturate(180%);
    box-shadow: 0 24px 80px rgba(20, 16, 12, 0.28);
}

.visitor-gate-logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #faf7f2;
    padding: 0.55rem 0.9rem;
    margin-bottom: 1.25rem;
}

.visitor-gate-logo img {
    display: block;
    max-height: 48px;
    max-width: 180px;
    object-fit: contain;
}

.visitor-gate-name {
    font-size: 1.6rem;
    color: #1f1b17;
    margin-bottom: 1rem;
}

.visitor-gate-box h2 {
    font-size: clamp(1.6rem, 3vw, 2.1rem);
    font-weight: 400;
    color: #1f1b17;
    margin-bottom: 0.75rem;
    line-height: 1.25;
}

.visitor-gate-box > p {
    color: rgba(31, 27, 23, 0.7);
    font-weight: 300;
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.visitor-gate-error {
    background: rgba(180, 60, 50, 0.1);
    color: #8a2b22;
    font-size: 0.82rem;
    padding: 0.7rem 0.9rem;
    margin-bottom: 1rem;
}

.visitor-gate-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.7rem;
    width: 100%;
    padding: 0.95rem 1rem;
    margin-bottom: 0.7rem;
    font-size: 0.78rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.visitor-gate-google {
    background: #1f1b17;
    color: #faf7f2;
}

.visitor-gate-google:hover {
    background: #b8946a;
    color: #1f1b17;
}

.visitor-gate-facebook {
    background: #1877f2;
    color: #fff;
}

.visitor-gate-facebook:hover {
    background: #0f5fcc;
}

.visitor-gate-note {
    margin: 0.4rem 0 0 !important;
    font-size: 0.72rem !important;
    color: rgba(31, 27, 23, 0.45) !important;
}

[dir="rtl"] .visitor-gate-btn {
    letter-spacing: 0;
}
