/* Estilos compartilhados das páginas de ferramentas */
.tool-page-main {
  max-width: 980px;
  width: 100%;
}
.tool-panel {
  background: #fff;
  border: 2px solid #d4c5b9;
  border-radius: 2px;
  padding: 36px;
  margin-bottom: 40px;
}
.tool-panel .section-title {
  font-size: 2.1em;
  margin-bottom: 18px;
}
.tool-panel .intro-text {
  margin-bottom: 26px;
}
.tool-panel .intro-text:last-child {
  margin-bottom: 0;
}
.tool-field {
  margin-bottom: 20px;
}
.tool-label {
  display: block;
  font-weight: 600;
  color: #4a5568;
  margin-bottom: 10px;
}
.tool-row {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}
.tool-row input[type="color"] {
  width: 56px;
  height: 44px;
  padding: 0;
  border: 1px solid #d4c5b9;
  border-radius: 2px;
  background: #fff;
  cursor: pointer;
}
.tool-row input[type="text"],
.tool-row input[type="number"],
.tool-row select {
  flex: 1;
  min-width: 120px;
  height: 44px;
  border: 1px solid #d4c5b9;
  border-radius: 2px;
  padding: 0 12px;
  font-size: 1em;
  font-weight: 600;
  color: #2d3142;
  background: #fff;
}
.tool-field input[type="text"],
.tool-field input[type="number"],
.tool-field select {
  min-height: 44px;
  border: 1px solid #d4c5b9;
  border-radius: 2px;
  padding: 10px 12px;
  font-size: 1em;
  line-height: 1.25;
  font-weight: 600;
  color: #2d3142;
  background: #fff;
}
.tool-row input[type="text"] {
  text-transform: uppercase;
}
.tool-row input:focus,
.tool-row select:focus {
  outline: 2px solid rgb(107 122 161 / 0.25);
  border-color: #6b7aa1;
}
.tool-btn {
  background: #6b7aa1;
  color: #fff;
  border: 2px solid #6b7aa1;
  padding: 10px 20px;
  font-weight: 600;
  font-size: 0.95em;
  border-radius: 2px;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease;
}
.tool-btn:hover {
  background: #4a5568;
  border-color: #4a5568;
}
.tool-btn-secondary {
  background: #fff;
  color: #4a5568;
  border-color: #d4c5b9;
}
.tool-btn-secondary:hover {
  background: #f8f7f4;
  border-color: #6b7aa1;
  color: #2d3142;
}
.result-card {
  background: #f8f7f4;
  border: 1px solid #d4c5b9;
  border-radius: 2px;
  padding: 20px;
  margin-top: 20px;
}
.result-card pre,
.code-copy-block {
  background: #2d3142;
  color: #e8dfd6;
  padding: 16px 18px;
  border-radius: 2px;
  font-size: 0.9em;
  overflow-x: auto;
  line-height: 1.5;
  margin: 12px 0 0;
  word-break: break-all;
}
.hub-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
  margin-top: 28px;
}
.hub-card {
  background: #fff;
  border: 2px solid #d4c5b9;
  border-left: 5px solid #8e9775;
  border-radius: 2px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: box-shadow 0.25s ease, border-left-color 0.25s ease;
}
.hub-card:hover {
  border-left-color: #6b7aa1;
  box-shadow: 0 5px 18px rgb(107 122 161 / 0.12);
}
.hub-card h2 {
  font-size: 1.35em;
  color: #4a5568;
  margin: 0;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.hub-card p {
  color: #3a3e4f;
  font-size: 0.98em;
  line-height: 1.65;
  margin: 0;
  flex: 1;
}
.hub-card a.hub-link {
  align-self: flex-start;
  background: #6b7aa1;
  color: #fff !important;
  text-decoration: none !important;
  padding: 11px 20px;
  font-weight: 600;
  font-size: 0.92em;
  border-radius: 2px;
  border: 2px solid #6b7aa1;
  transition: background 0.2s ease, border-color 0.2s ease;
}
.hub-card a.hub-link:hover {
  background: #4a5568;
  border-color: #4a5568;
  color: #fff !important;
}
nav a.active {
  color: #6b7aa1;
  font-weight: 600;
}
.footer-links {
  margin: 15px 0;
}
.swatch-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 16px;
}
.swatch-btn {
  min-width: 100px;
  padding: 14px 16px;
  border: 2px solid #d4c5b9;
  border-radius: 2px;
  cursor: pointer;
  text-align: center;
  font-weight: 600;
  font-size: 0.88em;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.swatch-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgb(45 49 66 / 0.12);
}
.swatch-btn small {
  display: block;
  margin-top: 6px;
  font-weight: 500;
  opacity: 0.95;
}
.hm-toast {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%) translateY(12px);
  background: #4a5568;
  color: #f5f1ea;
  padding: 12px 22px;
  border-radius: 2px;
  font-size: 0.95em;
  font-weight: 600;
  z-index: 10001;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
  box-shadow: 0 4px 16px rgb(45 49 66 / 0.2);
}
.hm-toast.visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

@media (max-width: 768px) {
  .tool-panel {
    padding: 24px;
  }
  .tool-row {
    flex-direction: column;
    align-items: stretch;
  }
  .tool-row input[type="color"] {
    width: 100%;
    height: 48px;
  }
  .tool-row input[type="text"],
  .tool-row input[type="number"],
  .tool-row select,
  .tool-field input[type="text"],
  .tool-field input[type="number"],
  .tool-field select {
    min-height: 52px;
    height: 52px;
    padding: 12px 14px;
    font-size: 1rem;
    line-height: 1.3;
  }
}

/* Destaque legível em fundos claros (o strong global usa amarelo pouco visível no branco) */
.tool-page-main .tool-panel strong,
.tool-page-main .result-card strong,
.tool-page-main .intro-text strong {
  color: #2d3142;
  font-weight: 600;
}
.hero-header strong {
  color: #ffffff;
  font-weight: 600;
}
span.tool-strong-light {
  color: #2d3142;
  font-weight: 600;
}

.compare-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  align-items: start;
}
@media (max-width: 900px) {
  .compare-grid {
    grid-template-columns: 1fr;
  }
}
.metric-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  margin-top: 12px;
  font-size: 0.95em;
  color: #4a5568;
}
.metric-row span {
  font-weight: 600;
  color: #2d3142;
}
.export-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}
.export-tabs button {
  background: #fff;
  border: 1px solid #d4c5b9;
  padding: 8px 14px;
  border-radius: 2px;
  cursor: pointer;
  font-weight: 600;
  color: #4a5568;
}
.export-tabs button.is-active {
  background: #6b7aa1;
  border-color: #6b7aa1;
  color: #fff;
}
.sim-preview-wrap {
  border: 1px solid #d4c5b9;
  border-radius: 2px;
  overflow: hidden;
  margin-top: 16px;
}
.sim-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  gap: 12px;
  flex-wrap: wrap;
}
.sim-card {
  padding: 16px;
  margin: 12px;
  border-radius: 2px;
  border: 1px solid #d4c5b9;
}
.sim-form-row {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 10px;
}
.sim-form-row input {
  padding: 10px 12px;
  border-radius: 2px;
  border: 1px solid;
  font-size: 1rem;
}
.history-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.history-list li {
  border: 1px solid #d4c5b9;
  border-radius: 2px;
  padding: 14px 16px;
  margin-bottom: 10px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: space-between;
  align-items: flex-start;
}
.history-list small {
  color: #6b7280;
  display: block;
  margin-top: 6px;
}
.checklist-alert {
  border-left: 4px solid #c47c6e;
  padding: 12px 14px;
  margin-bottom: 10px;
  background: #fff9f7;
  color: #3a3e4f;
}
.checklist-ok {
  border-left-color: #8e9775;
  background: #f6faf4;
}

/* Feedback ao salvar no histórico local (sem alert) */
.tool-btn .save-feedback-check {
  display: none;
  margin-left: 8px;
  color: #5a7d4a;
  font-weight: 700;
  font-size: 1.05em;
  line-height: 1;
  vertical-align: middle;
}
.tool-btn.is-saved {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0 4px;
  border-color: #8e9775;
}
.tool-btn.is-saved .save-feedback-check {
  display: inline;
}
