/* ================================================================
   SchergenDNS – Styles
   Gleiche Farbwelt wie die übrigen Werkzeuge.
   ================================================================ */

:root {
  --bg:            #0e1016;
  --surface:       rgba(255, 255, 255, .045);
  --surface-2:     rgba(255, 255, 255, .075);
  --line:          rgba(255, 255, 255, .10);
  --line-soft:     rgba(255, 255, 255, .06);
  --text:          #e8ebf2;
  --text-dim:      #98a1b5;
  --accent:        #7aa2ff;
  --accent-strong: #5b86ff;
  --ok:            #2fd68b;
  --warn:          #ffc861;
  --off:           #ff5468;
  --radius:        16px;
  --shadow:        0 18px 45px rgba(0, 0, 0, .45);
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas,
          "Liberation Mono", monospace;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }

body {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
               "Helvetica Neue", Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  font-size: 15px;
  line-height: 1.5;
}
body.is-busy { cursor: progress; }

h1, h2, h3 { margin: 0; font-weight: 650; letter-spacing: -.01em; }
code { font-family: var(--mono); font-size: .92em; }

kbd {
  font: inherit;
  font-size: .78em;
  font-weight: 600;
  padding: .1em .4em;
  border: 1px solid var(--line);
  border-bottom-width: 2px;
  border-radius: 6px;
  background: var(--surface-2);
  color: var(--text-dim);
}

.aurora {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(1100px 700px at 12% -10%, #26304a 0%, transparent 60%),
    radial-gradient(900px 600px at 100% 0%, #2a2140 0%, transparent 55%);
}

/* ----------------------------------------------------------------
   Buttons, Kopfzeile, Gerüst
   ---------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .4em;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text);
  border-radius: 10px;
  padding: .5rem .9rem;
  font: inherit;
  font-weight: 550;
  text-decoration: none;
  cursor: pointer;
  transition: background .15s, border-color .15s, transform .08s;
}
.btn:hover:not(:disabled)  { background: var(--surface-2); border-color: rgba(255,255,255,.18); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .45; cursor: progress; }
.btn--primary {
  background: linear-gradient(180deg, var(--accent), var(--accent-strong));
  border-color: transparent;
  color: #0b1020;
  font-weight: 650;
}
.btn--primary:hover:not(:disabled) { filter: brightness(1.06); }
.btn--ghost { background: transparent; }

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: .85rem clamp(1rem, 3vw, 2rem);
  border-bottom: 1px solid var(--line-soft);
  background: rgba(14, 16, 22, .72);
  backdrop-filter: blur(14px);
  position: sticky;
  top: 0;
  z-index: 30;
}
.topbar__brand { display: flex; align-items: center; gap: .6rem; font-weight: 650; }
.topbar__logo  { font-size: 1.25rem; }
.topbar__right { display: flex; align-items: center; gap: .75rem; }
.topbar__note  {
  color: var(--text-dim);
  font-size: .8rem;
  padding: .3rem .7rem;
  border: 1px solid var(--line-soft);
  border-radius: 999px;
}

.shell {
  max-width: 900px;
  margin: 0 auto;
  padding: clamp(1.2rem, 3vw, 2rem) clamp(1rem, 3vw, 2rem) 3rem;
}

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.1rem clamp(1rem, 2vw, 1.3rem) 1.2rem;
  margin-bottom: clamp(.9rem, 2vw, 1.2rem);
}
.card--input { box-shadow: var(--shadow); }
.card--check { border-color: rgba(122,162,255,.35); }

.card__head  { display: flex; align-items: baseline; gap: .7rem; flex-wrap: wrap; margin-bottom: .8rem; }
.card__title { font-size: 1.05rem; font-family: var(--mono); }
.card--check .card__title { font-family: inherit; margin-bottom: .9rem; }
.card__aside { font-size: .84rem; font-weight: 400; }
.ms { margin-left: auto; font-size: .76rem; color: var(--text-dim); font-variant-numeric: tabular-nums; }

.sub {
  font-size: .78rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--text-dim);
  margin: 1.2rem 0 .5rem;
}
.hint { color: var(--text-dim); font-size: .82rem; margin: .6rem 0 0; }
.note { color: var(--text-dim); font-size: .86rem; margin: 0 0 .6rem; white-space: pre-line; }
.dim  { color: var(--text-dim); }

/* ----------------------------------------------------------------
   Eingabe
   ---------------------------------------------------------------- */
.field > label {
  display: block;
  font-size: .78rem;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--text-dim);
  margin-bottom: .35rem;
}
.inputrow { display: flex; gap: .6rem; }
.inputrow input {
  flex: 1;
  min-width: 0;
  padding: .7rem .85rem;
  border-radius: 11px;
  border: 1px solid var(--line);
  background: rgba(0, 0, 0, .28);
  color: var(--text);
  font: inherit;
  font-family: var(--mono);
  font-size: 1rem;
}
.inputrow input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(122, 162, 255, .18);
}

.types { display: flex; flex-wrap: wrap; gap: .4rem; }
.type {
  font: inherit;
  font-family: var(--mono);
  font-size: .82rem;
  font-weight: 600;
  color: var(--text-dim);
  background: rgba(0, 0, 0, .25);
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: .3rem .7rem;
  cursor: pointer;
  transition: color .12s, border-color .12s, background .12s;
}
.type:hover { color: var(--text); }
.type.is-on {
  color: #0b1020;
  background: linear-gradient(180deg, var(--accent), var(--accent-strong));
  border-color: transparent;
}

.actions { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; margin-top: 1rem; }
.actions .hint { margin: 0 0 0 auto; }

.samples { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; margin-top: .9rem; }
.samples:empty { margin-top: 0; }
.samples__label { font-size: .78rem; color: var(--text-dim); margin-right: .2rem; }
.chip-btn {
  font: inherit;
  font-family: var(--mono);
  font-size: .78rem;
  color: var(--text-dim);
  background: var(--surface-2);
  border: 1px solid var(--line-soft);
  border-radius: 999px;
  padding: .22rem .65rem;
  cursor: pointer;
  transition: color .15s, border-color .15s;
}
.chip-btn:hover { color: var(--accent); border-color: rgba(122,162,255,.4); }

/* ----------------------------------------------------------------
   Ergebnisse
   ---------------------------------------------------------------- */
.summary {
  border-radius: 12px;
  padding: .6rem 1rem;
  margin-bottom: 1rem;
  border: 1px solid var(--line);
  background: var(--surface-2);
  font-family: var(--mono);
  font-size: .92rem;
}

.recs { display: grid; gap: 1px; background: var(--line-soft); border: 1px solid var(--line-soft); border-radius: 12px; overflow: hidden; }

.rec {
  display: grid;
  grid-template-columns: minmax(150px, 240px) minmax(0, 1fr) 30px;
  gap: .8rem;
  align-items: start;
  padding: .55rem .8rem;
  background: rgba(14, 16, 22, .55);
}
.rec:nth-child(odd) { background: rgba(255,255,255,.015); }

.rec__meta { display: flex; flex-wrap: wrap; align-items: baseline; gap: .4rem; min-width: 0; }
.rec__host { font-family: var(--mono); font-size: .82rem; color: var(--text-dim); overflow-wrap: anywhere; }
.rec__ttl  { font-size: .72rem; color: var(--text-dim); opacity: .8; white-space: nowrap; }
.rec__value { min-width: 0; display: flex; flex-wrap: wrap; align-items: baseline; gap: .45rem; }
.rec__copy {
  background: none;
  border: 0;
  color: var(--text-dim);
  cursor: copy;
  font-size: .95rem;
  padding: 0;
  line-height: 1.4;
}
.rec__copy:hover { color: var(--accent); }

.txt {
  font-family: var(--mono);
  font-size: .86rem;
  overflow-wrap: anywhere;
  width: 100%;
}
.pri {
  font-family: var(--mono);
  font-size: .74rem;
  color: var(--text-dim);
  border: 1px solid var(--line-soft);
  border-radius: 6px;
  padding: 0 .35rem;
}
.tagling {
  font-family: var(--mono);
  font-size: .68rem;
  border: 1px solid var(--line-soft);
  border-radius: 999px;
  padding: 0 .45rem;
  color: var(--text-dim);
}

.link {
  font: inherit;
  font-family: var(--mono);
  font-size: .88rem;
  color: var(--text);
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  text-align: left;
  border-bottom: 1px dotted rgba(255,255,255,.25);
  overflow-wrap: anywhere;
}
.link:hover { color: var(--accent); border-bottom-color: var(--accent); }

.iplink {
  font-family: var(--mono);
  font-size: .88rem;
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px dotted rgba(122,162,255,.5);
}
.iplink:hover { color: #b9ccff; }

.kind {
  font-size: .66rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  padding: .12rem .45rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--text-dim);
  white-space: nowrap;
}
.kind--spf   { color: #b9ccff; border-color: rgba(122,162,255,.4); background: rgba(122,162,255,.12); }
.kind--dmarc { color: #8ae9bf; border-color: rgba(47,214,139,.4);  background: rgba(47,214,139,.12); }
.kind--dkim  { color: #ffdca0; border-color: rgba(255,200,97,.4);  background: rgba(255,200,97,.12); }

.inline-note {
  font-size: .8rem;
  color: var(--text-dim);
  width: 100%;
  margin: .15rem 0 0;
  padding: .3rem .55rem;
  border-radius: 8px;
  background: var(--surface-2);
  border: 1px solid var(--line-soft);
}
.inline-note--ok   { color: #8ae9bf; border-color: rgba(47,214,139,.35);  background: rgba(47,214,139,.10); }
.inline-note--warn { color: #ffdca0; border-color: rgba(255,200,97,.35);  background: rgba(255,200,97,.10); }
.inline-note--bad  { color: #ffc3ca; border-color: rgba(255,84,104,.35);  background: rgba(255,84,104,.10); }

.soa { display: grid; gap: .15rem; width: 100%; }
.soa__row { display: flex; gap: .6rem; font-size: .82rem; }
.soa__key { color: var(--text-dim); min-width: 8.5rem; }
.soa__val { font-family: var(--mono); overflow-wrap: anywhere; }

/* ----------------------------------------------------------------
   Mail-Diagnose
   ---------------------------------------------------------------- */
.verdict {
  display: flex;
  align-items: flex-start;
  gap: .8rem;
  border-radius: 12px;
  padding: .7rem .85rem;
  border: 1px solid var(--line);
  background: var(--surface-2);
  margin-bottom: .55rem;
}
.verdict__icon { font-size: 1.1rem; font-weight: 700; width: 1.4rem; text-align: center; flex: none; }
.verdict--ok   { border-color: rgba(47,214,139,.4);  background: rgba(47,214,139,.10); }
.verdict--ok   .verdict__icon { color: var(--ok); }
.verdict--warn { border-color: rgba(255,200,97,.4);  background: rgba(255,200,97,.10); }
.verdict--warn .verdict__icon { color: var(--warn); }
.verdict--bad  { border-color: rgba(255,84,104,.4);  background: rgba(255,84,104,.10); }
.verdict--bad  .verdict__icon { color: var(--off); }
.verdict .note { margin: .2rem 0 0; font-family: var(--mono); font-size: .8rem; }

/* ----------------------------------------------------------------
   Fußzeile und Meldung
   ---------------------------------------------------------------- */
.foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: .5rem;
  color: var(--text-dim);
  font-size: .8rem;
  padding-top: 1.2rem;
  border-top: 1px solid var(--line-soft);
  text-align: center;
}
.foot__sep { opacity: .5; }

.toast {
  position: fixed;
  left: 50%;
  bottom: 1.5rem;
  transform: translate(-50%, 140%);
  background: #1c2130;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: .6rem 1rem;
  font-size: .87rem;
  box-shadow: var(--shadow);
  transition: transform .25s ease, opacity .25s;
  opacity: 0;
  z-index: 60;
  max-width: min(90vw, 460px);
  overflow-wrap: anywhere;
}
.toast.is-visible { transform: translate(-50%, 0); opacity: 1; }
.toast.is-error { border-color: rgba(255, 84, 104, .5); color: #ffc3ca; }

@media (max-width: 700px) {
  .rec { grid-template-columns: 1fr 26px; }
  .rec__meta { grid-column: 1 / -1; }
  .rec__value { grid-column: 1; }
  .soa__key { min-width: 7rem; }
  .topbar__note, .actions .hint { display: none; }
  .inputrow { flex-wrap: wrap; }
  .inputrow input { width: 100%; flex: none; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}
