/* Beauty AI World — bright "beautiful AI world" theme with a dark variant. */
:root {
  --bg: #fbf9ff;
  --bg-soft: #f3efff;
  --card: #ffffff;
  --ink: #1d1b2e;
  --ink-soft: #5d5a75;
  --line: #e7e2f6;
  --brand-1: #ff8fb8;   /* blossom pink */
  --brand-2: #8b7cff;   /* lilac */
  --brand-3: #3cc8e8;   /* sky */
  --brand-4: #5fe0b0;   /* mint */
  --grad: linear-gradient(120deg, var(--brand-1), var(--brand-2) 45%, var(--brand-3));
  --shadow: 0 18px 50px -20px rgba(80, 60, 160, .28);
  --radius: 22px;
  --max: 1160px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f0e1a;
    --bg-soft: #17152a;
    --card: #1b1930;
    --ink: #f1eefe;
    --ink-soft: #b3aed0;
    --line: #2c2948;
    --shadow: 0 18px 50px -20px rgba(0, 0, 0, .6);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans Arabic", "Noto Sans Devanagari", sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 20px; }
.grad-text { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* Aurora backdrop. The soft edge comes from the gradient itself (no filter: blur), and the
   drift only animates transform on its own layer, so the GPU moves it without repainting. */
.aurora { position: fixed; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; }
.aurora span { position: absolute; border-radius: 50%; opacity: .45; background: radial-gradient(closest-side, var(--c) 30%, transparent); will-change: transform; animation: drift 22s ease-in-out infinite alternate; }
.aurora span:nth-child(1) { --c: var(--brand-1); width: 760px; height: 760px; top: -280px; left: -240px; }
.aurora span:nth-child(2) { --c: var(--brand-2); width: 840px; height: 840px; top: calc(10% - 120px); right: -340px; animation-delay: -6s; }
.aurora span:nth-child(3) { --c: var(--brand-3); width: 700px; height: 700px; bottom: -320px; left: calc(20% - 120px); animation-delay: -12s; opacity: .3; }
@media (prefers-color-scheme: dark) { .aurora span { opacity: .22; } }
@keyframes drift { to { transform: translate3d(40px, 60px, 0) scale(1.08); } }
@media (prefers-reduced-motion: reduce) { .aurora span { animation: none; } html { scroll-behavior: auto; } }

/* Header */
/* Near-opaque instead of backdrop-filter: blurring what scrolls behind it costs a repaint every frame. */
.site-header { position: sticky; top: 0; z-index: 50; background: color-mix(in srgb, var(--bg) 94%, transparent); border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; align-items: center; gap: 16px; height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 800; letter-spacing: -.01em; font-size: 18px; white-space: nowrap; }
.brand img { width: 34px; height: 34px; }
.nav-links { display: flex; gap: 6px; margin-inline-start: auto; }
.nav-links a { text-decoration: none; color: var(--ink-soft); font-weight: 600; font-size: 15px; padding: 8px 12px; border-radius: 999px; }
.nav-links a:hover { color: var(--ink); background: var(--bg-soft); }
.lang-wrap { position: relative; display: flex; align-items: center; }
.lang-wrap svg { position: absolute; inset-inline-start: 10px; width: 16px; height: 16px; color: var(--ink-soft); pointer-events: none; }
.lang-select { appearance: none; -webkit-appearance: none; font: inherit; font-size: 14px; font-weight: 600; color: var(--ink); background: var(--card); border: 1px solid var(--line); border-radius: 999px; padding-block: 7px; padding-inline: 32px 14px; cursor: pointer; }
.menu-toggle { display: none; background: none; border: 0; color: var(--ink); padding: 8px; cursor: pointer; }
.menu-toggle svg { width: 24px; height: 24px; }

/* Buttons & chips */
.btn { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; font-weight: 700; font-size: 16px; padding: 14px 24px; border-radius: 999px; transition: transform .15s ease, box-shadow .15s ease; }
.btn:active { transform: scale(.98); }
.btn-primary { background: var(--grad); color: #fff; box-shadow: 0 12px 30px -10px rgba(139, 124, 255, .7); }
.btn-primary:hover { box-shadow: 0 16px 36px -10px rgba(139, 124, 255, .85); }
.btn-ghost { background: var(--card); color: var(--ink); border: 1px solid var(--line); }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px; background: var(--card); border: 1px solid var(--line); font-size: 13px; font-weight: 600; color: var(--ink-soft); }
.chip i { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.eyebrow { display: inline-block; font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--brand-2); }

/* Hero */
.hero { padding: 72px 0 40px; }
.hero .wrap { display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; }
.hero h1 { font-size: clamp(40px, 6vw, 68px); line-height: 1.05; letter-spacing: -.03em; margin: 14px 0 18px; font-weight: 800; }
.hero h1 .grad-text { display: block; }
.hero p.lead { font-size: 19px; color: var(--ink-soft); max-width: 560px; margin: 0 0 28px; }
.hero .actions { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 26px; }
.hero .chips { display: flex; flex-wrap: wrap; gap: 8px; }
.hero-visual { position: relative; display: flex; justify-content: center; min-height: 520px; }
.hero-visual .phone { position: absolute; }
.hero-visual .phone.back { transform: translate(-46%, 8%) rotate(-9deg) scale(.86); opacity: .95; }
.hero-visual .phone.front { transform: translate(18%, -2%) rotate(5deg); }
.orbit { position: absolute; inset: 6% 4%; border-radius: 50%; border: 1.5px dashed color-mix(in srgb, var(--brand-2) 45%, transparent); animation: spin 60s linear infinite; }
.orbit::after { content: ""; position: absolute; top: 12%; left: 8%; width: 14px; height: 14px; border-radius: 50%; background: var(--brand-4); box-shadow: 0 0 18px var(--brand-4); }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .orbit { animation: none; } }

/* Phone frame */
.phone { width: 250px; aspect-ratio: 9 / 20; border-radius: 36px; padding: 9px; background: #14131f; box-shadow: var(--shadow), inset 0 0 0 1.5px rgba(255,255,255,.08); }
.phone img { width: 100%; height: 100%; object-fit: cover; border-radius: 28px; }

/* Sections */
section { padding: 84px 0; }
.section-head { max-width: 720px; margin-bottom: 40px; }
.section-head.center { text-align: center; margin-left: auto; margin-right: auto; }
.section-head h2 { font-size: clamp(30px, 4vw, 44px); line-height: 1.15; letter-spacing: -.02em; margin: 10px 0 14px; }
.section-head p { color: var(--ink-soft); font-size: 18px; margin: 0; }

.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow); }
.card .icon { width: 52px; height: 52px; border-radius: 16px; display: grid; place-items: center; margin-bottom: 18px; color: #fff; }
.card .icon svg { width: 26px; height: 26px; }
.card h3 { margin: 0 0 8px; font-size: 20px; }
.card p { margin: 0; color: var(--ink-soft); }
.i-pink { background: linear-gradient(135deg, #ff8fb8, #ff6f9e); }
.i-lilac { background: linear-gradient(135deg, #a597ff, #7a6af5); }
.i-sky { background: linear-gradient(135deg, #5fd8f2, #2fb2d6); }

/* App feature */
.app-feature { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; background: var(--card); border: 1px solid var(--line); border-radius: 30px; padding: 40px; box-shadow: var(--shadow); position: relative; overflow: hidden; }
.app-feature::before { content: ""; position: absolute; width: 420px; height: 420px; right: -140px; top: -160px; border-radius: 50%; background: radial-gradient(circle, color-mix(in srgb, var(--brand-3) 30%, transparent), transparent 70%); pointer-events: none; }
.app-title { display: flex; align-items: center; gap: 16px; margin-bottom: 14px; }
.app-title img { width: 72px; height: 72px; border-radius: 20px; box-shadow: 0 10px 26px -8px rgba(128, 131, 255, .7); }
.app-title h3 { margin: 0; font-size: 30px; letter-spacing: -.02em; }
.app-title p { margin: 2px 0 0; color: var(--ink-soft); font-weight: 600; }
.app-desc { color: var(--ink-soft); font-size: 17px; margin: 0 0 18px; }
.features { list-style: none; padding: 0; margin: 0 0 26px; display: grid; grid-template-columns: 1fr 1fr; gap: 10px 18px; }
.features li { display: flex; gap: 10px; align-items: flex-start; font-weight: 600; font-size: 15px; }
.features li svg { flex: 0 0 20px; width: 20px; height: 20px; color: var(--brand-4); margin-top: 2px; }
.store-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.store-badge { display: inline-flex; align-items: center; gap: 10px; background: #111; color: #fff; border-radius: 14px; padding: 10px 18px; font-weight: 700; text-decoration: none; }
.store-badge svg { width: 24px; height: 24px; }
.store-badge small { display: block; font-size: 11px; font-weight: 500; opacity: .75; line-height: 1.1; }
.text-link { font-weight: 700; color: var(--brand-2); text-decoration: none; }
.text-link:hover { text-decoration: underline; }

.gallery { display: flex; gap: 18px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 8px 4px 18px; -webkit-overflow-scrolling: touch; }
.gallery figure { margin: 0; flex: 0 0 auto; scroll-snap-align: center; text-align: center; }
.gallery .phone { width: 200px; }
.gallery figcaption { margin-top: 10px; font-size: 14px; font-weight: 700; color: var(--ink-soft); }

.next-app { margin-top: 20px; display: flex; align-items: center; gap: 20px; padding: 26px 30px; border-radius: var(--radius); border: 2px dashed var(--line); background: color-mix(in srgb, var(--card) 60%, transparent); }
.next-app .dots { display: flex; gap: 6px; }
.next-app .dots i { width: 12px; height: 12px; border-radius: 50%; animation: pulse 1.6s ease-in-out infinite; }
.next-app .dots i:nth-child(1) { background: var(--brand-1); }
.next-app .dots i:nth-child(2) { background: var(--brand-2); animation-delay: .2s; }
.next-app .dots i:nth-child(3) { background: var(--brand-3); animation-delay: .4s; }
@keyframes pulse { 50% { transform: scale(.6); opacity: .5; } }
.next-app h3 { margin: 0 0 4px; font-size: 19px; }
.next-app p { margin: 0; color: var(--ink-soft); }

/* Stats */
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.stat { text-align: center; padding: 34px 20px; border-radius: var(--radius); background: var(--card); border: 1px solid var(--line); }
.stat b { display: block; font-size: 56px; line-height: 1; letter-spacing: -.03em; font-weight: 800; margin-bottom: 10px; }
.stat span { color: var(--ink-soft); font-weight: 600; }

/* Contact */
.contact-box { text-align: center; padding: 56px 28px; border-radius: 32px; background: var(--grad); color: #fff; box-shadow: var(--shadow); position: relative; overflow: hidden; }
.contact-box .eyebrow { color: rgba(255,255,255,.85); }
.contact-box h2 { font-size: clamp(28px, 4vw, 42px); line-height: 1.15; margin: 10px auto 12px; max-width: 760px; letter-spacing: -.02em; }
.contact-box p { margin: 0 auto 26px; max-width: 560px; font-size: 18px; opacity: .92; }
.contact-box .btn { background: #fff; color: #3b2fb8; }
.contact-box .mail { display: block; margin-top: 14px; font-weight: 700; opacity: .95; text-decoration: none; }

/* Footer */
footer { padding: 40px 0 48px; color: var(--ink-soft); font-size: 14px; }
footer .wrap { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; justify-content: space-between; border-top: 1px solid var(--line); padding-top: 28px; }
footer nav { display: flex; gap: 18px; flex-wrap: wrap; }
footer a { text-decoration: none; font-weight: 600; }
footer a:hover { color: var(--ink); }

/* Legal page */
.legal { padding: 56px 0 30px; }
.legal .wrap { max-width: 820px; }
.legal h1 { font-size: clamp(32px, 5vw, 46px); letter-spacing: -.02em; line-height: 1.15; margin: 8px 0 6px; }
.legal .updated { color: var(--ink-soft); margin: 0 0 28px; font-weight: 600; }
.legal .summary { background: var(--card); border: 1px solid var(--line); border-inline-start: 5px solid var(--brand-4); border-radius: 16px; padding: 20px 24px; margin-bottom: 30px; box-shadow: var(--shadow); }
.legal .summary h2 { margin: 0 0 6px; font-size: 18px; }
.legal .summary p { margin: 0; }
.legal .summary ul { margin: 0; padding-inline-start: 20px; }
.legal .summary li { color: var(--ink); margin: 6px 0; }
.legal h2 { font-size: 21px; margin: 30px 0 8px; }
.legal section { padding: 0; scroll-margin-top: 84px; } /* not the home page's 84px section padding */
.legal p, .legal li { color: var(--ink-soft); font-size: 16.5px; }
.legal p { margin: 0 0 10px; }
.legal ul { margin: 0 0 12px; padding-inline-start: 22px; }
.legal li { margin: 0 0 8px; }
.legal li::marker { color: var(--brand-2); }
.legal strong { color: var(--ink); }
.legal section a { color: var(--brand-2); font-weight: 600; text-underline-offset: 3px; overflow-wrap: anywhere; }
.legal .toc { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 18px 24px; margin-bottom: 10px; }
.legal .toc h2 { margin: 0 0 8px; font-size: 14px; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-soft); }
.legal .toc ol { list-style: none; margin: 0; padding: 0; columns: 2; column-gap: 28px; }
.legal .toc li { margin: 0 0 6px; font-size: 15px; break-inside: avoid; }
.legal .toc a { text-decoration: none; font-weight: 600; }
.legal .toc a:hover { color: var(--ink); text-decoration: underline; }
.legal .notice { white-space: pre-wrap; overflow-wrap: anywhere; font-size: 12.5px; line-height: 1.55; color: var(--ink-soft); background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 16px 18px; margin: 6px 0 12px; max-height: 320px; overflow: auto; }
.legal .note { margin-top: 36px; font-size: 14px; font-style: italic; }
.legal .legal-links { margin-top: 8px; font-weight: 600; }
@media (max-width: 640px) { .legal .toc ol { columns: 1; } }
.legal .app-chip { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 700; }
.legal .app-chip img { width: 36px; height: 36px; border-radius: 10px; }

/* Reveal on scroll (only when JS runs) */
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity .45s ease, transform .45s ease; }
.js .reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .js .reveal { opacity: 1; transform: none; transition: none; } }

/* Responsive */
@media (max-width: 960px) {
  .hero .wrap, .app-feature { grid-template-columns: 1fr; }
  .hero { padding-top: 44px; }
  .hero-visual { min-height: 460px; }
  .cards, .stats { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .menu-toggle { display: inline-flex; margin-inline-start: auto; }
  .nav-links { display: none; position: absolute; top: 68px; left: 0; right: 0; flex-direction: column; padding: 12px 16px 18px; background: var(--bg); border-bottom: 1px solid var(--line); }
  .nav-links.open { display: flex; }
  .site-header .lang-wrap { order: 2; }
  .menu-toggle { order: 3; margin-inline-start: 0; }
  .brand { margin-inline-end: auto; }
  .brand span { font-size: 16px; }
  section { padding: 60px 0; }
  .app-feature { padding: 26px 20px; }
  .features { grid-template-columns: 1fr; }
  .hero-visual { min-height: 400px; }
  .hero-visual .phone { width: 190px; }
  .hero-visual .phone.back { transform: translate(-30%, 8%) rotate(-8deg) scale(.86); }
  .hero-visual .phone.front { transform: translate(24%, -2%) rotate(5deg); }
  .next-app { flex-direction: column; align-items: flex-start; }
  .wrap { padding: 0 16px; }
}
@media (max-width: 380px) {
  .brand span { display: none; }
}

/* Right-to-left (Arabic) and complex scripts. Layout spacing uses logical properties
   (margin-inline-*, padding-inline-*) above, so it flips on its own. */
[dir="rtl"] .btn svg { transform: scaleX(-1); }
/* Arabic letters join and Devanagari has stacked marks: no tightened tracking or caps spacing. */
html:lang(ar) *, html:lang(hi) * { letter-spacing: normal !important; }
html:lang(ar) body, html:lang(hi) body { line-height: 1.75; }
