/* ========================================
   VanTaiHangHoa.com – Tool-Specific Styles
   ======================================== */

/* === TOOL PAGE LAYOUT === */
.tool-page {
  padding: 32px 0 64px;
}
.tool-page__content {
  max-width: 800px;
  margin: 0 auto;
}

/* === CALCULATOR FORM === */
.calculator-form {
  background: var(--bg-card);
  border: 1px solid var(--color-black-border);
  border-radius: var(--radius-xl);
  padding: 24px;
  margin-bottom: 24px;
}
.calculator-form__title {
  font-size: var(--text-xl);
  font-weight: 700;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.calculator-form__title svg {
  width: 24px;
  height: 24px;
  color: var(--color-gold);
}

/* === RESULT DISPLAY === */
.result-container {
  display: none;
  margin-bottom: 24px;
}
.result-container.show { display: block; }

.result-card__actions {
  display: flex;
  gap: 12px;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--color-black-border);
}
@media (max-width: 480px) {
  .result-card__actions { flex-direction: column; }
}

/* === CBM CALCULATOR === */
.cbm-dimensions {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
@media (max-width: 480px) {
  .cbm-dimensions { grid-template-columns: 1fr; }
}
.cbm-result-visual {
  background: var(--bg-card);
  border: 1px solid var(--color-black-border);
  border-radius: var(--radius-lg);
  padding: 20px;
  text-align: center;
  margin-top: 16px;
}
.cbm-result-visual__value {
  font-size: var(--text-4xl);
  font-weight: 800;
  color: var(--color-gold);
}
.cbm-result-visual__unit {
  font-size: var(--text-sm);
  color: var(--text-muted);
}

/* === WEIGHT CONVERTER === */
.converter-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-top: 20px;
}
@media (min-width: 640px) {
  .converter-grid { grid-template-columns: repeat(3, 1fr); }
}
.converter-item {
  background: var(--bg-card);
  border: 1px solid var(--color-black-border);
  border-radius: var(--radius-md);
  padding: 16px;
  text-align: center;
}
.converter-item__value {
  font-size: var(--text-xl);
  font-weight: 700;
  color: var(--color-gold);
}
.converter-item__unit {
  font-size: var(--text-sm);
  color: var(--text-muted);
  margin-top: 4px;
}

/* === ROUTE SUGGESTER === */
.route-suggestion {
  background: var(--bg-card);
  border: 1px solid var(--color-black-border);
  border-radius: var(--radius-lg);
  padding: 20px;
  margin-bottom: 16px;
}
.route-suggestion__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}
.route-suggestion__badge {
  padding: 4px 12px;
  font-size: var(--text-xs);
  font-weight: 700;
  border-radius: var(--radius-full);
}
.route-suggestion__badge--optimal {
  background: rgba(34,197,94,0.15);
  color: var(--color-success);
}
.route-suggestion__badge--alternative {
  background: rgba(59,130,246,0.15);
  color: var(--color-info);
}
.route-suggestion__details {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 12px;
}

/* === TRANSIT TIME === */
.transit-timeline {
  position: relative;
  padding-left: 32px;
  margin-top: 20px;
}
.transit-timeline::before {
  content: '';
  position: absolute;
  left: 12px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--color-black-border);
}
.timeline-item {
  position: relative;
  padding-bottom: 24px;
}
.timeline-item::before {
  content: '';
  position: absolute;
  left: -26px;
  top: 6px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--color-gold);
  border: 2px solid var(--bg-primary);
}
.timeline-item__time {
  font-size: var(--text-sm);
  color: var(--color-gold);
  font-weight: 600;
  margin-bottom: 4px;
}
.timeline-item__desc {
  font-size: var(--text-sm);
  color: var(--text-muted);
}

/* === TOOL COMPARISON TABLE === */
.comparison-table {
  width: 100%;
  border-collapse: collapse;
  margin: 24px 0;
  font-size: var(--text-sm);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.comparison-table th {
  background: var(--color-gold);
  color: var(--color-black);
  padding: 12px;
  font-weight: 700;
  text-align: left;
}
.comparison-table td {
  padding: 12px;
  border-bottom: 1px solid var(--color-black-border);
  background: var(--bg-card);
}
.comparison-table tr:last-child td { border-bottom: none; }
.comparison-table tr:hover td { background: rgba(245,166,35,0.03); }

/* === TOOL INFO SECTION === */
.tool-info {
  margin-top: 48px;
}
.tool-info h2 {
  font-size: var(--text-xl);
  font-weight: 700;
  margin-bottom: 12px;
  padding-left: 16px;
  border-left: 4px solid var(--color-gold);
}
.tool-info p {
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 16px;
}
.tool-info ul {
  padding-left: 24px;
  margin-bottom: 16px;
}
.tool-info li {
  list-style: disc;
  color: var(--text-muted);
  margin-bottom: 8px;
  line-height: 1.6;
}

/* === TOOL SUMMARY BOX === */
.tool-summary {
  background: rgba(245,166,35,0.05);
  border: 1px solid var(--color-gold-muted);
  border-radius: var(--radius-lg);
  padding: 20px;
  margin: 24px 0;
}
.tool-summary__title {
  font-size: var(--text-base);
  font-weight: 700;
  color: var(--color-gold);
  margin-bottom: 8px;
}
.tool-summary__text {
  font-size: var(--text-sm);
  color: var(--text-secondary);
  line-height: 1.6;
}
