:root {
  --paper: #F7F1E7;
  --paper-bright: #FFF9F0;
  --paper-deep: #EADFCC;
  --rose: #D98F98;
  --rose-deep: #9D5863;
  --rose-soft: #E9B8BB;
  --gold: #B08D57;
  --gold-soft: #D7BC86;
  --ink: #392F2C;
  --ink-soft: #74665E;
  --green: #425F51;
  --line: rgba(112, 83, 70, 0.18);
  --shadow: rgba(69, 45, 37, 0.13);
  --radius: 8px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Georgia, "Times New Roman", serif;
  line-height: 1.58;
  letter-spacing: 0;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 4px; }
button, input, textarea, select { font: inherit; }

.skip-link {
  position: fixed;
  left: 16px;
  top: -80px;
  z-index: 100;
  padding: 10px 14px;
  background: var(--ink);
  color: white;
}
.skip-link:focus { top: 12px; }

.site-nav {
  position: fixed;
  inset: 0 0 auto;
  z-index: 20;
  border-bottom: 1px solid rgba(255,255,255,0.32);
  background: rgba(247, 241, 231, 0.84);
  -webkit-backdrop-filter: blur(18px) saturate(115%);
  backdrop-filter: blur(18px) saturate(115%);
}
.nav-inner, .footer-inner, .wide { width: min(1180px, calc(100% - 48px)); margin-inline: auto; }
.nav-inner { height: 68px; display: flex; align-items: center; justify-content: space-between; gap: 28px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-size: 20px; font-weight: 700; }
.brand img { width: 34px; height: 34px; object-fit: contain; }
.site-nav nav { display: flex; align-items: center; gap: 26px; }
.site-nav nav a { color: var(--ink-soft); text-decoration: none; font-size: 14px; font-weight: 700; }
.site-nav nav a:hover, .site-nav nav a:focus-visible { color: var(--rose-deep); }
.site-nav .nav-download { padding: 9px 15px; border: 1px solid var(--line); border-radius: 999px; background: rgba(255,249,240,0.62); }

.hero {
  min-height: min(790px, 92vh);
  position: relative;
  display: grid;
  align-items: center;
  overflow: hidden;
  isolation: isolate;
  padding: 104px 24px 54px;
  background-color: #F4EEE4;
  background-image:
    radial-gradient(ellipse at 72% 45%, rgba(255,255,255,0.72) 0%, rgba(255,255,255,0.14) 42%, rgba(96,70,54,0.08) 100%),
    url("/assets/hero-paper-grain.png");
  background-position: center, center;
  background-size: cover, 512px auto;
  background-blend-mode: normal, multiply;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  box-shadow: inset 0 -54px 90px rgba(80, 55, 43, 0.06);
}
.hero-layout { width: min(1240px, 100%); margin-inline: auto; display: grid; grid-template-columns: minmax(400px, 0.86fr) minmax(520px, 1.14fr); align-items: center; gap: clamp(20px, 3vw, 52px); }
.hero-content { position: relative; z-index: 2; color: var(--ink); text-align: left; }
.hero-trefoil-glow {
  position: absolute;
  z-index: -1;
  width: 340px;
  height: 340px;
  left: -106px;
  top: -82px;
  background: linear-gradient(135deg, #93C07C, #E3A24F 52%, #8E8AC0);
  opacity: 0.075;
  filter: blur(22px);
  -webkit-mask: url("/assets/trefoil.svg") center / contain no-repeat;
  mask: url("/assets/trefoil.svg") center / contain no-repeat;
}
.hero-mark { width: 72px; height: 72px; margin: 0 0 22px; object-fit: contain; }
.eyebrow { margin: 0 0 12px; color: var(--rose-deep); font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.12em; }
.hero .eyebrow { color: var(--rose-deep); }
.hero h1 { margin: 0; font-size: clamp(64px, 7.6vw, 104px); line-height: 0.92; font-weight: 600; }
.hero-subtitle { margin: 18px 0 0; font-size: clamp(23px, 2.4vw, 33px); color: var(--ink); }
.hero-copy { max-width: 550px; margin: 22px 0 0; font-size: clamp(16px, 1.5vw, 19px); color: var(--ink-soft); }
.hero-actions { margin-top: 30px; display: flex; justify-content: flex-start; align-items: center; gap: 22px; flex-wrap: wrap; }
.primary-action {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  padding: 12px 22px;
  border: 1px solid rgba(157,88,99,0.5);
  border-radius: 999px;
  background: var(--rose-soft);
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
  box-shadow: 0 8px 24px rgba(49,30,29,0.12);
}
.primary-action:hover { background: #F0C7C9; }
.text-action { color: var(--rose-deep); font-weight: 700; }
.hero-qr { margin: 30px 0 0; display: inline-flex; align-items: center; gap: 12px; text-align: left; }
.hero-qr img { width: 66px; height: 66px; padding: 6px; border-radius: 6px; background: var(--paper-bright); }
.hero-qr img, .qr-paper img { image-rendering: pixelated; }
.hero-qr p { margin: 0; display: grid; font-size: 13px; color: var(--ink-soft); }
.hero-qr strong { color: var(--ink); }
.hero-still-life { position: relative; min-height: 600px; }
.hero-card {
  position: absolute;
  z-index: 1;
  width: 108%;
  max-width: none;
  left: -5%;
  top: 50%;
  transform: translateY(-50%) rotate(2.2deg);
  border-radius: 5px;
  box-shadow: 0 34px 58px rgba(69,45,37,0.20), 0 5px 12px rgba(69,45,37,0.10);
}
.hero-rose {
  position: absolute;
  z-index: 2;
  width: 38%;
  right: -2%;
  bottom: 1%;
  transform: rotate(58deg);
  filter: saturate(0.72) brightness(0.98) drop-shadow(0 15px 16px rgba(69,45,37,0.18));
}
.hero-seal {
  position: absolute;
  z-index: 3;
  width: 19%;
  left: 3%;
  bottom: 3%;
  transform: rotate(-10deg);
  filter: drop-shadow(0 12px 13px rgba(69,45,37,0.22));
}

.opening { padding: 88px 24px 72px; border-bottom: 1px solid var(--line); }
.narrow { width: min(780px, 100%); margin-inline: auto; }
.opening h2, .principles h2 { margin: 0; font-size: clamp(37px, 6vw, 66px); line-height: 1.02; font-weight: 500; }
.opening .narrow > p:last-child { max-width: 650px; margin: 28px 0 0 auto; color: var(--ink-soft); font-size: 18px; }

.stories { overflow: hidden; }
.story { min-height: 720px; display: grid; grid-template-columns: minmax(300px, 500px) minmax(300px, 430px); align-items: center; justify-content: center; gap: clamp(52px, 9vw, 130px); padding: 82px 48px; border-bottom: 1px solid var(--line); }
.story:nth-child(even) { background: var(--green); color: var(--paper-bright); }
.story:nth-child(even) .story-copy { order: 2; }
.story:nth-child(even) .phone-frame { order: 1; }
.story:nth-child(even) .eyebrow { color: var(--gold-soft); }
.story:nth-child(even) .story-copy > p:last-child { color: rgba(255,249,240,0.76); }
.story-number { margin: 0 0 28px; color: var(--gold); font-size: 16px; font-style: italic; }
.story-kicker { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.story-kicker .eyebrow { margin: 0; }
.app-glyph, .app-glyph-original { display: block; flex: 0 0 auto; width: 34px; height: 34px; }
.app-glyph { background: var(--gold); -webkit-mask-position: center; mask-position: center; -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat; -webkit-mask-size: contain; mask-size: contain; }
.app-glyph-original { object-fit: contain; }
.app-glyph-today { -webkit-mask-image: url("/assets/icon-today.png"); mask-image: url("/assets/icon-today.png"); }
.app-glyph-garden { -webkit-mask-image: url("/assets/icon-garden.png"); mask-image: url("/assets/icon-garden.png"); background: var(--rose); }
.app-glyph-ashab { -webkit-mask-image: url("/assets/icon-ashab.png"); mask-image: url("/assets/icon-ashab.png"); background: var(--rose); }
.app-glyph-circles { -webkit-mask-image: url("/assets/icon-circles.png"); mask-image: url("/assets/icon-circles.png"); }
.app-glyph-locker { -webkit-mask-image: url("/assets/icon-locker.png"); mask-image: url("/assets/icon-locker.png"); background: var(--rose); }
.app-glyph-quran { -webkit-mask-image: url("/assets/icon-quran.png"); mask-image: url("/assets/icon-quran.png"); background: var(--ink); }
.app-glyph-today, .app-glyph-garden, .app-glyph-circles { -webkit-mask-size: 118%; mask-size: 118%; }
.story:nth-child(even) .app-glyph { background: var(--gold-soft); }
.story h2 { margin: 0; font-size: clamp(38px, 5vw, 64px); line-height: 1.04; font-weight: 500; }
.story-copy > p:last-child { margin: 24px 0 0; color: var(--ink-soft); font-size: 17px; }
.phone-frame { width: min(390px, 82vw); margin: 0; padding: 10px; border-radius: 48px; background: #171414; box-shadow: 0 30px 70px var(--shadow); }
.phone-crop { position: relative; overflow: hidden; aspect-ratio: 0.46; border-radius: 39px; background: var(--paper-bright); }
.phone-crop img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: top; }
.phone-crop-today img { object-position: 50% 0%; }
.phone-crop-garden img, .phone-crop-create img { object-position: 50% 0%; }

.feature-ledger { padding: 102px 0; background: var(--paper-bright); }
.ledger-heading { max-width: 650px; margin-bottom: 52px; }
.ledger-heading h2, .plus h2, .download-band h2 { margin: 0; font-size: clamp(36px, 5vw, 58px); line-height: 1.05; font-weight: 500; }
.ledger-grid { display: grid; grid-template-columns: repeat(2, 1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.ledger-grid article { min-height: 250px; padding: 34px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.ledger-glyph { width: 38px; height: 38px; margin-bottom: 26px; }
.ledger-grid h3 { margin: 0 0 10px; font-size: 25px; }
.ledger-grid p { margin: 0; max-width: 430px; color: var(--ink-soft); }

.principles { padding: 110px 24px; background: var(--rose-soft); }
.promise-copy { margin-top: 34px; padding-top: 30px; border-top: 1px solid rgba(57,47,44,0.18); }
.promise-copy p { margin: 0 0 24px; color: var(--ink-soft); font-family: Georgia, "Times New Roman", serif; font-size: clamp(18px, 2.15vw, 24px); line-height: 1.62; }
.promise-copy p:first-child { color: var(--ink); font-size: clamp(20px, 2.35vw, 27px); }
.promise-copy p:last-child { margin-bottom: 0; }

.plus { padding: 86px 0; background: var(--green); color: var(--paper-bright); }
.plus-inner { display: grid; grid-template-columns: 1fr 0.8fr; align-items: end; gap: 70px; }
.plus .eyebrow { color: var(--gold-soft); }
.plus-inner > p { margin: 0; color: rgba(255,249,240,0.76); font-size: 17px; }

.download-band { padding: 94px 0; }
.download-inner { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 70px; }
.download-copy > p:not(.eyebrow) { color: var(--ink-soft); font-size: 17px; }
.download-copy .primary-action { margin-top: 14px; }
.release-note { display: block; margin-top: 12px; color: var(--ink-soft); font-size: 13px; font-style: italic; }
.qr-paper { display: block; width: 224px; padding: 16px; background: var(--paper-bright); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 18px 42px var(--shadow); }
.qr-paper img { width: 100%; aspect-ratio: 1; }

.site-footer { padding: 50px 0; background: var(--ink); color: var(--paper-bright); }
.footer-inner { display: grid; grid-template-columns: 1fr auto; gap: 34px; align-items: start; }
.footer-brand { font-size: 26px; font-weight: 700; text-decoration: none; }
.footer-inner p { margin: 5px 0 0; color: rgba(255,249,240,0.62); }
.footer-inner nav { display: flex; gap: 20px; flex-wrap: wrap; justify-content: flex-end; }
.footer-inner nav a { color: var(--paper-bright); }
.footer-inner .copyright { grid-column: 1 / -1; padding-top: 28px; border-top: 1px solid rgba(255,255,255,0.14); font-size: 13px; }

.download-main { min-height: calc(100vh - 68px); padding-top: 68px; }
.download-hero { min-height: calc(100vh - 68px); position: relative; display: grid; place-items: center; padding: 54px 24px; overflow: hidden; isolation: isolate; }
.download-art { position: absolute; inset: 0; z-index: -2; background-image: image-set(url("/assets/hero-cinematic.jpg") 1x, url("/assets/hero-cinematic@2x.png") 2x); background-position:center 54%; background-size:cover; background-repeat:no-repeat; }
.download-hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: rgba(247,241,231,0.74); }
.download-card { width: min(590px, 100%); text-align: center; padding: 42px; background: rgba(255,249,240,0.91); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 28px 80px rgba(39,27,24,0.20); }
.download-mark { width: 74px; height: 74px; margin: 0 auto 18px; }
.download-card h1 { margin: 0; font-size: clamp(39px, 7vw, 62px); line-height: 1.02; font-weight: 500; }
.download-lede { color: var(--ink-soft); font-size: 17px; }
.qr-paper-large { width: min(260px, 78%); margin: 26px auto 20px; }
.download-help { max-width: 390px; margin: 22px auto 0; color: var(--ink-soft); font-size: 14px; }

.support-main { padding: 132px 24px 90px; }
.legal-shell { width: min(760px, 100%); margin: 0 auto; }
.legal-shell h1 { margin: 0; font-size: clamp(48px, 8vw, 78px); line-height: 1; font-weight: 500; }
.support-lede { max-width: 620px; color: var(--ink-soft); font-size: 19px; }
.faq { margin-top: 64px; }
.faq h2 { font-size: 34px; font-weight: 500; }
.faq details { border-top: 1px solid var(--line); padding: 20px 0; }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; font-size: 19px; font-weight: 700; }
.faq details p { color: var(--ink-soft); padding-right: 34px; }

@media (max-width: 820px) {
  .nav-inner, .footer-inner, .wide { width: min(100% - 32px, 680px); }
  .site-nav nav a:not(.nav-download) { display: none; }
  .hero { min-height: auto; padding: 100px 18px 52px; }
  .hero-layout { grid-template-columns: 1fr; gap: 24px; }
  .hero-content { width: min(620px, 100%); margin-inline: auto; text-align: center; }
  .hero-trefoil-glow { left: 50%; transform: translateX(-50%); }
  .hero-mark { margin-inline: auto; }
  .hero-copy { max-width: 520px; }
  .hero-actions { justify-content: center; }
  .hero-qr { margin-top: 30px; }
  .hero-still-life { width: min(660px, 100%); min-height: 480px; margin-inline: auto; }
  .hero-card { width: 100%; left: 0; }
  .hero-rose { width: 33%; right: 0; bottom: 0; }
  .hero-seal { width: 17%; left: 5%; bottom: 2%; }
  .story { min-height: auto; grid-template-columns: 1fr; gap: 44px; padding: 70px 20px; }
  .story:nth-child(even) .story-copy, .story:nth-child(even) .phone-frame { order: initial; }
  .story-copy { width: min(560px, 100%); margin-inline: auto; }
  .phone-frame { justify-self: center; }
  .ledger-grid, .plus-inner, .download-inner { grid-template-columns: 1fr; }
  .plus-inner, .download-inner { gap: 42px; }
  .qr-paper { width: 200px; }
  .footer-inner { grid-template-columns: 1fr; }
  .footer-inner nav { justify-content: flex-start; }
}

@media (max-width: 520px) {
  .nav-inner { height: 62px; }
  .brand { font-size: 18px; }
  .brand img { width: 30px; height: 30px; }
  .site-nav nav { gap: 10px; }
  .site-nav .nav-download { padding: 8px 12px; }
  .hero { padding: 92px 16px 36px; align-items: start; }
  .hero-mark { width: 68px; height: 68px; }
  .hero h1 { font-size: 62px; }
  .hero-subtitle { font-size: 23px; }
  .hero-copy { font-size: 16px; }
  .hero-actions { display: grid; justify-items: center; gap: 15px; }
  .hero-qr img { width: 58px; height: 58px; }
  .hero-still-life { min-height: 330px; margin-top: 8px; }
  .hero-card { width: 108%; left: -4%; box-shadow: 0 22px 36px rgba(69,45,37,0.18), 0 4px 10px rgba(69,45,37,0.08); }
  .hero-rose { width: 36%; right: -2%; bottom: -2%; }
  .hero-seal { width: 19%; left: 1%; bottom: 0; }
  .opening { padding: 72px 20px 62px; }
  .opening .narrow > p:last-child { font-size: 16px; }
  .story { padding: 62px 18px; }
  .story h2 { font-size: 39px; }
  .story-copy > p:last-child { font-size: 16px; }
  .phone-frame { width: min(330px, 88vw); border-radius: 42px; }
  .phone-crop { border-radius: 34px; }
  .feature-ledger, .principles, .plus, .download-band { padding-top: 74px; padding-bottom: 74px; }
  .ledger-grid { grid-template-columns: 1fr; }
  .ledger-grid article { min-height: 215px; padding: 28px; }
  .download-card { padding: 32px 20px; }
  .footer-inner nav { display: grid; gap: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
