@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&family=Ubuntu:wght@300;400;500;700&display=swap');

*{
    margin: 0;
    padding: 0;
    font-family: "Inter", "Ubuntu", system-ui, -apple-system, sans-serif;
    box-sizing: border-box;
}

/*======================================================================
  Design Tokens: "AG Sky UI" — cielo animado + tarjetas de vidrio claras
  (con una variante oscura puntual) + dock flotante estilo dock de macOS.
======================================================================*/
:root{
    /* Alias heredados (compatibilidad con el resto del CSS existente,
       ahora remapeados a la nueva paleta clara / cielo) */
    --AGPRINCIPAL: #f2a541;
    --greenAG: #111113;
    --DarkColor: rgba(255, 255, 255, 0.80);
    --DargGray: rgba(17, 17, 19, 0.06);
    --grayLith: rgba(17, 17, 19, 0.08);
    --ColorLith: #16161a;
    --AGSECON: transparent;

    /* Radios */
    --radius-card: 28px;
    --radius-pill: 999px;
    --radius-sm: 14px;
    --radius-element: 14px;
    --radius-container: 32px;

    /* Superficies claras */
    --surface-light: rgba(255, 255, 255, 0.80);
    --surface-light-hover: rgba(255, 255, 255, 0.93);
    --border-light: rgba(17, 17, 19, 0.08);
    --text-on-light: #16161a;
    --text-on-light-secondary: #6f6f76;
    --text-on-light-tertiary: #a4a4ab;
    /* Halo de legibilidad de noche para texto secundario/terciario dentro
       de tarjetas "glassy" (ver .card.light.glassy más abajo). Por
       defecto "none" -- no afecta a nada fuera de esas tarjetas. */
    --muted-text-shadow: none;

    /* Superficies oscuras (uso puntual: tarjeta "Información general") */
    --surface-dark: rgba(15, 15, 18, 0.82);
    --surface-dark-hover: rgba(15, 15, 18, 0.94);
    --border-dark: rgba(255, 255, 255, 0.10);
    --text-on-dark: #ffffff;
    --text-on-dark-secondary: rgba(255, 255, 255, 0.56);

    /* Alias genéricos usados por el resto del CSS de la app */
    --surface-1: var(--surface-light);
    --surface-2: var(--surface-light-hover);
    --surface-hover: var(--surface-light-hover);
    --border-subtle: var(--border-light);
    --border-medium: rgba(17, 17, 19, 0.16);
    --border-glow: rgba(17, 17, 19, 0.28);
    --text-primary: var(--text-on-light);
    --text-secondary: var(--text-on-light-secondary);
    --text-tertiary: var(--text-on-light-tertiary);
    --text-accent: var(--accent-blue);
    --text-success: #1e9e63;

    /* Acentos */
    --accent-amber: #f2a541;
    --accent-amber-bg: rgba(242, 165, 65, 0.16);
    --accent-blue: #4f7fe0;
    --accent-blue-bg: rgba(79, 127, 224, 0.14);
    --accent-primary: #111113;
    --accent-primary-hover: #2a2a2e;
    --accent-secondary: var(--accent-amber);
    --accent-active: #111113;

    /* Blur */
    --blur-sm: blur(10px);
    --blur-md: blur(22px);
    --blur-lg: blur(30px);
    --blur-xl: blur(40px);
    --blur-card: blur(22px);

    /* Sombras */
    --shadow-card: 0 22px 44px -16px rgba(10, 10, 15, 0.35);
    --shadow-dock: 0 20px 50px -10px rgba(0, 0, 0, 0.55);
    --shadow-inner-glow: inset 0 1px 1px 0 rgba(255, 255, 255, 0.5);

    --dock-bg: #111113;

    --formFont: clamp(11px, 1.55vw + 0.6dvh + 5px, 15px);
}

html{
    background: #0b1026;
}

body{
    min-height: 100vh;
    overflow-x: hidden;
    margin: 0;
    position: relative;
    color: var(--text-on-light);
}

.container{
    position: relative;
    width: 100%;
    z-index: 1;
}

/* Contenedor de contenido de cada página: por encima del cielo fijo
   (que pinta con z-index:0), sin alterar el layout interno de cada
   página (flex/alto fijo/etc. siguen definidos en el CSS de cada una). */
.main{
    position: relative;
    z-index: 1;
}

/*======================================================================
  Cielo animado de fondo — refleja la hora real del día (madrugada,
  amanecer, mediodía, atardecer, noche) y unas nubes que cruzan la
  pantalla. Vive fijo detrás de todo el contenido en cada página.
======================================================================*/
.sky{
    position: fixed;
    inset: 0;
    z-index: 0;
    overflow: hidden;
    background: #0b1026;
}

.sky-gradient{
    position: absolute;
    inset: -2%;
    background: linear-gradient(180deg,
        #0b1026 0%,
        #16213f 7%,
        #2c3c62 14%,
        #56638c 20%,
        #a9879a 25%,
        #f0a97e 30%,
        #ffd7a1 35%,
        #cfe6f2 41%,
        #9cd0ea 48%,
        #7fc0e6 55%,
        #9cd0ea 62%,
        #ffd7a1 69%,
        #f0a97e 74%,
        #a9879a 79%,
        #56638c 85%,
        #2c3c62 91%,
        #16213f 96%,
        #0b1026 100%
    );
    background-size: 100% 700%;
    background-position: 0% 0%;
    transition: background-position 4s ease;
}

.sky-dim{
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at 50% 20%, rgba(0,0,0,0) 0%, rgba(0,0,0,0.18) 100%);
    pointer-events: none;
}

.cloud{
    position: absolute;
    left: 0;
    background: radial-gradient(ellipse at center, var(--cloud-color, rgba(255,255,255,0.85)), rgba(255,255,255,0) 72%);
    filter: blur(18px);
    border-radius: 50%;
    mix-blend-mode: screen;
    transition: background 4s ease;
    animation-name: floatRTL;
    animation-timing-function: linear;
    animation-iteration-count: infinite;
}
.c1{ width:520px; height:170px; top:8%;  opacity:0.55; animation-duration:70s;  animation-delay:0s;   }
.c2{ width:380px; height:130px; top:20%; opacity:0.40; animation-duration:95s;  animation-delay:-25s; }
.c3{ width:620px; height:200px; top:38%; opacity:0.42; animation-duration:120s; animation-delay:-60s; }
.c4{ width:340px; height:120px; top:58%; opacity:0.32; animation-duration:80s;  animation-delay:-45s; }
.c5{ width:460px; height:150px; top:76%; opacity:0.30; animation-duration:105s; animation-delay:-10s; }
.c6{ width:300px; height:110px; top:48%; opacity:0.24; animation-duration:130s; animation-delay:-90s; }
@keyframes floatRTL{
    from{ transform: translateX(115vw); }
    to{ transform: translateX(-45vw); }
}

/*======================================================================
  Layout general de página (viewport, topbar, encabezado)
======================================================================*/
.viewport{
    position: relative;
    z-index: 1;
    max-width: 1400px;
    margin: 0 auto;
    padding: 32px 32px 130px;
}

.app-topbar{
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 28px;
    gap: 16px;
    flex-wrap: wrap;
}
.brand{ display: flex; align-items: center; gap: 12px; }
.brand-mark{
    /* Logo AG (2026-09-23): negro sobre fondos claros, verde sobre oscuros. */
    width: 64px;
    height: 34px;
    background: url('/assets/img/logo-ag-negro.png') left center / contain no-repeat;
    flex-shrink: 0;
}
html.bg-solid-dark .brand-mark{ background-image: url('/assets/img/logo-ag-verde.png'); }
.brand h1{ margin: 0; font-size: 1.15rem; font-weight: 800; letter-spacing: -0.01em; color: #111113; }

.topbar-right{ display: flex; align-items: center; gap: 10px; }
.btn-create{
    display: flex;
    align-items: center;
    gap: 6px;
    background: #111113;
    color: #fff;
    border: none;
    border-radius: var(--radius-pill);
    padding: 11px 18px 11px 14px;
    font-family: inherit;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    box-shadow: var(--shadow-card);
    text-decoration: none;
}
.icon-circle{
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--surface-light);
    -webkit-backdrop-filter: var(--blur-card);
    backdrop-filter: var(--blur-card);
    border: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #111113;
    cursor: pointer;
    transition: background .2s ease;
}
.icon-circle:hover{ background: var(--surface-light-hover); }
.avatar{
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #111113;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.8rem;
    border: 2px solid rgba(255,255,255,0.6);
}

.page-heading{ margin: 6px 0 26px; display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: 8px; }
.page-heading p{ margin: 0; font-size: 0.85rem; color: var(--text-on-light-secondary); text-shadow: var(--muted-text-shadow, none); font-weight: 500; }
.page-topbar-shell{ max-width: 1400px; margin: 0 auto; padding: 32px 32px 0; }
.page-heading h2{ margin: 0; font-size: 1.9rem; font-weight: 800; letter-spacing: -0.02em; color: #111113; }

.grid{ display: grid; grid-template-columns: repeat(12, 1fr); gap: 18px; }

/*======================================================================
  Tarjetas de vidrio (base compartida por toda la app)
======================================================================*/
.card{
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-card);
    padding: 22px;
    transition: background .2s ease, border-color .2s ease;
}
.card.light{
    background: var(--surface-light);
    -webkit-backdrop-filter: var(--blur-card);
    backdrop-filter: var(--blur-card);
    border: 1px solid var(--border-light);
    color: var(--text-on-light);
}
.card.light:hover{ background: var(--surface-light-hover); }
.card.dark{
    background: var(--surface-dark);
    -webkit-backdrop-filter: var(--blur-card);
    backdrop-filter: var(--blur-card);
    border: 1px solid var(--border-dark);
    color: var(--text-on-dark);
}
.card.dark:hover{ background: var(--surface-dark-hover); }

.card.light.glassy{
    /* Arreglo de legibilidad de noche (2026-09-17, quinta y última vuelta):
       las vueltas anteriores aplicaban la sombra a TODO el texto de la
       tarjeta (".card.light.glassy *"), incluyendo títulos y valores en
       negrita -- que ya se leían perfecto sin ayuda y quedaban con un
       borde/sombra que no debían tener (se veían "raros", menos nítidos
       que el negro plano de siempre).
       Esta vuelta ya NO toca el texto principal (títulos, valores en
       negrita) para nada -- ni color ni sombra -- se queda exactamente
       como se ve en el resto de la app.
       Solo el texto secundario/terciario (subtítulos y etiquetas como
       "FIRMADO", "DÍAS", "Próximos 60 días") se aclara acá, y su sombra
       se activa vía la variable --muted-text-shadow (definida en :root
       como "none" y sólo encendida acá adentro): cada regla del resto
       del CSS que pinta texto secundario/terciario ya trae también
       "text-shadow: var(--muted-text-shadow, none)" agregado a su lado,
       así que fuera de una tarjeta "glassy" esa sombra sigue apagada
       (no cambia nada en el resto de la app) y sólo se enciende acá,
       donde realmente hace falta. */
    background: rgba(255,255,255,0.30);
    backdrop-filter: blur(34px) saturate(160%);
    -webkit-backdrop-filter: blur(34px) saturate(160%);
    border: 1px solid rgba(255,255,255,0.38);

    --text-on-light-secondary: rgba(255, 255, 255, 0.82);
    --text-on-light-tertiary: rgba(255, 255, 255, 0.64);
    --muted-text-shadow: 0 1px 2px rgba(0, 0, 0, 0.7), 0 0 5px rgba(0, 0, 0, 0.32);
}
.card.light.glassy:hover{ background: rgba(255,255,255,0.42); }
.card.dark.glassy{
    background: rgba(15,15,18,0.34);
    backdrop-filter: blur(34px) saturate(160%);
    -webkit-backdrop-filter: blur(34px) saturate(160%);
    border: 1px solid rgba(255,255,255,0.18);
}
.card.dark.glassy:hover{ background: rgba(15,15,18,0.48); }

.card-head{ display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 16px; }
.card-head h3{ margin: 0; font-size: 1rem; font-weight: 800; letter-spacing: -0.01em; }
.head-icons{ display: flex; align-items: center; gap: 6px; }
.mini-icon-btn{
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    flex-shrink: 0;
}
.light .mini-icon-btn{ background: rgba(17,17,19,0.06); color: #111113; }
.dark .mini-icon-btn{ background: rgba(255,255,255,0.10); color: #fff; }

/*======================================================================
  Dock de navegación — fijo abajo, píldora negra sólida, lo más parecido
  posible al Dock de macOS: el ítem activo se expande mostrando su
  etiqueta, los demás muestran un tooltip flotante al pasar el mouse, y
  el dock se esconde al bajar la página y reaparece al subir.
======================================================================*/
.dock-wrap{
    position: fixed;
    bottom: 22px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    z-index: 1000;
    pointer-events: none;
    transform: translateY(140%);
    transition: transform .4s cubic-bezier(.34,1.56,.64,1);
}
.dock-wrap.visible{
    transform: translateY(0);
}
.dock{
    pointer-events: auto;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px;
    background: rgba(24,24,27,0.62);
    -webkit-backdrop-filter: blur(26px) saturate(180%);
    backdrop-filter: blur(26px) saturate(180%);
    border: 1px solid rgba(255,255,255,0.14);
    border-radius: 22px;
    box-shadow: var(--shadow-dock);
    max-width: calc(100vw - 24px);
    overflow: visible;
    scrollbar-width: none;
}
.dock::-webkit-scrollbar{ display: none; }
@media (max-width: 480px){
    /* En celulares no hay hover real con mouse (la magnificacion no
       aplica), asi que ahi si conviene volver a permitir scroll
       horizontal si el dock no entra en el ancho de pantalla. */
    .dock{ overflow-x: auto; overflow-y: hidden; }
}

.dock-item{
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    border-radius: 14px;
    background: rgba(255,255,255,0.07);
    color: rgba(255,255,255,0.65);
    text-decoration: none;
    cursor: pointer;
    flex-shrink: 0;
    transform-origin: bottom center;
    transition: transform .15s cubic-bezier(.22,1,.36,1), background .2s ease, color .2s ease;
}
.dock-item:hover{ background: rgba(255,255,255,0.16); color: #fff; }
.dock-item.active{
    background: #fff;
    color: #111113;
}
.dock-item.active::after{
    content: '';
    position: absolute;
    bottom: -7px;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: #fff;
}
.dock-item .dock-label{
    position: absolute;
    bottom: 100%;
    left: 50%;
    margin-bottom: 12px;
    font-size: 0.7rem;
    font-weight: 600;
    background: rgba(28,28,30,0.94);
    color: #fff;
    padding: 5px 10px;
    border-radius: 7px;
    white-space: nowrap;
    opacity: 0;
    transform: translateX(-50%) translateY(4px);
    transition: opacity .15s ease, transform .15s ease;
    pointer-events: none;
}
.dock-item .dock-label::after{
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: rgba(28,28,30,0.94);
}
.dock-item:hover .dock-label{ opacity: 1; transform: translateX(-50%) translateY(0); }
.dock-divider{ width: 1px; height: 32px; background: rgba(255,255,255,0.18); margin: 0 6px; }

@media (max-width: 620px){
    .dock{ gap: 2px; padding: 7px; }
    .dock-item{ width: 46px; height: 46px; }
}

/*------------- Utilidad reutilizable: superficie de vidrio -------------*/
.glass-surface{
    background: var(--surface-light);
    -webkit-backdrop-filter: var(--blur-md);
    backdrop-filter: var(--blur-md);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-card);
}

/* ================= Campanita de notificaciones (2026-09-23) =================
   Ver assets/js/notificaciones.js. */
.notif-bell{ position: relative; }
.notif-bell.is-open{ background: #111113; color: #fff; }
.notif-badge{
    position: absolute; top: -4px; right: -4px; min-width: 19px; height: 19px; padding: 0 5px;
    border-radius: 999px; background: #f2a541; color: #111113; border: 2px solid #fff;
    font-size: 0.64rem; font-weight: 900; line-height: 15px; text-align: center; box-sizing: border-box;
    animation: notif-pop .35s cubic-bezier(.2,.8,.2,1);
}
.notif-badge.has-overdue{ background: #e34948; color: #fff; }
.notif-badge[hidden]{ display: none; }
@keyframes notif-pop{ from{ transform: scale(.4); opacity: 0; } to{ transform: scale(1); opacity: 1; } }
.notif-panel{
    position: fixed; z-index: 5000; max-height: min(520px, calc(100vh - 120px)); display: none; flex-direction: column;
    background: rgba(17,17,19,0.96); color: #fff; border-radius: 20px; border: 1px solid rgba(255,255,255,0.1);
    box-shadow: 0 24px 60px rgba(0,0,0,0.35); overflow: hidden;
    -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px);
}
.notif-panel.open{ display: flex; animation: notif-in .18s ease-out; }
@keyframes notif-in{ from{ transform: translateY(-6px); opacity: 0; } to{ transform: none; opacity: 1; } }
.notif-head{ display: flex; justify-content: space-between; align-items: baseline; gap: 10px; padding: 16px 18px 10px; }
.notif-head strong{ font-size: 0.95rem; font-weight: 800; }
.notif-head span{ font-size: 0.72rem; font-weight: 600; color: rgba(255,255,255,0.55); }
.notif-list{ overflow-y: auto; padding: 0 8px 8px; }
.notif-group{ font-size: 0.62rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.04em; color: rgba(255,255,255,0.45); padding: 10px 10px 4px; }
.notif-item{
    width: 100%; display: flex; align-items: center; gap: 10px; padding: 10px; border: none; border-radius: 12px;
    background: transparent; color: #fff; text-align: left; cursor: pointer; font: inherit;
}
.notif-item:hover, .notif-item:focus{ outline: none; background: rgba(255,255,255,0.08); }
.notif-dot{ width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; background: #f2a541; }
.notif-item.is-vencido .notif-dot{ background: #e34948; }
.notif-body{ flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.notif-body strong{ font-size: 0.8rem; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.notif-body span{ font-size: 0.7rem; color: rgba(255,255,255,0.55); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.notif-days{ flex-shrink: 0; font-size: 0.68rem; font-weight: 800; padding: 3px 8px; border-radius: 999px; background: rgba(242,165,65,0.18); color: #f2a541; }
.notif-item.is-vencido .notif-days{ background: rgba(227,73,72,0.2); color: #ff7a79; }
.notif-empty{ padding: 18px 18px 22px; font-size: 0.8rem; color: rgba(255,255,255,0.7); }
.notif-foot{ padding: 10px 18px 14px; font-size: 0.66rem; color: rgba(255,255,255,0.4); border-top: 1px solid rgba(255,255,255,0.08); }

/* ================= Menú de usuario + fondo sólido (2026-09-23) =================
   Ver assets/js/user-avatar.js. */
.avatar.um-trigger{ cursor: pointer; overflow: hidden; transition: box-shadow .15s ease; }
.avatar.um-trigger:hover, .avatar.um-trigger:focus{ outline: none; box-shadow: 0 0 0 3px rgba(242,165,65,0.55); }
.avatar.has-photo{ padding: 0; background: #111113; }
.avatar.has-photo img{ width: 100%; height: 100%; object-fit: cover; display: block; }

.um-panel{
    position: fixed; z-index: 5000; display: none; flex-direction: column; gap: 4px;
    max-height: calc(100vh - 100px); overflow-y: auto;
    background: rgba(17,17,19,0.96); color: #fff; border-radius: 20px; border: 1px solid rgba(255,255,255,0.1);
    box-shadow: 0 24px 60px rgba(0,0,0,0.35); padding: 16px;
    -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px);
}
.um-panel.open{ display: flex; animation: notif-in .18s ease-out; }
.um-head{ display: flex; align-items: center; gap: 12px; padding-bottom: 12px; border-bottom: 1px solid rgba(255,255,255,0.08); }
.um-avatar{ width: 52px; height: 52px; border-radius: 50%; overflow: hidden; flex-shrink: 0; background: rgba(255,255,255,0.12); display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 1.05rem; }
.um-avatar img{ width: 100%; height: 100%; object-fit: cover; }
.um-id{ min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.um-id strong{ font-size: 0.92rem; font-weight: 800; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.um-id span{ font-size: 0.72rem; color: rgba(255,255,255,0.55); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.um-id .um-company{ color: #f2a541; font-weight: 700; }
.um-section{ padding: 12px 0 4px; }
.um-label{ font-size: 0.62rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.04em; color: rgba(255,255,255,0.45); margin-bottom: 8px; }
.um-row{ display: flex; gap: 8px; flex-wrap: wrap; }
.um-rol{ display: inline-block; margin-top: 4px; padding: 2px 8px; border-radius: 999px; font-size: 0.66rem; font-weight: 700; background: rgba(255,255,255,0.12); color: rgba(255,255,255,0.85); }
.um-hint{ font-weight: 500; text-transform: none; letter-spacing: 0; opacity: 0.7; }
.um-logo-prev{ margin-bottom: 8px; padding: 8px 12px; border-radius: 10px; background: #fff; display: flex; align-items: center; justify-content: center; height: 56px; }
.um-logo-prev img{ max-width: 100%; max-height: 40px; object-fit: contain; }
.um-btn{ display: inline-flex; align-items: center; padding: 8px 12px; border-radius: 10px; border: none; background: #fff; color: #111113; font: inherit; font-size: 0.76rem; font-weight: 700; cursor: pointer; }
.um-btn.ghost{ background: rgba(255,255,255,0.1); color: #fff; }
.um-seg, .um-langs{ display: flex; padding: 3px; border-radius: 12px; background: rgba(255,255,255,0.08); gap: 2px; }
.um-seg button, .um-langs button{ flex: 1; min-width: 0; border: none; background: transparent; color: rgba(255,255,255,0.75); padding: 7px 6px; border-radius: 9px; font: inherit; font-size: 0.74rem; font-weight: 700; cursor: pointer; }
.um-seg button.active, .um-langs button.active{ background: #fff; color: #111113; }
.um-langs button:disabled{ opacity: 0.45; cursor: default; }
.um-langs small{ font-size: 0.58rem; font-weight: 700; opacity: 0.8; }
.um-link{ margin-top: 6px; border: none; background: none; padding: 2px 0; color: rgba(255,255,255,0.7); font: inherit; font-size: 0.72rem; text-decoration: underline; cursor: pointer; }
.um-link:hover{ color: #fff; }
.um-colores[hidden]{ display: none; }
.um-sublabel{ margin: 12px 0 0; font-size: 0.64rem; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; color: rgba(255,255,255,0.5); }
.um-texturas{ display: grid; grid-template-columns: repeat(7, 1fr); gap: 7px; margin-top: 8px; }
.um-swatches{ display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; margin-top: 10px; }
.um-swatches[hidden]{ display: none; }
.um-swatch{ position: relative; aspect-ratio: 1; border-radius: 50%; border: 2px solid rgba(255,255,255,0.18); cursor: pointer; padding: 0; }
.um-swatch.active{ border-color: #f2a541; box-shadow: 0 0 0 2px rgba(242,165,65,0.35); }
.um-swatch.um-jaguar{ background: #d6a04e url('/assets/img/fondo-jaguar.svg') center / 70px 70px; }
.bg-fade{ position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: 1; transition: opacity 1.5s ease; }
.um-swatch.um-rotar{ background: conic-gradient(#d6a04e, #d8261c, #f4f1ea, #9a5424, #1c8a5a, #e0569a, #2d5047, #d6a04e); }
.um-swatch.um-rotar::after{ content: '↻'; position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: #fff; font-size: 1.05rem; font-weight: 800; text-shadow: 0 1px 4px rgba(0,0,0,0.7); }
.um-swatch.um-delfin{ background: #2d5047 url('/assets/img/fondo-delfin.jpg') 8% 20% / 200px 200px; }
.um-swatch.um-condor{ background: #1a1a1e url('/assets/img/fondo-condor.jpg') 30% 12% / 170px 170px; }
.um-swatch.um-ranas{ background: #2c6a36 url('/assets/img/fondo-ranas.jpg') 15% 8% / 190px 190px; }
.um-swatch.um-cocodrilo{ background: #4e5a28 url('/assets/img/fondo-cocodrilo.jpg') 20% 20% / 170px 170px; }
.um-swatch.um-orquidea{ background: #1a3a26 url('/assets/img/fondo-orquidea.jpg') 30% 38% / 130px 130px; }
.um-swatch.um-colibri{ background: #1c8a5a url('/assets/img/fondo-colibri.jpg') 35% 10% / 200px 200px; }
.um-swatch.um-armadillo{ background: #9c8b78 url('/assets/img/fondo-armadillo.jpg') 50% 50% / 160px 160px; }
.um-swatch.um-oso{ background: #1a1410 url('/assets/img/fondo-oso.jpg') 18% 18% / 150px 150px; }
.um-swatch.um-tortuga{ background: #8a6a30 url('/assets/img/fondo-tortuga.jpg') 50% 50% / 110px 114px; }
.um-swatch.um-jirafa{ background: #9a5424 url('/assets/img/fondo-jirafa.png') 35% 45% / 100px 100px; }
.um-swatch.um-cebra{ background: #f4f1ea url('/assets/img/fondo-cebra.png') 30% 40% / 150px 150px; }
.um-swatch.um-guacamaya{ background: #d8261c url('/assets/img/fondo-guacamaya.svg') 40% 42% / 160px 131px; }
.um-custom input{ position: absolute; inset: 0; opacity: 0; width: 100%; height: 100%; cursor: pointer; border: none; padding: 0; }
.um-msg{ margin: 8px 0 0; font-size: 0.72rem; color: #f2a541; }
.um-msg[hidden]{ display: none; }
.um-logout{ margin-top: 12px; padding: 10px; border-radius: 12px; border: none; background: rgba(227,73,72,0.16); color: #ff7a79; font: inherit; font-size: 0.8rem; font-weight: 800; cursor: pointer; }
.um-logout:hover{ background: rgba(227,73,72,0.26); }

/* Fondo de un solo color (preferencia del usuario) */
html.bg-solid, html.bg-solid body, html.bg-solid .sky{ background: var(--solid-bg); }
html.bg-solid .sky-gradient, html.bg-solid .sky-dim, html.bg-solid .cloud{ display: none; }
/* Fondo "Jaguar" (2026-09-24): rosetas de jaguar con un velo oscuro encima
   para que el texto blanco se lea. */
html.bg-jaguar, html.bg-jaguar body{ background: #6b4a22; }
html.bg-jaguar .sky{
    background:
        linear-gradient(180deg, rgba(22,13,5,0.30) 0%, rgba(22,13,5,0.46) 100%),
        url('/assets/img/fondo-jaguar.svg') 0 0 / 460px 460px repeat,
        #6b4a22;
}
/* Fondo "Guacamaya" (2026-09-24): plumaje de guacamaya bandera. */
html.bg-guacamaya, html.bg-guacamaya body{ background: #5a0d0a; }
html.bg-guacamaya .sky{
    background:
        linear-gradient(180deg, rgba(18,6,6,0.30) 0%, rgba(18,6,6,0.46) 100%),
        url('/assets/img/fondo-guacamaya.svg') 0 0 / 644px 528px repeat,
        #5a0d0a;
}
/* Fondo "Cebra" (2026-09-24): rayas de cebra; velo más fuerte porque el
   blanco y negro tienen mucho contraste. */
html.bg-cebra, html.bg-cebra body{ background: #2a2a2e; }
html.bg-cebra .sky{
    background:
        linear-gradient(180deg, rgba(12,12,14,0.42) 0%, rgba(12,12,14,0.56) 100%),
        url('/assets/img/fondo-cebra.png') 0 0 / 640px 640px repeat,
        #2a2a2e;
}
/* Fondo "Jirafa" (2026-09-24): manchas de jirafa. */
html.bg-jirafa, html.bg-jirafa body{ background: #5e3417; }
html.bg-jirafa .sky{
    background:
        linear-gradient(180deg, rgba(22,11,4,0.32) 0%, rgba(22,11,4,0.48) 100%),
        url('/assets/img/fondo-jirafa.png') 0 0 / 640px 640px repeat,
        #5e3417;
}
/* Fondo "Tortuga" (2026-09-24): placas del caparazón con anillos. */
html.bg-tortuga, html.bg-tortuga body{ background: #3b2e16; }
html.bg-tortuga .sky{
    background:
        linear-gradient(180deg, rgba(16,12,4,0.26) 0%, rgba(16,12,4,0.42) 100%),
        url('/assets/img/fondo-tortuga.jpg') 0 0 / 640px 665px repeat,
        #3b2e16;
}
/* Fondo "Oso de anteojos" (2026-09-24): pelaje oscuro con marcas crema. */
html.bg-oso, html.bg-oso body{ background: #1a1410; }
html.bg-oso .sky{
    background:
        linear-gradient(180deg, rgba(10,8,6,0.18) 0%, rgba(10,8,6,0.34) 100%),
        url('/assets/img/fondo-oso.jpg') 0 0 / 640px 640px repeat,
        #1a1410;
}
/* Fondo "Armadillo" (2026-09-24): bandas del caparazón. */
html.bg-armadillo, html.bg-armadillo body{ background: #4a3e33; }
html.bg-armadillo .sky{
    background:
        linear-gradient(180deg, rgba(16,12,8,0.30) 0%, rgba(16,12,8,0.46) 100%),
        url('/assets/img/fondo-armadillo.jpg') 0 0 / 640px 640px repeat,
        #4a3e33;
}
/* Fondo "Colibrí" (2026-09-24): plumaje iridiscente verde, turquesa y violeta. */
html.bg-colibri, html.bg-colibri body{ background: #0d3b2c; }
html.bg-colibri .sky{
    background:
        linear-gradient(180deg, rgba(4,14,12,0.28) 0%, rgba(4,14,12,0.44) 100%),
        url('/assets/img/fondo-colibri.jpg') 0 0 / 640px 640px repeat,
        #0d3b2c;
}
/* Fondo "Orquídeas" (2026-09-24): orquídeas sobre follaje. */
html.bg-orquidea, html.bg-orquidea body{ background: #10261a; }
html.bg-orquidea .sky{
    background:
        linear-gradient(180deg, rgba(6,12,8,0.24) 0%, rgba(6,12,8,0.42) 100%),
        url('/assets/img/fondo-orquidea.jpg') 0 0 / 640px 640px repeat,
        #10261a;
}
/* Fondo "Cocodrilo" (2026-09-24): escamas de cocodrilo. */
html.bg-cocodrilo, html.bg-cocodrilo body{ background: #1f2812; }
html.bg-cocodrilo .sky{
    background:
        linear-gradient(180deg, rgba(8,10,4,0.26) 0%, rgba(8,10,4,0.44) 100%),
        url('/assets/img/fondo-cocodrilo.jpg') 0 0 / 640px 640px repeat,
        #1f2812;
}
/* Fondo "Ranitas doradas" (2026-09-24): ranitas doradas sobre hojas de selva. */
html.bg-ranas, html.bg-ranas body{ background: #0e2616; }
html.bg-ranas .sky{
    background:
        linear-gradient(180deg, rgba(4,12,6,0.22) 0%, rgba(4,12,6,0.40) 100%),
        url('/assets/img/fondo-ranas.jpg') 0 0 / 640px 640px repeat,
        #0e2616;
}
/* Fondo "Cóndor" (2026-09-24): plumaje negro con la franja blanca del ala. */
html.bg-condor, html.bg-condor body{ background: #0e0e11; }
html.bg-condor .sky{
    background:
        linear-gradient(180deg, rgba(6,6,8,0.34) 0%, rgba(6,6,8,0.50) 100%),
        url('/assets/img/fondo-condor.jpg') 0 0 / 640px 640px repeat,
        #0e0e11;
}
/* Fondo "Delfín rosado" (2026-09-24): botos en el río. */
html.bg-delfin, html.bg-delfin body{ background: #123030; }
html.bg-delfin .sky{
    background:
        linear-gradient(180deg, rgba(4,12,12,0.22) 0%, rgba(4,12,12,0.40) 100%),
        url('/assets/img/fondo-delfin.jpg') 0 0 / 640px 640px repeat,
        #123030;
}
html.bg-delfin .brand h1, html.bg-delfin .page-heading h2, html.bg-delfin .page-heading p,
html.bg-condor .brand h1, html.bg-condor .page-heading h2, html.bg-condor .page-heading p,
html.bg-ranas .brand h1, html.bg-ranas .page-heading h2, html.bg-ranas .page-heading p,
html.bg-cocodrilo .brand h1, html.bg-cocodrilo .page-heading h2, html.bg-cocodrilo .page-heading p,
html.bg-orquidea .brand h1, html.bg-orquidea .page-heading h2, html.bg-orquidea .page-heading p,
html.bg-colibri .brand h1, html.bg-colibri .page-heading h2, html.bg-colibri .page-heading p,
html.bg-armadillo .brand h1, html.bg-armadillo .page-heading h2, html.bg-armadillo .page-heading p,
html.bg-oso .brand h1, html.bg-oso .page-heading h2, html.bg-oso .page-heading p,
html.bg-tortuga .brand h1, html.bg-tortuga .page-heading h2, html.bg-tortuga .page-heading p,
html.bg-jirafa .brand h1, html.bg-jirafa .page-heading h2, html.bg-jirafa .page-heading p,
html.bg-cebra .brand h1, html.bg-cebra .page-heading h2, html.bg-cebra .page-heading p,
html.bg-jaguar .brand h1, html.bg-guacamaya .brand h1,
html.bg-jaguar .page-heading h2, html.bg-guacamaya .page-heading h2,
html.bg-jaguar .page-heading p, html.bg-guacamaya .page-heading p{ text-shadow: 0 1px 8px rgba(0,0,0,0.55); }
/* Tarjetas de vidrio: sobre un color plano el efecto vidrio no aporta y
   puede dejar texto con poco contraste -- se vuelven sólidas. */
html.bg-solid .card.light.glassy{
    background: rgba(255,255,255,0.88);
    border-color: rgba(17,17,19,0.08);
    --text-on-light-secondary: #6f6f76;
    --text-on-light-tertiary: #a4a4ab;
    --muted-text-shadow: none;
}
html.bg-solid .card.dark.glassy{ background: rgba(15,15,18,0.9); }
/* Texto que va directo sobre el fondo: blanco si el color es oscuro. */
html.bg-solid-dark .brand h1,
html.bg-solid-dark .page-heading h2{ color: #fff; }
html.bg-solid-dark .page-heading p{ color: rgba(255,255,255,0.72); }
/* Home -> "Metas del mes" usa texto blanco con sombra pensado para el
   cielo; con fondo sólido la tarjeta queda clara, así que va en oscuro. */
html.bg-solid .goal-item span.label{ color: #6f6f76; text-shadow: none; }
html.bg-solid .goal-item.done span.label{ color: #111113; text-shadow: none; }
html.bg-solid .goal-check{ border-color: rgba(17,17,19,0.3); }
html.bg-solid .goal-add{ color: #6f6f76; text-shadow: none; border-color: rgba(17,17,19,0.2); }
html.bg-solid .goal-item .goal-remove:hover{ color: #111113; background: rgba(17,17,19,0.08); }
