.hero {
  text-align: center;
  max-width: 860px;
  margin: 0 auto 40px;
  min-height: auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hero__pill {
  align-self: center;
  margin-bottom: 14px;
  animation: rise 0.5s ease backwards;
}

.hero__title {
  font-size: clamp(24px, 6vw, 46px);
  letter-spacing: -0.03em;
  line-height: 1.08;
  animation: rise 0.55s 0.08s ease backwards;
}

.hero__lead {
  max-width: 38rem;
  margin: 14px auto 0;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.5;
  animation: rise 0.55s 0.14s ease backwards;
}

.hero__banner {
  display: block;
  width: 100%;
  max-width: 860px;
  height: auto;
  margin: 18px auto 0;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-soft);
  object-fit: cover;
  object-position: center;
  aspect-ratio: 2 / 1;
  animation: screen-on 0.9s 0.15s cubic-bezier(0.2, 0.7, 0.2, 1) backwards;
}

.modes .mode:nth-child(1) {
  animation: rise 0.55s 0.32s ease backwards;
}

.modes .mode:nth-child(2) {
  animation: rise 0.55s 0.44s ease backwards;
}

.mode__emoji {
  font-size: 22px;
  line-height: 1;
}

.modes {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  margin-top: 22px;
  text-align: left;
}

.mode {
  display: flex;
  flex-direction: column;
  gap: 13px;
  transition: transform 200ms ease, border-color 200ms ease;
}

.mode:hover {
  transform: translateY(-3px);
  border-color: var(--border-strong);
}

.mode__icon {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 13px;
  background: var(--ok-soft);
  border: 1px solid var(--accent-border-mid);
  color: var(--accent);
}

.mode__icon--blue {
  background: var(--accent-2-soft);
  border-color: var(--accent-2-border);
  color: var(--accent-2);
}

.mode h2 {
  font-size: 21px;
}

.mode > p {
  color: var(--muted);
  font-size: 15px;
}

.mode__list {
  list-style: none;
  margin: 4px 0 10px;
  padding: 0;
  display: grid;
  gap: 9px;
}

.mode__list li {
  position: relative;
  padding-left: 24px;
  color: var(--muted);
  font-size: 14px;
}

.mode__list li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 7px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 10px var(--accent-glow);
}

.mode .btn {
  margin-top: auto;
}

.security,
.how {
  margin-bottom: 48px;
}

.privacy {
  margin-bottom: 48px;
}

.section-head .pill {
  margin-bottom: 12px;
}

.trust-banner {
  display: flex;
  gap: 18px;
  align-items: flex-start;
  max-width: 820px;
  margin: 0 auto 14px;
  border-color: var(--accent-border-soft);
}

.trust-banner__icon {
  flex: none;
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  font-size: 24px;
  line-height: 1;
  border-radius: 15px;
  background: var(--ok-soft);
  border: 1px solid var(--accent-border-mid);
}

.trust-banner__body h3 {
  font-size: 18px;
  margin-bottom: 6px;
}

.trust-banner__body p {
  color: var(--muted);
  font-size: 14.5px;
}

.trust-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
}

/* Each trust card carries its own soft colour so the row reads as a set
   rather than four identical panels. The colours come from the shared design
   tokens, so they follow day/night themes automatically. */
.trust {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(120% 100% at 50% -20%, var(--trust-tint), transparent 62%),
    var(--panel);
  border-color: var(--trust-border);
  transition: transform 200ms ease, border-color 200ms ease, box-shadow 200ms ease;
}

.trust:hover {
  transform: translateY(-3px);
  border-color: var(--trust-color);
  box-shadow: var(--shadow-soft);
}

.trust:nth-child(1) {
  --trust-color: var(--accent);
  --trust-tint: var(--ok-soft);
  --trust-border: var(--accent-border-mid);
}

.trust:nth-child(2) {
  --trust-color: var(--accent-2);
  --trust-tint: var(--accent-2-soft);
  --trust-border: var(--accent-2-border);
}

.trust:nth-child(3) {
  --trust-color: var(--accent-warm);
  --trust-tint: var(--accent-warm-soft);
  --trust-border: var(--accent-warm-border);
}

.trust:nth-child(4) {
  --trust-color: var(--danger);
  --trust-tint: var(--danger-soft);
  --trust-border: var(--danger-border);
}

.trust__icon {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  margin-bottom: 10px;
  border-radius: 10px;
  font-size: 17px;
  line-height: 1;
  background: var(--trust-tint);
  border: 1px solid var(--trust-border);
}

.trust h3 {
  font-size: 15.5px;
  margin-bottom: 4px;
}

.trust p {
  color: var(--muted);
  font-size: 13.5px;
}

/* Entrance reveal: the trust cards fade and rise, staggered, the first time the
   grid scrolls into view. Gated on the `js-reveal` class that landing.js sets,
   so without JavaScript the cards simply show as normal. */
.js-reveal .trust-grid:not(.is-revealed) .trust {
  opacity: 0;
}

.trust-grid.is-revealed .trust {
  animation: trust-in 620ms cubic-bezier(0.2, 0.7, 0.2, 1) backwards;
}

.trust-grid.is-revealed .trust:nth-child(2) {
  animation-delay: 90ms;
}

.trust-grid.is-revealed .trust:nth-child(3) {
  animation-delay: 180ms;
}

.trust-grid.is-revealed .trust:nth-child(4) {
  animation-delay: 270ms;
}

@keyframes trust-in {
  from {
    opacity: 0;
    transform: translateY(18px) scale(0.97);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.trust-disclosure {
  max-width: 820px;
  margin: 16px auto 0;
  padding: 18px 20px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--wash);
}

.trust-disclosure h3 {
  font-size: 14.5px;
  margin-bottom: 6px;
}

.trust-disclosure p {
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.55;
}

.section-head {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 24px;
}

.section-head h2 {
  font-size: clamp(22px, 4vw, 34px);
}

.section-head p {
  color: var(--muted);
  margin-top: 10px;
}

.feature-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
}

.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  counter-reset: step;
}

.steps li {
  display: flex;
  gap: 16px;
  padding: 22px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--step-bg);
}

.steps__num {
  flex: none;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: var(--accent-warm-soft);
  border: 1px solid var(--accent-warm-border);
  color: var(--accent-warm);
  font-size: 16px;
  line-height: 1;
}

.feature.card .feature__icon {
  font-size: 17px;
  line-height: 1;
}

.steps h3 {
  font-size: 16px;
  margin-bottom: 4px;
}

.steps p {
  color: var(--muted);
  font-size: 14px;
}

.faq {
  display: grid;
  gap: 12px;
  max-width: 760px;
  margin: 0 auto;
}

.faq details {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--step-bg);
  padding: 16px 18px;
}

.faq summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 16px;
}

.faq details p {
  color: var(--muted);
  font-size: 14.5px;
  margin-top: 10px;
}

.footer {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: space-between;
  align-items: center;
  padding-top: 26px;
  border-top: 1px solid var(--border);
  color: var(--faint);
  font-size: 13.5px;
}

.footer__links {
  display: flex;
  gap: 16px;
}

.footer__links a {
  color: var(--muted);
}

/* Legal / policy document -------------------------------------------------- */

.legal {
  max-width: 760px;
  margin: 0 auto 40px;
}

.legal__updated {
  color: var(--faint);
  font-size: 13.5px;
  margin-top: 8px;
}

.legal__lead {
  color: var(--muted);
  font-size: 15.5px;
  line-height: 1.6;
}

.legal h2 {
  font-size: 19px;
  margin: 30px 0 10px;
}

.legal p {
  color: var(--muted);
  font-size: 14.5px;
  line-height: 1.65;
}

.legal p + p {
  margin-top: 10px;
}

.legal ul {
  margin: 8px 0 0;
  padding-left: 20px;
  display: grid;
  gap: 8px;
}

.legal li {
  color: var(--muted);
  font-size: 14.5px;
  line-height: 1.6;
}

.legal strong {
  color: var(--text);
}

/* Bootstrap breakpoints: sm / md / lg / xl / xxl */

@media (min-width: 576px) {
  .hero {
    margin-bottom: 48px;
  }

  .hero__banner {
    aspect-ratio: 32 / 11;
    border-radius: var(--radius-lg);
  }

  .feature-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .trust-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }
}

@media (min-width: 768px) {
  .hero {
    min-height: calc(100vh - 200px);
    margin-bottom: 56px;
  }

  .hero--compact {
    min-height: auto;
    margin-bottom: 40px;
  }

  .downloads {
    margin-bottom: 64px;
  }

  .hero__pill {
    margin-bottom: 18px;
  }

  .hero__banner {
    margin-top: 22px;
    aspect-ratio: 32 / 9;
  }

  .modes {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
    margin-top: 28px;
  }

  .security,
  .how {
    margin-bottom: 64px;
  }

  .privacy {
    margin-bottom: 64px;
  }

  .section-head {
    margin-bottom: 30px;
  }
}

@media (min-width: 992px) {
  .feature-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
  }

  .trust-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
  }

  .feature-grid--3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .steps {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
  }
}

@media (min-width: 1200px) {
  .hero {
    max-width: 920px;
  }
}

.hero--compact {
  min-height: auto;
  margin-bottom: 36px;
}

.topbar__nav a[aria-current="page"] {
  color: var(--text);
  background: var(--wash);
}

.downloads {
  margin-bottom: 48px;
}

.download-list {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  text-align: left;
}

.download-platform {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.download-platform__head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 8px;
}

.download-platform__head h2 {
  font-size: 21px;
}

.download-platform__head p {
  color: var(--muted);
  font-size: 14.5px;
  margin-top: 4px;
}

.download-platform__copy {
  flex: 1 1 180px;
  min-width: 0;
}

.download-file {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 16px;
  padding: 16px 0;
  border-top: 1px solid var(--border);
}

.download-file__meta {
  flex: 1 1 200px;
  min-width: 0;
}

.download-file__meta h3 {
  font-size: 16px;
  margin-bottom: 3px;
}

.download-file__meta p {
  color: var(--muted);
  font-size: 13.5px;
}

.download-file__size {
  color: var(--faint);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}

.download-empty {
  color: var(--muted);
  text-align: center;
}

.download-notes code {
  font-family: var(--mono);
  font-size: 12.5px;
}

.download-qr {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 8px 0 0;
  padding-top: 14px;
  border-top: 1px solid var(--border);
}

.download-qr img {
  width: 148px;
  height: 148px;
  padding: 8px;
  background: #fff;
  border-radius: 12px;
  flex: none;
}

.download-qr figcaption {
  min-width: 0;
}

.download-qr p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.45;
}

.download-qr__title {
  color: var(--text);
  font-weight: 650;
  margin-bottom: 4px;
}

.download-platform__tip {
  margin: 0;
  padding: 12px 16px 16px;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.45;
  border-top: 1px solid var(--border);
}

.steps--install {
  max-width: 720px;
  margin: 0 auto;
  grid-template-columns: minmax(0, 1fr) !important;
}

.steps--install li {
  align-items: flex-start;
}

.steps--install .steps__num {
  flex: 0 0 auto;
}

@media (min-width: 768px) {
  .download-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
  }
}

@media (max-width: 575.98px) {
  .footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .download-file .btn {
    width: 100%;
  }
}

/* Public pages adopt the monitor width ------------------------------------ */

/* The landing, download, and privacy pages use the full window width (with a
   small side margin) instead of a centered column. The host and viewer app
   pages keep their centered layout. */
.app.app--fluid {
  max-width: none;
  box-sizing: border-box;
}

/* The hero and its banner stretch to the monitor, while long prose (the policy
   page, the FAQ, and callouts) keeps a comfortable reading measure. */
.app--fluid .hero,
.app--fluid .hero__banner {
  max-width: none;
}
