/* /app: the page with the explanation and the screenshots. Colours come from
   the tokens on :root (src/layouts/Base.astro); nothing here is hard-coded
   except the device frames. The Mac screenshot is a real window with its own
   rounded corners, so the "frame" is only a shadow that follows its outline.
   The phone is a rounded rectangle with a dark rim, drawn here, no Apple art. */

.app-page {
  max-width: 1120px;
  margin: 0 auto;
  padding: 24px 16px 16px;
}
@media (min-width: 768px) {
  .app-page {
    padding: 48px 32px 24px;
  }
}

.app-page h1,
.app-page h2 {
  margin: 0;
  color: var(--text1);
  letter-spacing: -0.03em;
}

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

.ap-hero {
  display: grid;
  gap: 32px;
  align-items: center;
  padding-bottom: 48px;
}
@media (min-width: 900px) {
  .ap-hero {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    gap: 48px;
    padding-bottom: 80px;
  }
}

.ap-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 18px;
}
.ap-brand img {
  border-radius: 14px;
  display: block;
  box-shadow: var(--shadow-md);
}
.ap-brand h1 {
  font-size: 34px;
  font-weight: 780;
}
.ap-lead {
  margin: 0 0 24px;
  font-size: 19px;
  line-height: 1.5;
  color: var(--text2);
  text-wrap: balance;
}

/* ---- Feature blocks ---------------------------------------------------- */

.ap-feature {
  display: grid;
  gap: 24px;
  align-items: center;
  padding: 40px 0;
  border-top: 1px solid var(--border);
}
@media (min-width: 900px) {
  .ap-feature {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    gap: 56px;
    padding: 64px 0;
  }
  .ap-feature[data-flip] {
    grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  }
  .ap-feature[data-flip] .ap-feature-text {
    order: 2;
  }
}

.ap-feature h2 {
  font-size: 28px;
  font-weight: 760;
  margin-bottom: 12px;
}
.ap-feature p {
  margin: 0 0 12px;
  font-size: 16.5px;
  line-height: 1.6;
  color: var(--text3);
  max-width: 52ch;
}

/* ---- Screenshots: a Mac window with an iPhone in front of it ----------- */

.ap-shot {
  position: relative;
  /* room for the phone that hangs over the bottom corner of the window */
  padding-bottom: 6%;
  padding-right: 4%;
}
.ap-mac {
  display: block;
  width: 100%;
  height: auto;
  filter: drop-shadow(0 18px 28px rgba(60, 40, 15, 0.22)) drop-shadow(0 2px 4px rgba(60, 40, 15, 0.12));
}
.ap-phone {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 24%;
  padding: 1.1%;
  background: var(--ink);
  border-radius: clamp(14px, 4.4vw, 34px);
  box-shadow: var(--shadow-lg), inset 0 0 0 1px rgba(255, 255, 255, 0.18);
}
.ap-phone img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: clamp(10px, 3.4vw, 26px);
}
@media (max-width: 599px) {
  /* The window is small on a phone: the iPhone gets a bigger share of it. */
  .ap-phone {
    width: 32%;
  }
}
@media (min-width: 900px) {
  .ap-phone {
    border-radius: 30px;
    padding: 7px;
  }
  .ap-phone img {
    border-radius: 23px;
  }
}

/* ---- One purchase and the closing -------------------------------------- */

.ap-purchase {
  margin-top: 8px;
  padding: 40px 24px;
  text-align: center;
  background: var(--card);
  border: 1px solid var(--border2);
  border-radius: 24px;
  box-shadow: var(--shadow-md);
}
.ap-purchase h2 {
  font-size: 28px;
  font-weight: 760;
  margin-bottom: 10px;
}
.ap-purchase p {
  margin: 0 auto;
  max-width: 46ch;
  font-size: 17px;
  line-height: 1.6;
  color: var(--text3);
  text-wrap: balance;
}

.ap-closing {
  padding: 40px 0 24px;
  text-align: center;
}
.ap-disclaimer {
  margin: 20px 0 0;
  font-size: 13.5px;
  color: var(--text4);
}
