﻿/*===== GOOGLE FONTS =====*/
@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600&display=swap");

/*===== VARIABLES CSS =====*/
:root {
    --header-height: 3rem;
    --first-color: #fff;
    --first-color-dark: #C6C6C6;
    --first-color-darken: #A9ADB4;
    --white-color: #000;
    --body-font: 'Poppins', sans-serif;
    --big-font-size: 2.5rem;
    --normal-font-size: .938rem;
    --z-fixed: 100;
}

@media screen and (min-width: 768px) {
    :root {
        --big-font-size: 5rem;
        --normal-font-size: 1rem;
    }
}

/*===== BASE =====*/
*, ::before, ::after {
    box-sizing: border-box;
}

.perfil {
    background-color: #DFDEDE;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: flex-start; /* ⬅ Cambiado de center a flex-start */
    font-family: "Poppins", sans-serif;
    padding: 2rem 1rem; /* Añadido padding superior */
}

    .perfil .box {
        background-color: #fff;
        border-radius: 1.5rem;
        margin: 1rem;
        box-shadow: 0 60px 40px -30px rgba(0, 0, 0, 0.27);
        width: 100%;
        max-width: 1600px;
        height: auto; /* ⬅ Cambiado de 750px a auto */
        min-height: 700px; /* ⬅ Podés dejar una altura mínima si querés que se vea equilibrado */
        display: flex;
        flex-direction: column;
        padding: 0;
        overflow: hidden;
    }

    .perfil .content {
        flex: 1;
        background-color: #dfdede;
        border-radius: 1rem;
        padding: 2rem;
        overflow-y: auto;
    }

    .perfil .step {
        display: none;
        font-size: 1rem;
        color: #333;
    }

        .perfil .step.active {
            display: block;
        }

body {
    margin: 0; /* Elimina el espacio superior */
    /*padding: 0;*/
    font-family: var(--body-font);
    font-size: var(--normal-font-size);
    font-weight: 500;
    background-color: #DFDEDE;
}


h1, p, ul {
    margin: 0;
}

ul {
    padding: 0;
    list-style: none;
}

a {
    text-decoration: none;
}

img {
    max-width: 100%;
    height: auto;
}

/*===== LAYOUT =====*/
.bd-grid {
    max-width: 1300px; /* antes 1024px */
    display: grid;
    grid-template-columns: 1fr;
    column-gap: 2rem;
    width: 100%;
    margin: 0 auto;
    padding: 0 1rem;
}

.l-header {
    width: 100%;
    top: 0;
    left: 0;
    z-index: var(--z-fixed);
    background-color: var(--first-color);
}

/*===== NAV =====*/
.nav {
    height: var(--header-height);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

@media screen and (max-width: 768px) {
    .nav__menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        height: 100%;
        padding: 3.5rem 1.5rem 0;
        background: rgba(255,255,255,.3);
        backdrop-filter: blur(10px);
        transition: .5s;
    }
}

.nav__close {
    position: absolute;
    top: .75rem;
    right: 1rem;
    font-size: 1.5rem;
    cursor: pointer;
}

.nav__item {
    margin-bottom: 2rem;
}

.nav__close, .nav__link, .nav__logo, .nav__toggle {
    color: var(--white-color);
}

    .nav__link:hover {
        color: var(--first-color-dark);
    }

.nav__toggle {
    font-size: 1.5rem;
    cursor: pointer;
}

.show {
    right: 0;
}

/*===== HOME =====*/
.home {
    position: relative;
    height: 100%;
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    padding: 1rem; /* ⬅ espacio lateral */
}

.home__container {
    position: relative;
    width: 100%;
    height: 100%;
    display: grid;
    grid-template-columns: 1fr; /* Móvil por defecto */
    min-height: 700px;
}

.home__img {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 100%;
    z-index: 1;
}

    .home__img img.carousel {
        height: 100%;
        width: 100%;
        object-fit: cover;
        position: absolute;
        top: 0;
        left: 0;
        opacity: 0;
        animation: fade 12s infinite;
        transition: opacity 1s ease-in-out;
    }

        .home__img img.carousel:nth-child(1) {
            animation-delay: 0s;
        }

        .home__img img.carousel:nth-child(2) {
            animation-delay: 4s;
        }

        .home__img img.carousel:nth-child(3) {
            animation-delay: 8s;
        }

@keyframes fade {
    0% {
        opacity: 0;
    }

    10% {
        opacity: 1;
    }

    30% {
        opacity: 1;
    }

    40% {
        opacity: 0;
    }

    100% {
        opacity: 0;
    }
}

img.carousel {
    display: block;
}

.home__img img.carousel:first-child {
    opacity: 1;
}

.home__data {
    position: relative;
    z-index: 2;
    color: white;
    text-align: left;
    padding: 1rem 2rem;
    background-color: rgba(0, 0, 0, 0.4);
    border-radius: 1rem;
    max-width: 45%;
}

.home__title {
    font-size: var(--big-font-size);
    line-height: 1.3;
    margin-bottom: 1rem;
}

.home__description {
    margin-bottom: 2.5rem;
}

.home__button {
    background-color: #1E88E5;
    color: white;
    border: none;
    border-radius: .5rem;
    padding: 1rem 2rem;
    font-size: 1rem;
    box-shadow: 0 4px 14px rgba(0,0,0,0.15);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

    .home__button:hover {
        transform: scale(1.05);
        box-shadow: 0 6px 20px rgba(0,0,0,0.2);
    }

/* ===== MEDIA QUERIES ===== */
@media screen and (min-width: 768px) {
    body {
        margin: 0;
    }

    .nav {
        height: calc(var(--header-height) + 1.5rem);
    }

    .nav__toggle, .nav__close {
        display: none;
    }

    .nav__list {
        display: flex;
    }

    .nav__item {
        margin-left: 3rem;
        margin-bottom: 0;
    }
}

@media screen and (min-width: 768px) {
    .home__container {
        grid-template-columns: 1fr 1fr; /* Dos columnas en pantallas grandes */
        align-items: center;
    }

    .home__img,
    .home__data {
        position: relative;
        height: 100%;
    }

    .home__img {
        order: 2;
    }

    .home__data {
        z-index: 2;
        color: white;
        text-align: left;
        padding: 2rem;
        background-color: rgba(0, 0, 0, 0.4);
        border-radius: 1rem;
        margin: 2rem;
    }
}

/*===== NAV ACTIVE LINK =====*/
.nav__link.active {
    position: relative;
}

    .nav__link.active::after {
        content: '';
        position: absolute;
        bottom: -4px;
        left: 0;
        width: 100%;
        height: 2px;
        background-color: var(--white-color);
    }

/*===== HEADER =====*/
.l-header {
    width: 100%;
    background-color: var(--first-color);
    border-bottom: 2px solid var(--first-color-dark);
}

.nav__logo img {
    height: 50px;
    max-height: 100%;
    object-fit: contain;
}

/* Mobile */
@media screen and (max-width: 768px) {
    .perfil .box {
        height: auto;
        min-height: 600px;
    }

    .home {
        flex-direction: column;
        height: auto;
        min-height: 550px;
    }

    .home__container {
        height: auto;
        min-height: 650px;
    }

    .home__img {
        position: relative;
        height: 300px;
    }

    .home__data {
        position: relative;
        z-index: 2;
        padding: 1rem;
        margin-top: 1rem;
        background-color: rgba(0, 0, 0, 0.5);
        text-align: center;
        max-width: 100%;
    }

    .home__title {
        font-size: 1.75rem;
    }

    .home__description {
        font-size: 1rem;
        margin-bottom: 1.5rem;
    }

    .home__button {
        padding: 0.75rem 1.5rem;
        font-size: 1rem;
    }

    .home__img img.carousel {
        object-position: center center;
    }
}

@media screen and (max-width: 768px) {
    .perfil {
        align-items: flex-start; /* ⬅ Esto sube el contenido */
        padding-top: 0rem; /* ⬅ Espacio mínimo arriba */
        padding-bottom: 2rem; /* ⬅ Espacio abajo para que no quede pegado */
    }
}

/*===== ANIMACIONES (usa Animate.css si lo deseas) =====*/
@import url("https://cdnjs.cloudflare.com/ajax/libs/animate.css/4.1.1/animate.min.css");

/* Estilo para destacar palabras */
.resaltado {
    color: #E53935;
    font-weight: 600;
}

/* Botón con ícono */
.home__button i {
    margin-right: 0.5rem;
    vertical-align: middle;
    font-size: 1.2rem;
}

/* Mejora visual al contenedor */
.home__data {
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.resaltado {
    color: #E53935;
    font-weight: bold;
}

/* Mejora del contenedor izquierdo */
.home__data {
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(8px);
    padding: 2rem;
    border-radius: 1rem;
    max-width: 500px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
}

/* Mejora del carrusel */
.home__img img.carousel {
    object-fit: cover;
    object-position: center center;
    border-radius: 0 1rem 1rem 0;
}

.dashboard-casillero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    max-width: 1200px;
    margin: 1.5rem auto; /* antes 3rem */
    padding: 2rem;
    background-color: white;
    border-radius: 1rem;
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.08);
}

.casillero-info-card {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 2rem;
}

.titulo-principal {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.descripcion {
    font-size: 1.2rem;
    margin-bottom: 2rem;
}

.datos-casillero {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    font-size: 1rem;
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 0.75rem;
    margin-bottom: 2rem;
}

.codigo {
    font-weight: bold;
    color: #1E88E5;
}

.boton-acceso {
    background-color: #1E88E5;
    color: white;
    text-decoration: none;
    /*margin-top: 1rem;*/
    padding: 1rem 2rem;
    border-radius: 0.75rem;
    width: fit-content;
    box-shadow: 0 4px 14px rgba(0,0,0,0.15);
    transition: transform 0.2s ease;
}

    .boton-acceso:hover {
        transform: scale(1.05);
    }

.casillero-banner {
    position: relative;
    border-radius: 1rem;
    overflow: hidden;
    height: 100%;
    min-height: 400px;
}

    .casillero-banner img.carousel {
        width: 100%;
        height: 100%;
        object-fit: cover;
        position: absolute;
        top: 0;
        left: 0;
        opacity: 0;
        animation: fade 12s infinite;
        transition: opacity 1s ease-in-out;
        border-radius: 1rem;
    }

        .casillero-banner img.carousel:first-child {
            opacity: 1;
        }

@keyframes fade {
    0%, 100% {
        opacity: 0;
    }

    10%, 30% {
        opacity: 1;
    }

    40%, 100% {
        opacity: 0;
    }
}

/* Responsive */
@media screen and (max-width: 992px) {
    .dashboard-casillero {
        grid-template-columns: 1fr;
        padding: 1rem;
    }

    .casillero-banner {
        height: 300px;
    }

    .titulo-principal {
        font-size: 2rem;
    }
}

/* ==== MEJORAS PARA DISPOSITIVOS PEQUEÑOS (Mobile First) ==== */
@media screen and (max-width: 400px) {
    .perfil {
        padding: 0.5rem;
        align-items: flex-start;
    }

        .perfil .box {
            padding: 1rem;
            margin: 0;
            width: 100%;
            height: auto;
            min-height: 550px;
        }

    .nav__logo img {
        max-height: 28px;
    }

    h2 {
        font-size: 1.6rem;
    }

    p, .info-card, .info-card b {
        font-size: 0.9rem;
    }

    .home__data {
        padding: 1rem;
        margin-top: 1rem;
        text-align: center;
    }

    .home__title {
        font-size: 1.75rem;
    }

    .home__description {
        font-size: 1rem;
        margin-bottom: 1.5rem;
    }

    .home__button {
        padding: 0.75rem 1.5rem;
        font-size: 1rem;
    }
}

/* Mostrar el botón de menú hamburguesa en móviles */
.nav__toggle {
    display: block;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--white-color);
    margin-left: auto;
}

@media screen and (min-width: 768px) {
    .nav__toggle {
        display: none;
    }
}

.btn-copiar {
    background-color: transparent;
    border: none;
    cursor: pointer;
    font-size: 1rem;
    color: #333;
    transition: color 0.2s ease;
}

    .btn-copiar:hover {
        color: #1565C0;
    }

.navegacion-direcciones button {
    background-color: #1e88e5;
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 5px;
    font-weight: 500;
    cursor: pointer;
}

    .navegacion-direcciones button:disabled {
        background-color: #ccc;
        cursor: not-allowed;
    }

.profile-container {
    background: #fff;
    padding: 2rem;
    border-radius: 16px;
    max-width: 600px;
    margin: 2rem auto;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.05);
    font-family: 'Poppins', sans-serif;
}

    .profile-container h2 {
        text-align: center;
        margin-bottom: 2rem;
        font-size: 1.5rem;
        color: #333;
    }

.profile-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
}

.profile-section {
    flex: 1 1 45%;
}

.profile-field {
    margin-bottom: 1rem;
    color: #444;
    font-size: 0.95rem;
}

    .profile-field strong {
        display: block;
        margin-bottom: 0.2rem;
        color: #555;
    }

.edit-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1.2rem;
    margin-top: 2rem;
    background-color: #f5f4ff;
    color: #5f42ff;
    border: 1px solid #cfc5ff;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

    .edit-btn:hover {
        background-color: #e3dbff;
    }

.edicion-usuario {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    margin-top: 2rem;
}

    .edicion-usuario input {
        padding: 0.5rem 0.75rem;
        border: 1px solid #ccc;
        border-radius: 6px;
        font-size: 0.9rem;
    }

.form-buttons {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    margin-top: 1rem;
}

.save-btn,
.cancel-btn {
    padding: 0.6rem 1.2rem;
    border: none;
    border-radius: 6px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.save-btn {
    background-color: #5f42ff;
    color: white;
}

    .save-btn:hover {
        background-color: #452fd4;
    }

.cancel-btn {
    background-color: #f3f3f3;
    color: #333;
}

    .cancel-btn:hover {
        background-color: #e1e1e1;
    }

.oculto {
    display: none !important;
}

@media screen and (max-width: 600px) {
    .dashboard-casillero {
        padding: 1rem 0.5rem;
    }

    .casillero-info-card {
        padding: 1rem 0.75rem;
        margin: 0 auto;
        box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    }

    .titulo-principal {
        font-size: 1.25rem;
        margin-bottom: 0.5rem;
    }

    .descripcion {
        font-size: 0.85rem;
        margin-bottom: 1rem;
    }

    .navegacion-direcciones {
        gap: 0.5rem;
        margin-bottom: 1rem;
    }

        .navegacion-direcciones button,
        .navegacion-direcciones select {
            width: 100%;
            font-size: 0.9rem;
            padding: 0.4rem 0.6rem;
        }

    .datos-casillero {
        padding: 1rem;
        gap: 0.5rem;
        margin-bottom: 1rem;
    }

    .campo-casillero {
        padding: 0.5rem 0.75rem;
        gap: 0.25rem;
    }

        .campo-casillero span {
            font-size: 0.85rem;
            line-height: 1.3;
        }

    .btn-copiar {
        font-size: 0.75rem;
        padding: 0.3rem 0.5rem;
        border-radius: 4px;
        margin-left: auto;
    }
}

input[readonly] {
    background-color: #f5f5f5;
    cursor: not-allowed;
}