/* ==========================================================================
   KYNORIA — Suez Canal Toll Estimator
   Loaded only by suez-canal-toll-calculator.html
   ========================================================================== */

.form-hint {
  font-size: var(--text-xs);
  color: var(--text-light);
  margin-top: var(--space-2);
  line-height: 1.5;
}

.toll-radio {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  margin-right: var(--space-6);
  font-size: var(--text-sm);
  color: var(--text-dark);
  cursor: pointer;
}

.toll-radio input {
  accent-color: var(--secondary);
}


/* ── Form layout ──────────────────────────────────────────────────────────── */

#toll-form .form-group {
  margin-bottom: var(--space-4);
}

#toll-form [hidden] {
  display: none !important;
}

.toll-step {
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--secondary);
  margin: var(--space-6) 0 var(--space-3);
  padding-bottom: var(--space-2);
  border-bottom: 1px solid var(--border);
}

.toll-step:first-child {
  margin-top: 0;
}

.toll-req {
  color: var(--danger);
}

.toll-fieldset {
  border: 0;
  padding: 0;
  min-width: 0;
}

.toll-fieldset legend {
  margin-bottom: var(--space-2);
  line-height: 1.5;
}

.toll-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 var(--space-4);
}

.toll-units {
  display: grid;
  gap: var(--space-2);
  margin-top: var(--space-3);
}

.toll-units:empty {
  display: none;
}

.toll-units__label {
  font-size: var(--text-xs);
  margin-bottom: 0;
}

.toll-error {
  margin-top: var(--space-4);
  padding: var(--space-3) var(--space-4);
  border-left: 4px solid var(--danger);
  border-radius: var(--radius-md);
  background: rgba(220, 38, 38, 0.06);
  color: var(--text-dark);
  font-size: var(--text-sm);
}

.toll-bands {
  margin-top: var(--space-5);
  font-size: var(--text-sm);
}

.toll-bands summary {
  cursor: pointer;
  font-weight: var(--weight-semibold);
  color: var(--navy);
  margin-bottom: var(--space-3);
}

@media (max-width: 520px) {
  .toll-grid {
    grid-template-columns: 1fr;
  }
}


/* ── Warning banner ───────────────────────────────────────────────────────── */

.toll-warning {
  padding: var(--space-5) var(--space-6);
  margin-bottom: var(--space-8);
  border-left: 4px solid var(--danger);
  border-radius: var(--radius-md);
  background: rgba(220, 38, 38, 0.06);
  color: var(--text-dark);
  font-size: var(--text-sm);
  line-height: 1.6;
}

.toll-warning code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.92em;
  padding: 0.1em 0.35em;
  border-radius: var(--radius-sm, 4px);
  background: rgba(11, 35, 65, 0.08);
}


/* ── Tariff status / update check ────────────────────────────────────────── */

.tariff-status {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  padding: var(--space-4) var(--space-6);
  margin-bottom: var(--space-6);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--light-bg);
}

.tariff-status__text {
  font-size: var(--text-sm);
  color: var(--text-body);
  line-height: 1.5;
}

.tariff-status__text strong {
  color: var(--text-dark);
}

.tariff-check-result {
  margin-top: var(--space-4);
  padding: var(--space-4) var(--space-5);
  border-radius: var(--radius-md);
  background: var(--white);
  border: 1px solid var(--border);
  font-size: var(--text-sm);
  color: var(--text-body);
  line-height: 1.6;
}

.tariff-check-result ul {
  margin: var(--space-2) 0 0;
  padding-left: var(--space-5);
}

.tariff-check-result a {
  color: var(--secondary);
  font-weight: 600;
}

.tariff-check-result.is-error {
  border-left: 4px solid var(--danger);
}


/* ── Result total ─────────────────────────────────────────────────────────── */

.toll-total {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: var(--space-3);
  padding: var(--space-5) 0 var(--space-6);
  border-bottom: 1px solid var(--border);
  margin-bottom: var(--space-5);
}

.toll-total__sdr {
  font-family: var(--font-heading);
  font-size: var(--text-3xl);
  font-weight: var(--weight-bold);
  color: var(--navy);
  line-height: 1.1;
}

.toll-total__usd {
  font-size: var(--text-base);
  color: var(--text-muted);
}


/* ── Breakdown table ──────────────────────────────────────────────────────── */

.toll-table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--text-sm);
}

.toll-table caption {
  caption-side: top;
  text-align: left;
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-light);
  padding-bottom: var(--space-3);
}

.toll-table th,
.toll-table td {
  padding: var(--space-2) var(--space-3);
  border-bottom: 1px solid var(--border);
  text-align: left;
}

.toll-table th {
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  border-bottom-width: 2px;
}

.toll-table .num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.toll-table__subtotal td {
  font-weight: var(--weight-semibold);
  background: rgba(11, 35, 65, 0.04);
}

.toll-source {
  font-size: var(--text-xs);
  color: var(--text-light);
  margin-top: var(--space-4);
  line-height: 1.5;
}


/* ── Disclaimer ───────────────────────────────────────────────────────────── */

.toll-disclaimer {
  margin-top: var(--space-12);
  padding: var(--space-8);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg, 12px);
  background: var(--bg-alt, #F4F6F9);
}

.toll-disclaimer h3 {
  font-size: var(--text-lg);
  margin-bottom: var(--space-4);
}

.toll-disclaimer p {
  font-size: var(--text-sm);
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: var(--space-3);
}

.toll-disclaimer p:last-child {
  margin-bottom: 0;
}


/* ── Official SCA tools ──────────────────────────────────────────────────── */

.toll-official-links {
  margin-top: var(--space-8);
  padding: var(--space-8);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg, 12px);
}

.toll-official-links h3 {
  font-size: var(--text-lg);
  margin-bottom: var(--space-3);
}

.toll-official-links > p {
  font-size: var(--text-sm);
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: var(--space-5);
}

.toll-official-links__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-5);
}

.toll-official-links__card {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  padding: var(--space-5);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--light-bg);
  text-decoration: none;
  transition: border-color var(--transition-base), box-shadow var(--transition-base);
}

.toll-official-links__card:hover {
  border-color: var(--secondary);
  box-shadow: var(--shadow-sm, 0 2px 8px rgba(0,0,0,0.06));
}

.toll-official-links__title {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--secondary);
}

.toll-official-links__desc {
  font-size: var(--text-xs);
  color: var(--text-muted);
  line-height: 1.6;
}

@media (max-width: 768px) {
  .toll-official-links__grid {
    grid-template-columns: 1fr;
  }
}


@media (max-width: 768px) {
  .toll-total__sdr {
    font-size: var(--text-2xl);
  }
}
