:root {
  --creme: #F4F1EA;
  --creme-claro: #FAF8F4;
  --cafe: #4A2B1D;
  --espresso: #2A1B14;
  --terracota: #B26034;
  --terracota-escuro: #9B5219;
  --taupe: #8A6A55;
  --borda: #DFD5C8;
  --alerta-bg: #F9EFEA;
  --sucesso-bg: #F1EFE6;
  --radius: 14px;
  --shadow: 0 8px 24px rgba(42, 27, 20, 0.06);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background-color: var(--creme);
  color: var(--cafe);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.container {
  max-width: 1020px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Header */
.site-header {
  background: var(--creme-claro);
  border-bottom: 1px solid var(--borda);
  padding: 14px 0;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--cafe);
}

.brand-logo {
  width: 44px;
  height: 44px;
  object-fit: contain;
}

.brand-text {
  display: flex;
  flex-direction: column;
}

.brand-name {
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.14em;
  color: var(--espresso);
}

.brand-sub {
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  color: var(--taupe);
}

/* Nav pills */
.tools-nav {
  background: var(--creme);
  border-bottom: 1px solid var(--borda);
  position: sticky;
  top: 0;
  z-index: 20;
}

.nav-scroll {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 12px 20px;
  scrollbar-width: none;
}

.nav-scroll::-webkit-scrollbar {
  display: none;
}

.nav-pill {
  background: transparent;
  border: 1px solid var(--borda);
  color: var(--cafe);
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.nav-pill:hover {
  border-color: var(--terracota);
  color: var(--terracota-escuro);
}

.nav-pill.active {
  background: var(--terracota);
  border-color: var(--terracota);
  color: var(--creme);
}

/* Main */
.main-content {
  padding-top: 28px;
  padding-bottom: 56px;
}

.view {
  display: none;
}

.view.active {
  display: block;
  animation: fadeIn 0.22s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

.eyebrow {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  color: var(--terracota-escuro);
  margin-bottom: 8px;
  text-transform: uppercase;
}

h1 {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: clamp(1.9rem, 4vw, 2.7rem);
  line-height: 1.12;
  color: var(--espresso);
  margin-bottom: 12px;
  font-weight: 700;
}

h1 em, h2 em {
  font-style: italic;
  color: var(--terracota);
}

.subtitle, .hero-lead {
  color: var(--taupe);
  font-size: 1rem;
  max-width: 700px;
}

/* Hero & Hub */
.hero-card {
  background: var(--creme-claro);
  border: 1px solid var(--borda);
  border-radius: var(--radius);
  padding: 32px;
  margin-bottom: 24px;
  box-shadow: var(--shadow);
}

.hero-quote {
  margin-top: 18px;
  display: inline-block;
  background: var(--terracota);
  color: var(--creme);
  padding: 6px 14px;
  border-radius: 6px;
  font-size: 0.88rem;
  font-weight: 500;
}

.hub-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.tool-card {
  background: var(--creme-claro);
  border: 1px solid var(--borda);
  border-radius: var(--radius);
  padding: 24px;
  cursor: pointer;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.tool-card:hover {
  transform: translateY(-2px);
  border-color: var(--terracota);
  box-shadow: var(--shadow);
}

.tool-card-wide {
  grid-column: 1 / -1;
}

.tool-badge {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  color: var(--terracota);
  margin-bottom: 8px;
}

.tool-card h2 {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.45rem;
  line-height: 1.2;
  color: var(--espresso);
  margin-bottom: 8px;
}

.tool-card p {
  font-size: 0.92rem;
  color: var(--taupe);
  margin-bottom: 16px;
}

.tool-link {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--terracota-escuro);
}

/* Cards & Forms */
.section-head {
  margin-bottom: 20px;
}

.card {
  background: var(--creme-claro);
  border: 1px solid var(--borda);
  border-radius: var(--radius);
  padding: 26px;
  box-shadow: var(--shadow);
  margin-bottom: 22px;
}

.card-title {
  font-size: 1.05rem;
  color: var(--espresso);
  margin-bottom: 16px;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.field span {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--cafe);
}

.field input, .field select {
  padding: 11px 12px;
  border: 1px solid var(--borda);
  border-radius: 8px;
  background: #FFFDF9;
  color: var(--espresso);
  font-size: 0.95rem;
  font-family: inherit;
}

.field input:focus, .field select:focus {
  outline: none;
  border-color: var(--terracota);
}

.divider {
  border: none;
  border-top: 1px solid var(--borda);
  margin: 24px 0;
}

/* Quiz & Checklists */
.quiz-list {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.quiz-item {
  padding-bottom: 14px;
  border-bottom: 1px solid var(--borda);
}

.quiz-q {
  font-weight: 600;
  margin-bottom: 10px;
  color: var(--espresso);
}

.radio-group {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
}

.radio-group label, .inline-check {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.93rem;
  cursor: pointer;
}

.checklist-questions {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.check-card {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px;
  background: var(--creme);
  border: 1px solid var(--borda);
  border-radius: 10px;
  cursor: pointer;
  font-size: 0.94rem;
}

.check-card input, .inline-check input {
  margin-top: 3px;
  accent-color: var(--terracota);
  width: 17px;
  height: 17px;
}

.check-options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 12px;
  margin-top: 18px;
}

/* Buttons */
.actions-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 22px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 20px;
  border-radius: 8px;
  font-size: 0.92rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.18s ease;
}

.btn-sm {
  padding: 8px 14px;
  font-size: 0.84rem;
}

.btn-primary {
  background: var(--terracota);
  color: var(--creme);
}

.btn-primary:hover {
  background: var(--terracota-escuro);
}

.btn-outline {
  background: transparent;
  border-color: var(--terracota);
  color: var(--terracota-escuro);
}

.btn-outline:hover {
  background: var(--alerta-bg);
}

/* Result Box */
.result-box {
  background: var(--creme-claro);
  border: 1px solid var(--terracota);
  border-left: 5px solid var(--terracota);
  border-radius: var(--radius);
  padding: 26px;
  margin-bottom: 24px;
  box-shadow: var(--shadow);
}

.result-box.hidden {
  display: none;
}

.result-box h3 {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.5rem;
  color: var(--espresso);
  margin-bottom: 12px;
}

.kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 14px;
  margin: 16px 0;
}

.kpi {
  background: var(--creme);
  border: 1px solid var(--borda);
  border-radius: 10px;
  padding: 14px;
}

.kpi-label {
  font-size: 0.78rem;
  color: var(--taupe);
  display: block;
}

.kpi-value {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--terracota-escuro);
}

.result-list {
  margin: 12px 0 0 18px;
}

.result-list li {
  margin-bottom: 6px;
}

.badge-status {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 700;
  margin-bottom: 10px;
}

.badge-ok { background: #E7ECE2; color: #354728; }
.badge-warn { background: #F7E8D8; color: #8A4513; }
.badge-high { background: #F5DDD8; color: #7C2318; }

/* OAB CTA Box */
.oab-cta-box {
  background: var(--espresso);
  color: var(--creme);
  border-radius: var(--radius);
  padding: 28px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-top: 28px;
}

.oab-cta-box .eyebrow {
  color: #D79C79;
}

.oab-cta-content {
  flex: 1 1 500px;
}

.oab-cta-content h3 {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.45rem;
  margin-bottom: 6px;
}

.oab-disclaimer {
  margin-top: 10px;
  font-size: 0.78rem;
  color: #CBB8AD;
  line-height: 1.45;
}

.oab-cta-action {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}

.cta-phone {
  font-size: 0.8rem;
  color: #CBB8AD;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--borda);
  padding: 20px 0;
  font-size: 0.84rem;
  color: var(--taupe);
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}

.footer-inner a {
  color: var(--terracota-escuro);
  text-decoration: none;
}

/* Print / PDF */
.only-print {
  display: none;
}

@media print {
  body {
    background: #FFFFFF;
    color: #2A1B14;
  }
  .no-print {
    display: none !important;
  }
  .only-print {
    display: flex !important;
  }
  .print-header {
    align-items: center;
    gap: 14px;
    border-bottom: 2px solid #9B5219;
    padding-bottom: 12px;
    margin-bottom: 20px;
    font-size: 0.85rem;
  }
  .print-logo {
    width: 48px;
    height: 48px;
    object-fit: contain;
  }
  .card, .result-box {
    box-shadow: none;
    border-color: #CBB8AD;
    break-inside: avoid;
  }
  .oab-cta-box {
    background: #F4F1EA;
    color: #2A1B14;
    border: 1px solid #9B5219;
  }
  .oab-disclaimer {
    color: #4A2B1D;
  }
}

@media (max-width: 720px) {
  .hub-grid {
    grid-template-columns: 1fr;
  }
  .brand-sub {
    display: none;
  }
  .hero-card, .card, .result-box {
    padding: 20px;
  }
}
