/* ==========================================================================
   StudyLoop — download page
   The same tokens as the app (css/theme.css), so the page is the app's colour,
   theme and accent. This one scrolls, unlike the app window.
   ========================================================================== */

html, body { height: auto; overflow: auto; }

body {
  background: var(--bg);
  font-size: 15px;
}

/* The only decoration on the page: one soft accent wash behind the top. */
.glow {
  position: absolute;
  inset: 0 0 auto 0;
  height: 640px;
  background: radial-gradient(58% 62% at 50% 0%, var(--accent-soft), transparent 72%);
  pointer-events: none;
  z-index: 0;
}

.site {
  position: relative;
  z-index: 1;
  max-width: 1020px;
  margin: 0 auto;
  padding: 0 28px 88px;
}

/* ── nav ─────────────────────────────────────────────────────────────── */
.nav {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 24px 0 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
}
.brand:hover { text-decoration: none; }

.brand__mark { width: 28px; height: 28px; flex: none; }

.brand__name {
  font-size: 14.5px;
  font-weight: 650;
  letter-spacing: -.01em;
}

.nav__links {
  margin-left: auto;
  display: flex;
  gap: 24px;
  font-size: 13px;
}
.nav__links a { color: var(--text-2); }
.nav__links a:hover { color: var(--text); text-decoration: none; }

.nav__cta {
  margin-left: 6px;
  padding: 7px 14px;
  border-radius: var(--r-pill);
  border: 1px solid var(--rule-strong);
  background: var(--sunken);
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text);
}
.nav__cta:hover { border-color: var(--accent); color: var(--accent-text); text-decoration: none; }

/* ── hero ────────────────────────────────────────────────────────────── */
.hero {
  padding: 76px 0 0;
  max-width: 740px;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 11px;
  border-radius: var(--r-pill);
  border: 1px solid var(--rule-strong);
  background: var(--sunken);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--text-2);
}

.hero h1 {
  margin-top: 20px;
  font-family: var(--font-serif);
  font-size: clamp(40px, 6.2vw, 62px);
  font-weight: 400;
  line-height: 1.02;
  letter-spacing: -.024em;
}

.hero__sub {
  margin-top: 20px;
  max-width: 560px;
  font-size: 16px;
  line-height: 1.62;
  color: var(--text-2);
}
.hero__sub strong { color: var(--text); font-weight: 600; }

.actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 30px;
}

.ico {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.btn-dl {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  height: 46px;
  padding: 0 22px;
  border-radius: var(--r-md);
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 14.5px;
  font-weight: 600;
  transition: filter var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.btn-dl:hover { filter: brightness(1.1); text-decoration: none; }
.btn-dl:active { transform: translateY(1px); }

.btn-alt {
  display: inline-flex;
  align-items: center;
  height: 46px;
  padding: 0 19px;
  border-radius: var(--r-md);
  border: 1px solid var(--rule-strong);
  background: var(--sunken);
  color: var(--text);
  font-size: 14.5px;
  font-weight: 550;
}
.btn-alt:hover { border-color: var(--text-3); text-decoration: none; }

.facts {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 18px;
  font-size: 12px;
  color: var(--text-3);
}
.facts li + li::before {
  content: "·";
  margin-right: 8px;
  color: var(--rule-strong);
}

/* ── the window, shown small ────────────────────────────────────────── */
.frame {
  margin-top: 58px;
  padding: 1px;
  border-radius: calc(var(--r-lg) + 2px);
  background: linear-gradient(180deg, var(--rule-strong), var(--rule) 60%, transparent);
}

.mock {
  border-radius: var(--r-lg);
  background: var(--chrome);
  overflow: hidden;
  box-shadow: var(--shadow-2);
}

.mock__bar {
  display: flex;
  align-items: center;
  gap: 7px;
  height: 34px;
  padding: 0 13px;
  border-bottom: 1px solid var(--rule);
  background: var(--rail);
}
.mock__bar i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--rule-strong);
}
.mock__bar span {
  margin-left: 9px;
  font-size: 10.5px;
  color: var(--text-3);
}

.mock__body {
  display: grid;
  grid-template-columns: 50px 164px minmax(0, 1fr) 154px;
  height: 336px;
}

.mock__rail {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 13px 0;
  background: var(--rail);
  border-right: 1px solid var(--rule);
}
.mock__logo {
  width: 20px;
  height: 20px;
  border-radius: 7px;
  background: var(--accent);
  opacity: .9;
}
.mock__dot {
  width: 17px;
  height: 17px;
  border-radius: 6px;
  background: var(--sunken);
}
.mock__dot.on { background: var(--accent-soft); box-shadow: inset 0 0 0 1px var(--accent-ring); }
.mock__spacer { flex: 1; }

.mock__side {
  padding: 13px 9px;
  border-right: 1px solid var(--rule);
  background: var(--chrome);
  overflow: hidden;
}

.mock__head {
  margin: 0 0 6px 6px;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--text-3);
}
.mock__head + .mock__head { margin-top: 15px; }

.mock__row {
  display: flex;
  align-items: center;
  gap: 6px;
  height: 24px;
  padding: 0 7px;
  border-radius: var(--r-xs);
  font-size: 11.5px;
  color: var(--text-2);
}
.mock__row.on { background: var(--sunken); color: var(--text); font-weight: 550; }
.mock__row b { margin-left: auto; font-size: 9.5px; font-weight: 600; color: var(--accent-text); }

.mock__main {
  display: flex;
  flex-direction: column;
  gap: 11px;
  padding: 14px 15px;
  background: var(--bg);
  overflow: hidden;
}
.mock__title {
  display: flex;
  align-items: baseline;
  gap: 9px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--rule);
  font-size: 12.5px;
  font-weight: 650;
}
.mock__title span { font-size: 10px; font-weight: 400; color: var(--text-3); }

.mock__note { display: flex; gap: 9px; }

.mock__av {
  width: 25px;
  height: 25px;
  flex: none;
  display: grid;
  place-items: center;
  border-radius: var(--r-sm);
  background: hsl(var(--h) 40% 26%);
  color: hsl(var(--h) 60% 82%);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: .02em;
}

.mock__text { min-width: 0; font-size: 11.5px; line-height: 1.45; }
.mock__who { font-size: 11.5px; font-weight: 650; }
.mock__time { margin-left: 4px; font-size: 9.5px; color: var(--text-3); }
.mock__text p { margin-top: 2px; font-size: 11.5px; color: var(--text-2); }

.mock__pill {
  display: inline-block;
  margin-top: 5px;
  padding: 2px 6px;
  border-radius: var(--r-xs);
  border: 1px solid var(--rule);
  background: var(--sunken);
  font-size: 9px;
  color: var(--text-3);
}

.mock__composer {
  margin-top: auto;
  display: flex;
  align-items: center;
  height: 30px;
  padding: 0 11px;
  border-radius: var(--r-sm);
  border: 1px solid var(--rule-strong);
  background: var(--sunken);
  font-size: 11px;
  color: var(--text-3);
}

.mock__panel {
  padding: 13px 11px;
  border-left: 1px solid var(--rule);
  background: var(--chrome);
  overflow: hidden;
}
.mock__person {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 29px;
  font-size: 11px;
  color: var(--text-2);
}
.mock__person .mock__av { width: 20px; height: 20px; font-size: 8px; border-radius: var(--r-xs); }

/* ── sections ───────────────────────────────────────────────────────── */
.section { margin-top: 88px; }

.section__head { max-width: 640px; }

.eyebrow {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: .11em;
  text-transform: uppercase;
  color: var(--accent-text);
}

.section__head h2 {
  margin-top: 12px;
  font-family: var(--font-serif);
  font-size: 30px;
  font-weight: 400;
  line-height: 1.15;
  letter-spacing: -.016em;
}

.section__head p {
  margin-top: 10px;
  font-size: 14.5px;
  line-height: 1.6;
  color: var(--text-2);
}

/* ── the two apps ───────────────────────────────────────────────────── */
.apps {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-top: 26px;
}

.appcard {
  display: flex;
  gap: 15px;
  padding: 20px;
  border: 1px solid var(--rule);
  border-radius: var(--r-md);
  background: var(--chrome);
  transition: border-color var(--dur) var(--ease);
}
.appcard:hover { border-color: var(--rule-strong); }

.appcard--guard {
  background: linear-gradient(180deg, var(--accent-soft), transparent 60%), var(--chrome);
}

.appcard__icon {
  width: 52px;
  height: 52px;
  flex: none;
  border-radius: 16px;
}

.appcard__icon--key {
  display: grid;
  place-items: center;
  background: var(--sunken);
  border: 1px solid var(--rule-strong);
  color: var(--accent-text);
}
.appcard__icon--key svg {
  width: 26px;
  height: 26px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.appcard__body { min-width: 0; }

.appcard h3 {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  font-size: 14.5px;
  font-weight: 650;
  letter-spacing: -.005em;
}

.tag {
  padding: 2px 7px;
  border-radius: var(--r-pill);
  border: 1px solid var(--rule-strong);
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: .05em;
  text-transform: uppercase;
  color: var(--text-3);
}

.appcard p {
  margin-top: 8px;
  font-size: 12.5px;
  line-height: 1.6;
  color: var(--text-2);
}

.ticks { margin-top: 12px; display: flex; flex-direction: column; gap: 6px; }

.ticks li {
  position: relative;
  padding-left: 19px;
  font-size: 12px;
  line-height: 1.5;
  color: var(--text-2);
}
.ticks li::before {
  content: "";
  position: absolute;
  left: 3px;
  top: 6px;
  width: 8px;
  height: 4px;
  border-left: 1.6px solid var(--accent);
  border-bottom: 1.6px solid var(--accent);
  transform: rotate(-45deg);
}

/* ── the key ───────────────────────────────────────────────────────── */
.keys {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 26px;
}

.key {
  display: grid;
  place-items: center;
  min-width: 40px;
  height: 40px;
  padding: 0 11px;
  border-radius: var(--r-md);
  border: 1px solid var(--rule-strong);
  border-bottom-width: 2px;
  background: var(--sunken);
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
}

.keys__label {
  margin-left: 8px;
  font-size: 12px;
  color: var(--text-3);
}

.guard {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-top: 26px;
}

.guard li {
  display: flex;
  gap: 12px;
  padding: 18px;
  border: 1px solid var(--rule);
  border-radius: var(--r-md);
  background: var(--chrome);
}

.guard__n {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  flex: none;
  border-radius: 50%;
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 11px;
  font-weight: 700;
}

.guard h3 { font-size: 13px; font-weight: 650; }
.guard p { margin-top: 6px; font-size: 12px; line-height: 1.55; color: var(--text-2); }
.guard em { color: var(--text); font-style: normal; font-weight: 550; }

.fine {
  max-width: 640px;
  margin-top: 18px;
  font-size: 12px;
  line-height: 1.6;
  color: var(--text-3);
}
.fine code { font-size: 11px; }

/* ── install ───────────────────────────────────────────────────────── */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-top: 26px;
}

.step {
  padding: 18px;
  border: 1px solid var(--rule);
  border-radius: var(--r-md);
  background: var(--sunken);
}

.step__n {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  margin-bottom: 11px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 11px;
  font-weight: 700;
}

.step h3 { font-size: 13px; font-weight: 650; }
.step p { margin-top: 6px; font-size: 12px; line-height: 1.55; color: var(--text-2); }
.step strong { color: var(--text); font-weight: 600; }

.notice {
  margin-top: 18px;
  padding: 17px 18px;
  border: 1px solid var(--rule-strong);
  border-left: 2px solid var(--warn);
  border-radius: var(--r-md);
  background: var(--chrome);
}

.notice strong { font-size: 12.5px; font-weight: 650; }
.notice p { margin-top: 7px; font-size: 12.5px; line-height: 1.55; color: var(--text-2); }
.notice .fine { margin-top: 8px; }

.cmd {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  padding: 9px 10px;
  border-radius: var(--r-sm);
  border: 1px solid var(--rule);
  background: var(--code);
}

.cmd code {
  flex: 1;
  min-width: 0;
  padding: 0;
  background: none;
  font-size: 11.5px;
  color: var(--text);
  white-space: nowrap;
  overflow-x: auto;
}

.cmd--block { display: block; padding: 13px 15px; }
.cmd--block code { white-space: pre; font-size: 12.5px; }

.copy {
  flex: none;
  padding: 4px 9px;
  border-radius: var(--r-xs);
  border: 1px solid var(--rule-strong);
  background: var(--raise);
  font-size: 11px;
  font-weight: 550;
  color: var(--text-2);
}
.copy:hover { border-color: var(--text-3); color: var(--text); }

/* ── footer ────────────────────────────────────────────────────────── */
.foot {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
  margin-top: 84px;
  padding-top: 24px;
  border-top: 1px solid var(--rule);
  font-size: 12px;
  color: var(--text-3);
}
.foot a { color: var(--text-3); }
.foot a:hover { color: var(--text); text-decoration: none; }

.foot__mark {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-2);
  font-weight: 550;
}

.foot__right { margin-left: auto; }

/* ── narrow windows ────────────────────────────────────────────────── */
@media (max-width: 940px) {
  .apps, .guard, .steps { grid-template-columns: 1fr; }
  .mock__body { grid-template-columns: 46px 150px minmax(0, 1fr); }
  .mock__panel { display: none; }
  .hero { padding-top: 54px; }
  .nav__links { display: none; }
  .nav__cta { margin-left: auto; }
}

@media (max-width: 620px) {
  .site { padding: 0 18px 60px; }
  .mock__body { grid-template-columns: 44px minmax(0, 1fr); }
  .mock__side { display: none; }
  .actions { flex-wrap: wrap; }
  .foot__right { margin-left: 0; }
}
