:root {
    --lp-bg: #ffffff;
    --lp-surface: #ffffff;
    --lp-surface-2: #f2ede5;
    --lp-surface-3: #424953;
    --lp-text: #424953;
    --lp-text-soft: #8f6a3b;
    --lp-text-invert: #ffffff;
    --lp-line: rgba(27, 26, 24, 0.12);
    --lp-gold: #b68c53;
    --lp-gold-dark: #8f6a3b;
    --lp-grey: #8D9BA4;
    --lp-dark-grey: #424953;
    --lp-green: #237a57;
    --lp-red: #9a4d4d;
    --lp-orange: #B96f20;
    --lp-shadow: 0 16px 48px rgba(0, 0, 0, 0.08);
    --lp-radius-lg: 20px;
    --lp-radius-md: 12px;
    --lp-radius-sm: 4px;
    --lp-radius-null: 0px;
    --lp-container: 1920px;
    --lp-section-padding: 120px;
    --lp-section-padding-md: 60px;
    --lp-section-padding-sm: 30px;
    --lp-section-padding-null: 0px;
    --lp-lead-font: "Barlow", sans-serif;
    --lp-title-font: "Playfair Display", serif;
}

.lp-cmap-wrapper,
.lp-cmap-wrapper * {
    box-sizing: border-box;
}

.lp-cmap-wrapper {
    background-color: #f1f1f1;
    position: relative;
    overflow-x: hidden;
    width: 100vw;
    max-width: 100vw;
    margin-left: calc(50% - 50vw);
}

.lp-cmap-wrapper .lp-landing__section {
    padding: var(--lp-section-padding) 0 0;
    position: relative;
    overflow: visible;
}

.lp-cmap-wrapper .lp-landing__container {
    width: min(100% - 32px, var(--lp-container));
    margin: 0 auto;
}

.lp-cmap-masthead {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    padding-bottom: 56px;
}

.lp-cmap-masthead__left {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    gap: 14px;
    padding-left: 2rem;
}

.lp-cmap-wrapper .lp-landing__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--lp-grey);
    font-family: var(--lp-lead-font);
    font-size: 1rem;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 3px;
}

.lp-cmap-wrapper .lp-landing__section-title {
    font-family: var(--lp-title-font);
    font-size: 1.8rem !important;
    font-weight: 700 !important;
    letter-spacing: -0.5px;
    line-height: 2.6rem;
    color: #424953 !important;
    margin: 0;
}

.lp-cmap-wrapper .lp-landing__section-title em {
    font-style: italic;
    color: var(--lp-dark-grey);
}

.lp-cmap-masthead__right {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    gap: 28px;
}

.lp-cmap-masthead__subtitle {
    max-width: 400px;
}

.lp-cmap-masthead__stats {
    display: flex;
    gap: 36px;
}

.lp-cmap-stat {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.lp-cmap-stat__num {
    font-family: var(--lp-title-font);
    font-size: 2rem;
    font-weight: 700;
    color: var(--lp-dark-grey);
    line-height: 1;
}

.lp-cmap-stat__label {
    font-family: var(--lp-lead-font);
    font-weight: 400;
    font-size: 0.75rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--lp-grey);
}

.lp-cmap-map-wrap {
    border-top: 1px solid var(--lp-line);
    position: relative;
    width: 100vw;
    max-width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    left: auto;
    transform: none;
    height: clamp(280px, 50vh, 500px);
    min-height: 240px;
    overflow: hidden;
}

.lp-cmap-map-wrap > div[id] {
    width: 100%;
    height: 100%;
    display: block;
}

.lp-cmap-map-wrap .leaflet-container {
    width: 100%;
    height: 100%;
    background: #e9ecef;
}

.lp-cmap-map-fade {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 80px;
    background: linear-gradient(to bottom, transparent, #f1f1f1);
    pointer-events: none;
    z-index: 500;
}

.lp-cmap-map-fade-top {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 40px;
    background: linear-gradient(to bottom, rgba(241,241,241,0.6), transparent);
    pointer-events: none;
    z-index: 500;
}

.lp-cmap-offices {
    margin-top: 50px;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
}

.lp-cmap-tile {
    padding: 32px 36px 36px;
    border-right: 1px solid var(--lp-line);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: background 0.35s ease;
    background: transparent;
}

.lp-cmap-tile:last-child {
    border-right: none;
}

.lp-cmap-tile::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(to right, var(--lp-gold-dark), var(--lp-gold));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

.lp-cmap-tile:hover,
.lp-cmap-tile.is-active {
    background: var(--lp-surface-3);
}

.lp-cmap-tile:hover::before,
.lp-cmap-tile.is-active::before {
    transform: scaleX(1);
}

.lp-cmap-tile:hover .lp-cmap-tile__num,
.lp-cmap-tile.is-active .lp-cmap-tile__num {
    color: rgba(255, 255, 255, 0.55);
}

.lp-cmap-tile:hover .lp-cmap-tile__city,
.lp-cmap-tile.is-active .lp-cmap-tile__city {
    color: #ffffff;
}

.lp-cmap-tile:hover .lp-cmap-tile__country,
.lp-cmap-tile.is-active .lp-cmap-tile__country {
    color: rgba(255, 255, 255, 0.55);
}

.lp-cmap-tile:hover .lp-cmap-tile__rule,
.lp-cmap-tile.is-active .lp-cmap-tile__rule {
    background: rgba(255, 255, 255, 0.4);
}

.lp-cmap-tile:hover .lp-cmap-tile__info-icon,
.lp-cmap-tile.is-active .lp-cmap-tile__info-icon {
    color: rgba(255, 255, 255, 0.7);
}

.lp-cmap-tile:hover .lp-cmap-tile__info-text,
.lp-cmap-tile.is-active .lp-cmap-tile__info-text {
    color: rgba(255, 255, 255, 0.85);
}

.lp-cmap-tile:hover .lp-cmap-tile__info-text a,
.lp-cmap-tile.is-active .lp-cmap-tile__info-text a {
    color: rgba(255, 255, 255, 0.85);
    border-bottom-color: rgba(255, 255, 255, 0.25);
}

.lp-cmap-tile:hover .lp-cmap-tile__info-text a:hover,
.lp-cmap-tile.is-active .lp-cmap-tile__info-text a:hover {
    color: #ffffff;
    border-bottom-color: rgba(255, 255, 255, 0.6);
}

.lp-cmap-tile__num {
    font-family: var(--lp-title-font);
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--lp-dark-grey);
    letter-spacing: 0.12em;
    margin-bottom: 12px;
    position: relative;
    z-index: 1;
}

.lp-cmap-tile__city {
    font-family: var(--lp-title-font);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--lp-dark-grey);
    line-height: 1.15;
    margin-bottom: 4px;
    position: relative;
    z-index: 1;
}

.lp-cmap-tile__country {
    font-family: var(--lp-lead-font);
    font-weight: 400;
    font-size: 0.7rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--lp-grey);
    margin-bottom: 20px;
    position: relative;
    z-index: 1;
}

.lp-cmap-tile__rule {
    width: 20px;
    height: 1px;
    background: var(--lp-dark-grey);
    margin-bottom: 16px;
    position: relative;
    z-index: 1;
    transition: width 0.35s ease;
}

.lp-cmap-tile:hover .lp-cmap-tile__rule,
.lp-cmap-tile.is-active .lp-cmap-tile__rule {
    width: 40px;
}

.lp-cmap-tile__detail {
    position: relative;
    z-index: 1;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.5s ease, opacity 0.35s ease;
}

.lp-cmap-tile:hover .lp-cmap-tile__detail,
.lp-cmap-tile.is-active .lp-cmap-tile__detail {
    max-height: 200px;
    opacity: 1;
}

.lp-cmap-tile__info-row {
    display: flex;
    gap: 10px;
    margin-bottom: 8px;
    align-items: flex-start;
}

.lp-cmap-tile__info-icon {
    color: var(--lp-dark-grey);
    flex-shrink: 0;
    margin-top: 2px;
}

.lp-cmap-tile__info-text {
    font-family: var(--lp-lead-font);
    font-weight: 400;
    font-size: 0.8rem;
    line-height: 1.7em;
    color: var(--lp-text);
}

.lp-cmap-tile__info-text a {
    color: var(--lp-text);
    text-decoration: none;
    border-bottom: 1px solid var(--lp-line);
    transition: color 0.2s, border-color 0.2s;
}

.lp-cmap-tile__info-text a:hover {
    color: var(--lp-dark-grey);
    border-color: var(--lp-dark-grey);
}

.lp-cmap-wrapper .leaflet-control-attribution {
    font-family: var(--lp-lead-font) !important;
    font-size: 9px !important;
    color: var(--lp-grey) !important;
    background-color: rgba(251, 248, 245, 0.72) !important;
    border: 1px solid rgba(0, 0, 0, 0.06);
    -webkit-backdrop-filter: blur(4px);
    backdrop-filter: blur(4px);
}

.lp-cmap-wrapper .leaflet-control-zoom a {
    font-family: var(--lp-lead-font) !important;
    background: var(--lp-surface) !important;
    color: var(--lp-dark-grey) !important;
    border-color: var(--lp-line) !important;
}

.lp-cmap-wrapper .leaflet-control-zoom a:hover {
    background: var(--lp-surface-2) !important;
    color: var(--lp-dark-grey) !important;
}

.lp-cmap-wrapper .leaflet-popup-content-wrapper {
    background: var(--lp-surface) !important;
    border-radius: var(--lp-radius-lg) !important;
    border: 1px solid var(--lp-line) !important;
    box-shadow: var(--lp-shadow) !important;
    padding: 0 !important;
    min-width: 200px;
}

.lp-cmap-wrapper .leaflet-popup-tip {
    background: var(--lp-surface) !important;
}

.lp-cmap-wrapper .leaflet-popup-tip-container {
    margin-top: -1px;
}

.lp-cmap-wrapper .leaflet-popup-close-button {
    color: var(--lp-grey) !important;
    font-size: 16px !important;
    top: 10px !important;
    right: 12px !important;
}

.lp-cmap-wrapper .leaflet-popup-close-button:hover {
    color: var(--lp-dark-grey) !important;
}

.lp-cmap-wrapper .leaflet-popup-content {
    margin: 0 !important;
}

.lp-cmap-popup {
    padding: 20px 22px 16px;
    border-radius: var(--lp-radius-lg);
}

.lp-cmap-popup__eyebrow {
    font-family: var(--lp-lead-font);
    font-weight: 400;
    font-size: 0.65rem;
    letter-spacing: 0.28em;
    text-transform: uppercase;
    color: var(--lp-dark-grey);
    margin-bottom: 4px;
}

.lp-cmap-popup__city {
    font-family: var(--lp-title-font);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--lp-dark-grey) !important;
    margin-bottom: 20px;
}

.lp-cmap-marker {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    position: relative;
}

.lp-cmap-dot {
    width: 10px;
    height: 10px;
    background: var(--lp-dark-grey);
    border-radius: 50%;
    border: 2px solid var(--lp-surface);
    box-shadow: 0 2px 10px rgba(66,73,83,0.35);
    position: relative;
    z-index: 1;
    transition: transform 0.3s ease, background 0.3s ease;
}

.lp-cmap-ring {
    position: absolute;
    width: 32px;
    height: 32px;
    border: 1.5px solid rgba(66,73,83,0.3);
    border-radius: 50%;
    animation: lp-cmap-pulse 2.5s ease-out infinite;
}

@keyframes lp-cmap-pulse {
    0%   { transform: scale(0.4); opacity: 0.7; }
    100% { transform: scale(1.2); opacity: 0; }
}

.lp-cmap-marker.is-active .lp-cmap-dot {
    background: var(--lp-dark-grey);
    transform: scale(1.3);
}

.lp-cmap-bottom {
    display: none;
}

.lp-cmap-bottom__brand {
    font-family: var(--lp-title-font);
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--lp-dark-grey);
    letter-spacing: 0.02em;
}

.lp-cmap-bottom__brand span {
    color: var(--lp-dark-grey);
}

.lp-cmap-bottom__contact {
    display: flex;
    gap: 28px;
    align-items: center;
}

.lp-cmap-bottom__link {
    font-family: var(--lp-lead-font);
    font-weight: 400;
    font-size: 0.8rem;
    letter-spacing: 0.04em;
    color: var(--lp-grey);
    text-decoration: none;
    transition: color 0.2s;
}

.lp-cmap-bottom__link:hover {
    color: var(--lp-dark-grey);
}

.lp-cmap-bottom__sep {
    width: 1px;
    height: 14px;
    background: var(--lp-line);
}

.lp-cmap-wrapper .lp-reveal {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity .7s ease, transform .7s ease;
}

.lp-cmap-wrapper .lp-reveal--visible {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 1100px) {
    .lp-cmap-offices {
        grid-template-columns: repeat(2, 1fr);
    }

    .lp-cmap-tile:nth-child(2) {
        border-right: none;
    }

    .lp-cmap-tile:nth-child(3) {
        border-top: 1px solid var(--lp-line);
    }

    .lp-cmap-tile:nth-child(4) {
        border-top: 1px solid var(--lp-line);
        border-right: none;
    }
}

@media (max-width: 900px) {
    .lp-cmap-masthead {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .lp-cmap-masthead__subtitle {
        max-width: 100%;
    }
}

@media (max-width: 767px) {
    .lp-cmap-wrapper .lp-landing__section {
        padding: 64px 0 0;
    }

    .lp-cmap-wrapper .lp-landing__section-title {
        font-size: 1.6rem !important;
        line-height: 2.4rem;
    }

    .lp-cmap-map-wrap {
        height: 240px;
        min-height: 240px;
    }

    .lp-cmap-offices {
        grid-template-columns: 1fr;
    }

    .lp-cmap-tile {
        border-right: none;
        border-bottom: 1px solid var(--lp-line);
    }

    .lp-cmap-tile:last-child {
        border-bottom: none;
    }

    .lp-cmap-tile:nth-child(n) {
        border-top: none;
    }

    .lp-cmap-bottom {
        flex-direction: column;
        gap: 14px;
        text-align: center;
        padding: 20px 16px;
    }

    .lp-cmap-bottom__contact {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .lp-cmap-masthead__left {
        padding-left: 1rem;
    }    
}

/* Estilos de Leaflet */
.leaflet-bottom {
    margin: 2rem;
}

.leaflet-popup {
    border-radius: var(--lp-radius-lg) !important;
}

.leaflet-popup-content p {
    margin: 1.2em 0 0.5em 0;
}