@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=IBM+Plex+Mono:wght@400;500;600&display=swap");

:root {
  --bg: #eef2f6;
  --surface: #ffffff;
  --surface-2: #f7f9fc;
  --surface-3: #e9eef5;
  --text: #122033;
  --muted: #516073;
  --muted-2: #6e7d91;
  --border: #d6dee8;
  --brand: #0f4c81;
  --brand-2: #145d9d;
  --brand-soft: #e8f1fa;
  --accent: #d97706;
  --accent-soft: #fff3df;
  --success-bg: #e6f6e9;
  --success-text: #17603a;
  --warning-bg: #fff3dd;
  --warning-text: #915b05;
  --danger-bg: #fde8e8;
  --danger-text: #9a2525;
  --shadow: 0 18px 40px rgba(18, 32, 51, 0.08);
  --radius: 18px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "Inter", Arial, Helvetica, sans-serif;
  background:
    linear-gradient(180deg, #dfe7f0 0, #eef2f6 120px, #eef2f6 100%),
    var(--bg);
  color: var(--text);
  line-height: 1.62;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image: linear-gradient(rgba(15, 76, 129, 0.025) 1px, transparent 1px), linear-gradient(90deg, rgba(15, 76, 129, 0.025) 1px, transparent 1px);
  background-size: 28px 28px;
  mask-image: linear-gradient(180deg, rgba(0,0,0,.25), transparent 70%);
}
a { color: inherit; text-decoration: none; }
.container {
  width: min(1160px, calc(100% - 28px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(247,249,252,0.94);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(18, 32, 51, 0.08);
  box-shadow: 0 8px 24px rgba(18, 32, 51, 0.04);
}
.site-header::before {
  content: "Ferramentas de obra e reforma";
  display: block;
  font-family: "IBM Plex Mono", monospace;
  font-size: .72rem;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: #dbeafe;
  background: linear-gradient(90deg, #10263b, #16344f);
  padding: 7px calc((100vw - min(1160px, calc(100% - 28px))) / 2 + 2px);
}
.nav {
  min-height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.logo {
  display: inline-flex;
  flex-direction: column;
  gap: 2px;
  font-weight: 800;
  letter-spacing: -.04em;
  font-size: 1.2rem;
  color: var(--text);
}
.logo::after {
  content: "calculadoras práticas";
  font-size: .68rem;
  text-transform: uppercase;
  letter-spacing: .09em;
  color: var(--muted-2);
  font-family: "IBM Plex Mono", monospace;
  font-weight: 600;
}
.nav-links {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}
.nav-links a {
  font-size: .88rem;
  color: var(--muted);
  padding: 9px 12px;
  border-radius: 999px;
  border: 1px solid transparent;
  transition: .18s ease;
}
.nav-links a:hover,
.nav-links a:focus-visible {
  border-color: var(--border);
  background: var(--surface);
  color: var(--brand);
}
.nav-links a[href="empresas.html"],
.nav-links a[href="guias.html"] {
  font-weight: 700;
  color: var(--brand);
}

.hero { padding: 54px 0 34px; }
.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  gap: 26px;
  align-items: start;
}
.kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--brand-soft);
  color: var(--brand);
  border: 1px solid rgba(15,76,129,.15);
  border-radius: 999px;
  padding: 7px 12px;
  font-size: .76rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: 14px;
}
.kicker::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px rgba(217,119,6,.14);
}
h1, h2, h3 { line-height: 1.08; margin: 0 0 14px; letter-spacing: -.04em; }
h1 { font-size: clamp(2.4rem, 5vw, 4.2rem); max-width: 11ch; }
h2 { font-size: clamp(1.55rem, 3vw, 2.25rem); }
h3 { font-size: 1.08rem; }
.lead {
  color: var(--muted);
  font-size: 1.05rem;
  max-width: 760px;
  margin: 0 0 22px;
}
.actions { display: flex; flex-wrap: wrap; gap: 10px; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 16px;
  border-radius: 13px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font-weight: 700;
  box-shadow: 0 8px 18px rgba(18, 32, 51, 0.05);
  transition: transform .15s ease, border-color .15s ease, background .15s ease;
}
.button:hover { transform: translateY(-1px); border-color: #b8c8da; }
.button.primary {
  color: #fff;
  background: linear-gradient(180deg, var(--brand-2), var(--brand));
  border-color: var(--brand);
}
.card {
  background: linear-gradient(180deg, rgba(255,255,255,.96), rgba(255,255,255,1));
  border: 1px solid rgba(18, 32, 51, 0.08);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.hero-card {
  padding: 24px;
  position: relative;
  overflow: hidden;
}
.hero-card::before {
  content: "PAINEL";
  position: absolute;
  top: 16px;
  right: 18px;
  font-family: "IBM Plex Mono", monospace;
  font-size: .72rem;
  color: var(--muted-2);
  letter-spacing: .08em;
}
.trust-list p {
  margin: 0 0 14px;
  color: var(--muted);
  padding-left: 16px;
  border-left: 3px solid var(--surface-3);
}

.section { padding: 34px 0; }
.section.tight { padding-top: 24px; padding-bottom: 24px; }
.grid-2, .grid-3 {
  display: grid;
  gap: 18px;
}
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.tool-card, .tool-item {
  display: block;
  padding: 22px;
  background: linear-gradient(180deg, #fff, #f8fafc);
  border: 1px solid rgba(18,32,51,.1);
  border-radius: 18px;
  box-shadow: 0 10px 24px rgba(18, 32, 51, 0.05);
  transition: transform .16s ease, box-shadow .16s ease, border-color .16s ease;
  position: relative;
  overflow: hidden;
}
.tool-card::before, .tool-item::before {
  content: "ferramenta";
  position: absolute;
  top: 14px;
  right: 16px;
  font-family: "IBM Plex Mono", monospace;
  color: var(--muted-2);
  font-size: .68rem;
  text-transform: uppercase;
}
.tool-card:hover, .tool-item:hover {
  transform: translateY(-2px);
  border-color: #bdd3e7;
  box-shadow: 0 16px 30px rgba(18,32,51,.09);
}
.tool-card h3, .tool-item strong {
  padding-right: 80px;
  margin-bottom: 8px;
}
.tool-card p, .tool-item span, .info-card p, .content-block p {
  color: var(--muted);
}
.info-card { padding: 22px; }

.page-title {
  padding: 38px 0 18px;
}
.breadcrumb {
  color: var(--muted-2);
  font-size: .88rem;
  margin-bottom: 14px;
  font-family: "IBM Plex Mono", monospace;
}
.breadcrumb a { color: var(--brand); font-weight: 600; }
.breadcrumb span { margin: 0 6px; }
.page-title h1 { max-width: 14ch; }
.page-title .lead { margin-bottom: 0; max-width: 860px; }

.calculator-shell {
  display: grid;
  grid-template-columns: .9fr 1.1fr;
  gap: 20px;
  align-items: stretch;
}
.panel {
  padding: 22px;
  position: relative;
}
.panel > h2:first-child {
  margin-bottom: 18px;
  font-size: 1.45rem;
}
.panel > h2:first-child::after {
  content: "";
  display: block;
  width: 54px;
  height: 4px;
  border-radius: 999px;
  margin-top: 10px;
  background: linear-gradient(90deg, var(--accent), transparent);
}
.field { margin-bottom: 16px; }
label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-weight: 800;
  margin-bottom: 7px;
}
.help {
  display: block;
  color: var(--muted-2);
  font-size: .86rem;
  margin-top: 6px;
}
input, select {
  width: 100%;
  border: 1px solid #cfd8e3;
  border-radius: 12px;
  min-height: 48px;
  padding: 0 12px;
  font-size: 1rem;
  background: #fff;
  color: var(--text);
  font-family: "IBM Plex Mono", monospace;
}
input:focus, select:focus {
  outline: 3px solid rgba(15, 76, 129, .12);
  border-color: var(--brand);
}

.visual {
  min-height: 280px;
  border: 1px solid #d4deea;
  border-radius: 18px;
  background: linear-gradient(180deg, #f8fafc, #eef3f8);
  position: relative;
  overflow: hidden;
  margin-bottom: 18px;
}
.visual::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(rgba(15,76,129,.06) 1px, transparent 1px), linear-gradient(90deg, rgba(15,76,129,.06) 1px, transparent 1px);
  background-size: 18px 18px;
}
.visual::after {
  content: "prévia técnica";
  position: absolute;
  top: 12px;
  right: 14px;
  font-family: "IBM Plex Mono", monospace;
  color: var(--muted-2);
  font-size: .7rem;
  text-transform: uppercase;
}
.ramp-base, .ramp-height, .ramp-line {
  position: absolute;
  left: 28px;
  bottom: 42px;
  transform-origin: left bottom;
  z-index: 2;
}
.ramp-base { height: 3px; background: #718096; }
.ramp-height { width: 3px; background: #718096; left: auto; }
.ramp-line { height: 5px; background: var(--brand); border-radius: 20px; }
.stair-draw {
  position: absolute;
  left: 28px;
  bottom: 42px;
  display: flex;
  align-items: flex-end;
  z-index: 2;
}
.step {
  border-top: 4px solid var(--brand);
  border-right: 4px solid var(--brand);
}
.results {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 16px;
}
.result {
  background: linear-gradient(180deg, #fff, #f6f8fb);
  border: 1px solid #dde5ee;
  border-radius: 16px;
  padding: 16px;
  position: relative;
  overflow: hidden;
}
.result::before {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 4px;
  background: linear-gradient(90deg, var(--brand), transparent 72%);
}
.result span {
  display: block;
  color: var(--muted-2);
  font-family: "IBM Plex Mono", monospace;
  font-size: .74rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .04em;
}
.result strong {
  display: block;
  margin-top: 8px;
  font-size: 1.52rem;
  line-height: 1.1;
}
.status {
  margin-top: 14px;
  padding: 14px 16px;
  border-radius: 14px;
  font-weight: 800;
  border: 1px solid transparent;
}
.status.success { background: var(--success-bg); color: var(--success-text); border-color: rgba(23,96,58,.12); }
.status.warning { background: var(--warning-bg); color: var(--warning-text); border-color: rgba(145,91,5,.12); }
.status.danger { background: var(--danger-bg); color: var(--danger-text); border-color: rgba(154,37,37,.12); }
.status-box.neutral { background: #ebf2fb; color: #24496e; }

.field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.result-grid.bigger { grid-template-columns: 1fr 1fr; }
.excavation-drawing {
  min-height: 170px;
  margin-top: 24px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  perspective: 700px;
}
.soil-block {
  width: 190px;
  height: 90px;
  background: linear-gradient(135deg, #a65a1a, #7c4313);
  border: 1px solid rgba(124, 67, 19, .8);
  border-radius: 12px 12px 5px 5px;
  box-shadow: inset 0 14px 26px rgba(255,255,255,.08), 0 18px 34px rgba(18,32,51,.12);
  position: relative;
  transition: width .25s ease, height .25s ease;
}
.soil-block::before {
  content: "";
  position: absolute;
  inset: 12px;
  border-radius: 10px;
  background-image: radial-gradient(rgba(255,255,255,.2) 1px, transparent 1px);
  background-size: 14px 14px;
  opacity: .6;
}
.material-visual {
  min-height: 190px;
  display: flex;
  align-items: end;
  justify-content: center;
  gap: 14px;
  margin: 18px 0 8px;
}
.material-block {
  width: 180px;
  height: 88px;
  border-radius: 14px 14px 6px 6px;
  border: 1px solid var(--border);
  background: linear-gradient(135deg, #e5eef7, #cfdceb);
  box-shadow: inset 0 12px 24px rgba(255,255,255,.55), 0 18px 34px rgba(18, 32, 51, .10);
  transition: width .25s ease, height .25s ease;
}
.tile-grid-preview {
  width: min(280px, 90%);
  aspect-ratio: 1.35 / 1;
  border: 1px solid var(--border);
  border-radius: 14px;
  background-image: linear-gradient(#cbd5e1 1px, transparent 1px), linear-gradient(90deg, #cbd5e1 1px, transparent 1px);
  background-size: 34px 34px;
  background-color: #f8fafc;
  box-shadow: 0 18px 34px rgba(18, 32, 51, .10);
}
.paint-wall-preview {
  width: min(300px, 92%);
  height: 160px;
  border-radius: 16px;
  border: 1px solid var(--border);
  background: linear-gradient(135deg, #eff6ff, #dbeafe);
  box-shadow: inset 0 0 0 12px rgba(255,255,255,.35), 0 18px 34px rgba(18, 32, 51, .10);
  transition: opacity .25s ease;
}

.content-block {
  max-width: 900px;
}
.content-block > h2,
.guide-article > h2 {
  margin-top: 0;
}
.content-block ul, .content-block ol,
.guide-article ul, .guide-article ol {
  color: var(--muted);
  padding-left: 22px;
}
.content-block li, .guide-article li { margin-bottom: 8px; }
.notice {
  background: var(--accent-soft);
  border: 1px solid #fbd38d;
  color: #8a5400;
  border-radius: 14px;
  padding: 16px;
  margin: 18px 0;
}
.formula-box {
  background: linear-gradient(180deg, #fff, #f8fafc);
  border: 1px dashed #bfd0e3;
  border-radius: 14px;
  padding: 16px 18px;
  margin: 18px 0;
  font-family: "IBM Plex Mono", monospace;
  font-size: .95rem;
}
details {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 16px 18px;
  margin: 12px 0;
  box-shadow: 0 8px 24px rgba(18, 32, 51, .04);
}
summary {
  cursor: pointer;
  font-weight: 800;
}
details p { margin-bottom: 0; }
.related {
  background: transparent;
}
.related .content-block {
  background: linear-gradient(180deg, #f9fbfd, #f4f7fb);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 22px;
}

.guide-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 24px;
  align-items: start;
}
.guide-article {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 26px;
  box-shadow: var(--shadow);
}
.guide-aside {
  position: sticky;
  top: 116px;
}
.task-list li {
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}
.task-list li:last-child { border-bottom: 0; }

.site-footer {
  margin-top: 48px;
  padding: 30px 0 36px;
  border-top: 1px solid rgba(18,32,51,.08);
  background: rgba(255,255,255,.45);
  color: var(--muted);
  font-size: .92rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 22px;
}
.footer-grid nav {
  display: flex;
  gap: 12px 16px;
  flex-wrap: wrap;
  align-content: start;
}
.footer-grid nav a:hover { color: var(--brand); }

.home-tool-matrix {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 12px;
  margin-top: 18px;
}
.home-tool-matrix a {
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface-2);
  padding: 14px 16px;
  font-weight: 700;
  display: flex;
  justify-content: space-between;
  gap: 12px;
}
.home-tool-matrix a span {
  color: var(--muted-2);
  font-family: "IBM Plex Mono", monospace;
  font-size: .72rem;
  text-transform: uppercase;
}
.brand-section {
  background: linear-gradient(180deg, rgba(255,255,255,.45), rgba(255,255,255,0));
}
.metric-card p { margin: 0 0 10px; }
.ordered-clean { padding-left: 22px; margin: 18px 0 0; }
.ordered-clean li { margin: 10px 0; }

@media (max-width: 980px) {
  .nav { align-items: flex-start; flex-direction: column; padding: 14px 0 16px; }
  .site-header::before { padding-left: 14px; padding-right: 14px; }
  .hero-grid, .calculator-shell, .grid-2, .grid-3, .footer-grid { grid-template-columns: 1fr; }
  .page-title h1, h1 { max-width: none; }
}
@media (max-width: 860px) {
  .guide-layout { grid-template-columns: 1fr; }
  .guide-aside { position: static; }
}
@media (max-width: 640px) {
  .results, .field-grid, .result-grid.bigger, .home-tool-matrix { grid-template-columns: 1fr; }
  .panel { padding: 18px; }
  .visual { min-height: 220px; }
  .container { width: min(1160px, calc(100% - 20px)); }
}


/* Etapa 7.6: central de cálculo */
.site-header::before {
  content: "OC// Central de cálculo para obra";
}
.home-page .hero {
  padding: 34px 0 20px;
}
.center-shell {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: 20px;
  align-items: start;
}
.command-panel {
  padding: 26px;
}
.command-panel h1 {
  font-size: clamp(2rem, 4vw, 3.3rem);
  max-width: 13ch;
}
.command-panel .lead-inline {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 14px 0 18px;
}
.mini-chip {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--border);
  color: var(--muted);
  font-size: .84rem;
  font-weight: 700;
}
.tool-search {
  margin-top: 8px;
  margin-bottom: 16px;
}
.tool-search input {
  min-height: 56px;
  border-radius: 16px;
  padding: 0 16px;
  font-size: 1rem;
}
.search-note {
  margin-top: 8px;
  color: var(--muted-2);
  font-size: .86rem;
}
.command-side {
  padding: 0;
  overflow: hidden;
}
.command-side .side-head {
  padding: 20px 22px 14px;
  border-bottom: 1px solid var(--border);
  background: linear-gradient(180deg, #f8fbff, #f3f7fb);
}
.command-side .side-head h2 {
  font-size: 1.2rem;
  margin-bottom: 6px;
}
.command-side .side-head p { margin: 0; color: var(--muted); }
.command-links {
  display: grid;
  gap: 0;
}
.command-links a {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 14px;
  align-items: center;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  background: rgba(255,255,255,.88);
}
.command-links a:last-child { border-bottom: 0; }
.command-links a:hover { background: #f8fbff; }
.command-links strong { display: block; margin-bottom: 2px; }
.command-links small, .command-links span { color: var(--muted-2); }
.oc-code {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 76px;
  min-height: 34px;
  padding: 0 10px;
  border-radius: 999px;
  font-family: "IBM Plex Mono", monospace;
  font-size: .74rem;
  letter-spacing: .05em;
  text-transform: uppercase;
  color: var(--brand);
  background: var(--brand-soft);
  border: 1px solid rgba(15,76,129,.14);
}
.unit-pill {
  font-family: "IBM Plex Mono", monospace;
  font-size: .74rem;
  color: var(--muted-2);
}
.tool-grid-v2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 14px;
}
.tool-card-v2 {
  display: block;
  padding: 18px;
  border-radius: 18px;
  background: linear-gradient(180deg, #fff, #f8fafc);
  border: 1px solid rgba(18,32,51,.1);
  box-shadow: 0 10px 24px rgba(18,32,51,.05);
}
.tool-card-v2:hover { transform: translateY(-2px); box-shadow: 0 14px 28px rgba(18,32,51,.08); }
.tool-card-v2 .card-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin-bottom: 10px;
}
.tool-card-v2 h3 {
  margin: 0 0 6px;
  font-size: 1.02rem;
}
.tool-card-v2 p {
  margin: 0;
  color: var(--muted);
  font-size: .94rem;
}
.tool-card-v2 .card-foot {
  margin-top: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.tool-card-v2 .card-foot em {
  font-style: normal;
  color: var(--muted-2);
  font-size: .82rem;
}
.tool-card-v2 .card-foot strong {
  font-size: .84rem;
  color: var(--brand);
}
.tool-page .page-title {
  padding: 24px 0 12px;
}
.tool-page .page-title .lead {
  font-size: .98rem;
  max-width: 900px;
}
.tool-page .page-title h1 {
  font-size: clamp(1.9rem, 4vw, 2.6rem);
}
.tool-page .page-title .kicker {
  margin-bottom: 10px;
}
.tool-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}
.tool-meta-badges {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.tool-badge {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 10px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--border);
  color: var(--muted);
  font-size: .78rem;
  font-weight: 700;
}
.tool-app-shell {
  padding: 8px;
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(255,255,255,.55), rgba(255,255,255,.16));
  border: 1px solid rgba(18,32,51,.06);
}
.tool-page .calculator-shell {
  grid-template-columns: .88fr 1.12fr;
  gap: 14px;
}
.tool-page .panel {
  border-radius: 18px;
}
.tool-page .panel:first-child {
  background: linear-gradient(180deg, #f8fbff, #ffffff);
}
.tool-page .panel:last-child {
  background: linear-gradient(180deg, #ffffff, #f7f9fc);
}
.metric-strip {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin: 10px 0 0;
}
.metric-strip .mini-chip {
  background: var(--surface-2);
}
.section-head-inline {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: end;
  margin-bottom: 18px;
}
.section-head-inline p {
  margin: 0;
}
.no-results {
  display: none;
  padding: 16px;
  border-radius: 14px;
  border: 1px dashed var(--border);
  background: #fff;
  color: var(--muted);
}
@media (max-width: 980px) {
  .center-shell, .tool-page .calculator-shell, .tool-grid-v2 { grid-template-columns: 1fr; }
}


/* Etapa 7.7: assinatura de identidade */
:root {
  --brand-deep: #0d2237;
  --brand-warm: #ff8f1f;
  --brand-warm-soft: #fff0df;
}
body::after {
  content: "";
  position: fixed;
  inset: auto 0 0 0;
  height: 6px;
  background: linear-gradient(90deg, var(--brand) 0 22%, var(--brand-warm) 22% 28%, var(--brand) 28% 50%, transparent 50%);
  opacity: .9;
  pointer-events: none;
}
.logo {
  flex-direction: row;
  align-items: center;
  gap: 12px;
  font-size: 1.06rem;
}
.logo::after {
  content: "sistema de cálculo";
  display: none;
}
.logo-mark {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  background: linear-gradient(160deg, #132f4a, #0b1f31);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  box-shadow: 0 10px 20px rgba(18,32,51,.12);
  border: 1px solid rgba(255,255,255,.08);
  font-family: "IBM Plex Mono", monospace;
  font-weight: 700;
  letter-spacing: -.05em;
}
.logo-mark::before {
  content: "OC";
  position: relative;
  z-index: 2;
}
.logo-mark::after {
  content: "//";
  position: absolute;
  right: 6px;
  bottom: 5px;
  color: var(--brand-warm);
  font-family: "IBM Plex Mono", monospace;
  font-size: .72rem;
  font-weight: 700;
}
.logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1.05;
}
.logo-title {
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: -.04em;
}
.logo-sub {
  font-size: .66rem;
  text-transform: uppercase;
  letter-spacing: .11em;
  color: var(--muted-2);
  font-family: "IBM Plex Mono", monospace;
  font-weight: 600;
  margin-top: 3px;
}
.nav-links a:hover,
.nav-links a:focus-visible {
  border-color: #c3d4e6;
  background: #fff;
  color: var(--brand);
}
.nav-links a[href="index.html"] {
  position: relative;
}
.nav-links a[href="index.html"]::before {
  content: "OC";
  margin-right: 6px;
  color: var(--brand-warm);
  font-family: "IBM Plex Mono", monospace;
  font-size: .72rem;
}
.kicker, .oc-code {
  background-image: linear-gradient(180deg, #ffffff, #f6f9fd);
  box-shadow: inset 0 0 0 1px rgba(15,76,129,.08);
}
.kicker {
  position: relative;
  padding-right: 16px;
}
.kicker::after {
  content: "//";
  margin-left: 4px;
  color: var(--brand-warm);
  font-family: "IBM Plex Mono", monospace;
}
.center-shell {
  position: relative;
}
.command-panel, .command-side, .tool-card-v2, .tool-card, .panel, .guide-article, .related .content-block, .info-card {
  position: relative;
  overflow: hidden;
}
.command-panel::before, .command-side::before, .tool-card-v2::before, .tool-card::before, .panel::before, .guide-article::before, .related .content-block::before, .info-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 70px;
  height: 4px;
  background: linear-gradient(90deg, var(--brand), var(--brand-warm));
}
.command-panel::after {
  content: "OC// CORE";
  position: absolute;
  top: 18px;
  right: 18px;
  font-family: "IBM Plex Mono", monospace;
  font-size: .72rem;
  letter-spacing: .08em;
  color: rgba(81,96,115,.85);
}
.command-side .side-head {
  border-bottom: 1px solid #d9e4ef;
  background: linear-gradient(180deg, #f6fbff, #f2f7fc);
}
.command-links a {
  transition: background .16s ease, transform .16s ease;
}
.command-links a:hover {
  transform: translateX(4px);
}
.oc-code {
  min-width: 84px;
  color: var(--brand-deep);
  border-left: 3px solid var(--brand-warm);
  background: linear-gradient(180deg, #fff, #f8fafc);
}
.unit-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 68px;
  min-height: 28px;
  padding: 0 8px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: #fff;
}
.tool-card-v2, .tool-card {
  clip-path: polygon(0 0, calc(100% - 18px) 0, 100% 18px, 100% 100%, 0 100%);
}
.tool-card-v2 .card-foot strong {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.tool-card-v2 .card-foot strong::after {
  content: "→";
  color: var(--brand-warm);
}
.tool-card-v2 .card-top {
  margin-bottom: 14px;
}
.tool-card-v2 h3 {
  max-width: 18ch;
}
.no-results {
  border-style: solid;
  border-left: 4px solid var(--brand-warm);
}
.home-page .related .tool-card h3::before {
  content: "guia";
  display: inline-block;
  margin-right: 8px;
  font-family: "IBM Plex Mono", monospace;
  color: var(--brand-warm);
  font-size: .74rem;
  text-transform: uppercase;
}
.section-head-inline h2::after, .content-block h2::after, .guide-article h2::after {
  content: "";
  display: block;
  width: 56px;
  height: 4px;
  margin-top: 10px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--brand), var(--brand-warm), transparent);
}
.tool-meta-badges .tool-badge:first-child {
  border-color: rgba(255,143,31,.35);
  background: var(--brand-warm-soft);
  color: #8a4e00;
}
.tool-page .tool-app-shell {
  box-shadow: 0 20px 48px rgba(13, 34, 55, 0.08);
  background: linear-gradient(180deg, rgba(255,255,255,.68), rgba(255,255,255,.18));
}
.tool-page .panel:first-child {
  border-right: 1px dashed #d5dfeb;
}
.result {
  padding-top: 18px;
}
.result::after {
  content: attr(data-unit);
  position: absolute;
  top: 12px;
  right: 12px;
  font-family: "IBM Plex Mono", monospace;
  font-size: .66rem;
  color: var(--muted-2);
  text-transform: uppercase;
}
.status {
  border-left: 4px solid currentColor;
}
.metric-strip .mini-chip {
  border-left: 3px solid var(--brand-warm);
}
.related .content-block {
  box-shadow: var(--shadow);
}
.footer-grid {
  align-items: start;
}
.footer-grid > div strong::after {
  content: " // sistema OC";
  color: var(--brand-warm);
  font-family: "IBM Plex Mono", monospace;
  font-size: .74rem;
  font-weight: 600;
}
.identity-note {
  margin-top: 12px;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px dashed #d6dee8;
  background: #fff;
  color: var(--muted);
  font-size: .92rem;
}
.identity-note strong {
  color: var(--brand-deep);
}
@media (max-width: 720px) {
  .logo-sub { display: none; }
  .logo-mark { width: 40px; height: 40px; }
  .command-panel::after { display: none; }
}


/* Etapa 7.8: experiência mobile */
@media (max-width: 760px) {
  body {
    background: #eef2f6;
    line-height: 1.55;
  }

  body::after {
    height: 4px;
  }

  .container {
    width: min(100% - 18px, 1160px);
  }

  .site-header {
    position: sticky;
  }

  .site-header::before {
    font-size: .64rem;
    padding: 6px 10px;
    text-align: center;
  }

  .nav {
    min-height: auto;
    padding: 10px 0 12px;
    gap: 10px;
  }

  .logo {
    width: 100%;
    justify-content: center;
    gap: 10px;
  }

  .logo-mark {
    width: 38px;
    height: 38px;
    border-radius: 12px;
  }

  .logo-title {
    font-size: 1rem;
  }

  .logo-sub {
    display: block;
    font-size: .58rem;
    letter-spacing: .08em;
  }

  .nav-links {
    width: 100%;
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    gap: 8px;
    justify-content: flex-start;
    padding: 2px 0 4px;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

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

  .nav-links a {
    flex: 0 0 auto;
    padding: 8px 11px;
    font-size: .82rem;
    background: rgba(255,255,255,.72);
    border-color: rgba(214,222,232,.78);
  }

  .hero {
    padding: 18px 0 12px;
  }

  .center-shell {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .command-panel {
    padding: 18px;
    border-radius: 18px;
  }

  .command-panel::after {
    display: none;
  }

  .command-panel h1 {
    font-size: clamp(1.75rem, 9vw, 2.45rem);
    max-width: 100%;
    margin-bottom: 10px;
  }

  .lead {
    font-size: .98rem;
  }

  .lead-inline {
    gap: 8px;
  }

  .mini-chip {
    min-height: 30px;
    font-size: .78rem;
    padding: 0 10px;
  }

  .tool-search input {
    min-height: 52px;
    font-size: .92rem;
    border-radius: 14px;
  }

  .search-note {
    font-size: .8rem;
  }

  .command-side {
    border-radius: 18px;
  }

  .command-side .side-head {
    padding: 16px;
  }

  .command-side .side-head h2 {
    font-size: 1.05rem;
  }

  .command-links a {
    grid-template-columns: auto 1fr;
    padding: 14px 16px;
    gap: 12px;
  }

  .command-links .unit-pill {
    grid-column: 2;
    justify-self: start;
    min-height: 24px;
    min-width: auto;
    font-size: .68rem;
  }

  .oc-code {
    min-width: 70px;
    min-height: 30px;
    font-size: .66rem;
  }

  .section {
    padding: 24px 0;
  }

  .section.tight {
    padding-top: 18px;
    padding-bottom: 18px;
  }

  .section-head-inline {
    display: block;
    margin-bottom: 12px;
  }

  h2 {
    font-size: clamp(1.35rem, 6vw, 1.75rem);
  }

  h3 {
    font-size: 1rem;
  }

  .tool-grid-v2,
  .grid-2,
  .grid-3 {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .tool-card-v2,
  .tool-card,
  .info-card {
    padding: 16px;
    border-radius: 17px;
    clip-path: none;
  }

  .tool-card-v2 .card-top {
    margin-bottom: 10px;
  }

  .tool-card-v2 h3 {
    max-width: none;
  }

  .tool-card-v2 .card-foot {
    align-items: flex-start;
    flex-direction: column;
    gap: 6px;
    margin-top: 12px;
  }

  .page-title {
    padding: 18px 0 8px;
  }

  .breadcrumb {
    font-size: .76rem;
    white-space: nowrap;
    overflow-x: auto;
    margin-bottom: 10px;
  }

  .tool-header-row {
    display: block;
  }

  .tool-page .page-title h1 {
    font-size: clamp(1.6rem, 8vw, 2.1rem);
    line-height: 1.05;
  }

  .tool-page .page-title .lead {
    font-size: .92rem;
  }

  .tool-meta-badges {
    margin-top: 10px;
    gap: 6px;
  }

  .tool-badge {
    min-height: 28px;
    font-size: .72rem;
  }

  .tool-app-shell {
    padding: 0;
    border-radius: 18px;
    border: 0;
    background: transparent;
    box-shadow: none;
  }

  .tool-page .calculator-shell,
  .calculator-shell {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .panel {
    padding: 16px;
    border-radius: 18px;
  }

  .panel > h2:first-child {
    font-size: 1.2rem;
  }

  .field {
    margin-bottom: 13px;
  }

  label {
    font-size: .92rem;
    margin-bottom: 6px;
  }

  input, select {
    min-height: 50px;
    font-size: 16px;
    border-radius: 13px;
  }

  .help {
    font-size: .78rem;
  }

  .visual {
    min-height: 190px;
    margin-bottom: 14px;
    border-radius: 16px;
  }

  .visual::after {
    font-size: .62rem;
    top: 10px;
    right: 10px;
  }

  .results,
  .result-grid.bigger,
  .field-grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .result {
    padding: 14px 14px 16px;
    border-radius: 15px;
  }

  .result span {
    font-size: .7rem;
  }

  .result strong {
    font-size: 1.35rem;
  }

  .identity-note {
    font-size: .84rem;
    padding: 11px 12px;
    margin-top: 10px;
  }

  .status {
    font-size: .88rem;
    padding: 12px;
  }

  .content-block,
  .guide-article {
    max-width: 100%;
  }

  .content-block p,
  .guide-article p {
    font-size: .95rem;
  }

  .formula-box,
  .notice,
  details {
    padding: 14px;
    border-radius: 14px;
  }

  .guide-layout {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .guide-article {
    padding: 18px;
    border-radius: 18px;
  }

  .guide-aside {
    position: static;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .footer-grid nav {
    gap: 10px 12px;
  }

  .site-footer {
    margin-top: 30px;
    padding: 22px 0 30px;
  }
}

@media (max-width: 420px) {
  .container {
    width: min(100% - 14px, 1160px);
  }

  .command-panel,
  .panel,
  .tool-card-v2,
  .tool-card,
  .related .content-block,
  .guide-article {
    padding: 14px;
  }

  .command-links a {
    padding: 13px 14px;
  }

  .oc-code {
    min-width: 64px;
    font-size: .62rem;
  }

  .tool-page .page-title h1,
  .command-panel h1 {
    letter-spacing: -.05em;
  }

  .result strong {
    font-size: 1.25rem;
  }

  .visual {
    min-height: 175px;
  }
}



/* Etapa 7.9: estrutura de painel operacional */
.home-page .site-footer {
  margin-top: 18px;
}
.dashboard-main {
  padding: 18px 0 26px;
}
.workspace-shell {
  display: grid;
  grid-template-columns: 118px minmax(0, 1fr) 300px;
  gap: 16px;
  align-items: start;
}
.workspace-rail,
.workspace-main,
.workspace-inspector {
  min-width: 0;
}
.workspace-rail {
  position: sticky;
  top: 118px;
  display: grid;
  gap: 10px;
}
.rail-stamp {
  height: 74px;
  border-radius: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: "IBM Plex Mono", monospace;
  font-weight: 800;
  color: #fff;
  background: linear-gradient(150deg, var(--brand-deep), #132f4a);
  box-shadow: 0 16px 36px rgba(13,34,55,.14);
  position: relative;
  overflow: hidden;
}
.rail-stamp::after {
  content: "";
  position: absolute;
  right: -18px;
  bottom: -18px;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--brand-warm);
}
.rail-item {
  display: grid;
  gap: 5px;
  padding: 14px 12px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: rgba(255,255,255,.72);
  box-shadow: 0 10px 24px rgba(18,32,51,.04);
}
.rail-item span {
  font-family: "IBM Plex Mono", monospace;
  font-size: .7rem;
  color: var(--brand-warm);
}
.rail-item strong {
  font-size: .86rem;
  line-height: 1.05;
}
.rail-item.active,
.rail-item:hover {
  border-color: rgba(15,76,129,.22);
  background: #fff;
}
.workspace-main {
  display: grid;
  gap: 14px;
}
.operator-bar {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 16px;
  align-items: end;
  padding: 24px;
  border-radius: 26px;
  background: linear-gradient(160deg, #ffffff, #f7fafc);
  border: 1px solid rgba(18,32,51,.08);
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}
.operator-bar::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(rgba(15,76,129,.045) 1px, transparent 1px), linear-gradient(90deg, rgba(15,76,129,.045) 1px, transparent 1px);
  background-size: 24px 24px;
  mask-image: linear-gradient(90deg, transparent, #000 16%, #000 84%, transparent);
}
.operator-bar > * {
  position: relative;
  z-index: 1;
}
.operator-bar h1 {
  max-width: 660px;
  font-size: clamp(2rem, 4.2vw, 4.1rem);
  margin-bottom: 0;
}
.operator-status {
  min-width: 146px;
  display: grid;
  gap: 6px;
  padding: 14px;
  border-radius: 18px;
  background: var(--brand-deep);
  color: #fff;
  border-bottom: 4px solid var(--brand-warm);
}
.operator-status span {
  font-family: "IBM Plex Mono", monospace;
  font-size: .74rem;
  color: #cbdced;
  text-transform: uppercase;
}
.operator-status strong {
  font-size: 1.35rem;
  text-transform: uppercase;
  letter-spacing: -.04em;
}
.calc-command {
  padding: 18px;
  border-radius: 22px;
  border: 1px solid var(--border);
  background: #fff;
  box-shadow: 0 12px 28px rgba(18,32,51,.05);
}
.calc-command label {
  font-family: "IBM Plex Mono", monospace;
  font-size: .76rem;
  text-transform: uppercase;
  color: var(--muted-2);
  margin-bottom: 10px;
}
.command-input-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: center;
}
.command-input-row input {
  min-height: 58px;
  border-radius: 18px;
  font-size: 16px;
  background: #f8fafc;
}
.command-input-row span {
  height: 58px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  border-radius: 18px;
  color: #fff;
  background: var(--brand);
  font-weight: 800;
  white-space: nowrap;
}
.tool-board {
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 12px;
}
.tool-tile {
  min-height: 188px;
  display: grid;
  grid-template-rows: auto 1fr auto auto;
  gap: 10px;
  padding: 18px;
  border-radius: 24px;
  background: linear-gradient(180deg, #fff, #f8fafc);
  border: 1px solid rgba(18,32,51,.09);
  box-shadow: 0 12px 28px rgba(18,32,51,.045);
  position: relative;
  overflow: hidden;
  clip-path: polygon(0 0, calc(100% - 22px) 0, 100% 22px, 100% 100%, 0 100%);
}
.tool-tile::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 5px;
  background: linear-gradient(180deg, var(--brand), var(--brand-warm));
}
.tool-tile:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 34px rgba(18,32,51,.08);
}
.tool-tile .oc-code {
  width: max-content;
}
.tool-tile strong {
  font-size: clamp(1.25rem, 2vw, 1.55rem);
  letter-spacing: -.04em;
  align-self: end;
}
.tool-tile small {
  color: var(--muted);
  font-size: .92rem;
}
.tool-tile em {
  justify-self: start;
  font-style: normal;
  font-family: "IBM Plex Mono", monospace;
  font-size: .72rem;
  color: var(--brand-deep);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 6px 10px;
  background: #fff;
}
.workspace-inspector {
  position: sticky;
  top: 118px;
  display: grid;
  gap: 12px;
}
.inspector-card {
  padding: 18px;
  border-radius: 22px;
  border: 1px solid var(--border);
  background: rgba(255,255,255,.78);
  box-shadow: 0 12px 28px rgba(18,32,51,.045);
}
.inspector-card h2 {
  font-size: 1.25rem;
  margin-bottom: 8px;
}
.inspector-card p {
  color: var(--muted);
  margin: 0;
}
.inspector-card.compact {
  display: grid;
  gap: 8px;
}
.inspector-card.compact a {
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
  color: var(--brand-deep);
  font-weight: 700;
}
.inspector-card.compact a:last-child {
  border-bottom: 0;
}
.inspector-label {
  display: block;
  margin-bottom: 10px;
  font-family: "IBM Plex Mono", monospace;
  color: var(--brand-warm);
  font-size: .72rem;
  font-weight: 800;
  text-transform: uppercase;
}
.home-page .brand-section,
.home-page .section.related,
.home-page .section:not(.tight),
.home-page .hero {
  display: none;
}
.home-page .section.tight {
  padding: 0;
}
.home-page .no-results {
  margin-top: 10px;
}
/* Guias como fichas, não artigos comuns */
.content-page .guide-article {
  border-radius: 24px;
  padding: 28px;
  background: linear-gradient(180deg, #fff, #f8fafc);
}
.content-page .guide-article h2 {
  padding-top: 8px;
}
.content-page .guide-article h2::before {
  content: "ficha // ";
  color: var(--brand-warm);
  font-family: "IBM Plex Mono", monospace;
  font-size: .76rem;
  text-transform: uppercase;
  letter-spacing: .06em;
}
.content-page .guide-article ol,
.content-page .guide-article ul {
  list-style: none;
  padding-left: 0;
}
.content-page .guide-article li {
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: #fff;
}
@media (max-width: 1180px) {
  .workspace-shell { grid-template-columns: 92px minmax(0,1fr); }
  .workspace-inspector { grid-column: 2; position: static; grid-template-columns: repeat(3, minmax(0,1fr)); }
  .rail-item strong { font-size: .76rem; }
  .tool-board { grid-template-columns: repeat(2, minmax(0,1fr)); }
}
@media (max-width: 820px) {
  .dashboard-main { padding-top: 10px; }
  .workspace-shell { grid-template-columns: 1fr; gap: 12px; }
  .workspace-rail { position: static; display: flex; overflow-x: auto; padding-bottom: 4px; }
  .rail-stamp { min-width: 70px; height: 58px; border-radius: 18px; }
  .rail-item { min-width: 112px; padding: 11px 12px; }
  .operator-bar { grid-template-columns: 1fr; padding: 18px; border-radius: 22px; }
  .operator-bar h1 { font-size: clamp(1.75rem, 9vw, 2.6rem); }
  .operator-status { display: none; }
  .command-input-row { grid-template-columns: 1fr; }
  .command-input-row span { height: 42px; }
  .tool-board { grid-template-columns: 1fr; }
  .tool-tile { min-height: 152px; border-radius: 20px; clip-path: none; }
  .workspace-inspector { grid-column: auto; grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  .operator-bar, .calc-command, .inspector-card, .tool-tile { border-radius: 18px; }
  .tool-tile { padding: 16px; }
  .workspace-rail { margin-left: -7px; margin-right: -7px; padding-left: 7px; }
}


/* Etapa 7.10: ajuste fino responsivo */
.site-header::before {
  font-size: .64rem;
  padding-top: 5px;
  padding-bottom: 5px;
}
.nav {
  min-height: 64px;
}
.nav-links {
  gap: 6px;
}
.nav-links a {
  padding: 8px 10px;
  font-size: .82rem;
  white-space: nowrap;
}
.dashboard-main {
  padding-top: 14px;
}
.workspace-shell {
  gap: 14px;
}
.operator-bar {
  padding: 20px;
}
.operator-bar h1 {
  font-size: clamp(1.8rem, 4vw, 3.55rem);
  max-width: 540px;
}
.operator-status {
  min-width: 132px;
  padding: 12px;
}
.calc-command {
  padding: 16px;
}
.command-input-row input {
  min-height: 54px;
}
.command-input-row span {
  height: 54px;
}
.tool-tile {
  min-height: 176px;
}
.tool-tile strong {
  line-height: 1.02;
}
.inspector-card {
  padding: 16px;
}

@media (max-width: 900px) {
  .site-header::before {
    font-size: .6rem;
    letter-spacing: .05em;
  }
  .nav {
    min-height: auto;
    padding: 10px 0 12px;
    gap: 10px;
  }
  .logo-mark {
    width: 38px;
    height: 38px;
    border-radius: 12px;
  }
  .logo-title {
    font-size: .98rem;
  }
  .logo-sub {
    font-size: .58rem;
    letter-spacing: .1em;
  }
  .nav-links {
    width: 100%;
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 2px;
    scrollbar-width: none;
    -ms-overflow-style: none;
    justify-content: flex-start;
  }
  .nav-links::-webkit-scrollbar,
  .workspace-rail::-webkit-scrollbar {
    display: none;
  }
  .nav-links a {
    flex: 0 0 auto;
    border: 1px solid var(--border);
    background: rgba(255,255,255,.7);
    border-radius: 999px;
  }
  .workspace-shell {
    grid-template-columns: 1fr;
    gap: 12px;
  }
  .workspace-rail,
  .workspace-inspector {
    position: static;
  }
  .workspace-rail {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding: 0 2px 4px;
    margin: 0;
  }
  .rail-stamp {
    min-width: 74px;
    width: 74px;
    height: 56px;
    border-radius: 18px;
    flex: 0 0 auto;
  }
  .rail-item {
    min-width: 122px;
    flex: 0 0 auto;
    padding: 10px 12px;
    justify-content: center;
  }
  .operator-bar {
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 16px;
    border-radius: 20px;
  }
  .operator-bar::before {
    background-size: 20px 20px;
  }
  .operator-bar h1 {
    font-size: clamp(1.6rem, 8vw, 2.55rem);
    max-width: 12ch;
    line-height: .98;
  }
  .operator-status {
    display: none;
  }
  .calc-command {
    padding: 14px;
    border-radius: 18px;
  }
  .command-input-row {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  .command-input-row input {
    min-height: 52px;
    border-radius: 16px;
  }
  .command-input-row span {
    width: 100%;
    height: 40px;
    border-radius: 999px;
    font-size: .98rem;
  }
  .tool-board {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }
  .tool-tile {
    min-height: 164px;
    padding: 16px;
    border-radius: 18px;
    clip-path: none;
  }
  .tool-tile strong {
    font-size: 1.55rem;
  }
  .tool-tile small {
    font-size: .9rem;
    line-height: 1.35;
  }
  .workspace-inspector {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .inspector-card {
    border-radius: 18px;
  }
}

@media (max-width: 560px) {
  body {
    background: linear-gradient(180deg, #dfe7f0 0, #eef2f6 96px, #eef2f6 100%), var(--bg);
  }
  .container {
    width: min(1160px, calc(100% - 16px));
  }
  .site-header::before {
    font-size: .56rem;
    padding-left: 8px;
    padding-right: 8px;
  }
  .nav {
    padding: 8px 0 10px;
  }
  .logo {
    gap: 10px;
  }
  .logo-mark {
    width: 36px;
    height: 36px;
  }
  .logo-title {
    font-size: .94rem;
  }
  .logo-sub {
    display: block;
    font-size: .54rem;
  }
  .nav-links a {
    padding: 7px 11px;
    font-size: .8rem;
  }
  .dashboard-main {
    padding-top: 8px;
    padding-bottom: 18px;
  }
  .workspace-rail {
    margin-left: -2px;
    margin-right: -2px;
  }
  .rail-stamp {
    min-width: 64px;
    width: 64px;
    height: 48px;
    border-radius: 16px;
  }
  .rail-item {
    min-width: 112px;
    padding: 8px 12px;
    border-radius: 16px;
    gap: 2px;
  }
  .rail-item strong {
    font-size: .82rem;
  }
  .rail-item span {
    font-size: .66rem;
  }
  .workspace-main {
    gap: 10px;
  }
  .operator-bar {
    padding: 14px;
    border-radius: 18px;
  }
  .operator-bar h1 {
    max-width: 10ch;
    font-size: clamp(1.45rem, 11vw, 2.1rem);
  }
  .kicker {
    margin-bottom: 10px;
    padding: 6px 10px 6px 10px;
    font-size: .68rem;
  }
  .calc-command {
    padding: 12px;
    border-radius: 16px;
  }
  .calc-command label {
    margin-bottom: 8px;
  }
  .command-input-row input {
    min-height: 50px;
    padding: 0 14px;
  }
  .command-input-row span {
    height: 38px;
    font-size: .95rem;
  }
  .tool-board {
    grid-template-columns: 1fr;
  }
  .tool-tile {
    min-height: 136px;
    padding: 14px;
    gap: 8px;
  }
  .tool-tile strong {
    font-size: 1.05rem;
    align-self: start;
  }
  .tool-tile small {
    font-size: .84rem;
  }
  .tool-tile em {
    font-size: .68rem;
    padding: 5px 8px;
  }
  .tool-tile .oc-code {
    min-width: 64px;
    min-height: 28px;
    font-size: .68rem;
  }
  .workspace-inspector {
    gap: 8px;
  }
  .inspector-card {
    padding: 14px;
    border-radius: 16px;
  }
  .inspector-card h2 {
    font-size: 1.05rem;
  }
  .inspector-card.compact a {
    padding: 8px 0;
    font-size: .92rem;
  }
  .site-footer {
    margin-top: 18px;
    padding: 20px 0 28px;
  }
}


/* Etapa 7.11: home mais objetiva */
.home-page .operator-bar {
  padding: 22px;
}
.home-page .operator-bar h1 {
  max-width: 8ch;
  font-size: clamp(1.9rem, 4vw, 3.2rem);
}
.home-page .tool-board {
  margin-top: 0;
}
.home-page .workspace-main {
  gap: 12px;
}
.home-page .no-results,
.home-page .calc-command {
  display: none !important;
}
@media (max-width: 900px) {
  .home-page .operator-bar {
    padding: 16px;
  }
  .home-page .operator-bar h1 {
    max-width: 9ch;
    font-size: clamp(1.65rem, 8vw, 2.35rem);
  }
}
@media (max-width: 560px) {
  .home-page .workspace-main {
    gap: 10px;
  }
  .home-page .operator-bar {
    padding: 14px;
  }
  .home-page .operator-bar h1 {
    max-width: 8ch;
    font-size: clamp(1.45rem, 10vw, 1.95rem);
  }
}


/* Etapa 7.13: topo mais enxuto nas calculadoras */
.calc-page-compact {
  padding: 18px 0 4px;
}
.calc-page-compact .breadcrumb {
  margin-bottom: 8px;
  font-size: .8rem;
}
.calc-page-compact h1 {
  font-size: clamp(1.8rem, 3.5vw, 2.45rem);
  max-width: none;
  margin-bottom: 0;
}
.tool-page .section:first-of-type {
  padding-top: 12px;
}
.tool-page .tool-app-shell {
  margin-top: 0;
}
.tool-page .calculator-shell {
  gap: 12px;
}
.tool-page .panel > h2:first-child {
  font-size: 1.3rem;
  margin-bottom: 16px;
}
.tool-page .panel {
  padding-top: 18px;
}
.tool-page .visual {
  margin-bottom: 14px;
}
.tool-page .results {
  margin-top: 12px;
}
.tool-page .identity-note {
  margin-top: 10px;
}
@media (max-width: 900px) {
  .calc-page-compact {
    padding: 14px 0 2px;
  }
  .calc-page-compact h1 {
    font-size: clamp(1.55rem, 7vw, 2.05rem);
  }
  .tool-page .section:first-of-type {
    padding-top: 10px;
  }
}
@media (max-width: 560px) {
  .calc-page-compact {
    padding: 10px 0 0;
  }
  .calc-page-compact .breadcrumb {
    margin-bottom: 6px;
    font-size: .74rem;
  }
  .calc-page-compact h1 {
    font-size: clamp(1.4rem, 8vw, 1.85rem);
    line-height: 1.02;
  }
  .tool-page .section:first-of-type {
    padding-top: 8px;
  }
  .tool-page .panel {
    padding-top: 16px;
  }
}


/* Etapa 7.15: URLs em pastas e ajuste das páginas de guia */
.nav-links a[href="empresas.html"],
.nav-links a[href="/empresas/"],
.footer-grid a[href="/empresas/"] { display: none !important; }
.content-page .page-title {
  padding: 30px 0 20px;
}
.content-page .page-title .content-block {
  max-width: 780px;
  margin-left: auto;
  margin-right: auto;
}
.content-page .breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 14px;
  font-size: .8rem;
  line-height: 1.2;
  white-space: normal;
  overflow: visible;
  color: var(--muted-2);
  font-family: "IBM Plex Mono", monospace;
}
.content-page .breadcrumb a,
.content-page .breadcrumb span {
  background: transparent !important;
  color: var(--muted-2);
  padding: 0;
  margin: 0;
  border: 0;
  box-shadow: none;
}
.content-page .breadcrumb a {
  color: var(--brand);
  font-weight: 700;
}
.content-page .page-title h1 {
  max-width: 620px;
  font-size: clamp(2.05rem, 4vw, 3.45rem);
}
.content-page .page-title .lead {
  max-width: 740px;
  font-size: 1rem;
}
.content-page .page-title .actions {
  margin-top: 12px;
}
.content-page .guide-layout {
  max-width: 980px;
  margin-left: auto;
  margin-right: auto;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 22px;
}
.content-page .guide-article {
  box-shadow: 0 18px 42px rgba(18, 32, 51, .07);
  border-radius: 22px;
  padding: 26px;
}
.content-page .guide-article li {
  line-height: 1.55;
}
.content-page .formula-box {
  line-height: 1.6;
  white-space: normal;
}
.content-page .guide-aside {
  align-self: start;
  top: 112px;
}
.content-page .related .content-block {
  max-width: 980px;
  margin-left: auto;
  margin-right: auto;
}
.content-page .related .grid-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
@media (max-width: 900px) {
  .content-page .page-title {
    padding: 20px 0 14px;
  }
  .content-page .guide-layout {
    grid-template-columns: 1fr;
  }
  .content-page .guide-aside {
    position: static;
  }
  .content-page .related .grid-3 {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 560px) {
  .content-page .page-title .content-block,
  .content-page .guide-layout,
  .content-page .related .content-block {
    max-width: 100%;
  }
  .content-page .page-title h1 {
    font-size: clamp(1.7rem, 10vw, 2.25rem);
  }
  .content-page .page-title .actions .button {
    width: 100%;
  }
  .content-page .guide-article {
    padding: 16px;
    border-radius: 18px;
  }
}


/* Etapa 7.17: padronização das páginas do grupo Guias */
.content-page main {
  --guide-width: 980px;
}
.content-page .page-title {
  padding: 28px 0 18px;
}
.content-page .page-title .content-block,
.content-page .section.tight > .container.content-block,
.content-page .related .content-block,
.content-page .guide-layout {
  width: min(var(--guide-width), calc(100% - 28px));
  max-width: var(--guide-width);
  margin-left: auto;
  margin-right: auto;
}
.content-page .page-title h1 {
  max-width: 720px;
  margin-bottom: 12px;
}
.content-page .page-title .lead {
  max-width: 760px;
  margin-bottom: 0;
}
.content-page .page-title .actions {
  margin-top: 12px;
}
.content-page .breadcrumb {
  display: flex;
  align-items: center;
  gap: 7px;
  min-height: 20px;
  margin-bottom: 14px;
  line-height: 1.2;
}
.content-page .breadcrumb a,
.content-page .breadcrumb span {
  display: inline-flex;
  align-items: center;
}
.content-page .guide-layout {
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 22px;
}
.content-page .guide-article {
  min-width: 0;
  padding: 26px;
}
.content-page .guide-aside {
  min-width: 0;
  position: sticky;
  top: 110px;
  align-self: start;
}
.content-page .guide-aside h2 {
  font-size: 1.18rem;
}
.content-page .guide-aside p {
  font-size: .94rem;
}
.content-page .section.tight .grid-3,
.content-page .related .grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  align-items: stretch;
}
.content-page .tool-card {
  height: 100%;
  min-height: 190px;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  padding: 22px;
}
.content-page .related .tool-card {
  min-height: 142px;
}
.content-page .tool-card h3 {
  max-width: 18ch;
  padding-right: 0;
  margin-bottom: 10px;
}
.content-page .tool-card p {
  margin-bottom: 0;
}
.content-page .related {
  margin-top: 10px;
}
.content-page .related .content-block {
  padding: 24px;
}
.content-page .guide-article .ordered-clean,
.content-page .guide-article .task-list {
  margin-top: 14px;
}
.content-page .guide-article li {
  margin-bottom: 10px;
}
.content-page .formula-box {
  margin: 18px 0 22px;
}
@media (max-width: 980px) {
  .content-page .guide-layout {
    grid-template-columns: 1fr;
  }
  .content-page .guide-aside {
    position: static;
  }
  .content-page .section.tight .grid-3,
  .content-page .related .grid-3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 640px) {
  .content-page .page-title .content-block,
  .content-page .section.tight > .container.content-block,
  .content-page .related .content-block,
  .content-page .guide-layout {
    width: min(100% - 16px, var(--guide-width));
  }
  .content-page .section.tight .grid-3,
  .content-page .related .grid-3 {
    grid-template-columns: 1fr;
  }
  .content-page .tool-card,
  .content-page .related .tool-card {
    min-height: 0;
  }
  .content-page .guide-article,
  .content-page .related .content-block {
    padding: 18px;
  }
}
