:root {
    --color-bg: #ffffff;
    --color-bg-soft: #f6f8fc;
    --color-text: #1a1d29;
    --color-text-muted: #5a6072;
    --color-border: #e5e9f0;
    --color-primary: #2563eb;
    --color-primary-dark: #1d4ed8;
    --color-primary-soft: #eaf1ff;
    --color-accent: #f59e0b;
    --max-width: 1120px;
    --radius: 16px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--color-bg);
    color: var(--color-text);
    line-height: 1.6;
    font-size: 16px;
}

img {
    max-width: 100%;
    display: block;
}

a {
    color: var(--color-primary);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

h1, h2, h3 {
    line-height: 1.25;
    color: var(--color-text);
}

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

/* ---------- Site nav ---------- */

.site-nav {
    border-bottom: 1px solid var(--color-border);
    position: sticky;
    top: 0;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: saturate(180%) blur(10px);
    z-index: 20;
}

.site-nav__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding-top: 14px;
    padding-bottom: 14px;
}

.site-nav__brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 17px;
    color: var(--color-text);
}

.site-nav__brand img {
    width: 32px;
    height: 32px;
    border-radius: 8px;
}

.site-nav__links {
    display: flex;
    align-items: center;
    gap: 24px;
    font-size: 15px;
    font-weight: 500;
}

.site-nav__links a {
    color: var(--color-text-muted);
}

.site-nav__links a:hover {
    color: var(--color-text);
}

.site-nav__right {
    display: flex;
    align-items: center;
    gap: 14px;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 20px;
    border-radius: 999px;
    font-weight: 600;
    font-size: 15px;
    border: 1px solid transparent;
    cursor: pointer;
    white-space: nowrap;
}

.btn:hover {
    text-decoration: none;
}

.btn--primary {
    background: var(--color-primary);
    color: #fff;
}

.btn--primary:hover {
    background: var(--color-primary-dark);
}

.btn--small {
    padding: 8px 16px;
    font-size: 14px;
}

/* ---------- Language switcher ---------- */

.lang-switch {
    position: relative;
}

.lang-switch > summary {
    list-style: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border-radius: 999px;
    border: 1px solid var(--color-border);
    font-size: 14px;
    font-weight: 500;
    color: var(--color-text);
}

.lang-switch > summary::-webkit-details-marker {
    display: none;
}

.lang-switch__menu {
    position: absolute;
    inset-inline-end: 0;
    top: calc(100% + 8px);
    background: #fff;
    border: 1px solid var(--color-border);
    border-radius: 12px;
    box-shadow: 0 12px 32px rgba(20, 24, 40, 0.14);
    padding: 6px;
    min-width: 200px;
    max-height: 320px;
    overflow-y: auto;
    display: grid;
    gap: 2px;
}

.lang-switch__menu a {
    display: block;
    padding: 9px 12px;
    border-radius: 8px;
    font-size: 14px;
    color: var(--color-text);
}

.lang-switch__menu a:hover {
    background: var(--color-bg-soft);
    text-decoration: none;
}

.lang-switch__menu a[aria-current="true"] {
    background: var(--color-primary-soft);
    color: var(--color-primary-dark);
    font-weight: 600;
}

/* ---------- Hero ---------- */

.hero {
    background: linear-gradient(180deg, #eef4ff 0%, #ffffff 65%);
    padding: 64px 0 40px;
}

.hero__inner {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 48px;
    align-items: center;
}

.eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-size: 13px;
    font-weight: 700;
    color: var(--color-primary);
    margin: 0 0 12px;
}

.hero__title {
    font-size: 44px;
    font-weight: 800;
    margin: 0 0 18px;
    letter-spacing: -0.02em;
}

.hero__subtitle {
    font-size: 18px;
    color: var(--color-text-muted);
    margin: 0 0 28px;
    max-width: 46ch;
}

.hero__cta-row {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 28px;
}

.cta-note {
    font-size: 13px;
    color: var(--color-text-muted);
}

.badge-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #fff;
    border: 1px solid var(--color-border);
    padding: 7px 14px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 600;
    color: var(--color-text-muted);
}

.hero__image {
    justify-self: center;
}

.hero__carousel {
    position: relative;
    max-width: 355px;
    width: 100%;
    aspect-ratio: 1614 / 3322;
}

.hero__carousel .phone-mockup {
    position: absolute;
    inset: 0;
    opacity: 0;
    animation: hero-carousel-fade 25s infinite;
    animation-delay: calc(var(--i, 0) * 5s);
}

.hero__carousel .phone-mockup .phone-frame {
    height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 30px 40px rgba(30, 45, 90, 0.35));
}


.hero__carousel .phone-mockup .phone-screen {
    position: absolute;
    z-index: 1;
    left: 20px;
    top: 24px;
    width: calc(100% - 39px);
    height: calc(100% - 47px);
    border-radius: 12px;
}

@keyframes hero-carousel-fade {
    0% {
        opacity: 0;
    }
    2.4% {
        opacity: 1;
    }
    17.6% {
        opacity: 1;
    }
    20% {
        opacity: 0;
    }
    100% {
        opacity: 0;
    }
}

@media (prefers-reduced-motion: reduce) {
    .hero__carousel .phone-mockup {
        animation: none;
        opacity: 0;
    }

    .hero__carousel .phone-mockup:first-child {
        opacity: 1;
    }
}

/* ---------- iPhone frame mockups (bare frame + CSS positioned screenshot) ---------- */

.phone-mockup {
    position: relative;
    width: 100%;
}

.phone-mockup .phone-frame {
    width: 100%;
    height: auto;
    display: block;
    z-index: 2;
    position: relative;
}

.phone-mockup .phone-screen {
    position: absolute;
    z-index: 1;
    left: 14px;
    top: 11px;
    width: calc(100% - 27px);
    height: calc(100% - 22px);
    border-radius: 12px;
}

.phone-mockup .phone-screen img {
    width: 100%;
    height: 100%;
    display: block;
}

/* ---------- Sections ---------- */

section {
    padding: 72px 0;
}

.section-head {
    text-align: center;
    max-width: 640px;
    margin: 0 auto 48px;
}

.section-head h2 {
    font-size: 32px;
    font-weight: 800;
    margin: 0;
    letter-spacing: -0.01em;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 28px;
}

.feature-card {
    display: grid;
    grid-template-columns: 243px 1fr;
    gap: 24px;
    align-items: center;
    background: var(--color-bg-soft);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: 24px;
}

.feature-card .phone-mockup .phone-frame {
    filter: drop-shadow(0 16px 20px rgba(30, 45, 90, 0.25));
}

.feature-card h3 {
    font-size: 19px;
    margin: 0 0 8px;
}

.feature-card p {
    margin: 0;
    color: var(--color-text-muted);
    font-size: 15px;
}

.feature-card:nth-child(odd) {
    grid-template-columns: 243px 1fr;
}

.feature-card:nth-child(even) {
    grid-template-columns: 1fr 243px;
}

.feature-card:nth-child(even) .phone-mockup {
    order: 2;
}

.panel {
    background: var(--color-primary-soft);
    border-radius: 24px;
    padding: 56px;
    text-align: center;
}

.panel h2 {
    font-size: 28px;
    font-weight: 800;
    margin: 0 0 14px;
}

.panel p {
    color: var(--color-text-muted);
    font-size: 16px;
    max-width: 60ch;
    margin: 0 auto;
}

.lang-pill-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    margin-top: 28px;
}

.lang-pill {
    background: #fff;
    border: 1px solid var(--color-border);
    border-radius: 999px;
    padding: 8px 16px;
    font-size: 14px;
    font-weight: 600;
}

.faq-list {
    max-width: 760px;
    margin: 0 auto;
    display: grid;
    gap: 14px;
}

.faq-item {
    border: 1px solid var(--color-border);
    border-radius: 14px;
    padding: 4px 20px;
    background: #fff;
}

.faq-item > summary {
    list-style: none;
    cursor: pointer;
    padding: 18px 0;
    font-weight: 700;
    font-size: 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.faq-item > summary::-webkit-details-marker {
    display: none;
}

.faq-item > summary::after {
    content: '+';
    font-size: 22px;
    font-weight: 400;
    color: var(--color-text-muted);
    flex-shrink: 0;
}

.faq-item[open] > summary::after {
    content: '\2212';
}

.faq-item p {
    margin: 0 0 18px;
    color: var(--color-text-muted);
}

.final-cta {
    text-align: center;
}

.final-cta h2 {
    font-size: 30px;
    font-weight: 800;
    margin: 0 0 10px;
}

.final-cta p {
    color: var(--color-text-muted);
    margin: 0 0 26px;
}

/* ---------- Legal / support pages ---------- */

.page-header {
    padding: 48px 0 8px;
}

.page-header h1 {
    font-size: 34px;
    font-weight: 800;
    margin: 0 0 8px;
}

.page-header .meta {
    color: var(--color-text-muted);
    font-size: 14px;
}

.prose {
    padding: 24px 0 64px;
    max-width: 760px;
    margin: 0 auto;
}

.prose h2 {
    font-size: 20px;
    margin: 36px 0 12px;
}

.prose p, .prose li {
    color: var(--color-text-muted);
    font-size: 16px;
}

.prose ul {
    padding-inline-start: 22px;
}

.prose strong {
    color: var(--color-text);
}

.contact-box {
    background: var(--color-bg-soft);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: 20px 24px;
    margin: 20px 0;
}

/* ---------- Footer ---------- */

.site-footer {
    border-top: 1px solid var(--color-border);
    padding: 40px 0;
}

.site-footer__inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    font-size: 14px;
    color: var(--color-text-muted);
}

.site-footer__links {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.site-footer__links a {
    color: var(--color-text-muted);
}

/* ---------- RTL ---------- */

[dir="rtl"] .feature-card:nth-child(odd),
[dir="rtl"] .feature-card:nth-child(even) {
    grid-template-columns: 243px 1fr;
}

[dir="rtl"] .feature-card:nth-child(even) .phone-mockup {
    order: 0;
}

[dir="rtl"] .faq-item > summary::after {
    content: '+';
}

/* ---------- Responsive ---------- */

@media (max-width: 860px) {
    .hero__inner {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero__subtitle {
        max-width: none;
        margin-inline: auto;
    }

    .hero__cta-row,
    .badge-row {
        justify-content: center;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .feature-card,
    [dir="rtl"] .feature-card:nth-child(odd),
    [dir="rtl"] .feature-card:nth-child(even) {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .feature-card .phone-mockup,
    [dir="rtl"] .feature-card:nth-child(even) .phone-mockup {
        order: 0;
        justify-self: center;
        max-width: 243px;
        margin: 0 auto;
    }

    .site-nav__links {
        display: none;
    }

    .panel {
        padding: 32px 20px;
    }

    .hero__title {
        font-size: 32px;
    }
}
