/*
 * Extra styles for the landing page only (index.html). The shared look is in styles.css.
 * The page's colours follow the chosen sign through three variables: --a, --b and --c.
 */
:root { --a: #2fa0f3; --b: #8d13b3; --c: #1e0685; }

/* The living aura behind the top of the page, painted by landing.js. */
#sky { position: absolute; top: 0; left: 0; width: 100%; height: 1100px; z-index: 0; pointer-events: none; -webkit-mask-image: linear-gradient(to bottom, #000 62%, transparent); mask-image: linear-gradient(to bottom, #000 62%, transparent); }
.hero { min-height: 100vh; padding-bottom: 72px; }
.hero h1 span { display: block; opacity: 0; transform: translateY(26px); animation: rise 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) forwards; }
.hero h1 span:nth-child(2) { animation-delay: 0.12s; }
.hero h1 span:nth-child(3) { animation-delay: 0.24s; }
@keyframes rise { to { opacity: 1; transform: none; } }

/* Things fade up as they scroll into view. */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.8s ease, transform 0.8s cubic-bezier(0.2, 0.7, 0.2, 1); }
.reveal.in { opacity: 1; transform: none; }

/* The phone leans a little and follows the pointer. */
.stage { perspective: 1400px; }
.phone { transform: rotateY(var(--ry, -8deg)) rotateX(var(--rx, 4deg)); transition: transform 0.5s ease-out; will-change: transform; }
.screen::before { background:
    radial-gradient(70% 42% at 18% 26%, var(--a), transparent 72%),
    radial-gradient(70% 46% at 88% 34%, var(--b), transparent 72%),
    linear-gradient(to bottom, transparent 55%, var(--base) 96%); opacity: 0.95; transition: opacity 0.4s; }
.days i { cursor: pointer; }
.swap { transition: opacity 0.22s ease, transform 0.22s ease; }
.swap.out { opacity: 0; transform: translateX(-14px); }

/* A slow line of the twelve signs. */
.ribbon { overflow: hidden; padding: 18px 0; opacity: 0.5; -webkit-mask-image: linear-gradient(to right, transparent, #000 15%, #000 85%, transparent); mask-image: linear-gradient(to right, transparent, #000 15%, #000 85%, transparent); }
.ribbon div { display: flex; gap: 56px; width: max-content; font-size: 26px; animation: slide 60s linear infinite; }
@keyframes slide { to { transform: translateX(-50%); } }

/* Choose a sign */
.signs { display: flex; flex-wrap: wrap; gap: 10px; }
.signs button { font: inherit; font-weight: 500; font-size: 15px; color: var(--ink); background: var(--panel); border: 0; border-radius: 999px; height: 46px; padding: 0 18px; cursor: pointer; display: inline-flex; align-items: center; gap: 8px; transition: background 0.25s, color 0.25s, transform 0.15s; }
.signs button:hover { transform: translateY(-2px); }
.signs button[aria-pressed='true'] { background: #fff; color: #14101e; }
.you { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 28px; }
.reading { position: relative; overflow: hidden; border-radius: 36px; padding: 40px; min-height: 380px; display: grid; align-content: end; gap: 10px; background: var(--base); }
.reading::before { content: ''; position: absolute; inset: 0; background:
    radial-gradient(60% 60% at 20% 18%, var(--a), transparent 70%),
    radial-gradient(60% 60% at 86% 30%, var(--b), transparent 70%),
    radial-gradient(70% 50% at 50% 100%, var(--c), transparent 75%);
  transition: opacity 0.5s; }
.reading > * { position: relative; }
.reading .glyph { position: absolute; top: 28px; right: 34px; font-size: 64px; opacity: 0.9; }
.reading h3 { font-size: clamp(64px, 9vw, 104px); line-height: 0.95; }
.reading p { color: #fff; font-size: 18px; }
.made { display: grid; gap: 4px; align-content: center; }
.made .row { display: flex; gap: 16px; align-items: flex-start; padding: 16px 0; }
.made .row + .row { border-top: 1px solid rgba(255, 255, 255, 0.12); }
.made .dot { width: 36px; height: 36px; border-radius: 50%; flex: none; transition: background 0.5s; }
.made b { font-weight: 500; display: block; }

/* The bento of features */
.bento { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; }
.bento .card { grid-column: span 2; min-height: 300px; align-content: space-between; overflow: hidden; }
.bento .card.w3 { grid-column: span 3; }
.bento .card.w4 { grid-column: span 4; }
.card .copy { display: grid; gap: 8px; }

.bars { display: flex; align-items: flex-end; gap: 10px; height: 104px; }
.bars i { flex: 1; display: grid; justify-items: center; gap: 6px; font-style: normal; font-size: 11px; color: var(--ink-3); font-weight: 500; }
.bars i::before { content: ''; width: 20px; border-radius: 10px; background: rgba(255, 255, 255, 0.2); height: 0; transition: height 0.9s cubic-bezier(0.2, 0.7, 0.2, 1); transition-delay: calc(var(--n) * 70ms); }
.in .bars i::before { height: var(--h); }
.bars i.now::before { background: #fff; }
.bars i.now { color: #fff; }

.cal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px 0; font-size: 13px; text-align: center; font-weight: 500; }
.cal span { display: grid; gap: 1px; justify-items: center; min-height: 34px; align-content: end; }
.cal em { font-style: normal; font-size: 10px; height: 12px; line-height: 12px; }
.cal .h { color: var(--ink-3); min-height: 0; font-size: 11px; }
.cal .g em { color: #7cd4ff; }
.cal .b em { color: #ffd36e; }

.dates { display: grid; gap: 0; }
.dates div { display: flex; gap: 16px; padding: 12px 0; align-items: center; }
.dates div + div { border-top: 1px solid rgba(255, 255, 255, 0.12); }
.dates b { font-family: 'Caslon', Georgia, serif; font-weight: 400; font-size: 30px; width: 40px; text-align: center; line-height: 1; }
.dates small { color: var(--ink-3); display: block; font-size: 12px; }
.pill { display: inline-flex; align-self: start; height: 34px; align-items: center; padding: 0 14px; border-radius: 999px; background: #fff; color: #14101e; font-size: 13px; font-weight: 500; width: max-content; }

.meter { display: grid; gap: 12px; }
.meter div { display: flex; justify-content: space-between; align-items: center; font-size: 14px; font-weight: 500; }
.meter i { display: flex; gap: 3px; }
.meter i u { width: 5px; height: 18px; border-radius: 3px; background: rgba(255, 255, 255, 0.22); }
.meter i u.on { background: #fff; }

.wheel { width: 100%; max-width: 280px; margin: 0 auto; display: block; }
.wheel .turn { transform-origin: 150px 150px; animation: spin 180s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Ask Aura */
.ask { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 48px; align-items: center; }
.orb { width: 132px; height: 132px; border-radius: 50%; position: relative; background: #07062b; overflow: hidden; box-shadow: 0 0 60px rgba(195, 79, 208, 0.22), inset 0 0 0 1px rgba(255, 255, 255, 0.06); }
.orb::before, .orb::after { content: ''; position: absolute; width: 90%; height: 90%; border-radius: 50%; filter: blur(16px); }
.orb::before { left: -34%; top: -34%; background: #4fc3d9; animation: wanderA 7s ease-in-out infinite alternate; }
.orb::after { right: -30%; bottom: -44%; background: #c34fd0; animation: wanderB 9s ease-in-out infinite alternate; }
@keyframes wanderA { to { transform: translate(14%, 10%) scale(1.15, 0.9); } }
@keyframes wanderB { to { transform: translate(-16%, -8%) scale(0.9, 1.2); } }
.chat { background: var(--sheet); border-radius: 36px; padding: 28px; display: grid; gap: 16px; min-height: 330px; align-content: start; }
.chat .who { display: flex; align-items: center; gap: 12px; }
.chat .who .orb { width: 38px; height: 38px; box-shadow: none; }
.chat .who .orb::before, .chat .who .orb::after { filter: blur(6px); }
.chat .who small { display: block; color: var(--ink-3); font-size: 13px; }
.chat .q { justify-self: end; background: rgba(255, 255, 255, 0.14); border-radius: 22px 22px 6px 22px; padding: 12px 18px; color: #fff; }
.chat .a { color: #fff; font-size: 18px; line-height: 1.5; min-height: 5.2em; }
.chat .dots { display: inline-flex; gap: 5px; }
.chat .dots i { width: 7px; height: 7px; border-radius: 50%; background: #fff; animation: blink 1s infinite; }
.chat .dots i:nth-child(2) { animation-delay: 0.2s; }
.chat .dots i:nth-child(3) { animation-delay: 0.4s; }
@keyframes blink { 0%, 100% { opacity: 0.25; } 40% { opacity: 1; } }

/* The closing call */
.finale { position: relative; overflow: hidden; border-radius: 44px; padding: 96px 32px; text-align: center; display: grid; gap: 24px; justify-items: center; background: var(--base); }
.finale::before { content: ''; position: absolute; inset: 0; background:
    radial-gradient(50% 80% at 15% 20%, var(--a), transparent 70%),
    radial-gradient(50% 80% at 85% 30%, var(--b), transparent 70%),
    radial-gradient(60% 60% at 50% 110%, var(--c), transparent 75%); }
.finale > * { position: relative; }
.finale h2 { font-size: clamp(44px, 7vw, 84px); }
.finale p { color: #fff; }

@media (max-width: 820px) {
  .you, .ask { grid-template-columns: 1fr; }
  .bento { grid-template-columns: 1fr; }
  .bento .card, .bento .card.w3, .bento .card.w4 { grid-column: auto; }
  .reading { padding: 28px; min-height: 320px; }
  .phone { --ry: 0deg; --rx: 0deg; }
  .finale { padding: 64px 22px; border-radius: 32px; }
}
@media (prefers-reduced-motion: reduce) {
  .reveal, .hero h1 span { opacity: 1; transform: none; animation: none; transition: none; }
  .ribbon div, .wheel .turn, .orb::before, .orb::after { animation: none; }
  .phone { transform: none; }
}

/* The hero fills the first screen, with its content centred in the space under the top bar. */
.hero > .wrap { min-height: calc(100vh - 72px); display: flex; flex-direction: column; }
.hero .hero-grid { flex: 1; padding-top: 24px; }

/* ── Second pass ─────────────────────────────────────────────────────────── */
/* Living colour: a small canvas stretched over its box and painted by landing.js. */
.glow { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.reading::before, .finale::before, .screen::before { content: none; }
.reading > *:not(.glow), .finale > *:not(.glow), .member > *:not(.glow) { position: relative; }
.screen::after { content: ''; position: absolute; inset: 55% 0 0; background: linear-gradient(to bottom, transparent, var(--base) 78%); pointer-events: none; }
.screen > .glow { position: absolute; }

/* The phone, matched to the app: its own Moon, its reading card, its tab bar. */
.moon { position: absolute !important; right: 8px; top: 138px; width: 104px; height: 104px; background: none; box-shadow: none; border-radius: 0; }
.days i.lock::after { content: ''; position: absolute; right: -2px; top: 19px; width: 11px; height: 11px; border-radius: 50%; background: #3a2f7a url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 10'%3E%3Crect x='2.6' y='4.6' width='4.8' height='3.6' rx='.8' fill='%23fff'/%3E%3Cpath d='M3.6 4.6V3.6a1.4 1.4 0 0 1 2.8 0v1' fill='none' stroke='%23fff' stroke-width='.9'/%3E%3C/svg%3E") center/7px no-repeat; }
.days i { position: relative; }
.days i.lock { color: rgba(255, 255, 255, 0.74); }
.days i.lock::before { opacity: 0.6; }
.s-word { margin-top: 18px; }
.s-line { margin-top: 10px; }
.s-card { margin: 18px -6px 0; padding: 16px 16px 14px; gap: 7px; z-index: 1; }
.s-top { display: flex; align-items: center; gap: 8px; font-size: 10px; font-weight: 500; }
.s-tag { padding: 4px 10px; border-radius: 999px; background: rgba(255, 255, 255, 0.14); }
.s-stars { letter-spacing: 2px; }
.s-stars u { text-decoration: none; opacity: 0.25; }
.s-count { margin-left: auto; color: var(--ink-3); }
.s-foot { display: flex; align-items: center; gap: 16px; margin-top: 6px; }
.s-dots { display: flex; gap: 4px; margin-right: auto; align-items: center; }
.s-dots i { width: 4px; height: 4px; border-radius: 50%; background: rgba(255, 255, 255, 0.35); }
.s-dots i:first-child { width: 14px; border-radius: 3px; background: #fff; }
img.s-bar { position: absolute; left: 12px; right: 12px; bottom: 14px; width: calc(100% - 24px); height: auto; padding: 0; background: none; border-radius: 0; z-index: 2; }

/* The app's three day marks, as drawings. */
[data-mark] { display: inline-flex; vertical-align: -1px; margin-right: 6px; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 18px; }
.cal em { display: grid; place-items: center; }

/* Plans */
.plans { display: grid; grid-template-columns: 0.8fr 1.2fr; gap: 16px; align-items: stretch; }
.free { align-content: start; }
.member { position: relative; overflow: hidden; border-radius: 36px; padding: 36px; display: grid; gap: 14px; background: var(--base); align-content: start; }
.member-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.switch { display: flex; background: rgba(5, 1, 45, 0.55); border-radius: 999px; padding: 4px; }
.switch button { font: inherit; font-size: 14px; font-weight: 500; color: #fff; background: none; border: 0; height: 38px; padding: 0 18px; border-radius: 999px; cursor: pointer; display: inline-flex; align-items: center; gap: 8px; transition: background 0.25s, color 0.25s; }
.switch button[aria-pressed='true'] { background: #fff; color: #14101e; }
.switch em { font-style: normal; font-size: 11px; padding: 3px 8px; border-radius: 999px; background: rgba(20, 16, 30, 0.12); }
.switch button[aria-pressed='false'] em { background: rgba(255, 255, 255, 0.16); }
.cost { color: #fff; font-size: 18px; }
.cost .price { font-size: clamp(64px, 9vw, 96px); }
.perks { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 8px 0 6px; }
.perks span { background: rgba(5, 1, 45, 0.5); border-radius: 18px; padding: 14px 16px; font-size: 15px; font-weight: 500; color: #fff; }
.member .button { justify-self: start; }
@media (max-width: 820px) { .plans, .perks { grid-template-columns: 1fr; } .member { padding: 26px; border-radius: 30px; } }
.reading > .glyph:not(.glow) { position: absolute; }
.moon { top: 150px; right: 10px; width: 92px; height: 92px; }
/* The fade at the bottom of the phone screen sits under the words, not over them. */
.screen::after { z-index: 0; }
.screen > *:not(.glow) { z-index: 1; }

/* Each perk has its icon in a small round badge, as on the app's unlock sheet. */
.perks span { display: flex; align-items: center; gap: 12px; padding: 12px 14px; }
.perks i { flex: none; width: 34px; height: 34px; border-radius: 50%; background: rgba(255, 255, 255, 0.12); display: grid; place-items: center; }

/* ── The phone, third pass: no frame, no tilt, a status bar, a little wider ── */
.phone { width: 330px; padding: 0; background: none; border-radius: 44px; transform: none !important; transition: none; box-shadow: 0 40px 90px rgba(0, 0, 0, 0.45); }
.screen { border-radius: 44px; padding: 14px 20px 0; }
.s-status { display: flex; align-items: center; justify-content: space-between; height: 30px; padding: 0 8px 0 14px; font-size: 13px; margin-bottom: 6px; }
.s-status b { font-weight: 600; width: 66px; }
.s-status .island { width: 92px; height: 27px; border-radius: 14px; background: #000; }
.s-status span { display: flex; gap: 5px; align-items: center; width: 66px; justify-content: flex-end; }
.s-ask { font-family: 'Caslon', Georgia, serif; font-size: 17px; display: inline-flex; align-items: baseline; gap: 4px; color: #fff; }
.s-ask img { height: 15px; width: auto; }
.moon { top: 176px; right: 14px; width: 98px; height: 98px; }
.s-head .s-ask { font-size: 17px; color: #fff; }

/* ── Fourth pass ─────────────────────────────────────────────────────────── */
/* Smooth colour: the canvases are painted with more detail and softened by the browser, so no lines or steps show. */
.glow, #sky { filter: blur(22px); transform: scale(1.12); }
.reading, .finale, .member { isolation: isolate; }

/* Two real screenshots, one behind the other. */
.shots { position: relative; height: 640px; }
.shot { position: absolute; margin: 0; width: 290px; border-radius: 42px; overflow: hidden; box-shadow: 0 40px 90px rgba(0, 0, 0, 0.5); }
.shot img { width: 100%; height: auto; display: block; }
.shot .island { position: absolute; top: 9px; left: 50%; width: 84px; height: 25px; margin-left: -42px; border-radius: 13px; background: #000; }
.shot.front { left: 0; top: 0; z-index: 1; }
.shot.back { right: 0; top: 56px; width: 250px; border-radius: 36px; opacity: 0.92; }
.shot.back .island { top: 8px; width: 72px; height: 22px; margin-left: -36px; }

/* "Ask" followed by the logo, on one line. */
.with-logo img { display: inline-block; height: 0.8em; width: auto; vertical-align: -0.02em; margin-left: 0.12em; }
.chat-logo { height: 24px; width: auto; display: block; margin-bottom: 2px; }

/* The week card: marks above the days, close to the words under them. */
.bento .card { align-content: start; gap: 28px; }
.bars { height: 124px; }
.bars i::before { content: none; }
.bars em { height: 14px; display: grid; place-items: center; font-style: normal; }
.bars u { width: 20px; border-radius: 10px; background: rgba(255, 255, 255, 0.2); height: 0; text-decoration: none; transition: height 0.9s cubic-bezier(0.2, 0.7, 0.2, 1); transition-delay: calc(var(--n) * 70ms); }
.in .bars u { height: var(--h); }
.bars i.now u { background: #fff; }

@media (max-width: 820px) {
  .shots { height: 560px; max-width: 360px; margin: 0 auto; width: 100%; }
  .shot { width: 240px; }
  .shot.back { width: 200px; top: 48px; }
}
/* The hero is only as tall as what is in it. */
.hero { min-height: 0; padding-bottom: 32px; }
.hero > .wrap { min-height: 0; }
.hero .hero-grid { padding-top: 40px; }
#sky { height: 900px; }
/* The sign's dates sit at the top left of its card, level with the symbol. */
.reading > #y-dates:not(.glow) { position: absolute; top: 40px; left: 40px; margin: 0; }
@media (max-width: 820px) { .reading > #y-dates:not(.glow) { top: 28px; left: 28px; } }
/* Sign chips: hovering lightens the chip a little. Nothing moves. */
.signs button:hover { transform: none; background: rgba(255, 255, 255, 0.16); }
.signs button[aria-pressed='true']:hover { background: #fff; }
