/* ==========================================================================
   Info-DNS · hoja de estilos de la versión nueva
   Independiente del tema anterior: no requiere Bootstrap ni Font Awesome.
   ========================================================================== */

/* --- Tokens --------------------------------------------------------------- */

:root {
	color-scheme: light;

	--bg: #f6f7fb;
	--bg-grad: radial-gradient(1200px 600px at 50% -200px, #e6eaff 0%, transparent 70%);
	--surface: #ffffff;
	--surface-2: #f2f4f9;
	--surface-3: #e9ecf4;
	--border: #e2e6ef;
	--border-strong: #cdd4e3;

	--text: #0f1420;
	--text-2: #3d4659;
	--muted: #6b7489;

	--accent: #4f5bd5;
	--accent-ink: #ffffff;
	--accent-hover: #4049c4;
	--accent-soft: #eceefc;

	--ok: #0d9268;
	--warn: #b47608;
	--danger: #d23a56;

	--shadow-sm: 0 1px 2px rgba(15, 20, 32, .06), 0 1px 3px rgba(15, 20, 32, .04);
	--shadow: 0 2px 4px rgba(15, 20, 32, .04), 0 12px 28px -12px rgba(15, 20, 32, .18);
	--shadow-lg: 0 4px 8px rgba(15, 20, 32, .04), 0 24px 48px -16px rgba(15, 20, 32, .22);

	--radius: 14px;
	--radius-sm: 9px;
	--radius-lg: 20px;

	--mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
	--sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

	--maxw: 1180px;
}

[data-theme="dark"] {
	color-scheme: dark;

	--bg: #0b0e14;
	--bg-grad: radial-gradient(1200px 600px at 50% -240px, #1b2142 0%, transparent 70%);
	--surface: #131822;
	--surface-2: #181e2a;
	--surface-3: #202736;
	--border: #242c3a;
	--border-strong: #334055;

	--text: #eef1f7;
	--text-2: #c2c9d8;
	--muted: #8b95ab;

	--accent: #7c87ff;
	--accent-ink: #0b0e14;
	--accent-hover: #929cff;
	--accent-soft: #1c2240;

	--ok: #35c793;
	--warn: #e0a331;
	--danger: #ff6b85;

	--shadow-sm: 0 1px 2px rgba(0, 0, 0, .4);
	--shadow: 0 2px 4px rgba(0, 0, 0, .3), 0 14px 32px -14px rgba(0, 0, 0, .7);
	--shadow-lg: 0 4px 10px rgba(0, 0, 0, .35), 0 28px 56px -20px rgba(0, 0, 0, .8);
}

/* --- Reset ---------------------------------------------------------------- */

*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

/* Necesario: varios componentes fijan display y anularían el atributo hidden */
[hidden] { display: none !important; }

body {
	margin: 0;
	min-height: 100vh;
	background: var(--bg);
	background-image: var(--bg-grad);
	background-repeat: no-repeat;
	color: var(--text);
	font-family: var(--sans);
	font-size: 15px;
	line-height: 1.55;
	-webkit-font-smoothing: antialiased;
	display: flex;
	flex-direction: column;
}

h1, h2, h3, h4, h5 {
	margin: 0;
	font-weight: 650;
	letter-spacing: -.02em;
	line-height: 1.2;
}

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

img, svg { max-width: 100%; }

input, button, select, textarea { font: inherit; color: inherit; }

:focus-visible {
	outline: 2px solid var(--accent);
	outline-offset: 2px;
	border-radius: 4px;
}

/* --- Estructura ----------------------------------------------------------- */

.wrap {
	width: 100%;
	max-width: var(--maxw);
	margin-inline: auto;
	padding-inline: 20px;
}

main { flex: 1 0 auto; }

.section { padding-block: 56px; }
.section-sm { padding-block: 32px; }

/* --- Cabecera ------------------------------------------------------------- */

.site-header {
	position: sticky;
	top: 0;
	z-index: 50;
	background: color-mix(in srgb, var(--bg) 82%, transparent);
	backdrop-filter: saturate(180%) blur(14px);
	-webkit-backdrop-filter: saturate(180%) blur(14px);
	border-bottom: 1px solid transparent;
	transition: border-color .2s ease, background .2s ease;
}

.site-header.is-stuck {
	border-bottom-color: var(--border);
	background: color-mix(in srgb, var(--bg) 94%, transparent);
}

.site-header .wrap {
	display: flex;
	align-items: center;
	gap: 16px;
	min-height: 62px;
}

.brand {
	display: inline-flex;
	align-items: center;
	gap: 9px;
	color: var(--text);
	font-weight: 700;
	letter-spacing: -.03em;
	font-size: 18px;
	text-decoration: none;
	flex: none;
}

.brand:hover { text-decoration: none; }

/* El logotipo original es monocromo oscuro: en tema oscuro se pasa a blanco */
.brand-logo {
	display: block;
	height: 25px;
	width: auto;
	flex: none;
}

[data-theme="dark"] .brand-logo {
	filter: brightness(0) invert(1);
	opacity: .92;
}

.site-footer .brand-logo { height: 28px; }

.site-nav {
	display: flex;
	align-items: center;
	gap: 4px;
	margin-left: auto;
}

.site-nav a.navlink {
	padding: 7px 11px;
	border-radius: var(--radius-sm);
	color: var(--text-2);
	font-size: 14px;
	font-weight: 550;
	text-decoration: none;
	white-space: nowrap;
}

.site-nav a.navlink:hover {
	background: var(--surface-2);
	color: var(--text);
	text-decoration: none;
}

.site-nav a.navlink.is-active { color: var(--accent); background: var(--accent-soft); }

/* Buscador compacto en la cabecera (páginas de resultados) */

.header-search {
	flex: 1 1 320px;
	max-width: 420px;
	min-width: 0;
	display: flex;
	align-items: center;
	gap: 8px;
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: 999px;
	padding: 4px 4px 4px 12px;
	box-shadow: var(--shadow-sm);
	transition: border-color .15s ease, box-shadow .15s ease;
}

.header-search:focus-within {
	border-color: var(--accent);
	box-shadow: 0 0 0 3px var(--accent-soft);
}

.header-search input {
	flex: 1;
	min-width: 0;
	border: 0;
	background: none;
	padding: 5px 0;
	font-family: var(--mono);
	font-size: 13.5px;
}

.header-search input:focus { outline: none; }

.header-search button {
	flex: none;
	border: 0;
	cursor: pointer;
	width: 30px;
	height: 30px;
	border-radius: 999px;
	background: var(--accent);
	color: var(--accent-ink);
	display: grid;
	place-items: center;
}

.header-search button:hover { background: var(--accent-hover); }

/* Botón de tema */

.theme-toggle {
	flex: none;
	width: 34px;
	height: 34px;
	display: grid;
	place-items: center;
	border-radius: var(--radius-sm);
	border: 1px solid var(--border);
	background: var(--surface);
	color: var(--text-2);
	cursor: pointer;
}

.theme-toggle:hover { color: var(--text); border-color: var(--border-strong); }
.theme-toggle .icon-moon { display: none; }
[data-theme="dark"] .theme-toggle .icon-sun { display: none; }
[data-theme="dark"] .theme-toggle .icon-moon { display: block; }

.nav-toggle {
	display: none;
	width: 34px;
	height: 34px;
	place-items: center;
	border-radius: var(--radius-sm);
	border: 1px solid var(--border);
	background: var(--surface);
	color: var(--text-2);
	cursor: pointer;
}

/* --- Botones -------------------------------------------------------------- */

.btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 9px 16px;
	border-radius: var(--radius-sm);
	border: 1px solid transparent;
	background: var(--surface-2);
	color: var(--text);
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
	text-decoration: none;
	white-space: nowrap;
	transition: background .15s ease, border-color .15s ease, color .15s ease, transform .1s ease;
}

.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px); }

.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-primary:hover { background: var(--accent-hover); }

.btn-ghost { background: var(--surface); border-color: var(--border); color: var(--text-2); }
.btn-ghost:hover { border-color: var(--border-strong); color: var(--text); }

.btn-sm { padding: 6px 11px; font-size: 13px; border-radius: 8px; }
.btn-lg { padding: 13px 24px; font-size: 15.5px; border-radius: var(--radius); }

.btn svg { flex: none; }

/* --- Tarjetas ------------------------------------------------------------- */

.card {
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: var(--radius);
	box-shadow: var(--shadow-sm);
}

.card-head {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 13px 16px;
	border-bottom: 1px solid var(--border);
}

.card-head h3 {
	font-size: 14.5px;
	font-weight: 650;
}

.card-body { padding: 16px; }

/* --- Portada -------------------------------------------------------------- */

.hero {
	padding-block: 64px 44px;
	text-align: center;
}

.hero .eyebrow {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	padding: 5px 12px 5px 8px;
	border-radius: 999px;
	background: var(--surface);
	border: 1px solid var(--border);
	color: var(--muted);
	font-size: 12.5px;
	font-weight: 550;
	margin-bottom: 20px;
	box-shadow: var(--shadow-sm);
}

.hero .eyebrow .dot {
	width: 7px;
	height: 7px;
	border-radius: 999px;
	background: var(--ok);
	box-shadow: 0 0 0 3px color-mix(in srgb, var(--ok) 20%, transparent);
}

.hero h1 {
	font-size: clamp(32px, 6vw, 52px);
	letter-spacing: -.035em;
	margin-bottom: 14px;
}

.hero h1 em {
	font-style: normal;
	background: linear-gradient(100deg, var(--accent), color-mix(in srgb, var(--accent) 50%, var(--ok)));
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
}

.hero .lead {
	max-width: 560px;
	margin-inline: auto;
	color: var(--muted);
	font-size: clamp(15px, 2.2vw, 17.5px);
}

/* Buscador principal */

.search-card {
	max-width: 680px;
	margin: 30px auto 0;
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow-lg);
	overflow: hidden;
	text-align: left;
}

.search-tabs {
	display: flex;
	gap: 2px;
	padding: 6px 6px 0;
	border-bottom: 1px solid var(--border);
}

.search-tabs button {
	flex: 1;
	padding: 10px 12px;
	border: 0;
	background: none;
	border-radius: var(--radius-sm) var(--radius-sm) 0 0;
	color: var(--muted);
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
	position: relative;
}

.search-tabs button:hover { color: var(--text); background: var(--surface-2); }

.search-tabs button[aria-selected="true"] { color: var(--accent); }

.search-tabs button[aria-selected="true"]::after {
	content: "";
	position: absolute;
	left: 12px;
	right: 12px;
	bottom: -1px;
	height: 2px;
	border-radius: 2px;
	background: var(--accent);
}

.search-panel { padding: 18px; }
.search-panel[hidden] { display: none; }

.field-row {
	display: flex;
	gap: 10px;
	align-items: stretch;
}

.input {
	width: 100%;
	padding: 13px 15px;
	border-radius: var(--radius);
	border: 1px solid var(--border-strong);
	background: var(--surface-2);
	font-family: var(--mono);
	font-size: 15px;
	transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
}

.input::placeholder { color: var(--muted); opacity: .75; }

.input:focus {
	outline: none;
	background: var(--surface);
	border-color: var(--accent);
	box-shadow: 0 0 0 3px var(--accent-soft);
}

textarea.input { resize: vertical; min-height: 118px; line-height: 1.6; }

select.input { font-family: var(--sans); cursor: pointer; }

.field-help {
	margin-top: 10px;
	color: var(--muted);
	font-size: 13px;
}

.search-foot {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px 16px;
	margin-top: 14px;
}

.examples {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 6px;
	font-size: 13px;
	color: var(--muted);
}

.chip-example {
	border: 1px solid var(--border);
	background: var(--surface-2);
	border-radius: 999px;
	padding: 3px 10px;
	font-family: var(--mono);
	font-size: 12.5px;
	color: var(--text-2);
	cursor: pointer;
}

.chip-example:hover { border-color: var(--accent); color: var(--accent); }

/* --- Métricas ------------------------------------------------------------- */

.stats {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 14px;
	margin-top: 44px;
}

.stat {
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: var(--radius);
	padding: 18px;
	text-align: center;
	box-shadow: var(--shadow-sm);
}

.stat .num {
	font-size: clamp(22px, 4vw, 30px);
	font-weight: 700;
	letter-spacing: -.03em;
	font-variant-numeric: tabular-nums;
}

.stat .lbl {
	color: var(--muted);
	font-size: 13px;
	margin-top: 2px;
}

/* --- Bloques de características ------------------------------------------ */

.features {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 16px;
}

.feature {
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: var(--radius);
	padding: 20px;
	box-shadow: var(--shadow-sm);
}

.feature .ico {
	width: 38px;
	height: 38px;
	border-radius: 10px;
	display: grid;
	place-items: center;
	background: var(--accent-soft);
	color: var(--accent);
	margin-bottom: 13px;
}

.feature h3 { font-size: 15.5px; margin-bottom: 6px; }
.feature p { color: var(--muted); font-size: 14px; }

/* --- Cabecera de resultados ---------------------------------------------- */

.result-head {
	padding-block: 28px 20px;
	border-bottom: 1px solid var(--border);
	margin-bottom: 26px;
}

.result-head .top {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 12px 16px;
}

.result-head h1 {
	font-family: var(--mono);
	font-size: clamp(22px, 4.4vw, 34px);
	font-weight: 600;
	letter-spacing: -.03em;
	word-break: break-all;
}

.result-head .puny {
	font-family: var(--mono);
	font-size: 13px;
	color: var(--muted);
	margin-top: 4px;
}

.head-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-left: auto;
}

.meta-row {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 14px;
}

.badge {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 4px 10px;
	border-radius: 999px;
	border: 1px solid var(--border);
	background: var(--surface);
	font-size: 12.5px;
	font-weight: 550;
	color: var(--text-2);
}

.badge svg { opacity: .7; }
.badge-ok { color: var(--ok); border-color: color-mix(in srgb, var(--ok) 35%, var(--border)); background: color-mix(in srgb, var(--ok) 9%, var(--surface)); }
.badge-warn { color: var(--warn); border-color: color-mix(in srgb, var(--warn) 35%, var(--border)); background: color-mix(in srgb, var(--warn) 9%, var(--surface)); }
.badge-danger { color: var(--danger); border-color: color-mix(in srgb, var(--danger) 35%, var(--border)); background: color-mix(in srgb, var(--danger) 9%, var(--surface)); }

/* --- Rejilla de resultados ------------------------------------------------ */

.result-grid {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 320px;
	gap: 24px;
	align-items: start;
	padding-bottom: 60px;
}

.sidebar {
	position: sticky;
	top: 82px;
	display: flex;
	flex-direction: column;
	gap: 16px;
}

/* --- Tarjeta de tipo de registro ----------------------------------------- */

.rec-stack {
	display: flex;
	flex-direction: column;
	gap: 14px;
}

.rec-card {
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: var(--radius);
	box-shadow: var(--shadow-sm);
	overflow: hidden;
	transition: border-color .15s ease;
}

.rec-card:hover { border-color: var(--border-strong); }
.rec-card[hidden] { display: none; }

.rec-head {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 11px 14px;
	background: var(--surface-2);
	border-bottom: 1px solid var(--border);
}

.rec-type {
	--c: var(--accent);
	flex: none;
	display: inline-flex;
	align-items: center;
	padding: 3px 9px;
	border-radius: 7px;
	background: color-mix(in srgb, var(--c) 15%, transparent);
	color: var(--c);
	border: 1px solid color-mix(in srgb, var(--c) 30%, transparent);
	font-family: var(--mono);
	font-size: 12px;
	font-weight: 650;
	letter-spacing: .02em;
}

.rec-type[data-type="NS"]      { --c: #4f5bd5; }
.rec-type[data-type="NS_ROOT"] { --c: #6b7489; }
.rec-type[data-type="A"]       { --c: #0d9268; }
.rec-type[data-type="AAAA"]    { --c: #0e8f97; }
.rec-type[data-type="MX"]      { --c: #b47608; }
.rec-type[data-type="TXT"]     { --c: #8a4fd0; }
.rec-type[data-type="CNAME"]   { --c: #2b7fd4; }
.rec-type[data-type="SOA"]     { --c: #c2466b; }

[data-theme="dark"] .rec-type[data-type="NS"]      { --c: #8d96ff; }
[data-theme="dark"] .rec-type[data-type="NS_ROOT"] { --c: #99a3b8; }
[data-theme="dark"] .rec-type[data-type="A"]       { --c: #3fd39b; }
[data-theme="dark"] .rec-type[data-type="AAAA"]    { --c: #40cdd6; }
[data-theme="dark"] .rec-type[data-type="MX"]      { --c: #e8ad43; }
[data-theme="dark"] .rec-type[data-type="TXT"]     { --c: #b58cf0; }
[data-theme="dark"] .rec-type[data-type="CNAME"]   { --c: #63b3f5; }
[data-theme="dark"] .rec-type[data-type="SOA"]     { --c: #ff7d9e; }

.rec-title {
	font-size: 13.5px;
	font-weight: 600;
	color: var(--text-2);
	min-width: 0;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.rec-count {
	margin-left: auto;
	flex: none;
	display: flex;
	align-items: center;
	gap: 8px;
	color: var(--muted);
	font-size: 12.5px;
	font-variant-numeric: tabular-nums;
}

.icon-btn {
	flex: none;
	width: 28px;
	height: 28px;
	display: grid;
	place-items: center;
	border-radius: 7px;
	border: 1px solid transparent;
	background: none;
	color: var(--muted);
	cursor: pointer;
	transition: background .15s ease, color .15s ease;
}

.icon-btn:hover { background: var(--surface-3); color: var(--text); }
.icon-btn.is-done { color: var(--ok); }

/* Filas */

.rec-rows { display: flex; flex-direction: column; }

.rec-row {
	display: flex;
	align-items: baseline;
	flex-wrap: wrap;
	gap: 10px;
	padding: 11px 14px;
	border-top: 1px solid var(--border);
	font-family: var(--mono);
	font-size: 13.5px;
	line-height: 1.5;
	word-break: break-word;
}

.rec-row:first-child { border-top: 0; }
.rec-row:hover { background: var(--surface-2); }

.rec-row .host {
	flex: none;
	color: var(--muted);
	max-width: 42%;
	overflow-wrap: anywhere;
}

.rec-row .arrow { flex: none; color: var(--border-strong); }

.rec-row .val {
	flex: 1;
	min-width: 0;
	color: var(--text);
	overflow-wrap: anywhere;
}

/* Un valor muy largo (clave DKIM, SPF con muchos includes) ocupa su propia
   línea completa en vez de quedarse en una columna estrecha y altísima */
.rec-row.is-long .val {
	order: 9;          /* el TTL se queda arriba a la derecha, el valor debajo */
	flex-basis: 100%;
	margin-top: 2px;
}

.rec-row .val a { text-decoration: none; border-bottom: 1px dashed color-mix(in srgb, var(--accent) 45%, transparent); }
.rec-row .val a:hover { text-decoration: none; border-bottom-style: solid; }

.rec-row .note {
	color: var(--muted);
	font-size: 12.5px;
}

.rec-row .pri {
	flex: none;
	display: inline-grid;
	place-items: center;
	min-width: 24px;
	height: 20px;
	padding-inline: 5px;
	border-radius: 5px;
	background: var(--surface-3);
	color: var(--muted);
	font-size: 11.5px;
	font-weight: 600;
}

.tag {
	flex: none;
	align-self: flex-start;
	padding: 1px 7px;
	border-radius: 5px;
	background: var(--accent-soft);
	color: var(--accent);
	border: 1px solid color-mix(in srgb, var(--accent) 25%, transparent);
	font-family: var(--sans);
	font-size: 11px;
	font-weight: 650;
	text-transform: uppercase;
	letter-spacing: .04em;
	white-space: nowrap;
}

.ttl {
	flex: none;
	margin-left: auto;
	padding: 2px 7px;
	border-radius: 5px;
	background: var(--surface-2);
	border: 1px solid var(--border);
	color: var(--muted);
	font-size: 11.5px;
	font-variant-numeric: tabular-nums;
	white-space: nowrap;
}

.rec-row:hover .ttl { background: var(--surface-3); }

.rec-empty {
	padding: 14px;
	color: var(--muted);
	font-size: 13.5px;
}

/* Esqueleto de carga */

.skeleton { padding: 13px 14px; display: flex; flex-direction: column; gap: 9px; }

.sk-line {
	height: 11px;
	border-radius: 5px;
	background: linear-gradient(90deg, var(--surface-2) 25%, var(--surface-3) 50%, var(--surface-2) 75%);
	background-size: 200% 100%;
	animation: sk 1.3s ease-in-out infinite;
}

.sk-line:nth-child(2) { width: 72%; }
.sk-line:nth-child(3) { width: 54%; }

@keyframes sk {
	0% { background-position: 200% 0; }
	100% { background-position: -200% 0; }
}

@media (prefers-reduced-motion: reduce) {
	.sk-line { animation: none; }
}

/* --- Panel lateral -------------------------------------------------------- */

.panel {
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: var(--radius);
	box-shadow: var(--shadow-sm);
	overflow: hidden;
}

.panel-head {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 12px 15px;
	border-bottom: 1px solid var(--border);
	font-size: 13.5px;
	font-weight: 650;
}

.panel-head svg { color: var(--muted); flex: none; }
.panel-body { padding: 15px; font-size: 13.5px; color: var(--text-2); }
.panel-body p { margin-bottom: 12px; }
.panel-body .btn { width: 100%; }

/* Observaciones (HTML heredado del controlador: .alert-info / .alert-danger) */

.obs { display: flex; flex-direction: column; gap: 8px; }
.obs > div { display: block; }
.obs i { display: none; }

.obs .alert {
	display: block;
	padding: 10px 12px 10px 13px;
	border-radius: var(--radius-sm);
	border: 1px solid var(--border);
	border-left: 3px solid var(--muted);
	background: var(--surface-2);
	font-size: 13px;
	line-height: 1.5;
	color: var(--text-2);
}

.obs .alert b { color: var(--text); font-weight: 650; }

.obs .alert-info {
	border-left-color: var(--accent);
	background: color-mix(in srgb, var(--accent) 7%, var(--surface));
	border-color: color-mix(in srgb, var(--accent) 22%, var(--border));
}

.obs .alert-danger {
	border-left-color: var(--danger);
	background: color-mix(in srgb, var(--danger) 7%, var(--surface));
	border-color: color-mix(in srgb, var(--danger) 22%, var(--border));
	color: color-mix(in srgb, var(--danger) 70%, var(--text));
}

.obs .alert-danger b { color: inherit; }

/* --- Avisos --------------------------------------------------------------- */

.notice {
	display: flex;
	gap: 12px;
	padding: 14px 16px;
	border-radius: var(--radius);
	border: 1px solid var(--border);
	background: var(--surface);
	font-size: 14px;
	box-shadow: var(--shadow-sm);
}

.notice svg { flex: none; margin-top: 2px; }
.notice-title { font-weight: 650; margin-bottom: 2px; }
.notice p { color: var(--muted); font-size: 13.5px; }

.notice-danger { border-left: 3px solid var(--danger); }
.notice-danger svg { color: var(--danger); }
.notice-warn { border-left: 3px solid var(--warn); }
.notice-warn svg { color: var(--warn); }

.notice ul { margin: 6px 0 0; padding-left: 18px; color: var(--muted); font-size: 13.5px; }

.empty-state {
	text-align: center;
	padding: 56px 20px;
	color: var(--muted);
}

.empty-state .ico {
	width: 52px;
	height: 52px;
	margin: 0 auto 16px;
	border-radius: 14px;
	display: grid;
	place-items: center;
	background: var(--surface-2);
	border: 1px solid var(--border);
	color: var(--muted);
}

.empty-state h2 { font-size: 19px; color: var(--text); margin-bottom: 8px; }

/* --- Rejilla masiva ------------------------------------------------------- */

.bulk-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(330px, 1fr));
	gap: 16px;
	padding-bottom: 60px;
}

.bulk-card .rec-head { background: var(--surface); }

.bulk-card .bulk-domain {
	font-family: var(--mono);
	font-size: 14px;
	font-weight: 600;
	min-width: 0;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.bulk-card .bulk-domain a { color: var(--text); }
.bulk-card .bulk-domain a:hover { color: var(--accent); text-decoration: none; }

/* --- Historial ------------------------------------------------------------ */

.timeline { display: flex; flex-direction: column; gap: 10px; }

.tl-item {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 12px 15px;
	border: 1px solid var(--border);
	border-radius: var(--radius);
	background: var(--surface);
	box-shadow: var(--shadow-sm);
	text-decoration: none;
	color: inherit;
	transition: border-color .15s ease, transform .1s ease;
}

.tl-item:hover { border-color: var(--accent); text-decoration: none; }
.tl-item.is-current { border-color: var(--accent); background: var(--accent-soft); }

.tl-dot {
	width: 9px;
	height: 9px;
	flex: none;
	border-radius: 999px;
	background: var(--border-strong);
}

.tl-item.is-current .tl-dot { background: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 25%, transparent); }

.tl-date { font-family: var(--mono); font-size: 13.5px; }
.tl-rel { margin-left: auto; color: var(--muted); font-size: 12.5px; }

/* --- Formularios / errores ------------------------------------------------ */

.alert-box {
	display: flex;
	gap: 10px;
	padding: 12px 14px;
	border-radius: var(--radius-sm);
	border: 1px solid color-mix(in srgb, var(--danger) 30%, var(--border));
	background: color-mix(in srgb, var(--danger) 8%, var(--surface));
	color: color-mix(in srgb, var(--danger) 75%, var(--text));
	font-size: 13.5px;
	margin-bottom: 16px;
}

.alert-box ul { margin: 0; padding-left: 18px; }
.alert-box svg { flex: none; margin-top: 2px; color: var(--danger); }

/* --- Cabecera de página simple ------------------------------------------- */

.page-head {
	padding-block: 44px 24px;
	text-align: center;
}

.page-head h1 {
	font-size: clamp(26px, 5vw, 38px);
	margin-bottom: 10px;
}

.page-head p {
	color: var(--muted);
	max-width: 56ch;
	margin-inline: auto;
}

/* --- Texto largo (legales) ------------------------------------------------ */

.prose {
	max-width: 76ch;
	margin-inline: auto;
	color: var(--text-2);
	font-size: 15px;
	line-height: 1.7;
}

.prose h2 {
	font-size: 19px;
	margin: 32px 0 10px;
	color: var(--text);
	scroll-margin-top: 80px;
}

.prose h2:first-child { margin-top: 0; }

.prose h3, .prose h4 {
	font-size: 16px;
	margin: 22px 0 6px;
	color: var(--text);
}

.prose p { margin: 0 0 14px; }
.prose ul, .prose ol { margin: 0 0 14px; padding-left: 22px; }
.prose li { margin-bottom: 6px; }
.prose a { overflow-wrap: anywhere; }
.prose b, .prose strong { color: var(--text); font-weight: 650; }

/* --- Formularios ---------------------------------------------------------- */

.form-card {
	max-width: 460px;
	margin-inline: auto;
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow-lg);
	padding: 26px;
}

.form-card.is-wide { max-width: 640px; }

.form-field { margin-bottom: 16px; }

.form-field label {
	display: block;
	margin-bottom: 6px;
	font-size: 13.5px;
	font-weight: 600;
	color: var(--text-2);
}

.form-field .input {
	font-family: var(--sans);
	padding: 11px 13px;
	font-size: 14.5px;
}

.form-field .input.is-invalid {
	border-color: var(--danger);
	background: color-mix(in srgb, var(--danger) 5%, var(--surface));
}

.form-error {
	display: block;
	margin-top: 5px;
	color: var(--danger);
	font-size: 12.5px;
}

.form-actions { margin-top: 20px; }
.form-actions .btn { width: 100%; }

.form-foot {
	margin-top: 18px;
	padding-top: 16px;
	border-top: 1px solid var(--border);
	text-align: center;
	font-size: 13.5px;
	color: var(--muted);
}

.form-row-between {
	display: flex;
	flex-wrap: wrap;
	gap: 8px 14px;
	align-items: center;
	justify-content: space-between;
	font-size: 13.5px;
}

.check {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	color: var(--text-2);
	cursor: pointer;
}

.check input { accent-color: var(--accent); width: 15px; height: 15px; }

.alert-ok {
	display: flex;
	gap: 10px;
	padding: 12px 14px;
	border-radius: var(--radius-sm);
	border: 1px solid color-mix(in srgb, var(--ok) 30%, var(--border));
	background: color-mix(in srgb, var(--ok) 8%, var(--surface));
	color: color-mix(in srgb, var(--ok) 75%, var(--text));
	font-size: 13.5px;
	margin-bottom: 16px;
}

.alert-ok svg { flex: none; margin-top: 2px; }

/* --- Pie ------------------------------------------------------------------ */

.site-footer {
	flex: none;
	border-top: 1px solid var(--border);
	background: var(--surface);
	padding-block: 36px 24px;
	margin-top: auto;
}

.footer-grid {
	display: grid;
	grid-template-columns: 1.6fr 1fr 1fr 1fr;
	gap: 28px;
}

.footer-grid h4 {
	font-size: 12px;
	text-transform: uppercase;
	letter-spacing: .07em;
	color: var(--muted);
	font-weight: 650;
	margin-bottom: 10px;
}

.footer-grid ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 7px; }
.footer-grid a { color: var(--text-2); font-size: 13.5px; text-decoration: none; }
.footer-grid a:hover { color: var(--accent); }
.footer-about { color: var(--muted); font-size: 13.5px; max-width: 34ch; margin-top: 10px; }

.footer-bottom {
	display: flex;
	flex-wrap: wrap;
	gap: 10px 20px;
	align-items: center;
	justify-content: space-between;
	margin-top: 28px;
	padding-top: 18px;
	border-top: 1px solid var(--border);
	color: var(--muted);
	font-size: 12.5px;
}

/* --- Aviso de vista previa ------------------------------------------------ */

.preview-bar {
	background: color-mix(in srgb, var(--accent) 12%, var(--surface));
	border-bottom: 1px solid color-mix(in srgb, var(--accent) 25%, var(--border));
	color: var(--text-2);
	font-size: 12.5px;
	text-align: center;
	padding: 7px 16px;
}

.preview-bar b { color: var(--text); }

/* --- Copia al portapapeles ------------------------------------------------ */

.toast {
	position: fixed;
	left: 50%;
	bottom: 26px;
	transform: translate(-50%, 16px);
	z-index: 90;
	padding: 9px 16px;
	border-radius: 999px;
	background: var(--text);
	color: var(--bg);
	font-size: 13px;
	font-weight: 600;
	box-shadow: var(--shadow-lg);
	opacity: 0;
	pointer-events: none;
	transition: opacity .18s ease, transform .18s ease;
}

.toast.is-visible { opacity: 1; transform: translate(-50%, 0); }

/* --- Responsive ----------------------------------------------------------- */

@media (max-width: 960px) {
	.result-grid { grid-template-columns: minmax(0, 1fr); }
	.sidebar { position: static; }
	.footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 760px) {
	.site-header .wrap { flex-wrap: wrap; min-height: 56px; padding-block: 8px; }
	.header-search { order: 3; flex-basis: 100%; max-width: none; }
	.nav-toggle { display: grid; }
	.site-nav {
		order: 4;
		flex-basis: 100%;
		flex-wrap: wrap;
		margin-left: 0;
		padding-bottom: 6px;
	}
	.site-nav:not(.is-open) { display: none; }
	.site-nav a.navlink { flex: 1 1 auto; text-align: center; background: var(--surface-2); }
	.features { grid-template-columns: 1fr; }
	.stats { grid-template-columns: 1fr; }
	.hero { padding-block: 40px 30px; }
	.section { padding-block: 36px; }
	.head-actions { margin-left: 0; width: 100%; }
	.head-actions .btn { flex: 1 1 auto; }
	.rec-row { flex-wrap: wrap; gap: 6px 8px; }
	.rec-row .host { max-width: 100%; }
	.ttl { margin-left: 0; }
}

@media (max-width: 480px) {
	.footer-grid { grid-template-columns: 1fr; gap: 20px; }
	.search-panel { padding: 14px; }
	.field-row { flex-direction: column; }
}
