/* Alpyn website. No external fonts, scripts or requests: everything is served from this site. */

:root {
  color-scheme: dark light;
  /* Night (default): the app's dark palette and the icon's sunrise. */
  --bg: #0f0d1a;
  --bg-deep: #0a0912;
  --surface: #1a1628;
  --surface-2: #221d33;
  --line: rgba(221, 211, 254, 0.12);
  --text: #f5f3ff;
  --text-dim: #bdb6d4;
  --text-faint: #8d86a6;
  --accent: #a78bfa;
  --accent-ink: #c4b2ff;
  --accent-soft: rgba(167, 139, 250, 0.14);
  --sun: #fba35a;
  --sun-soft: rgba(251, 163, 90, 0.16);
  --gold: #f2b84b;
  --sky: linear-gradient(180deg, #3b2470 0%, #6a3a8c 45%, #d7708a 78%, #fba35a 100%);
  --shadow: 0 24px 60px -20px rgba(0, 0, 0, 0.65);
  --radius: 22px;
  --wrap: 1120px;
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-display: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", Roboto, "Helvetica Neue", Arial,
    sans-serif;
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #f7f6fb;
    --bg-deep: #efedf6;
    --surface: #ffffff;
    --surface-2: #f1eef9;
    --line: rgba(25, 22, 33, 0.1);
    --text: #191621;
    --text-dim: #4d475e;
    --text-faint: #6e6880;
    --accent: #7451c8;
    --accent-ink: #6440b8;
    --accent-soft: rgba(116, 81, 200, 0.1);
    --sun: #d9701f;
    --sun-soft: rgba(217, 112, 31, 0.12);
    --shadow: 0 24px 60px -24px rgba(40, 24, 80, 0.35);
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
}

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.6 var(--font);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--accent-ink);
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
}

a:hover {
  text-decoration-thickness: 2px;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
}

h1,
h2,
h3 {
  font-family: var(--font-display);
  line-height: 1.12;
  letter-spacing: -0.02em;
  margin: 0 0 0.5em;
  text-wrap: balance;
}

p {
  margin: 0 0 1em;
}

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 24px;
}

.skip {
  position: absolute;
  left: -9999px;
}

.skip:focus {
  left: 16px;
  top: 12px;
  z-index: 20;
  background: var(--surface);
  padding: 8px 14px;
  border-radius: 10px;
}

.eyebrow {
  display: inline-block;
  font-size: 13px;
  font-weight: 650;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--sun);
  margin-bottom: 14px;
}

/* ---------- Header ---------- */

.site-header {
  position: absolute;
  inset: 0 0 auto;
  z-index: 10;
}

.site-header.solid {
  position: relative;
  border-bottom: 1px solid var(--line);
  background: var(--bg);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 72px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: inherit;
  text-decoration: none;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 20px;
  letter-spacing: -0.01em;
}

.brand img {
  width: 34px;
  height: 34px;
  border-radius: 9px;
}

.nav {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.nav a {
  color: inherit;
  text-decoration: none;
  font-size: 15px;
  padding: 8px 12px;
  border-radius: 999px;
  opacity: 0.85;
}

.nav a:hover,
.nav a[aria-current="page"] {
  opacity: 1;
  background: var(--accent-soft);
}

.on-art {
  color: #f5f3ff;
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  min-height: min(920px, 100svh);
  display: flex;
  align-items: flex-end;
  color: #f5f3ff;
  background: #0f0d1a;
  isolation: isolate;
  overflow: hidden;
}

.hero picture,
.hero .hero-art {
  position: absolute;
  inset: 0;
  z-index: -2;
}

.hero .hero-art {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 30%;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg, rgba(15, 13, 26, 0.35) 0%, rgba(15, 13, 26, 0) 26%, rgba(15, 13, 26, 0.15) 55%, #0f0d1a 100%),
    linear-gradient(90deg, rgba(15, 13, 26, 0.65) 0%, rgba(15, 13, 26, 0) 60%);
}

.hero .wrap {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: end;
  gap: 48px;
  padding-top: 140px;
  padding-bottom: 72px;
}

.hero .eyebrow {
  color: #ffc58f;
}

.hero h1 {
  font-size: clamp(40px, 6.2vw, 76px);
  font-weight: 750;
  margin-bottom: 20px;
}

.hero h1,
.hero .lede {
  text-shadow: 0 2px 24px rgba(15, 13, 26, 0.55);
}

.hero .lede {
  font-size: clamp(18px, 1.6vw, 21px);
  color: #ddd6f3;
  max-width: 34ch;
  margin-bottom: 26px;
}

.pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 0;
  margin: 0 0 30px;
  list-style: none;
}

.pills li {
  font-size: 15px;
  font-weight: 600;
  padding: 7px 14px;
  border-radius: 999px;
  background: rgba(245, 243, 255, 0.1);
  border: 1px solid rgba(245, 243, 255, 0.18);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.soon {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 14px 22px 14px 16px;
  border-radius: 16px;
  background: #f5f3ff;
  color: #16112b;
  font-weight: 650;
  font-size: 16px;
  line-height: 1.25;
}

.soon small {
  display: block;
  font-weight: 500;
  font-size: 13px;
  color: #5a5370;
}

.soon .dot {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  flex: none;
}

.hero-phone {
  justify-self: center;
  width: min(300px, 100%);
}

/* ---------- Phone frame ---------- */

.phone {
  position: relative;
  border-radius: 46px;
  padding: 10px;
  background: linear-gradient(160deg, #3a3550, #15121f 55%, #2a2540);
  box-shadow: var(--shadow), inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.phone img {
  border-radius: 37px;
  width: 100%;
  aspect-ratio: 780 / 1688;
  object-fit: cover;
  background: #15121f;
}

/* ---------- Sections ---------- */

section {
  padding: 104px 0;
}

.section-head {
  max-width: 680px;
  margin-bottom: 48px;
}

.section-head h2 {
  font-size: clamp(32px, 4.2vw, 50px);
  font-weight: 720;
}

.section-head p {
  font-size: 19px;
  color: var(--text-dim);
}

.split {
  display: grid;
  grid-template-columns: 1fr minmax(240px, 320px);
  gap: 64px;
  align-items: center;
}

.split.flip {
  grid-template-columns: minmax(240px, 320px) 1fr;
}

.split.flip .split-media {
  order: -1;
}

.split-media {
  justify-self: center;
  width: 100%;
  max-width: 300px;
}

/* Phases */

.phases {
  list-style: none;
  padding: 0;
  margin: 0 0 28px;
  display: grid;
  gap: 14px;
}

.phase {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 18px;
  padding: 22px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--line);
}

.phase .num {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 20px;
  background: var(--accent-soft);
  color: var(--accent-ink);
}

.phase:nth-child(2) .num {
  background: rgba(215, 112, 138, 0.16);
  color: #e58aa3;
}

.phase:nth-child(3) .num {
  background: var(--sun-soft);
  color: var(--sun);
}

.phase h3 {
  font-size: 20px;
  margin: 2px 0 4px;
}

.phase h3 span {
  font-weight: 500;
  color: var(--text-faint);
  font-size: 15px;
  margin-left: 6px;
  letter-spacing: 0;
}

.phase p {
  margin: 0;
  color: var(--text-dim);
  font-size: 16px;
}

.note {
  font-size: 15px;
  color: var(--text-faint);
  max-width: 60ch;
}

/* Habits */

.band {
  background: var(--bg-deep);
  border-block: 1px solid var(--line);
}

.habit-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 40px;
}

.habit {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 16 / 10;
  color: #f5f3ff;
  background: #1a1628;
  box-shadow: 0 10px 30px -18px rgba(0, 0, 0, 0.6);
}

.habit img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.habit::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(15, 13, 26, 0) 35%, rgba(15, 13, 26, 0.85) 100%);
}

.habit span {
  position: absolute;
  left: 18px;
  bottom: 14px;
  z-index: 1;
  font-family: var(--font-display);
  font-weight: 650;
  font-size: 19px;
}

.cols {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.col h3 {
  font-size: 20px;
  margin-bottom: 8px;
}

.col p {
  color: var(--text-dim);
  font-size: 16px;
  margin: 0;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
  padding: 0;
  margin: 36px 0 0;
}

.chips li {
  font-size: 14px;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--text-dim);
}

/* Forgiving progress */

.points {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 22px;
}

.points li {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 16px;
}

.points .ic {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: var(--accent-soft);
  color: var(--accent-ink);
}

.points .ic svg {
  width: 20px;
  height: 20px;
}

.points h3 {
  font-size: 18px;
  margin: 0 0 4px;
  letter-spacing: -0.01em;
}

.points p {
  margin: 0;
  color: var(--text-dim);
  font-size: 16px;
}

/* Privacy */

.cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.card {
  padding: 24px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--line);
}

.card h3 {
  font-size: 18px;
  margin: 14px 0 6px;
  letter-spacing: -0.01em;
}

.card p {
  margin: 0;
  color: var(--text-dim);
  font-size: 15px;
}

.card .ic {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: var(--sun-soft);
  color: var(--sun);
}

.card .ic svg {
  width: 20px;
  height: 20px;
}

/* Closing */

.closing {
  position: relative;
  text-align: center;
  color: #f5f3ff;
  overflow: hidden;
  isolation: isolate;
  padding: 120px 0;
  background: #0f0d1a;
}

.closing .closing-art {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
}

.closing::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg, #0f0d1a 0%, rgba(15, 13, 26, 0.35) 30%, rgba(15, 13, 26, 0.45) 70%, #0f0d1a 100%);
}

.closing .app-icon {
  width: 96px;
  height: 96px;
  border-radius: 22px;
  margin: 0 auto 26px;
  box-shadow: 0 18px 40px -12px rgba(0, 0, 0, 0.7);
}

.closing h2 {
  font-size: clamp(32px, 4.4vw, 54px);
}

.closing p {
  color: #ddd6f3;
  font-size: 19px;
  max-width: 46ch;
  margin: 0 auto 28px;
}

/* ---------- Footer ---------- */

.site-footer {
  padding: 48px 0 56px;
  border-top: 1px solid var(--line);
  font-size: 15px;
  color: var(--text-faint);
}

.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 20px 32px;
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
}

.site-footer a {
  color: var(--text-dim);
  text-decoration: none;
}

.site-footer a:hover {
  color: var(--text);
  text-decoration: underline;
}

.site-footer .fine {
  flex-basis: 100%;
  font-size: 13px;
  margin: 0;
}

/* ---------- Document pages (Privacy, Terms, Support) ---------- */

.doc {
  padding: 64px 0 96px;
}

.doc .wrap {
  max-width: 760px;
}

.doc h1 {
  font-size: clamp(34px, 5vw, 48px);
  font-weight: 740;
}

.doc .meta {
  color: var(--text-faint);
  font-size: 15px;
  margin-bottom: 32px;
}

.doc h2 {
  font-size: 24px;
  margin: 48px 0 14px;
  padding-top: 8px;
  scroll-margin-top: 24px;
}

.doc h3 {
  font-size: 18px;
  margin: 28px 0 8px;
  letter-spacing: -0.01em;
}

.doc p,
.doc li {
  color: var(--text-dim);
}

.doc strong {
  color: var(--text);
  font-weight: 640;
}

.doc ul {
  padding-left: 1.2em;
  margin: 0 0 1em;
}

.doc li {
  margin-bottom: 0.45em;
}

.summary {
  padding: 24px 26px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--line);
  margin-bottom: 8px;
}

.summary h2 {
  margin-top: 0 !important;
  padding-top: 0 !important;
  font-size: 19px !important;
}

.summary ul {
  margin: 0;
}

.doc .toc {
  columns: 2;
  column-gap: 32px;
  padding: 0;
  list-style: none;
  font-size: 15px;
  margin: 32px 0 0;
}

.toc li {
  margin-bottom: 6px;
  break-inside: avoid;
}

.table-wrap {
  overflow-x: auto;
  margin: 0 0 1.2em;
  border: 1px solid var(--line);
  border-radius: 16px;
}

table {
  border-collapse: collapse;
  width: 100%;
  font-size: 15px;
}

th,
td {
  text-align: left;
  vertical-align: top;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  color: var(--text-dim);
}

th {
  color: var(--text);
  background: var(--surface);
  font-weight: 640;
}

tr:last-child td {
  border-bottom: 0;
}

.contact-card {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 26px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--line);
  margin: 8px 0 24px;
}

.contact-card p {
  margin: 0;
}

.contact-card .addr {
  font-size: 20px;
  font-weight: 650;
  color: var(--text);
  word-break: break-all;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: 14px;
  background: var(--accent);
  color: #16112b;
  text-decoration: none;
  font-weight: 650;
}

@media (prefers-color-scheme: light) {
  .button {
    color: #fefeff;
  }
}

.button:hover {
  filter: brightness(1.06);
}

.faq details {
  border-bottom: 1px solid var(--line);
  padding: 4px 0;
}

.faq summary {
  cursor: pointer;
  list-style: none;
  padding: 16px 36px 16px 0;
  position: relative;
  font-weight: 620;
  color: var(--text);
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  content: "";
  position: absolute;
  right: 6px;
  top: 50%;
  width: 9px;
  height: 9px;
  border-right: 2px solid var(--text-faint);
  border-bottom: 2px solid var(--text-faint);
  transform: translateY(-70%) rotate(45deg);
  transition: transform 0.2s;
}

.faq details[open] summary::after {
  transform: translateY(-30%) rotate(225deg);
}

.faq details > div {
  padding: 0 0 16px;
}

.callout {
  padding: 18px 20px;
  border-radius: 16px;
  background: var(--sun-soft);
  border: 1px solid color-mix(in srgb, var(--sun) 30%, transparent);
  margin: 24px 0;
}

.callout p {
  margin: 0;
  color: var(--text);
}

/* ---------- 404 ---------- */

.lost {
  min-height: 70vh;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 80px 0;
}

/* ---------- Responsive ---------- */

@media (max-width: 960px) {
  .cards {
    grid-template-columns: repeat(2, 1fr);
  }

  .habit-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .cols {
    grid-template-columns: 1fr;
    gap: 22px;
  }
}

@media (max-width: 820px) {
  section {
    padding: 76px 0;
  }

  .hero {
    min-height: auto;
  }

  .hero .wrap {
    grid-template-columns: 1fr;
    padding-top: 120px;
    padding-bottom: 56px;
    gap: 48px;
  }

  .hero::after {
    background: linear-gradient(180deg, rgba(15, 13, 26, 0.5) 0%, rgba(15, 13, 26, 0.3) 18%, rgba(15, 13, 26, 0.62) 34%, rgba(15, 13, 26, 0.72) 50%, #0f0d1a 80%);
  }

  .hero-phone {
    width: min(260px, 72%);
  }

  .split,
  .split.flip {
    grid-template-columns: 1fr;
    gap: 44px;
  }

  .split.flip .split-media {
    order: 0;
  }

  .split-media {
    max-width: 260px;
  }

  .doc .toc {
    columns: 1;
  }
}

/* Narrow phones: the data table becomes one card per row. */
@media (max-width: 560px) {
  .table-wrap {
    border: 0;
    overflow: visible;
  }

  .table-wrap thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
  }

  .table-wrap table,
  .table-wrap tbody,
  .table-wrap tr,
  .table-wrap td {
    display: block;
  }

  .table-wrap tr {
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 6px 0;
    margin-bottom: 10px;
    background: var(--surface);
  }

  .table-wrap td {
    border: 0;
    padding: 6px 16px;
  }

  .table-wrap td:first-child {
    color: var(--text);
    font-weight: 640;
    font-size: 16px;
  }

  .table-wrap td:not(:first-child)::before {
    content: attr(data-label) ": ";
    color: var(--text-faint);
    font-weight: 600;
  }
}

@media (max-width: 560px) {
  body {
    font-size: 16px;
  }

  .wrap {
    padding: 0 16px;
  }

  .site-header .wrap {
    height: 64px;
  }

  .brand span {
    display: none;
  }

  .nav a {
    font-size: 14px;
    padding: 7px 10px;
  }

  .cards,
  .habit-grid {
    grid-template-columns: 1fr;
  }

  .habit {
    aspect-ratio: 16 / 8;
  }

  .phase {
    grid-template-columns: 44px 1fr;
    padding: 18px;
    gap: 14px;
  }

  .phase h3 span {
    display: block;
    margin: 2px 0 0;
  }

  .phase .num {
    width: 44px;
    height: 44px;
    font-size: 17px;
    border-radius: 13px;
  }

  .section-head p,
  .closing p {
    font-size: 17px;
  }
}
