/* App pages styled like each app's own official site: a hero in the app's colour (taken from its icon)
   with the App Store badge and a phone showing the app, then features beside a second phone, a gallery
   of framed screenshots, the facts, and a closing download band. The app index lists every app as a card. */
.ofs { --app: #ff3e7f; --app-soft: #ffe3ec; --app-mid: #ffb8cd; --app-on: #15171c; --app-deep: #7a1f3d; }

/* Phone frames (portrait and landscape) */
.phone { margin: 0; position: relative; border-radius: 46px; padding: 10px; background: #15171c; box-shadow: 0 42px 70px -34px rgba(21, 23, 28, 0.6), inset 0 0 0 2px #2b2e36; }
.phone img { display: block; width: 100%; height: auto; border-radius: 36px; background: #000; }
.phone--wide { border-radius: 34px; padding: 9px; }
.phone--wide img { border-radius: 26px; }

/* Hero */
.ofs-hero { position: relative; overflow: hidden; padding: calc(var(--y-header-h) + 28px) 0 64px; background: linear-gradient(165deg, var(--app-soft) 0%, var(--app-soft) 35%, var(--y-bg) 100%); }
.ofs-hero::before { content: ""; position: absolute; right: -12vw; top: 6%; width: min(760px, 70vw); aspect-ratio: 1; border-radius: 50%; background: radial-gradient(circle at 40% 40%, var(--app-mid) 0%, transparent 68%); opacity: 0.75; pointer-events: none; }
.ofs-hero__inner { position: relative; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: clamp(28px, 5vw, 72px); align-items: center; }
.ofs-hero__icon { width: 112px; height: 112px; border-radius: 26px; margin-top: 18px; box-shadow: 0 20px 36px -22px rgba(21, 23, 28, 0.6), 0 0 0 1px rgba(21, 23, 28, 0.06); }
.ofs-hero__name { margin: 18px 0 0; font-weight: 900; font-size: clamp(2.2rem, 5.2vw, 3.7rem); line-height: 1.16; letter-spacing: -0.02em; word-break: keep-all; overflow-wrap: anywhere; }
.ofs-hero__catch { margin: 14px 0 0; max-width: 24em; font-weight: 700; font-size: clamp(1.05rem, 1.6vw, 1.3rem); line-height: 1.7; color: var(--y-ink-2); }
.ofs-chips { list-style: none; margin: 18px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.ofs-chips li { font-size: 0.82rem; font-weight: 700; padding: 3px 12px; border-radius: 999px; background: rgba(255, 255, 255, 0.75); border: 1px solid var(--y-line); }
.ofs-get { margin-top: 24px; display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; }
.ofs-badge { display: inline-block; line-height: 0; border-radius: 10px; }
.ofs-badge img { height: 52px; width: auto; }
.ofs-badge:focus-visible { outline: 3px solid var(--app-deep); outline-offset: 4px; }
.ofs-get__note { font-size: 0.85rem; color: var(--y-ink-2); font-weight: 700; }
.ofs-hero__device { display: grid; justify-items: center; }
.ofs-hero__device .phone { width: min(300px, 100%); transform: rotate(3deg); }
.ofs-hero__device .phone--wide { width: min(560px, 100%); transform: rotate(-2deg); }
.ofs--wide .ofs-hero__inner { grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); }
@media (max-width: 860px) {
  .ofs-hero { padding-bottom: 44px; }
  .ofs-hero__inner, .ofs--wide .ofs-hero__inner { grid-template-columns: 1fr; }
  .ofs-hero__icon { width: 88px; height: 88px; border-radius: 21px; }
  .ofs-hero__device .phone { width: min(240px, 70vw); }
  .ofs-hero__device .phone--wide { width: 100%; }
}
@media (prefers-reduced-motion: reduce) { .ofs-hero__device .phone { transform: none; } }

/* Section headings and the lead */
.ofs-h { margin: 0; font-weight: 900; font-size: clamp(1.6rem, 3.4vw, 2.4rem); line-height: 1.3; letter-spacing: -0.01em; }
.ofs-h::after { content: ""; display: block; width: 44px; height: 6px; margin-top: 12px; border-radius: 999px; background: var(--app); }
.ofs-intro { padding-block: clamp(52px, 7vw, 88px) 12px; max-width: 860px !important; }
.ofs-lead { margin: 22px 0 0; font-size: clamp(1.05rem, 1.5vw, 1.2rem); line-height: 2.05; font-weight: 500; }

/* Features beside a second phone */
.ofs-features { padding-block: clamp(40px, 6vw, 72px); }
.ofs-features__grid { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
.ofs-features__list ul { list-style: none; margin: 24px 0 0; padding: 0; display: grid; gap: 12px; }
.ofs-features__list li { position: relative; padding: 16px 18px 16px 50px; border-radius: 18px; background: var(--y-surface); border: 1px solid var(--y-line); line-height: 1.8; font-weight: 500; }
.ofs-features__list li::before { content: ""; position: absolute; left: 18px; top: 1.25em; width: 18px; height: 18px; border-radius: 50%; background: linear-gradient(to bottom, var(--y-surface) 0 50%, var(--app) 50%); box-shadow: 0 0 0 2px var(--y-ink); }
.ofs-facts { margin-top: 18px; padding: 16px 20px; border-radius: 18px; background: var(--app-soft); }
.ofs-facts p { margin: 0; line-height: 1.85; }
.ofs-facts p + p { margin-top: 4px; }
.ofs-features__device { position: sticky; top: calc(var(--y-header-h) + 28px); display: grid; justify-items: center; }
.ofs-features__device .phone { width: min(280px, 100%); transform: rotate(-3deg); }
.ofs--wide .ofs-features__grid { grid-template-columns: 1fr; }
.ofs--wide .ofs-features__device { position: static; order: -1; }
.ofs--wide .ofs-features__device .phone { width: min(640px, 100%); transform: none; }
@media (max-width: 860px) {
  .ofs-features__grid { grid-template-columns: 1fr; }
  .ofs-features__device { position: static; }
  .ofs-features__device .phone { width: min(230px, 66vw); }
}

/* Gallery of framed screenshots */
.ofs-gallery { padding-block: clamp(40px, 6vw, 72px); background: linear-gradient(180deg, var(--y-bg), var(--app-soft) 55%, var(--y-bg)); }
.ofs-gallery .shots { margin-top: 26px; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x proximity; scrollbar-width: thin; padding: 8px max(16px, calc((100% - 1160px) / 2)) 26px; scroll-padding-inline: max(16px, calc((100% - 1160px) / 2)); }
.ofs-gallery .shots:focus-visible { outline: 3px solid var(--app-deep); outline-offset: -3px; }
.ofs-gallery ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 22px; width: max-content; }
.ofs-gallery li { scroll-snap-align: start; }
.ofs-gallery .phone { width: clamp(190px, 22vw, 250px); }
.ofs-gallery .phone--wide { width: clamp(320px, 46vw, 560px); }

/* Facts, related articles */
.ofs-info { padding-block: clamp(44px, 6vw, 72px) 24px; max-width: 860px !important; display: grid; gap: 22px; }
.appx__info { display: grid; grid-template-columns: 8em minmax(0, 1fr); gap: 10px 18px; margin: 0; }
.appx__info dt { font-weight: 900; }
.appx__info dd { margin: 0; color: var(--y-ink-2); }
.appx__info a, .appx__related a { color: var(--y-ink); font-weight: 700; text-decoration-color: var(--app); text-decoration-thickness: 2px; text-underline-offset: 4px; }
.appx__asof { margin: 0; font-size: 0.82rem; color: var(--y-muted); line-height: 1.7; }
.appx__related h3 { margin: 6px 0 8px; font-weight: 900; font-size: 1.1rem; }
.appx__related ul { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--y-line); }
.appx__related li { border-bottom: 1px solid var(--y-line); }
.appx__related a { display: block; padding: 12px 2px; line-height: 1.6; }
@media (max-width: 560px) { .appx__info { grid-template-columns: 1fr; gap: 2px; } .appx__info dd { margin-bottom: 10px; } }

/* Closing download band */
.ofs-final { margin-top: clamp(32px, 5vw, 56px); padding-block: clamp(48px, 7vw, 84px); background: var(--app-soft); text-align: center; }
.ofs-final__inner { display: grid; justify-items: center; gap: 12px; }
.ofs-final__icon { width: 96px; height: 96px; border-radius: 22px; box-shadow: 0 18px 32px -20px rgba(21, 23, 28, 0.6); }
.ofs-final__name { margin: 6px 0 0; font-weight: 900; font-size: clamp(1.5rem, 3.2vw, 2.2rem); line-height: 1.3; word-break: keep-all; overflow-wrap: anywhere; }
.ofs-final__catch { margin: 0 0 8px; color: var(--y-ink-2); font-weight: 700; max-width: 26em; line-height: 1.7; }
.ofs-more { padding-top: clamp(40px, 6vw, 64px); }
.ofs-more .ofs-h { margin-bottom: 4px; }

/* App index */
.apps-index { padding: calc(var(--y-header-h) + 44px) 0 80px; }
.apps-index h1 { margin: 0; font-weight: 900; font-size: clamp(2.2rem, 5vw, 3.2rem); line-height: 1.2; letter-spacing: -0.02em; }
.apps-index .lede { margin: 12px 0 0; color: var(--y-ink-2); max-width: 36em; }
.apps-index section { margin-top: 48px; }
.apps-index h2 { margin: 0; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; font-weight: 900; font-size: 1.4rem; }
.apps-grid { list-style: none; margin: 18px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.app-card { display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 14px; align-items: center; height: 100%; padding: 14px 16px; border-radius: 20px; background: linear-gradient(120deg, var(--card-soft, var(--y-surface)) 0%, var(--y-surface) 55%); border: 1px solid rgba(21, 23, 28, 0.07); box-shadow: var(--y-shadow); color: var(--y-ink); text-decoration: none; transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1); }
.app-card:hover { transform: translateY(-3px); }
.app-card:active { transform: translateY(-1px) scale(0.99); }
.app-card img { width: 64px; height: 64px; border-radius: 15px; box-shadow: 0 0 0 1px rgba(21, 23, 28, 0.06); }
.app-card .n { font-weight: 900; font-size: 0.98rem; line-height: 1.45; }
.app-card .c { display: block; margin-top: 2px; font-size: 0.82rem; color: var(--y-ink-2); line-height: 1.6; }
.app-card .p { display: inline-block; margin-top: 6px; font-size: 0.74rem; font-weight: 700; padding: 1px 10px; border-radius: 999px; background: var(--y-surface); border: 1px solid var(--y-line); }
@media (prefers-reduced-motion: reduce) { .app-card:hover { transform: none; } }
