:root {
    --marron: #3D2B1F;
    --crema: #F5EFE6;
    --crema-2: #EBE1D2;
    --verde: #2E7D44;
    --verde-claro: #E3F4E8;
    --rojo: #B23B3B;
    --rojo-claro: #FBE6E6;
}

* { box-sizing: border-box; }

html, body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background: var(--crema);
    color: var(--marron);
    -webkit-text-size-adjust: 100%;
}

h1, h2 { font-weight: 700; }
h1:focus { outline: none; }

/* ── Shell ─────────────────────────────────────────────── */
.app-shell { min-height: 100vh; display: flex; flex-direction: column; }

.app-header {
    background: var(--marron);
    color: var(--crema);
    display: flex; align-items: center; justify-content: space-between;
    padding: 14px 18px;
}
.app-header .brand { font-weight: 700; font-size: 1.2rem; letter-spacing: .5px; }
.header-user { font-size: .9rem; display: flex; align-items: center; gap: 12px; }
.logout {
    background: transparent; color: var(--crema);
    border: 1px solid rgba(245,239,230,.5); border-radius: 8px;
    padding: 4px 10px; font-size: .85rem; cursor: pointer;
}
.logout:active { background: rgba(245,239,230,.15); }

.app-main { flex: 1; padding: 20px 18px 40px; max-width: 560px; width: 100%; margin: 0 auto; }

.saludo { font-size: 1.5rem; margin: 8px 0 2px; }
.rol { color: #7a6a5c; margin: 0 0 22px; }
.cargando, .vacio, .proximamente { color: #7a6a5c; }
.proximamente { margin-top: 28px; font-size: .85rem; }

/* ── Tarjetas dashboard ────────────────────────────────── */
.cards { display: grid; gap: 14px; }
.cards-grid { grid-template-columns: 1fr 1fr; }
.card {
    background: #fff; border: none; border-radius: 16px;
    padding: 20px; text-align: left; cursor: pointer;
    box-shadow: 0 2px 8px rgba(61,43,31,.08);
    display: flex; flex-direction: column; gap: 4px;
}
.card:active { background: var(--crema-2); }
.card-icon { font-size: 1.6rem; }
.card-title { font-weight: 700; font-size: 1.05rem; }
.card-desc { color: #7a6a5c; font-size: .85rem; }

/* ── Dashboard (estilo app Android) ────────────────────── */
.dash { display: flex; flex-direction: column; }
.dash-head { text-align: center; padding: 16px 0 18px; display: flex; flex-direction: column; gap: 6px; align-items: center; }
.dash-brand { font-size: 1.9rem; font-weight: 800; letter-spacing: .5px; color: var(--marron); }
.dash-bienvenida { font-size: .95rem; color: #6B5A4E; }
.dash-rol {
    background: var(--marron); color: #C9B99A; font-size: .72rem; font-weight: 700;
    letter-spacing: .5px; padding: 7px 18px; border-radius: 999px;
}
.dash-aviso {
    background: #FEF3C7; color: #92400E; border-radius: 12px; padding: 12px 14px;
    margin: 4px 0 12px; font-size: .9rem; cursor: pointer;
}
.seccion-h {
    font-size: .72rem; font-weight: 700; color: #A09080; letter-spacing: .5px;
    text-transform: uppercase; margin: 16px 4px 8px;
}

/* Tarjeta-fila (icono + texto + chevron), como en la app */
.rowcard {
    width: 100%; background: #fff; border: none; border-radius: 20px;
    padding: 14px 18px; margin-bottom: 12px; cursor: pointer; text-align: left;
    display: flex; align-items: center; gap: 14px;
    box-shadow: 0 2px 8px rgba(61,43,31,.07); position: relative; min-height: 78px;
}
.rowcard:active { background: var(--crema-2); }
.rowcard-ic {
    flex-shrink: 0; width: 48px; height: 48px; border-radius: 14px; background: #F0EAE0;
    display: flex; align-items: center; justify-content: center; font-size: 1.4rem;
}
.rowcard-tx { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.rowcard-tx b { font-size: .98rem; color: var(--marron); }
.rowcard-tx small { font-size: .78rem; color: #A09080; }
.rowcard-ch { color: #C9B99A; font-size: 1.5rem; line-height: 1; }

/* Tarjetas cuadradas en dos columnas */
.dash-2col { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.cardbox {
    background: #fff; border: none; border-radius: 20px; padding: 16px; cursor: pointer;
    text-align: left; display: flex; flex-direction: column; gap: 10px; position: relative;
    box-shadow: 0 2px 8px rgba(61,43,31,.07);
}
.cardbox:active { background: var(--crema-2); }
.cardbox-ic {
    width: 48px; height: 48px; border-radius: 14px; background: #F0EAE0;
    display: flex; align-items: center; justify-content: center; font-size: 1.4rem;
}
.cardbox-tx { display: flex; flex-direction: column; gap: 2px; }
.cardbox-tx b { font-size: .98rem; color: var(--marron); }
.cardbox-tx small { font-size: .78rem; color: #A09080; }

.badge-rojo {
    background: #C0392B; color: #fff; font-size: .75rem; font-weight: 700;
    min-width: 22px; height: 22px; border-radius: 999px; padding: 0 6px;
    display: flex; align-items: center; justify-content: center;
    position: absolute; top: 10px; right: 12px;
}

/* ── Login ─────────────────────────────────────────────── */
.login-bg {
    min-height: 100vh; background: var(--marron);
    display: flex; align-items: center; justify-content: center; padding: 24px;
}
.login-card {
    background: var(--crema); border-radius: 20px;
    padding: 32px 26px; width: 100%; max-width: 380px;
    box-shadow: 0 10px 40px rgba(0,0,0,.3);
}
.login-brand { text-align: center; margin: 0; font-size: 2rem; letter-spacing: 1px; }
.login-sub { text-align: center; color: #7a6a5c; margin: 4px 0 24px; }
.login-form { display: flex; flex-direction: column; }
.login-form label { font-size: .85rem; font-weight: 600; margin: 12px 0 6px; }
.login-form input {
    border: 1px solid #d6c9b8; border-radius: 10px; padding: 12px;
    font-size: 1rem; background: #fff; color: var(--marron);
}
.login-form input:focus { outline: 2px solid var(--marron); border-color: var(--marron); }
.login-btn {
    margin-top: 22px; background: var(--marron); color: var(--crema);
    border: none; border-radius: 10px; padding: 14px; font-size: 1rem;
    font-weight: 600; cursor: pointer;
}
.login-btn:disabled { opacity: .6; }
.login-error { color: var(--rojo); font-size: .9rem; margin: 14px 0 0; }
.login-sep { display: flex; align-items: center; gap: 10px; margin: 18px 0; color: #a09080; font-size: .85rem; }
.login-sep::before, .login-sep::after { content: ""; flex: 1; height: 1px; background: #d6c9b8; }
.login-clickup {
    width: 100%; background: #fff; color: #7B68EE; border: 1.5px solid #7B68EE;
    border-radius: 10px; padding: 13px; font-size: 1rem; font-weight: 600; cursor: pointer;
}
.login-clickup:disabled { opacity: .6; }
.login-clickup:active { background: #f3f0ff; }

/* ── Fichaje ───────────────────────────────────────────── */
.estado-box {
    border-radius: 16px; padding: 18px; margin-bottom: 18px;
    display: flex; flex-direction: column; gap: 2px;
}
.estado-box.dentro { background: var(--rojo-claro); }
.estado-box.fuera  { background: var(--verde-claro); }
.estado-label { font-weight: 700; font-size: 1.1rem; }
.estado-desde { color: #7a6a5c; font-size: .9rem; }

.fichar-btn {
    width: 100%; border: none; border-radius: 16px; padding: 20px;
    font-size: 1.15rem; font-weight: 700; cursor: pointer; color: #fff;
}
.fichar-btn.entrada { background: var(--verde); }
.fichar-btn.salida  { background: var(--rojo); }
.fichar-btn:disabled { opacity: .6; }
.aviso { color: var(--rojo); font-size: .9rem; }

.hoy-title { font-size: 1.1rem; margin: 28px 0 10px; }
.lista-fichajes { list-style: none; padding: 0; margin: 0; }
.lista-fichajes li {
    background: #fff; border-radius: 12px; padding: 12px 16px; margin-bottom: 8px;
    display: flex; align-items: center; justify-content: space-between;
    box-shadow: 0 1px 4px rgba(61,43,31,.06);
}
.tipo { font-weight: 600; }
.tipo.entrada { color: var(--verde); }
.tipo.salida  { color: var(--rojo); }
.hora { font-variant-numeric: tabular-nums; color: var(--marron); }

/* ── Vacaciones ────────────────────────────────────────── */
.vac-panel {
    display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 18px;
}
.vac-kpi {
    background: #fff; border-radius: 14px; padding: 16px 8px; text-align: center;
    box-shadow: 0 1px 4px rgba(61,43,31,.06);
    display: flex; flex-direction: column; gap: 2px;
}
.vac-kpi.destacado { background: var(--marron); color: var(--crema); }
.vac-num { font-size: 1.6rem; font-weight: 700; }
.vac-lbl { font-size: .8rem; opacity: .8; }
.vac-solicitar { margin-bottom: 4px; }
.vac-form {
    background: #fff; border-radius: 14px; padding: 16px; margin: 14px 0 8px;
    display: flex; flex-direction: column; box-shadow: 0 1px 4px rgba(61,43,31,.06);
}
.vac-form label { font-size: .85rem; font-weight: 600; margin: 10px 0 4px; }
.vac-form input, .vac-form textarea {
    border: 1px solid #d6c9b8; border-radius: 10px; padding: 10px;
    font-size: 1rem; background: #fff; color: var(--marron); font-family: inherit;
}
.vac-item { }
.vac-item-info { display: flex; flex-direction: column; gap: 2px; }
.vac-periodo { font-weight: 600; }
.vac-dias { color: #7a6a5c; font-size: .85rem; }

.badge {
    font-size: .8rem; font-weight: 600; padding: 4px 10px; border-radius: 999px;
    white-space: nowrap;
}
.estado-pendiente { background: #FEF3C7; color: #92400E; }
.estado-aprobada  { background: #D1FAE5; color: #065F46; }
.estado-rechazada { background: #FEE2E2; color: #991B1B; }
.estado-cancelada { background: #F3F4F6; color: #374151; }

/* ── Consultas ─────────────────────────────────────────── */
.trabajo-item { cursor: pointer; gap: 10px; }
.trabajo-item:active { background: var(--crema-2); }
.trabajo-name { font-weight: 600; flex: 1; }
.status-chip {
    color: #fff; font-size: .75rem; font-weight: 600; padding: 4px 10px;
    border-radius: 999px; white-space: nowrap; text-transform: capitalize;
    text-shadow: 0 1px 1px rgba(0,0,0,.25);
}
.volver {
    background: none; border: none; color: var(--marron); font-size: .95rem;
    cursor: pointer; padding: 4px 0; margin-bottom: 6px; font-weight: 600;
}
.detalle-estado { margin-bottom: 14px; }
.detalle-row {
    background: #fff; border-radius: 12px; padding: 12px 16px; margin-bottom: 8px;
    display: flex; flex-direction: column; gap: 4px; box-shadow: 0 1px 4px rgba(61,43,31,.06);
}
.detalle-lbl { font-size: .75rem; font-weight: 700; color: #7a6a5c; text-transform: uppercase; letter-spacing: .5px; }
.detalle-link { color: #2563EB; text-decoration: none; word-break: break-word; }
.detalle-desc { white-space: pre-wrap; }
.fotos-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); gap: 8px;
}
.fotos-grid img {
    width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 10px;
    background: var(--crema-2);
}
/* Recuadro "+" para añadir una foto nueva, del mismo tamaño que las fotos */
.foto-add {
    display: flex; align-items: center; justify-content: center;
    width: 100%; aspect-ratio: 1; border-radius: 10px;
    border: 2px dashed #c9b99a; background: var(--crema-2);
    color: #8b6148; font-size: 2.2rem; font-weight: 700;
    line-height: 1; cursor: pointer; user-select: none;
}
.foto-add:hover { background: #efe7da; }
.foto-add input { display: none; }
.vac-form select {
    border: 1px solid #d6c9b8; border-radius: 10px; padding: 10px;
    font-size: 1rem; background: #fff; color: var(--marron);
}

/* ── Nóminas / Documentos ──────────────────────────────── */
.doc-item { gap: 10px; }
.doc-firma, .doc-estado { font-size: .8rem; }
.doc-estado { color: #7a6a5c; }
.doc-acciones { display: flex; gap: 6px; flex-shrink: 0; }
.btn-mini {
    border: 1px solid #d6c9b8; background: #fff; color: var(--marron);
    border-radius: 8px; padding: 6px 12px; font-size: .85rem; font-weight: 600; cursor: pointer;
}
.btn-mini:active { background: var(--crema-2); }
.btn-mini.firmar { background: #D9A441; color: #fff; border-color: #D9A441; }
.btn-mini.leido  { background: var(--marron); color: var(--crema); border-color: var(--marron); }

/* ── Perfil ────────────────────────────────────────────── */
.perfil-card {
    background: #fff; border-radius: 18px; padding: 24px; margin: 8px 0 18px;
    display: flex; flex-direction: column; align-items: center; gap: 10px;
    box-shadow: 0 2px 8px rgba(61,43,31,.07);
}
.perfil-avatar {
    width: 72px; height: 72px; border-radius: 999px; background: var(--marron); color: var(--crema);
    display: flex; align-items: center; justify-content: center; font-size: 1.6rem; font-weight: 700;
}
.perfil-nombre { font-size: 1.2rem; font-weight: 700; }
.perfil-rol-badge {
    background: var(--marron); color: #C9B99A; font-size: .72rem; font-weight: 700;
    letter-spacing: .5px; padding: 6px 16px; border-radius: 999px; text-transform: uppercase;
}

/* ── Sugerencias ───────────────────────────────────────── */
.sug-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.sug-filtro {
    width: 100%; border: 1px solid #d6c9b8; border-radius: 10px; padding: 10px;
    font-size: 1rem; background: #fff; color: var(--marron); margin-bottom: 14px;
}
.sug-card {
    background: #fff; border-radius: 14px; padding: 14px; margin-bottom: 10px;
    box-shadow: 0 1px 4px rgba(61,43,31,.06); display: flex; flex-direction: column; gap: 4px;
}
.sug-card-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.sug-cat { font-size: .72rem; font-weight: 700; color: #8B6148; }
.sug-titulo { font-weight: 700; }
.sug-desc { font-size: .9rem; color: #6B5A4E; white-space: pre-wrap; }
.sug-autor { font-size: .75rem; color: #A09080; }
.sug-nota { font-size: .82rem; font-style: italic; color: #1E40AF; }
.sug-admin { display: flex; gap: 8px; margin-top: 8px; }
.sug-admin select { flex: 1; border: 1px solid #d6c9b8; border-radius: 8px; padding: 7px; background: #fff; color: var(--marron); }
.sug-sep {
    display: flex; align-items: center; gap: 10px; margin: 16px 0 8px;
    color: #A09080; font-size: .75rem; font-weight: 700; text-transform: uppercase;
}
.sug-sep::before, .sug-sep::after { content: ""; flex: 1; height: 2px; background: #D8CFC2; }

/* ── Trabajando ahora ──────────────────────────────────── */
.ta-fila {
    background: #fff; border-radius: 16px; padding: 12px 16px; margin-bottom: 8px;
    display: flex; align-items: center; gap: 12px; box-shadow: 0 1px 4px rgba(61,43,31,.06);
}
.ta-punto { width: 10px; height: 10px; border-radius: 999px; background: #C9B99A; flex-shrink: 0; }
.ta-punto.dentro { background: #16A34A; }
.ta-tx { display: flex; flex-direction: column; gap: 2px; }
.ta-tx b { font-size: .95rem; color: var(--marron); }
.ta-tx small { font-size: .75rem; color: #A09080; }

/* ── Festivos ──────────────────────────────────────────── */
.fest-fila {
    background: #fff; border-radius: 12px; padding: 10px 14px; margin-bottom: 8px;
    display: flex; align-items: center; gap: 10px; box-shadow: 0 1px 4px rgba(61,43,31,.06);
}
.fest-fecha { font-size: .82rem; font-weight: 700; color: var(--marron); width: 64px; flex-shrink: 0; }
.fest-info { flex: 1; display: flex; flex-direction: column; gap: 1px; }
.fest-info small { font-size: .68rem; color: #A09080; }
.fest-info small.fest-tipo-c { color: #8B6148; }

/* ── Notas ─────────────────────────────────────────────── */
.nota-card { background: #fff; border-radius: 12px; padding: 10px 12px; margin-bottom: 10px; box-shadow: 0 1px 4px rgba(61,43,31,.06); }
.nota-cab { font-size: .7rem; color: #A09080; margin-bottom: 4px; }
.nota-texto { font-size: .95rem; color: var(--marron); white-space: pre-wrap; }
.nota-img { width: 100%; border-radius: 10px; display: block; }
.nota-video { background: #3D2B1F; color: #fff; border-radius: 10px; padding: 18px; text-align: center; font-weight: 700; }
.nota-barra { position: sticky; bottom: 0; background: var(--crema); display: flex; gap: 6px; align-items: center; padding: 8px 0; }
.nota-imgbtn { display: flex; align-items: center; justify-content: center; cursor: pointer; }
.nota-input { flex: 1; border: 1px solid #d6c9b8; border-radius: 20px; padding: 10px 14px; font-size: 1rem; background: #fff; color: var(--marron); }
.nota-enviar { background: var(--marron); color: var(--crema); border-color: var(--marron); }

/* ── Informe de jornada ────────────────────────────────── */
.ij-row { display: flex; gap: 10px; }
.ij-resumen { font-weight: 700; color: var(--marron); margin: 14px 0 8px; }
.ij-tabla { width: 100%; border-collapse: collapse; background: #fff; border-radius: 12px; overflow: hidden; box-shadow: 0 1px 4px rgba(61,43,31,.06); }
.ij-tabla th { background: var(--marron); color: var(--crema); font-size: .78rem; padding: 8px; text-align: left; }
.ij-tabla td { padding: 8px; font-size: .85rem; border-top: 1px solid #F0EAE0; font-variant-numeric: tabular-nums; }

/* ── Mis horas (calendario de jornada) ─────────────────── */
.mh-total { font-size: .9rem; color: #6B5A4E; margin: 4px 0 12px; }
.mh-fila {
    background: #fff; border-radius: 12px; padding: 10px 14px; margin-bottom: 8px;
    display: flex; align-items: center; gap: 10px; box-shadow: 0 1px 4px rgba(61,43,31,.06); cursor: pointer;
}
.mh-fila.nolab { background: #F0EAE0; }
.mh-fecha { width: 56px; flex-shrink: 0; font-size: .82rem; font-weight: 700; color: var(--marron); }
.mh-fecha.gris { color: #A09080; }
.mh-centro { flex: 1; display: flex; flex-direction: column; gap: 1px; }
.mh-centro small { font-size: .72rem; }
.mh-barra { width: 64px; height: 12px; border-radius: 6px; background: #E8DDD0; overflow: hidden; flex-shrink: 0; }
.mh-fill { display: block; height: 100%; border-radius: 6px; }
.mh-editor { background: #fff; border-radius: 14px; padding: 16px; margin-top: 14px; box-shadow: 0 2px 10px rgba(61,43,31,.12); display: flex; flex-direction: column; }
.mh-editor label { font-size: .85rem; font-weight: 600; margin: 10px 0 4px; }
.mh-editor input { border: 1px solid #d6c9b8; border-radius: 10px; padding: 10px; font-size: 1rem; background: #fff; color: var(--marron); }
.mh-editor-btns { display: flex; gap: 8px; align-items: center; margin-top: 14px; }

/* ── Bolsa de horas ────────────────────────────────────── */
.bh-check { display: flex; align-items: center; gap: 8px; font-size: .9rem; margin-top: 10px; }
.bh-fila { background: #fff; border-radius: 16px; padding: 10px 14px; margin-bottom: 8px; display: flex; align-items: center; gap: 10px; box-shadow: 0 1px 4px rgba(61,43,31,.06); }
.bh-ic { font-size: 1.3rem; }
.bh-tx { flex: 1; display: flex; flex-direction: column; gap: 1px; }
.bh-tx b { font-size: .95rem; color: var(--marron); }
.bh-tx small { font-size: .72rem; color: #A09080; }
.bh-imp { font-weight: 700; font-size: .95rem; }
.bh-del { background: #F0EAE0; color: #C0392B; border: none; width: 34px; height: 34px; border-radius: 999px; cursor: pointer; flex-shrink: 0; }

/* ── Gestión de usuarios ───────────────────────────────── */
.usr-card { background: #fff; border-radius: 14px; margin-bottom: 8px; box-shadow: 0 1px 4px rgba(61,43,31,.06); overflow: hidden; }
.usr-head { display: flex; align-items: center; gap: 10px; padding: 12px 14px; cursor: pointer; }
.usr-avatar { width: 38px; height: 38px; border-radius: 999px; background: var(--marron); color: var(--crema); display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: .85rem; flex-shrink: 0; }
.usr-tx { flex: 1; display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.usr-tx b { font-size: .95rem; color: var(--marron); }
.usr-tx small { font-size: .72rem; color: #A09080; overflow: hidden; text-overflow: ellipsis; }
.usr-rol { font-size: .7rem; font-weight: 700; color: #8B6148; background: #F0EAE0; padding: 4px 10px; border-radius: 999px; }
.usr-edit { padding: 0 14px 14px; display: flex; flex-direction: column; border-top: 1px solid #F0EAE0; }
.usr-edit label { font-size: .8rem; font-weight: 600; margin: 10px 0 4px; }
.usr-edit select, .usr-edit input { border: 1px solid #d6c9b8; border-radius: 8px; padding: 8px; background: #fff; color: var(--marron); }
.usr-links { display: flex; gap: 6px; margin-top: 12px; flex-wrap: wrap; }

/* ── Horario laboral ───────────────────────────────────── */
.hl-row { display: flex; align-items: center; justify-content: space-between; padding: 8px 0; border-bottom: 1px solid #F0EAE0; }
.hl-row input { width: 90px; border: 1px solid #d6c9b8; border-radius: 8px; padding: 8px; text-align: center; background: #fff; color: var(--marron); }

/* ── Validación / Error UI ─────────────────────────────── */
.valid.modified:not([type=checkbox]) { outline: 1px solid #26b050; }
.invalid { outline: 1px solid #e50000; }
.validation-message { color: #e50000; }

#blazor-error-ui {
    color-scheme: light only;
    background: lightyellow; bottom: 0; box-shadow: 0 -1px 2px rgba(0,0,0,.2);
    box-sizing: border-box; display: none; left: 0; padding: 0.6rem 1.25rem 0.7rem;
    position: fixed; width: 100%; z-index: 1000;
}
#blazor-error-ui .dismiss { cursor: pointer; position: absolute; right: 0.75rem; top: 0.5rem; }

/* ── Ventas / Objetivos / Retrasos ──────────────────────────────── */
.vt-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0; }
.vt-chip {
    border: none; border-radius: 20px; padding: 6px 14px; font-size: 13px;
    font-weight: 700; background: #F0EAE0; color: #3D2B1F; cursor: pointer;
}
.vt-chip.on { background: #3D2B1F; color: #C9B99A; }
.vt-chart {
    display: flex; align-items: flex-end; gap: 4px; height: 100px;
    margin: 14px 0 8px; padding: 0 2px;
}
.vt-bar-col {
    flex: 1; display: flex; flex-direction: column; align-items: center;
    justify-content: flex-end; height: 100%; cursor: pointer;
}
.vt-bar-n { font-size: 9px; color: #9CA3AF; margin-bottom: 2px; }
.vt-bar { width: 100%; background: #C9B99A; border-radius: 3px 3px 0 0; }
.vt-bar.cur { background: #3D2B1F; }
.vt-bar-l { font-size: 9px; color: #9CA3AF; margin-top: 3px; }
.vt-bar-l.cur { color: #3D2B1F; font-weight: 700; }
.vt-total { font-size: 13px; color: #A09080; font-weight: 600; margin: 10px 0 6px; }
.vt-meta { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.vt-asg { font-size: 12px; color: #A09080; }

.obj-kpis { display: flex; gap: 8px; margin: 12px 0; }
.obj-kpi {
    flex: 1; background: #F5EFE6; border-radius: 12px; padding: 12px 8px;
    display: flex; flex-direction: column; align-items: center; gap: 2px;
}
.obj-kpi-l { font-size: 11px; color: #A09080; }
.obj-kpi-v { font-size: 18px; font-weight: 800; color: #3D2B1F; }
.obj-kpi-m { font-size: 11px; color: #A09080; }
.obj-pts { font-size: 14px; font-weight: 800; }
.obj-mg { font-size: 12px; font-weight: 600; }

/* ── Calendario ─────────────────────────────────────────────────── */
.cal-head { display: flex; align-items: center; justify-content: space-between; }
.cal-add {
    border: none; border-radius: 20px; padding: 8px 16px; font-weight: 700;
    background: #3D2B1F; color: #C9B99A; cursor: pointer; font-size: 14px;
}
.cal-nav { display: flex; align-items: center; justify-content: center; gap: 14px; margin: 10px 0; }
.cal-mes { font-size: 16px; font-weight: 800; color: #3D2B1F; min-width: 150px; text-align: center; }
.cal-dia-h {
    font-size: 13px; font-weight: 800; color: #A09080; text-transform: capitalize;
    margin: 16px 0 6px;
}
.cal-ev { border-radius: 10px; padding: 10px 12px; margin-bottom: 8px; cursor: pointer; }
.cal-ev-top { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.cal-ev-tit { font-weight: 700; color: #3D2B1F; }
.cal-ev-tag { font-size: 11px; font-weight: 700; }
.cal-ev-sub { font-size: 12px; color: #A09080; margin-top: 2px; }

.cal-modal-bg {
    position: fixed; inset: 0; background: rgba(0,0,0,.4); z-index: 2000;
    display: flex; align-items: center; justify-content: center; padding: 16px;
}
.cal-modal {
    background: #fff; border-radius: 16px; padding: 18px; width: 100%; max-width: 440px;
    max-height: 90vh; overflow-y: auto;
}
.cal-modal label { display: block; font-size: 12px; color: #A09080; font-weight: 700; margin: 10px 0 4px; }
.cal-modal input[type=text], .cal-modal input:not([type]), .cal-modal select,
.cal-modal textarea, .cal-modal input[type=date], .cal-modal input[type=time] {
    width: 100%; box-sizing: border-box; border: 1px solid #E5DCCD; border-radius: 8px;
    padding: 8px 10px; font-size: 14px;
}
.cal-check { display: flex; align-items: center; gap: 6px; font-weight: 700; }
.cal-check input { width: auto; }
.cal-fechas { display: flex; gap: 10px; }
.cal-fechas > div { flex: 1; }
.cal-modal-acc { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; align-items: center; }
.btn-peligro {
    border: none; border-radius: 8px; padding: 10px 16px; font-weight: 700;
    background: #FEE2E2; color: #DC2626; cursor: pointer;
}

/* ── Reseñas ────────────────────────────────────────────────────── */
.res-google {
    background: #3D2B1F; color: #F5EFE6; border-radius: 16px; padding: 16px;
    margin: 12px 0; text-align: center;
}
.res-g-rating { font-size: 30px; font-weight: 800; color: #FFC107; }
.res-g-det { font-size: 13px; color: #C9B99A; margin-top: 2px; }
.res-g-sem { font-size: 12px; color: #6EE7B7; font-weight: 700; margin-top: 6px; }
.res-card {
    background: #fff; border-radius: 16px; padding: 14px 16px; margin-bottom: 8px; cursor: pointer;
}
.res-card-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.res-cliente { font-size: 15px; font-weight: 700; color: #3D2B1F; }
.res-chip { font-size: 10px; font-weight: 700; border-radius: 10px; padding: 4px 10px; white-space: nowrap; }
.res-tel { font-size: 12px; color: #6B5A4E; margin-top: 4px; }
.res-nota { font-size: 12px; color: #A09080; margin-top: 2px; }

/* ── Banco ──────────────────────────────────────────────────────── */
.bnk-aviso { background: #FEF3C7; color: #92400E; border-radius: 10px; padding: 10px 12px; font-size: 13px; margin: 8px 0; }
.bnk-aviso.grave { background: #FEE2E2; color: #991B1B; }
.bnk-saldo { background: #3D2B1F; color: #F5EFE6; border-radius: 16px; padding: 18px; text-align: center; margin: 10px 0; }
.bnk-saldo-v { font-size: 28px; font-weight: 800; }
.bnk-saldo-s { font-size: 12px; color: #C9B99A; margin-top: 4px; }
.bnk-acc { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.bnk-btn { border: none; border-radius: 20px; padding: 8px 16px; font-weight: 700; background: #C9B99A; color: #3D2B1F; cursor: pointer; font-size: 13px; }
.bnk-btn.alt { background: #F0EAE0; }
.bnk-btn:disabled { opacity: .5; cursor: default; }
.bnk-queries { font-size: 12px; color: #A09080; margin-left: auto; }
.bnk-cuentas { display: flex; gap: 6px; margin-bottom: 6px; }
.bnk-chip { border: none; border-radius: 10px; padding: 7px 12px; font-size: 12px; font-weight: 700; background: #fff; color: #3D2B1F; cursor: pointer; }
.bnk-chip.on { background: #3D2B1F; color: #fff; }
.bnk-cuenta { display: flex; justify-content: space-between; align-items: center; background: #fff; border-radius: 10px; padding: 10px 12px; margin-bottom: 6px; cursor: pointer; }
.bnk-cuenta.sel { background: #EFE7DA; border: 2px solid #8B6148; }
.bnk-cuenta-izq { display: flex; flex-direction: column; }
.bnk-cuenta-n { font-size: 13px; font-weight: 700; color: #1C1917; }
.bnk-cuenta-i { font-size: 10px; color: #A09080; }
.bnk-cuenta-s { font-size: 13px; font-weight: 700; color: #3D2B1F; }
.bnk-dia { font-size: 11px; font-weight: 700; color: #8B6148; margin: 10px 0 4px; }
.bnk-mov { display: flex; justify-content: space-between; align-items: center; gap: 8px; background: #fff; border-radius: 9px; padding: 9px 11px; margin-bottom: 5px; cursor: pointer; }
.bnk-mov-izq { display: flex; flex-direction: column; min-width: 0; }
.bnk-mov-t { font-size: 12px; color: #1C1917; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bnk-mov-t.exp { white-space: normal; }
.bnk-mov-f { font-size: 10px; color: #A09080; }
.bnk-mov-imp { font-size: 13px; font-weight: 700; white-space: nowrap; }
.bnk-detalle { white-space: pre-wrap; font-family: inherit; font-size: 13px; color: #3D2B1F; background: #F5EFE6; border-radius: 8px; padding: 10px; }

/* ── Admin nóminas / documentos ─────────────────────────────────── */
.adm-subir { background: #F5EFE6; border-radius: 14px; padding: 14px; margin: 12px 0; }
.adm-subir label { display: block; font-size: 12px; color: #A09080; font-weight: 700; margin: 8px 0 4px; }
.adm-subir input:not([type=checkbox]), .adm-subir textarea, .adm-subir select {
    width: 100%; box-sizing: border-box; border: 1px solid #E5DCCD; border-radius: 8px; padding: 8px 10px; font-size: 14px;
}
.adm-periodo { display: flex; gap: 8px; margin-bottom: 8px; }
.adm-periodo select { flex: 1; }
.adm-file { display: block; margin-top: 10px; }
.adm-file input { width: 100%; }
.adm-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; background: #fff; border-radius: 12px; padding: 12px 14px; margin-bottom: 8px; }
.adm-row-info { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.adm-row-t { font-size: 14px; font-weight: 700; color: #3D2B1F; }
.adm-row-s { font-size: 11px; color: #A09080; }
.adm-row-f { font-size: 11px; font-weight: 700; }
.adm-row-acc { display: flex; gap: 6px; align-items: center; flex-shrink: 0; }
.btn-mini.firmar { background: #3D2B1F; color: #C9B99A; }

/* ── Botón de ajustes en cabecera del dashboard ─────────────────── */
.dash-head { position: relative; }
.dash-cfg {
    position: absolute; top: 0; right: 0; border: none; background: transparent;
    font-size: 20px; cursor: pointer; padding: 4px 8px; opacity: .85;
}

/* ── Botones de documentación (Consultas) ───────────────────────── */
.doc-botones { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0 4px; }
.doc-btn {
    display: inline-block; background: #3D2B1F; color: #C9B99A; text-decoration: none;
    border-radius: 10px; padding: 10px 14px; font-size: 13px; font-weight: 700;
}
.doc-btn:hover { opacity: .9; }

/* ── Calendario de vacaciones ───────────────────────────────────── */
.vac-cal { background: #fff; border-radius: 16px; padding: 14px; margin: 14px 0; }
.vac-cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; margin-top: 8px; }
.vac-cal-dow { text-align: center; font-size: 11px; font-weight: 700; color: #A09080; padding-bottom: 4px; }
.vac-cal-cell {
    aspect-ratio: 1 / 1; display: flex; align-items: center; justify-content: center;
    font-size: 13px; color: #3D2B1F; border-radius: 8px; background: #F7F3EC;
}
.vac-cal-cell.vacia { background: transparent; }
.vac-cal-cell.finde { color: #C0B4A4; }
.vac-cal-cell.aprob { background: #16A34A; color: #fff; font-weight: 700; }
.vac-cal-cell.pend  { background: #F59E0B; color: #fff; font-weight: 700; }
.vac-cal-cell.fest  { background: #7C3AED; color: #fff; font-weight: 700; }
.vac-cal-cell.equipo { background: #8B6148; color: #fff; font-weight: 700; }
.vac-cal-leyenda { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 12px; font-size: 11px; color: #A09080; }
.vac-cal-leyenda span { display: flex; align-items: center; gap: 5px; }
.vac-cal-leyenda .lg { width: 12px; height: 12px; border-radius: 4px; display: inline-block; }
.vac-cal-leyenda .lg.aprob { background: #16A34A; }
.vac-cal-leyenda .lg.equipo { background: #8B6148; }
.vac-cal-leyenda .lg.pend { background: #F59E0B; }
.vac-cal-leyenda .lg.fest { background: #7C3AED; }

/* ── Tarjetas de Consultas (con icono de notas y badge "!") ─────── */
.cns-lista { display: flex; flex-direction: column; gap: 10px; margin-top: 12px; }
.cns-card {
    position: relative; display: flex; align-items: stretch; background: #fff;
    border-radius: 14px; overflow: hidden; cursor: pointer; min-height: 64px;
}
.cns-bar { width: 6px; flex-shrink: 0; }
.cns-body { display: flex; flex-direction: column; gap: 6px; padding: 12px 46px 12px 14px; flex: 1; min-width: 0; }
.cns-name { font-size: 14px; font-weight: 700; color: #3D2B1F; line-height: 1.3; }
.cns-status {
    align-self: flex-start; font-size: 10px; font-weight: 700; border-radius: 6px;
    padding: 2px 8px; max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.cns-notas {
    position: absolute; right: 10px; bottom: 8px; border: none; background: transparent;
    font-size: 20px; cursor: pointer; padding: 2px; line-height: 1;
}
.cns-badge {
    position: absolute; right: 10px; top: 8px; width: 22px; height: 22px; border: none;
    border-radius: 11px; background: #E11D48; color: #fff; font-weight: 800; font-size: 13px;
    cursor: pointer; display: flex; align-items: center; justify-content: center; line-height: 1;
}

/* ── Galería de planos / despieces ──────────────────────────────── */
.gal-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 8px; margin-top: 8px; }
.gal-thumb { border: none; padding: 0; background: #E5DDD4; border-radius: 12px; overflow: hidden; aspect-ratio: 1 / 1; cursor: pointer; }
.gal-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gal-lightbox {
    position: fixed; inset: 0; background: rgba(0,0,0,.92); z-index: 3000;
    display: flex; align-items: center; justify-content: center;
}
.gal-lightbox img { max-width: 92vw; max-height: 88vh; object-fit: contain; border-radius: 8px; }
.gal-nav {
    position: absolute; top: 50%; transform: translateY(-50%); border: none;
    background: rgba(255,255,255,.15); color: #fff; font-size: 32px; width: 48px; height: 64px;
    border-radius: 10px; cursor: pointer;
}
.gal-nav.izq { left: 10px; }
.gal-nav.der { right: 10px; }
.gal-cerrar {
    position: absolute; top: 14px; right: 16px; border: none; background: rgba(255,255,255,.15);
    color: #fff; font-size: 20px; width: 40px; height: 40px; border-radius: 20px; cursor: pointer;
}
.gal-contador { position: absolute; bottom: 16px; left: 0; right: 0; text-align: center; color: #fff; font-size: 13px; }

/* ── Visor de PDF ───────────────────────────────────────────────── */
.pdf-frame { width: 100%; height: 78vh; border: none; border-radius: 12px; background: #fff; }
