/* =========================================================
   Las Torres Tapachula · Residencias & Plaza Comercial
   Capa visual sobre la plantilla Tripio (Tailwind)
   Paleta tomada del logo:
   rojo #BA241D · rojo oscuro #A11F0B · naranja #E73F0A
   verde #BBCE46 · amarillo #F1EB73 · grafito #2E2F34 · gris #6C6F76
   ========================================================= */

/* ---------- Tipografías locales ---------- */
@font-face { font-family: 'Montserrat'; font-weight: 600; font-style: normal; font-display: swap; src: url('../fonts/montserrat-latin-600-normal.woff2') format('woff2'); }
@font-face { font-family: 'Montserrat'; font-weight: 700; font-style: normal; font-display: swap; src: url('../fonts/montserrat-latin-700-normal.woff2') format('woff2'); }
@font-face { font-family: 'Montserrat'; font-weight: 800; font-style: normal; font-display: swap; src: url('../fonts/montserrat-latin-800-normal.woff2') format('woff2'); }
@font-face { font-family: 'Open Sans'; font-weight: 400; font-style: normal; font-display: swap; src: url('../fonts/open-sans-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Open Sans'; font-weight: 400; font-style: italic; font-display: swap; src: url('../fonts/open-sans-latin-400-italic.woff2') format('woff2'); }
@font-face { font-family: 'Open Sans'; font-weight: 600; font-style: normal; font-display: swap; src: url('../fonts/open-sans-latin-600-normal.woff2') format('woff2'); }
@font-face { font-family: 'Open Sans'; font-weight: 700; font-style: normal; font-display: swap; src: url('../fonts/open-sans-latin-700-normal.woff2') format('woff2'); }

:root {
  --lt-red: #BA241D;
  --lt-red-dark: #A11F0B;
  --lt-orange: #E73F0A;
  --lt-green: #BBCE46;
  --lt-yellow: #F1EB73;
  --lt-dark: #2E2F34;
  --lt-gray: #6C6F76;
}

html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body { font-family: 'Open Sans', system-ui, sans-serif; overflow-x: hidden; -webkit-font-smoothing: antialiased; }
::selection { background: var(--lt-red); color: #fff; }

/* ---------- Franja de 4 colores (firma de la marca) ---------- */
.lt-stripe { display: flex; height: 6px; width: 100%; }
.lt-stripe > span { flex: 1; }
.lt-stripe > span:nth-child(1) { background: var(--lt-yellow); }
.lt-stripe > span:nth-child(2) { background: var(--lt-green); }
.lt-stripe > span:nth-child(3) { background: var(--lt-orange); }
.lt-stripe > span:nth-child(4) { background: var(--lt-red-dark); }
.lt-stripe-mini { display: inline-flex; gap: 3px; }
.lt-stripe-mini > span { width: 14px; height: 4px; border-radius: 2px; }
.lt-stripe-mini > span:nth-child(1) { background: var(--lt-yellow); }
.lt-stripe-mini > span:nth-child(2) { background: var(--lt-green); }
.lt-stripe-mini > span:nth-child(3) { background: var(--lt-orange); }
.lt-stripe-mini > span:nth-child(4) { background: var(--lt-red-dark); }

/* ---------- Preloader ---------- */
.preloader { position: fixed; inset: 0; z-index: 99999; background: var(--lt-dark); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 22px; transition: opacity .5s ease, visibility .5s ease; }
.preloader.hidden { opacity: 0; visibility: hidden; }
.preloader img { width: 120px; animation: ltRise 1.6s ease-in-out infinite; }
.preloader .lt-stripe { width: 140px; border-radius: 3px; overflow: hidden; }
.preloader .lt-stripe > span { transform-origin: left; animation: ltGrow 1.2s ease-in-out infinite; }
.preloader .lt-stripe > span:nth-child(2) { animation-delay: .1s; }
.preloader .lt-stripe > span:nth-child(3) { animation-delay: .2s; }
.preloader .lt-stripe > span:nth-child(4) { animation-delay: .3s; }
@keyframes ltRise { 0%, 100% { transform: translateY(0); opacity: 1; } 50% { transform: translateY(-8px); opacity: .85; } }
@keyframes ltGrow { 0%, 100% { transform: scaleX(.25); } 50% { transform: scaleX(1); } }

/* ---------- Navbar ---------- */
#navbar .nav-link { position: relative; }
#navbar .nav-link::after { content: ''; position: absolute; left: 16px; right: 16px; bottom: 4px; height: 2px; background: var(--lt-orange); transform: scaleX(0); transition: transform .3s ease; }
#navbar .nav-link:hover::after, #navbar .nav-link.is-active::after { transform: scaleX(1); }
#navbar .brand-mark-dark { display: none; }
.navbar-scrolled { background: rgba(255, 255, 255, .97) !important; box-shadow: 0 6px 24px rgba(46, 47, 52, .10); backdrop-filter: blur(16px); }
.navbar-scrolled .nav-link, .navbar-scrolled .menu-icon { color: var(--lt-dark) !important; }
.navbar-scrolled .brand-word { color: var(--lt-red) !important; }
.navbar-scrolled .brand-sub { color: var(--lt-gray) !important; }
#navbar.navbar-scrolled .brand-mark-light { display: none; }
#navbar.navbar-scrolled .brand-mark-dark { display: block; }
.navbar-scrolled .nav-phone { color: var(--lt-dark) !important; }

/* ---------- Menú móvil ---------- */
.mobile-menu { transform: translateX(100%); transition: transform .35s cubic-bezier(.4, 0, .2, 1); }
.mobile-menu.active { transform: translateX(0); }
.mobile-overlay { opacity: 0; visibility: hidden; transition: all .3s ease; }
.mobile-overlay.active { opacity: 1; visibility: visible; }

/* ---------- Hero ---------- */
.hero-slide { position: absolute; inset: 0; opacity: 0; transform: scale(1.06); transition: opacity 1.2s ease, transform 7s ease-out; background-size: cover; background-position: center; }
.hero-slide.active { opacity: 1; transform: scale(1); }
.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
    100deg,
    rgba(30, 31, 35, .58) 0%,
    rgba(30, 31, 35, .38) 42%,
    rgba(30, 31, 35, .08) 72%,
    rgba(186, 36, 29, .10) 100%
);
}
.hero-overlay::after { content: ''; position: absolute; inset: auto 0 0 0; height: 40%; background: linear-gradient(to top, rgba(30, 31, 35, .75), transparent); }
.slide-dot { height: 6px; width: 18px; border-radius: 3px; background: rgba(255, 255, 255, .45); transition: all .35s ease; }
.slide-dot.active { width: 42px; background: var(--lt-orange); }

/* ---------- Pestañas del buscador ---------- */
.book-tab { color: var(--lt-gray); background: #F3F4F6; }
.book-tab.active { color: #fff; background: var(--lt-red); box-shadow: 0 8px 20px -8px rgba(186, 36, 29, .6); }
.book-panel { display: none; }
.book-panel.active { display: grid; animation: ltFade .35s ease; }
@keyframes ltFade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.lt-field { width: 100%; padding: .8rem 1rem .8rem 2.6rem; background: #F7F7F8; border: 1px solid #E5E7EB; border-radius: .9rem; font-size: .9rem; color: var(--lt-dark); transition: all .2s ease; appearance: none; }
.lt-field:focus { outline: none; border-color: var(--lt-red); box-shadow: 0 0 0 4px rgba(186, 36, 29, .12); background: #fff; }

/* ---------- Tarjetas ---------- */
.lift { transition: transform .4s cubic-bezier(.4, 0, .2, 1), box-shadow .4s ease; }
.lift:hover { transform: translateY(-8px); box-shadow: 0 28px 50px -18px rgba(46, 47, 52, .35); }
.zoom-img { transition: transform .8s cubic-bezier(.4, 0, .2, 1); }
.group:hover .zoom-img { transform: scale(1.08); }
.amenity .amenity-icon { transition: all .5s ease; }
.amenity:hover .amenity-icon { background: var(--lt-red); color: #fff; transform: rotate(-6deg) scale(1.05); }

/* ---------- Botones ---------- */
.btn-shine { position: relative; overflow: hidden; }
.btn-shine::before { content: ''; position: absolute; top: 0; left: -120%; width: 100%; height: 100%; background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .28), transparent); transition: left .6s ease; }
.btn-shine:hover::before { left: 120%; }

/* ---------- Filtro de la plaza ---------- */
.plaza-filter { background: #fff; color: var(--lt-gray); border: 1px solid #E5E7EB; }
.plaza-filter.active, .plaza-filter:hover { background: var(--lt-dark); color: #fff; border-color: var(--lt-dark); }
.tenant.is-hidden { display: none; }

/* ---------- Galería + lightbox ---------- */
.gallery-grid { columns: 1; column-gap: 1rem; }
@media (min-width: 640px) { .gallery-grid { columns: 2; } }
@media (min-width: 1024px) { .gallery-grid { columns: 3; } }
.gallery-grid > button { break-inside: avoid; margin-bottom: 1rem; width: 100%; display: block; }
.lightbox { opacity: 0; visibility: hidden; transition: all .3s ease; }
.lightbox.open { opacity: 1; visibility: visible; }

/* ---------- FAQ ---------- */
.faq-item summary { list-style: none; cursor: pointer; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item[open] .faq-icon { transform: rotate(45deg); background: var(--lt-red); color: #fff; }
.faq-icon { transition: all .3s ease; }

/* ---------- Flotantes ---------- */
.back-to-top { opacity: 0; visibility: hidden; transform: translateY(10px); transition: all .3s ease; }
.back-to-top.visible { opacity: 1; visibility: visible; transform: none; }
.wa-float { animation: ltPulse 2.4s ease-in-out infinite; }
@keyframes ltPulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, .45); } 50% { box-shadow: 0 0 0 14px rgba(37, 211, 102, 0); } }

/* ---------- Scrollbar ---------- */
::-webkit-scrollbar { width: 9px; }
::-webkit-scrollbar-track { background: #F1F1F2; }
::-webkit-scrollbar-thumb { background: var(--lt-gray); border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: var(--lt-red); }

/* ---------- Accesibilidad ---------- */
:focus-visible { outline: 3px solid rgba(231, 63, 10, .55); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
