/*
 * Villa Notos — Design v2
 * Improvements guided by impeccable, emil-design-eng & high-end-visual-design skills
 *
 * Principles applied:
 *  — No `transition: all` (specify exact properties)
 *  — Custom cubic-bezier easing (not default ease/ease-in-out)
 *  — Button `:active` scale feedback
 *  — Hover gated by `@media (hover: hover) and (pointer: fine)`
 *  — Floating island nav (detached pill, not full-width sticky)
 *  — Film grain on hero (luxury paper-like texture)
 *  — Eyebrow tags as pill badges
 *  — Asymmetric feature cards (breaks identical grid anti-pattern)
 *  — Blur + translate on scroll reveals (premium entrance feel)
 */

/* ── Design tokens ── */
:root {
  --ease-expo:     cubic-bezier(0.16, 1, 0.3, 1);
  --ease-quart:    cubic-bezier(0.25, 1, 0.5, 1);
  --ease-in-expo:  cubic-bezier(0.7, 0, 0.84, 0);
}

/* ════════════════════════════════════════════
   1. FLOATING PILL NAVIGATION
═══════════════════════════════════════════ */

nav[data-astro-cid-dmqpwcec] {
  top: 18px;
  left: 50%;
  right: auto;
  transform: translateX(-50%);
  width: calc(100% - 40px);
  max-width: 1040px;
  border-radius: 999px;
  padding: 14px 28px;
  background: rgba(26, 20, 16, 0.48);
  backdrop-filter: blur(18px) saturate(1.3);
  -webkit-backdrop-filter: blur(18px) saturate(1.3);
  border: 1px solid rgba(196, 168, 130, 0.1);
  box-shadow:
    0 4px 24px rgba(26, 20, 16, 0.22),
    inset 0 1px 0 rgba(237, 228, 211, 0.05);
  transition:
    top 0.4s var(--ease-expo),
    padding 0.3s var(--ease-expo),
    background 0.35s ease,
    border-color 0.35s ease,
    box-shadow 0.35s ease;
}

nav[data-astro-cid-dmqpwcec].scrolled {
  top: 12px;
  padding: 12px 28px;
  background: rgba(247, 242, 234, 0.97);
  backdrop-filter: blur(20px) saturate(1.2);
  -webkit-backdrop-filter: blur(20px) saturate(1.2);
  border-color: rgba(196, 168, 130, 0.22);
  box-shadow:
    0 2px 20px rgba(26, 20, 16, 0.07),
    0 0 0 1px rgba(196, 168, 130, 0.08);
}

/* Mobile: pill becomes a rounded rect */
@media (max-width: 768px) {
  nav[data-astro-cid-dmqpwcec] {
    top: 10px;
    width: calc(100% - 24px);
    border-radius: 18px;
    padding: 12px 18px;
  }
  nav[data-astro-cid-dmqpwcec].scrolled {
    top: 8px;
    padding: 10px 18px;
  }
}

/* Nav CTA: pill shape, tighter transition */
.nav-cta[data-astro-cid-dmqpwcec] {
  border-radius: 999px;
  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    transform 0.15s var(--ease-expo);
}

.nav-cta[data-astro-cid-dmqpwcec]:active {
  transform: scale(0.96);
}

@media (hover: hover) and (pointer: fine) {
  .nav-cta[data-astro-cid-dmqpwcec]:hover {
    transform: translateY(-1px);
  }
}


/* ════════════════════════════════════════════
   2. FILM GRAIN ON HERO (luxury texture)
═══════════════════════════════════════════ */

.hero[data-astro-cid-bbe6dxrz]::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  opacity: 0.045;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.88' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='200' height='200' filter='url(%23n)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 180px 180px;
}

/* Hero content must stay above grain */
.hero-content[data-astro-cid-bbe6dxrz] {
  z-index: 5;
}

.scroll-hint[data-astro-cid-bbe6dxrz] {
  z-index: 5;
}


/* ════════════════════════════════════════════
   3. EYEBROW TAGS — pill badge style
═══════════════════════════════════════════ */

.eyebrow {
  display: inline-block;
  background: rgba(196, 168, 130, 0.1);
  border: 1px solid rgba(196, 168, 130, 0.25);
  border-radius: 999px;
  padding: 5px 16px;
  margin-bottom: 20px;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--earth);
}

/* Hero eyebrow: light on dark background */
.hero-eyebrow[data-astro-cid-bbe6dxrz] {
  background: rgba(196, 168, 130, 0.12);
  border-color: rgba(196, 168, 130, 0.22);
  color: var(--stone);
}

/* Gallery, booking: slightly different tint */
.gallery[data-astro-cid-ihllb3az] .eyebrow,
.booking[data-astro-cid-k66kqjni] .eyebrow[data-astro-cid-k66kqjni] {
  background: rgba(196, 168, 130, 0.08);
}


/* ════════════════════════════════════════════
   4. BUTTONS — pill shape, active feedback,
      custom easing, hover gating
═══════════════════════════════════════════ */

/* Replace `transition: all` with specific props + custom curve */
.btn {
  border-radius: 999px;
  transition:
    background 0.22s ease,
    border-color 0.22s ease,
    color 0.22s ease,
    transform 0.16s var(--ease-expo),
    box-shadow 0.22s ease;
}

/* Press feedback on all buttons */
.btn:active {
  transform: scale(0.97);
  box-shadow: none;
}

/* Hover — only on devices that have a real pointer */
@media (hover: hover) and (pointer: fine) {
  .btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(45, 74, 45, 0.28);
  }

  .btn-primary:active {
    transform: scale(0.97);
    box-shadow: none;
  }

  .btn-ghost:hover {
    transform: translateY(-1px);
  }

  .btn-ghost:active {
    transform: scale(0.97);
  }
}


/* ════════════════════════════════════════════
   5. FEATURE CARDS — asymmetric grid
      Breaks the "identical card grid" pattern.
      Layout:
        [Beach Access — tall left]  [Two Bedrooms]
        [Beach Access — tall left]  [Olive Groves]
        [Near Plomari — full width, horizontal]
═══════════════════════════════════════════ */

.features-grid[data-astro-cid-v2cbyr3p] {
  display: grid;
  grid-template-columns: 1.55fr 1fr;
  grid-template-rows: auto auto auto;
  gap: 18px;
  align-items: stretch;
}

/* Beach Access (card 1): spans 2 rows — hero position */
.features-grid[data-astro-cid-v2cbyr3p] .feature-card[data-astro-cid-v2cbyr3p]:nth-child(1) {
  grid-row: 1 / 3;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 280px;
  background: linear-gradient(150deg, #fff 50%, rgba(212, 233, 242, 0.35));
  border-color: rgba(74, 127, 165, 0.18);
}

.features-grid[data-astro-cid-v2cbyr3p] .feature-card[data-astro-cid-v2cbyr3p]:nth-child(1) .feature-icon[data-astro-cid-v2cbyr3p] {
  color: var(--aegean);
}

.features-grid[data-astro-cid-v2cbyr3p] .feature-card[data-astro-cid-v2cbyr3p]:nth-child(1) h3[data-astro-cid-v2cbyr3p] {
  font-size: 20px;
  color: var(--aegean);
}

/* Near Plomari (card 4): full width, horizontal layout */
.features-grid[data-astro-cid-v2cbyr3p] .feature-card[data-astro-cid-v2cbyr3p]:nth-child(4) {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 60px 1fr;
  grid-template-rows: auto auto;
  column-gap: 22px;
  row-gap: 0;
  align-items: start;
  background: rgba(139, 107, 61, 0.04);
  border-color: rgba(139, 107, 61, 0.18);
}

.features-grid[data-astro-cid-v2cbyr3p] .feature-card[data-astro-cid-v2cbyr3p]:nth-child(4) .feature-icon[data-astro-cid-v2cbyr3p] {
  grid-row: 1 / 3;
  grid-column: 1;
  margin-bottom: 0;
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(139, 107, 61, 0.09);
  border-radius: 14px;
  align-self: center;
  color: var(--earth);
}

.features-grid[data-astro-cid-v2cbyr3p] .feature-card[data-astro-cid-v2cbyr3p]:nth-child(4) h3[data-astro-cid-v2cbyr3p] {
  grid-row: 1;
  grid-column: 2;
  align-self: end;
  padding-bottom: 6px;
  color: var(--earth-dark);
}

.features-grid[data-astro-cid-v2cbyr3p] .feature-card[data-astro-cid-v2cbyr3p]:nth-child(4) p[data-astro-cid-v2cbyr3p] {
  grid-row: 2;
  grid-column: 2;
  align-self: start;
}

/* Feature card hover: better easing */
.feature-card[data-astro-cid-v2cbyr3p] {
  transition:
    transform 0.3s var(--ease-expo),
    box-shadow 0.3s var(--ease-expo),
    border-color 0.3s ease;
}

@media (hover: hover) and (pointer: fine) {
  .feature-card[data-astro-cid-v2cbyr3p]:hover {
    transform: translateY(-3px);
    box-shadow: 0 16px 48px rgba(139, 107, 61, 0.11);
    border-color: rgba(196, 168, 130, 0.45);
  }
}

/* Mobile: back to equal 2-col grid */
@media (max-width: 640px) {
  .features-grid[data-astro-cid-v2cbyr3p] {
    grid-template-columns: 1fr 1fr;
  }

  .features-grid[data-astro-cid-v2cbyr3p] .feature-card[data-astro-cid-v2cbyr3p]:nth-child(1) {
    grid-row: auto;
    min-height: auto;
    justify-content: flex-start;
  }

  .features-grid[data-astro-cid-v2cbyr3p] .feature-card[data-astro-cid-v2cbyr3p]:nth-child(4) {
    grid-column: span 2;
    grid-template-columns: 44px 1fr;
    column-gap: 16px;
  }

  .features-grid[data-astro-cid-v2cbyr3p] .feature-card[data-astro-cid-v2cbyr3p]:nth-child(4) .feature-icon[data-astro-cid-v2cbyr3p] {
    width: 44px;
    height: 44px;
  }
}


/* ════════════════════════════════════════════
   6. SCROLL REVEALS — blur + custom easing
      (premium entrance feel)
═══════════════════════════════════════════ */

.reveal-up,
.reveal-left,
.reveal-right {
  opacity: 0;
  transition:
    opacity 0.72s var(--ease-expo),
    transform 0.72s var(--ease-expo),
    filter 0.65s ease;
}

.reveal-up {
  transform: translateY(36px);
  filter: blur(5px);
}

.reveal-left {
  transform: translateX(-36px);
  filter: blur(5px);
}

.reveal-right {
  transform: translateX(36px);
  filter: blur(5px);
}

.reveal-up.is-visible,
.reveal-left.is-visible,
.reveal-right.is-visible {
  opacity: 1;
  transform: none;
  filter: blur(0);
}

/* Stagger delays */
.reveal-delay-1 { transition-delay: 0.05s; }
.reveal-delay-2 { transition-delay: 0.12s; }
.reveal-delay-3 { transition-delay: 0.19s; }
.reveal-delay-4 { transition-delay: 0.26s; }

/* Respect prefers-reduced-motion */
@media (prefers-reduced-motion: reduce) {
  .reveal-up, .reveal-left, .reveal-right {
    filter: none;
    transition: opacity 0.3s ease;
  }
  .reveal-up { transform: translateY(8px); }
  .reveal-left { transform: translateX(-8px); }
  .reveal-right { transform: translateX(8px); }
  .reveal-delay-1, .reveal-delay-2,
  .reveal-delay-3, .reveal-delay-4 {
    transition-delay: 0s;
  }
}


/* ════════════════════════════════════════════
   7. GALLERY — smoother image zoom on hover
═══════════════════════════════════════════ */

.gallery-item[data-astro-cid-ihllb3az] .gallery-item-inner[data-astro-cid-ihllb3az] img {
  transition: transform 0.65s var(--ease-expo);
}

@media (hover: hover) and (pointer: fine) {
  .gallery-item[data-astro-cid-ihllb3az]:hover .gallery-item-inner[data-astro-cid-ihllb3az] img {
    transform: scale(1.04);
  }
}


/* ════════════════════════════════════════════
   8. DIVIDER — gradient fade, more refined
═══════════════════════════════════════════ */

.divider {
  width: 52px;
  height: 1px;
  background: linear-gradient(to right, var(--stone) 0%, transparent 100%);
  border-radius: 0;
  margin-bottom: 28px;
}


/* ════════════════════════════════════════════
   9. MICRO INTERACTIONS — floating buttons
═══════════════════════════════════════════ */

/* WhatsApp fab */
#whatsapp-btn {
  transition:
    transform 0.2s var(--ease-expo),
    box-shadow 0.2s ease;
}

#whatsapp-btn:active {
  transform: scale(0.93);
}

@media (hover: hover) and (pointer: fine) {
  #whatsapp-btn:hover {
    transform: translateY(-3px) scale(1.04);
    box-shadow: 0 12px 32px rgba(37, 211, 102, 0.28);
  }
}

/* Back to top */
#back-to-top {
  transition:
    opacity 0.3s ease,
    transform 0.2s var(--ease-expo),
    background 0.2s ease;
}

#back-to-top:active {
  transform: scale(0.94);
}

@media (hover: hover) and (pointer: fine) {
  #back-to-top:hover {
    transform: translateY(-2px);
  }
}


/* ════════════════════════════════════════════
   10. LIGHTBOX — tighter close/nav transitions
═══════════════════════════════════════════ */

.lightbox-close[data-astro-cid-ihllb3az],
.lightbox-nav[data-astro-cid-ihllb3az] {
  transition:
    background 0.18s ease,
    transform 0.16s var(--ease-expo);
}

.lightbox-close[data-astro-cid-ihllb3az]:active,
.lightbox-nav[data-astro-cid-ihllb3az]:active {
  transform: scale(0.92);
}


/* ════════════════════════════════════════════
   11. SECTION SPACING — more generous rhythm
       (luxury = breathing room)
═══════════════════════════════════════════ */

.section-pad {
  padding: clamp(100px, 11vw, 160px) 0;
}


/* ════════════════════════════════════════════
   12. FORM INPUTS — better focus states
═══════════════════════════════════════════ */

.wizard-card[data-astro-cid-k66kqjni] input,
.wizard-card[data-astro-cid-k66kqjni] select,
.wizard-card[data-astro-cid-k66kqjni] textarea {
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

.wizard-card[data-astro-cid-k66kqjni] input:focus,
.wizard-card[data-astro-cid-k66kqjni] select:focus,
.wizard-card[data-astro-cid-k66kqjni] textarea:focus {
  outline: none;
  border-color: var(--olive-light);
  box-shadow: 0 0 0 3px rgba(107, 140, 90, 0.15);
}
