/*
 * El aspecto de la web, el de la app (modelo B, "Opérculo" con los colores de "Ciclo"): los mismos colores, letra y
 * logotipo que kaliptos-angular (styles/redesign.css), con las bandas en tinta del panel de su login.
 */

/* Instrument Sans, de la 400 a la 700, alojada aquí (licencia OFL, de @fontsource/instrument-sans 5.3.0, como en la
   app). Cada peso en dos trozos, latin y latin-ext: una página en inglés sólo descarga el primero */
@font-face {
    font-family: "Instrument Sans";
    src: url("../fonts/InstrumentSans-Regular-latin.woff2") format("woff2");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
    font-family: "Instrument Sans";
    src: url("../fonts/InstrumentSans-Regular-latin-ext.woff2") format("woff2");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
    font-family: "Instrument Sans";
    src: url("../fonts/InstrumentSans-Medium-latin.woff2") format("woff2");
    font-weight: 500;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
    font-family: "Instrument Sans";
    src: url("../fonts/InstrumentSans-Medium-latin-ext.woff2") format("woff2");
    font-weight: 500;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
    font-family: "Instrument Sans";
    src: url("../fonts/InstrumentSans-SemiBold-latin.woff2") format("woff2");
    font-weight: 600;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
    font-family: "Instrument Sans";
    src: url("../fonts/InstrumentSans-SemiBold-latin-ext.woff2") format("woff2");
    font-weight: 600;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
    font-family: "Instrument Sans";
    src: url("../fonts/InstrumentSans-Bold-latin.woff2") format("woff2");
    font-weight: 700;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
    font-family: "Instrument Sans";
    src: url("../fonts/InstrumentSans-Bold-latin-ext.woff2") format("woff2");
    font-weight: 700;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* Los colores de la marca, los mismos que la app (kaliptos-angular, styles/redesign.css): tinta #121A21 para el texto,
   esmeralda de acento sobre el fondo nube #F6F8F7 y las bandas en tinta. El esmeralda de la marca (#0B8A5A) con texto
   blanco no llega al 4,5:1 de AA, así que los botones y los enlaces usan #0B7A50. En oscuro, el acento es el brote
   #3DDC97 con el texto en tinta. El tema es el del sistema, salvo que se elija otro en el pie (data-theme en <html>);
   la web no ve el elegido en la app, que está en otro dominio */
:root {
    color-scheme: light;
    --k-bg: #f6f8f7;
    --k-bg-alt: #ffffff;
    --k-surface: #ffffff;
    --k-text: #121a21;
    --k-muted: #55625c;
    --k-border: #d8e0dc;
    --k-brand: #0b8a5a;
    --k-accent: #0b7a50;
    --k-accent-hover: #0b6e48;
    --k-on-accent: #ffffff;
    --k-soft: #dff6ea;
    --k-soft-text: #0b6e48;
    --k-header-bg: rgba(246, 248, 247, 0.88);
    /* Las bandas en tinta (la portada y el cierre), como el panel del login */
    --k-ink: #121a21;
    --k-ink-surface: #1a242d;
    --k-ink-text: #ffffff;
    --k-ink-muted: #b9c6c0;
    --k-ink-line: #2a3540;
    --k-brote: #3ddc97;
    --k-brote-hover: #8febc2;
}

@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) {
        color-scheme: dark;
        --k-bg: #0b1116;
        --k-bg-alt: #0f171d;
        --k-surface: #121a21;
        --k-text: #e8efeb;
        --k-muted: #9fb0a8;
        --k-border: #24313b;
        --k-brand: #3ddc97;
        --k-accent: #3ddc97;
        --k-accent-hover: #8febc2;
        --k-on-accent: #0b1116;
        --k-soft: #123527;
        --k-soft-text: #8febc2;
        --k-header-bg: rgba(11, 17, 22, 0.88);
        --k-ink: #16261f;
        --k-ink-surface: #1d3128;
        --k-ink-text: #ffffff;
        --k-ink-muted: #9fb0a8;
        --k-ink-line: #24402f;
    }
}

:root[data-theme="dark"] {
    color-scheme: dark;
    --k-bg: #0b1116;
    --k-bg-alt: #0f171d;
    --k-surface: #121a21;
    --k-text: #e8efeb;
    --k-muted: #9fb0a8;
    --k-border: #24313b;
    --k-brand: #3ddc97;
    --k-accent: #3ddc97;
    --k-accent-hover: #8febc2;
    --k-on-accent: #0b1116;
    --k-soft: #123527;
    --k-soft-text: #8febc2;
    --k-header-bg: rgba(11, 17, 22, 0.88);
    --k-ink: #16261f;
    --k-ink-surface: #1d3128;
    --k-ink-text: #ffffff;
    --k-ink-muted: #9fb0a8;
    --k-ink-line: #24402f;
}

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

html {
    scroll-behavior: smooth;
    /* Que la cabecera fija no tape el título de la sección a la que se salta */
    scroll-padding-top: 80px;
}

body {
    margin: 0;
    background: var(--k-bg);
    color: var(--k-text);
    font-family: "Instrument Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    font-size: 16px;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3 {
    margin: 0;
    font-weight: 500;
    letter-spacing: -0.02em;
    line-height: 1.15;
}

p {
    margin: 0;
}

a {
    color: var(--k-accent);
}

a:hover {
    color: var(--k-accent-hover);
}

:focus-visible {
    outline: 2px solid var(--k-accent);
    outline-offset: 3px;
}

.visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

.k-icons {
    display: none;
}

.k-icon {
    width: 24px;
    height: 24px;
    flex: none;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.k-wrap {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.k-skip {
    position: absolute;
    top: -100px;
    left: 16px;
    z-index: 100;
    padding: 10px 16px;
    border-radius: 12px;
    background: var(--k-accent);
    color: var(--k-on-accent);
    font-weight: 700;
}

.k-skip:focus {
    top: 12px;
    color: var(--k-on-accent);
}

/* El logotipo: el símbolo (el fruto con su opérculo) y la palabra, pintados como máscara para que tomen el color que
   toque. La palabra mide 1em de alto y el símbolo 1,42em: el tamaño lo pone el font-size de quien los contiene */
.k-brand {
    display: inline-flex;
    align-items: center;
    flex: none;
    font-size: 24px;
    color: var(--k-text);
    text-decoration: none;
}

.k-brand:hover {
    color: var(--k-text);
}

.k-logo {
    display: inline-block;
    height: 1em;
    aspect-ratio: 166.9 / 39.3;
    background-color: currentColor;
    -webkit-mask: url("../images/kaliptos.svg") center / contain no-repeat;
    mask: url("../images/kaliptos.svg") center / contain no-repeat;
}

.k-mark {
    display: inline-block;
    flex: none;
    width: 1.42em;
    height: 1.42em;
    margin-right: 0.43em;
    background-color: var(--k-brand);
    -webkit-mask: url("../images/kaliptos-mark.svg") center / contain no-repeat;
    mask: url("../images/kaliptos-mark.svg") center / contain no-repeat;
}

/* Botones, como los de la app: esquinas de 12px y en negrita */
.k-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 50px;
    padding: 0 22px;
    border: 1px solid transparent;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 700;
    text-decoration: none;
    white-space: nowrap;
    transition: background-color 0.15s, border-color 0.15s, color 0.15s;
}

.k-btn-sm {
    min-height: 40px;
    padding: 0 16px;
    font-size: 14px;
}

.k-btn-primary {
    background: var(--k-accent);
    color: var(--k-on-accent);
}

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

.k-btn-outline {
    border-color: var(--k-border);
    background: var(--k-surface);
    color: var(--k-text);
}

.k-btn-outline:hover {
    border-color: var(--k-accent);
    background: var(--k-soft);
    color: var(--k-text);
}

/* En las bandas en tinta: el brote con el texto en tinta, y el contorno en blanco */
.k-btn-brote {
    background: var(--k-brote);
    color: #0b1116;
}

.k-btn-brote:hover {
    background: var(--k-brote-hover);
    color: #0b1116;
}

.k-btn-ghost {
    border-color: var(--k-ink-line);
    color: var(--k-ink-text);
}

.k-btn-ghost:hover {
    border-color: var(--k-ink-muted);
    color: var(--k-ink-text);
}

/* La cabecera, fija arriba, translúcida con una línea debajo como la barra de la app */
.k-header {
    position: sticky;
    top: 0;
    z-index: 50;
    border-bottom: 1px solid var(--k-border);
    background: var(--k-header-bg);
    -webkit-backdrop-filter: saturate(1.4) blur(10px);
    backdrop-filter: saturate(1.4) blur(10px);
}

.k-header-row {
    display: flex;
    align-items: center;
    gap: 32px;
    height: 68px;
}

.k-nav {
    display: flex;
    gap: 28px;
    margin-right: auto;
}

.k-nav a,
.k-link-login {
    font-size: 15px;
    font-weight: 500;
    color: var(--k-muted);
    text-decoration: none;
}

.k-nav a:hover,
.k-link-login:hover {
    color: var(--k-text);
}

.k-header-actions {
    display: flex;
    align-items: center;
    gap: 20px;
}

/* El desplegable de las secciones, sólo en pantallas estrechas */
.k-menu {
    display: none;
    position: relative;
}

.k-menu summary {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: 1px solid var(--k-border);
    border-radius: 12px;
    cursor: pointer;
    list-style: none;
}

.k-menu summary::-webkit-details-marker {
    display: none;
}

.k-menu-panel {
    position: absolute;
    right: 0;
    top: 50px;
    display: flex;
    flex-direction: column;
    min-width: 220px;
    padding: 8px;
    border: 1px solid var(--k-border);
    border-radius: 16px;
    background: var(--k-surface);
    box-shadow: 0 12px 32px rgba(18, 26, 33, 0.12);
}

.k-menu-panel a {
    padding: 10px 12px;
    border-radius: 10px;
    color: var(--k-text);
    font-weight: 500;
    text-decoration: none;
}

.k-menu-panel a:hover {
    background: var(--k-soft);
    color: var(--k-soft-text);
}

.k-eyebrow {
    margin-bottom: 14px;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--k-accent);
}

/* La portada, en tinta */
.k-hero {
    background: var(--k-ink);
    color: var(--k-ink-text);
}

.k-hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
    align-items: center;
    gap: 64px;
    padding-top: 96px;
    padding-bottom: 96px;
}

.k-hero .k-eyebrow {
    color: var(--k-brote);
}

.k-hero h1 {
    font-size: 58px;
    line-height: 1.04;
}

.k-hero-lead {
    margin-top: 24px;
    max-width: 540px;
    font-size: 19px;
    color: var(--k-ink-muted);
}

.k-hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 36px;
}

.k-hero-points {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 28px;
    margin: 32px 0 0;
    padding: 0;
    list-style: none;
    font-size: 15px;
    color: var(--k-ink-muted);
}

.k-hero-points li {
    display: flex;
    align-items: center;
    gap: 8px;
}

.k-hero-points .k-icon {
    width: 20px;
    height: 20px;
    color: var(--k-brote);
}

/* El lote de ejemplo: una tarjeta como las de la app, siempre en claro para que destaque sobre la tinta */
.k-preview {
    margin: 0;
    padding: 24px;
    border-radius: 16px;
    background: #ffffff;
    color: #121a21;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
}

.k-preview-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e0e6e3;
}

.k-preview-name {
    font-size: 17px;
    font-weight: 600;
}

.k-preview-meta {
    margin-top: 2px;
    font-size: 13px;
    color: #55625c;
}

.k-tag {
    flex: none;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}

.k-tag-onsale {
    background: #dff6ea;
    color: #0b6e48;
}

.k-preview-table {
    width: 100%;
    margin-top: 8px;
    border-collapse: collapse;
    font-size: 14px;
}

.k-preview-table th {
    padding: 10px 8px;
    font-size: 12px;
    font-weight: 600;
    text-align: left;
    color: #55625c;
}

.k-preview-table td {
    padding: 10px 8px;
    border-top: 1px solid #eef2f0;
    vertical-align: middle;
}

.k-preview-table td b {
    display: block;
    font-weight: 600;
}

.k-preview-table td span:not(.k-twins) {
    display: block;
    font-size: 12px;
    color: #55625c;
}

.k-preview-table .k-num {
    text-align: right;
    white-space: nowrap;
}

.k-twins {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 10px;
    background: #f0f3f2;
    font-size: 12px;
    font-weight: 600;
}

.k-suggested {
    color: #0b7a50;
    font-weight: 700;
}

.k-preview-foot {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 12px;
    padding: 10px 12px;
    border-radius: 12px;
    background: #dff6ea;
    color: #0b6e48;
    font-size: 13px;
    font-weight: 600;
}

.k-preview-foot .k-icon {
    width: 18px;
    height: 18px;
}

/* La franja de los tipos de equipo */
.k-devices {
    border-bottom: 1px solid var(--k-border);
    background: var(--k-bg-alt);
}

.k-devices .k-wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding-top: 28px;
    padding-bottom: 28px;
}

.k-devices p {
    font-size: 14px;
    font-weight: 600;
    color: var(--k-muted);
}

.k-devices ul {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 32px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.k-devices li {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
}

.k-devices .k-icon {
    color: var(--k-accent);
}

/* Las secciones */
.k-section {
    padding: 104px 0;
}

.k-section-alt {
    border-top: 1px solid var(--k-border);
    border-bottom: 1px solid var(--k-border);
    background: var(--k-bg-alt);
}

.k-section-head {
    max-width: 640px;
    margin: 0 auto 56px;
    text-align: center;
}

.k-section-head h2 {
    font-size: 42px;
}

.k-section-head > p:not(.k-eyebrow) {
    margin-top: 16px;
    font-size: 18px;
    color: var(--k-muted);
}

.k-section-head-left {
    margin: 0;
    text-align: left;
}

/* Cuando el texto es una de las dos columnas, el hueco lo pone la cuadrícula */
.k-split > .k-section-head {
    margin-bottom: 0;
}

.k-section-head-left .k-btn {
    margin-top: 32px;
}

/* Cómo funciona: cuatro pasos numerados, con la línea encima como los del login */
.k-steps {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 32px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.k-steps li {
    padding-top: 24px;
    border-top: 2px solid var(--k-border);
}

.k-step-num {
    display: block;
    margin-bottom: 16px;
    font-size: 36px;
    font-weight: 500;
    letter-spacing: -0.02em;
    color: var(--k-accent);
}

.k-steps h3 {
    font-size: 20px;
}

.k-steps p {
    margin-top: 10px;
    color: var(--k-muted);
}

/* Funciones: tarjetas planas con borde fino y esquinas de 16px, como las de la app */
.k-features {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 20px;
}

.k-feature {
    padding: 28px 24px;
    border: 1px solid var(--k-border);
    border-radius: 16px;
    background: var(--k-surface);
}

.k-feature-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    margin-bottom: 20px;
    border-radius: 12px;
    background: var(--k-soft);
    color: var(--k-soft-text);
}

.k-feature h3 {
    font-size: 18px;
    font-weight: 600;
    letter-spacing: -0.01em;
}

.k-feature p {
    margin-top: 10px;
    font-size: 15px;
    color: var(--k-muted);
}

/* Para compradores: el texto a la izquierda y la lista a la derecha */
.k-split {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    align-items: center;
    gap: 64px;
}

.k-checklist {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.k-checklist li {
    display: flex;
    gap: 16px;
    padding: 18px 0;
    border-bottom: 1px solid var(--k-border);
    color: var(--k-muted);
}

.k-checklist li:last-child {
    border-bottom: 0;
}

.k-checklist .k-icon {
    margin-top: 2px;
    color: var(--k-accent);
}

.k-checklist b {
    display: block;
    margin-bottom: 2px;
    font-weight: 600;
    color: var(--k-text);
}

/* Newsletters: el texto con la lista a la izquierda y los resultados de ejemplo a la derecha */
#newsletters .k-section-head-left {
    margin-bottom: 32px;
}

.k-checklist-icons .k-icon {
    margin-top: 0;
    padding: 4px;
    width: 32px;
    height: 32px;
    border-radius: 10px;
    background: var(--k-soft);
    color: var(--k-soft-text);
}

/* Los estados de un correo, como las etiquetas de la app */
:root {
    --k-chip-bg: #eef2f0;
    --k-chip-text: #3d4a44;
    --k-warn-bg: #fdf1dc;
    --k-warn-text: #8a5a00;
    --k-bad-bg: #fde7e7;
    --k-bad-text: #a32a2a;
    --k-results-shadow: 0 18px 48px rgba(18, 26, 33, 0.08);
}

@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) {
        --k-chip-bg: #1d2830;
        --k-chip-text: #c3d0ca;
        --k-warn-bg: #3a2d12;
        --k-warn-text: #f3c56b;
        --k-bad-bg: #3b1d1d;
        --k-bad-text: #f2a3a3;
        --k-results-shadow: none;
    }
}

:root[data-theme="dark"] {
    --k-chip-bg: #1d2830;
    --k-chip-text: #c3d0ca;
    --k-warn-bg: #3a2d12;
    --k-warn-text: #f3c56b;
    --k-bad-bg: #3b1d1d;
    --k-bad-text: #f2a3a3;
    --k-results-shadow: none;
}

.k-chip {
    flex: none;
    padding: 3px 10px;
    border-radius: 12px;
    background: var(--k-chip-bg);
    color: var(--k-chip-text);
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
}

.k-chip-ok {
    background: var(--k-accent);
    color: var(--k-on-accent);
}

.k-chip-soft {
    background: var(--k-soft);
    color: var(--k-soft-text);
}

.k-chip-warn {
    background: var(--k-warn-bg);
    color: var(--k-warn-text);
}

.k-chip-bad {
    background: var(--k-bad-bg);
    color: var(--k-bad-text);
}

/* El correo de ejemplo, como se ve en un buzón: siempre en claro, como el lote de la portada */
.k-mail {
    margin: 0;
    overflow: hidden;
    border: 1px solid var(--k-border);
    border-radius: 16px;
    background: #ffffff;
    color: #121a21;
    box-shadow: var(--k-results-shadow);
}

.k-mail-bar {
    padding: 18px 24px;
    border-bottom: 1px solid #e0e6e3;
    background: #f6f8f7;
    font-size: 13px;
}

.k-mail-bar p:first-child {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 4px 12px;
}

.k-mail-bar span {
    color: #55625c;
}

.k-mail-subject {
    margin-top: 6px;
    font-size: 16px;
    font-weight: 600;
}

.k-mail-body {
    padding: 24px;
    font-size: 14px;
    color: #3d4a44;
}

.k-mail-body > p + p {
    margin-top: 10px;
}

/* El logo del vendedor (de ejemplo), en texto */
.k-mail-logo {
    margin-bottom: 20px;
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 0.12em;
    color: #1f3a5f;
}

.k-mail-logo span {
    margin-left: 4px;
    color: #e2803a;
}

.k-mail-hello {
    color: #121a21;
}

.k-mail-batch {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-top: 14px;
    padding: 14px 16px;
    border: 1px solid #e0e6e3;
    border-radius: 12px;
}

.k-mail-batch div {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.k-mail-batch b {
    color: #121a21;
    font-weight: 600;
}

.k-mail-batch div span {
    font-size: 13px;
    color: #55625c;
}

.k-mail-btn {
    flex: none;
    padding: 8px 14px;
    border-radius: 10px;
    background: #1f3a5f;
    color: #ffffff;
    font-size: 13px;
    font-weight: 700;
}

.k-mail-foot {
    margin-top: 22px !important;
    padding-top: 14px;
    border-top: 1px solid #e0e6e3;
    font-size: 12px;
    color: #55625c;
}

/* Los resultados de un envío: las cifras y los destinatarios, como en la app */
.k-report {
    margin: 0;
    padding: 28px;
    border: 1px solid var(--k-border);
    border-radius: 16px;
    background: var(--k-surface);
    box-shadow: var(--k-results-shadow);
}

.k-report-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
}

.k-report-name {
    font-size: 18px;
    font-weight: 600;
}

.k-report-meta {
    margin-top: 2px;
    font-size: 13px;
    color: var(--k-muted);
}

.k-stats {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    margin-top: 24px;
    border: 1px solid var(--k-border);
    border-radius: 12px;
}

.k-stats div {
    display: flex;
    flex-direction: column;
    padding: 14px 16px;
}

.k-stats div + div {
    border-left: 1px solid var(--k-border);
}

.k-stats span {
    font-size: 13px;
    font-weight: 600;
    color: var(--k-muted);
}

.k-stats b {
    margin-top: 2px;
    font-size: 28px;
    line-height: 1.15;
    font-weight: 500;
    letter-spacing: -0.02em;
}

.k-stats small {
    font-size: 12px;
    color: var(--k-muted);
}

.k-stats .k-stat-bad span {
    color: var(--k-bad-text);
}

.k-table-wrap {
    margin-top: 20px;
    overflow-x: auto;
}

.k-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

.k-table th {
    padding: 10px 12px;
    border-bottom: 1px solid var(--k-border);
    font-size: 12px;
    font-weight: 600;
    text-align: left;
    color: var(--k-muted);
    white-space: nowrap;
}

.k-table td {
    padding: 11px 12px;
    border-bottom: 1px solid var(--k-border);
    white-space: nowrap;
}

.k-table tbody tr:last-child td {
    border-bottom: 0;
}

.k-table .k-col-msg,
.k-table .k-col-date {
    color: var(--k-muted);
}

.k-report-note {
    margin-top: 14px;
    font-size: 13px;
    color: var(--k-muted);
}

/* Lo que trajo: el texto y las tres cifras en una fila */
.k-brought-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
    margin-top: 32px;
}

.k-brought-intro h3 {
    font-size: 22px;
}

.k-brought-intro p {
    margin-top: 6px;
    color: var(--k-muted);
}

.k-brought-kpis {
    display: grid;
    grid-template-columns: repeat(3, minmax(130px, 1fr));
    gap: 12px;
}

.k-brought-kpis div {
    display: flex;
    flex-direction: column;
    padding: 16px 20px;
    border: 1px solid var(--k-border);
    border-radius: 12px;
    background: var(--k-surface);
}

.k-brought-kpis b {
    font-size: 30px;
    font-weight: 500;
    letter-spacing: -0.02em;
}

.k-brought-kpis span {
    font-size: 13px;
    color: var(--k-muted);
}

/* Dashboard: la tarjeta de Sales a la izquierda y el texto a la derecha */
#dashboard .k-section-head-left {
    margin-bottom: 32px;
}

.k-split-reverse > :last-child {
    order: -1;
}

.k-sales {
    margin: 0;
    padding: 28px;
    border: 1px solid var(--k-border);
    border-radius: 16px;
    background: var(--k-surface);
    box-shadow: var(--k-results-shadow);
}

.k-sales-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    font-size: 13px;
    color: var(--k-muted);
}

.k-sales-title {
    font-size: 17px;
    font-weight: 600;
    color: var(--k-text);
}

.k-sales-period {
    margin-top: 10px;
    font-size: 13px;
    color: var(--k-muted);
}

.k-sales-main {
    margin-top: 2px;
    font-size: 14px;
    color: var(--k-muted);
}

.k-sales-main b {
    font-size: 30px;
    font-weight: 500;
    letter-spacing: -0.02em;
    color: var(--k-text);
}

.k-sales-pace {
    margin-top: 2px;
    font-size: 13px;
    color: var(--k-muted);
}

/* Las barras: una por mes, la del mes en curso en el acento y con su importe */
.k-sbars {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    align-items: end;
    gap: 14px;
    height: 220px;
    margin-top: 24px;
}

.k-sbar {
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto;
    justify-items: center;
    gap: 6px;
    height: 100%;
}

.k-sbar-amount {
    min-height: 1.4em;
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
}

.k-sbar-fill {
    align-self: end;
    width: 100%;
    max-width: 56px;
    min-height: 2px;
    border-radius: 6px 6px 0 0;
    background: var(--k-border);
}

.k-sbar-now .k-sbar-fill {
    background: var(--k-accent);
}

.k-sbar-label {
    font-size: 12px;
    color: var(--k-muted);
}

/* Preguntas frecuentes: desplegables sin JavaScript */
.k-faq-wrap {
    max-width: 800px;
}

.k-faq {
    border-top: 1px solid var(--k-border);
}

.k-faq details {
    border-bottom: 1px solid var(--k-border);
}

.k-faq summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 22px 0;
    font-size: 18px;
    font-weight: 500;
    cursor: pointer;
    list-style: none;
}

.k-faq summary::-webkit-details-marker {
    display: none;
}

/* El + que gira y se queda en ×, dibujado con dos rayas */
.k-faq summary::after {
    content: "";
    flex: none;
    width: 14px;
    height: 14px;
    background:
        linear-gradient(var(--k-accent), var(--k-accent)) center / 100% 2px no-repeat,
        linear-gradient(var(--k-accent), var(--k-accent)) center / 2px 100% no-repeat;
    transition: transform 0.2s;
}

.k-faq details[open] summary::after {
    transform: rotate(45deg);
}

.k-faq details p {
    padding: 0 40px 24px 0;
    color: var(--k-muted);
}

/* El cierre, en tinta */
.k-cta {
    background: var(--k-ink);
    color: var(--k-ink-text);
}

.k-cta-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
    padding-top: 72px;
    padding-bottom: 72px;
}

.k-cta h2 {
    font-size: 36px;
}

.k-cta p {
    margin-top: 10px;
    font-size: 18px;
    color: var(--k-ink-muted);
}

.k-cta-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

/* El pie */
.k-footer {
    border-top: 1px solid var(--k-border);
    font-size: 14px;
    color: var(--k-muted);
}

.k-footer-row {
    display: flex;
    align-items: center;
    gap: 24px;
    padding-top: 32px;
    padding-bottom: 32px;
}

.k-footer-brand {
    font-size: 20px;
}

/* Los contactos, separados por un punto y sin partirse cada uno */
.k-footer-contact span {
    white-space: nowrap;
}

.k-footer-contact span + span::before {
    content: "·";
    margin-right: 0.35em;
}

.k-footer-links {
    display: flex;
    gap: 20px;
    margin-left: auto;
}

.k-footer-links a {
    color: var(--k-muted);
    text-decoration: none;
}

.k-footer-links a:hover {
    color: var(--k-text);
}

/* La fila de los textos legales, debajo del pie */
.k-footer-legal {
    padding-top: 16px;
    padding-bottom: 28px;
    border-top: 1px solid var(--k-border);
}

.k-footer-legal nav {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 24px;
    font-size: 13px;
}

.k-footer-legal a {
    color: var(--k-muted);
    text-decoration: none;
}

.k-footer-legal a:hover {
    color: var(--k-text);
}

/* Los textos legales: una columna de lectura */
.k-legal {
    padding: 72px 0 96px;
}

.k-legal .k-wrap {
    max-width: 800px;
}

.k-legal h1 {
    font-size: 44px;
}

.k-legal-updated {
    margin-top: 12px;
    font-size: 14px;
    color: var(--k-muted);
}

.k-legal-draft {
    margin-top: 20px;
    padding: 14px 16px;
    border-radius: 12px;
    background: var(--k-warn-bg);
    color: var(--k-warn-text);
    font-size: 15px;
}

.k-legal-toc {
    margin-top: 32px;
    padding: 20px 24px;
    border: 1px solid var(--k-border);
    border-radius: 16px;
    background: var(--k-surface);
}

.k-legal-toc ol {
    margin: 0;
    padding-left: 20px;
    columns: 2;
    column-gap: 32px;
    font-size: 15px;
}

.k-legal-toc li {
    padding: 3px 0;
    break-inside: avoid;
}

.k-legal section {
    margin-top: 44px;
}

.k-legal h2 {
    font-size: 26px;
}

.k-legal h3 {
    margin-top: 24px;
    font-size: 18px;
    font-weight: 600;
    letter-spacing: -0.01em;
}

.k-legal section p,
.k-legal section ul {
    margin-top: 14px;
    color: var(--k-muted);
}

.k-legal section ul {
    padding-left: 22px;
}

.k-legal section li + li {
    margin-top: 8px;
}

.k-legal b {
    color: var(--k-text);
    font-weight: 600;
}

.k-legal code {
    font-size: 0.9em;
    color: var(--k-text);
}

/* Lo que falta por completar o confirmar, para que el asesor lo vea */
.k-todo {
    padding: 1px 4px;
    border-radius: 4px;
    background: var(--k-warn-bg);
    color: var(--k-warn-text);
}

.k-legal-table-wrap {
    margin-top: 14px;
    overflow-x: auto;
}

.k-legal-table {
    width: 100%;
    margin-top: 14px;
    border-collapse: collapse;
    font-size: 15px;
}

.k-legal-table-wrap .k-legal-table {
    margin-top: 0;
}

.k-legal-table th {
    padding: 10px 12px;
    border-bottom: 1px solid var(--k-border);
    font-size: 13px;
    font-weight: 600;
    text-align: left;
    color: var(--k-muted);
}

.k-legal-table td {
    padding: 12px;
    border-bottom: 1px solid var(--k-border);
    vertical-align: top;
    color: var(--k-muted);
}

.k-legal-table td:first-child {
    color: var(--k-text);
}

@media (max-width: 575.98px) {
    .k-legal {
        padding: 48px 0 64px;
    }

    .k-legal h1 {
        font-size: 34px;
    }

    .k-legal h2 {
        font-size: 22px;
    }

    .k-legal-toc {
        padding: 16px;
    }

    .k-legal-toc ol {
        columns: 1;
    }

    /* Las tablas, como fichas: cada fila en un bloque y el nombre de cada columna encima de su valor */
    .k-legal-table thead {
        display: none;
    }

    .k-legal-table,
    .k-legal-table tbody,
    .k-legal-table tr,
    .k-legal-table td {
        display: block;
    }

    .k-legal-table tr {
        padding: 12px 0;
        border-bottom: 1px solid var(--k-border);
    }

    .k-legal-table td {
        padding: 3px 0;
        border: 0;
        font-size: 14px;
    }

    .k-legal-table td::before {
        content: attr(data-label);
        display: block;
        font-size: 12px;
        font-weight: 600;
        color: var(--k-muted);
    }
}

/* El selector de tema del pie: tres botones juntos, con el elegido relleno, como en el menú de la cuenta de la app */
.k-theme {
    display: inline-flex;
    padding: 3px;
    border: 1px solid var(--k-border);
    border-radius: 12px;
}

.k-theme[hidden] {
    display: none;
}

.k-theme button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 30px;
    padding: 0;
    border: 0;
    border-radius: 9px;
    background: transparent;
    color: var(--k-muted);
    cursor: pointer;
}

.k-theme button:hover {
    color: var(--k-text);
}

.k-theme button[aria-pressed="true"] {
    background: var(--k-soft);
    color: var(--k-soft-text);
}

.k-theme .k-icon {
    width: 18px;
    height: 18px;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .k-btn,
    .k-faq summary::after {
        transition: none;
    }
}

/* Pantallas medianas: las funciones en dos columnas, el menú en el desplegable */
@media (max-width: 1080px) {
    .k-nav {
        display: none;
    }

    .k-header-actions {
        margin-left: auto;
    }

    .k-menu {
        display: block;
    }

    .k-features {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .k-steps {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 40px 32px;
    }

    .k-stats {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .k-stats div:nth-child(5) {
        border-left: 0;
    }

    .k-stats div:nth-child(n + 5) {
        border-top: 1px solid var(--k-border);
    }

    .k-brought-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .k-hero h1 {
        font-size: 48px;
    }
}

/* Tabletas y móviles: todo en una columna */
@media (max-width: 860px) {
    .k-hero-grid,
    .k-split {
        grid-template-columns: minmax(0, 1fr);
        gap: 48px;
    }

    .k-split-reverse > :last-child {
        order: 0;
    }

    .k-hero-grid {
        padding-top: 56px;
        padding-bottom: 64px;
    }

    .k-devices .k-wrap,
    .k-cta-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .k-section {
        padding: 72px 0;
    }

    .k-footer-row {
        flex-wrap: wrap;
    }

    .k-footer-links {
        margin-left: 0;
    }
}

@media (max-width: 575.98px) {
    .k-wrap {
        padding-left: 16px;
        padding-right: 16px;
    }

    .k-header-row {
        gap: 12px;
        height: 60px;
    }

    .k-brand {
        font-size: 20px;
    }

    .k-header-actions {
        gap: 10px;
    }

    .k-link-login {
        display: none;
    }

    .k-hero h1 {
        font-size: 38px;
    }

    .k-hero-lead {
        font-size: 17px;
    }

    .k-hero-actions .k-btn {
        flex: 1 1 100%;
    }

    .k-preview {
        padding: 16px;
    }

    .k-mail-bar,
    .k-mail-body,
    .k-report {
        padding-left: 16px;
        padding-right: 16px;
    }

    .k-mail-batch {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .k-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .k-stats div:nth-child(odd) {
        border-left: 0;
    }

    .k-stats div:nth-child(n + 3) {
        border-top: 1px solid var(--k-border);
    }

    .k-stats div:last-child {
        grid-column: span 2;
    }

    .k-table .k-col-name,
    .k-table .k-col-msg,
    .k-table .k-col-date {
        display: none;
    }

    .k-brought-kpis {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        width: 100%;
    }

    .k-brought-kpis div {
        padding: 12px;
    }

    .k-brought-kpis b {
        font-size: 24px;
    }

    .k-sales {
        padding: 20px 16px;
    }

    .k-sbars {
        gap: 8px;
        height: 180px;
    }

    .k-sales-main b {
        display: block;
    }

    .k-sales-sep {
        display: none;
    }

    /* En el móvil, el lote de ejemplo sin la columna del grado para que quepa */
    .k-preview-table th:nth-child(2),
    .k-preview-table td:nth-child(2) {
        display: none;
    }

    .k-section-head {
        margin-bottom: 40px;
    }

    .k-section-head h2 {
        font-size: 32px;
    }

    .k-section-head > p:not(.k-eyebrow) {
        font-size: 17px;
    }

    .k-features,
    .k-steps {
        grid-template-columns: minmax(0, 1fr);
    }

    .k-cta h2 {
        font-size: 30px;
    }

    .k-cta-actions,
    .k-cta-actions .k-btn {
        width: 100%;
    }

    .k-faq summary {
        font-size: 17px;
    }

    .k-faq details p {
        padding-right: 0;
    }

    /* Los tipos de equipo, en una cuadrícula */
    .k-devices ul {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
        gap: 14px 12px;
        width: 100%;
    }

    /* Los pasos, con el número al lado del título */
    .k-steps {
        gap: 28px;
    }

    .k-steps li {
        display: grid;
        grid-template-columns: 36px minmax(0, 1fr);
        column-gap: 8px;
        padding-top: 20px;
    }

    .k-step-num {
        grid-row: span 2;
        margin: 0;
        font-size: 28px;
        line-height: 1;
    }

    .k-steps p {
        margin-top: 6px;
    }

    /* Las funciones, más compactas: el icono al lado del título */
    .k-features {
        gap: 12px;
    }

    .k-feature {
        display: grid;
        grid-template-columns: 40px minmax(0, 1fr);
        column-gap: 14px;
        align-items: center;
        padding: 18px 16px;
    }

    .k-feature-icon {
        width: 40px;
        height: 40px;
        margin: 0;
    }

    .k-feature p {
        grid-column: 1 / -1;
        margin-top: 10px;
    }

    /* Menos hueco entre el texto y la lista o la tarjeta de cada sección partida */
    .k-split {
        gap: 32px;
    }

    /* El pie, en columna */
    .k-footer-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }

    /* Los contactos, uno por línea */
    .k-footer-contact span {
        display: block;
    }

    .k-footer-contact span + span::before {
        content: none;
    }
}

/* Móviles muy estrechos (320 px): la cabecera, algo más compacta para que quepa */
@media (max-width: 359.98px) {
    .k-header-row {
        gap: 8px;
    }

    .k-header-actions {
        gap: 8px;
    }

    .k-brand {
        font-size: 18px;
    }

    .k-header .k-btn-sm {
        padding: 0 12px;
    }
}
