/* Free Resources — theme-aware, screenshot-aligned layout */

.rc-wrap {
  max-width: 920px;
  margin-inline: auto;
}

.rc-hero {
  padding: 2.75rem 0 2rem;
  background: var(--bg-primary);
  border-bottom: 1px solid var(--border);
}
.rc-eyebrow {
  margin: 0 0 .4rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  font-size: .72rem;
  font-weight: 700;
  color: var(--muted);
  text-align: center;
}
.rc-hero h1 {
  margin: 0;
  text-align: center;
  font-size: clamp(1.85rem, 4vw, 2.45rem);
  letter-spacing: -.03em;
  color: var(--navy);
}
.rc-lead {
  text-align: center;
  color: var(--muted);
  max-width: 36rem;
  margin: .65rem auto 0;
  font-size: 1.02rem;
}

.rc-search {
  display: flex;
  gap: .5rem;
  margin-top: 1.35rem;
  flex-wrap: wrap;
  justify-content: center;
}
.rc-search input[type="search"] {
  flex: 1 1 280px;
  max-width: 520px;
  min-height: 48px;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: .75rem 1rem;
  font: inherit;
  background: var(--input-bg);
  color: var(--input-text);
}
.rc-search .btn { min-height: 48px; width: auto; padding: .75rem 1.25rem; }

.rc-section { padding: 2rem 0; }
.rc-heading {
  text-align: center;
  margin: 0 0 1.35rem;
  font-size: 1.35rem;
  color: var(--navy);
  font-weight: 800;
}
.rc-subhead {
  margin: 0 0 1rem;
  font-size: 1.05rem;
  color: var(--navy);
}
.rc-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

/* Top 2×2 hub cards */
.rc-hub-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}
@media (min-width: 720px) {
  .rc-hub-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.15rem; }
}
.rc-hub-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1.35rem 1.4rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: .55rem;
  min-height: 168px;
  box-shadow: var(--shadow-sm);
  transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease, background-color .25s ease;
}
.rc-hub-card:hover {
  border-color: color-mix(in srgb, var(--brand) 35%, var(--border));
  box-shadow: var(--shadow);
  transform: translateY(-1px);
}
.rc-hub-card:focus-within {
  outline: 2px solid color-mix(in srgb, var(--brand) 45%, transparent);
  outline-offset: 2px;
}
.rc-hub-card h2 {
  margin: 0;
  font-size: 1.15rem;
  color: var(--navy);
  font-weight: 800;
}
.rc-hub-card p {
  margin: 0;
  flex: 1;
  color: var(--muted);
  font-size: .95rem;
  line-height: 1.5;
}
.rc-hub-link {
  color: var(--brand);
  font-weight: 700;
  font-size: .92rem;
  text-decoration: none;
  align-self: flex-start;
}
.rc-hub-link:hover { text-decoration: underline; color: var(--brand-dark); }

/* Documentation categories — one row on desktop */
.rc-doc-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: .85rem;
}
@media (min-width: 560px) {
  .rc-doc-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 960px) {
  .rc-doc-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
.rc-doc-card {
  display: flex;
  flex-direction: column;
  gap: .35rem;
  padding: 1.15rem 1.1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  text-decoration: none;
  color: inherit;
  min-height: 110px;
  transition: border-color .15s ease, transform .15s ease, background-color .25s ease;
}
.rc-doc-card:hover,
.rc-doc-card:focus-visible {
  border-color: var(--brand);
  transform: translateY(-1px);
  outline: none;
}
.rc-doc-card strong {
  font-size: 1rem;
  color: var(--navy);
}
.rc-doc-card span {
  font-size: .86rem;
  color: var(--muted);
  line-height: 1.45;
}

/* Popular / search articles */
.rc-article-list {
  display: grid;
  gap: .85rem;
}
.rc-article {
  display: flex;
  flex-direction: column;
  gap: .35rem;
  padding: 1.15rem 1.25rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  text-decoration: none;
  color: inherit;
  transition: border-color .15s ease, background-color .25s ease;
}
.rc-article:hover,
.rc-article:focus-visible {
  border-color: var(--brand);
  outline: none;
}
.rc-article strong {
  font-size: 1.05rem;
  color: var(--navy);
}
.rc-article p {
  margin: 0;
  color: var(--muted);
  font-size: .92rem;
}
.rc-tag {
  align-self: flex-start;
  font-size: .72rem;
  text-transform: uppercase;
  letter-spacing: .06em;
  font-weight: 700;
  color: var(--brand);
  background: var(--brand-soft);
  padding: .15rem .55rem;
  border-radius: 999px;
}

.rc-empty {
  text-align: center;
  padding: 2rem 1.25rem;
  background: var(--surface);
  border: 1px dashed var(--border);
  border-radius: 14px;
  color: var(--ink);
}
.rc-empty strong { display: block; color: var(--navy); margin-bottom: .35rem; }
.rc-empty p { margin: 0; color: var(--muted); }

/* Shared FAQ / pager (legacy class names kept) */
.help-faq-list { display: grid; gap: .55rem; }
.help-faq-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: .85rem 1rem;
  color: var(--ink);
}
.help-faq-item summary { cursor: pointer; font-weight: 650; color: var(--navy); }
.help-faq-body { margin-top: .65rem; color: var(--muted); }

.help-pager { display: flex; gap: .35rem; margin-top: 1.25rem; flex-wrap: wrap; justify-content: center; }
.help-pager a {
  min-width: 2rem;
  text-align: center;
  padding: .35rem .55rem;
  border-radius: 8px;
  border: 1px solid var(--border);
  text-decoration: none;
  color: inherit;
  background: var(--surface);
}
.help-pager a.active { background: var(--brand); color: #fff; border-color: var(--brand); }

.help-hero, .help-hero-sm {
  padding: 2rem 0 1.5rem;
  background: var(--subhead-bg, var(--bg-secondary));
  border-bottom: 1px solid var(--border);
  transition: var(--theme-transition, background-color .25s ease);
}
.help-hero h1, .help-hero-sm h1 { color: var(--navy); margin: 0; }
.help-hero .lead, .help-hero-sm .lead { color: var(--subhead-fg, var(--muted)); }
.help-detail { max-width: 760px; }
.help-body { line-height: 1.65; color: var(--ink); }
.help-actions { display: flex; flex-wrap: wrap; gap: .65rem; margin-top: 1.25rem; }
.help-eyebrow {
  margin: 0 0 .4rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  font-size: .72rem;
  color: var(--muted);
}

.nav-desktop a.is-active,
.mobile-drawer .panel a.is-active {
  background: var(--brand-soft);
  color: var(--brand);
}

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); border: 0;
}

@media (max-width: 390px) {
  .rc-hub-card { min-height: 0; padding: 1.15rem 1.1rem; }
  .rc-hero { padding: 2rem 0 1.5rem; }
}
