/* App-style phone layout: search pill, area chips, swipeable rows and a bottom tab bar. */

.hero-search > summary { list-style: none; cursor: pointer; }
.hero-search > summary::-webkit-details-marker { display: none; }
.hero-search > summary {
  width: min(560px, 100%); margin: 0 auto; display: flex; align-items: center; gap: 12px;
  padding: 11px 20px; border: 1px solid var(--line); border-radius: 999px; background: var(--white);
  box-shadow: 0 10px 28px rgba(20, 38, 42,.13); text-align: left; color: var(--ink);
}
.hero-search > summary svg { width: 20px; height: 20px; flex-shrink: 0; }
.hero-search > summary > span { display: grid; gap: 2px; min-width: 0; }
.hero-search > summary b { font-size: 14px; }
.hero-search > summary small { overflow: hidden; color: var(--muted); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.hero-search[open] > summary { margin-bottom: 12px; }

/* Wide screens keep the full search form in view; the pill is only a phone affordance.
   The hero-search controller opens the details element, and this keeps it visible before that. */
@media (min-width: 761px) {
  .hero-search[open] > summary { display: none; }
}
@supports selector(::details-content) {
  @media (min-width: 761px) {
    .hero-search > summary { display: none; }
    .hero-search::details-content { content-visibility: visible; }
  }
}

.area-chips { width: min(1240px, calc(100% - 48px)); margin: 30px auto 0; display: flex; flex-wrap: wrap; gap: 8px; }
.area-chips a {
  border: 1px solid var(--line); border-radius: 999px; padding: 9px 16px; background: var(--white);
  color: var(--ink); font-size: 13px; font-weight: 600; text-decoration: none; white-space: nowrap;
}
.area-chips a:hover { border-color: var(--ink); }
.area-chips + .section { padding-top: 40px; }

.tab-bar { display: none; }

@media (max-width: 760px) {
  html:has(> body > .tab-bar) { scroll-padding-bottom: calc(72px + env(safe-area-inset-bottom)); }
  body:has(> .tab-bar) { padding-bottom: calc(64px + env(safe-area-inset-bottom)); }
  body:has(> .tab-bar) .site-header { position: relative; }

  .tab-bar {
    display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
    padding: 4px 4px calc(4px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); background: var(--white);
  }
  .tab-bar a {
    flex: 1 1 0; min-width: 0; min-height: 52px; display: grid; justify-items: center; align-content: center; gap: 4px;
    color: var(--muted); font-size: 11px; font-weight: 600; text-decoration: none;
  }
  .tab-bar a span { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .tab-bar a svg { width: 22px; height: 22px; stroke-width: 1.8; }
  .tab-bar a[aria-current="page"] { color: var(--action); }

  .hero { padding: 20px 16px 22px; }
  .hero h1 { margin-bottom: 16px; font-size: 26px; letter-spacing: -1px; }
  .hero-search > summary { padding: 12px 18px; }

  .area-chips { width: 100%; margin-top: 14px; padding: 4px 16px; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .area-chips::-webkit-scrollbar { display: none; }
  .area-chips + .section { padding-top: 24px; }

  .section { padding: 40px 0; }
  .section-heading { align-items: end; gap: 12px; margin-bottom: 16px; }
  .section-heading > div { min-width: 0; }
  .section-heading .text-link { display: inline-flex; flex-shrink: 0; padding: 4px 0; font-size: 13px; }
  .section h2 { font-size: 22px; line-height: 1.15; letter-spacing: -.6px; }

  .property-rail {
    grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 80%; gap: 14px;
    margin: -4px -16px 0; padding: 4px 16px; overflow-x: auto; scroll-snap-type: x mandatory;
    scroll-padding-inline: 16px; overscroll-behavior-x: contain; scrollbar-width: none;
  }
  .property-rail::-webkit-scrollbar { display: none; }
  .property-rail > .property-card { scroll-snap-align: start; }

  .property-grid .property-card__image,
  .results-grid .property-card__image { height: auto; aspect-ratio: 20 / 17; border-radius: 14px; }
  .property-card__body { padding-top: 10px; }
  .property-card h3 { margin: 4px 0 5px; font-size: 16px; }
  .card-meta { margin-top: 10px; }
  .card-evidence { gap: 6px; border: 0; }
  .card-evidence span { padding: 8px; border-radius: 10px; background: var(--sand); }
  .card-evidence span + span { border-left: 0; }

  .promise-section { gap: 28px; padding: 44px 16px; }
  .promise-intro h2 { font-size: 34px; letter-spacing: -1.5px; }
  .promise-intro p { margin: 14px 0 20px; font-size: 14px; }
  .promise-grid {
    grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 78%; gap: 12px;
    margin: -4px -16px 0; padding: 4px 16px; border: 0; overflow-x: auto; scroll-snap-type: x mandatory;
    scroll-padding-inline: 16px; scrollbar-width: none;
  }
  .promise-grid::-webkit-scrollbar { display: none; }
  .promise-grid article { min-height: 0; padding: 22px; border: 1px solid rgba(255,255,255,.18); border-radius: 14px; scroll-snap-align: start; }
  .promise-grid h3 { margin: 22px 0 8px; font-size: 17px; }

  .steps article { padding: 16px; }
  .support-banner { gap: 18px; margin: 0 auto 40px; padding: 26px 20px; border-radius: 14px; }
  .support-banner h2 { font-size: 24px; }

  .site-footer { padding-top: 40px; }
  .footer-main { gap: 24px; padding-bottom: 32px; }
}
