:root {
  --ink: #1D1D1F;
  --gray: #6E6E73;
  --line: #D2D2D7;
  --hair: #E8E8ED;
  --bg: #FFFFFF;
  --soft: #F5F5F7;
  --green: #248A3D;
  --green-hover: #1E7A35;
  --link: #248A3D;
  --ok: #248A3D;
  --warn: #B25000;
  --warn-bg: #FFF1E0;
  --out: #C9001A;
  --out-bg: #FFE8EA;
  --radius: 28px;
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --font: "IBM Plex Sans Arabic", system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.75;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; height: auto; }

a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }

h1, h2, h3 { line-height: 1.3; margin: 0; font-weight: 700; text-wrap: balance; }

p { margin: 0; text-wrap: pretty; }

:focus-visible { outline: 3px solid rgba(36, 138, 61, 0.45); outline-offset: 3px; border-radius: 8px; }

.wrap { width: 100%; max-width: 1080px; margin-inline: auto; padding-inline: 20px; }
.narrow { max-width: 760px; }

.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.skip {
  position: absolute; inset-inline-start: 12px; top: -48px; z-index: 20;
  background: var(--ink); color: #fff; padding: 8px 14px; border-radius: 10px;
}
.skip:focus { top: 12px; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 10;
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid transparent;
  transition: border-color 200ms var(--ease-out);
}
.site-header.scrolled { border-bottom-color: var(--hair); }

.header-row { display: flex; align-items: center; gap: 24px; height: 56px; }
.brand img { height: 32px; width: auto; }
.nav { display: none; gap: 28px; margin-inline-start: auto; }
.nav a { color: var(--ink); opacity: 0.8; font-size: 0.875rem; transition: opacity 150ms ease; }
.nav a:hover { opacity: 1; text-decoration: none; }
.header-row .btn-small { margin-inline-start: auto; }

@media (min-width: 860px) {
  .nav { display: flex; }
  .header-row .btn-small { margin-inline-start: 4px; }
}

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 0 24px;
  background: var(--green); color: #fff;
  font: 500 1.0625rem/1 var(--font);
  border: 0; border-radius: 999px; cursor: pointer;
  transition: transform 160ms var(--ease-out), background-color 160ms ease;
}
.btn:hover { background: var(--green-hover); text-decoration: none; }
.btn:active { transform: scale(0.97); }
.btn-small { min-height: 30px; padding: 0 14px; font-size: 0.8rem; }
.btn-wide { width: 100%; }

.more { font-size: 1.0625rem; display: inline-flex; align-items: center; gap: 4px; }
.more::after { content: "‹"; font-size: 1.2em; line-height: 1; }

.link-btn {
  background: none; border: 0; padding: 6px 2px; cursor: pointer;
  font: 500 0.95rem var(--font); color: var(--link);
}
.link-btn:hover { text-decoration: underline; text-underline-offset: 3px; }

/* Hero */
.hero { position: relative; padding: 40px 0 64px; text-align: center; overflow: hidden; }
.hero .wrap { position: relative; }

.grid-bg {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(to right, var(--hair) 1px, transparent 1px),
    linear-gradient(to bottom, var(--hair) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 22%, #000 35%, transparent 85%);
  -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 22%, #000 35%, transparent 85%);
}

.hero-copy {
  max-width: 820px; margin: 0 auto; padding: 36px 20px;
  background: #fff; border: 2px dashed var(--green); border-radius: var(--radius);
}
@media (min-width: 760px) { .hero { padding-top: 64px; } .hero-copy { padding: 52px 56px; } }
.kicker { color: var(--gray); font-weight: 600; font-size: 1.05rem; margin-bottom: 10px; }
h1 { font-size: clamp(2.25rem, 8vw, 4rem); line-height: 1.2; }
.lead { margin: 18px auto 0; max-width: 32em; color: var(--gray); font-size: clamp(1.1rem, 3vw, 1.3rem); line-height: 1.6; }

.actions { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 14px 28px; margin-top: 30px; }

.hero-shot { width: 100%; max-width: 980px; margin: 56px auto 0; }
.window {
  background: #fff; border-radius: 16px; overflow: hidden;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.06), 0 30px 70px -24px rgba(0, 0, 0, 0.22);
}
.window-bar {
  display: flex; gap: 8px; padding: 12px 16px;
  background: #ECECEE; border-bottom: 1px solid #DCDCE0; direction: ltr;
}
.window-bar span { width: 12px; height: 12px; border-radius: 50%; box-shadow: inset 0 0 0 0.5px rgba(0, 0, 0, 0.12); }
.window-bar span:nth-child(1) { background: #FF5F57; }
.window-bar span:nth-child(2) { background: #FEBC2E; }
.window-bar span:nth-child(3) { background: #28C840; }
.hero-shot figcaption { margin-top: 14px; color: var(--gray); font-size: 0.8rem; }

.trust {
  list-style: none; padding: 0; margin: 48px auto 0; max-width: 820px;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px;
}
.trust li { display: grid; gap: 2px; font-size: 0.9rem; color: var(--gray); line-height: 1.5; }
.trust strong { color: var(--ink); font-size: 1rem; }

@media (max-width: 520px) {
  .trust { margin-top: 32px; gap: 8px; }
  .trust li { font-size: 0.75rem; }
  .trust strong { font-size: 0.85rem; }
}

/* Sections */
.section { padding: 80px 0; }
section[id] { scroll-margin-top: 56px; }
.soft { background: var(--soft); }

.section-head { text-align: center; max-width: 680px; margin: 0 auto 44px; }
.section-head h2 { font-size: clamp(1.9rem, 6vw, 3rem); line-height: 1.25; }
.section-head p { margin-top: 14px; color: var(--gray); font-size: 1.15rem; }

/* Demo */
.demo {
  max-width: 820px; margin: 0 auto;
  background: #fff; border-radius: var(--radius);
  padding: 24px;
}
.demo-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.demo-tag { font-size: 0.8rem; color: var(--gray); background: var(--soft); padding: 4px 12px; border-radius: 999px; }
.demo-total { display: flex; align-items: baseline; gap: 10px; font-size: 0.9rem; color: var(--gray); }
.demo-total strong { color: var(--ink); font-size: 1.4rem; font-variant-numeric: tabular-nums; }

.table-scroll { position: relative; overflow-x: auto; -webkit-overflow-scrolling: touch; }
.demo-table { width: 100%; min-width: 520px; border-collapse: collapse; font-size: 0.95rem; }
.demo-table th { text-align: start; font-weight: 500; color: var(--gray); font-size: 0.82rem; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.demo-table td { padding: 12px; border-bottom: 1px solid var(--hair); transition: background-color 220ms var(--ease-out); }
.demo-table tbody tr:last-child td { border-bottom: 0; }
.demo-table .num { font-variant-numeric: tabular-nums; }
.demo-table tr.warn td { background: var(--warn-bg); }
.demo-table tr.out td { background: var(--out-bg); }

.stock { display: inline-block; min-width: 2ch; font-weight: 600; }
.stock.tick { animation: tick 220ms var(--ease-out); }
@keyframes tick { from { transform: translateY(-4px); opacity: 0.4; } to { transform: none; opacity: 1; } }

.status { display: inline-flex; align-items: center; gap: 6px; font-size: 0.85rem; font-weight: 600; white-space: nowrap; }
.status::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.status.ok { color: var(--ok); }
.status.warn { color: var(--warn); }
.status.out { color: var(--out); }

.sell {
  min-height: 32px; padding: 0 16px; border: 0; border-radius: 999px; cursor: pointer;
  background: var(--green); color: #fff; font: 500 0.85rem var(--font);
  transition: transform 140ms var(--ease-out), opacity 140ms ease;
}
.sell:active { transform: scale(0.95); }
.sell:disabled { opacity: 0.25; cursor: not-allowed; }

.demo .link-btn { display: block; margin: 12px auto 0; }

@media (max-width: 560px) {
  .demo { padding: 16px 12px; border-radius: 22px; }
  .demo-table { min-width: 0; font-size: 0.9rem; }
  .demo-table th:nth-child(2), .demo-table td:nth-child(2) { display: none; }
  .demo-table th, .demo-table td { padding-inline: 6px; }
  .status { font-size: 0.8rem; }
  .sell { padding: 0 12px; }
}

/* Feature tiles */
.tiles { display: grid; gap: 20px; }
.tile {
  background: var(--soft); border-radius: var(--radius); overflow: hidden;
  padding: 36px 24px 0; text-align: center;
  display: flex; flex-direction: column;
}
.tile-copy { max-width: 560px; margin: 0 auto; }
.tile h3 { font-size: clamp(1.4rem, 4.5vw, 2rem); line-height: 1.3; }
.tile p { margin-top: 10px; color: var(--gray); }
.tile-shot {
  margin: auto auto 0; width: 100%; max-width: 860px;
  background: #fff; border-radius: 16px 16px 0 0; padding: 10px 10px 0;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.05), 0 -8px 30px -12px rgba(0, 0, 0, 0.1);
}
.tile-copy { padding-bottom: 28px; }
.tile-shot img { border-radius: 8px 8px 0 0; }

.tile-hint { display: none; margin: -16px 0 12px; color: var(--gray); font-size: 0.8rem; }

@media (max-width: 640px) {
  .tile { padding-inline: 16px; }
  .tile-shot { overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
  .tile-shot::-webkit-scrollbar { display: none; }
  .tile-shot img { width: 760px; max-width: none; }
  .tile-hint { display: block; }
}

@media (min-width: 900px) {
  .tiles { grid-template-columns: 1fr 1fr; }
  .tile-wide { grid-column: 1 / -1; padding-top: 48px; }
  .tile { padding-inline: 40px; }
}

/* Inside the file */
.sheets {
  list-style: none; counter-reset: sheet; padding: 0; margin: 0;
  display: grid; gap: 14px;
}
.sheets li {
  counter-increment: sheet; position: relative;
  background: #fff; border-radius: 20px; padding: 22px;
  padding-inline-start: 72px;
}
.sheets li::before {
  content: counter(sheet);
  position: absolute; inset-inline-start: 22px; top: 22px;
  width: 34px; height: 34px; display: grid; place-items: center;
  background: var(--soft); border-radius: 50%;
  color: var(--ink); font-weight: 600; font-size: 0.95rem;
}
.sheets strong { display: block; font-size: 1.05rem; }
.sheets span { display: block; color: var(--gray); font-size: 0.95rem; }
.note { margin-top: 32px; text-align: center; color: var(--gray); font-size: 0.95rem; }

@media (min-width: 720px) { .sheets { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .sheets { grid-template-columns: repeat(3, 1fr); } }

/* Products */
.products { display: grid; gap: 20px; }
.product {
  background: var(--soft); border-radius: var(--radius); padding: 24px;
  display: flex; flex-direction: column; text-align: center;
}
.product-shot {
  margin: 0 0 24px; border-radius: 14px; overflow: hidden; background: #fff;
  aspect-ratio: 16 / 9; box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.05);
}
.product-shot img { width: 100%; height: 100%; object-fit: cover; object-position: top center; }
.product-shot.pair { display: grid; grid-template-columns: 1fr 1fr; gap: 2px; background: var(--hair); }
.product h3 { font-size: 1.35rem; line-height: 1.35; }
.product-sub { color: var(--gray); margin-top: 6px; font-size: 0.95rem; }
.badge { color: var(--green); font-weight: 600; font-size: 0.85rem; margin-bottom: 4px; }
.product-price { margin-top: 18px; display: flex; align-items: baseline; justify-content: center; gap: 6px; }
.amount { font-size: 2.6rem; font-weight: 700; line-height: 1; font-variant-numeric: tabular-nums; }
.currency { font-size: 1.1rem; font-weight: 600; }
.was { color: var(--gray); font-size: 0.85rem; margin-top: 6px; }
.checks { list-style: none; padding: 20px 0 0; margin: 20px 0 24px; border-top: 1px solid var(--line); text-align: start; display: grid; gap: 10px; font-size: 0.95rem; }
.checks li { position: relative; padding-inline-start: 26px; }
.checks li::before {
  content: ""; position: absolute; inset-inline-start: 0; top: 0.45em;
  width: 16px; height: 16px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3 8.5l3.2 3.2L13 4.8' fill='none' stroke='%231D1D1F' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 16px no-repeat;
}
.product .btn { margin-top: auto; }
.product-bundle { background: #fff; border: 2px dashed var(--green); }

.fine-row {
  list-style: none; padding: 0; margin: 32px 0 0;
  display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 28px;
  color: var(--gray); font-size: 0.85rem;
}

@media (min-width: 900px) {
  .products { grid-template-columns: repeat(3, 1fr); }
  .product { padding: 28px; }
}

/* FAQ */
.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none; cursor: pointer; padding: 22px 0;
  font-weight: 600; font-size: 1.1rem;
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; flex: none; font-weight: 400; font-size: 1.6rem; line-height: 1; color: var(--gray);
  transition: transform 200ms var(--ease-out);
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding: 0 0 22px; color: var(--gray); }

/* Closing */
.closing { text-align: center; padding: 96px 0; }
.closing-logo { height: 64px; width: auto; margin: 0 auto 20px; }
.closing h2 { font-size: clamp(1.9rem, 6vw, 3rem); line-height: 1.25; }
.closing p { color: var(--gray); margin-top: 12px; font-size: 1.15rem; }

/* Footer */
.site-footer { background: var(--soft); padding: 32px 0 40px; color: var(--gray); font-size: 0.8rem; }
.footer-row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.footer-row img { height: 28px; width: auto; }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px 24px; padding-top: 16px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 6px 22px; }
.footer-links a { color: var(--ink); opacity: 0.8; overflow-wrap: anywhere; }

/* Reveal on scroll */
.js .reveal {
  opacity: 0; transform: translateY(14px);
  transition: opacity 300ms var(--ease-out), transform 300ms var(--ease-out);
  transition-delay: calc(var(--d, 0) * 60ms);
}
.js .reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { transform: none; transition: opacity 200ms ease; }
  .stock.tick { animation: none; }
  .btn:active, .sell:active { transform: none; }
  .faq summary::after { transition: none; }
}

/* Phone screenshots of the app */
.phone {
  display: block; width: 100%; height: auto; border-radius: 30px; background: #F2F2F7;
  box-shadow: 0 0 0 6px #fff, 0 0 0 7px var(--hair), 0 30px 60px -28px rgba(0, 0, 0, 0.28);
}
.phones {
  margin: 56px auto 0; max-width: 820px;
  display: grid; grid-template-columns: 1fr 1.15fr 1fr; align-items: center; gap: 4%;
}
.phones .side { opacity: 0.96; }
.phones figcaption { grid-column: 1 / -1; margin-top: 28px; color: var(--gray); font-size: 0.85rem; }
@media (max-width: 640px) {
  .phones { grid-template-columns: 1fr 1.3fr 1fr; gap: 3%; margin-inline: -6px; }
  .phone { border-radius: 20px; box-shadow: 0 0 0 4px #fff, 0 0 0 5px var(--hair), 0 20px 40px -20px rgba(0, 0, 0, 0.28); }
}
.tile-phone { margin: auto auto 0; width: min(280px, 78%); height: 340px; overflow: hidden; padding: 8px 8px 0; }
.tile-phone .phone { border-radius: 30px 30px 0 0; }
.products.four .product { text-align: center; }
.yearly { display: block; margin-top: 12px; font-size: 0.95rem; font-weight: 500; }
@media (min-width: 720px) { .products.four { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .products.four { grid-template-columns: repeat(4, 1fr); } .products.four .product { padding: 24px; } }
.soft .product { background: #fff; }
