@font-face {
    font-family: 'AloeveraDisplay';
    src: url('../fonts/AloeveraDisplay-Regular.woff') format('woff');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #084d43;
    --secondary-color: #8b9d9b;
    --accent-color: #3d6f6d;
    --text-dark: #2c3e3c;
    --text-light: #6b7c7a;
    --bg-light: #f5f5f5;
    --bg-white: #ffffff;
    --bg-gray: #e8eceb;
}

body {
    font-family: 'AloeveraDisplay', 'Inter', sans-serif;
    color: var(--text-dark);
    line-height: 1.6;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
header {
    background: #ffffff;
    padding: 1rem 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
}

header::after {
    content: '';
    display: block;
    width: 90%;
    height: 1px;
    background-color: var(--primary-color);
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
}

/* Responsive - línea verde del header */
@media (max-width: 768px) {
    header::after {
        height: 3px;
    }
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img {
    height: 50px;
    max-width: 100%;
    object-fit: contain;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-menu a {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 500;
    transition: color 0.3s;
}

.nav-menu a:hover {
    color: var(--primary-color);
}

.nav-menu a.active {
    background-color: var(--secondary-color);
    color: var(--bg-white);
    padding: 0.5rem 1rem;
    border-radius: 50px;
    border: none;
    box-shadow: none;
    text-shadow: none;
    transition: background-color 0.3s, color 0.3s;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 5px;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: var(--text-dark);
    transition: 0.3s;
}

/* Hero Emporio */
.hero-emporio {
    background-image: linear-gradient(rgba(0,0,0,0.4), rgba(0,0,0,0.4)), url('../assets/images/inicio emporio.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    padding: 180px 0 60px;
    height: 700px;
    border-bottom-left-radius: 80px;
    border-bottom-right-radius: 80px;
    box-shadow: 0 25px 80px rgba(0,0,0,0.3);
    position: relative;
    z-index: 2;
    overflow: hidden;
}

.hero-content {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    position: relative;
}

.hero-text {
    transition: opacity 0.5s ease-in-out, transform 0.5s ease-in-out;
    min-height: 300px;
}

.hero-text h1 {
    font-size: 4rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.5rem;
    letter-spacing: 2px;
    text-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

.hero-text p {
    font-size: 1.2rem;
    color: rgba(255,255,255,0.9);
    margin-bottom: 2rem;
}

.hero-text-bottom {
    display: flex;
    align-items: center;
    gap: 2.5rem;
    margin-top: 1.5rem;
}

.hero-subheadline {
    font-size: 0.95rem;
    color: rgba(255,255,255,0.8);
    line-height: 1.7;
    margin-bottom: 0;
    flex: 1;
}

.hero-text-bottom .btn-primary {
    flex-shrink: 0;
}

/* Estilos de hero-image eliminados - ahora se usa background-image */

.nav-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    background: transparent;
    border: none;
    cursor: pointer;
    transition: 0.3s;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.nav-arrow.prev {
    left: -60px;
}

.nav-arrow.next {
    right: -60px;
}

.nav-arrow img {
    width: 100%;
    height: 61px;
    max-width: 100%;
}

.nav-arrow:hover {
    opacity: 0.7;
}

.hero-dots {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin: 2rem 0;
}

.dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--secondary-color);
    cursor: pointer;
    transition: 0.3s;
}

.dot.active {
    background: var(--primary-color);
    width: 30px;
    border-radius: 5px;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 0.6rem 3.5rem;
    border-radius: 25px;
    font-size: 1rem;
    cursor: pointer;
    transition: 0.3s;
    display: block;
    margin-left: auto;
    margin-right: 0;
    text-decoration: none;
    text-align: center;
    width: fit-content;
}

.btn-primary:hover {
    background: var(--accent-color);
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(45, 95, 93, 0.3);
}

/* Departamentos Section */
.departamentos {
    padding: 80px 0;
    background: var(--bg-gray);
    position: relative;
    z-index: 1;
    margin-top: -60px;
    padding-top: 140px;
    border-bottom-left-radius: 80px;
    border-bottom-right-radius: 80px;
}

.departamentos h2 {
    font-size: 2.5rem;
    color: var(--primary-color);
    text-align: center;
    margin-bottom: 0.5rem;
}

.subtitle {
    text-align: center;
    color: var(--text-light);
    margin-bottom: 3rem;
}

.cards-container {
    position: relative;
    overflow: hidden;
    flex: 1;
}

.cards-wrapper {
    display: flex;
    gap: 2rem;
    padding: 20px 0;
}

.card {
    min-width: 250px;
    width: 250px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, box-shadow 0.3s ease, opacity 0.3s ease;
    opacity: 1;
}

.card:hover {
    transform: translateY(-10px);
}

.card:hover .card-image {
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

.card-image {
    width: 250px;
    height: 350px;
    border-radius: 40px;
    display: block;
    object-fit: cover;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
}

.card h3 {
    font-size: 1.2rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    margin-top: 1.5rem;
    text-align: left;
}

.card p {
    color: var(--text-light);
    font-size: 0.9rem;
    text-align: left;
}

.carousel-outer {
    position: relative;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.scroll-arrow {
    background: transparent;
    border: none;
    cursor: pointer;
    transition: 0.3s;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    z-index: 2;
}

.scroll-arrow img {
    width: 100%;
    height: 61px;
    max-width: 100%;
}

.scroll-arrow:hover {
    opacity: 0.7;
}

.btn-secondary {
    background: white;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    padding: 1rem 2.5rem;
    border-radius: 25px;
    font-size: 1rem;
    cursor: pointer;
    transition: 0.3s;
    display: block;
    margin: 3rem auto 0;
    width: fit-content;
    text-decoration: none;
}

.btn-secondary:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-2px);
}

/* Tierra Section */
.tierra {
    padding: 80px 0;
    background: var(--bg-white);
}

.tierra-header {
    margin-bottom: 3rem;
}

.tierra-header h2 {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.tierra-header p {
    color: var(--text-light);
}

.tierra-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: start;
}

.tierra-image-main {
    width: 100%;
    aspect-ratio: 16/9;
    background: var(--bg-light);
    border-radius: 15px;
    overflow: hidden;
    margin-bottom: 2rem;
}

.tierra-preview-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: opacity 0.3s ease;
}

.tierra-info .location {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.tierra-info h3 {
    font-size: 1.8rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.tierra-info .tierra-price {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.tierra-info .description {
    color: var(--text-light);
    line-height: 1.8;
    margin-bottom: 1.5rem;
}

.btn-visitar-predio {
    display: inline-block;
    background: var(--primary-color);
    color: white;
    text-decoration: none;
    padding: 0.8rem 2rem;
    border-radius: 25px;
    font-size: 0.95rem;
    transition: background 0.3s, transform 0.3s, box-shadow 0.3s;
}

.btn-visitar-predio:hover {
    background: var(--accent-color);
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(45, 95, 93, 0.3);
}

.tierra-right {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    margin-top: -70px;
}

.tierra-arrow {
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.3s;
}

.tierra-arrow img {
    width: 100%;
    height: 61px;
    max-width: 100%;
}

.tierra-arrow.up img {
    transform: rotate(90deg);
}

.tierra-arrow.down img {
    transform: rotate(90deg);
}

.tierra-arrow:hover {
    opacity: 0.6;
}

.tierra-carousel {
    width: 100%;
    overflow: hidden;
}

.tierra-carousel-wrapper {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.tierra-card {
    display: flex;
    gap: 1.5rem;
    align-items: center;
    padding: 1rem;
    border-radius: 15px;
    cursor: pointer;
    transition: background 0.3s ease, box-shadow 0.3s ease;
    flex-shrink: 0;
}

.tierra-card:hover {
    background: var(--bg-light);
}

.tierra-card.active {
    background: var(--bg-light);
    box-shadow: 0 3px 15px rgba(0,0,0,0.1);
}

.card-icon {
    min-width: 100px;
    width: 100%;
    height: 61px;
    background: var(--bg-gray);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.card-icon i {
    font-size: 1.5rem;
    color: var(--secondary-color);
}

.card-icon-img {
    width: 100px;
    width: 100%;
    height: 61px;
    object-fit: cover;
    border-radius: 12px;
    flex-shrink: 0;
}

.card-text h4 {
    font-size: 1rem;
    color: var(--primary-color);
    margin-bottom: 0.3rem;
}

.card-text p {
    color: var(--text-light);
    font-size: 0.85rem;
    line-height: 1.5;
}

.card-text .tierra-card-price {
    color: var(--primary-color);
    font-weight: 600;
    font-size: 0.9rem;
}

/* Localizaciones Section */
.localizaciones {
    padding: 80px 0;
    background: linear-gradient(135deg, #e8eceb 0%, #d4dbd9 100%);
}

.localizaciones h2 {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

/* Mapa Leaflet */
#loc-leaflet-map {
    height: 520px;
    margin-top: 2.5rem;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0,0,0,0.15);
    z-index: 1;
}

/* Popup personalizado */
.loc-popup-content {
    min-width: 200px;
    font-family: inherit;
}

.loc-popup-name {
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--primary-color);
    margin-bottom: 0.3rem;
    line-height: 1.3;
}

.loc-popup-location {
    font-size: 0.78rem;
    color: #666;
    margin-bottom: 0.35rem;
}

.loc-popup-location i {
    color: var(--primary-color);
    margin-right: 3px;
}

.loc-popup-price {
    font-weight: 700;
    font-size: 0.9rem;
    color: #1a3a2f;
    margin-bottom: 0.75rem;
    padding-top: 0.35rem;
    border-top: 1px dashed rgba(26,58,47,0.2);
}

.loc-popup-link {
    display: block;
    text-align: center;
    background: var(--primary-color);
    color: white;
    text-decoration: none;
    padding: 0.45rem 1rem;
    border-radius: 20px;
    font-size: 0.78rem;
    transition: background 0.2s;
}

.loc-popup-link:hover {
    background: var(--accent-color);
}


/* Botones de ubicación */
.location-pins {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;
}

.location-pin {
    background: white;
    border: 2px solid transparent;
    padding: 0.5rem 1rem;
    border-radius: 25px;
    cursor: pointer;
    font-size: 0.85rem;
    color: var(--text-dark);
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.location-pin i {
    color: var(--primary-color);
}

.location-pin:hover {
    border-color: var(--primary-color);
}

.location-pin.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.location-pin.active i {
    color: white;
}


/* Historias Section */
.historias {
    padding: 80px 0;
    background: var(--bg-white);
    border-bottom-left-radius: 80px;
    border-bottom-right-radius: 80px;
    box-shadow: 0 -25px 80px rgba(0,0,0,0.15), 0 25px 80px rgba(0,0,0,0.3);
    position: relative;
    z-index: 1;
}

.historias h2 {
    font-size: 2.5rem;
    color: var(--primary-color);
    text-align: center;
    margin-bottom: 0.5rem;
}

.historias-slider {
    position: relative;
    overflow: hidden;
    flex: 1;
}

.historias-outer {
    margin: 3rem 0;
}

.historias-wrapper {
    display: flex;
    gap: 1.5rem;
    padding: 20px 0;
    transition: transform 0.5s ease-in-out;
}

.historia-card {
    min-width: 250px;
    width: 250px;
    flex-shrink: 0;
    border-radius: 15px;
    overflow: hidden;
    transition: box-shadow 0.4s ease;
    position: relative;
    opacity: 1;
}

.historia-image {
    width: 100%;
    aspect-ratio: 2/3;
    object-fit: cover;
    display: block;
}

.historia-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(45, 95, 93, 0.95));
    color: white;
    padding: 1.5rem;
}

.historia-content h4 {
    font-size: 1.1rem;
    margin-bottom: 0.3rem;
}

.historia-subtitle {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.7);
    display: block;
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.historia-content p {
    font-size: 0.85rem;
    line-height: 1.5;
}

.historia-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.historias-link {
    text-align: center;
    color: var(--primary-color);
    font-size: 0.95rem;
    margin-top: 1.5rem;
}

.social-icons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 2rem;
}

.social-icons a {
    width: 40px;
    width: 100%;
    height: 61px;
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s;
}

.social-icons a:hover {
    background: var(--accent-color);
    transform: translateY(-3px);
}

/* Newsletter Section */
.newsletter {
    padding: 80px 0;
    background: linear-gradient(135deg, #e8eceb 0%, #d4dbd9 100%);
}

.newsletter-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.newsletter-text h2 {
    font-size: 2.5rem;
    color: var(--primary-color);
    line-height: 1.3;
}

.newsletter-form p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
    text-align: right;
}

.newsletter-form form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    width: 70%;
    margin-left: auto;
}

.newsletter-form input {
    padding: 1rem;
    border: 1px solid var(--secondary-color);
    border-radius: 25px;
    font-size: 1rem;
    transition: 0.3s;
}

.newsletter-form input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(45, 95, 93, 0.1);
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    color: var(--text-light);
}

.checkbox-label input {
    max-width: 100%;
}

.btn-submit {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 25px;
    font-size: 1rem;
    cursor: pointer;
    transition: 0.3s;
}

.btn-submit:hover {
    background: var(--accent-color);
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(45, 95, 93, 0.3);
}

/* Footer */
footer {
    background: var(--primary-color);
    color: white;
    padding: 30px 0;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 3rem;
}

.footer-left {
    display: flex;
    align-items: center;
    gap: 3rem;
    flex: 1;
}

.footer-language {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.copyright {
    font-size: 0.95rem;
    opacity: 0.95;
    white-space: nowrap;
}

.language-toggle {
    background: transparent;
    border: none;
    color: white;
    cursor: pointer;
    padding: 0.3rem;
    transition: 0.3s;
    display: flex;
    align-items: center;
}

.language-toggle:hover {
    opacity: 0.7;
}

.language-toggle i {
    font-size: 0.8rem;
}

.footer-links {
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
}

.footer-links a {
    color: white;
    text-decoration: none;
    transition: 0.3s;
    opacity: 0.9;
    font-size: 0.95rem;
    white-space: nowrap;
}

.footer-links a:hover {
    opacity: 1;
    text-decoration: underline;
}

.footer-social {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.footer-social a {
    width: 40px;
    width: 100%;
    height: 61px;
    background: rgba(255,255,255,0.1);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s;
    font-size: 1.1rem;
}

.footer-social a:hover {
    background: rgba(255,255,255,0.2);
    transform: translateY(-3px);
}

/* Responsive Design */
@media (max-width: 968px) {
    .hero-emporio {
        border-bottom-left-radius: 40px;
        border-bottom-right-radius: 40px;
    }

    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background: var(--bg-white);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 27px rgba(0,0,0,0.05);
        padding: 2rem 0;
    }

    .nav-menu.active {
        left: 0;
    }

    .hamburger {
        display: flex;
    }

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

    .hero-text h1 {
        font-size: 3rem;
    }

    .hero-text-bottom {
        flex-direction: column;
        align-items: flex-start;
        gap: 1.5rem;
    }

    .nav-arrow.prev {
        left: -20px;
    }

    .nav-arrow.next {
        right: -20px;
    }

    .tierra-content,
    .newsletter-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    #loc-leaflet-map {
        height: 350px;
    }

    #loc-leaflet-map {
        height: 360px;
    }

    .footer-content {
        flex-direction: column;
        gap: 2rem;
        text-align: center;
    }

    .footer-left {
        flex-direction: column;
        gap: 1.5rem;
        width: 100%;
    }

    .footer-links {
        justify-content: center;
    }

    .footer-social {
        justify-content: center;
    }
}

@media (max-width: 576px) {
    .hero-text h1 {
        font-size: 2.5rem;
    }

    .departamentos h2,
    .tierra h2,
    .localizaciones h2,
    .historias h2,
    .newsletter-text h2 {
        font-size: 2rem;
    }

    .scroll-arrow {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }

    .card {
        min-width: 200px;
    }

    .historia-card {
        min-width: 200px;
    }

    .localizaciones h2 {
        text-align: center;
    }

    .localizaciones .subtitle {
        text-align: center;
    }

    .footer-links {
        flex-direction: column;
        gap: 0.8rem;
    }

    .footer-social a {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }
}