/* ==========================================================================
   FOLS Advocacia — componentes de dados (v2)
   Faixa de bancários na home + cards de profissão / CATs.
   Depende dos tokens definidos em styles.css.
   ========================================================================== */

/* ---------- Faixa de bancários na home ---------- */
.bank-spotlight {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  align-items: center;
  gap: clamp(24px, 4vw, 52px);
  margin-top: 18px;
  padding: clamp(24px, 3.2vw, 38px);
  border: 1px solid var(--pine);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(560px 340px at 96% 0%, rgba(90, 127, 127, 0.3), transparent 68%),
    radial-gradient(420px 280px at 2% 100%, rgba(176, 122, 50, 0.14), transparent 70%),
    var(--pine);
  color: var(--cream);
}
.bank-spotlight-copy { max-width: 52ch; }
.bank-spotlight-copy .kicker {
  display: inline-block;
  margin-bottom: 10px;
  color: var(--accent-soft);
}
.bank-spotlight-title {
  margin: 0 0 8px;
  color: var(--cream);
  font-family: var(--font-display);
  font-size: clamp(30px, 3.2vw, 42px);
  font-weight: 500;
  line-height: 1.05;
  letter-spacing: -0.015em;
}
.bank-spotlight-copy p {
  max-width: 48ch;
  margin: 0;
  color: rgba(246, 241, 231, 0.74);
  font-size: 15px;
  line-height: 1.62;
}
.bank-spotlight-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 16px;
  margin-top: 20px;
}
.bank-spotlight-actions .btn { flex: none; }
.bank-spotlight-copy .bank-spotlight-note {
  max-width: 52ch;
  margin: 0;
  color: rgba(246, 241, 231, 0.64);
  font-size: 10px;
  line-height: 1.45;
}
.bank-spotlight-note a {
  color: var(--accent-soft);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.bank-spotlight-secondary {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: rgba(246, 241, 231, 0.78);
  font-size: 12.5px;
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.bank-spotlight-secondary:hover { color: var(--cream); }
.bank-spotlight-note a {
  color: var(--accent-soft);
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ---------- Lista de CATs ---------- */
.cat-panel {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}
.cat-panel--dark {
  border-color: rgba(246, 241, 231, 0.18);
  background: rgba(246, 241, 231, 0.06);
  color: var(--cream);
}
.cat-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.12em;
  line-height: 1.3;
  text-transform: uppercase;
}
.cat-panel--dark .cat-head {
  border-bottom-color: rgba(246, 241, 231, 0.16);
  color: rgba(246, 241, 231, 0.68);
}
.cat-badge {
  padding: 4px 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 9.5px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: none;
}
.cat-panel--dark .cat-badge {
  border-color: rgba(228, 200, 138, 0.34);
  color: var(--accent-soft);
}
.cat-list {
  display: grid;
  gap: 12px;
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
}
.cat-row {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr) auto;
  gap: 7px 10px;
  align-items: center;
}
.cat-code {
  justify-self: start;
  padding: 3px 6px;
  border-radius: 6px;
  background: var(--sage-soft);
  color: var(--sage-ink);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.3;
  white-space: nowrap;
}
.cat-name {
  min-width: 0;
  color: var(--ink);
  font-size: 13px;
  line-height: 1.35;
}
.cat-pct {
  color: var(--ink);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  line-height: 1.3;
  white-space: nowrap;
}
.cat-bar {
  grid-column: 1 / -1;
  height: 4px;
  margin-top: -1px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--line);
}
.cat-bar span {
  display: block;
  width: var(--pct);
  height: 100%;
  border-radius: inherit;
  background: var(--sage-ink);
}
.cat-panel--dark .cat-code {
  background: rgba(246, 241, 231, 0.12);
  color: var(--accent-soft);
}
.cat-panel--dark .cat-name,
.cat-panel--dark .cat-pct { color: rgba(246, 241, 231, 0.9); }
.cat-panel--dark .cat-bar { background: rgba(246, 241, 231, 0.14); }
.cat-panel--dark .cat-bar span { background: var(--accent-soft); }
.cat-note {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.5;
}
.cat-panel--dark .cat-note { color: rgba(246, 241, 231, 0.58); }

/* ---------- Cards de profissão (página de bancários) ---------- */
.profession-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.profession-card {
  padding: clamp(20px, 2.4vw, 28px);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
}
.profession-head {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}
.profession-icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--sage-soft);
  color: var(--pine);
}
.profession-icon .icon { width: 22px; height: 22px; }
.profession-kicker {
  display: block;
  margin-bottom: 2px;
  color: var(--muted);
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.12em;
  line-height: 1.3;
  text-transform: uppercase;
}
.profession-head h3 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(24px, 2.4vw, 30px);
  font-weight: 500;
  line-height: 1.1;
}
.profession-tag {
  padding: 4px 8px;
  border: 1px solid rgba(176, 122, 50, 0.34);
  border-radius: 999px;
  color: var(--accent-ink);
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.06em;
  line-height: 1.3;
  white-space: nowrap;
}
.profession-card .cat-list { margin-top: 0; }
.profession-card .cat-note { margin-top: 16px; }
.profession-meta {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.5;
}
.profession-meta strong {
  color: var(--ink-soft);
  font-weight: 600;
}

/* ---------- Carrossel de profissões (home) ---------- */
.prof-carousel {
  min-width: 0;
}
.prof-carousel-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(246, 241, 231, 0.16);
}
.prof-carousel-caption {
  color: rgba(246, 241, 231, 0.68);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.12em;
  line-height: 1.3;
  text-transform: uppercase;
}
.prof-carousel-actions { display: flex; align-items: center; gap: 8px; }
.prof-carousel-btn {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid rgba(246, 241, 231, 0.22);
  border-radius: 8px;
  background: transparent;
  color: rgba(246, 241, 231, 0.8);
  cursor: pointer;
  transition: background 0.2s var(--ease), color 0.2s var(--ease);
}
.prof-carousel-btn:hover {
  background: rgba(246, 241, 231, 0.1);
  color: var(--cream);
}
.prof-carousel-btn .icon { width: 14px; height: 14px; }
.prof-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 12px 0 0;
}
.prof-tab {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 8px 10px;
  border: 1px solid rgba(246, 241, 231, 0.2);
  border-radius: 999px;
  background: transparent;
  color: rgba(246, 241, 231, 0.66);
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 10px;
  font-weight: 500;
  line-height: 1.3;
  text-align: left;
  transition: background 0.2s var(--ease), color 0.2s var(--ease),
    border-color 0.2s var(--ease);
}
.prof-tab:hover { color: var(--cream); border-color: rgba(246, 241, 231, 0.4); }
.prof-tab.is-active,
.prof-tab[aria-selected="true"] {
  border-color: var(--accent-soft);
  background: var(--accent-soft);
  color: var(--pine);
}
.prof-stage { min-height: 264px; margin-top: 14px; }
.prof-slide[hidden] { display: none; }
.prof-slide.is-active { animation: prof-fade 0.22s var(--ease) both; }
@keyframes prof-fade {
  from { opacity: 0; transform: translateY(3px); }
  to { opacity: 1; transform: translateY(0); }
}
.prof-slide-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(246, 241, 231, 0.16);
}
.prof-slide-kicker {
  display: block;
  margin-bottom: 2px;
  color: rgba(246, 241, 231, 0.58);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.12em;
  line-height: 1.3;
  text-transform: uppercase;
}
.prof-slide-head h4 {
  margin: 0;
  color: var(--cream);
  font-family: var(--font-display);
  font-size: 25px;
  font-weight: 500;
  line-height: 1.05;
}
.prof-slide-total {
  flex: none;
  color: rgba(246, 241, 231, 0.62);
  font-size: 9.5px;
  line-height: 1.4;
  text-align: right;
}
.prof-slide-total strong {
  display: block;
  color: var(--accent-soft);
  font-size: 13px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.prof-slide .cat-list { margin-top: 12px; gap: 9px; }
.prof-slide-note {
  margin: 12px 0 0;
  color: rgba(246, 241, 231, 0.66);
  font-size: 10.5px;
  line-height: 1.5;
}
.prof-slide-note a { color: var(--accent-soft); }
.prof-carousel .cat-panel--dark { border: 0; background: transparent; padding: 0; }
.prof-status {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}
.prof-carousel.is-paused .prof-carousel-btn[data-prof-pause] {
  border-color: rgba(228, 200, 138, 0.5);
  color: var(--accent-soft);
}
@media (prefers-reduced-motion: reduce) {
  .prof-slide.is-active { animation: none; }
}

.data-cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px 24px;
  margin-top: 16px;
  padding: 18px 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper-deep);
}
.data-cta strong {
  display: block;
  margin-bottom: 2px;
  color: var(--ink);
  font-size: 14px;
  font-weight: 600;
}
.data-cta span { color: var(--muted); font-size: 12.5px; line-height: 1.5; }
.data-disclaimer {
  max-width: 78ch;
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.6;
}
.data-disclaimer strong { color: var(--ink-soft); font-weight: 600; }
.data-disclaimer a {
  color: var(--sage-ink);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.data-source-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 44px;
  margin-top: 6px;
  color: var(--sage-ink);
  font-size: 12px;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.data-source-link .icon { width: 14px; height: 14px; }

@media (max-width: 960px) {
  .bank-spotlight { grid-template-columns: 1fr; }
  .profession-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  .bank-spotlight { padding: 22px; }
  .bank-spotlight-actions .btn { width: 100%; }
  .profession-grid { grid-template-columns: 1fr; }
  .cat-panel { padding: 16px; }
  .cat-row { grid-template-columns: 48px minmax(0, 1fr) auto; }
  .prof-carousel-top { align-items: flex-start; }
  .prof-stage { min-height: 300px; }
}
@media (max-width: 420px) {
  .bank-spotlight { padding: 18px; border-radius: var(--radius); }
  .cat-head { font-size: 10px; }
  .cat-badge { font-size: 9px; }
  .cat-name { font-size: 12.5px; }
}

/* Fallback sem JavaScript: mostra todos os painéis, sem controles */
html:not(.js) .prof-slide[hidden] { display: block !important; }
html:not(.js) .prof-tabs,
html:not(.js) .prof-carousel-actions { display: none !important; }
