/* Kayan App website. Brand colors match the app; logical properties keep
   the layout right for both Arabic (rtl) and English (ltr). */
:root {
  --emerald: #043c37;
  --emerald-2: #0a524a;
  --emerald-3: #127064;
  --gold: #eac365;
  --gold-soft: #f6e3b2;
  --cream: #fbf7ee;
  --bg: #f7f3ea;
  --surface: #ffffff;
  --line: #e7dfcd;
  --ink: #10201d;
  --muted: #5b6b67;
  --radius: 24px;
  --shadow: 0 1px 2px rgb(16 32 29 / 0.04), 0 12px 32px -12px rgb(16 32 29 / 0.14);
  --font: 'IBM Plex Sans Arabic', system-ui, sans-serif;
  --display: Alexandria, 'IBM Plex Sans Arabic', sans-serif;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #081412;
    --surface: #0f1f1c;
    --line: #1e3430;
    --ink: #eef3f1;
    --muted: #a3b4af;
    --shadow: 0 1px 2px rgb(0 0 0 / 0.3), 0 12px 32px -12px rgb(0 0 0 / 0.5);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 17px/1.7 var(--font); }
h1, h2, h3 { font-family: var(--display); line-height: 1.25; margin: 0; letter-spacing: -0.01em; }
p { margin: 0; }
a { color: inherit; }
img { max-width: 100%; display: block; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; border-radius: 6px; }
.wrap { width: min(1160px, 100% - 32px); margin-inline: auto; }
.skip { position: absolute; inset-inline-start: 16px; top: -60px; z-index: 50; padding: 10px 16px; border-radius: 12px; background: var(--gold); color: var(--emerald); font-weight: 600; }
.skip:focus { top: 12px; }

/* ---------------------------------------------------------------- header */
.site-head { position: sticky; top: 0; z-index: 40; background: rgb(4 60 55 / 0.88); backdrop-filter: saturate(160%) blur(14px); -webkit-backdrop-filter: saturate(160%) blur(14px); border-bottom: 1px solid rgb(234 195 101 / 0.14); }
.site-head .wrap { display: flex; align-items: center; gap: 12px; min-height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--cream); font: 700 19px var(--display); }
.brand img { width: 38px; height: 38px; border-radius: 10px; }
.nav { display: flex; gap: 2px; margin-inline-start: auto; }
.nav a { min-height: 44px; display: inline-flex; align-items: center; padding: 0 14px; border-radius: 12px; color: #d4e2de; text-decoration: none; font-weight: 500; }
.nav a:hover { color: var(--cream); background: rgb(255 255 255 / 0.06); }
.nav a[aria-current='page'] { color: var(--gold); }
.lang { min-height: 40px; display: inline-flex; align-items: center; gap: 6px; padding: 0 14px; border-radius: 99px; border: 1px solid rgb(234 195 101 / 0.4); color: var(--gold); text-decoration: none; font-weight: 600; font-size: 15px; }
.lang:hover { background: rgb(234 195 101 / 0.1); }
.lang svg { width: 17px; height: 17px; }
@media (max-width: 720px) {
  .site-head .wrap { flex-wrap: wrap; padding-block: 8px; }
  .nav { order: 3; width: 100%; margin: 0; justify-content: space-between; }
  .nav a { padding: 0 10px; font-size: 15px; }
  .lang { margin-inline-start: auto; }
}

/* ---------------------------------------------------------------- buttons */
.btn { min-height: 52px; display: inline-flex; align-items: center; justify-content: center; gap: 10px; padding: 0 22px; border: 0; border-radius: 16px; font: 600 16px var(--font); text-decoration: none; cursor: pointer; transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease; }
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: none; }
.btn svg { width: 22px; height: 22px; flex: none; }
.btn.gold { background: var(--gold); color: var(--emerald); box-shadow: 0 8px 24px -10px rgb(234 195 101 / 0.8); }
.btn.dark { background: var(--emerald); color: var(--cream); }
.btn.ghost { background: rgb(255 255 255 / 0.08); color: var(--cream); border: 1px solid rgb(255 255 255 / 0.18); }
.btn.line { background: transparent; color: var(--ink); border: 1.5px solid var(--line); }
.btn[aria-disabled='true'] { opacity: 0.6; pointer-events: none; }
.btn small { font-weight: 400; opacity: 0.8; }
.store { flex-direction: column; align-items: flex-start; gap: 0; line-height: 1.2; padding-inline: 18px 22px; }
.store-row { display: flex; align-items: center; gap: 10px; }
.store small { font-size: 12px; }
.store strong { font-size: 17px; }

/* ---------------------------------------------------------------- hero */
.hero { position: relative; overflow: hidden; background: radial-gradient(1200px 500px at 85% -10%, rgb(234 195 101 / 0.18), transparent 60%), radial-gradient(900px 600px at 0% 110%, rgb(18 112 100 / 0.55), transparent 60%), var(--emerald); color: var(--cream); padding: 64px 0 88px; }
.hero::before { content: ''; position: absolute; inset: 0; background-image: linear-gradient(rgb(255 255 255 / 0.035) 1px, transparent 1px), linear-gradient(90deg, rgb(255 255 255 / 0.035) 1px, transparent 1px); background-size: 44px 44px; mask-image: radial-gradient(ellipse at 50% 30%, #000 30%, transparent 75%); pointer-events: none; }
.hero .wrap { position: relative; display: grid; grid-template-columns: 1.1fr 0.9fr; align-items: center; gap: 48px; }
@media (max-width: 900px) { .hero .wrap { grid-template-columns: 1fr; } .hero { padding-top: 40px; } }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: 99px; background: rgb(234 195 101 / 0.12); border: 1px solid rgb(234 195 101 / 0.3); color: var(--gold); font-weight: 600; font-size: 14px; }
.eyebrow::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 4px rgb(234 195 101 / 0.2); }
.hero h1 { margin-top: 18px; font-size: clamp(36px, 6vw, 62px); }
.hero h1 em { font-style: normal; color: var(--gold); }
.lead { margin-top: 18px; font-size: clamp(17px, 2vw, 20px); color: #cfdeda; max-width: 38ch; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.trust { display: flex; flex-wrap: wrap; gap: 28px; margin-top: 36px; }
.trust div { display: flex; flex-direction: column; }
.trust strong { font: 700 26px var(--display); color: var(--cream); }
.trust span { font-size: 14px; color: #a9c2bc; }

/* Phone mockup: an illustration of the app, built in HTML. */
.phone-stage { position: relative; justify-self: center; }
.phone-stage::before { content: ''; position: absolute; inset: 10% -10% -5%; background: radial-gradient(closest-side, rgb(234 195 101 / 0.35), transparent); filter: blur(30px); }
.phone { position: relative; width: min(300px, 78vw); aspect-ratio: 9 / 18.5; border-radius: 44px; padding: 12px; background: linear-gradient(145deg, #1d3a35, #061d1a); box-shadow: 0 40px 80px -30px rgb(0 0 0 / 0.6), inset 0 0 0 1.5px rgb(255 255 255 / 0.08); transform: rotate(-3deg); }
[dir='ltr'] .phone { transform: rotate(3deg); }
.screen { height: 100%; border-radius: 34px; overflow: hidden; background: #f7f3ea; color: #10201d; display: flex; flex-direction: column; font-size: 11px; line-height: 1.4; }
.screen-top { background: var(--emerald); color: var(--cream); padding: 30px 14px 16px; }
.screen-top b { display: block; font: 700 15px var(--display); color: var(--gold); }
.screen-search { margin-top: 10px; padding: 8px 10px; border-radius: 10px; background: rgb(255 255 255 / 0.1); color: #b9cdc8; }
.screen-body { padding: 12px; display: flex; flex-direction: column; gap: 10px; }
.chips { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.chips span { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 8px 2px; border-radius: 12px; background: #fff; font-size: 9px; font-weight: 600; text-align: center; }
.chips i { width: 22px; height: 22px; border-radius: 8px; background: var(--emerald); display: block; }
.chips span:nth-child(2) i { background: #0a524a; }
.chips span:nth-child(3) i { background: var(--gold); }
.chips span:nth-child(4) i { background: #127064; }
.mini-card { display: flex; align-items: center; gap: 8px; padding: 9px; border-radius: 14px; background: #fff; }
.mini-card .av { width: 34px; height: 34px; border-radius: 10px; flex: none; background: linear-gradient(135deg, var(--emerald), #127064); }
.mini-card:nth-child(3) .av { background: linear-gradient(135deg, #c99a2e, var(--gold)); }
.mini-card div { flex: 1; min-width: 0; }
.mini-card b { display: block; font-size: 11px; }
.mini-card small { color: #5b6b67; font-size: 9px; }
.open { font-size: 9px; font-weight: 700; color: #0b7a55; background: #dcefe6; padding: 2px 6px; border-radius: 99px; }
.alert { padding: 9px 10px; border-radius: 12px; background: #fbeccd; color: #6b4a00; font-size: 10px; font-weight: 600; }

/* ---------------------------------------------------------------- sections */
.section { padding: 88px 0; }
.section.tight { padding: 56px 0; }
.head { max-width: 680px; margin-bottom: 40px; }
.head.center { margin-inline: auto; text-align: center; }
.kicker { color: var(--emerald-3); font-weight: 700; font-size: 14px; letter-spacing: 0.04em; text-transform: uppercase; }
@media (prefers-color-scheme: dark) { .kicker { color: var(--gold); } }
.head h2 { margin-top: 8px; font-size: clamp(28px, 4vw, 42px); }
.head p { margin-top: 14px; color: var(--muted); font-size: 18px; }

/* Bento features */
.bento { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; }
.tile { grid-column: span 2; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow); }
.tile.wide { grid-column: span 3; }
.tile.dark { background: linear-gradient(160deg, var(--emerald-2), var(--emerald)); color: var(--cream); border-color: transparent; }
.tile.dark p { color: #c4d6d1; }
.tile h3 { margin-top: 18px; font-size: 20px; }
.tile p { margin-top: 8px; color: var(--muted); }
@media (max-width: 900px) { .tile, .tile.wide { grid-column: span 3; } }
@media (max-width: 620px) { .bento { grid-template-columns: 1fr; } .tile, .tile.wide { grid-column: auto; } }
.ico { width: 52px; height: 52px; display: grid; place-items: center; border-radius: 16px; background: rgb(4 60 55 / 0.08); color: var(--emerald); }
.tile.dark .ico { background: rgb(234 195 101 / 0.14); color: var(--gold); }
@media (prefers-color-scheme: dark) { .ico { background: rgb(234 195 101 / 0.1); color: var(--gold); } }
.ico svg { width: 26px; height: 26px; }

/* Steps */
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); gap: 16px; counter-reset: step; list-style: none; padding: 0; margin: 0; }
.steps li { counter-increment: step; position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; }
.steps li::before { content: counter(step); display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; background: var(--emerald); color: var(--gold); font: 700 18px var(--display); }
.steps h3 { margin-top: 16px; font-size: 19px; }
.steps p { margin-top: 6px; color: var(--muted); }

/* Call to action band */
.cta { position: relative; overflow: hidden; border-radius: 32px; padding: clamp(32px, 6vw, 56px); background: radial-gradient(600px 300px at 90% 0%, rgb(234 195 101 / 0.25), transparent 60%), linear-gradient(150deg, var(--emerald-2), var(--emerald)); color: var(--cream); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; }
.cta h2 { font-size: clamp(26px, 4vw, 38px); color: var(--cream); }
.cta p { margin-top: 10px; color: #c4d6d1; max-width: 46ch; }

/* ---------------------------------------------------------------- pricing */
.page-hero { background: radial-gradient(900px 400px at 80% -20%, rgb(234 195 101 / 0.16), transparent 60%), var(--emerald); color: var(--cream); padding: 64px 0 120px; text-align: center; }
.page-hero h1 { font-size: clamp(32px, 5vw, 52px); margin-top: 14px; }
.page-hero .lead { margin-inline: auto; max-width: 52ch; }
.plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: -84px; position: relative; }
@media (max-width: 900px) { .plans { grid-template-columns: 1fr; max-width: 480px; margin-inline: auto; } }
.plan { position: relative; display: flex; flex-direction: column; gap: 18px; background: var(--surface); border: 1px solid var(--line); border-radius: 28px; padding: 32px; box-shadow: var(--shadow); }
.plan.best { border: 2px solid var(--gold); box-shadow: 0 30px 60px -30px rgb(234 195 101 / 0.55); }
.badge { position: absolute; top: -14px; inset-inline-start: 28px; padding: 3px 14px; border-radius: 99px; background: var(--gold); color: var(--emerald); font-weight: 700; font-size: 13px; }
.plan h3 { font-size: 22px; }
.plan .for { color: var(--muted); margin-top: -10px; font-size: 15px; }
.price { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.price strong { font: 700 44px var(--display); color: var(--emerald); }
@media (prefers-color-scheme: dark) { .price strong { color: var(--gold); } }
.price span { color: var(--muted); }
.per-month { margin-top: -12px; font-size: 14px; color: var(--muted); }
.plan ul { list-style: none; margin: 0; padding: 18px 0 0; border-top: 1px solid var(--line); display: flex; flex-direction: column; gap: 10px; flex: 1; }
.plan li { display: flex; gap: 10px; align-items: flex-start; }
.plan li::before { content: ''; flex: none; width: 20px; height: 20px; margin-top: 4px; border-radius: 50%; background: var(--emerald) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23EAC365' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l5 5 9-10'/%3E%3C/svg%3E") center / 12px no-repeat; }
.plan li.off { color: var(--muted); opacity: 0.6; }
.plan li.off::before { background: var(--line) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235b6b67' stroke-width='3' stroke-linecap='round'%3E%3Cpath d='M7 12h10'/%3E%3C/svg%3E") center / 12px no-repeat; }
.plan .btn { width: 100%; }
.skeleton { min-height: 520px; border-radius: 28px; background: linear-gradient(90deg, var(--surface) 25%, var(--line) 50%, var(--surface) 75%); background-size: 200% 100%; animation: shimmer 1.4s infinite; }
@keyframes shimmer { to { background-position: -200% 0; } }
.free-note { margin-top: 28px; padding: 18px 22px; border-radius: 18px; background: var(--surface); border: 1px dashed var(--line); color: var(--muted); text-align: center; }

/* ---------------------------------------------------------------- FAQ */
.faq { max-width: 820px; margin-inline: auto; display: flex; flex-direction: column; gap: 12px; }
.faq details { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 0 22px; }
.faq summary { min-height: 64px; display: flex; align-items: center; justify-content: space-between; gap: 12px; cursor: pointer; font-weight: 600; font-size: 18px; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; flex: none; width: 32px; height: 32px; display: grid; place-items: center; border-radius: 10px; background: rgb(4 60 55 / 0.08); color: var(--emerald-3); font-size: 22px; transition: transform 0.2s; }
@media (prefers-color-scheme: dark) { .faq summary::after { color: var(--gold); background: rgb(234 195 101 / 0.1); } }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding-bottom: 20px; color: var(--muted); }

/* ---------------------------------------------------------------- claim & docs */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(22px, 4vw, 36px); box-shadow: var(--shadow); }
.narrow { max-width: 760px; margin-inline: auto; }
.claim-steps { list-style: none; margin: 20px 0 0; padding: 0; display: flex; flex-direction: column; gap: 14px; counter-reset: s; }
.claim-steps li { counter-increment: s; display: flex; gap: 14px; }
.claim-steps li::before { content: counter(s); flex: none; width: 34px; height: 34px; display: grid; place-items: center; border-radius: 10px; background: var(--emerald); color: var(--gold); font-weight: 700; }
.claim-steps li > div { flex: 1; min-width: 0; }
.code-box { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 10px; }
.code-box input { flex: 1 1 240px; min-width: 0; min-height: 52px; padding: 0 14px; border: 1.5px solid var(--line); border-radius: 14px; background: var(--bg); color: var(--ink); font: 14px ui-monospace, monospace; }
.notice { margin-top: 18px; padding: 14px 16px; border-radius: 14px; background: #fbeccd; color: #6b4a00; }
.doc h1 { font-size: clamp(30px, 5vw, 42px); }
.doc .updated { margin-top: 8px; color: var(--muted); }
.doc h2 { margin-top: 34px; font-size: 22px; }
.doc p, .doc ul, .doc ol { margin-top: 10px; }
.doc ul, .doc ol { padding-inline-start: 22px; }
.doc li + li { margin-top: 6px; }

/* ---------------------------------------------------------------- footer */
.site-foot { margin-top: 40px; background: #03302c; color: #b6cbc6; padding: 56px 0 28px; }
.foot-grid { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 32px; }
@media (max-width: 760px) { .foot-grid { grid-template-columns: 1fr 1fr; } .foot-grid > :first-child { grid-column: 1 / -1; } }
.site-foot h3 { font: 600 15px var(--font); color: var(--cream); margin-bottom: 10px; }
.site-foot ul { list-style: none; margin: 0; padding: 0; }
.site-foot li a { min-height: 40px; display: inline-flex; align-items: center; color: #b6cbc6; text-decoration: none; }
.site-foot li a:hover { color: var(--gold); }
.site-foot .about { margin-top: 12px; max-width: 34ch; }
.foot-bottom { margin-top: 40px; padding-top: 22px; border-top: 1px solid rgb(255 255 255 / 0.08); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; font-size: 14px; }

/* ---------------------------------------------------------------- motion */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn, .faq summary::after { transition: none; }
  .skeleton { animation: none; }
}

/* Monthly / yearly switch */
.billing { display: inline-flex; gap: 4px; margin-top: 26px; padding: 5px; border-radius: 99px; background: rgb(255 255 255 / 0.08); border: 1px solid rgb(255 255 255 / 0.14); }
.billing button { min-height: 44px; display: inline-flex; align-items: center; gap: 8px; padding: 0 20px; border: 0; border-radius: 99px; background: transparent; color: #d4e2de; font: 600 16px var(--font); cursor: pointer; }
.billing button[aria-pressed='true'] { background: var(--gold); color: var(--emerald); }
.billing span { font-size: 12px; padding: 2px 8px; border-radius: 99px; background: rgb(4 60 55 / 0.12); }
.billing button[aria-pressed='false'] span { background: rgb(234 195 101 / 0.18); color: var(--gold); }
