/* ============ Tools page ============ */

.tool-nav {
  display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-bottom: 26px;
}
.tool-nav a {
  border: 1px solid var(--border); background: #fff; color: var(--ink);
  padding: 9px 16px; border-radius: 30px; font-weight: 700; font-size: 0.88rem;
  transition: all 0.2s ease;
}
.tool-nav a:hover { border-color: var(--primary); color: var(--primary); transform: translateY(-1px); }

.t-note { color: var(--ink-soft); font-size: 0.85rem; margin-top: 14px; line-height: 1.55; }
.t-note a { font-weight: 700; }
.t-note-top {
  max-width: 760px; margin: 0 auto 30px; text-align: center;
  background: var(--primary-soft); border: 1px solid var(--border);
  color: var(--ink-soft); padding: 12px 18px; border-radius: 12px; font-size: 0.9rem;
}

.tool-card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  margin: 0 0 26px; padding: 30px; scroll-margin-top: 96px;
  box-shadow: var(--shadow);
}
.tool-card::before {
  content: ""; display: block; height: 3px; margin: -30px -30px 22px;
  background: linear-gradient(90deg, var(--primary), var(--primary-dark));
  border-radius: 14px 14px 0 0;
}
.tool-head { display: flex; gap: 18px; align-items: flex-start; margin-bottom: 24px; }
.tool-head .svc-icon { flex: 0 0 auto; }
.tool-head h3 { font-size: 1.25rem; color: var(--ink); letter-spacing: -0.2px; }
.tool-head p { color: var(--ink-soft); font-size: 0.92rem; margin-top: 6px; max-width: 640px; }

.t-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 34px; align-items: start; }
.t-form { display: flex; flex-direction: column; gap: 16px; }
.t-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.t-row.t-actions { grid-template-columns: 1fr; }
.t-field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.t-field label { font-size: 0.82rem; font-weight: 700; color: var(--ink); }
.t-field input, .t-field select {
  width: 100%; padding: 11px 13px; border: 1px solid var(--border); border-radius: 9px;
  font: inherit; font-size: 0.95rem; color: var(--ink); background: #fbfdfd; min-width: 0;
}
.t-field input:focus, .t-field select:focus {
  outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.15);
}

.t-result {
  background: var(--bg-soft); border: 1px solid var(--border); border-radius: 12px;
  padding: 24px; text-align: center;
}
.t-result-big {
  font-size: clamp(2rem, 4vw, 3rem); font-weight: 800; color: var(--primary);
  line-height: 1.05; word-break: break-word;
}
.t-result-label { font-size: 1.05rem; font-weight: 700; color: var(--ink); margin-top: 6px; }
.t-result .t-note { margin-top: 16px; padding-top: 14px; border-top: 1px dashed var(--border); }

.t-out-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 12px;
}
.t-out-grid.t-out-2 { grid-template-columns: 1fr 1fr; }
.t-out-grid.t-out-4 { grid-template-columns: 1fr 1fr; }
.t-out-grid .t-out-full { grid-column: 1 / -1; }
.t-out {
  background: #fff; border: 1px solid var(--border); border-radius: 10px;
  padding: 14px 10px;
}
.t-out .k { font-size: 0.72rem; font-weight: 800; text-transform: uppercase; letter-spacing: 1px; color: var(--ink-soft); }
.t-out .v { font-size: 1.15rem; font-weight: 800; color: var(--ink); margin-top: 4px; word-break: break-word; }
.t-out .u { font-size: 0.78rem; color: var(--primary); font-weight: 700; }

.t-table { margin-top: 16px; text-align: left; }
.t-table table { width: 100%; border-collapse: collapse; font-size: 0.8rem; }
.t-table th, .t-table td { border: 1px solid var(--border); padding: 6px 8px; text-align: left; color: var(--ink); }
.t-table th { background: var(--primary-soft); color: var(--primary-dark); font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.6px; }
.t-table td { color: var(--ink-soft); }

.faq-list { display: flex; flex-direction: column; gap: 16px; max-width: 820px; }
.faq-item { background: #fff; border: 1px solid var(--border); border-radius: 12px; padding: 22px 24px; }
.faq-item h3 { font-size: 1.02rem; color: var(--ink); margin-bottom: 6px; }
.faq-item p { color: var(--ink-soft); font-size: 0.94rem; }

@media (max-width: 992px) {
  .t-grid { grid-template-columns: 1fr !important; gap: 24px; }
  .t-row { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 720px) {
  .tool-card { padding: 22px; }
  .tool-card::before { margin: -22px -22px 18px; }
  .tool-head { flex-direction: column; gap: 12px; }
  .t-row { grid-template-columns: 1fr !important; }
  .t-out-grid, .t-out-grid.t-out-2, .t-out-grid.t-out-4 { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 480px) {
  .t-out-grid, .t-out-grid.t-out-2, .t-out-grid.t-out-4 { grid-template-columns: 1fr; }
}
