/* RESET Y BASE */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #1e3a8a 0%, #3b82f6 30%, #60a5fa 70%, #93c5fd 100%);
    min-height: 100vh;
    color: white;
    position: relative;
    overflow-x: hidden;
}

/* Desktop: sin scroll */
@media (min-width: 769px) {
    body {
        height: 100vh;
        overflow: hidden;
    }
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.15) 0%, transparent 35%),
        radial-gradient(circle at 80% 80%, rgba(30, 58, 138, 0.4) 0%, transparent 45%),
        radial-gradient(circle at 50% 50%, rgba(59, 130, 246, 0.2) 0%, transparent 40%);
    pointer-events: none;
    z-index: 0;
    animation: backgroundShift 20s ease-in-out infinite;
}

/* Elementos HelpDesk flotantes */
body::after {
    content: '🖥️💻📱🔧⚙️📊🎫📞💬🛠️📋✅';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    font-size: 30px;
    opacity: 0.06;
    pointer-events: none;
    z-index: 1;
    animation: floatIcons 30s linear infinite;
    word-spacing: 100px;
    line-height: 120px;
    letter-spacing: 80px;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-around;
    align-items: center;
    transform: rotate(-10deg);
}

@keyframes floatIcons {
    0% {
        transform: translateY(0px) rotate(-10deg);
    }

    50% {
        transform: translateY(-20px) rotate(-8deg);
    }

    100% {
        transform: translateY(0px) rotate(-10deg);
    }
}

@keyframes backgroundShift {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.8;
    }
}

/* LOGO MUNICIPALIDAD */
.muni-logo {
    position: absolute;
    top: 30px;
    left: 40px;
    z-index: 10;
    animation: fadeInLeft 1s ease-out;
}

.muni-logo img {
    height: 65px;
    width: auto;
    object-fit: contain;
    filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.3));
    transition: all 0.3s ease;
    cursor: pointer;
}

.muni-logo img:hover {
    transform: scale(1.05);
    filter: drop-shadow(0 6px 16px rgba(0, 0, 0, 0.4));
}

/* HEADER */
.header {
    position: absolute;
    top: 30px;
    right: 40px;
    z-index: 10;
    animation: fadeInRight 1s ease-out;
}

.login-btn {
    background: rgba(0, 0, 0, 0.25);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.3);
    padding: 14px 28px;
    border-radius: 35px;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    transition: all 0.3s ease;
    backdrop-filter: blur(20px);
    font-size: 0.95rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.login-btn:hover {
    background: rgba(0, 0, 0, 0.4);
    border-color: rgba(255, 255, 255, 0.6);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
    text-decoration: none;
}

.login-btn i {
    font-size: 1.1rem;
}

/* CONTAINER PRINCIPAL */
.main-container {
    position: relative;
    z-index: 1;
    width: 100%;
}

/* Desktop: centrado vertical absoluto */
@media (min-width: 769px) {
    .main-container {
        height: calc(100vh - 60px);
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 0 40px;
    }
}

/* Móvil/Tablet: flujo normal */
@media (max-width: 768px) {
    .main-container {
        padding: 90px 20px 20px;
        min-height: auto;
    }
}

.content-area {
    text-align: center;
    max-width: 800px;
    width: 100%;
    animation: fadeInUp 1.2s ease-out 0.3s both;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(25px);
    border-radius: 25px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
    padding: 40px 35px;
    position: relative;
    overflow: hidden;
}

.content-area::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.08) 0%, transparent 40%),
        radial-gradient(circle at 80% 80%, rgba(147, 197, 253, 0.1) 0%, transparent 30%);
    pointer-events: none;
    z-index: 0;
}

.content-area>* {
    position: relative;
    z-index: 1;
}

/* HERO SECTION */
.hero-section {
    margin-bottom: 35px;
}

.logo-container {
    width: 110px;
    height: 110px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 25px;
    backdrop-filter: blur(25px);
    border: 3px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
    animation: pulse 3s ease-in-out infinite;
    transition: all 0.3s ease;
}

.logo-container img {
    width: 80px;
    height: 80px;
    object-fit: contain;
}

@keyframes textGlow {

    0%,
    100% {
        filter: brightness(1);
    }

    50% {
        filter: brightness(1.1);
    }
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.02);
    }
}

.main-title {
    font-size: 4.5rem;
    font-weight: 900;
    margin-bottom: 25px;
    background: linear-gradient(45deg, #ffffff, #f8fafc);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: textGlow 4s ease-in-out infinite;
}

.main-subtitle {
    font-size: 1.4rem;
    margin-bottom: 20px;
    opacity: 0.98;
    font-weight: 500;
    text-shadow: 0 3px 12px rgba(0, 0, 0, 0.4);
    color: #f8fafc;
}

.main-description {
    font-size: 1.1rem;
    opacity: 0.95;
    line-height: 1.5;
    max-width: 500px;
    margin: 0 auto 40px;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    color: #f1f5f9;
    font-weight: 500;
}

/* BOTONES DE ACCIÓN */
.action-section {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 35px;
}

.action-btn {
    padding: 16px 40px;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 50px;
    text-decoration: none;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 200px;
    justify-content: center;
    border: 2px solid transparent;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.btn-primary-action {
    background: rgba(255, 255, 255, 0.95);
    color: #1e3a8a;
}

.btn-primary-action:hover {
    background: white;
    color: #1e40af;
    transform: translateY(-3px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.25);
    text-decoration: none;
}

.btn-outline-action {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-color: rgba(255, 255, 255, 0.6);
}

.btn-outline-action:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: white;
    color: white;
    transform: translateY(-3px);
    backdrop-filter: blur(15px);
    text-decoration: none;
}

/* CÓMO FUNCIONA */
.how-it-works {
    display: flex;
    justify-content: center;
    gap: 30px;
    max-width: 100%;
    margin: 0 auto;
}

.step-item {
    text-align: center;
    flex: 1;
    max-width: 250px;
}

.step-number {
    width: 60px;
    height: 60px;
    background: rgba(255, 255, 255, 0.2);
    border: 3px solid rgba(255, 255, 255, 0.4);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 1.8rem;
    font-weight: 900;
    backdrop-filter: blur(15px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
}

.step-item:hover .step-number {
    transform: scale(1.1);
    background: rgba(255, 255, 255, 0.3);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.25);
}

.step-title {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 10px;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
    color: #ffffff;
}

.step-description {
    font-size: 0.95rem;
    opacity: 0.98;
    line-height: 1.4;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
    color: #ffffff;
    font-weight: 500;
}

/* FOOTER */
.footer-info {
    text-align: center;
    font-size: 0.9rem;
    opacity: 0.9;
    color: #ffffff;
    font-weight: 500;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
    padding: 20px;
    background: rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(15px);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px 20px 0 0;
}

/* Desktop: footer fijo abajo */
@media (min-width: 769px) {
    .footer-info {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        margin: 0;
        border-radius: 0;
        padding: 15px 20px;
    }
}

/* Móvil/Tablet: footer normal después del contenido */
@media (max-width: 768px) {
    .footer-info {
        position: relative;
        margin: 30px 10px 0;
        border-radius: 15px;
        background: rgba(0, 0, 0, 0.2);
        border: 1px solid rgba(255, 255, 255, 0.15);
    }
}

/* ANIMACIONES */
@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* RESPONSIVE MEJORADO */

/* TABLET (481px a 768px) */
@media (max-width: 768px) {
    .muni-logo {
        top: 20px;
        left: 20px;
    }

    .muni-logo img {
        height: 3.125rem;
        /* 50px */
    }

    .header {
        top: 20px;
        right: 20px;
    }

    .login-btn {
        padding: 0.625rem 1.125rem;
        font-size: 0.85rem;
        gap: 0.375rem;
    }

    .content-area {
        padding: 2.5rem 1.5rem;
        border-radius: 1.5rem;
        margin: 0 0.625rem;
    }

    .hero-section {
        margin-bottom: 1.875rem;
    }

    .logo-container {
        width: 6.875rem;
        height: 6.875rem;
        margin-bottom: 1.5625rem;
    }

    .logo-container img {
        width: 4.6875rem;
        height: 4.6875rem;
    }

    .main-title {
        font-size: 2.5rem;
    }

    .main-description {
        font-size: 1rem;
        margin-bottom: 1.875rem;
        padding: 0 1rem;
        text-align: center;
    }

    .action-section {
        flex-direction: column;
        align-items: center;
        gap: 1.25rem;
        margin-bottom: 1.875rem;
    }

    .action-btn {
        width: 100%;
        max-width: 18.75rem;
        /* 300px */
        padding: 1rem 2.5rem;
    }

    .how-it-works {
        flex-direction: column;
        gap: 1.5rem;
        align-items: center;
    }

    .step-item {
        max-width: 17.5rem;
        /* 280px */
        text-align: center;
    }
}

/* MÓVIL (hasta 480px) */
@media (max-width: 480px) {
    .muni-logo {
        top: 15px;
        left: 15px;
    }

    .muni-logo img {
        height: 2.5rem;
        /* 40px */
    }

    .header {
        top: 15px;
        right: 15px;
    }

    .login-btn {
        padding: 0.5rem 0.875rem;
        font-size: 0.8rem;
        gap: 0.25rem;
    }

    .login-btn i {
        font-size: 1rem;
    }

    .content-area {
        padding: 2rem 1.25rem;
        border-radius: 1.25rem;
        margin: 0 0.3125rem;
    }

    .hero-section {
        margin-bottom: 1.5rem;
    }

    .logo-container {
        width: 5.625rem;
        height: 5.625rem;
        margin-bottom: 1.25rem;
    }

    .logo-container img {
        width: 3.75rem;
        height: 3.75rem;
    }

    .main-title {
        font-size: 2rem;
        text-align: center;
    }

    .main-description {
        font-size: 0.9rem;
        margin-bottom: 1.5rem;
        padding: 0 0.5rem;
        text-align: center;
    }

    .action-section {
        gap: 1rem;
        margin-bottom: 1.5rem;
    }

    .action-btn {
        max-width: 17.5rem;
        padding: 0.875rem 1.875rem;
        font-size: 1rem;
    }

    .how-it-works {
        gap: 1.25rem;
    }

    .step-item {
        max-width: 15.625rem;
        /* 250px */
    }

    .step-number {
        width: 3.125rem;
        height: 3.125rem;
        font-size: 1.5rem;
        margin-bottom: 0.9375rem;
    }

    .step-title {
        font-size: 1.1rem;
        margin-bottom: 0.5rem;
    }

    .step-description {
        font-size: 0.85rem;
    }
}

/* MÓVIL MUY PEQUEÑO (hasta 360px) */
@media (max-width: 360px) {
    .main-title {
        font-size: 1.75rem;
    }

    .action-btn {
        max-width: 15.625rem;
        padding: 0.75rem 1.5625rem;
        font-size: 0.9rem;
    }

    .step-item {
        max-width: 13.75rem;
    }

    .step-number {
        width: 2.8125rem;
        height: 2.8125rem;
        font-size: 1.3rem;
    }
}