/* Componentes comunes de las páginas de políticas (documento legal con índice y anclas).
 * Se carga en las páginas de la lista paginas_politicas (inc/config.php):
 * /politicas-de-uso-de-hosting/ y /politicas-servicio-diseno-web/. */

/* Anclas: el título no queda bajo la cabecera fija; desplazamiento suave solo si el usuario no pide menos movimiento */
.tc-pol-doc [id] { scroll-margin-top: 110px; }
@media (prefers-reduced-motion: no-preference) {
	html { scroll-behavior: smooth; }
}

/* Valor destacado en las tarjetas */
:is(.entry-content, .is-root-container) .tc-pol-valor { margin: 0 0 6px; font-family: 'Lexend', sans-serif; font-size: 20px; font-weight: 600; color: var(--dw-fg); }

/* 1 columna en pantallas muy angostas */
@media (max-width: 400px) {
	.tc-dw-selgrid.tc-pol-cards { grid-template-columns: minmax(0, 1fr); }
}

/* Documento */
.tc-pol-doc :is(.tc-pol-indice, .tc-pol-cap) { max-width: 860px; margin-inline: auto !important; box-sizing: border-box; }
.tc-pol-indice { padding: 26px 30px; background: #F4F6F8; border: 1px solid #E2E7ED; border-radius: 16px; }
:is(.entry-content, .is-root-container) .tc-pol-indice-title { margin: 0 0 14px; font-size: 20px; font-weight: 500; color: var(--tc-c-navy); }
:is(.entry-content, .is-root-container) .tc-pol-indice-lista { columns: 2; column-gap: 32px; margin: 0; padding-left: 0; list-style: none; }
:is(.entry-content, .is-root-container) .tc-pol-indice-lista li { break-inside: avoid; margin: 0 0 8px; font-size: 15px; line-height: 1.45; }
:is(.entry-content, .is-root-container) .tc-pol-indice-lista a { color: var(--tc-c-navy); text-decoration: none; }
:is(.entry-content, .is-root-container) .tc-pol-indice-lista a:hover { color: var(--tc-acento); text-decoration: underline; }

:is(.entry-content, .is-root-container) .tc-dsec .tc-pol-cap { margin-top: 40px !important; }
:is(.entry-content, .is-root-container) .tc-pol-h2 { margin: 0 0 14px; padding-bottom: 10px; border-bottom: 2px solid #E6EAF0; font-size: 22px; font-weight: 500; line-height: 1.35; color: var(--tc-c-navy); }
:is(.entry-content, .is-root-container) .tc-pol-cap h3 { margin: 22px 0 10px; font-size: 18px; font-weight: 500; line-height: 1.4; color: var(--tc-c-navy); }
:is(.entry-content, .is-root-container) .tc-pol-cap p, :is(.entry-content, .is-root-container) .tc-pol-cap li { font-size: 15.5px; line-height: 1.7; color: var(--tc-c-texto); }
:is(.entry-content, .is-root-container) .tc-pol-cap p { margin: 0 0 12px; }
:is(.entry-content, .is-root-container) .tc-pol-cap ul { margin: 0 0 14px; padding-left: 22px; }
:is(.entry-content, .is-root-container) .tc-pol-cap li { margin: 0 0 4px; }
:is(.entry-content, .is-root-container) .tc-pol-cap strong { color: var(--tc-c-navy); }
:is(.entry-content, .is-root-container) .tc-pol-cap a { color: var(--tc-acento); word-break: break-word; }

/* Capítulo destacado (SPAM) */
.tc-pol-cap--destacado { padding: 24px 26px; background: #FCE9E9; border: 1px solid #F3C9C9; border-radius: 16px; }

/* Advertencia (pérdida de correos) */
.tc-pol-aviso { position: relative; margin: 14px 0 16px; padding: 18px 20px 18px 62px; background: #FFF6E5; border: 1px solid #F1D49B; border-radius: 12px; }
.tc-pol-aviso::before { content: ""; position: absolute; left: 20px; top: 18px; width: 26px; height: 26px; background: #8A5A00; -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M10.3 3.9 1.8 18a2 2 0 0 0 1.7 3h17a2 2 0 0 0 1.7-3L13.7 3.9a2 2 0 0 0-3.4 0z'/%3E%3Cpath d='M12 9v4M12 17h.01'/%3E%3C/svg%3E") center / contain no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M10.3 3.9 1.8 18a2 2 0 0 0 1.7 3h17a2 2 0 0 0 1.7-3L13.7 3.9a2 2 0 0 0-3.4 0z'/%3E%3Cpath d='M12 9v4M12 17h.01'/%3E%3C/svg%3E") center / contain no-repeat; }
:is(.entry-content, .is-root-container) .tc-pol-cap .tc-pol-aviso-text { margin: 0; color: #5C3D00; }

/* Volver al índice */
:is(.entry-content, .is-root-container) .tc-pol-cap .tc-pol-volver { margin: 8px 0 0; text-align: right; font-size: 13.5px; }
:is(.entry-content, .is-root-container) .tc-pol-volver a { color: #6B7684; text-decoration: none; }
:is(.entry-content, .is-root-container) .tc-pol-volver a:hover { color: var(--tc-acento); }

/* Tabla de valores */
.tc-pol-tabla-wrap { max-width: 860px; margin: 0 auto; }
:is(.entry-content, .is-root-container) .tc-pol-tabla { margin: 0; overflow: hidden; background: #ffffff; border: 1px solid #DDE3EA; border-radius: 14px; }
.tc-pol-tabla table { width: 100%; border-collapse: collapse; font-size: 15px; }
.tc-pol-tabla th, .tc-pol-tabla td { padding: 13px 18px; border: 0; border-top: 1px solid #E6EAF0; text-align: left; color: var(--tc-c-texto); }
.tc-pol-tabla thead th { border-top: 0; background: #0F2830; font-weight: 600; color: #ffffff; }
.tc-pol-tabla th:last-child, .tc-pol-tabla td:last-child { text-align: right; white-space: nowrap; font-weight: 600; color: var(--tc-c-navy); }
.tc-pol-tabla thead th:last-child { color: #ffffff; }
:is(.entry-content, .is-root-container) .tc-pol-nota { margin: 12px 0 0; font-size: 14px; line-height: 1.6; color: #6B7684; }

/* Cierre: botón borde sobre fondo oscuro */
:is(.entry-content, .is-root-container) .tc-pol-arriba a::after { display: none; }
:is(.entry-content, .is-root-container) .tc-ctas .tc-pol-arriba a { min-height: 50px; padding: 0 24px; border-radius: 12px; font-size: 16px; }

@media (max-width: 767px) {
	:is(.entry-content, .is-root-container) .tc-pol-indice-lista { columns: 1; }
	.tc-pol-indice { padding: 20px 18px; }
	.tc-pol-cap--destacado { padding: 18px 16px; }
	:is(.entry-content, .is-root-container) .tc-pol-h2 { font-size: 19px; }
	.tc-pol-tabla th, .tc-pol-tabla td { padding: 11px 12px; font-size: 14px; }
	.tc-pol-tabla th:last-child, .tc-pol-tabla td:last-child { white-space: normal; }
}
.tc-dw-hero .tc-kicker { justify-content: center; }

/* ── Políticas del servicio de diseño web ─────────────────────────── */

/* 13 tarjetas: 3 columnas en computador y 2 en tablet, con la última centrada */
@media (min-width: 1101px) {
	.tc-dw-selgrid.tc-pol-cards--impar { grid-template-columns: repeat(6, minmax(0, 1fr)); }
	.tc-pol-cards--impar .tc-dw-sel { grid-column: span 2; }
	.tc-pol-cards--impar .tc-dw-sel:last-child { grid-column: 3 / span 2; }
}
@media (min-width: 768px) and (max-width: 1100px) {
	.tc-dw-selgrid.tc-pol-cards--impar { grid-template-columns: repeat(4, minmax(0, 1fr)); }
	.tc-pol-cards--impar .tc-dw-sel { grid-column: span 2; }
	.tc-pol-cards--impar .tc-dw-sel:last-child { grid-column: 2 / span 2; }
}

/* Tres modalidades de desarrollo: tarjetas pastel más anchas que el texto del documento */
.tc-pol-mods { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; width: min(1180px, calc(100vw - 80px)); margin: 22px 0 26px; position: relative; left: 50%; transform: translateX(-50%); }
.tc-pol-mod { padding: 74px 22px 20px; text-align: left; }
.tc-pol-mods .tc-pol-mod > .wp-block-group__inner-container { flex: 1; width: 100%; max-width: none; margin: 0 !important; padding: 0 !important; }
.tc-pol-mod:hover { transform: none; border-color: transparent; }
:is(.entry-content, .is-root-container) .tc-pol-mod .tc-pol-mod-n { margin: 0 0 4px; text-align: center; font-size: 12.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--dw-fg); }
:is(.entry-content, .is-root-container) .tc-pol-mod .tc-dw-sel-title { margin: 0 0 14px; white-space: normal; text-align: center; font-size: 18px; }
:is(.entry-content, .is-root-container) .tc-pol-cap .tc-pol-mod p, :is(.entry-content, .is-root-container) .tc-pol-cap .tc-pol-mod li { font-size: 14.5px; line-height: 1.6; color: #34404C; }
:is(.entry-content, .is-root-container) .tc-pol-cap .tc-pol-mod ul { padding-left: 18px; }
@media (min-width: 768px) and (max-width: 1100px) {
	.tc-pol-mods { grid-template-columns: minmax(0, 1fr); width: auto; left: 0; transform: none; }
}
@media (max-width: 767px) {
	.tc-pol-mods { width: auto; left: 0; transform: none; }
	.tc-pol-mods.tc-carrusel { display: flex; gap: 14px; margin: 10px -24px 4px; align-items: stretch; }
	.tc-carrusel > .wp-block-group__inner-container > .tc-pol-mod, .tc-carrusel .tc-pol-mod { padding: 70px 18px 18px; text-align: left; }
}
@media (max-width: 380px) {
	.tc-pol-mods.tc-carrusel { margin-inline: -16px; }
}

/* Recuadros destacados con ícono: ver .tc-pol-recuadro en components/diseno-comun.css */
:is(.entry-content, .is-root-container) .tc-pol-cap .tc-pol-recuadro h3 { margin-top: 6px; }

/* Botones con borde rojo dentro del documento */
:is(.entry-content, .is-root-container) .tc-pol-cap .tc-pol-btn { margin: 4px 0 18px; }
:is(.entry-content, .is-root-container) .tc-pol-cap .tc-pol-btn a { color: var(--tc-acento); word-break: normal; text-align: center; }

/* Tablas dentro de los capítulos */
:is(.entry-content, .is-root-container) .tc-pol-cap .tc-pol-tabla { margin: 6px 0 18px; }
/* Tablas de texto: todas las columnas a la izquierda */
.tc-pol-tabla--cols th:last-child, .tc-pol-tabla--cols td:last-child { text-align: left; white-space: normal; font-weight: 400; color: var(--tc-c-texto); }
.tc-pol-tabla--cols thead th:last-child { font-weight: 600; color: #ffffff; }
.tc-pol-tabla--cols td:first-child { font-weight: 600; color: var(--tc-c-navy); }
/* Tablas de valores con varias columnas numéricas */
.tc-pol-tabla--num th:not(:first-child), .tc-pol-tabla--num td:not(:first-child) { text-align: right; white-space: nowrap; }
.tc-pol-tabla--num td:not(:first-child) { font-weight: 600; color: var(--tc-c-navy); }
.tc-pol-tabla--num td:nth-child(3) { font-weight: 400; color: var(--tc-c-texto); }
.tc-pol-tabla-wrap--ancha { max-width: 980px; }
/* Tablas anchas: desplazamiento horizontal propio, la página nunca se desborda */
:is(.entry-content, .is-root-container) .tc-pol-tabla--scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
@media (max-width: 767px) {
	.tc-pol-tabla--scroll table { min-width: 620px; }
	.tc-pol-tabla--num th:not(:first-child), .tc-pol-tabla--num td:not(:first-child) { white-space: nowrap; }
}

/* Cierre: datos de contacto con enlaces legibles sobre fondo oscuro */
:is(.entry-content, .is-root-container) .tc-cierre .tc-pol-contacto a { color: #ffffff; text-decoration: underline; text-underline-offset: 3px; }
