@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@400;600;700;800&family=Plus+Jakarta+Sans:wght@400;500;600;700;800;900&display=swap');

:root {
    --color-bg: #FFFFFF;
    --color-bg-subtle: #F8FAFC;
    --color-bg-muted: #F1F5F9;
    --color-shell: rgba(32, 31, 46, 0.9);
    --color-shell-strong: #232131;
    --color-shell-border: rgba(255, 255, 255, 0.08);

    --color-trust: #2563EB;
    --color-trust-light: #3B82F6;
    --color-trust-pale: #EFF6FF;

    --color-text-primary: #0F172A;
    --color-text-secondary: #475569;
    --color-text-muted: #94A3B8;

    --navbar-height: 72px;
    --font-sans: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
}

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

html {
    scroll-behavior: smooth;
    font-family: var(--font-sans);
    max-width: 100%;
    overflow-x: clip;
}

body {
    background: var(--color-bg);
    color: var(--color-text-primary);
    line-height: 1.65;
    max-width: 100%;
    overflow-x: hidden;
}

img,
video,
canvas,
iframe {
    max-width: 100%;
}

::selection {
    background: rgba(37, 99, 235, 0.15);
    color: var(--color-trust);
}

.mx-auto-center {
    margin-left: auto !important;
    margin-right: auto !important;
}

.hero-section {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    min-height: 100vh;
    width: 100%;
}

main > section:first-of-type {
    padding-top: 72px;
}

.site-header {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 60;
    padding: 4px 20px 0;
    transition: background 0.35s ease, box-shadow 0.35s ease, padding 0.35s ease;
}

.site-header.scrolled {
    background: transparent;
    backdrop-filter: none;
    box-shadow: none;
    padding: 4px 20px 0;
}

.site-header-inner {
    width: min(1280px, 100%);
    margin: 0 auto;
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 22px;
}

.site-brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 4px 10px;
    border-radius: 22px;
    background: transparent;
    border: none;
    box-shadow: none;
    text-decoration: none;
    backdrop-filter: none;
}

.site-brand-mark {
    width: 64px;
    height: 64px;
    border-radius: 10px;
    border: none;
    position: relative;
    flex-shrink: 0;
    background: url('logo.png') center/170% no-repeat;
}

.site-brand-mark::before,
.site-brand-mark::after {
    content: none;
}

.site-brand-mark::before {
    top: auto;
    bottom: auto;
}

.site-brand-mark::after {
    top: auto;
    bottom: auto;
}

.site-brand-copy {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.site-brand-title {
    font-size: 1.35rem;
    line-height: 1;
    font-weight: 800;
    letter-spacing: -0.04em;
    color: #ffffff;
}

.site-brand-subtitle {
    font-size: 0.66rem;
    line-height: 1;
    font-weight: 800;
    letter-spacing: 0.24em;
    text-transform: uppercase;
    color: rgba(194, 212, 255, 0.8);
}

.footer-brand {
    direction: ltr;
}

.footer-brand-logo {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    object-fit: cover;
    flex-shrink: 0;
}

.site-header-menu {
    justify-self: center;
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 8px 20px;
    border-radius: 24px;
    background: transparent;
    border: none;
    box-shadow: none;
    backdrop-filter: none;
}

.site-header-link {
    color: rgba(255, 255, 255, 0.72);
    font-size: 0.96rem;
    font-weight: 700;
    text-decoration: none;
    transition: color 0.2s ease, opacity 0.2s ease;
}

.site-header-link:hover,
.site-header-link.is-active {
    color: #ffffff;
}

.site-header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.lang-switch {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 5px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    background: rgba(255, 255, 255, 0.05);
}

.lang-switch-btn {
    border: none;
    border-radius: 999px;
    padding: 6px 10px;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.02em;
    color: rgba(255, 255, 255, 0.72);
    background: transparent;
    cursor: pointer;
    transition: all 0.2s ease;
}

.lang-switch-btn.is-active {
    color: #ffffff;
    background: rgba(59, 130, 246, 0.35);
}

.lang-switch-mobile {
    margin-top: 14px;
    width: fit-content;
}

.site-header-ghost,
.site-header-button,
.site-header-mobile {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    border-radius: 16px;
    padding: 0 18px;
    text-decoration: none;
    border: none;
    backdrop-filter: none;
    box-shadow: none;
}

.site-header-ghost {
    background: transparent;
    color: rgba(255, 255, 255, 0.92);
    font-size: 0.96rem;
    font-weight: 700;
}

.site-header-button {
    background: linear-gradient(135deg, #9b87f5 0%, #7c6bda 100%);
    color: #ffffff;
    font-size: 0.96rem;
    font-weight: 800;
}

.site-header-mobile {
    display: none;
    background: transparent;
    color: #ffffff;
}

.site-header-mobile svg {
    width: 22px;
    height: 22px;
}

.fade-up {
    opacity: 0;
    transform: translateY(36px);
    transition: opacity 0.75s cubic-bezier(0.25, 1, 0.5, 1), transform 0.75s cubic-bezier(0.25, 1, 0.5, 1);
}

.fade-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ---- Mobile Nav Drawer ---- */
.mobile-nav-overlay {
    position: fixed;
    inset: 0;
    z-index: 100;
    background: rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.mobile-nav-overlay.open {
    opacity: 1;
    visibility: visible;
}

.mobile-nav-drawer {
    position: fixed;
    top: 0;
    right: 0;
    z-index: 101;
    width: min(320px, 85vw);
    height: 100vh;
    background: #1a1930;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    transform: translateX(100%);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
}

.mobile-nav-drawer.open {
    transform: translateX(0);
}

.mobile-nav-close {
    align-self: flex-end;
    background: none;
    border: none;
    color: #ffffff;
    cursor: pointer;
    padding: 8px;
    margin-bottom: 12px;
}

.mobile-nav-close svg {
    width: 24px;
    height: 24px;
}

.mobile-nav-drawer a {
    display: block;
    padding: 14px 16px;
    border-radius: 12px;
    color: rgba(255, 255, 255, 0.8);
    font-size: 1.05rem;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.2s ease, color 0.2s ease;
}

.mobile-nav-drawer a:hover,
.mobile-nav-drawer a.is-active {
    background: rgba(255, 255, 255, 0.08);
    color: #ffffff;
}

.mobile-nav-drawer .mobile-nav-cta {
    margin-top: auto;
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.mobile-nav-drawer .mobile-nav-cta a {
    text-align: center;
    padding: 14px 16px;
}

.mobile-nav-drawer .mobile-nav-cta a:last-child {
    background: linear-gradient(135deg, #9b87f5 0%, #7c6bda 100%);
    color: #ffffff;
    border-radius: 14px;
}

html[dir="rtl"] body {
    font-family: 'Cairo', 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
}

html[dir="rtl"] .site-brand-copy {
    align-items: flex-end;
}

html[dir="rtl"] .footer-brand {
    direction: ltr;
}

html[dir="rtl"] .site-header-menu,
html[dir="rtl"] .site-header-actions,
html[dir="rtl"] .mobile-nav-drawer {
    direction: rtl;
}

html[dir="rtl"] .mobile-nav-drawer {
    left: 0;
    right: auto;
    transform: translateX(-100%);
}

html[dir="rtl"] .mobile-nav-drawer.open {
    transform: translateX(0);
}

html[dir="rtl"] .mobile-nav-close {
    align-self: flex-start;
}

html[dir="rtl"] input,
html[dir="rtl"] textarea,
html[dir="rtl"] select {
    text-align: right;
}

/* Improve Arabic hero title readability across shared hero heading patterns. */
html[dir="rtl"] .hero-shell h1,
html[lang="ar"] .hero-shell h1,
html[dir="rtl"] .hero-copy h1,
html[lang="ar"] .hero-copy h1,
html[dir="rtl"] .hero-content-products h1,
html[lang="ar"] .hero-content-products h1 {
    line-height: 1.25;
    letter-spacing: 0.01em;
}

/* Premium Button Styling */
.btn-premium {
    position: relative;
    border-radius: 9999px;
    overflow: hidden;
    transition: all 0.3s ease;
    background-color: #0f172a;
    color: white;
    z-index: 10;
}

.btn-premium::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(120deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transform: translateX(-100%);
    transition: transform 0.6s ease;
    z-index: -1;
}

.btn-premium:hover::before {
    transform: translateX(100%);
}

.btn-premium:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px -5px rgba(15, 23, 42, 0.4);
}

@media (max-width: 1100px) {
    .site-header-inner {
        grid-template-columns: auto auto;
    }

    .site-header-menu,
    .site-header-actions {
        display: none;
    }

    .site-header-mobile {
        display: inline-flex;
        justify-self: end;
    }
}

@media (max-width: 640px) {
    .lang-switch-btn {
        padding: 6px 9px;
        font-size: 0.68rem;
    }
}

@media (max-width: 640px) {
    .site-header {
        padding: 8px 12px 0;
    }

    .site-brand {
        padding: 6px 8px;
        gap: 9px;
    }

    .site-brand-mark {
        width: 42px;
        height: 42px;
        background-size: 165%;
    }

    .site-brand-title {
        font-size: 1rem;
    }

    .site-brand-subtitle {
        font-size: 0.52rem;
        letter-spacing: 0.18em;
    }

    .footer-brand-logo {
        width: 28px;
        height: 28px;
    }
}