* { box-sizing: border-box; margin: 0; padding: 0; }
html, body{
    height: 100%;
    overflow-x: hidden;
    overflow-y: auto;
}

body { 
    font-family: Arial, sans-serif;
    background: white;
    color:#1f2933;
    display: flex;
    flex-direction: column;
}

main.container {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer {
    margin-top: auto;
    padding: 16px;
    text-align: center;
    background: #1e3a8a;
    color: white;
    font-size: 14px;
}

.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
    background: linear-gradient(90deg, #1e3a8a, #38bdf8); 
}

.home {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 12px;
    padding-top: 20px;
}

.home .card {
    max-width: 520px;
}

.home .grid-propiedades {
    justify-items: center;
}

.logo {
    color: white; 
    font-weight: bold; 
    font-size: 20px; 
}

.nav {display: flex; gap: 14px; }
.nav a { text-decoration: none; color: white; font-weight: 500; }
.nav a:hover { text-decoration: underline; }

.container {
    padding: 22px;
    max-width: 1200px;
    margin: 0 auto;
}

.grid-propiedades {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
    margin-top: 10px;
}

.card {
    border: 1px solid #ddd;
    border-radius: 12px;
    overflow: hidden;
    background: white;
}

.card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    display: block;
}

.card-body {
    padding: 14px;
}

.card-body h2 {
    font-size: 18px;
}

.card {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.btn {
    display: inline-block;
    margin-top: 12px;
    padding: 10px 16px;
    background: #22c55e;
    color: #fff;
    text-decoration: none;
    border-radius: 8px;
    font-weight: bold;
}

.contact-grid{
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px,1fr));
    gap: 18px;
    margin-top: 18px;
}

.contact-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 16px;
}

.contact-card a{ color:#1e3a8a;}

.map-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 16px;
    margin-top: 18px;
}

.map-responsive {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    border-radius: 12px;
    margin: 12px 0;
}

.map-responsive iframe {
    position: absolute;
    top: 0; left: 0;
    width: 100%;
    height: 100%;
}

.about-grid{
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 18px;
    margin-top: 18px;
}

.about-card{
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 20px;
    min-height: 180px;
}

.about-card h3 {
    font-size: 22px;
    margin-bottom: 10px;
}

.about-card p {
    font-size: 16px;
    line-height: 1.5;
}

.menu-btn {
    display: none;
    background: transparent;
    border: 2px solid rgba(255, 255, 255, 0.7);
    color: white;
    padding: 6px 10px;
    border-radius: 8px;
    font-size: 18px;
    cursor: pointer;
}

.filters {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin: 10px 0;
}

.filter-btn {
    padding: 8px 12px;
    border-radius: 10px;
    border: 1px solid #ddd;
    background: white;
    cursor: pointer;
}

.filter-btn:hover {
    border-color: #1e3a8a;
}

@media (max-width: 768px) {
    .menu-btn { display: block;}
    
    .header {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    }

    .nav {
    display: none;
    flex-direction: column;
    width: 100%;
    flex-wrap: wrap;
    gap: 10px;
    padding-top: 10px;
    }

    .nav.open{
        display: flex;
    }

    .logo {
    font-size: 18px;
    }

    .container {
    padding: 16px;
    }

    .card-body h2 {
    font-size: 16px;
    }

    .grid-propiedades{
    grid-template-columns: 1fr;
}
}

.hidden { display: none !important; }

/* BOTÓN*/
.btn {
    transition: .15s ease, box-shadow .15s ease, opacity .2s ease; 
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 14px rgba(0, 0, 0, .15);
}

.btn.press {
    transform: scale(0.96);
}

/* CARGANDO*/
.btn.loading {
    opacity: .7;
    pointer-events: none;
}

/* ERROR: vibración */
@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-6px);}
    75% { transform: translateX(6px);}
}

.shake {
    animation: shake .3s;
}

/* TRANSICIÓN LOGIN → ADMIN*/
.fade-out {
    animation: fadeOut .4s forwards;
}

@keyframes fadeOut {
    to {
        opacity: 0;
        transform: translateY(-10px);
    }
}