/* =========================================================================
   Lomito Inversionista - Pagina de plataformas.

   Todo por variables: el sitio cambia solo entre claro y oscuro y un color
   fijo aqui dejaria la pagina en blanco a quien navega de noche.
   ========================================================================= */

.lmt-plat {
	padding: clamp(40px, 7vw, 80px) 0 clamp(56px, 9vw, 96px);
	background: var(--lmt-bg);
	color: var(--lmt-text);
}

/* ------------------------------- cabecera ------------------------------- */
.lmt-plat__head {
	max-width: 680px;
	margin-bottom: 32px;
}

.lmt-plat__title {
	font-family: var(--lmt-font-display);
	font-size: clamp(32px, 5.2vw, 52px);
	line-height: 1.06;
	letter-spacing: -0.02em;
	margin: 8px 0 16px;
}

.lmt-plat__sub {
	font-size: clamp(16px, 2vw, 19px);
	line-height: 1.55;
	color: var(--lmt-text-muted);
	margin: 0;
}

/* --------------------------- aviso de referidos -------------------------- */
.lmt-plat__aviso {
	border: 1px solid var(--lmt-border);
	border-left: 3px solid var(--lmt-accent);
	border-radius: var(--lmt-radius);
	background: var(--lmt-surface);
	padding: 18px 22px;
	margin-bottom: clamp(40px, 6vw, 64px);
}

.lmt-plat__aviso p {
	margin: 0;
	font-size: 15px;
	line-height: 1.6;
	color: var(--lmt-text-muted);
}

.lmt-plat__aviso strong {
	color: var(--lmt-text);
}

/* --------------------------------- grupos -------------------------------- */
.lmt-plat__grupo {
	margin-bottom: clamp(40px, 6vw, 64px);
}

.lmt-plat__grupo-titulo {
	font-family: var(--lmt-font-display);
	font-size: clamp(22px, 3vw, 28px);
	letter-spacing: -0.01em;
	margin: 0 0 6px;
	padding-top: 20px;
	border-top: 1px solid var(--lmt-border);
}

.lmt-plat__grupo-intro {
	margin: 0 0 24px;
	max-width: 620px;
	font-size: 15px;
	line-height: 1.6;
	color: var(--lmt-text-muted);
}

/* -------------------------------- rejilla -------------------------------- */
.lmt-plat__rejilla {
	display: grid;
	gap: 18px;
	grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
}

/* --------------------------------- ficha --------------------------------- */
.lmt-plat__ficha {
	display: flex;
	flex-direction: column;
	border: 1px solid var(--lmt-border);
	border-radius: var(--lmt-radius);
	background: var(--lmt-surface);
	padding: 22px;
	box-shadow: var(--lmt-shadow);
}

.lmt-plat__ficha-head {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 8px;
	margin-bottom: 10px;
}

.lmt-plat__nombre {
	font-family: var(--lmt-font-display);
	font-size: 20px;
	margin: 0;
	letter-spacing: -0.01em;
}

.lmt-plat__sello {
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	padding: 4px 9px;
	border-radius: 999px;
	background: var(--lmt-accent-soft);
	color: var(--lmt-accent);
	white-space: nowrap;
}

.lmt-plat__que {
	margin: 0 0 4px;
	font-size: 15px;
	font-weight: 600;
}

.lmt-plat__quien {
	margin: 0 0 14px;
	font-size: 14px;
	line-height: 1.55;
	color: var(--lmt-text-muted);
}

/* La advertencia tiene que verse dentro de la tarjeta, no al pie de pagina. */
.lmt-plat__ojo {
	margin: 0 0 14px;
	padding: 12px 14px;
	border-radius: 12px;
	background: var(--lmt-surface-2);
	font-size: 13px;
	line-height: 1.55;
	color: var(--lmt-text-muted);
}

.lmt-plat__ojo strong {
	color: var(--lmt-text);
}

.lmt-plat__guia,
.lmt-plat__singuia {
	margin: 0 0 16px;
	font-size: 13.5px;
	line-height: 1.5;
}

.lmt-plat__guia a {
	color: var(--lmt-accent);
	font-weight: 600;
	text-decoration: underline;
	text-underline-offset: 3px;
}

/* Admitir lo que no se ha revisado es parte del contenido, no un error: va en
   tono menor pero legible, nunca escondido. Se uso --lmt-text-muted y no
   --lmt-text-faint porque este ultimo da 3.6:1 sobre la superficie clara y no
   llega al minimo de 4.5:1. Una advertencia que no se lee no advierte nada. */
.lmt-plat__singuia {
	color: var(--lmt-text-muted);
}

/* El boton se pega abajo para que todas las tarjetas se alineen. */
.lmt-plat__ir {
	margin: auto 0 0;
}

.lmt-plat__ir .lmt-btn {
	width: 100%;
	justify-content: center;
}

/* ---------------------------------- pie ---------------------------------- */
.lmt-plat__pie {
	max-width: 720px;
	margin-top: clamp(32px, 5vw, 48px);
	padding-top: 24px;
	border-top: 1px solid var(--lmt-border);
	font-size: 14px;
	line-height: 1.6;
	color: var(--lmt-text-muted);
}

.lmt-plat__pie p {
	margin: 0 0 12px;
}

.lmt-plat__pie strong {
	color: var(--lmt-text);
}

.lmt-plat__pie-links a {
	color: var(--lmt-text);
	text-decoration: underline;
	text-underline-offset: 3px;
}

.lmt-plat__pie-links span {
	margin: 0 8px;
	color: var(--lmt-text-faint);
}

/* --------------------------------- movil --------------------------------- */
@media (max-width: 600px) {
	.lmt-plat__rejilla {
		grid-template-columns: 1fr;
	}

	.lmt-plat__ficha {
		padding: 18px;
	}
}

/* =========================================================================
   Comparador de /plataformas/ (desde la 2.60.0).
   ========================================================================= */
.lmt-comp {
	--lmt-comp-sello: #fde047;
	--lmt-comp-sello-txt: #1f2937;
	--lmt-comp-bajo: #047857;
	--lmt-comp-medio: #b45309;
	--lmt-comp-alto: #b91c1c;
	--lmt-comp-ojo: #92400e;
	margin: 0 0 clamp(40px, 6vw, 72px);
}

html[data-lomito-theme="dark"] .lmt-comp {
	--lmt-comp-bajo: #6ee7b7;
	--lmt-comp-medio: #fbbf24;
	--lmt-comp-alto: #f87171;
	--lmt-comp-ojo: #fcd34d;
}

.lmt-comp__head {
	display: grid;
	grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
	gap: 24px 48px;
	align-items: end;
	margin-bottom: 28px;
}

.lmt-comp__sello {
	display: inline-block;
	margin: 0 0 14px;
	padding: 6px 14px;
	border-radius: 999px;
	background: var(--lmt-comp-sello);
	color: var(--lmt-comp-sello-txt);
	font-size: .75rem;
	font-weight: 800;
	letter-spacing: .05em;
	text-transform: uppercase;
	transform: rotate(-1.5deg);
}

.lmt-comp__titulo {
	margin: 0;
	font-family: var(--lmt-font-display);
	font-size: clamp(2rem, 4.6vw, 3.4rem);
	font-weight: 800;
	line-height: 1.04;
	letter-spacing: -0.03em;
	color: var(--lmt-text);
}

.lmt-comp__sub {
	margin: 0;
	font-size: 1rem;
	line-height: 1.6;
	color: var(--lmt-text-muted);
}

.lmt-comp__filtros {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-bottom: 22px;
}

.lmt-comp__chip {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	padding: 10px 18px;
	border: 1px solid var(--lmt-border);
	border-radius: 999px;
	background: var(--lmt-surface);
	color: var(--lmt-text);
	font: inherit;
	font-weight: 700;
	cursor: pointer;
}

.lmt-comp__chip:hover { border-color: var(--lmt-accent); }

.lmt-comp__chip.is-activo {
	background: var(--lmt-text);
	border-color: var(--lmt-text);
	color: var(--lmt-bg);
}

.lmt-comp__n {
	display: inline-grid;
	place-items: center;
	min-width: 24px;
	height: 24px;
	padding: 0 6px;
	border-radius: 999px;
	background: var(--lmt-surface-2);
	color: var(--lmt-text);
	font-size: .78rem;
}

.lmt-comp__chip.is-activo .lmt-comp__n {
	background: rgba(255, 255, 255, .2);
	color: inherit;
}

html[data-lomito-theme="dark"] .lmt-comp__chip.is-activo .lmt-comp__n { background: rgba(0, 0, 0, .15); }

.lmt-comp__caja {
	overflow: hidden;
	border: 1px solid var(--lmt-border);
	border-radius: var(--lmt-radius-lg, 24px);
	background: var(--lmt-surface);
	box-shadow: var(--lmt-shadow);
}

.lmt-comp__tabla {
	width: 100%;
	border-collapse: collapse;
	font-size: .92rem;
}

.lmt-comp__tabla thead th {
	padding: 16px 14px;
	background: var(--lmt-surface-2);
	color: var(--lmt-text-muted);
	font-size: .72rem;
	font-weight: 800;
	letter-spacing: .06em;
	text-align: left;
	text-transform: uppercase;
	white-space: nowrap;
}

.lmt-comp__tabla tbody tr { border-top: 1px solid var(--lmt-border); }
.lmt-comp__tabla tbody tr[hidden] { display: none; }

.lmt-comp__tabla td,
.lmt-comp__tabla tbody th {
	padding: 18px 14px;
	color: var(--lmt-text);
	text-align: left;
	vertical-align: top;
	font-weight: 400;
}

.lmt-comp__app {
	display: flex;
	gap: 12px;
	min-width: 230px;
}

.lmt-comp__ini {
	flex: 0 0 auto;
	display: grid;
	place-items: center;
	width: 42px;
	height: 42px;
	border-radius: 50%;
	color: #fff;
	font-size: .8rem;
	font-weight: 800;
}

.lmt-comp__nom {
	display: flex;
	flex-direction: column;
	gap: 4px;
	min-width: 0;
}

.lmt-comp__nom strong { font-size: 1rem; font-weight: 800; }

.lmt-comp__para,
.lmt-comp__nota {
	display: block;
	font-size: .8rem;
	line-height: 1.4;
	color: var(--lmt-text-muted);
}

.lmt-comp__ojo {
	font-size: .78rem;
	line-height: 1.4;
	color: var(--lmt-comp-ojo);
}

.lmt-comp__riesgo {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	font-weight: 700;
	white-space: nowrap;
}

.lmt-comp__riesgo::before {
	content: "";
	width: 9px;
	height: 9px;
	border-radius: 50%;
	background: currentColor;
}

.lmt-comp__riesgo--bajo { color: var(--lmt-comp-bajo); }
.lmt-comp__riesgo--medio { color: var(--lmt-comp-medio); }
.lmt-comp__riesgo--alto { color: var(--lmt-comp-alto); }

.lmt-comp__accion { white-space: nowrap; vertical-align: middle !important; }

.lmt-comp__btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 10px 18px;
	border-radius: 999px;
	background: var(--lmt-text);
	color: var(--lmt-bg) !important;
	font-weight: 800;
	font-size: .88rem;
	text-decoration: none !important;
}

.lmt-comp__btn:hover { opacity: .88; }

.lmt-comp__pie {
	margin-top: 16px;
	font-size: .82rem;
	line-height: 1.6;
	color: var(--lmt-text-muted);
}

.lmt-comp__pie p { margin: 0 0 8px; }

.lmt-comp__fuentes summary {
	cursor: pointer;
	font-weight: 700;
	color: var(--lmt-text);
}

.lmt-comp__fuentes ul { margin: 8px 0 0; padding-left: 18px; }

/* La ficha a la que lleva «Ver ficha» no queda tapada por la barra fija. */
.lmt-plat__ficha { scroll-margin-top: 110px; }

/* Tableta: la tabla se desliza de lado dentro de su caja. */
@media (max-width: 1100px) {
	.lmt-comp__caja { overflow-x: auto; }
	.lmt-comp__tabla { min-width: 1000px; }
}

/* Celular: cada plataforma es una tarjeta. */
@media (max-width: 760px) {
	.lmt-comp__head { grid-template-columns: minmax(0, 1fr); }
	.lmt-comp__caja { overflow: visible; border: 0; background: none; box-shadow: none; }
	.lmt-comp__tabla { min-width: 0; }
	.lmt-comp__tabla thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
	.lmt-comp__tabla,
	.lmt-comp__tabla tbody,
	.lmt-comp__tabla tr,
	.lmt-comp__tabla td,
	.lmt-comp__tabla tbody th { display: block; width: auto; }
	.lmt-comp__tabla tbody tr {
		margin-bottom: 14px;
		padding: 16px;
		border: 1px solid var(--lmt-border);
		border-radius: var(--lmt-radius, 16px);
		background: var(--lmt-surface);
	}
	.lmt-comp__tabla tbody tr[hidden] { display: none; }
	.lmt-comp__tabla td,
	.lmt-comp__tabla tbody th { padding: 6px 0; }
	.lmt-comp__app { min-width: 0; padding-bottom: 10px !important; }
	.lmt-comp__tabla td[data-col] {
		display: grid;
		grid-template-columns: 40% minmax(0, 1fr);
		gap: 10px;
	}
	.lmt-comp__tabla td[data-col]::before {
		content: attr(data-col);
		color: var(--lmt-text-muted);
		font-size: .75rem;
		font-weight: 700;
	}
	.lmt-comp__accion { padding-top: 12px !important; }
	.lmt-comp__btn { width: 100%; box-sizing: border-box; }
}

/* La pagina vive dentro del ancho de contenido del tema (700 px): el
   comparador se sale a lo ancho, centrado, hasta 1240 px. */
.lmt-comp {
	position: relative;
	left: 50%;
	width: min(1240px, calc(100vw - 32px));
	transform: translateX(-50%);
}

.lmt-comp__caja { overflow-x: auto; }

@media (max-width: 760px) {
	.lmt-comp { left: auto; width: auto; transform: none; }
	.lmt-comp__caja { overflow: visible; }
}

/* Los textos ocultos para lectores de pantalla (position:absolute) se anclaban a .lmt-comp y escapaban del recorte de la caja: en tableta la página se desbordaba. */
.lmt-comp__caja { position: relative; }
