/* =========================================================
   Acre & Horizon — Custom Styles
   Tailwind provides the utility layer; this file carries
   base resets, custom animations, and slider styles.
   ========================================================= */

@layer base {
  html,
  body {
    margin: 0;
    padding: 0;
    overflow-x: clip;
    max-width: 100vw;
  }
  html {
    scroll-behavior: smooth;
    scroll-padding-top: 96px;   /* clear the fixed header when jumping to anchors */
  }
  main,
  section,
  footer {
    max-width: 100vw;
    overflow-x: clip;
  }
  body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
    word-wrap: break-word;
  }
  @media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
  }
  main > :first-child {
    margin-top: 0 !important;
  }
  main > :last-child {
    margin-bottom: 0 !important;
  }
}

/* Slim scrollbar (Chromium / WebKit) — replaces the total hide from the
   Stitch reference so the page remains navigable with a scroll bar. */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: rgba(0, 33, 22, 0.15);
  border-radius: 999px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(0, 33, 22, 0.28);
}

/* Fine-grained tuning for text that Tailwind CDN keeps at default. */
.font-display-hero {
  font-family: 'Playfair Display', serif;
}
.font-headline-lg,
.font-headline-md,
.font-headline-sm {
  font-family: 'Playfair Display', serif;
}
.font-body-lg,
.font-body-md,
.font-body-sm,
.font-title-md,
.font-title-lg,
.font-label-md,
.font-label-sm,
.font-price-lg,
.font-price-sm {
  font-family: 'Plus Jakarta Sans', sans-serif;
}

/* ============= On-scroll reveal (very light) ============= */
[data-reveal] {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.55s ease-out, transform 0.55s ease-out;
}
[data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0);
}
@media (prefers-reduced-motion: reduce) {
  [data-reveal] { opacity: 1; transform: none; transition: none; }
}

/* ============= Country pill dropdown ============= */
.country-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 260px;
  background: #ffffff;
  border-radius: 12px;
  box-shadow: 0 24px 48px -16px rgba(0, 33, 22, 0.18),
              0 4px 12px -4px rgba(0, 33, 22, 0.08);
  padding: 8px;
  z-index: 60;
  opacity: 0;
  transform: translateY(-6px);
  pointer-events: none;
  transition: opacity 0.18s ease, transform 0.18s ease;
}
.country-menu.is-open {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.country-menu button {
  display: flex;
  width: 100%;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 8px;
  text-align: left;
  transition: background 0.15s ease;
}
.country-menu button:hover {
  background: #f4f3f1;
}
.country-menu button.is-active {
  background: #eef4f0;
}
.country-menu .flag {
  font-size: 22px;
  line-height: 1;
}

/* ============= Hero atmospheric grain ============= */
.hero-atmosphere {
  background-image:
    radial-gradient(ellipse 90% 60% at 50% -20%, rgba(18, 55, 42, 0.14), transparent 55%),
    radial-gradient(ellipse 60% 40% at 90% 0%, rgba(114, 91, 56, 0.08), transparent 60%);
  pointer-events: none;
}

/* ============= Tab active state ============= */
.pillar-tab.is-active,
.hero-cat-btn.is-active,
.cat-btn.is-active {
  background: #ffffff;
  color: #002116;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04), 0 1px 3px rgba(0, 0, 0, 0.06);
}

.view-btn.is-active {
  background: #efeeec;
}

/* ============= Hide scrollbars on filter row on mobile ============= */
.scrollbar-none {
  scrollbar-width: none;
}
.scrollbar-none::-webkit-scrollbar { display: none; }

/* ============= Property card hover ============= */
.property-card {
  transition: box-shadow 0.35s ease, transform 0.35s ease;
}
.property-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 22px 40px -18px rgba(0, 33, 22, 0.22),
              0 4px 12px -4px rgba(0, 33, 22, 0.08);
}
.property-card img,
.nation-card img {
  transition: transform 0.7s ease;
}
.property-card:hover img,
.nation-card:hover img {
  transform: scale(1.05);
}

/* ============= Testimonials slider ============= */
.testimonials-track {
  display: flex;
  transition: transform 0.55s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: transform;
}
.testimonials-slide {
  flex: 0 0 100%;
  padding: 0 12px;
}
@media (min-width: 1024px) {
  .testimonials-slide {
    flex: 0 0 50%;
  }
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: rgba(0, 33, 22, 0.18);
  transition: background 0.25s ease, width 0.25s ease;
}
.dot.is-active {
  background: #002116;
  width: 26px;
}

/* ============= Mobile menu ============= */
.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 55;
  background: rgba(250, 249, 247, 0.98);
  backdrop-filter: blur(24px);
  transform: translateX(100%);
  transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  overflow-y: auto;
}
.mobile-menu.is-open {
  transform: translateX(0);
}

/* ============= Line clamp helpers ============= */
.line-clamp-1 {
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.line-clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.line-clamp-3 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ============= Sticky header shadow on scroll ============= */
.header-scrolled {
  background: rgba(250, 249, 247, 0.94);
  box-shadow: 0 1px 12px rgba(0, 33, 22, 0.08);
}

/* ============= Marquee for the buffer section ============= */
@keyframes marquee {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}
.marquee-track {
  animation: marquee 44s linear infinite;
  will-change: transform;
}

/* ============= Focus ring ============= */
button:focus-visible,
a:focus-visible,
select:focus-visible,
input:focus-visible {
  outline: 2px solid #12372a;
  outline-offset: 2px;
  border-radius: 6px;
}

/* ============= Lightbox ============= */
.gallery-tile {
  cursor: zoom-in;
  background: transparent;
  border: 0;
  padding: 0;
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(6, 16, 12, 0.94);
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px 12px 12px;
  opacity: 0;
  transition: opacity 0.2s ease;
}
.lightbox.is-open {
  display: flex;
  opacity: 1;
}
body.lightbox-open {
  overflow: hidden;
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease;
  z-index: 3;
}
.lightbox-close:hover { background: rgba(255, 255, 255, 0.24); }

.lightbox-counter {
  position: absolute;
  top: 26px;
  left: 24px;
  color: #ffffff;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 13px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 600;
  opacity: 0.85;
  z-index: 3;
}

.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 52px;
  height: 52px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease;
  z-index: 3;
}
.lightbox-nav:hover { background: rgba(255, 255, 255, 0.28); }
.lightbox-prev { left: 20px; }
.lightbox-next { right: 20px; }

.lightbox-stage {
  flex: 1;
  min-height: 0;
  width: min(100%, 1200px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
}
.lightbox-image {
  max-width: 100%;
  max-height: calc(100vh - 200px);
  border-radius: 12px;
  object-fit: contain;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}
.lightbox-video {
  width: min(100%, 1200px);
  aspect-ratio: 16 / 9;
  border-radius: 12px;
  overflow: hidden;
  background: #000;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.lightbox-thumbs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 12px 8px;
  max-width: 100%;
  scrollbar-width: thin;
  scrollbar-color: rgba(255,255,255,0.35) transparent;
}
.lightbox-thumbs::-webkit-scrollbar { height: 6px; }
.lightbox-thumbs::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.35); border-radius: 999px; }
.lightbox-thumb {
  width: 84px;
  height: 60px;
  border-radius: 8px;
  overflow: hidden;
  flex-shrink: 0;
  cursor: pointer;
  opacity: 0.55;
  border: 2px solid transparent;
  transition: opacity 0.15s ease, border-color 0.15s ease;
  background: #000;
}
.lightbox-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.lightbox-thumb:hover { opacity: 0.85; }
.lightbox-thumb.is-active { opacity: 1; border-color: #ffffff; }

@media (max-width: 640px) {
  .lightbox-nav { width: 40px; height: 40px; }
  .lightbox-prev { left: 8px; }
  .lightbox-next { right: 8px; }
  .lightbox-thumb { width: 60px; height: 44px; }
}

/* ===================== List Property wizard ===================== */
.lp-chip {
  display: inline-flex;
  align-items: center;
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid rgba(0, 0, 0, 0.1);
  background: #ffffff;
  color: #414844;
  font-family: 'Roboto', system-ui, sans-serif;
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: 0.01em;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
  cursor: pointer;
}
.lp-chip:hover,
.lp-chip.is-active,
.peer:checked ~ .lp-chip {
  background: #002116;
  color: #ffffff;
  border-color: #002116;
}
.lp-step-tab {
  opacity: 0.75;
  transition: opacity 0.15s ease;
}
.lp-step-tab.is-active { opacity: 1; }
.lp-step-tab:hover { opacity: 1; cursor: pointer; }
