@font-face {
    font-family: "Manrope";
    src: url("assets/fonts/manrope-regular.ttf") format("truetype");
    font-style: normal;
    font-weight: 400;
    font-display: swap;
}
@font-face {
    font-family: "Manrope";
    src: url("assets/fonts/manrope-semibold.ttf") format("truetype");
    font-style: normal;
    font-weight: 600;
    font-display: swap;
}
@font-face {
    font-family: "Manrope";
    src: url("assets/fonts/manrope-extrabold.ttf") format("truetype");
    font-style: normal;
    font-weight: 800;
    font-display: swap;
}

/* ── Tokens — Light theme (default) ────────── */
:root {
    --brand:        #2DC98A;
    --brand-mint:   #47D9A0;
    --brand-vivid:  #00C878;
    --brand-deep:   #1AAF72;
    --brand-soft:   #E6FAF2;
    --brand-border: rgba(45, 201, 138, 0.25);
    --accent:       #0D9155;
    --accent-soft:  #D4F4E4;
    --gold:         #FFD93D;

    --bg:           #F0FBF6;
    --bg-deep:      #D9F4E9;
    --surface:      rgba(255, 255, 255, 0.84);
    --surface-strong: #ffffff;

    --ink:          #0D2218;
    --ink-soft:     #4A6B59;
    --line:         rgba(13, 34, 24, 0.1);
    --white:        #ffffff;

    --shadow:       0 24px 60px rgba(13, 34, 24, 0.13);
    --shadow-soft:  0 8px 28px rgba(13, 34, 24, 0.07);
    --glow:         0 0 40px rgba(45, 201, 138, 0.2);

    --radius-lg:  32px;
    --radius-md:  24px;
    --radius-sm:  18px;
    --max-width: 1200px;
}

/* ── Dark theme override ────────────────────── */
[data-theme="dark"] {
    --bg:           #060F09;
    --bg-deep:      #0C1810;
    --surface:      rgba(12, 24, 16, 0.95);
    --surface-strong: #111F16;

    --ink:          #E8F5EE;
    --ink-soft:     #9DB8AA;
    --line:         rgba(45, 201, 138, 0.14);

    --brand-soft:   rgba(45, 201, 138, 0.12);
    --brand-border: rgba(45, 201, 138, 0.28);
    --accent:       #47D9A0;
    --accent-soft:  rgba(45, 201, 138, 0.12);

    --shadow:       0 24px 60px rgba(0, 0, 0, 0.55);
    --shadow-soft:  0 8px 28px rgba(0, 0, 0, 0.38);
    --glow:         0 0 40px rgba(45, 201, 138, 0.28);
}

/* ── Reset / base ───────────────────────────── */
html {
    scroll-behavior: smooth;
    scroll-padding-top: 6rem;
}
*, *::before, *::after { box-sizing: border-box; }

body {
    margin: 0;
    min-height: 100vh;
    font-family: "Manrope", "Segoe UI", sans-serif;
    color: var(--ink);
    background-color: var(--bg);
    background-image:
        radial-gradient(ellipse 70% 40% at 10% 0%, rgba(45, 201, 138, 0.16) 0%, transparent 60%),
        radial-gradient(ellipse 50% 30% at 90% 8%, rgba(0, 200, 120, 0.11) 0%, transparent 55%),
        linear-gradient(180deg, var(--bg) 0%, #f7fdf9 50%, #eef8f3 100%);
    transition: background-color 0.35s ease, color 0.35s ease;
    -webkit-font-smoothing: antialiased;
}

body[data-lang="ar"] {
    font-family: "Noto Sans Arabic", "Noto Naskh Arabic", "Cairo", "Segoe UI", sans-serif;
}

[data-theme="dark"] body {
    background-image:
        radial-gradient(ellipse 70% 40% at 10% 0%, rgba(45, 201, 138, 0.07) 0%, transparent 60%),
        radial-gradient(ellipse 50% 30% at 90% 8%, rgba(0, 200, 120, 0.05) 0%, transparent 55%);
}

img   { display: block; max-width: 100%; }
a     { color: inherit; }
p, li { color: var(--ink-soft); }

.container {
    width: min(var(--max-width), calc(100% - 2rem));
    margin: 0 auto;
}

/* ── Header ─────────────────────────────────── */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(20px) saturate(1.5);
    -webkit-backdrop-filter: blur(20px) saturate(1.5);
    background: rgba(240, 251, 246, 0.9);
    border-bottom: 1px solid var(--line);
    transition: background 0.35s ease, border-color 0.35s ease;
}
[data-theme="dark"] .site-header {
    background: rgba(6, 15, 9, 0.9);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.85rem 0;
}
.header-controls {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    flex-wrap: wrap;
    justify-content: flex-end;
}

/* Brand */
.brand {
    display: inline-flex;
    align-items: center;
    gap: 0.85rem;
    text-decoration: none;
}
.brand img {
    width: 46px;
    height: 46px;
    border-radius: 14px;
    object-fit: cover;
    box-shadow: 0 8px 24px rgba(45, 201, 138, 0.3), 0 0 0 2px rgba(45, 201, 138, 0.12);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.brand:hover img {
    transform: scale(1.06);
    box-shadow: 0 12px 32px rgba(45, 201, 138, 0.42), 0 0 0 3px rgba(45, 201, 138, 0.2);
}
.brand-copy          { display: grid; gap: 0.05rem; }
.brand-copy strong   { font-size: 1.05rem; font-weight: 800; letter-spacing: -0.03em; color: var(--ink); }
.brand-copy span     { font-size: 0.8rem; color: var(--ink-soft); }

/* Nav */
.site-nav {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    row-gap: 0.4rem;
}
.site-nav a {
    text-decoration: none;
    color: var(--ink-soft);
    font-size: 0.88rem;
    font-weight: 700;
    padding: 0.4rem 0.65rem;
    border-radius: 8px;
    white-space: nowrap;
    transition: color 0.2s, background 0.2s;
}
.site-nav a:hover,
.site-nav a:focus-visible {
    color: var(--accent);
    background: var(--accent-soft);
}
.nav-cta {
    padding: 0.65rem 1.1rem !important;
    border-radius: 999px !important;
    background: linear-gradient(135deg, var(--brand), var(--brand-deep)) !important;
    color: var(--white) !important;
    box-shadow: 0 4px 16px rgba(45, 201, 138, 0.38) !important;
}
.nav-cta:hover {
    background: linear-gradient(135deg, var(--brand-vivid), var(--brand)) !important;
    transform: translateY(-1px);
    box-shadow: 0 8px 24px rgba(45, 201, 138, 0.48) !important;
}

/* Lang switcher */
.lang-switcher {
    display: inline-flex;
    align-items: center;
    gap: 0.2rem;
    padding: 0.28rem;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: var(--surface);
    box-shadow: var(--shadow-soft);
}
.lang-button {
    border: 0;
    padding: 0.52rem 0.85rem;
    border-radius: 999px;
    background: transparent;
    color: var(--ink-soft);
    font: inherit;
    font-size: 0.8rem;
    font-weight: 800;
    letter-spacing: 0.05em;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
}
.lang-button:hover  { color: var(--accent); }
.lang-button.is-active {
    background: linear-gradient(135deg, var(--brand), var(--brand-deep));
    color: var(--white);
    box-shadow: 0 4px 14px rgba(45, 201, 138, 0.38);
}

/* Theme toggle */
.theme-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: var(--surface);
    color: var(--ink-soft);
    cursor: pointer;
    font-size: 1rem;
    line-height: 1;
    box-shadow: var(--shadow-soft);
    transition: border-color 0.2s, box-shadow 0.2s;
    flex-shrink: 0;
}
.theme-toggle:hover {
    border-color: var(--brand-border);
    box-shadow: var(--glow);
}
/* show moon in light, sun in dark */
.theme-toggle .icon-dark  { display: inline; }
.theme-toggle .icon-light { display: none; }
[data-theme="dark"] .theme-toggle .icon-dark  { display: none; }
[data-theme="dark"] .theme-toggle .icon-light { display: inline; }

/* ── Eyebrow ─────────────────────────────────── */
.section { padding: 5.5rem 0; }

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.45rem 0.9rem;
    border-radius: 999px;
    background: rgba(45, 201, 138, 0.12);
    color: var(--accent);
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.09em;
    text-transform: uppercase;
    border: 1px solid rgba(45, 201, 138, 0.2);
}

/* ── Hero ────────────────────────────────────── */
.hero {
    padding: 4.5rem 0 6rem;
    position: relative;
    overflow: visible; /* phones can bleed right */
}
.hero::after {
    content: "";
    position: absolute;
    top: -10%;
    right: -5%;
    width: 55%;
    height: 110%;
    background: radial-gradient(ellipse, rgba(45, 201, 138, 0.07) 0%, transparent 68%);
    pointer-events: none;
    z-index: 0;
}

.hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr);
    gap: 2rem;
    align-items: center;
}

/* Headings */
.hero-copy h1,
.page-hero h1,
.section-heading h2,
.cta-card h2,
.policy-section h2 {
    margin: 1rem 0 1.1rem;
    line-height: 0.97;
    letter-spacing: -0.06em;
}
.hero-copy h1 {
    font-size: clamp(3rem, 7vw, 5.6rem);
    max-width: 12ch;
    color: var(--ink);
}
/* Gradient text accent */
.hero-copy h1 span,
.section-heading h2 span,
.cta-card h2 span,
.page-hero h1 span {
    background: linear-gradient(90deg, var(--brand-vivid) 0%, var(--brand) 55%, var(--brand-deep) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-lead,
.section-heading p,
.page-hero p,
.cta-card > p {
    margin: 0;
    font-size: 1.08rem;
    line-height: 1.8;
    max-width: 60ch;
}

/* Quranic verse — visible only in Arabic */
.hero-verse { display: none; margin: 1.4rem 0 0; }
html[dir="rtl"] .hero-verse { display: block; }
.arabic-only { display: none; }
html[dir="rtl"] .arabic-only { display: block; }
.hero-verse blockquote {
    margin: 0;
    padding: 1rem 1.4rem;
    border-radius: 16px;
    border-right: 3px solid var(--brand);
    background: rgba(45, 201, 138, 0.09);
    border-left: 1px solid rgba(45, 201, 138, 0.18);
    color: var(--accent);
    font-size: 1.02rem;
    font-weight: 600;
    line-height: 2;
    text-align: right;
}
html[dir="rtl"] .hero-verse blockquote {
    border-right: 3px solid var(--brand);
    border-left: 1px solid rgba(45, 201, 138, 0.18);
}

/* ── Buttons ─────────────────────────────────── */
.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.85rem;
    margin: 2rem 0;
}
.hero-actions--center { justify-content: center; }

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    padding: 1rem 1.5rem;
    border-radius: 999px;
    font-weight: 800;
    font-size: 0.95rem;
    text-decoration: none;
    white-space: nowrap;
    transition: transform 0.22s ease, box-shadow 0.22s ease, background 0.22s ease;
}
.button:hover,
.button:focus-visible { transform: translateY(-2px); }

.button-primary {
    background: linear-gradient(135deg, var(--brand-vivid), var(--brand-deep));
    color: var(--white);
    box-shadow: 0 8px 30px rgba(45, 201, 138, 0.38);
}
.button-primary:hover { box-shadow: 0 14px 44px rgba(45, 201, 138, 0.5); }

.button-secondary {
    background: var(--surface);
    color: var(--ink);
    border: 1.5px solid rgba(45, 201, 138, 0.22);
    box-shadow: var(--shadow-soft);
}
.button-secondary:hover {
    border-color: rgba(45, 201, 138, 0.45);
    box-shadow: 0 8px 28px rgba(45, 201, 138, 0.18);
}

.button-playstore {
    background: linear-gradient(135deg, var(--brand), var(--brand-deep));
    color: var(--white);
    font-size: 1rem;
    font-weight: 800;
    padding: 1.05rem 2rem;
    box-shadow: 0 8px 32px rgba(45, 201, 138, 0.42);
}
.button-playstore:hover {
    background: linear-gradient(135deg, var(--brand-vivid), var(--brand));
    box-shadow: 0 14px 48px rgba(45, 201, 138, 0.55);
}

/* ── Hero list ───────────────────────────────── */
.hero-list,
.privacy-points {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.7rem;
    margin: 0;
    padding: 0;
    list-style: none;
}
.hero-list li,
.privacy-points li {
    display: flex;
    align-items: flex-start;
    gap: 0.55rem;
    padding: 0.9rem 1rem;
    border-radius: 18px;
    border: 1px solid rgba(45, 201, 138, 0.16);
    background: var(--surface);
    box-shadow: var(--shadow-soft);
    color: var(--ink);
    font-size: 0.88rem;
    font-weight: 700;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.hero-list li:hover,
.privacy-points li:hover {
    border-color: rgba(45, 201, 138, 0.38);
    box-shadow: 0 4px 20px rgba(45, 201, 138, 0.14);
}
.hero-list li::before,
.privacy-points li::before {
    content: "✓";
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 19px;
    height: 19px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--brand), var(--brand-deep));
    color: white;
    font-size: 0.62rem;
    font-weight: 900;
    margin-top: 0.06rem;
}

/* ── Hero media — two overlapping phones ─────── */
.hero-media {
    display: flex;
    flex-direction: column;
    align-items: flex-end; /* push phones toward right edge */
    gap: 1.2rem;
    padding: 1rem 0;
    position: relative;
    z-index: 1;
}

/* 4 phones fanned out with negative-margin overlap */
.mockup-phones {
    display: flex;
    align-items: flex-start;
    justify-content: flex-end;
}

.mockup-phone {
    width: 155px;
    flex-shrink: 0;
    border-radius: 26px;
    overflow: hidden;
    background: var(--surface-strong);
    border: 1px solid rgba(45, 201, 138, 0.18);
    position: relative;
}
/* each successive phone overlaps the previous one */
.mockup-phone + .mockup-phone { margin-left: -28px; }

.mockup-phone img {
    width: 100%;
    height: 330px;
    object-fit: cover;
    object-position: top;
    display: block;
}

/* Phone 1 — create habit — far left, tilted most */
.mockup-phone--p1 {
    transform: rotate(-8deg) translateY(32px);
    z-index: 1;
    opacity: 0.78;
    box-shadow: 0 12px 36px rgba(13, 34, 24, 0.13);
    animation: pfloat1 7.5s ease-in-out infinite;
}
/* Phone 2 — today — slight tilt, main focus */
.mockup-phone--p2 {
    transform: rotate(-2deg) translateY(10px);
    z-index: 4;
    box-shadow: 0 24px 60px rgba(13, 34, 24, 0.24), var(--glow);
    animation: pfloat2 6s ease-in-out infinite;
}
/* Phone 3 — habit detail — tilted right */
.mockup-phone--p3 {
    transform: rotate(4deg) translateY(20px);
    z-index: 3;
    opacity: 0.88;
    box-shadow: 0 16px 44px rgba(13, 34, 24, 0.16);
    animation: pfloat3 7s ease-in-out infinite 0.6s;
}
/* Phone 4 — stats — tilted most right */
.mockup-phone--p4 {
    transform: rotate(9deg) translateY(40px);
    z-index: 2;
    opacity: 0.72;
    box-shadow: 0 10px 32px rgba(13, 34, 24, 0.11);
    animation: pfloat4 8s ease-in-out infinite 1.2s;
}

@keyframes pfloat1 {
    0%,100% { transform: rotate(-8deg) translateY(32px); }
    50%      { transform: rotate(-8deg) translateY(22px); }
}
@keyframes pfloat2 {
    0%,100% { transform: rotate(-2deg) translateY(10px); }
    50%      { transform: rotate(-2deg) translateY(0px); }
}
@keyframes pfloat3 {
    0%,100% { transform: rotate(4deg) translateY(20px); }
    50%      { transform: rotate(4deg) translateY(10px); }
}
@keyframes pfloat4 {
    0%,100% { transform: rotate(9deg) translateY(40px); }
    50%      { transform: rotate(9deg) translateY(30px); }
}

/* Stat chips — simple pill row below phones */
.hero-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
    justify-content: flex-end;
}
.hero-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.5rem 0.9rem;
    border-radius: 999px;
    background: var(--surface-strong);
    border: 1px solid rgba(45, 201, 138, 0.22);
    box-shadow: var(--shadow-soft);
    white-space: nowrap;
}
.hero-chip-icon { font-size: 0.95rem; line-height: 1; }
.hero-chip-label {
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--ink-soft);
}
.hero-chip-value {
    font-size: 0.78rem;
    font-weight: 800;
    color: var(--ink);
}
.hero-chip-value.green {
    background: linear-gradient(90deg, var(--brand-vivid), var(--brand-deep));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ── Section heading ─────────────────────────── */
.section-heading {
    max-width: 780px;
    margin-bottom: 2.5rem;
}
.section-heading h2,
.page-hero h1 {
    font-size: clamp(2.2rem, 5vw, 4.2rem);
}

/* ── Feature grid ────────────────────────────── */
.feature-grid,
.summary-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.1rem;
}
.feature-card,
.summary-card,
.metric,
.policy-section,
.screenshot-card,
.note-box {
    border: 1px solid var(--line);
    background: var(--surface-strong);
    box-shadow: var(--shadow-soft);
}
.feature-card,
.summary-card,
.metric,
.screenshot-card,
.note-box {
    padding: 1.5rem;
    border-radius: 24px;
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.feature-card:hover,
.summary-card:hover {
    transform: translateY(-4px);
    border-color: rgba(45, 201, 138, 0.3);
    box-shadow: var(--shadow), var(--glow);
}
.feature-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    border-radius: 16px;
    margin-bottom: 1rem;
    font-size: 1.4rem;
    background: linear-gradient(135deg, var(--brand-soft), #f0fff8);
    border: 1px solid rgba(45, 201, 138, 0.2);
}
.feature-card h3,
.summary-card h3 {
    margin: 0 0 0.5rem;
    color: var(--ink);
    font-size: 1.02rem;
    font-weight: 800;
    letter-spacing: -0.03em;
}
.feature-card p,
.summary-card p { margin: 0; font-size: 0.92rem; line-height: 1.72; }

/* ── Split layout ────────────────────────────── */
.split-layout {
    display: grid;
    grid-template-columns: minmax(280px, 0.9fr) minmax(0, 1.1fr);
    gap: 1.5rem;
    align-items: start;
}
.story-panel {
    position: sticky;
    top: 5.5rem;
    padding: 2.2rem;
    border-radius: var(--radius-lg);
    background: linear-gradient(150deg, #0D6B45 0%, #1AAF72 60%, #2DC98A 100%);
    box-shadow: 0 28px 60px rgba(13, 107, 69, 0.28), 0 0 0 1px rgba(45, 201, 138, 0.18);
}
.story-panel .eyebrow {
    background: rgba(255, 255, 255, 0.14);
    color: rgba(255, 255, 255, 0.95);
    border-color: rgba(255, 255, 255, 0.18);
}
.story-panel h2 {
    margin: 1rem 0;
    color: var(--white);
    font-size: clamp(2rem, 3.8vw, 3.2rem);
    line-height: 1.02;
    letter-spacing: -0.05em;
}
.story-panel p       { color: rgba(255, 255, 255, 0.8); }
.story-panel strong  { color: var(--white); }

/* ── Category chips ──────────────────────────── */
.category-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin-bottom: 1.5rem;
}
.category-chip {
    display: inline-flex;
    padding: 0.62rem 1rem;
    border-radius: 999px;
    background: rgba(45, 201, 138, 0.1);
    color: var(--accent);
    font-size: 0.86rem;
    font-weight: 800;
    border: 1px solid rgba(45, 201, 138, 0.2);
    transition: background 0.2s, border-color 0.2s, transform 0.15s;
    cursor: default;
}
.category-chip:hover {
    background: rgba(45, 201, 138, 0.18);
    border-color: rgba(45, 201, 138, 0.42);
    transform: scale(1.04);
}

/* ── Metrics ─────────────────────────────────── */
.metrics-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1rem;
    margin-top: 1.2rem;
}
.metric {
    text-align: center;
    border-radius: 22px;
    padding: 1.5rem 1rem;
    transition: transform 0.25s, box-shadow 0.25s;
}
.metric:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow), var(--glow);
}
.metric strong {
    display: block;
    margin-bottom: 0.3rem;
    background: linear-gradient(90deg, var(--brand-vivid), var(--brand-deep));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-size: 2.2rem;
    font-weight: 800;
    letter-spacing: -0.06em;
    line-height: 1;
}
.metric p { margin: 0; font-size: 0.84rem; }

/* ── Today & Routini — screens duo ──────────── */
.screens-duo {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.5rem;
    margin-top: 2.5rem;
}
.screens-duo-card {
    border-radius: 28px;
    overflow: hidden;
    background: var(--surface-strong);
    border: 1px solid rgba(45, 201, 138, 0.15);
    box-shadow: var(--shadow);
    transition: transform 0.28s ease, box-shadow 0.28s ease, border-color 0.28s ease;
}
.screens-duo-card:hover {
    transform: translateY(-6px);
    border-color: rgba(45, 201, 138, 0.35);
    box-shadow: var(--shadow), var(--glow);
}
.screens-duo-visual {
    background: linear-gradient(160deg, var(--bg-deep) 0%, #c6ecdb 100%);
    overflow: hidden;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding: 2rem 1rem 0;
    min-height: 300px;
}
.duo-phones {
    display: flex;
    align-items: flex-end;
    justify-content: center;
}
.duo-phone {
    width: 130px;
    height: 260px;
    object-fit: cover;
    object-position: top;
    border-radius: 18px 18px 0 0;
    display: block;
    flex-shrink: 0;
}
.duo-phone--l {
    transform: rotate(-8deg) translateY(18px);
    margin-right: -28px;
    z-index: 1;
    opacity: 0.75;
    box-shadow: -6px -4px 28px rgba(13, 34, 24, 0.14);
}
.duo-phone--c {
    z-index: 3;
    box-shadow: 0 -6px 36px rgba(13, 34, 24, 0.18), 0 0 0 1px rgba(45,201,138,0.18);
    transform: translateY(0);
}
.duo-phone--r {
    transform: rotate(8deg) translateY(18px);
    margin-left: -28px;
    z-index: 2;
    opacity: 0.75;
    box-shadow: 6px -4px 28px rgba(13, 34, 24, 0.14);
}
.screens-duo-copy {
    padding: 1.4rem 1.6rem 1.8rem;
}
.screens-duo-tag {
    display: inline-block;
    padding: 0.3rem 0.75rem;
    border-radius: 999px;
    background: rgba(45, 201, 138, 0.12);
    color: var(--accent);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    border: 1px solid rgba(45, 201, 138, 0.22);
    margin-bottom: 0.65rem;
}
.screens-duo-copy h3 {
    margin: 0 0 0.5rem;
    color: var(--ink);
    font-size: 1.15rem;
    font-weight: 800;
    letter-spacing: -0.03em;
    line-height: 1.2;
}
.screens-duo-copy p {
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.72;
}

/* ── Screenshot grids ────────────────────────── */
.routine-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.1rem;
}
.screenshot-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.1rem;
}
.screenshot-grid > :last-child:nth-child(3n + 1) { grid-column: 2; }

.screenshot-card {
    border-radius: 24px;
    transition: transform 0.25s, box-shadow 0.25s, border-color 0.25s;
}
.screenshot-card:hover {
    transform: translateY(-4px);
    border-color: rgba(45, 201, 138, 0.3);
    box-shadow: var(--shadow), var(--glow);
}
.screenshot-card img {
    width: 100%;
    height: clamp(340px, 36vw, 620px);
    object-fit: contain;
    object-position: center top;
    border-radius: 20px 20px 0 0;
    background: linear-gradient(180deg, var(--bg-deep) 0%, #c8eedd 100%);
}
.screenshot-copy {
    padding: 1.1rem 1.25rem 1.4rem;
}
.screenshot-copy h3 {
    margin: 0 0 0.35rem;
    color: var(--ink);
    font-size: 0.97rem;
    font-weight: 800;
    letter-spacing: -0.02em;
}
.screenshot-copy p { margin: 0; font-size: 0.88rem; line-height: 1.68; }

/* ── Privacy banner ──────────────────────────── */
.privacy-banner {
    display: grid;
    grid-template-columns: minmax(240px, 0.85fr) minmax(0, 1.15fr);
    gap: 2rem;
    padding: 2.5rem;
    border-radius: var(--radius-lg);
    border: 1px solid rgba(45, 201, 138, 0.18);
    background: linear-gradient(135deg, var(--bg) 0%, var(--bg-deep) 100%);
    box-shadow: var(--shadow);
}
.privacy-banner h2 {
    margin: 0 0 0.8rem;
    font-size: clamp(1.9rem, 3.8vw, 3rem);
    line-height: 1.02;
    letter-spacing: -0.05em;
    color: var(--ink);
}
.privacy-banner p { margin: 0; }

/* ── CTA final ───────────────────────────────── */
.final-cta { padding-bottom: 6rem; }
.cta-card {
    padding: 4rem 3rem;
    text-align: center;
    border-radius: 36px;
    background: linear-gradient(145deg, #0A5C3A, #1AAF72 60%, #2DC98A 100%);
    box-shadow: 0 40px 80px rgba(13, 107, 69, 0.3), 0 0 0 1px rgba(45, 201, 138, 0.18);
    position: relative;
    overflow: hidden;
}
.cta-card::before {
    content: "";
    position: absolute;
    top: -30%;
    left: 50%;
    transform: translateX(-50%);
    width: 80%;
    height: 190%;
    background: radial-gradient(ellipse, rgba(255, 255, 255, 0.06) 0%, transparent 65%);
    pointer-events: none;
}
.cta-card h2          { color: var(--white); position: relative; }
.cta-card h2 span     { -webkit-text-fill-color: rgba(255, 255, 255, 0.92); background: none; color: rgba(255, 255, 255, 0.92); }
.cta-card > p         { color: rgba(255, 255, 255, 0.8); margin: 0 auto; max-width: 56ch; position: relative; }
.cta-card .button-secondary {
    background: rgba(255, 255, 255, 0.12);
    border: 1.5px solid rgba(255, 255, 255, 0.24);
    color: var(--white);
}
.cta-card .button-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.42);
}

/* ── Footer ──────────────────────────────────── */
.footer {
    padding: 1.5rem 0 3rem;
    border-top: 1px solid var(--line);
}
.footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}
.footer-copy  { font-size: 0.88rem; color: var(--ink-soft); }
.footer-links { display: flex; gap: 1rem; flex-wrap: wrap; }
.footer-links a {
    text-decoration: none;
    color: var(--ink-soft);
    font-size: 0.86rem;
    font-weight: 700;
    transition: color 0.2s;
}
.footer-links a:hover,
.footer-links a:focus-visible { color: var(--accent); }

/* ── Legal pages ─────────────────────────────── */
.page-hero { padding: 4rem 0 2rem; }
.page-hero p { max-width: 70ch; }

.summary-grid {
    margin-top: 2rem;
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.language-switch { display: flex; flex-wrap: wrap; gap: 0.65rem; margin-top: 1.5rem; }
.pill-link {
    display: inline-flex;
    align-items: center;
    padding: 0.7rem 1.1rem;
    border-radius: 999px;
    text-decoration: none;
    background: var(--surface-strong);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-soft);
    color: var(--ink);
    font-size: 0.88rem;
    font-weight: 800;
    transition: border-color 0.2s, color 0.2s;
}
.pill-link:hover,
.pill-link:focus-visible {
    border-color: rgba(45, 201, 138, 0.4);
    color: var(--accent);
}

.note-box {
    margin-top: 1.5rem;
    padding: 1rem 1.25rem;
    border-radius: 16px;
    border: 1px solid rgba(45, 201, 138, 0.2);
    background: rgba(45, 201, 138, 0.08);
    color: var(--accent);
    font-size: 0.88rem;
}

.policy-layout { display: grid; gap: 1.5rem; }
.policy-section {
    padding: 2rem;
    border-radius: 28px;
    scroll-margin-top: 6rem;
}
.policy-section h2 {
    margin: 0 0 0.9rem;
    font-size: clamp(1.8rem, 3.5vw, 2.8rem);
    line-height: 1.05;
    letter-spacing: -0.05em;
    color: var(--ink);
}
.policy-section h3 {
    margin: 1.6rem 0 0.55rem;
    color: var(--ink);
    font-size: 1.1rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}
.policy-section h4 {
    margin: 1rem 0 0.4rem;
    color: var(--accent);
    font-size: 0.95rem;
    font-weight: 700;
}
.policy-section p,
.policy-section li,
.policy-section td { margin: 0 0 0.5rem; line-height: 1.78; font-size: 0.92rem; }
.policy-section ul  { margin: 0.6rem 0; padding-left: 1.25rem; }
.policy-section li  { margin: 0.38rem 0; }
.policy-section strong { color: var(--ink); }

.policy-section[dir="rtl"] { text-align: right; }
.policy-section[dir="rtl"] ul { padding-right: 1.25rem; padding-left: 0; }

.summary-table-wrap { overflow-x: auto; margin-top: 1rem; }
.summary-table { width: 100%; min-width: 640px; border-collapse: collapse; }
.summary-table th,
.summary-table td { padding: 0.95rem 1rem; border-bottom: 1px solid var(--line); text-align: left; font-size: 0.9rem; }
.summary-table th { color: var(--ink-soft); font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.07em; font-weight: 700; }
.summary-table td:first-child { color: var(--ink); font-weight: 700; }
.summary-signoff { margin-top: 1.5rem; display: grid; gap: 0.3rem; }

/* ── Screenshot card featured variant ────────── */
.screenshot-card--featured {
    grid-column: span 2;
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 2rem;
}
.screenshot-card--featured img {
    width: 100%;
    max-width: 280px;
    justify-self: center;
}
@media (max-width: 600px) {
    .screenshot-card--featured {
        grid-column: span 1;
        grid-template-columns: 1fr;
    }
}

/* ── Faith / Spiritual section ───────────────── */
.faith-section {
    background: linear-gradient(160deg, #0d1f16 0%, #0f2a1e 40%, #12211a 100%);
    border-radius: 32px;
    margin: 0 1rem;
    overflow: hidden;
    position: relative;
}
.faith-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 80% 60% at 50% -10%, rgba(45,201,138,0.18) 0%, transparent 70%);
    pointer-events: none;
}
.faith-heading {
    position: relative;
}
.faith-moon {
    font-size: 2.8rem;
    margin-bottom: 0.5rem;
    display: block;
    filter: drop-shadow(0 0 18px rgba(45,201,138,0.5));
}
.faith-eyebrow-badge {
    background: rgba(45, 201, 138, 0.18);
    border: 1px solid rgba(45, 201, 138, 0.35);
    color: #2DC98A;
    padding: 0.3rem 1rem;
    border-radius: 999px;
    font-size: 0.72rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    font-weight: 700;
}
.faith-section .section-heading h2,
.faith-section .section-heading p {
    color: rgba(255,255,255,0.92);
}
.faith-section .section-heading h2 span {
    color: #2DC98A;
}
.faith-grid {
    margin-bottom: 3rem;
}
.faith-card {
    background: rgba(255,255,255,0.06);
    border-color: rgba(45,201,138,0.2);
    color: rgba(255,255,255,0.9);
}
.faith-card h3 {
    color: #fff;
}
.faith-card p {
    color: rgba(255,255,255,0.72);
}
.faith-card .feature-icon {
    filter: drop-shadow(0 0 12px rgba(45,201,138,0.4));
}

/* ── Faith phone showcase ────────────────────── */
.faith-phones {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: 0;
    padding-top: 1rem;
    padding-bottom: 0;
    overflow: hidden;
}
.faith-phone {
    flex-shrink: 0;
    position: relative;
}
.faith-phone img {
    display: block;
    border-radius: 24px 24px 0 0;
    object-fit: cover;
    object-position: top;
    box-shadow: 0 -8px 40px rgba(0,0,0,0.5);
}
.faith-phone--center img {
    width: 200px;
    height: 380px;
    border: 2px solid rgba(45,201,138,0.4);
    box-shadow: 0 -12px 60px rgba(45,201,138,0.25), 0 -8px 40px rgba(0,0,0,0.6);
    z-index: 3;
    position: relative;
}
.faith-phone--side {
    opacity: 0.65;
    z-index: 1;
}
.faith-phone--side:first-child {
    transform: rotate(-6deg) translateY(28px);
    margin-right: -32px;
}
.faith-phone--side:last-child {
    transform: rotate(6deg) translateY(28px);
    margin-left: -32px;
}
.faith-phone--side img {
    width: 158px;
    height: 300px;
}
@media (max-width: 600px) {
    .faith-phones { gap: 0; }
    .faith-phone--center img { width: 160px; height: 300px; }
    .faith-phone--side img { width: 120px; height: 230px; }
    .faith-phone--side:first-child { margin-right: -24px; }
    .faith-phone--side:last-child { margin-left: -24px; }
    .faith-section { margin: 0 0.5rem; }
}

/* ── Faith screenshot detail grid ────────────── */
.faith-shot-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.2rem;
    margin-top: 3.5rem;
}
.faith-shot-card {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(45,201,138,0.18);
    border-radius: 20px;
    overflow: hidden;
    transition: transform 0.25s ease, border-color 0.25s ease;
}
.faith-shot-card:hover {
    transform: translateY(-4px);
    border-color: rgba(45,201,138,0.4);
}
.faith-shot-card img {
    width: 100%;
    aspect-ratio: 9/16;
    object-fit: cover;
    object-position: top;
    display: block;
}
.faith-shot-copy {
    padding: 1rem 1.1rem 1.2rem;
}
.faith-shot-copy h4 {
    margin: 0 0 0.35rem;
    color: #fff;
    font-size: 0.92rem;
    font-weight: 800;
    line-height: 1.3;
}
.faith-shot-copy p {
    margin: 0;
    font-size: 0.8rem;
    color: rgba(255,255,255,0.62);
    line-height: 1.65;
}
@media (max-width: 760px) {
    .faith-shot-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
    .faith-shot-grid { grid-template-columns: 1fr; }
}

/* ── 404 ─────────────────────────────────────── */
.error-shell { padding: 5rem 0 7rem; text-align: center; }
.error-code {
    display: block;
    margin-bottom: 0.8rem;
    font-size: clamp(5rem, 18vw, 10rem);
    font-weight: 800;
    line-height: 0.9;
    letter-spacing: -0.08em;
    background: linear-gradient(135deg, var(--brand-vivid), var(--brand-deep));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.error-shell p { max-width: 58ch; margin: 0 auto 2rem; }
.error-actions { justify-content: center; }

/* ── RTL / Arabic ────────────────────────────── */
html[dir="rtl"] body { text-align: right; }
html[dir="rtl"] .brand { flex-direction: row-reverse; }
html[dir="rtl"] .site-nav,
html[dir="rtl"] .header-controls,
html[dir="rtl"] .hero-actions,
html[dir="rtl"] .footer-links,
html[dir="rtl"] .category-cloud,
html[dir="rtl"] .language-switch { direction: rtl; }
html[dir="rtl"] .screens-duo { direction: rtl; }
html[dir="rtl"] .summary-table th,
html[dir="rtl"] .summary-table td { text-align: right; }
html[dir="rtl"] .policy-section ul { padding-right: 1.25rem; padding-left: 0; }

/* ── Responsive ──────────────────────────────── */
@media (max-width: 1100px) {
    .hero-grid,
    .split-layout,
    .privacy-banner { grid-template-columns: 1fr; }
    .mockup-phone { width: 130px; }
    .mockup-phone img { height: 270px; }
    .hero-media { align-items: center; }
    .hero-chips { justify-content: center; }
    .story-panel { position: static; }
    .screens-duo { grid-template-columns: 1fr; }
    .feature-grid,
    .summary-grid,
    .screenshot-grid,
    .routine-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .screenshot-grid > :last-child:nth-child(odd) {
        grid-column: 1 / -1;
        width: min(100%, 460px);
        justify-self: center;
    }
}

@media (max-width: 760px) {
    .container { width: min(var(--max-width), calc(100% - 1.25rem)); }
    .header-inner, .footer-inner { flex-direction: column; align-items: flex-start; }
    .header-controls { width: 100%; }
    .site-nav {
        width: 100%;
        overflow-x: auto;
        flex-wrap: nowrap;
        padding-bottom: 0.25rem;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }
    .site-nav::-webkit-scrollbar { display: none; }
    .lang-switcher { align-self: flex-start; }
    .hero { padding: 2.5rem 0 4.5rem; }
    .hero-list, .privacy-points, .feature-grid, .summary-grid,
    .metrics-grid, .screenshot-grid, .routine-grid { grid-template-columns: 1fr; }
    .mockup-phone { width: 100px; }
    .mockup-phone + .mockup-phone { margin-left: -18px; }
    .mockup-phone img { height: 200px; }
    .mockup-phone--p3, .mockup-phone--p4 { display: none; }
    .screens-duo { grid-template-columns: 1fr; }
    .screens-duo-visual { min-height: 240px; }
    .duo-phone { width: 110px; height: 210px; }
    .duo-phone--l { margin-right: -22px; }
    .duo-phone--r { margin-left: -22px; }
    .screenshot-grid > :last-child:nth-child(odd) { grid-column: auto; width: 100%; justify-self: stretch; }
    .hero-copy h1 { max-width: none; font-size: clamp(2.6rem, 12vw, 4rem); }
    .hero-actions .button { width: 100%; justify-content: center; }
    .screen-card--today, .screen-card--stats { transform: none; animation: none; }
    .screen-card--routine, .screen-card--create { animation: none; }
    .cta-card, .privacy-banner, .policy-section { padding: 1.75rem 1.25rem; }
    html[dir="rtl"] .brand { flex-direction: row; }
}

@media (max-width: 520px) {
    .section, .final-cta { padding: 3.5rem 0; }
    .hero { padding-top: 2rem; }
    .brand img { width: 40px; height: 40px; }
    .site-nav a, .lang-button { font-size: 0.86rem; }
    .cta-card { border-radius: 26px; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation: none !important; transition: none !important; }
}
