/* =====================================================
   Tarjeta Vecina — Hoja de Estilos Principal
   Paleta:
     --color-primary   : Azul institucional (#1a3b70)
     --color-accent    : Amarillo vibrante  (#ffd100)
     --color-bg        : Gris claro         (#f0f4f8)
     --color-surface   : Blanco             (#ffffff)
     --color-text      : Gris oscuro        (#1e293b)
     --color-text-muted: Gris medio         (#64748b)
   ===================================================== */

/* ----- Reset y variables globales ----- */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --color-primary: #1a3b70;
    --color-primary-dark: #122958;
    --color-primary-light: #2451a0;
    --color-accent: #ffd100;
    --color-accent-dark: #e6bc00;
    --color-bg: #f0f4f8;
    --color-surface: #ffffff;
    --color-text: #1e293b;
    --color-text-muted: #64748b;
    --color-border: #e2e8f0;

    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --radius-pill: 999px;

    --shadow-sm: 0 1px 3px rgba(0, 0, 0, .08), 0 1px 2px rgba(0, 0, 0, .06);
    --shadow-md: 0 4px 16px rgba(26, 59, 112, .10), 0 2px 6px rgba(0, 0, 0, .06);
    --shadow-hover: 0 12px 32px rgba(26, 59, 112, .18), 0 4px 12px rgba(0, 0, 0, .08);

    --transition-fast: 200ms ease;
    --transition-med: 300ms ease;

    --font-family: 'Inter', system-ui, -apple-system, sans-serif;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family);
    background-color: #f2f5fc;
    color: var(--color-text);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow-x: hidden;
}

/* Figura geométrica superior izquierda (Cuadro inclinado en azul municipal) */
body::before {
    content: "";
    position: fixed;
    top: -110px;
    left: -90px;
    width: 440px;
    height: 440px;
    border-radius: 46px;
    background: linear-gradient(135deg, rgba(36, 81, 160, 0.14) 0%, rgba(13, 42, 90, 0.03) 100%);
    transform: rotate(-18deg);
    box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, 0.6);
    pointer-events: none;
    z-index: -2;
    animation: bgFloatTopLeft 18s ease-in-out infinite alternate;
}

/* Figura geométrica superpuesta en amarillo dorado */
body::after {
    content: "";
    position: fixed;
    top: 50px;
    left: -40px;
    width: 260px;
    height: 260px;
    border-radius: 36px;
    background: linear-gradient(135deg, rgba(255, 209, 0, 0.18) 0%, rgba(230, 126, 34, 0.04) 100%);
    transform: rotate(12deg);
    box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, 0.5);
    pointer-events: none;
    z-index: -1;
    animation: bgFloatTopLeftAccent 14s ease-in-out infinite alternate;
}

/* Capa de figuras geométricas secundarias en esquinas */
.bg-decor-wrapper {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: -3;
    overflow: hidden;
}

.bg-shape-tr {
    position: absolute;
    top: -90px;
    right: -110px;
    width: 460px;
    height: 460px;
    border-radius: 48px;
    background: linear-gradient(135deg, rgba(41, 128, 185, 0.1) 0%, rgba(36, 81, 160, 0.02) 100%);
    transform: rotate(22deg);
    box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, 0.6);
    animation: bgFloatTopRight 20s ease-in-out infinite alternate;
}

.bg-shape-br {
    position: absolute;
    bottom: -150px;
    right: -90px;
    width: 520px;
    height: 520px;
    border-radius: 54px;
    background: linear-gradient(135deg, rgba(255, 209, 0, 0.12) 0%, rgba(36, 81, 160, 0.05) 100%);
    transform: rotate(-15deg);
    box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, 0.5);
    animation: bgFloatBottomRight 24s ease-in-out infinite alternate;
}

.bg-shape-bl {
    position: absolute;
    bottom: -120px;
    left: -120px;
    width: 400px;
    height: 400px;
    border-radius: 44px;
    background: linear-gradient(135deg, rgba(142, 68, 173, 0.08) 0%, rgba(36, 81, 160, 0.02) 100%);
    transform: rotate(16deg);
    box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, 0.5);
    animation: bgFloatBottomLeft 16s ease-in-out infinite alternate;
}

/* Keyframes para animaciones flotantes sutiles del fondo */
@keyframes bgFloatTopLeft {
    0% {
        transform: rotate(-18deg) translate(0, 0);
    }
    100% {
        transform: rotate(-14deg) translate(18px, 14px);
    }
}

@keyframes bgFloatTopLeftAccent {
    0% {
        transform: rotate(12deg) translate(0, 0);
    }
    100% {
        transform: rotate(17deg) translate(-14px, 12px);
    }
}

@keyframes bgFloatTopRight {
    0% {
        transform: rotate(22deg) translate(0, 0);
    }
    100% {
        transform: rotate(18deg) translate(-20px, 16px);
    }
}

@keyframes bgFloatBottomRight {
    0% {
        transform: rotate(-15deg) translate(0, 0);
    }
    100% {
        transform: rotate(-10deg) translate(-16px, -18px);
    }
}

@keyframes bgFloatBottomLeft {
    0% {
        transform: rotate(16deg) translate(0, 0);
    }
    100% {
        transform: rotate(20deg) translate(14px, -12px);
    }
}

@media (prefers-reduced-motion: reduce) {
    body::before,
    body::after,
    .bg-shape-tr,
    .bg-shape-br,
    .bg-shape-bl {
        animation: none !important;
    }
}

/* ----- Contenedor general ----- */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}


/* =====================================================
   HEADER — Barra única: logo + nav links
   ===================================================== */
.site-header {
    background: var(--color-primary-light);
    border-bottom: 2px solid var(--color-accent);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 60px;
    gap: 1.5rem;
}

.header-brand {
    display: flex;
    align-items: center;
    gap: .85rem;
    flex-shrink: 0;
}

/* Logo: tamaño ajustado a la barra de 60px */
.header-logo {
    height: 44px;
    width: auto;
    object-fit: contain;
    filter: drop-shadow(0 1px 4px rgba(0, 0, 0, .3));
}

.header-label {
    display: block;
    font-size: .68rem;
    font-weight: 500;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--color-accent);
    line-height: 1;
}

/* H1: nombre del programa en la barra */
.header-title {
    font-size: 1.1rem;
    font-weight: 800;
    color: #fff;
    margin-top: .15rem;
    line-height: 1;
}

.header-text {
    display: none;
}

/* Contenedor de navegación principal */
.site-nav {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

/* Botones de control del menú móvil (ocultos en escritorio) */
.menu-toggle,
.menu-close {
    display: none;
}

.nav-overlay {
    display: none;
}

/* Links de nav dentro del header */
.navbar-links {
    display: flex;
    align-items: center;
    gap: .15rem;
    list-style: none;
    margin: 0;
    padding: 0;
    height: 100%;
}

.navbar-link {
    color: rgba(255, 255, 255, .82);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    padding: .3rem .7rem;
    border-radius: var(--radius-pill);
    white-space: nowrap;
    transition: color var(--transition-fast), background var(--transition-fast);
}

.navbar-link:hover {
    color: #fff;
    background: rgba(255, 255, 255, .12);
}

/* CTA: botón amarillo */
.navbar-cta {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    background: var(--color-accent);
    color: var(--color-primary-dark);
    font-size: 0.95rem;
    font-weight: 700;
    text-decoration: none;
    padding: .35rem .9rem;
    border-radius: var(--radius-pill);
    white-space: nowrap;
    flex-shrink: 0;
    transition: background var(--transition-fast), transform var(--transition-fast);
}

.navbar-cta:hover {
    background: var(--color-accent-dark);
    transform: translateY(-1px);
}

/* =====================================================
   HERO — Banner Principal Imagen
   ===================================================== */
.hero-banner-container {
    width: 100%;
    max-width: 1200px;
    margin: 2rem auto 0;
    aspect-ratio: 4 / 1;
    border-radius: var(--radius-lg);
    overflow: hidden;
    line-height: 0;
    box-shadow: var(--shadow-md);
}

.hero-banner-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}




/* =====================================================
   SECCIÓN INTRODUCTORIA
   ===================================================== */
.intro-section {
    text-align: center;
    padding: 3rem 0 2rem;
}

.intro-badge {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    background: var(--color-primary);
    color: var(--color-accent);
    font-size: .8125rem;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
    padding: .35rem 1rem;
    border-radius: var(--radius-pill);
    margin-bottom: 1rem;
}

.intro-title {
    font-size: 2rem;
    font-weight: 800;
    color: var(--color-primary);
    margin-bottom: .75rem;
}

.intro-text {
    font-size: 1rem;
    color: var(--color-text-muted);
    max-width: 560px;
    margin: 0 auto;
}

/* =====================================================
   CATEGORÍAS — Contenedor de todas las secciones
   ===================================================== */
.categorias-wrapper {
    display: flex;
    flex-direction: column;
    gap: 3rem;
    padding-bottom: 4rem;
}

/* Encabezado de categoría: icono + título + controles */
.categoria-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: .75rem 0 .75rem;
}

/* Círculo del ícono de categoría */
.categoria-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    flex-shrink: 0;
}

.categoria-title {
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--color-text);
    line-height: 1.2;
}

.categoria-count {
    font-size: .78rem;
    color: var(--color-text-muted);
    margin-top: .1rem;
}

/* Contenedor relativo de ancho completo */
.carousel-wrapper {
    position: relative;
    width: 100%;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid var(--color-border);
    background: var(--color-surface);
    color: var(--color-text);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    z-index: 10;
    transition: all var(--transition-fast);
}

.carousel-btn svg {
    stroke: var(--color-text);
    transition: stroke var(--transition-fast);
}

.carousel-btn:hover {
    background: var(--color-primary);
    border-color: var(--color-primary);
}

.carousel-btn:hover svg {
    stroke: #fff;
}

.carousel-btn--left {
    left: -22px;
}

.carousel-btn--right {
    right: -22px;
}



/* =====================================================
   CARRUSEL — Scroll horizontal con snap
   Cada card ocupa un ancho fijo; el contenedor
   hace scroll suave al llamar a scrollCarousel().
   ===================================================== */
.carousel {
    display: flex;
    gap: 1.25rem;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding: .75rem 5px 1.25rem;
    /* Padding horizontal mínimo para que no se corten las sombras */
    scroll-padding: 0 5px;
    /* Alineación del scroll-snap con el padding */
    scrollbar-width: none;
    /* Firefox */
}

.carousel::-webkit-scrollbar {
    display: none;
    /* Chrome / Safari */
}


/* =====================================================
   CARD — Tarjeta individual de empresa
   Ancho fijo para que el scroll funcione correctamente.
   ===================================================== */
.card {
    flex: 0 0 310px;
    scroll-snap-align: start;
    background: var(--color-surface);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transition: transform var(--transition-med), box-shadow var(--transition-med);
    border: 1px solid var(--color-border);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

/* Contenedor del logotipo sobre fondo blanco puro */
.card-image-wrapper {
    position: relative;
    width: 100%;
    height: 180px;
    overflow: hidden;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.25rem;
    border-bottom: 1px solid var(--color-border);
}

.card-img {
    max-width: 90%;
    max-height: 90%;
    width: auto;
    height: auto;
    object-fit: contain;
    transition: transform var(--transition-med);
}

.card:hover .card-img {
    transform: scale(1.06);
}

/* Sombreado degradado desactivado para ver la imagen nítida */
.card-image-overlay {
    display: none;
}

/* Badge de descuento flotante (acortado con puntos suspensivos si es extenso) */
.card-badge {
    position: absolute;
    top: 0.75rem;
    left: 0.75rem;
    max-width: calc(100% - 1.5rem);
    display: flex;
    align-items: center;
    gap: 0.35rem;
    color: white;
    background: var(--color-accent);
    font-size: 0.7rem;
    font-weight: 800;
    padding: 0.35rem 0.65rem;
    border-radius: var(--radius-sm);
    z-index: 2;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
    text-transform: uppercase;
    white-space: nowrap;
    overflow: hidden;
}

.card-badge i {
    font-size: 0.75rem;
    flex-shrink: 0;
}

.card-badge span {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: inline-block;
    max-width: 100%;
}

/* Cuerpo informativo de la tarjeta (debajo de la foto nítida) */
.card-content-body {
    padding: 1.1rem 1.1rem 0.85rem;
    background: #ffffff;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.45rem;
    flex-grow: 1;
}

.card-name {
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--color-text);
    line-height: 1.25;
    margin: 0;
    text-shadow: none;
}

.card-category {
    display: inline-block;
    font-size: 0.65rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding: 0.2rem 0.6rem;
    border-radius: var(--radius-sm);
    color: #fff;
}

/* Footer de la card: dirección */
.card-footer {
    display: flex;
    align-items: flex-start;
    gap: .45rem;
    padding-top: 0.65rem;
    margin-top: auto;
    width: 100%;
    border-top: 1px solid var(--color-border);
    background: transparent;
}

.card-pin {
    color: var(--color-text-muted);
    font-size: .8rem;
    margin-top: .15rem;
    flex-shrink: 0;
}

.card-address {
    font-style: normal;
    font-size: .78rem;
    color: var(--color-text-muted);
    line-height: 1.5;
}



/* =====================================================
   FOOTER
   ===================================================== */
.site-footer {
    background: var(--color-primary-light);
    color: rgba(255, 255, 255, .75);
    padding: 1.75rem 0;
    margin-top: auto;
}

.footer-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: .35rem;
    text-align: center;
}

.footer-copy {
    font-size: .875rem;
    font-weight: 500;
    color: rgba(255, 255, 255, .9);
}

.footer-legal {
    font-size: .75rem;
    opacity: .65;
}

/* =====================================================
   RESPONSIVE BREAKPOINTS
   Ajustes específicos para pantallas pequeñas.
   ===================================================== */

/* Tablet y dispositivos medianos */
@media (max-width: 768px) {

    /* Navbar: reducir padding en tablet */
    .navbar-link {
        padding: 0 .55rem;
        font-size: .75rem;
    }

    .header-inner {
        height: 60px;
        gap: 0.75rem;
    }


    .header-title {
        font-size: 1.25rem;
    }

    .header-logo {
        height: 56px;
    }

    /* Hero: ocultar tarjeta decorativa en tablet */
    .hero-card {
        display: none;
    }

    .hero-title {
        font-size: 2.1rem;
    }

    .hero {
        padding: 2.5rem 0;
    }

    .intro-title {
        font-size: 1.625rem;
    }

    .cards-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
        gap: 1.25rem;
    }
}



/* Móviles pequeños */
@media (max-width: 480px) {


    /* Header: barra única compacta con botón menú hamburguesa */
    .header-inner {
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        height: 60px;
        padding: 0 1rem;
    }

    .header-logo {
        height: 38px;
    }

    .header-label {
        font-size: 0.58rem;
        letter-spacing: 0.05em;
    }

    .header-title {
        font-size: 0.95rem;
        margin-top: 0.1rem;
    }

    /* Botón de apertura del menú lateral (hamburguesa) */
    .menu-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
        background: transparent;
        border: none;
        color: #fff;
        cursor: pointer;
        padding: 0.5rem;
        transition: color var(--transition-fast);
    }

    .menu-toggle:hover {
        color: var(--color-accent);
    }

    /* Menú lateral (Drawer Sidebar) */
    .site-nav {
        position: fixed;
        top: 0;
        right: 0;
        bottom: 0;
        width: 270px;
        background: var(--color-primary-light);
        z-index: 1000;
        display: flex;
        flex-direction: column;
        padding: 4.5rem 1.5rem 2rem;
        gap: 2.25rem;
        box-shadow: -8px 0 25px rgba(0, 0, 0, 0.35);
        transform: translateX(101%);
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        align-items: flex-start;
    }

    .site-nav.open {
        transform: translateX(0);
    }

    /* Botón de cierre dentro del panel lateral */
    .menu-close {
        display: flex;
        position: absolute;
        top: 1.25rem;
        right: 1.25rem;
        background: transparent;
        border: none;
        color: rgba(255, 255, 255, 0.7);
        cursor: pointer;
        padding: 0.5rem;
        align-items: center;
        justify-content: center;
        transition: color var(--transition-fast);
    }

    .menu-close:hover {
        color: #fff;
    }

    /* Enlaces de navegación apilados verticalmente en el sidebar */
    .navbar-links {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 1.25rem;
        width: 100%;
        height: auto;
    }

    .navbar-link {
        font-size: 1.05rem;
        font-weight: 600;
        color: rgba(255, 255, 255, 0.85);
        padding: 0.4rem 0;
        width: 100%;
        display: block;
        white-space: nowrap;
        border-radius: 0;
    }

    .navbar-link:hover {
        color: var(--color-accent);
        background: transparent;
    }

    /* Botón CTA dentro del menú lateral */
    .navbar-cta {
        width: 100%;
        justify-content: center;
        padding: 0.65rem;
        font-size: 0.9rem;
        margin-left: 0;
        margin-bottom: 0;
    }

    /* Fondo oscuro difuminado al abrir el menú */
    .nav-overlay {
        display: block;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(13, 42, 90, 0.65);
        backdrop-filter: blur(4px);
        z-index: 999;
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.3s ease;
    }

    .nav-overlay.open {
        opacity: 1;
        pointer-events: auto;
    }




    /* Hero: apilar en columna en móvil */
    .hero-inner {
        flex-direction: column;
    }

    .hero-card {
        display: block;
        width: 100%;
        max-width: 280px;
        margin: 0 auto;
    }

    .hero-title {
        font-size: 1.75rem;
    }

    .hero-desc {
        font-size: .9rem;
    }

    .hero-actions {
        flex-direction: column;
    }

    .hero-btn {
        justify-content: center;
    }

    .intro-title {
        font-size: 1.375rem;
    }

    .cards-grid {
        grid-template-columns: 1fr;
    }

    .carousel-btn {
        display: none;
    }

    .carousel {
        padding: .5rem 15px 1rem;
        scroll-padding: 0 15px;
    }
}


/* =====================================================
   FORMULARIO DE REGISTRO DE EMPRESAS — Diseño Moderno
   ===================================================== */
.form-container {
    max-width: 900px;
    margin: 0 auto;
}

/* Banner de Registro */
.register-banner-wrapper {
    width: 100%;
    max-width: 1200px;
    height: auto;
    aspect-ratio: 4 / 1;
    /* Proporción 1200x300 */
    border-radius: var(--radius-lg);
    overflow: hidden;
    margin-bottom: 2rem;
    box-shadow: var(--shadow-md);
}

.register-banner-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Invitación / Info Alert */
.register-info-alert {
    display: flex;
    gap: 1.25rem;
    background: rgba(26, 59, 112, 0.05);
    border-left: 4px solid var(--color-primary);
    padding: 1.5rem;
    border-radius: var(--radius-md);
    margin-bottom: 2.5rem;
}

.info-alert-icon {
    font-size: 1.5rem;
    color: var(--color-primary);
    flex-shrink: 0;
    margin-top: 0.1rem;
}

.info-alert-lead {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--color-primary-dark);
    margin-bottom: 0.5rem;
}

.info-alert-text {
    font-size: 0.92rem;
    color: var(--color-text-muted);
    line-height: 1.6;
}

/* Tarjeta del Formulario */
.register-card {
    background: var(--color-surface);
    border-radius: var(--radius-lg);
    box-shadow: 0 10px 30px rgba(26, 59, 112, 0.06);
    border: 1px solid var(--color-border);
    overflow: hidden;
    margin-bottom: 4rem;
}

.register-card-header {
    background: var(--color-primary-light);
    padding: 2.5rem 2rem;
    color: #fff;
    text-align: center;
    border-bottom: 3px solid var(--color-accent);
}

.register-card-title {
    font-size: 1.75rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin-bottom: 0.5rem;
}

.register-card-subtitle {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.75);
}

.register-card-body {
    padding: 3rem 2.5rem;
}

/* Estructura de Filas del Formulario */
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.form-group {
    margin-bottom: 1.75rem;
}

.form-label {
    display: block;
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--color-text);
    margin-bottom: 0.55rem;
}

/* Wrapper del Input con Icono */
.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
}

.input-icon {
    position: absolute;
    left: 1.25rem;
    color: var(--color-text-muted);
    font-size: 1.1rem;
    pointer-events: none;
    transition: color var(--transition-fast);
}

/* Input y Select */
.form-input,
.form-select {
    width: 100%;
    padding: 0.85rem 1.25rem 0.85rem 2.85rem;
    font-family: var(--font-family);
    font-size: 0.95rem;
    color: var(--color-text);
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
    outline: none;
}

.form-select {
    appearance: none;
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1.25rem center;
}

.form-input::placeholder {
    color: #94a3b8;
}

.input-wrapper--textarea {
    align-items: flex-start;
}

.input-wrapper--textarea .input-icon {
    top: 1rem;
}

textarea.form-input {
    resize: vertical;
    min-height: 110px;
    padding-top: 0.85rem;
}

/* Focus, Valid e Invalid States */
.form-input:focus,
.form-select:focus {
    border-color: var(--color-primary-light);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(36, 81, 160, 0.12);
}

.input-wrapper:focus-within .input-icon {
    color: var(--color-primary-light);
}

.input-wrapper.is-valid .form-input,
.input-wrapper.is-valid .form-select {
    border-color: #10b981;
    background: #f0fdf4;
}

.input-wrapper.is-valid .input-icon {
    color: #10b981;
}

.input-wrapper.is-invalid .form-input,
.input-wrapper.is-invalid .form-select {
    border-color: #ef4444;
    background: #fef2f2;
}

.input-wrapper.is-invalid .input-icon {
    color: #ef4444;
}

/* Textos de Error */
.error-text {
    display: block;
    font-size: 0.78rem;
    font-weight: 600;
    color: #ef4444;
    margin-top: 0.4rem;
    min-height: 1rem;
}

/* Contenedor del Botón Submit */
.form-submit-container {
    margin-top: 2rem;
    text-align: center;
}

.btn-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.65rem;
    background: var(--color-accent);
    color: var(--color-primary-dark);
    font-size: 1.05rem;
    font-weight: 800;
    border: none;
    padding: 1rem 2.5rem;
    border-radius: var(--radius-pill);
    cursor: pointer;
    transition: all var(--transition-fast);
    box-shadow: 0 4px 14px rgba(255, 209, 0, 0.3);
}

.btn-submit:hover:not(:disabled) {
    background: var(--color-accent-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 209, 0, 0.4);
}

.btn-submit:disabled {
    background: #e2e8f0;
    color: #94a3b8;
    cursor: not-allowed;
    box-shadow: none;
}

.btn-submit:disabled .btn-icon {
    opacity: 0.5;
}

/* Overlay de Carga Moderno */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(13, 42, 90, 0.85);
    backdrop-filter: blur(5px);
    z-index: 99999;
    display: none;
    justify-content: center;
    align-items: center;
}

.loading-content {
    text-align: center;
    color: #fff;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255, 255, 255, 0.1);
    border-top-color: var(--color-accent);
    border-radius: 50%;
    animation: spin 1s infinite linear;
    margin: 0 auto 1.25rem;
}

.loading-text {
    font-size: 1.1rem;
    font-weight: 700;
    letter-spacing: -0.01em;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* =====================================================
   RESPONSIVE PARA EL FORMULARIO DE REGISTRO
   ===================================================== */
@media (max-width: 768px) {
    .form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .register-card-body {
        padding: 2rem 1.5rem;
    }

    .register-card-header {
        padding: 2rem 1.5rem;
    }
}

@media (max-width: 480px) {
    .register-banner-wrapper {
        border-radius: var(--radius-md);
        margin-bottom: 1.5rem;
        aspect-ratio: auto;
        height: 180px;
    }

    .register-info-alert {
        padding: 1.15rem;
        gap: 0.85rem;
        margin-bottom: 2rem;
    }

    .info-alert-lead {
        font-size: 0.98rem;
    }

    .info-alert-text {
        font-size: 0.85rem;
    }

    .register-card-title {
        font-size: 1.4rem;
    }

    .btn-submit {
        width: 100%;
        padding: 0.85rem 1.5rem;
        font-size: 0.95rem;
    }
}


/* Modal de Agradecimiento */
.thanks-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(13, 42, 90, 0.7);
    backdrop-filter: blur(5px);
    z-index: 100000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.thanks-modal.open {
    opacity: 1;
    pointer-events: auto;
}

.thanks-modal-content {
    background: var(--color-surface);
    border-radius: var(--radius-lg);
    width: 90%;
    max-width: 480px;
    padding: 2.5rem 2rem;
    text-align: center;
    box-shadow: 0 20px 50px rgba(13, 42, 90, 0.15);
    border: 1px solid var(--color-border);
    transform: translateY(20px);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.thanks-modal.open .thanks-modal-content {
    transform: translateY(0);
}

.thanks-modal-icon {
    font-size: 3.5rem;
    color: #10b981;
    margin-bottom: 1.25rem;
    animation: scaleUp 0.4s ease-out;
}

.thanks-modal-title {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--color-primary-dark);
    margin-bottom: 0.75rem;
}

.thanks-modal-text {
    font-size: 0.95rem;
    color: var(--color-text-muted);
    line-height: 1.6;
    margin-bottom: 1.75rem;
}

.btn-thanks-close {
    background: var(--color-primary);
    color: #fff;
    font-size: 0.95rem;
    font-weight: 700;
    border: none;
    padding: 0.75rem 2rem;
    border-radius: var(--radius-pill);
    cursor: pointer;
    transition: all var(--transition-fast);
    box-shadow: 0 4px 10px rgba(26, 59, 112, 0.2);
}

.btn-thanks-close:hover {
    background: var(--color-primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 6px 15px rgba(26, 59, 112, 0.3);
}

@keyframes scaleUp {
    0% {
        transform: scale(0.8);
        opacity: 0;
    }

    100% {
        transform: scale(1);
        opacity: 1;
    }
}


/* =====================================================
   ESTILOS ESPECÍFICOS PARA LA SOLICITUD DE TARJETA
   ===================================================== */

/* Alerta Residencia Celeste Desvanecida */
.register-info-alert.alert-residencia {
    background: rgba(41, 128, 185, 0.08);
    border-left: 4px solid #2980b9;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.info-alert-icon--residencia {
    color: #2980b9;
}

.info-alert-lead--residencia {
    color: #1b4f72;
}

/* Lista de documentos */
.residencia-list {
    margin-top: 0.75rem;
    list-style: none;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

.residencia-list li {
    font-size: 0.9rem;
    color: var(--color-text);
    position: relative;
    padding-left: 1.25rem;
    line-height: 1.4;
}

.residencia-list li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.45rem;
    width: 6px;
    height: 6px;
    background-color: #2980b9;
    border-radius: 50%;
}


/* Caja de carga de archivos (File Upload) */
.file-upload-wrapper {
    width: 100%;
}

.file-upload-zone {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border: 2px dashed #cbd5e1;
    background: #f8fafc;
    border-radius: var(--radius-md);
    padding: 2.5rem 1.5rem;
    text-align: center;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.file-upload-zone:hover {
    border-color: var(--color-primary-light);
    background: #f1f5f9;
}

.file-upload-icon {
    font-size: 2.5rem;
    color: var(--color-text-muted);
    margin-bottom: 1rem;
    transition: color var(--transition-fast);
}

.file-upload-zone:hover .file-upload-icon {
    color: var(--color-primary-light);
}

.file-upload-title {
    display: block;
    font-size: 1rem;
    font-weight: 700;
    color: var(--color-text);
    margin-bottom: 0.35rem;
}

.file-upload-desc {
    display: block;
    font-size: 0.8rem;
    color: var(--color-text-muted);
}

.file-upload-input {
    display: none;
}

/* Previsualización del archivo cargado */
.file-preview-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #f0fdf4;
    border: 1px solid #10b981;
    border-radius: var(--radius-md);
    padding: 1rem 1.25rem;
    transition: all var(--transition-fast);
}

.file-preview-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.file-type-icon {
    font-size: 2.2rem;
}

.file-type-icon--pdf {
    color: #ef4444;
}

.file-type-icon--image {
    color: #3b82f6;
}

.file-name {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--color-text);
    word-break: break-all;
    line-height: 1.2;
}

.file-size {
    font-size: 0.75rem;
    color: var(--color-text-muted);
    margin-top: 0.15rem;
}

.btn-remove-file {
    background: transparent;
    border: none;
    color: #64748b;
    font-size: 1.25rem;
    cursor: pointer;
    padding: 0.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color var(--transition-fast);
}

.btn-remove-file:hover {
    color: #ef4444;
}


/* =====================================================
   ESTILOS DE LOGIN Y CUENTA DE USUARIO
   ===================================================== */

/* Botón "Mi Cuenta" en el header */
.navbar-login {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    background: transparent;
    border: 2px solid var(--color-accent);
    color: #fff;
    font-size: 0.95rem;
    font-weight: 700;
    text-decoration: none;
    padding: .3rem .9rem;
    border-radius: var(--radius-pill);
    white-space: nowrap;
    flex-shrink: 0;
    transition: background var(--transition-fast), color var(--transition-fast), transform var(--transition-fast);
}

.navbar-login:hover {
    background: var(--color-accent);
    color: var(--color-primary);
    transform: translateY(-1px);
}

/* --- LOGIN PAGE --- */
.login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: calc(100vh - 180px);
    /* Ajustado según header/footer */
    padding: 2rem 1.5rem;
}

.login-card {
    background: var(--color-surface);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    width: 100%;
    max-width: 420px;
    overflow: hidden;
}

.login-card-header {
    background: linear-gradient(135deg, var(--color-primary-light), var(--color-primary));
    color: #fff;
    padding: 2rem;
    text-align: center;
}

.login-logo {
    height: 60px;
    margin-bottom: 1rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.login-title {
    font-size: 1.5rem;
    font-weight: 800;
    margin-bottom: .25rem;
}

.login-subtitle {
    font-size: .85rem;
    color: rgba(255, 255, 255, 0.8);
}

.login-card-body {
    padding: 2rem;
}

.login-form-group {
    margin-bottom: 1.25rem;
}

.login-form-label {
    display: block;
    font-size: .85rem;
    font-weight: 600;
    margin-bottom: .4rem;
    color: var(--color-text);
}

.login-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.login-input-icon {
    position: absolute;
    left: 1rem;
    color: var(--color-text-muted);
    font-size: .95rem;
}

.login-input {
    width: 100%;
    padding: .75rem 1rem .75rem 2.5rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    font-family: var(--font-family);
    font-size: .9rem;
    color: var(--color-text);
    background: #f8fafc;
    transition: border-color var(--transition-fast), background var(--transition-fast), box-shadow var(--transition-fast);
}

.login-input:focus {
    outline: none;
    border-color: var(--color-primary-light);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(36, 81, 160, 0.15);
}

.login-btn {
    width: 100%;
    padding: .85rem;
    background: var(--color-primary-light);
    color: #fff;
    border: none;
    border-radius: var(--radius-sm);
    font-family: var(--font-family);
    font-size: .95rem;
    font-weight: 700;
    cursor: pointer;
    transition: background var(--transition-fast), transform var(--transition-fast);
    margin-top: 1rem;
}

.login-btn:hover {
    background: var(--color-primary);
}

.login-btn:active {
    transform: scale(0.98);
}

.login-footer-text {
    text-align: center;
    margin-top: 1.5rem;
    font-size: .8rem;
    color: var(--color-text-muted);
}

.login-footer-text a {
    color: var(--color-primary-light);
    text-decoration: none;
    font-weight: 600;
}

.login-footer-text a:hover {
    text-decoration: underline;
}

.clave-unica-btn {
    width: auto !important;
    min-width: 220px;
    margin: 0 auto;
    background: var(--color-primary-light);
    color: #fff;
    box-shadow: 0 4px 12px rgba(36, 81, 160, 0.25);
    transition: background var(--transition-fast), transform var(--transition-fast), box-shadow var(--transition-fast);
}

.clave-unica-btn:hover {
    background: var(--color-primary) !important;
    box-shadow: 0 6px 16px rgba(26, 59, 112, 0.35);
    transform: translateY(-2px);
}

/* --- DASHBOARD PAGE (MI CUENTA) --- */
.dashboard-layout {
    display: flex;
    min-height: calc(100vh - 60px);
    background: #f0f4f8;
}

/* Sidebar */
.dashboard-sidebar {
    width: 280px;
    background: var(--color-primary-light);
    color: #fff;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    border-right: 1px solid rgba(255, 255, 255, 0.1);
    transition: width var(--transition-med);
}

@media (min-width: 769px) {

    /* Estilos del Sidebar Colapsado */
    .dashboard-sidebar.collapsed {
        width: 80px;
    }

    .dashboard-sidebar.collapsed .sidebar-user-name {
        display: none;
    }

    .dashboard-sidebar.collapsed .sidebar-user-header {
        justify-content: center;
        padding: 1.25rem 0.5rem;
    }

    .dashboard-sidebar.collapsed .sidebar-back-btn i {
        transform: rotate(180deg);
    }

    .dashboard-sidebar.collapsed .sidebar-link span {
        display: none;
    }

    .dashboard-sidebar.collapsed .sidebar-link {
        justify-content: center;
        padding: 1rem 0;
    }
}

.sidebar-user-header {
    background: var(--color-primary-light);
    padding: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 2px solid var(--color-accent);
}

.sidebar-user-name {
    font-size: .95rem;
    font-weight: 700;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 180px;
}

.sidebar-back-btn {
    color: #fff;
    background: rgba(255, 255, 255, 0.15);
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    text-decoration: none;
    transition: background var(--transition-fast), transform var(--transition-fast);
}

.sidebar-back-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateX(-2px);
}

.sidebar-menu {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-menu-item {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.25rem;
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    font-size: .9rem;
    font-weight: 600;
    cursor: pointer;
    background: transparent;
    width: 100%;
    border: none;
    text-align: left;
    transition: background var(--transition-fast), color var(--transition-fast);
}

.sidebar-link:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
}

.sidebar-link.active {
    background: var(--color-primary);
    color: var(--color-accent);
    box-shadow: inset 4px 0 0 var(--color-accent);
}

.sidebar-link i {
    font-size: 1.1rem;
    width: 24px;
    text-align: center;
    flex-shrink: 0;
}

/* Panel de Contenido */
.dashboard-content-panel {
    flex-grow: 1;
    padding: 2.5rem;
    background: #ffffff;
}

.panel-section {
    display: none;
}

.panel-section.active {
    display: block;
    animation: fadeIn 300ms ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.panel-title {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--color-primary);
    margin-bottom: 0.5rem;
}

.panel-divider {
    height: 2px;
    background: var(--color-border);
    margin-bottom: 2rem;
    border: none;
}

/* --- VISTA: MIS DATOS --- */
.user-data-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-top: 1rem;
}

.user-data-card {
    background: #f8fafc;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 1.25rem 1.5rem;
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.user-data-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

.data-label {
    font-size: .8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: var(--color-text-muted);
    margin-bottom: .25rem;
}

.data-value {
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--color-text);
}

/* --- VISTA: MI TARJETA VECINA --- */
.card-section-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2.5rem;
}

/* Maquetación del espacio de la Tarjeta */
.virtual-card-mockup {
    width: 100%;
    max-width: 480px;
    aspect-ratio: 1.63 / 1;
    background: linear-gradient(135deg, #004ea6, #003673);
    border-radius: var(--radius-lg);
    box-shadow: 0 10px 25px rgba(0, 78, 166, 0.25);
    padding: 2rem;
    color: #fff;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
    border: 2px solid rgba(255, 255, 255, 0.1);
}

.virtual-card-mockup::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -20%;
    width: 120%;
    height: 120%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.08) 0%, transparent 60%);
    pointer-events: none;
}

.card-header-logo {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    width: 100%;
}

.card-muni-info {
    line-height: 1.1;
}

.card-muni-label {
    font-size: .65rem;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--color-accent);
    font-weight: 700;
}

.card-muni-title {
    font-size: 1rem;
    font-weight: 800;
}

.card-chip {
    width: 40px;
    height: 30px;
    background: linear-gradient(135deg, #ffd100, #b89700);
    border-radius: 6px;
}

.card-body-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    width: 100%;
    margin-top: auto;
}

.card-holder-details {
    max-width: 65%;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.card-holder-name {
    font-size: 1.2rem;
    font-weight: 700;
    line-height: 1.2;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.card-holder-rut {
    font-size: 0.9rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.85);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
    letter-spacing: 0.02em;
}

.card-qr-placeholder {
    width: 90px;
    height: 90px;
    background: #ffffff;
    border-radius: var(--radius-sm);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--color-primary);
    font-size: .8rem;
    font-weight: 800;
    box-shadow: var(--shadow-sm);
    border: 4px solid #fff;
}

.card-qr-icon {
    font-size: 2.2rem;
    margin-bottom: 2px;
}

/* Tabla de Movimientos */
.table-wrapper {
    width: 100%;
    overflow-x: auto;
    margin-top: 1rem;
}

.movements-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--color-text);
    text-align: center;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: .05em;
}

.movements-table {
    width: 100%;
    border-collapse: collapse;
    font-size: .9rem;
    text-align: left;
}

.movements-table th {
    background: var(--color-primary-light);
    color: #fff;
    padding: .85rem 1rem;
    font-weight: 700;
    border: 1px solid var(--color-primary-light);
}

.movements-table td {
    padding: .85rem 1rem;
    border: 1px solid var(--color-border);
    color: var(--color-text);
}

.movements-table tr:nth-child(even) {
    background-color: #f8fafc;
}

.movements-table tr:hover {
    background-color: rgba(26, 59, 112, 0.03);
}

.discount-badge {
    display: inline-block;
    padding: .2rem .6rem;
    background: #eefcf3;
    color: #15803d;
    font-weight: 700;
    font-size: .8rem;
    border-radius: var(--radius-pill);
    border: 1px solid #bbf7d0;
}

/* --- RESPONSIVE ADJUSTMENTS FOR DASHBOARD --- */
@media (max-width: 768px) {
    .dashboard-layout {
        flex-direction: column;
    }

    .dashboard-sidebar {
        width: 100%;
        border-right: none;
        border-bottom: 2px solid var(--color-border);
        background: var(--color-primary-light);
    }

    /* Cabecera compacta en móviles */
    .sidebar-user-header {
        padding: 0.75rem 1.25rem;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .sidebar-user-name {
        font-size: 0.85rem;
        max-width: 100%;
        text-align: center;
    }

    .sidebar-back-btn {
        display: none !important;
        /* El botón de colapso no se usa en móviles */
    }

    /* Menú en formato de barra de pestañas horizontal */
    .sidebar-menu {
        display: flex;
        flex-direction: row;
        width: 100%;
        background: var(--color-primary-light);
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        flex-wrap: nowrap;
        scrollbar-width: none;
        /* Para Firefox */
    }

    .sidebar-menu::-webkit-scrollbar {
        display: none;
        /* Para Chrome, Safari y Opera */
    }

    .sidebar-menu-item {
        flex: 0 0 auto;
        /* No encoger las pestañas */
        min-width: 130px;
        /* Ancho mínimo para cada botón */
        border-bottom: none;
        border-right: 1px solid rgba(255, 255, 255, 0.08);
    }

    .sidebar-menu-item:last-child {
        border-right: none;
    }

    .sidebar-link {
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 0.3rem;
        padding: 0.75rem 0.5rem;
        font-size: 0.75rem;
        text-align: center;
        white-space: nowrap;
        border-radius: 0;
    }

    .sidebar-link.active {
        background: rgba(255, 255, 255, 0.1);
        color: var(--color-accent);
        box-shadow: inset 0 -3px 0 var(--color-accent);
        /* Línea amarilla en la parte inferior */
    }

    .sidebar-link i {
        font-size: 1rem;
        width: auto;
        margin-bottom: 0;
    }

    .dashboard-content-panel {
        padding: 1.5rem 1rem;
    }

    .virtual-card-mockup {
        padding: 1.25rem;
    }

    .card-holder-name {
        font-size: 1.05rem;
    }

    .card-qr-placeholder {
        width: 75px;
        height: 75px;
    }

    .card-qr-icon {
        font-size: 1.75rem;
    }
}


/* =====================================================
   TUTORIAL "¿CÓMO OBTENERLA?" — Estilos Visuales
   ===================================================== */
.tutorial-container {
    max-width: 850px;
    margin: 0 auto;
}

.tutorial-header {
    text-align: center;
    margin-bottom: 3.5rem;
}

.tutorial-main-title {
    font-size: 2.25rem;
    font-weight: 800;
    color: var(--color-primary-dark);
    margin-bottom: 0.5rem;
    letter-spacing: -0.02em;
}

.tutorial-main-subtitle {
    font-size: 1.05rem;
    color: var(--color-text-muted);
}

/* Timeline */
.tutorial-timeline {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    position: relative;
    margin-bottom: 4rem;
}

.tutorial-step {
    display: flex;
    gap: 2rem;
}

.step-badge {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex-shrink: 0;
    width: 48px;
}

.step-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    background: var(--color-primary-light);
    color: #fff;
    font-size: 1.25rem;
    font-weight: 800;
    border-radius: 50%;
    border: 3px solid #fff;
    box-shadow: var(--shadow-sm);
    z-index: 2;
}

.step-line {
    width: 4px;
    background: #e2e8f0;
    flex-grow: 1;
    margin-top: 0.5rem;
    margin-bottom: -1.5rem;
    z-index: 1;
}

.step-card {
    flex-grow: 1;
    background: var(--color-surface);
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);
    box-shadow: 0 4px 15px rgba(26, 59, 112, 0.03);
    padding: 2rem;
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.step-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(26, 59, 112, 0.07);
}

.step-card-icon {
    font-size: 2rem;
    color: var(--color-primary-light);
    background: rgba(36, 81, 160, 0.08);
    width: 60px;
    height: 60px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.step-card-content {
    flex-grow: 1;
}

.step-title {
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--color-primary-dark);
    margin-bottom: 0.6rem;
    letter-spacing: -0.01em;
}

.step-desc {
    font-size: 0.98rem;
    color: var(--color-text-muted);
    line-height: 1.6;
}

/* Caja de Llamado a la Acción (CTA) Final */
.como-cta-box {
    background: linear-gradient(135deg, var(--color-primary-light) 0%, var(--color-primary-dark) 100%);
    border-radius: var(--radius-lg);
    padding: 3rem 2.5rem;
    text-align: center;
    color: #fff;
    box-shadow: 0 15px 35px rgba(18, 41, 88, 0.15);
    position: relative;
    overflow: hidden;
    z-index: 1;
}

/* Efecto de fondo */
.como-cta-box::before {
    content: "";
    position: absolute;
    top: -50px;
    right: -50px;
    width: 250px;
    height: 250px;
    background: rgba(255, 209, 0, 0.06);
    border-radius: 50%;
    z-index: -1;
}

.como-cta-icon {
    font-size: 3rem;
    color: var(--color-accent);
    margin-bottom: 1.25rem;
}

.como-cta-title {
    font-size: 1.85rem;
    font-weight: 800;
    margin-bottom: 0.75rem;
    letter-spacing: -0.01em;
}

.como-cta-desc {
    font-size: 1.05rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 2rem;
}

.como-cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    background: var(--color-accent);
    color: var(--color-primary-dark);
    font-size: 1.1rem;
    font-weight: 800;
    padding: 1rem 3rem;
    border-radius: var(--radius-pill);
    text-decoration: none;
    transition: all var(--transition-fast);
    box-shadow: 0 4px 15px rgba(255, 209, 0, 0.3);
}

.como-cta-btn:hover {
    background: var(--color-accent-dark);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 209, 0, 0.4);
}

/* Responsivo para el timeline */
@media (max-width: 768px) {
    .tutorial-step {
        gap: 1rem;
    }

    .step-badge {
        width: 36px;
    }

    .step-number {
        width: 36px;
        height: 36px;
        font-size: 1rem;
    }

    .step-card {
        padding: 1.5rem;
        gap: 1rem;
        flex-direction: column;
    }

    .step-card-icon {
        width: 50px;
        height: 50px;
        font-size: 1.5rem;
    }

    .como-cta-box {
        padding: 2.5rem 1.5rem;
    }

    .como-cta-title {
        font-size: 1.5rem;
    }

    .como-cta-btn {
        width: 100%;
        justify-content: center;
    }
}


/* =====================================================
   CATÁLOGO UNIFICADO CON FILTRO DINÁMICO — Estilos
   ===================================================== */
.filter-container {
    width: 100%;
    margin-bottom: 2.5rem;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.filter-select-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
    max-width: 400px;
}

.filter-select-icon {
    position: absolute;
    left: 1.25rem;
    color: var(--color-primary-light);
    font-size: 1rem;
    pointer-events: none;
    z-index: 2;
}

.filter-select {
    width: 100%;
    padding: 0.85rem 1rem 0.85rem 2.75rem;
    font-size: 1rem;
    font-weight: 600;
    color: var(--color-text);
    background-color: var(--color-surface);
    border: 2px solid var(--color-border);
    border-radius: var(--radius-pill);
    box-shadow: 0 4px 15px rgba(26, 59, 112, 0.04);
    cursor: pointer;
    outline: none;
    transition: all var(--transition-fast);
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%232451a0' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1.25rem center;
    background-size: 16px;
}

.filter-select:hover {
    border-color: var(--color-primary-light);
    box-shadow: 0 6px 20px rgba(26, 59, 112, 0.08);
}

.filter-select:focus {
    border-color: var(--color-primary-light);
    box-shadow: 0 0 0 3px rgba(36, 81, 160, 0.15);
}

/* Buscador de Beneficios */
.search-box-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
    max-width: 450px;
}

.search-icon {
    position: absolute;
    left: 1.25rem;
    color: var(--color-text-muted);
    font-size: 1rem;
    pointer-events: none;
    z-index: 2;
}

.search-input {
    width: 100%;
    padding: 0.85rem 1rem 0.85rem 2.75rem;
    font-size: 1rem;
    font-weight: 500;
    color: var(--color-text);
    background-color: var(--color-surface);
    border: 2px solid var(--color-border);
    border-radius: var(--radius-pill);
    box-shadow: 0 4px 15px rgba(26, 59, 112, 0.04);
    outline: none;
    transition: all var(--transition-fast);
    font-family: var(--font-family);
}

.search-input:hover {
    border-color: var(--color-primary-light);
    box-shadow: 0 6px 20px rgba(26, 59, 112, 0.08);
}

.search-input:focus {
    border-color: var(--color-primary-light);
    box-shadow: 0 0 0 3px rgba(36, 81, 160, 0.15);
    background-color: #fff;
}

/* Mensaje sin resultados */
.no-results-message {
    text-align: center;
    padding: 4rem 2rem;
    background: var(--color-surface);
    border-radius: var(--radius-lg);
    border: 1px dashed var(--color-border);
    max-width: 600px;
    margin: 2rem auto 5rem;
    box-shadow: var(--shadow-sm);
    animation: fadeIn 300ms ease-out forwards;
}

.no-results-icon {
    font-size: 3.5rem;
    color: var(--color-text-muted);
    margin-bottom: 1.25rem;
}

.no-results-title {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--color-primary-dark);
    margin-bottom: 0.5rem;
}

.no-results-text {
    font-size: 0.95rem;
    color: var(--color-text-muted);
    line-height: 1.5;
}

/* Grilla de Tiendas */
.empresas-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(275px, 1fr));
    gap: 2rem;
    margin-bottom: 5rem;
    animation: fadeIn 300ms ease-out forwards;
}

.empresas-grid .card {
    height: 100%;
    display: flex;
    flex-direction: column;
    margin: 0;
}

/* Ajustes de responsividad */
@media (max-width: 640px) {
    .filter-container {
        flex-direction: column;
        gap: 1rem;
    }

    .search-box-wrapper,
    .filter-select-wrapper {
        max-width: 100%;
    }

    .empresas-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}


/* ============================================================
   TARJETA HOVER CTA
   ============================================================ */
.card-clickable {
    cursor: pointer;
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.card-clickable:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 40px rgba(26, 59, 112, 0.14);
}

.card-hover-cta {
    position: absolute;
    bottom: 0.75rem;
    right: 0.75rem;
    background: rgba(255, 255, 255, 0.22);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    color: #fff;
    font-size: 0.78rem;
    font-weight: 700;
    padding: 0.35rem 0.85rem;
    border-radius: var(--radius-pill);
    border: 1px solid rgba(255, 255, 255, 0.3);
    display: flex;
    align-items: center;
    gap: 0.4rem;
    opacity: 0;
    transform: translateY(6px);
    transition: opacity 200ms ease, transform 200ms ease;
    letter-spacing: 0.02em;
    pointer-events: none;
}

.card-clickable:hover .card-hover-cta,
.card-clickable:focus .card-hover-cta {
    opacity: 1;
    transform: translateY(0);
}


/* ============================================================
   MODAL PREMIUM DE COMERCIO — Tarjeta Vecina
   ============================================================ */

/* Keyframe de apertura */
@keyframes slideUpModal {
    from {
        opacity: 0;
        transform: translateY(40px) scale(0.97);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Overlay */
.comercio-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(7, 16, 34, 0.72);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1.25rem;
}

.comercio-modal-overlay.is-open {
    display: flex;
}

.comercio-modal-overlay.is-open .comercio-modal {
    animation: slideUpModal 320ms cubic-bezier(0.34, 1.40, 0.64, 1) both;
}

/* Caja modal */
.comercio-modal {
    background: var(--color-surface);
    border-radius: 24px;
    width: 100%;
    max-width: 820px;
    max-height: 92vh;
    overflow-y: auto;
    overflow-x: hidden;
    box-shadow: 0 32px 80px rgba(7, 16, 34, 0.35), 0 0 0 1px rgba(255, 255, 255, 0.08);
    position: relative;
    scroll-behavior: smooth;
    animation: slideUpModal 320ms cubic-bezier(0.34, 1.40, 0.64, 1) both;
}

.comercio-modal::-webkit-scrollbar {
    width: 5px;
}

.comercio-modal::-webkit-scrollbar-track {
    background: transparent;
}

.comercio-modal::-webkit-scrollbar-thumb {
    background: var(--color-border);
    border-radius: 4px;
}

/* Barra superior estática del modal */
.comercio-modal-top-bar {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 1.75rem 0.5rem;
    background: #ffffff;
    border-radius: 24px 24px 0 0;
}

/* Sello Tarjeta Vecina en la barra superior */
.comercio-modal-sello {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    background: rgba(13, 42, 90, 0.06);
    border: 1px solid rgba(13, 42, 90, 0.14);
    color: var(--color-primary-dark);
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.35rem 0.9rem;
    border-radius: var(--radius-pill);
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.comercio-modal-sello i {
    font-size: 0.85rem;
    color: var(--color-primary);
}

/* Botón cerrar modal */
.comercio-modal-close {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #f1f5f9;
    border: 1px solid var(--color-border);
    color: #0f172a;
    font-size: 1.1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 180ms ease, transform 180ms ease;
}

.comercio-modal-close:hover {
    background: #e2e8f0;
    transform: scale(1.08);
}

/* Cuerpo del modal */
.comercio-modal-body {
    padding: 1.5rem 1.75rem 2.25rem;
}

/* Encabezado del comercio: Logo + Título + Categoría */
.comercio-modal-brand-header {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--color-border);
    margin-bottom: 1.75rem;
}

/* Caja para el logo / PORTE LOGO */
.comercio-modal-logo-box {
    width: 170px;
    height: 170px;
    min-width: 170px;
    border-radius: 20px;
    background: #ffffff;
    border: 1px solid var(--color-border);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.06);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.4rem;
    overflow: hidden;
}

.comercio-modal-logo-img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
}

/* Detalles del nombre y categoría */
.comercio-modal-brand-details {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.4rem;
    flex: 1;
}

.comercio-modal-cat-badge {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding: 0.25rem 0.75rem;
    border-radius: var(--radius-pill);
    color: #fff;
}

.comercio-modal-nombre {
    font-size: clamp(1.4rem, 4vw, 1.85rem);
    font-weight: 900;
    color: var(--color-text);
    margin: 0;
    line-height: 1.2;
}

/* Descripción del comercio a ancho completo */
.comercio-modal-desc-wrap {
    margin-bottom: 1.75rem;
}

.comercio-modal-desc {
    font-size: 0.94rem;
    color: #475569;
    line-height: 1.65;
    margin: 0;
    border-left: 3.5px solid var(--color-primary-light);
    background: #f8fafc;
    padding: 0.85rem 1.15rem;
    border-radius: 0 10px 10px 0;
    border: 1px solid #e2e8f0;
    border-left-width: 3.5px;
    font-style: normal;
}

@media (max-width: 576px) {
    .comercio-modal-top-bar {
        padding: 1rem 1.25rem 0.25rem;
    }

    .comercio-modal-body {
        padding: 1.25rem 1.25rem 2rem;
    }

    .comercio-modal-brand-header {
        flex-direction: row;
        align-items: center;
        gap: 1rem;
        padding-bottom: 1rem;
        margin-bottom: 1rem;
    }

    .comercio-modal-logo-box {
        width: 75px;
        height: 75px;
        min-width: 75px;
        border-radius: 14px;
        padding: 0.4rem;
    }

    .comercio-modal-desc-wrap {
        margin-bottom: 1.25rem;
    }

    .comercio-modal-desc {
        font-size: 0.88rem;
        padding: 0.75rem 0.9rem;
        line-height: 1.55;
    }
}

/* Secciones */
.comercio-modal-section {
    margin-bottom: 2rem;
}

.comercio-modal-section-title {
    font-size: 0.9rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--color-primary-dark);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.comercio-modal-section-title i {
    color: var(--color-primary-light);
}

/* Chips de descuentos */
.comercio-modal-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.descuento-chip {
    display: inline-flex;
    align-items: flex-start;
    gap: 0.5rem;
    max-width: 100%;
    padding: 0.65rem 1.1rem;
    border-radius: 14px;
    background: color-mix(in srgb, var(--chip-color, #2451a0) 12%, transparent);
    border: 1.5px solid color-mix(in srgb, var(--chip-color, #2451a0) 35%, transparent);
    color: var(--chip-color, var(--color-primary-light));
    font-size: 0.88rem;
    font-weight: 700;
    line-height: 1.4;
    white-space: normal;
    word-break: break-word;
    overflow-wrap: anywhere;
    transition: background 160ms ease, transform 160ms ease;
}

.descuento-chip:hover {
    background: color-mix(in srgb, var(--chip-color, #2451a0) 20%, transparent);
    transform: scale(1.02);
}

.descuento-chip i {
    font-size: 0.85rem;
    margin-top: 0.15rem;
    flex-shrink: 0;
}

/* Info grid */
.comercio-modal-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
    background: var(--color-background);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
    border: 1px solid var(--color-border);
}

.comercio-modal-info-item {
    display: flex;
    align-items: flex-start;
    gap: 0.85rem;
}

.comercio-info-icon {
    font-size: 1rem;
    color: var(--color-primary-light);
    margin-top: 0.15rem;
    flex-shrink: 0;
}

.comercio-info-label {
    display: block;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--color-text-muted);
    margin-bottom: 0.2rem;
}

.comercio-info-value {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--color-text);
    display: block;
}

.comercio-info-link {
    color: var(--color-primary-light);
    text-decoration: none;
    transition: opacity 150ms ease;
}

.comercio-info-link:hover {
    opacity: 0.75;
}

/* Mapa */
.comercio-modal-map-wrapper {
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--color-border);
    box-shadow: var(--shadow-sm);
}

.comercio-modal-map {
    width: 100%;
    height: 300px;
    border: none;
    display: block;
}

/* Responsividad del modal */
@media (max-width: 640px) {
    .comercio-modal-hero {
        height: 220px;
    }

    .comercio-modal-body {
        padding: 1.5rem 1.25rem 2rem;
    }

    .comercio-modal-nombre {
        font-size: 1.35rem;
    }

    .comercio-modal-info-grid {
        grid-template-columns: 1fr;
    }

    .comercio-modal-map {
        height: 230px;
    }
}

/* =====================================================
   Botones de Redes Sociales en Modal (Pills no invasivas)
   ===================================================== */
.comercio-social-links {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 4px;
}

.social-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 13px;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 200ms ease;
    border: 1px solid #e2e8f0;
    background: #f8fafc;
    color: #334155;
}

.social-pill-instagram:hover {
    background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
    color: #ffffff;
    border-color: transparent;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(220, 39, 67, 0.25);
}

.social-pill-facebook:hover {
    background: #1877f2;
    color: #ffffff;
    border-color: #1877f2;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(24, 119, 242, 0.25);
}