/*
 * aihi-provider.css - the page-scoped styles of the provider pages, the test pages, the size pages and the providers
 * list (Phase 3, builder B4; listed in $page->css by templates/pages/provider.php, test.php, size.php, providers.php).
 *
 * The look follows the approved homepage mockup E (designs/homepage-2026-10-24/Combined.dc.html): its size cards (white,
 * a 1 px #D9DBEB line, 18 px corners, 28 px padding, the Server / From list), its type scale and its colours, through
 * the custom properties of the shared stylesheet aihi-site.css (never new colours; the yellow stays for the "Ad" label
 * and the finder note only). Shared classes (plan table, prices, prose, page head, size bars) live in aihi-site.css.
 * Strict CSP: no inline style on a public page, so every look is a class here. All small-screen rules sit in ONE
 * marked block at the end.
 */

/* ---------------------------------------------------------------- sections of these pages */

.aihi-pp-section { margin-top: 56px; scroll-margin-top: 24px; max-width: 52rem; }
.aihi-pp-section--wide { max-width: none; }
.aihi-pp-h2 {
  font-family: var(--f-head);
  font-weight: 800;
  font-size: clamp(26px, 2.6vw, 32px);
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin-bottom: 10px;
}
.aihi-pp-intro { color: var(--c-text-2); max-width: 44rem; margin-bottom: 20px; text-wrap: pretty; }
.aihi-pp-empty { font-size: 19px; color: var(--c-text-2); margin-top: 8px; }
.aihi-pp-note { font-size: 14px; color: var(--c-muted); margin-top: 14px; }
.aihi-pp-links { list-style: none; padding: 0; margin: 0 0 16px; display: flex; flex-wrap: wrap; gap: 8px 24px; font-weight: 600; }
.aihi-pp-links a { color: var(--c-link); }
.aihi-pp-finder { font-size: 17px; color: var(--c-text-2); }
.aihi-pp-finder a { font-weight: 600; }

/* cards in the look of the mockup's size cards */
.aihi-pp-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(330px, 100%), 1fr));   /* empty columns kept: one card is one third (V-05) */
  gap: 20px;
}
.aihi-pp-card {
  padding: 28px;
  background: var(--c-white);
  border: 1px solid var(--c-line);
  border-radius: var(--r-big);
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.aihi-pp-card__logo { display: block; width: auto; max-width: 160px; height: auto; max-height: 40px; object-fit: contain; object-position: left center; }

/* every scroll box of these pages holds its absolutely placed children (the visually hidden words of the table cells):
   without it they are placed against the page and make the whole page scroll sideways on a phone */
.aihi-table-scroll { position: relative; }

/* data tables of these pages (locations, measured numbers) */
.aihi-pp-tablebox {
  background: var(--c-white);
  border: 1px solid var(--c-line);
  border-radius: var(--r-card);
}
.aihi-pp-table { width: 100%; min-width: 560px; border-collapse: collapse; font-size: 15px; }
.aihi-pp-table caption { text-align: left; padding: 14px 20px 6px; font-size: 14px; color: var(--c-muted); caption-side: top; }
.aihi-pp-table thead th {
  padding: 12px 16px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--c-muted);
  text-align: left;
  border-bottom: 1px solid var(--c-table-line);
}
.aihi-pp-table tbody th, .aihi-pp-table tbody td { padding: 14px 16px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--c-row-line); }
.aihi-pp-table tbody tr:last-child th, .aihi-pp-table tbody tr:last-child td { border-bottom: 0; }
.aihi-pp-table tbody th { font-weight: 600; }
.aihi-pp-table thead th:first-child, .aihi-pp-table tbody th { padding-left: 20px; }
.aihi-pp-table thead th:last-child, .aihi-pp-table tbody td:last-child { padding-right: 20px; }
.aihi-pp-table .aihi-cell__sub { display: block; font-weight: 400; }
.aihi-prose .aihi-pp-tablebox { margin-top: 1em; }

/* ---------------------------------------------------------------- provider pages */

.aihi-provhead__title { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; }
.aihi-prov-logo { display: block; width: auto; max-width: 220px; height: auto; max-height: 56px; object-fit: contain; }
.aihi-pp-closednote {
  max-width: 44rem;
  padding: 14px 18px;
  background: var(--c-filter-bg);
  border: 1px solid var(--c-line);
  border-left: 4px solid var(--c-navy);
  border-radius: var(--r-card);
  color: var(--c-navy);
}
.aihi-provpage__body { margin-top: 8px; }
.aihi-pp-offers { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 12px; }
.aihi-pp-offer {
  padding: 18px 22px;
  background: var(--c-white);
  border: 1px solid var(--c-line);
  border-radius: var(--r-card);
}
.aihi-pp-offer__text { font-weight: 600; }
.aihi-pp-offer__meta { margin-top: 4px; font-size: 14px; color: var(--c-muted); }
.aihi-pp-tests { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 18px; }
.aihi-pp-tests li { display: flex; flex-direction: column; gap: 4px; }
.aihi-pp-tests__name { font-weight: 700; font-size: 18px; }
.aihi-pp-tests__date { font-size: 14px; color: var(--c-muted); }
.aihi-pp-tests p { color: var(--c-text-2); }

/* ---------------------------------------------------------------- the providers list */

.aihi-provcard__name { font-family: var(--f-head); font-weight: 800; font-size: 22px; line-height: 1.2; letter-spacing: -0.01em; }
.aihi-provcard__name a { color: var(--c-navy); text-decoration: none; }
@media (hover: hover) { .aihi-provcard__name a:hover { color: var(--c-link); text-decoration: underline; } }
.aihi-provcard__name a:focus-visible { color: var(--c-link); text-decoration: underline; }
.aihi-provcard__summary { color: var(--c-text-2); }
.aihi-provcard__facts { margin-top: auto; display: flex; flex-wrap: wrap; align-items: flex-end; gap: 6px 18px; font-size: 15px; }
.aihi-provcard__count { color: var(--c-muted); }
.aihi-pp-closed { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.aihi-pp-closed li { display: flex; flex-direction: column; gap: 2px; }
.aihi-pp-closed a { font-weight: 600; align-self: flex-start; }
.aihi-pp-closed__note { color: var(--c-muted); font-size: 15px; }

/* ---------------------------------------------------------------- size pages (the homepage card, made a page) */

.aihi-sizepage__size { display: flex; align-items: flex-end; gap: 12px; }
.aihi-sizepage__word { font-family: var(--f-head); font-weight: 800; font-size: 28px; line-height: 1; }
.aihi-sizepage__facts {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 6px 16px;
  margin: 4px 0 0;
  font-size: 15px;
  max-width: 36rem;
}
.aihi-sizepage__facts dt { color: var(--c-muted); }
.aihi-sizepage__facts dd { margin: 0; }
.aihi-sizepage__from { font-weight: 600; }
/* the page's 730-hour note right under the From line of an hourly size */
.aihi-sizepage__note { margin: -6px 0 0; max-width: 36rem; }
.aihi-fit__title { font-family: var(--f-head); font-weight: 700; font-size: 22px; line-height: 1.25; letter-spacing: -0.01em; }
.aihi-fit__why { color: var(--c-text-2); }

/* ---------------------------------------------------------------- test pages */

.aihi-testpage__meta a { color: var(--c-link); }
.aihi-testpage__shot { margin: 1.4em 0 0; }
.aihi-testpage__shot img { display: block; border: 1px solid var(--c-line); border-radius: 12px; }
.aihi-testpage__more { margin-top: 2em; font-weight: 600; }

/* ================================================================ SMALL SCREENS (every small-screen rule is here) */

/* touch sizes at 1024 px and below: the links of these pages get a 44 px tall target */
@media (max-width: 1024px) {
  .aihi-pp-links a, .aihi-pp-closed a, .aihi-pp-tests__name, .aihi-provcard__name a, .aihi-pp-finder a, .aihi-testpage__more a,
  .aihi-pp-table a, .aihi-testpage__meta a {
    display: inline-block;
    min-height: 24px;
    padding: 10px 0;
  }
  .aihi-pp-table tbody td a { padding: 10.5px 0; }
}

/* phones: smaller card padding, the sections closer together */
@media (max-width: 600px) {
  .aihi-pp-section { margin-top: 44px; }
  .aihi-pp-card { padding: 22px; }
  .aihi-pp-offer { padding: 16px 18px; }
}
