/*
  "Quiet Ledger" — shared design system for all AbeFlutter app support sites.
  Warm ivory palette, Newsreader serif display type, Public Sans body type,
  brass accent, hairline rules. One consistent visual identity across apps.
*/

:root {
  --bg: #faf7f1;
  --surface: #ffffff;
  --surface-raised: #f1ebdf;
  --ink: #2a2620;
  --ink-muted: #7a7264;
  --accent: #a67a3d;
  --hairline: #e1d8c6;

  --font-display: 'Newsreader', serif;
  --font-body: 'Public Sans', sans-serif;

  --content-width: 1120px;
  --content-width-narrow: 820px;
  --content-width-article: 760px;

  --space-1: 0.5rem;
  --space-2: 1rem;
  --space-3: 1.5rem;
  --space-4: 2.5rem;
  --space-5: 4rem;
  --space-6: 6rem;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--ink); text-decoration: none; }
a:hover { color: var(--accent); }
a:focus-visible, button:focus-visible, summary:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
img { max-width: 100%; height: auto; display: block; }
strong { font-weight: 600; }

.shell {
  width: 100%;
  max-width: var(--content-width);
  margin: 0 auto;
  padding: 0 40px;
}
.shell--narrow { max-width: var(--content-width-narrow); }
.shell--article { max-width: var(--content-width-article); }

/* ---- Eyebrow label ---- */

.eyebrow {
  font: italic 500 13px var(--font-display);
  letter-spacing: 0.06em;
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin: 0 0 14px;
}
.eyebrow--left { justify-content: flex-start; }
.eyebrow::before,
.eyebrow--left::after {
  content: "";
  width: 22px;
  height: 1px;
  background: var(--accent);
  flex: none;
}
.eyebrow--left::before { display: none; }
.eyebrow--center::before { display: block; }

.section-heading {
  font: 400 34px var(--font-display);
  text-align: center;
  margin: 0 0 48px;
}

.home-intro {
  padding-top: 72px !important;
  padding-bottom: 0 !important;
}
.home-intro__title {
  font: 400 44px/1.2 var(--font-display);
  letter-spacing: -0.01em;
  margin: 0 0 12px;
}
.home-intro__lead {
  margin: 0;
  max-width: 28rem;
  color: var(--ink-muted);
  font: 400 17px/1.6 var(--font-body);
}
.home-section-title {
  text-align: left !important;
  margin-bottom: 28px !important;
  font-size: 22px !important;
}
.home-contact {
  margin: 0;
  font: 400 16px var(--font-body);
}
.home-contact a {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.home-contact a:hover { color: var(--accent); }

/* ---- Header ---- */

.site-header {
  border-bottom: 1px solid var(--hairline);
}

.site-header__inner {
  max-width: var(--content-width);
  margin: 0 auto;
  padding: 22px 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.logo-area {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-weight: 600;
  font-size: 15px;
}
.logo-area:hover { color: var(--ink); }
.logo-area img {
  width: 28px;
  height: 28px;
  border-radius: 7px;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 22px;
  font: 500 13px var(--font-body);
  color: var(--ink-muted);
  flex-wrap: wrap;
}
.site-nav a { color: var(--ink-muted); }
.site-nav a:hover, .site-nav a.is-current { color: var(--ink); }
.site-nav .lang-switch { border-left: 1px solid var(--hairline); padding-left: 18px; }

/* Cross-app menu in header */
.apps-menu {
  position: relative;
}
.apps-menu > summary {
  list-style: none;
  cursor: pointer;
  color: var(--ink-muted);
  font: 500 13px var(--font-body);
}
.apps-menu > summary::-webkit-details-marker { display: none; }
.apps-menu > summary::after { content: " ▾"; font-size: 10px; }
.apps-menu[open] > summary { color: var(--ink); }
.apps-menu__panel {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  min-width: 240px;
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 6px;
  box-shadow: 0 12px 28px -16px rgba(42, 38, 32, 0.35);
  padding: 8px 0;
  z-index: 40;
}
.apps-menu__panel a {
  display: block;
  padding: 10px 16px;
  color: var(--ink);
  font: 500 13px var(--font-body);
}
.apps-menu__panel a:hover {
  background: var(--surface-raised);
  color: var(--ink);
}
.apps-menu__panel a small {
  display: block;
  margin-top: 2px;
  font: 400 11.5px var(--font-body);
  color: var(--ink-muted);
}
.apps-menu__panel a[href="/"],
.apps-menu__panel a[href="/ja/"] {
  border-bottom: 1px solid var(--hairline);
  margin-bottom: 4px;
  padding-bottom: 12px;
}

/* ---- Buttons ---- */

.btn,
a.btn {
  display: inline-block;
  padding: 14px 28px;
  border-radius: 999px;
  font: 600 13px var(--font-body);
  text-align: center;
  white-space: nowrap;
  text-decoration: none;
  line-height: 1.2;
}
.btn-sm,
a.btn-sm { padding: 9px 20px; font-size: 12.5px; }
.btn-outline,
a.btn-outline {
  border: 1px solid var(--ink);
  background: transparent;
  color: var(--ink);
}
.btn-outline:hover,
a.btn-outline:hover { background: var(--ink); color: var(--bg); }
.btn-solid,
a.btn-solid {
  background: var(--ink);
  color: var(--bg);
  border: 1px solid var(--ink);
}
.btn-solid:hover,
a.btn-solid:hover { background: var(--accent); color: #fff; border-color: var(--accent); }
.btn-accent,
a.btn-accent {
  background: var(--accent);
  color: #fff;
  border: 1px solid var(--accent);
}
.btn-accent:hover,
a.btn-accent:hover { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.btn-outline-invert,
a.btn-outline-invert { border: 1px solid #fff; color: #fff; background: transparent; }
.btn-outline-invert:hover,
a.btn-outline-invert:hover { background: #fff; color: var(--ink); }

.btn-row {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}
.btn-row--center { justify-content: center; }

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

.hero {
  max-width: var(--content-width);
  margin: 0 auto;
  padding: 96px 40px 0;
  display: flex;
  gap: 72px;
  align-items: center;
  flex-wrap: wrap;
}
.hero__copy { flex: 1 1 320px; min-width: 0; }
.hero__title {
  font: 400 56px/1.14 var(--font-display);
  letter-spacing: -0.01em;
  margin: 0 0 22px;
}
.hero__title em {
  font-style: italic;
  color: var(--accent);
}
.hero__lead {
  font: 400 17px/1.65 var(--font-body);
  color: var(--ink-muted);
  max-width: 440px;
  margin: 0 0 30px;
}
.hero__note {
  font: 500 12.5px var(--font-body);
  color: var(--ink-muted);
  margin: 16px 0 0;
}
.hero__visual {
  flex: 1 1 280px;
  min-width: 0;
  display: flex;
  justify-content: center;
}
.hero__frame {
  background: var(--surface-raised);
  padding: 16px;
  border-radius: 6px;
  transform: none;
  box-shadow: 0 20px 40px -24px rgba(42, 38, 32, 0.28);
}
.hero__frame img {
  width: min(280px, 72vw);
  height: auto;
  border-radius: 3px;
  object-fit: contain;
}

/* ---- Feature grid (numbered, 3-up) ---- */

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--hairline);
  border-bottom: 1px solid var(--hairline);
}
.feature-grid__item {
  padding: 32px 30px;
  border-right: 1px solid var(--hairline);
}
.feature-grid__item:last-child { border-right: none; }
.feature-grid__num {
  font: italic 500 26px var(--font-display);
  color: var(--accent);
  margin-bottom: 10px;
}
.feature-grid__title {
  font: 600 14.5px var(--font-body);
  margin-bottom: 6px;
}
.feature-grid__desc {
  font: 400 13.5px/1.6 var(--font-body);
  color: var(--ink-muted);
}

.section-note {
  max-width: 640px;
  margin: 36px auto 0;
  text-align: center;
  font: 400 14px/1.7 var(--font-body);
  color: var(--ink-muted);
}
.section-lead {
  max-width: 700px;
  margin: 0 auto 48px;
  text-align: center;
  font: 400 15.5px/1.8 var(--font-body);
  color: var(--ink-muted);
}

/* ---- Spec list (label + description rows) ---- */

.spec-list { border-top: 1px solid var(--hairline); }
.spec-list__row {
  display: flex;
  gap: 24px;
  padding: 18px 0;
  border-bottom: 1px solid var(--hairline);
}
.spec-list__label {
  flex: 0 0 160px;
  font: italic 500 14px var(--font-display);
  color: var(--accent);
}
.spec-list__value {
  flex: 1;
  font: 400 14px/1.6 var(--font-body);
  color: var(--ink-muted);
}

/* ---- Fact list (dt/dd rows, used on simpler overview sections) ---- */

.fact-list {
  list-style: none;
  padding-left: 0;
  margin: 0;
  border-top: 1px solid var(--hairline);
}
.fact-list li {
  display: flex;
  gap: var(--space-2);
  padding: var(--space-2) 0;
  border-bottom: 1px solid var(--hairline);
  margin-bottom: 0;
}
.fact-list dt {
  flex: 0 0 9em;
  font: italic 500 14px var(--font-display);
  color: var(--accent);
}
.fact-list dd { margin: 0; flex: 1; color: var(--ink-muted); font-size: 14px; }

/* ---- Screenshot gallery ---- */

.screenshot-gallery {
  display: flex;
  gap: 20px;
  overflow-x: auto;
  padding: 4px 4px 16px;
  -webkit-overflow-scrolling: touch;
  scroll-snap-type: x proximity;
}
.screenshot-gallery figure {
  margin: 0;
  flex: 0 0 auto;
  width: min(280px, 70vw);
  scroll-snap-align: start;
}
.screenshot-gallery__frame {
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 4px;
  padding: 12px;
  box-shadow: 0 10px 26px -18px rgba(42, 38, 32, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
}
.screenshot-gallery__frame img {
  width: 100%;
  height: auto;
  max-height: none;
  border-radius: 2px;
  object-fit: contain;
  transform: none;
}
.screenshot-gallery figcaption {
  text-align: center;
  font: 500 12px var(--font-body);
  color: var(--ink-muted);
  margin-top: 12px;
  line-height: 1.4;
  overflow-wrap: anywhere;
}

/* ---- Numbered steps (how-to-use) ---- */

.steps { display: flex; flex-direction: column; }
.step { display: flex; gap: 28px; margin-bottom: 44px; }
.step:last-child { margin-bottom: 0; }
.step__marker {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.step__num {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--accent);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font: 600 14px var(--font-body);
}
.step__line {
  flex: 1;
  width: 1px;
  background: var(--hairline);
  margin-top: 8px;
}
.step__body { flex: 1; padding-bottom: 8px; }
.step__title { font: 600 16px var(--font-body); margin: 4px 0 8px; }
.step__desc { font: 400 14px/1.7 var(--font-body); color: var(--ink-muted); margin: 0 0 20px; }
.step__desc:last-child { margin-bottom: 0; }

.step-figures { display: flex; gap: 16px; }
.step-figures figure { margin: 0; flex: 1; }
.step-figures img {
  width: 100%;
  border-radius: 4px;
  border: 1px solid var(--hairline);
}
.step-figures figcaption {
  font: 400 11.5px var(--font-body);
  color: var(--ink-muted);
  margin-top: 8px;
}

/* ---- Plans / pricing ---- */

.plans-grid {
  display: flex;
  gap: 28px;
  flex-wrap: wrap;
  justify-content: center;
  margin-bottom: 28px;
}
.plan-card {
  flex: 1 1 320px;
  max-width: 380px;
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 6px;
  padding: 34px;
}
.plan-card--featured {
  background: var(--ink);
  color: var(--bg);
  position: relative;
}
.plan-card__badge {
  position: absolute;
  top: -12px;
  right: 24px;
  background: var(--accent);
  color: #fff;
  font: 600 11px var(--font-body);
  padding: 5px 12px;
  border-radius: 999px;
}
.plan-card__label {
  font: 600 12px var(--font-body);
  letter-spacing: 0.06em;
  color: var(--ink-muted);
  margin-bottom: 14px;
}
.plan-card--featured .plan-card__label { color: var(--accent); }
.plan-card__price { font: 400 26px var(--font-display); margin-bottom: 16px; }
.plan-card__desc { font: 400 14px/1.7 var(--font-body); color: var(--ink-muted); margin: 0; }
.plan-card--featured .plan-card__desc { color: inherit; opacity: 0.8; }

.plan-notes {
  max-width: 680px;
  margin: 0 auto;
  font: 400 13.5px/1.8 var(--font-body);
  color: var(--ink-muted);
}
.plan-notes p { margin: 0 0 10px; }
.plan-notes p:last-child { margin-bottom: 0; }
.plan-notes strong { color: var(--ink); }

/* ---- CTA band ---- */

.cta-band { margin-top: 110px; background: var(--surface-raised); }
.cta-band__inner {
  max-width: 640px;
  margin: 0 auto;
  padding: 70px 40px;
  text-align: center;
}
.cta-band__title { font: 400 26px var(--font-display); margin-bottom: 22px; }
.cta-band__fineprint {
  font: 400 11.5px var(--font-body);
  color: var(--ink-muted);
  margin: 14px 0 0;
}

/* ---- FAQ accordion ---- */

.faq-list { border-top: 1px solid var(--hairline); }
.faq-item { border-bottom: 1px solid var(--hairline); padding: 20px 0; }
.faq-item summary {
  cursor: pointer;
  font: 600 15px var(--font-body);
  list-style: none;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::before {
  content: "+ ";
  color: var(--accent);
  font-weight: 400;
}
.faq-item[open] summary::before { content: "\2212 "; }
.faq-item p {
  font: 400 14px/1.7 var(--font-body);
  color: var(--ink-muted);
  margin: 14px 0 0;
}

/* ---- Article teaser ---- */

.article-teaser {
  border-top: 1px solid var(--hairline);
  padding-top: 32px;
}
.article-teaser__label {
  font: 600 11px var(--font-body);
  letter-spacing: 0.06em;
  color: var(--ink-muted);
  margin-bottom: 10px;
}
.article-teaser__link { font: 400 20px var(--font-display); color: var(--ink); }
.article-teaser__link:hover { color: var(--accent); }

/* ---- Contact section ---- */

.contact-section {
  border-top: 1px solid var(--hairline);
  padding-top: 44px;
  text-align: center;
}
.contact-section__title { font: 400 30px var(--font-display); margin: 0 0 18px; }
.contact-section__lead {
  font: 400 14.5px/1.7 var(--font-body);
  color: var(--ink-muted);
  max-width: 480px;
  margin: 0 auto 26px;
}

/* ---- Footer ---- */

.site-footer { border-top: 1px solid var(--hairline); }
.site-footer__inner {
  max-width: var(--content-width);
  margin: 0 auto;
  padding: 28px 40px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  font: 400 12.5px var(--font-body);
  color: var(--ink-muted);
}
.site-footer__links { display: flex; gap: 20px; flex-wrap: wrap; }
.site-footer a { color: var(--ink-muted); }
.site-footer a:hover { color: var(--ink); }

/* ---- Sections rhythm ---- */

.section { max-width: var(--content-width); margin: 0 auto; padding: 96px 40px 0; }
.section--narrow { max-width: var(--content-width-narrow); }
.section--article { max-width: var(--content-width-article); }
.section--tight { padding-top: 80px; }
.section:first-of-type { padding-top: 96px; }

/* ---- Legal / article pages ---- */

.legal-page h1 { font: 400 40px var(--font-display); margin: 0 0 8px; }
.legal-page .page-meta {
  color: var(--ink-muted);
  font-size: 0.875rem;
  margin: 0 0 var(--space-4);
}
.legal-page section { margin-top: var(--space-4); }
.legal-page h2 { font: 600 16px var(--font-body); margin: 0 0 var(--space-2); }
.legal-page p { font: 400 14px/1.75 var(--font-body); color: var(--ink-muted); margin: 0 0 var(--space-2); }
.legal-page a { color: var(--accent); }
.legal-page a:hover { color: var(--ink); }

.article-page h1 { font: 400 40px/1.2 var(--font-display); margin: 0 0 8px; }
.article-page .page-meta { color: var(--ink-muted); font-size: 0.875rem; margin: 0 0 var(--space-4); }
.article-page > p:first-of-type { font: 400 17px/1.7 var(--font-body); color: var(--ink-muted); margin: 0 0 var(--space-5); }
.article-page section { margin-top: var(--space-5); }
.article-page h2 { font: 400 26px var(--font-display); margin: 0 0 var(--space-2); }
.article-page p { font: 400 15px/1.8 var(--font-body); color: var(--ink-muted); margin: 0 0 var(--space-2); }
.article-page ul { font: 400 15px/1.8 var(--font-body); color: var(--ink-muted); padding-left: 1.3em; }
.article-page li { margin-bottom: 0.6em; }
.article-page a { color: var(--accent); }
.article-page a:hover { color: var(--ink); }
.article-page strong { color: var(--ink); }

/* ---- Contact form ---- */

.form-wrap { max-width: 520px; }
.field { margin-bottom: 1.25rem; }
.field label { display: block; font-weight: 600; margin-bottom: 0.4rem; font-size: 0.95rem; }
.field-note { font-weight: 400; color: var(--ink-muted); font-size: 0.85rem; }
.field textarea,
.field input[type="email"] {
  width: 100%;
  padding: 0.65rem 0.75rem;
  border: 1px solid var(--hairline);
  border-radius: 6px;
  font: inherit;
  font-size: 1rem;
  background: var(--surface);
  color: var(--ink);
  -webkit-appearance: none;
}
.field textarea { min-height: 150px; resize: vertical; }
.field textarea:focus,
.field input[type="email"]:focus {
  outline: 2px solid var(--accent);
  outline-offset: -1px;
}
.char-count { font-size: 0.8rem; color: var(--ink-muted); text-align: right; margin-top: 0.25rem; }
.submit-btn {
  background: var(--ink);
  color: var(--bg);
  border: none;
  padding: 0.85rem 2rem;
  border-radius: 999px;
  font: inherit;
  font-size: 0.8125rem;
  font-weight: 600;
  cursor: pointer;
}
.submit-btn:hover { background: var(--accent); }
.submit-btn:disabled { opacity: 0.45; cursor: not-allowed; }
.notice { padding: 1rem 1.25rem; border-radius: 6px; margin-top: 1.5rem; line-height: 1.6; }
.notice--success { background: #eef1e4; color: #4b5a2a; }
.notice--error { background: #f6e4e0; color: #8a3a2a; }

/* ---- App list (homepage / hub) ---- */

.app-list { display: flex; flex-direction: column; gap: 1px; border: 1px solid var(--hairline); border-radius: 6px; overflow: hidden; }
.app-card {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 22px 26px;
  background: var(--surface);
  border-bottom: 1px solid var(--hairline);
}
.app-card:last-child { border-bottom: none; }
.app-card:hover { background: var(--surface-raised); }
.app-card__icon { width: 52px; height: 52px; border-radius: 12px; flex-shrink: 0; background: var(--hairline); object-fit: cover; }
.app-card__info { flex: 1; min-width: 0; }
.app-card__name { font: 600 15px var(--font-body); margin: 0 0 3px; }
.app-card__desc {
  font: 400 13.5px var(--font-body);
  color: var(--ink-muted);
  margin: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  white-space: normal;
}
.app-card__meta { font: 400 12px var(--font-body); color: var(--ink-muted); margin-top: 3px; }
.app-card__arrow { color: var(--hairline); font-size: 1.2rem; flex-shrink: 0; }

/* ---- Compare table (articles) ---- */

.table-wrap { overflow-x: auto; margin: var(--space-3) 0; }
.compare-table {
  width: 100%;
  border-collapse: collapse;
  font: 400 14px/1.5 var(--font-body);
}
.compare-table th,
.compare-table td {
  border: 1px solid var(--hairline);
  padding: 12px 14px;
  text-align: left;
  vertical-align: top;
}
.compare-table thead th {
  background: var(--surface-raised);
  font-weight: 600;
  color: var(--ink);
}
.compare-table tbody th {
  font-weight: 600;
  color: var(--ink);
  white-space: nowrap;
}
.compare-table td { color: var(--ink-muted); }

/* ---- Sample image grid (PDF previews etc.) ---- */

.sample-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  margin: var(--space-3) 0;
  align-items: start;
}
.sample-grid figure { margin: 0; }
.sample-grid a { display: block; }
.sample-grid img {
  width: 100%;
  height: auto;
  aspect-ratio: auto;
  object-fit: contain;
  border: 1px solid var(--hairline);
  border-radius: 4px;
  background: var(--surface);
}
.sample-grid figcaption {
  font: 500 12px var(--font-body);
  color: var(--ink-muted);
  margin-top: 10px;
  text-align: center;
}
@media (max-width: 640px) {
  .sample-grid { grid-template-columns: 1fr; }
}

/* ---- Hub list (free-pdf levels etc.) ---- */

.hub-list {
  list-style: none;
  padding: 0;
  margin: 0 0 var(--space-4);
  border: 1px solid var(--hairline);
  border-radius: 6px;
  overflow: hidden;
  background: var(--surface);
}
.hub-list li { border-bottom: 1px solid var(--hairline); margin: 0; }
.hub-list li:last-child { border-bottom: none; }
.hub-list a {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 16px;
  padding: 16px 20px;
  color: var(--ink);
}
.hub-list a:hover { background: var(--surface-raised); color: var(--ink); }
.hub-list__level {
  font: italic 500 18px var(--font-display);
  color: var(--accent);
  min-width: 2.5em;
}
.hub-list__type {
  font: 600 13px var(--font-body);
  color: var(--ink);
}
.hub-list__meta {
  flex: 1 1 100%;
  font: 400 13px var(--font-body);
  color: var(--ink-muted);
}
@media (min-width: 640px) {
  .hub-list__meta { flex: 1 1 auto; text-align: right; }
}

.ref-list {
  font: 400 13px/1.7 var(--font-body);
  color: var(--ink-muted);
  padding-left: 1.2em;
}
.ref-list li { margin-bottom: 0.75em; }
.ref-note { font-size: 0.875rem !important; }

/* ---- Responsive ---- */

@media (max-width: 760px) {
  :root {
    --space-5: 3rem;
    --space-6: 4rem;
  }

  body {
    padding-left: env(safe-area-inset-left);
    padding-right: env(safe-area-inset-right);
  }

  .shell,
  .section,
  .hero,
  .site-header__inner,
  .site-footer__inner,
  .cta-band__inner {
    padding-left: max(16px, env(safe-area-inset-left));
    padding-right: max(16px, env(safe-area-inset-right));
  }

  .site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: var(--bg);
    padding-top: env(safe-area-inset-top);
  }

  .site-header__inner {
    padding-top: 12px;
    padding-bottom: 12px;
    gap: 10px 14px;
    align-items: center;
  }

  .logo-area {
    font-size: 14px;
    min-width: 0;
  }

  .logo-area img {
    width: 26px;
    height: 26px;
  }

  .site-nav {
    gap: 12px;
    row-gap: 8px;
    justify-content: flex-end;
    flex: 1 1 auto;
  }

  .site-nav a,
  .apps-menu > summary {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    padding: 0 2px;
  }

  .site-nav .lang-switch {
    border-left: none;
    padding-left: 0;
  }

  .site-header .btn.btn-sm {
    display: none; /* store CTA lives in hero on small screens */
  }

  .apps-menu__panel {
    position: fixed;
    top: auto;
    left: max(12px, env(safe-area-inset-left));
    right: max(12px, env(safe-area-inset-right));
    width: auto;
    min-width: 0;
    max-height: min(70vh, 480px);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    box-shadow: 0 16px 40px -12px rgba(42, 38, 32, 0.4);
  }

  .apps-menu__panel a {
    padding: 14px 18px;
    min-height: 48px;
  }

  .hero {
    padding-top: 40px;
    gap: 28px;
    flex-direction: column;
    align-items: stretch;
  }

  .hero__copy {
    flex: 1 1 auto;
    order: 1;
  }

  .hero__visual {
    order: 2;
    width: 100%;
  }

  .hero__title {
    font-size: clamp(32px, 9vw, 40px);
    line-height: 1.2;
  }

  .hero__lead {
    font-size: 15.5px;
    max-width: none;
  }

  .hero__frame {
    padding: 12px;
    margin: 0 auto;
  }

  .hero__frame img {
    width: min(240px, 58vw);
  }

  .btn-row {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  .btn-row--center {
    align-items: stretch;
  }

  .btn,
  a.btn {
    width: 100%;
    text-align: center;
    padding: 14px 18px;
    min-height: 48px;
    white-space: normal;
    line-height: 1.35;
  }

  .feature-grid {
    grid-template-columns: 1fr;
  }

  .feature-grid__item {
    border-right: none;
    border-bottom: 1px solid var(--hairline);
    padding: 24px 0;
  }

  .feature-grid__item:last-child {
    border-bottom: none;
  }

  .section {
    padding-top: 56px;
  }

  .section--narrow,
  .section--article {
    padding-left: max(16px, env(safe-area-inset-left));
    padding-right: max(16px, env(safe-area-inset-right));
  }

  .section-heading {
    font-size: 26px;
    margin-bottom: 28px;
  }

  .section-lead {
    font-size: 14.5px;
    margin-bottom: 28px;
    text-align: left;
  }

  .home-intro {
    padding-top: 40px !important;
  }

  .home-intro__title {
    font-size: 34px;
  }

  .home-section-title {
    font-size: 20px !important;
    margin-bottom: 18px !important;
  }

  .screenshot-gallery {
    gap: 14px;
    margin-left: -4px;
    margin-right: -4px;
    padding-left: 4px;
    padding-right: 20px;
  }

  .screenshot-gallery figure {
    width: min(220px, 68vw);
  }

  .step {
    gap: 16px;
    margin-bottom: 32px;
  }

  .step__title {
    font-size: 15px;
  }

  .step__desc {
    font-size: 13.5px;
  }

  .step-figures {
    flex-direction: column;
  }

  .plans-grid {
    flex-direction: column;
    gap: 16px;
  }

  .plan-card {
    flex: 1 1 auto;
    max-width: none;
    width: 100%;
    padding: 24px 20px;
  }

  .cta-band {
    margin-top: 64px;
  }

  .cta-band__inner {
    padding-top: 48px;
    padding-bottom: 48px;
  }

  .cta-band__title {
    font-size: 22px;
  }

  .faq-item summary {
    min-height: 44px;
    padding: 4px 0;
    line-height: 1.45;
  }

  .app-card {
    gap: 14px;
    padding: 16px;
    min-height: 72px;
  }

  .app-card__icon {
    width: 44px;
    height: 44px;
    border-radius: 10px;
  }

  .app-card__name {
    font-size: 14.5px;
  }

  .app-card__desc {
    font-size: 12.5px;
    -webkit-line-clamp: 2;
  }

  .site-footer {
    padding-bottom: env(safe-area-inset-bottom);
  }

  .site-footer__inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    padding-top: 20px;
    padding-bottom: 28px;
  }

  .legal-page h1,
  .article-page h1 {
    font-size: 30px !important;
  }

  .form-wrap {
    max-width: none;
  }

  .submit-btn {
    width: 100%;
    min-height: 48px;
  }

  .hub-list a {
    padding: 14px 16px;
    min-height: 52px;
  }

  .contact-section {
    text-align: left;
  }

  .contact-section .btn {
    width: 100%;
  }

  .spec-list__row {
    flex-direction: column;
    gap: 4px;
  }

  .spec-list__label {
    flex: none;
  }

  .fact-list li {
    flex-direction: column;
    gap: 4px;
  }

  .fact-list dt {
    flex: none;
  }
}

@media (max-width: 380px) {
  .hero__title {
    font-size: 28px;
  }

  .logo-area span,
  .logo-area {
    max-width: 42vw;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
}
