.tool-hero {
  background: linear-gradient(135deg, #7c3aed 0%, #db2777 100%);
  padding: 3rem 1.5rem 2.5rem;
  text-align: center;
  color: #fff;
}
.tool-hero h1 {
  font-size: 2rem;
  font-weight: 800;
  color: #fff !important;
  line-height: 1.25;
  margin: 0 auto 0.5rem;
  max-width: 720px;
}
.tool-hero p {
  color: rgba(255, 255, 255, 0.88);
  font-size: 1rem;
  max-width: 580px;
  margin: 0 auto;
}
.tool-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 50px;
  padding: 0.3rem 0.9rem;
  font-size: 0.8rem;
  margin-bottom: 1rem;
}
.tool-page {
  max-width: 1080px;
  margin: 0 auto;
  padding: 2.25rem 1.25rem;
}
.ar-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.5rem;
  margin-bottom: 1.75rem;
}
@media (max-width: 860px) {
  .ar-grid { grid-template-columns: minmax(0, 1fr); }
}
.calc-card {
  background: var(--card-bg, #fff);
  border: 1px solid var(--border, #e2e8f0);
  border-radius: 18px;
  padding: 1.65rem;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.05);
}
.ar-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}
.ar-head h2 {
  font-size: 1.08rem;
  font-weight: 700;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 0.45rem;
}
.ar-head h2 i { color: #7c3aed; }
.ar-btn-ghost {
  background: var(--bg, #f8fafc);
  color: var(--text, #0f172a);
  border: 1px solid var(--border, #cbd5e1);
  border-radius: 9px;
  padding: 0.38rem 0.75rem;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
}
.ar-btn-ghost:hover { border-color: #7c3aed; color: #7c3aed; }

.ar-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 1.2rem;
}
.ar-chip {
  background: var(--bg, #f8fafc);
  color: var(--text, #0f172a);
  border: 1px solid var(--border, #cbd5e1);
  border-radius: 999px;
  padding: 0.3rem 0.72rem;
  font-size: 0.76rem;
  font-weight: 600;
  cursor: pointer;
}
.ar-chip:hover, .ar-chip.is-active {
  background: #7c3aed;
  color: #fff;
  border-color: #7c3aed;
}

.ar-section-title {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted, #64748b);
  margin-bottom: 0.5rem;
}
.ar-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
  margin-bottom: 1.15rem;
}
.form-field label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
}
.form-field input {
  width: 100%;
  min-height: 44px;
  padding: 0.55rem 0.8rem;
  font-size: 1rem;
  font-weight: 700;
  border: 1.5px solid var(--border, #cbd5e1);
  border-radius: 10px;
  background: var(--bg, #fff);
  color: var(--text, #0f172a);
}

.ar-css-box {
  background: var(--bg, #f8fafc);
  border: 1px solid var(--border, #e2e8f0);
  border-radius: 12px;
  padding: 0.75rem 0.9rem;
}
.ar-css-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.35rem;
  font-size: 0.78rem;
  font-weight: 700;
}
.ar-css-box code {
  font-size: 0.8rem;
  background: transparent;
  color: #7c3aed;
  padding: 0;
}

.ar-kpis {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
  margin-bottom: 1.1rem;
}
@media (max-width: 480px) {
  .ar-kpis { grid-template-columns: 1fr; }
}
.ar-kpi {
  padding: 0.95rem 1rem;
  border-radius: 12px;
  border: 1px solid var(--border, #e2e8f0);
  background: var(--bg, #f8fafc);
}
.ar-kpi.highlight {
  background: rgba(124, 58, 237, 0.08);
  border-color: #c4b5fd;
}
.ar-kpi-label { font-size: 0.74rem; font-weight: 700; text-transform: uppercase; color: var(--text-muted, #64748b); }
.ar-kpi-val { font-size: 1.45rem; font-weight: 800; color: var(--text, #0f172a); margin-top: 0.2rem; }
.ar-kpi-sub { font-size: 0.78rem; color: var(--text-muted, #64748b); margin-top: 0.2rem; }

.ar-stage {
  height: 185px;
  border-radius: 12px;
  border: 1px dashed var(--border, #cbd5e1);
  background: var(--bg, #f8fafc);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  margin-bottom: 1rem;
}
.ar-frame {
  background: linear-gradient(135deg, rgba(124, 58, 237, 0.2), rgba(219, 39, 119, 0.2));
  border: 2px solid #7c3aed;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.9rem;
  color: var(--text, #0f172a);
  transition: width 0.16s ease, height 0.16s ease;
}

.ar-res-title { font-size: 0.82rem; font-weight: 700; margin-bottom: 0.45rem; }
.ar-mini-table { width: 100%; border-collapse: collapse; font-size: 0.82rem; }
.ar-mini-table td {
  padding: 0.42rem 0.6rem;
  border-bottom: 1px solid var(--border, #e2e8f0);
}
.ar-mini-table td:last-child { text-align: right; font-weight: 700; font-family: monospace; }
.ar-mini-table tr { cursor: pointer; }
.ar-mini-table tr:hover { background: rgba(124, 58, 237, 0.06); }
