/* dns.css - Scoped styles for the DNS Lookup tool */

.dns-form {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 22px;
  margin: 0 0 18px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: flex-end;
}

.dns-form .field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 160px;
  flex: 1 1 160px;
}

.dns-form .field label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-2);
}

.dns-form .field input,
.dns-form .field select {
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: var(--r);
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  font-family: var(--font);
  transition: border-color 0.15s;
  outline: none;
}

.dns-form .field input:focus,
.dns-form .field select:focus {
  border-color: var(--accent);
}

.dns-form #dnsHost {
  font-family: var(--mono);
}

#dnsSubmit {
  align-self: flex-end;
  flex-shrink: 0;
}

/* Status badge */
.dns-status {
  display: inline-block;
  font-size: 13px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: var(--r-sm);
  margin-bottom: 14px;
  letter-spacing: 0.03em;
}

.dns-status.ok {
  background: color-mix(in srgb, var(--accent) 15%, transparent);
  color: var(--accent-d);
}

.dns-status.err {
  background: color-mix(in srgb, var(--danger) 15%, transparent);
  color: var(--danger);
}

/* Loading + empty states */
.dns-loading {
  color: var(--text-2);
  font-size: 14px;
  font-style: italic;
  padding: 12px 0;
}

.dns-empty {
  color: var(--text-2);
  font-size: 14px;
  padding: 12px 0;
}

/* Error text */
.err {
  color: var(--danger);
  font-size: 14px;
  font-weight: 500;
  margin: 8px 0;
}

/* Table */
.dns-table-wrap {
  overflow-x: auto;
  border-radius: var(--r);
  border: 1px solid var(--border);
  margin-bottom: 14px;
}

.dns-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
}

.dns-table thead tr {
  background: var(--surface-3);
}

.dns-table th {
  padding: 9px 12px;
  text-align: left;
  font-weight: 700;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-2);
  white-space: nowrap;
}

.dns-table tbody tr:nth-child(even) {
  background: var(--surface-2);
}

.dns-table tbody tr:nth-child(odd) {
  background: var(--surface);
}

.dns-table td {
  padding: 8px 12px;
  vertical-align: top;
  border-top: 1px solid var(--border);
  color: var(--text);
}

.dns-table .mono,
.dns-table .dns-data {
  font-family: var(--mono);
  font-size: 13px;
  word-break: break-all;
}

/* Actions bar */
.dns-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 4px;
}

/* Live network note */
.dns-net-note {
  font-size: 12.5px;
  color: var(--text-3);
  padding: 8px 0 4px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.dns-net-note::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--info, #2980b9);
  flex-shrink: 0;
}
