/* ── SPF/DKIM/DMARC Checker — tool styles ────────────────────────────────── */

main { max-width: 60rem; margin: 0 auto; padding: 0 1rem 2rem; }

/* Tab bar */
.tab-bar { display: flex; gap: .35rem; margin: 1.5rem 0 1rem; border-bottom: 1px solid var(--border, rgba(128,128,128,.25)); }
.tab-btn {
    appearance: none; background: transparent; border: 0; cursor: pointer;
    font: inherit; font-weight: 600; color: var(--text-3, #888);
    padding: .6rem .9rem; border-bottom: 2px solid transparent; margin-bottom: -1px;
    display: inline-flex; align-items: center; gap: .4rem;
}
.tab-btn:hover { color: var(--text, inherit); }
.tab-btn.active { color: var(--text, inherit); border-bottom-color: var(--accent, #4f8cff); }
.tab-icon { font-size: .95em; }
.tab-panel[hidden] { display: none; }

/* Cards */
.card {
    border: 1px solid var(--border, rgba(128,128,128,.25));
    border-radius: .65rem; padding: 1.1rem 1.2rem; margin-bottom: 1rem;
    background: var(--surface-1, transparent);
}
.card-title { font-weight: 700; margin-bottom: .85rem; font-size: 1.02rem; }

/* Inputs */
.input-row { display: flex; gap: .6rem; align-items: flex-end; flex-wrap: wrap; }
.input-group { display: flex; flex-direction: column; gap: .3rem; flex: 1 1 16rem; }
.input-group label { font-size: .8rem; font-weight: 600; color: var(--text-2, inherit); }
.input-group input, .input-group textarea, .input-group select {
    font: inherit; padding: .55rem .65rem; border-radius: .45rem;
    border: 1px solid var(--border, rgba(128,128,128,.35));
    background: var(--bg, #0d1117); color: var(--text, inherit); width: 100%;
}
.input-group textarea { resize: vertical; font-family: var(--font-mono, monospace); font-size: .85rem; }
.input-inline { flex: 1 1 13rem; }

/* Buttons */
.btn {
    appearance: none; cursor: pointer; font: inherit; font-weight: 600;
    border: 1px solid var(--border, rgba(128,128,128,.35)); border-radius: .45rem;
    padding: .55rem 1.1rem; background: var(--surface-2, transparent); color: var(--text, inherit);
}
.btn-primary { background: var(--accent, #4f8cff); border-color: var(--accent, #4f8cff); color: #fff; }
.btn-primary:hover { filter: brightness(1.05); }
.btn-sm { padding: .35rem .8rem; font-size: .85rem; }

/* Examples */
.examples { margin-top: .75rem; display: flex; gap: .4rem; flex-wrap: wrap; align-items: center; }
.examples-label { font-size: .78rem; color: var(--text-3, #888); }
.example-btn {
    appearance: none; cursor: pointer; font: inherit; font-size: .8rem;
    border: 1px solid var(--border, rgba(128,128,128,.3)); border-radius: 999px;
    padding: .2rem .65rem; background: transparent; color: var(--text-2, inherit);
}
.example-btn:hover { border-color: var(--accent, #4f8cff); color: var(--text, inherit); }

/* Results */
.result-area { margin-top: 1rem; display: flex; flex-direction: column; gap: .85rem; }
.res-card {
    border: 1px solid var(--border, rgba(128,128,128,.25)); border-left-width: 4px;
    border-radius: .55rem; padding: .95rem 1.1rem; background: var(--surface-1, transparent);
}
.res-card.pass { border-left-color: #2ea043; }
.res-card.warn { border-left-color: #d29922; }
.res-card.fail { border-left-color: #f85149; }
.res-card.info { border-left-color: var(--text-3, #888); }
.res-head { display: flex; align-items: center; gap: .55rem; flex-wrap: wrap; }
.res-title { font-weight: 700; font-size: 1rem; }
.res-badge {
    font-size: .68rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase;
    padding: .12rem .5rem; border-radius: 999px; border: 1px solid currentColor;
}
.res-badge.pass { color: #2ea043; }
.res-badge.warn { color: #d29922; }
.res-badge.fail { color: #f85149; }
.res-badge.info { color: var(--text-3, #888); }
.res-record {
    font-family: var(--font-mono, monospace); font-size: .82rem; line-height: 1.5;
    background: var(--bg, #0d1117); border: 1px solid var(--border, rgba(128,128,128,.25));
    border-radius: .4rem; padding: .55rem .7rem; margin: .65rem 0 .4rem; overflow-x: auto;
    white-space: pre-wrap; word-break: break-word;
}
.res-notes { margin: .5rem 0 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: .35rem; }
.res-notes li { font-size: .85rem; color: var(--text-2, inherit); display: flex; gap: .45rem; line-height: 1.5; }
.res-notes li::before { content: "•"; color: var(--text-3, #888); }
.res-notes li.n-fail::before { content: "✗"; color: #f85149; }
.res-notes li.n-warn::before { content: "!"; color: #d29922; font-weight: 700; }
.res-notes li.n-pass::before { content: "✓"; color: #2ea043; }
.res-loading { color: var(--text-3, #888); font-size: .9rem; padding: .5rem 0; }

/* Generator */
.gen-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); gap: .85rem; }
.gen-opts { display: flex; flex-wrap: wrap; gap: .85rem 1.2rem; align-items: flex-end; margin-top: .85rem; }
.opt-check { display: inline-flex; align-items: center; gap: .45rem; font-size: .85rem; color: var(--text-2, inherit); }
.gen-out { margin-top: 1rem; }
.gen-out > label { font-size: .8rem; font-weight: 600; color: var(--text-2, inherit); }
.record-out {
    font-family: var(--font-mono, monospace); font-size: .85rem; line-height: 1.5;
    background: var(--bg, #0d1117); border: 1px solid var(--border, rgba(128,128,128,.25));
    border-radius: .45rem; padding: .65rem .75rem; margin: .4rem 0 .5rem; overflow-x: auto;
    white-space: pre-wrap; word-break: break-word;
}
.gen-actions { display: flex; align-items: center; gap: .8rem; }
.lookup-meter { font-size: .8rem; color: var(--text-3, #888); }
.lookup-meter.over { color: #f85149; font-weight: 600; }
.gen-note p { color: var(--text-2, inherit); line-height: 1.6; margin: 0; }
.gen-note code, .gen-opts code, .feature-card code, .record-out code { font-family: var(--font-mono, monospace); font-size: .9em; }

/* Info / feature grid (mirrors other tools) */
.info-section { padding: 2.5rem 1rem; }
.info-inner { max-width: 62rem; margin: 0 auto; }
.section-lead { color: var(--text-2, inherit); max-width: 46rem; }
.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr)); gap: 1rem; margin-top: 1.5rem; }
.feature-card { border: 1px solid var(--border, rgba(128,128,128,.2)); border-radius: .55rem; padding: 1rem 1.1rem; }
.feature-card h3 { margin: 0 0 .4rem; font-size: .98rem; }
.feature-card p { margin: 0; color: var(--text-2, inherit); line-height: 1.55; font-size: .9rem; }
