/* Authority, research and data-hub layouts. Loaded only on these surfaces. */

.va-authority-context {
  --authority-ink: #17342e;
  --authority-green: #0f6b5b;
  --authority-blue: #245f85;
  --authority-gold: #9a681c;
  --authority-red: #a33d36;
  --authority-paper: #ffffff;
  --authority-mist: #edf4f1;
  --authority-blue-pale: #edf4f8;
  --authority-gold-pale: #fff7e6;
  --authority-red-pale: #fff1ef;
  --authority-line: #d5e0dc;
  background: #f6f8f7;
}

.authority-page,
.hub-page {
  padding-top: 72px;
  background: #f6f8f7;
  color: #20332f;
}

.authority-shell {
  width: 100%;
  max-width: 1120px;
  margin-inline: auto;
}

.authority-hero {
  padding: 4.25rem 2rem 3.5rem;
  background: #eaf3ef;
  border-bottom: 1px solid #ccddd6;
}

.authority-hero h1 {
  max-width: 900px;
  margin: 0 0 1rem;
  color: var(--authority-ink);
  font-size: 2.65rem;
  line-height: 1.35;
  font-weight: 900;
  letter-spacing: 0;
}

.authority-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .45rem;
  margin-bottom: 1.4rem;
  color: #60736d;
  font-size: .86rem;
}

.authority-breadcrumb a {
  color: var(--authority-green);
  text-decoration: none;
  font-weight: 700;
}

.authority-breadcrumb a:hover,
.authority-breadcrumb a:focus-visible {
  text-decoration: underline;
}

.authority-kicker {
  margin: 0 0 .65rem;
  color: #6f4d18;
  font-size: .82rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.authority-lead {
  max-width: 880px;
  margin: 0;
  color: #425b55;
  font-size: 1.1rem;
  line-height: 1.95;
}

.authority-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: .65rem 1.4rem;
  align-items: center;
  margin-top: 1.4rem;
  color: #5a6e68;
  font-size: .88rem;
}

.authority-meta-row a {
  color: var(--authority-green);
  font-weight: 800;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.authority-band {
  padding: 3.75rem 2rem;
  background: var(--authority-paper);
  border-bottom: 1px solid #e0e8e5;
}

.authority-band-alt {
  background: #f2f6f4;
}

.authority-band h2,
.hub-insights h2 {
  margin: 0 0 1.25rem;
  color: var(--authority-ink);
  font-size: 1.85rem;
  line-height: 1.45;
  font-weight: 900;
  letter-spacing: 0;
}

.authority-band h3,
.hub-insights h3 {
  margin: 1.7rem 0 .5rem;
  color: #24463f;
  font-size: 1.12rem;
  line-height: 1.55;
  letter-spacing: 0;
}

.authority-section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1.5rem;
  margin-bottom: 1.3rem;
}

.authority-section-heading h2,
.authority-section-heading p {
  margin-bottom: 0;
}

.authority-text-link,
.authority-row-link {
  color: var(--authority-green);
  font-weight: 800;
  text-decoration: none;
}

.authority-text-link:hover,
.authority-row-link:hover,
.authority-text-link:focus-visible,
.authority-row-link:focus-visible {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.authority-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: .8rem;
  margin-top: 1.25rem;
}

.authority-metric {
  min-height: 126px;
  padding: 1.15rem;
  background: #f2f8f5;
  border: 1px solid #cfe0d9;
  border-top: 4px solid var(--authority-green);
  border-radius: 8px;
}

.authority-metric.is-blue {
  background: var(--authority-blue-pale);
  border-color: #cbdce7;
  border-top-color: var(--authority-blue);
}

.authority-metric.is-gold {
  background: var(--authority-gold-pale);
  border-color: #ead8af;
  border-top-color: var(--authority-gold);
}

.authority-metric.is-red {
  background: var(--authority-red-pale);
  border-color: #e8c9c5;
  border-top-color: var(--authority-red);
}

.authority-metric strong {
  display: block;
  margin-bottom: .35rem;
  color: var(--authority-ink);
  font-family: 'DM Sans', 'Cairo', sans-serif;
  font-size: 2rem;
  line-height: 1.2;
}

.authority-metric span {
  display: block;
  color: #4c625c;
  font-size: .9rem;
  line-height: 1.65;
}

.authority-caveat {
  margin: 1.25rem 0 0;
  padding-inline-start: 1rem;
  border-inline-start: 3px solid #c08a31;
  color: #566963;
  font-size: .93rem;
  line-height: 1.85;
}

.authority-table-wrap {
  width: 100%;
  overflow-x: auto;
  background: #fff;
  border: 1px solid var(--authority-line);
  border-radius: 8px;
  outline: none;
}

.authority-table-wrap:focus-visible {
  border-color: var(--authority-green);
  box-shadow: 0 0 0 3px rgba(15, 107, 91, .13);
}

.authority-table {
  width: 100%;
  min-width: 790px;
  border-collapse: collapse;
  font-size: .9rem;
}

.authority-table th,
.authority-table td {
  padding: .9rem 1rem;
  border-bottom: 1px solid #e4ebe8;
  text-align: start;
  vertical-align: middle;
  line-height: 1.65;
}

.authority-table thead th {
  background: #e8f1ed;
  color: #29463f;
  font-size: .79rem;
  font-weight: 900;
  white-space: nowrap;
}

.authority-table tbody tr:last-child th,
.authority-table tbody tr:last-child td {
  border-bottom: 0;
}

.authority-table tbody tr:hover {
  background: #f8fbfa;
}

.authority-table a {
  color: var(--authority-green);
}

.authority-country {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  color: #203b35;
  font-weight: 800;
  white-space: nowrap;
}

.authority-status {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: .25rem .55rem;
  border-radius: 6px;
  font-size: .78rem;
  font-weight: 800;
  white-space: nowrap;
}

.authority-status.is-free { background: #e4f3eb; color: #145f4f; }
.authority-status.is-easy { background: #e7f0f6; color: #265f82; }
.authority-status.is-conditional { background: #fff2d5; color: #79521b; }
.authority-status.is-required { background: #fbe9e7; color: #8d332f; }

.authority-prose {
  color: #314b45;
  font-size: 1rem;
  line-height: 2;
}

.authority-prose-narrow {
  max-width: 860px;
}

.authority-prose p {
  margin: 0 0 1.15rem;
}

.authority-prose a {
  color: var(--authority-green);
  font-weight: 700;
}

.authority-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .75rem;
  margin-top: 1.6rem;
}

.authority-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: .65rem 1.1rem;
  background: var(--authority-green);
  border: 2px solid var(--authority-green);
  border-radius: 7px;
  color: #fff !important;
  font-weight: 800;
  text-decoration: none;
}

.authority-button:hover,
.authority-button:focus-visible {
  background: #0b594c;
  border-color: #0b594c;
  text-decoration: none;
}

.authority-button.is-secondary {
  background: #fff;
  border-color: #8eb5aa;
  color: #174d42 !important;
}

.authority-button.is-secondary:hover,
.authority-button.is-secondary:focus-visible {
  background: #edf5f2;
  border-color: var(--authority-green);
}

.authority-founder-hero {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 2rem;
  align-items: start;
}

.authority-avatar {
  display: grid;
  place-items: center;
  width: 112px;
  aspect-ratio: 1;
  background: #fff;
  border: 2px solid #a8c9be;
  border-radius: 8px;
  color: var(--authority-green);
  font-family: 'DM Sans', sans-serif;
  font-size: 2rem;
  font-weight: 900;
}

.authority-topic-grid,
.report-findings {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin: 1.35rem 0 2rem;
}

.authority-topic-grid > div,
.report-findings article {
  padding: 1.15rem 1.25rem;
  background: #fff;
  border: 1px solid var(--authority-line);
  border-radius: 8px;
}

.authority-topic-grid h3,
.report-findings h3 {
  margin-top: 0;
}

.authority-topic-grid p,
.report-findings p {
  margin-bottom: 0;
  color: #51655f;
  font-size: .92rem;
}

.report-findings .authority-row-link {
  display: inline-block;
  margin-top: .7rem;
}

.authority-steps {
  margin: 1rem 0 2rem;
  padding: 0;
  list-style: none;
  counter-reset: authority-step;
}

.authority-steps li {
  position: relative;
  padding: 1rem 3.25rem 1rem 0;
  border-bottom: 1px solid #dde6e2;
  counter-increment: authority-step;
}

[dir="ltr"] .authority-steps li {
  padding: 1rem 0 1rem 3.25rem;
}

.authority-steps li::before {
  content: counter(authority-step);
  position: absolute;
  inset-inline-start: 0;
  top: .85rem;
  display: grid;
  place-items: center;
  width: 2.25rem;
  height: 2.25rem;
  background: #e4f1ec;
  border: 1px solid #b7d2c8;
  border-radius: 50%;
  color: var(--authority-green);
  font-family: 'DM Sans', sans-serif;
  font-weight: 900;
}

.authority-steps strong,
.authority-steps span {
  display: block;
}

.authority-steps span {
  margin-top: .25rem;
  color: #566963;
}

.authority-definition-list {
  margin: 1rem 0 2rem;
  border-top: 1px solid #dbe5e1;
}

.authority-definition-list > div {
  display: grid;
  grid-template-columns: minmax(150px, .65fr) minmax(0, 2fr);
  gap: 1.25rem;
  padding: .95rem 0;
  border-bottom: 1px solid #dbe5e1;
}

.authority-definition-list strong {
  color: #23473f;
}

.authority-definition-list span {
  color: #526761;
}

.authority-data-dictionary {
  margin-top: 1.4rem;
  padding: 1.1rem 1.25rem;
  background: #f2f6f4;
  border: 1px solid #d8e3df;
  border-radius: 8px;
}

.authority-data-dictionary h3 {
  margin-top: 0;
}

.authority-data-dictionary p {
  margin-bottom: 0;
  overflow-wrap: anywhere;
}

.authority-data-dictionary code {
  color: #294f46;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: .82rem;
}

.report-table {
  min-width: 900px;
  font-variant-numeric: tabular-nums;
}

.report-table td:not(:nth-child(2)),
.report-table thead th:not(:nth-child(2)) {
  text-align: center;
}

/* Existing taxonomy hubs now use the same calm, data-first visual system. */
.hub-hero {
  padding: 3.75rem 2rem 3rem;
  background: #eaf3ef;
  border-bottom: 1px solid #ccddd6;
  color: #20332f;
  text-align: start;
}

.hub-hero .container {
  max-width: 1120px;
}

.hub-breadcrumb {
  color: #60736d;
}

.hub-breadcrumb a {
  color: var(--authority-green);
}

.hub-flag {
  margin-bottom: .6rem;
  font-size: 2.7rem;
}

.hub-hero h1 {
  max-width: 900px;
  color: var(--authority-ink);
  font-size: 2.35rem;
  line-height: 1.4;
  letter-spacing: 0;
}

.hub-intro {
  max-width: 850px;
  margin: 0;
  color: #4d655f;
}

.hub-overview {
  padding: 2.7rem 2rem;
  background: #fff;
  border-bottom: 1px solid #e0e8e5;
}

.hub-overview-box {
  max-width: 900px;
  margin: 0;
  padding: .2rem 1.3rem .2rem 0;
  background: transparent;
  border: 0;
  border-inline-start: 4px solid var(--authority-gold);
  border-radius: 0;
  box-shadow: none;
}

.hub-overview-box h2 {
  color: var(--authority-ink);
  font-size: 1.45rem;
}

.hub-overview-box p {
  color: #334d47;
}

.hub-insights {
  padding: 3.75rem 2rem;
  background: #f2f6f4;
  border-bottom: 1px solid #e0e8e5;
}

.hub-insights .container {
  max-width: 1120px;
}

.hub-practical-note {
  max-width: 900px;
  margin: 2rem 0 0;
  padding-inline-start: 1rem;
  border-inline-start: 3px solid var(--authority-gold);
  color: #526761;
  line-height: 1.9;
}

.hub-quality-note {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: .75rem 1.2rem;
  margin-top: 1rem;
  padding: .9rem 1rem;
  background: #fff;
  border: 1px solid #d8e3df;
  border-radius: 8px;
  color: #526761;
  font-size: .86rem;
}

.hub-quality-note a {
  color: var(--authority-green);
  font-weight: 800;
}

.hub-compare {
  padding: 3.25rem 2rem;
  background: #fff;
}

@media (max-width: 900px) {
  .authority-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .authority-section-heading {
    align-items: start;
    flex-direction: column;
  }
}

@media (max-width: 640px) {
  .authority-page,
  .hub-page {
    padding-top: 64px;
  }

  .authority-hero,
  .hub-hero {
    padding: 2.6rem 1.1rem 2.35rem;
  }

  .authority-hero h1,
  .hub-hero h1 {
    font-size: 1.85rem;
    line-height: 1.45;
  }

  .authority-lead,
  .hub-intro {
    font-size: 1rem;
  }

  .authority-band,
  .hub-overview,
  .hub-insights,
  .hub-compare {
    padding: 2.65rem 1.1rem;
  }

  .authority-band h2,
  .hub-insights h2,
  .hub-overview-box h2 {
    font-size: 1.45rem;
  }

  .authority-metrics,
  .authority-topic-grid,
  .report-findings {
    grid-template-columns: 1fr;
  }

  .authority-metric {
    min-height: 0;
  }

  .authority-founder-hero {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }

  .authority-avatar {
    width: 82px;
  }

  .authority-definition-list > div {
    grid-template-columns: 1fr;
    gap: .35rem;
  }

  .authority-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .authority-button {
    width: 100%;
  }

  .hub-overview-box {
    padding-inline-start: 1rem;
  }
}
