/*
 * Quiosco de los MUPIs (1080 × 1920, vertical).
 *
 * Identidad de Cool Farming University (manual de marca): naranja Pantone
 * 166C #EA5A0B, gris Cool Grey 5C #B1B3B3 y Montserrat como tipografía
 * corporativa (Nexa solo va dentro del logo). Calcula tu huella sigue el
 * mismo estilo con el verde de su logo (#00B23C).
 *
 * Fuentes en WOFF (el formato 1, no WOFF2) y, detrás, en TTF: el navegador
 * de Android 5.1 trae un WOFF2 de antes de que el formato se cerrara, no
 * sabe leer los de hoy y tampoco pasaba a la alternativa; pintaba la fuente
 * del sistema. WOFF lo entiende cualquier navegador.
 *
 * Compatible con Chromium 39 (Android 5.1, medido en el emulador): flexbox
 * sin `gap`, nada de grid, variables CSS, clamp() ni aspect-ratio. Por eso el
 * color de cada sitio no es una variable: la base va en naranja y el bloque
 * del final lo sustituye en `.sitio-huella`, regla a regla.
 */

@font-face {
    font-family: "Montserrat";
    font-weight: 500;
    font-style: normal;
    src: url("../fonts/Montserrat-Medium.woff") format("woff"),
         url("../fonts/Montserrat-Medium.ttf") format("truetype");
}

@font-face {
    font-family: "Montserrat";
    font-weight: 600;
    font-style: normal;
    src: url("../fonts/Montserrat-SemiBold.woff") format("woff"),
         url("../fonts/Montserrat-SemiBold.ttf") format("truetype");
}

@font-face {
    font-family: "Montserrat";
    font-weight: 700;
    font-style: normal;
    src: url("../fonts/Montserrat-Bold.woff") format("woff"),
         url("../fonts/Montserrat-Bold.ttf") format("truetype");
}

@font-face {
    font-family: "Montserrat";
    font-weight: 800;
    font-style: normal;
    src: url("../fonts/Montserrat-ExtraBold.woff") format("woff"),
         url("../fonts/Montserrat-ExtraBold.ttf") format("truetype");
}

* {
    -webkit-box-sizing: border-box;
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
}

/* Blanco también fuera de la página: en el navegador de Android 5.1 el
   alto que da el JS se queda algo corto y asomaba una franja abajo. */
body {
    background: #fff;
    color: #2b2b2a;
    font-family: "Montserrat", Arial, sans-serif;
    font-size: 34px;
    font-weight: 500;
    line-height: 1.4;
    -webkit-text-size-adjust: 100%;
    /* Quiosco: sin selección de texto, sin resaltado al tocar, sin zoom. */
    -webkit-user-select: none;
    user-select: none;
    -webkit-touch-callout: none;
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
    touch-action: manipulation;
}

input {
    -webkit-user-select: text;
    user-select: text;
}

button {
    font-family: inherit;
}

.oculto {
    display: none !important;
}

.sin-js {
    padding: 80px;
    text-align: center;
}

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

.app {
    display: -webkit-flex;
    display: flex;
    -webkit-flex-direction: column;
    flex-direction: column;
    max-width: 1080px;
    min-height: 100vh;
    margin: 0 auto;
    padding: 64px 90px 56px;
    border-top: 16px solid #ea5a0b;
    background: #fff;
}

.cabecera {
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
    -webkit-justify-content: space-between;
    justify-content: space-between;
    margin-bottom: 48px;
}

.logo {
    display: block;
    height: 88px;
    width: auto;
}

.logo--grande {
    height: auto;
    width: 620px;
    margin: 0 auto 72px;
}

.sitio-huella .logo--grande {
    width: 560px;
}

.titulo {
    margin: 0 0 40px;
    font-size: 74px;
    font-weight: 800;
    line-height: 1.1;
}

.subtitulo {
    margin: 0 0 16px;
    color: #6b6b69;
    font-size: 40px;
    font-weight: 700;
}

.texto p,
.final-texto p {
    margin: 0 0 26px;
}

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

.boton {
    display: inline-block;
    min-height: 112px;
    padding: 24px 64px;
    border: 4px solid #b1b3b3;
    border-radius: 999px;
    background: #fff;
    color: #2b2b2a;
    font-size: 34px;
    font-weight: 700;
    cursor: pointer;
}

.boton--principal {
    border-color: #ea5a0b;
    background: #ea5a0b;
    color: #fff;
    box-shadow: 0 8px 0 #b94608;
}

.boton--pequeno {
    min-height: 84px;
    padding: 14px 44px;
    font-size: 28px;
}

.boton--grande {
    display: block;
    width: 100%;
    min-height: 156px;
    font-size: 44px;
    font-weight: 800;
    letter-spacing: 0.02em;
}

.boton:active {
    -webkit-transform: translateY(4px);
    transform: translateY(4px);
}

.boton--principal:active {
    box-shadow: 0 4px 0 #b94608;
}

.boton[disabled] {
    opacity: 0.6;
}

/* ------------------------------------------------------------------ */
/* Inicio                                                               */
/* ------------------------------------------------------------------ */

.idiomas {
    display: -webkit-flex;
    display: flex;
    -webkit-justify-content: flex-end;
    justify-content: flex-end;
}

.idioma {
    min-width: 220px;
    min-height: 92px;
    margin-left: 24px;
    border: 4px solid #b1b3b3;
    border-radius: 999px;
    background: #fff;
    color: #2b2b2a;
    font-size: 30px;
    font-weight: 700;
}

.idioma.activo {
    border-color: #ea5a0b;
    background: #ea5a0b;
    color: #fff;
}

/* Centrado con márgenes automáticos y no con justify-content: si la
   pantalla es más baja que el contenido, el bloque crece hacia abajo en vez
   de montarse sobre los botones de idioma. */
.inicio-cuerpo {
    display: -webkit-flex;
    display: flex;
    -webkit-flex-direction: column;
    flex-direction: column;
    -webkit-flex: 1;
    flex: 1;
    text-align: center;
}

.inicio-cuerpo > :first-child {
    margin-top: auto;
}

.inicio-cuerpo > :last-child {
    margin-bottom: auto;
}

.inicio-cuerpo .texto {
    margin-bottom: 72px;
    color: #4a4a48;
    font-size: 36px;
    line-height: 1.45;
}

/* ------------------------------------------------------------------ */
/* Preguntas                                                            */
/* ------------------------------------------------------------------ */

.progreso-texto {
    color: #ea5a0b;
    font-size: 30px;
    font-weight: 800;
    white-space: nowrap;
}

.progreso-barra {
    display: block;
    height: 16px;
    margin-bottom: 72px;
    border-radius: 8px;
    background: #ececea;
    overflow: hidden;
}

.progreso-barra span {
    display: block;
    height: 100%;
    border-radius: 8px;
    background: #ea5a0b;
}

.pregunta {
    margin: 0 0 56px;
    font-size: 56px;
    font-weight: 800;
    line-height: 1.2;
}

.opciones {
    -webkit-flex: 1;
    flex: 1;
}

.opcion {
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
    width: 100%;
    min-height: 136px;
    margin: 0 0 26px;
    padding: 26px 36px;
    border: 4px solid #dcdddd;
    border-radius: 28px;
    background: #fff;
    color: #2b2b2a;
    font-size: 36px;
    font-weight: 600;
    line-height: 1.3;
    text-align: left;
    cursor: pointer;
}

.opcion:active {
    border-color: #b1b3b3;
}

.opcion.elegida {
    border-color: #ea5a0b;
    background: #ea5a0b;
    color: #fff;
}

.letra {
    -webkit-flex: none;
    flex: none;
    width: 80px;
    height: 80px;
    margin-right: 32px;
    border-radius: 50%;
    background: #fdeee6;
    color: #ea5a0b;
    font-weight: 800;
    line-height: 80px;
    text-align: center;
}

.opcion.elegida .letra {
    background: #fff;
}

.opcion-texto {
    -webkit-flex: 1;
    flex: 1;
}

.navegacion {
    margin-top: 48px;
}

/* ------------------------------------------------------------------ */
/* Final y formulario                                                   */
/* ------------------------------------------------------------------ */

/* La pantalla del email tiene que caber entera en 1920 px, con margen
   para las barras de Android si el aparato las enseña: título en una
   línea, texto más apretado y "Anterior" en la cabecera. */
.pantalla-final .cabecera {
    margin-bottom: 40px;
}

.pantalla-final .titulo {
    margin-bottom: 28px;
    font-size: 46px;
    letter-spacing: -0.01em;
    white-space: nowrap;
}

.pantalla-final .final-texto {
    color: #4a4a48;
    font-size: 28px;
    line-height: 1.35;
}

.pantalla-final .final-texto p {
    margin-bottom: 16px;
}

.pantalla-final .campo {
    height: 112px;
    margin-bottom: 28px;
}

.pantalla-final .casilla {
    margin-bottom: 20px;
}

.pantalla-final .boton--grande {
    min-height: 136px;
    margin-top: 12px;
}

.pantalla-final /* Sin mensaje, sin hueco: cada píxel de esta pantalla cuenta. */
.error:empty {
    display: none;
}

.primera-capa {
    margin-top: 24px;
    font-size: 20px;
}

.pantalla-final .pie {
    margin-top: 24px;
}

/* Con el teclado en pantalla abierto se recoge el texto de arriba. */
.escribiendo .final-texto p {
    display: none;
}

.escribiendo .final-texto .titulo {
    margin-bottom: 32px;
    font-size: 52px;
}

.formulario {
    margin-top: 16px;
}

.etiqueta {
    display: block;
    margin-bottom: 14px;
    font-weight: 700;
}

.campo {
    display: block;
    width: 100%;
    height: 124px;
    margin-bottom: 36px;
    padding: 0 36px;
    border: 4px solid #b1b3b3;
    border-radius: 24px;
    background: #fff;
    color: #2b2b2a;
    font-family: inherit;
    font-size: 40px;
    font-weight: 600;
    outline: none;
}

.campo:focus {
    border-color: #ea5a0b;
}

/* Casilla propia: la nativa no se deja agrandar ni colorear en
   Chromium 39. El input sigue ahí (es el que lee el JS), solo que no se ve. */
.casilla {
    position: relative;
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: flex-start;
    align-items: flex-start;
    margin-bottom: 28px;
    font-size: 28px;
}

.casilla input {
    position: absolute;
    top: 0;
    left: 0;
    width: 1px;
    height: 1px;
    margin: 0;
    opacity: 0;
}

.marca {
    position: relative;
    -webkit-flex: none;
    flex: none;
    width: 60px;
    height: 60px;
    margin-right: 26px;
    border: 4px solid #b1b3b3;
    border-radius: 16px;
    background: #fff;
}

.casilla input:checked + .marca {
    border-color: #ea5a0b;
    background: #ea5a0b;
}

.casilla input:checked + .marca:after {
    content: "";
    position: absolute;
    top: 6px;
    left: 17px;
    width: 14px;
    height: 28px;
    border: solid #fff;
    border-width: 0 7px 7px 0;
    -webkit-transform: rotate(45deg);
    transform: rotate(45deg);
}

.casilla-texto {
    -webkit-flex: 1;
    flex: 1;
    padding-top: 10px;
}

.enlace-legal {
    color: inherit;
    font-weight: 700;
    text-decoration: underline;
}

.error {
    margin: 0 0 20px;
    color: #c62828;
    font-weight: 700;
}

.primera-capa {
    margin: 32px 0 0;
    color: #6b6b69;
    font-size: 22px;
    line-height: 1.45;
}

.pie {
    margin: 40px 0 0;
    font-weight: 800;
}

.pie-legal {
    margin-top: 48px;
    color: #8a8b8b;
    font-size: 24px;
    text-align: center;
}

/* ------------------------------------------------------------------ */
/* Gracias y resultado (offline)                                        */
/* ------------------------------------------------------------------ */

.gracias {
    display: -webkit-flex;
    display: flex;
    -webkit-flex-direction: column;
    flex-direction: column;
    -webkit-flex: 1;
    flex: 1;
    text-align: center;
}

.gracias > :first-child {
    margin-top: auto;
}

.gracias > :last-child {
    margin-bottom: auto;
}

.gracias p {
    margin: 0 0 48px;
    color: #4a4a48;
}

.gracias strong {
    color: #2b2b2a;
    word-break: break-all;
}

.gracias-icono {
    position: relative;
    display: block;
    width: 180px;
    height: 180px;
    margin: 0 auto 48px;
    border-radius: 50%;
    background: #ea5a0b;
}

.gracias-icono:after {
    content: "";
    position: absolute;
    top: 38px;
    left: 64px;
    width: 40px;
    height: 80px;
    border: solid #fff;
    border-width: 0 16px 16px 0;
    -webkit-transform: rotate(45deg);
    transform: rotate(45deg);
}

.gracias .boton {
    -webkit-align-self: center;
    align-self: center;
}

.cifra {
    margin: 0 0 40px;
    color: #ea5a0b;
    font-size: 66px;
    font-weight: 800;
    line-height: 1.15;
}

.desglose {
    width: 100%;
    margin-bottom: 32px;
    border-collapse: collapse;
}

.desglose th,
.desglose td {
    padding: 18px 0;
    border-bottom: 3px solid #ececea;
    text-align: left;
}

.desglose th {
    font-weight: 700;
}

.desglose td {
    font-weight: 800;
    text-align: right;
    white-space: nowrap;
}

.cec {
    color: #4a4a48;
}

.correcciones {
    margin: 0 0 40px;
    padding-left: 48px;
    font-size: 27px;
}

.correcciones li {
    margin-bottom: 20px;
}

.correccion-pregunta,
.correccion-respuesta {
    display: block;
}

.correccion-respuesta {
    font-weight: 700;
}

.correcciones .fallo .correccion-respuesta {
    color: #c62828;
}

.qr-bloque {
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
    margin-top: 16px;
}

.qr {
    -webkit-flex: none;
    flex: none;
    margin-right: 48px;
    padding: 16px;
    border: 4px solid #ececea;
    border-radius: 24px;
    background: #fff;
}

.qr img {
    display: block;
    width: 340px;
    height: 340px;
}

.qr-texto p {
    margin: 0 0 20px;
}

.aviso-envio {
    margin: -16px 0 32px;
    color: #4a4a48;
    font-size: 28px;
}

.aviso-envio strong {
    color: #2b2b2a;
    word-break: break-all;
}

/* Pantalla del personal (…#personal): solo castellano, sin diseño. */
.pantalla-personal .titulo {
    font-size: 56px;
}

.datos-personal {
    margin: 32px 0 0;
    padding: 24px;
    border-radius: 16px;
    background: #f5f5f3;
    font-size: 20px;
    line-height: 1.5;
    white-space: pre-wrap;
    word-break: break-all;
    -webkit-user-select: text;
    user-select: text;
}

/* ------------------------------------------------------------------ */
/* Capas: legales y aviso de inactividad                                */
/* ------------------------------------------------------------------ */

.capa {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 10;
    display: -webkit-flex;
    display: flex;
    -webkit-flex-direction: column;
    flex-direction: column;
    max-width: 1080px;
    margin: 0 auto;
    background: #fff;
}

.capa-cabecera {
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
    -webkit-justify-content: space-between;
    justify-content: space-between;
    padding: 40px 90px;
    border-top: 16px solid #ea5a0b;
    border-bottom: 3px solid #ececea;
}

.capa-titulo {
    margin: 0 32px 0 0;
    font-size: 44px;
    font-weight: 800;
}

.capa-contenido {
    -webkit-flex: 1;
    flex: 1;
    padding: 40px 90px 120px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    color: #4a4a48;
    font-size: 28px;
}

.legal-texto h2 {
    color: #2b2b2a;
    font-size: 38px;
    font-weight: 800;
}

/* Los legales vienen del editor del admin y pueden traer tablas (la de
   cookies) o imágenes más anchas que la capa. */
.legal-texto table {
    width: 100%;
    margin: 24px 0;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 20px;
    line-height: 1.35;
}

.legal-texto th,
.legal-texto td {
    padding: 10px 8px;
    border-bottom: 2px solid #ececea;
    text-align: left;
    vertical-align: top;
    word-wrap: break-word;
}

.legal-texto img {
    max-width: 100%;
    height: auto;
}

.legal-texto h3 {
    color: #2b2b2a;
    font-size: 32px;
    font-weight: 700;
}

.aviso {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 20;
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
    -webkit-justify-content: center;
    justify-content: center;
    background: rgba(43, 43, 42, 0.7);
}

.aviso-caja {
    width: 820px;
    padding: 72px;
    border-radius: 40px;
    background: #fff;
    text-align: center;
}

.aviso-caja h2 {
    margin: 0 0 24px;
    font-size: 60px;
    font-weight: 800;
}

.aviso-caja p {
    margin: 0 0 48px;
    color: #4a4a48;
}

/* ------------------------------------------------------------------ */
/* Calcula tu huella: el verde de su logo en lugar del naranja          */
/* ------------------------------------------------------------------ */

.sitio-huella .app,
.sitio-huella .capa-cabecera {
    border-top-color: #00b23c;
}

.sitio-huella .boton--principal,
.sitio-huella .idioma.activo,
.sitio-huella .opcion.elegida,
.sitio-huella .casilla input:checked + .marca {
    border-color: #00b23c;
    background: #00b23c;
}

.sitio-huella .boton--principal {
    box-shadow: 0 8px 0 #008a2e;
}

.sitio-huella .boton--principal:active {
    box-shadow: 0 4px 0 #008a2e;
}

.sitio-huella .progreso-texto,
.sitio-huella .cifra {
    color: #00b23c;
}

.sitio-huella .progreso-barra span,
.sitio-huella .gracias-icono {
    background: #00b23c;
}

.sitio-huella .campo:focus {
    border-color: #00b23c;
}

.sitio-huella .letra {
    background: #e6f7ec;
    color: #00b23c;
}

.sitio-huella .opcion.elegida .letra {
    background: #fff;
}

/* ------------------------------------------------------------------ */
/* Resultado de la versión offline: tiene que caber sin scroll, y el    */
/* de University lleva las 7 preguntas con su respuesta correcta.       */
/* ------------------------------------------------------------------ */

.pantalla-resultado .cabecera {
    margin-bottom: 32px;
}

.pantalla-resultado .titulo {
    margin-bottom: 24px;
    font-size: 46px;
    letter-spacing: -0.01em;
    white-space: nowrap;
}

.pantalla-resultado .aviso-envio {
    margin: 0 0 24px;
    font-size: 26px;
}

.pantalla-resultado .subtitulo {
    margin-bottom: 4px;
    font-size: 30px;
}

.pantalla-resultado .cifra {
    margin-bottom: 24px;
    font-size: 52px;
}

.pantalla-resultado .desglose th,
.pantalla-resultado .desglose td {
    padding: 12px 0;
}

.pantalla-resultado .correcciones {
    margin-bottom: 24px;
    padding-left: 40px;
    font-size: 22px;
    line-height: 1.3;
}

.pantalla-resultado .correcciones li {
    margin-bottom: 12px;
}

.pantalla-resultado .qr-bloque {
    margin-top: 0;
}

.pantalla-resultado .qr img {
    width: 260px;
    height: 260px;
}

.pantalla-resultado .qr-texto {
    font-size: 28px;
}

.pantalla-resultado .navegacion {
    margin-top: 28px;
}
