/* ============================================================
   Rentals in Costa Rica — Home / Portfolio
   Shares the visual language of the Live Jacó site:
   warm cream background, teal primary, sand accents,
   Cormorant Garamond serif + Inter sans.
   ============================================================ */

/* ---------- Reset & base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
  color: var(--c-ink);
  background: var(--c-cream);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--c-primary); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
button { font: inherit; cursor: pointer; }
:focus-visible { outline: 3px solid var(--c-accent); outline-offset: 3px; border-radius: 4px; }

/* ---------- Tokens ---------- */
:root {
  --c-dark: #1c2a33;
  --c-dark-2: #243641;
  --c-primary: #0e5566;
  --c-primary-light: #3d8593;
  --c-cream: #f4e9d3;
  --c-cream-2: #e9dcc1;
  --c-sand: #d8c19a;
  --c-sand-dark: #b89870;
  --c-accent: #b8702f;
  --c-accent-dark: #9a5a23;
  --c-ink: #1c2a33;
  --c-ink-soft: #4a5963;
  --c-ink-mute: #7a8a93;
  --c-on-dark: #f4e9d3;
  --c-whatsapp: #25d366;
  --c-whatsapp-dark: #1ebe5b;

  --font-display: "Cormorant Garamond", "Playfair Display", Georgia, "Times New Roman", serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  --radius-sm: 4px;
  --radius: 10px;
  --radius-lg: 16px;
  --shadow-soft: 0 8px 30px rgba(28, 42, 51, 0.12);
  --shadow-img: 0 16px 40px rgba(28, 42, 51, 0.25);

  --container: 1180px;
  --container-narrow: 880px;

  --space-1: 0.5rem;
  --space-2: 1rem;
  --space-3: 1.5rem;
  --space-4: 2rem;
  --space-5: 3rem;
  --space-6: 4rem;
  --space-7: 6rem;
  --space-8: 8rem;
}

/* ---------- Typography ---------- */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.1;
  margin: 0 0 var(--space-3);
  color: var(--c-ink);
  letter-spacing: -0.005em;
}
h1 {
  font-size: clamp(2.4rem, 5vw + 1rem, 4.6rem);
  font-weight: 600;
  letter-spacing: 0.01em;
  line-height: 1.0;
}
h2 {
  font-size: clamp(1.8rem, 3vw + 0.8rem, 2.6rem);
  font-weight: 500;
  font-style: italic;
}
h3 {
  font-size: clamp(1.05rem, 0.4vw + 1rem, 1.25rem);
  font-weight: 600;
  font-style: normal;
  font-family: var(--font-body);
  letter-spacing: 0.01em;
}
p { margin: 0 0 var(--space-2); }

.eyebrow {
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--c-primary);
  margin-bottom: var(--space-2);
}

.lead {
  font-size: 1.15rem;
  color: var(--c-ink-soft);
  line-height: 1.7;
}

/* ---------- Layout ---------- */
.container { max-width: var(--container); margin: 0 auto; padding: 0 var(--space-4); }
.container-narrow { max-width: var(--container-narrow); margin: 0 auto; padding: 0 var(--space-4); }

.section { padding: var(--space-7) 0; }
.section--dark { background: var(--c-dark); color: var(--c-on-dark); }
.section--dark .eyebrow { color: var(--c-sand); }
.section--dark h2, .section--dark h3 { color: var(--c-on-dark); }

.skip-link {
  position: absolute; top: -40px; left: var(--space-2);
  background: var(--c-primary); color: white; padding: var(--space-1) var(--space-2);
  border-radius: var(--radius-sm); z-index: 100;
}
.skip-link:focus { top: var(--space-2); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: var(--c-cream);
  border-bottom: 1px solid var(--c-cream-2);
}
.site-header__inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: var(--space-2) var(--space-4);
  display: flex; align-items: center; justify-content: space-between;
  gap: var(--space-3);
}
.brand {
  display: flex; flex-direction: column;
  text-decoration: none; color: var(--c-ink);
  line-height: 1.1;
}
.brand__name {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 600;
  letter-spacing: 0.01em;
}
.brand__sub {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--c-primary);
  margin-top: 2px;
}
.lang-toggle {
  display: inline-flex; align-items: center; gap: 0.25rem;
  font-weight: 600; font-size: 0.85rem;
  letter-spacing: 0.1em; text-transform: uppercase;
  text-decoration: none;
  padding: 0.5rem 0.85rem;
  border: 1px solid var(--c-sand-dark);
  border-radius: var(--radius-sm);
  color: var(--c-ink-soft);
  background: transparent;
}
.lang-toggle:hover { background: var(--c-cream-2); }
.lang-toggle__current { color: var(--c-primary); }
.lang-toggle__sep { color: var(--c-ink-mute); }

/* ---------- Hero ---------- */
.hero {
  padding: var(--space-7) 0 var(--space-6);
  position: relative;
  overflow: hidden;
}
.hero::after {
  content: ""; position: absolute;
  bottom: 0; left: 50%;
  transform: translateX(-50%);
  width: 120px; height: 1px;
  background: var(--c-sand-dark);
}
.hero__inner {
  max-width: var(--container-narrow);
  margin: 0 auto;
  padding: 0 var(--space-4);
  text-align: center;
}
.hero h1 { margin-bottom: var(--space-3); }
.hero .lead { max-width: 640px; margin: 0 auto var(--space-3); }

/* ---------- Property cards ---------- */
.props {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-4);
}
.prop {
  display: flex; flex-direction: column;
  background: var(--c-cream-2);
  border-radius: var(--radius-lg);
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  box-shadow: var(--shadow-soft);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.prop:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(28, 42, 51, 0.18);
}
.prop--soon { cursor: default; opacity: 0.78; }
.prop--soon:hover { transform: none; box-shadow: var(--shadow-soft); }
.prop__img {
  aspect-ratio: 4 / 3;
  background: var(--c-sand);
  position: relative;
  overflow: hidden;
}
.prop__img img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  z-index: 1;
}
.prop__placeholder {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--c-sand) 0%, var(--c-sand-dark) 100%);
  color: var(--c-cream);
  font-family: var(--font-display);
  font-size: clamp(1.2rem, 2vw + 0.5rem, 2.2rem);
  font-style: italic;
  letter-spacing: 0.04em;
  text-align: center;
  padding: 0 1rem;
  z-index: 0;
}
.prop__body {
  padding: var(--space-3) var(--space-3) var(--space-4);
  display: flex; flex-direction: column;
  flex: 1;
}
.prop__loc {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--c-primary);
  margin-bottom: var(--space-1);
}
.prop--soon .prop__loc { color: var(--c-ink-mute); }
.prop__title {
  font-family: var(--font-display);
  font-size: 1.7rem;
  font-weight: 600;
  margin: 0 0 var(--space-1);
  letter-spacing: -0.005em;
  line-height: 1.1;
}
.prop__sub {
  color: var(--c-ink-soft);
  font-size: 0.95rem;
  margin: 0 0 var(--space-2);
}
.prop__meta {
  display: flex; flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: auto;
  padding-top: var(--space-2);
  font-size: 0.85rem;
  color: var(--c-ink-soft);
}
.prop__tag {
  background: var(--c-cream);
  border: 1px solid var(--c-sand);
  border-radius: 999px;
  padding: 0.2rem 0.7rem;
  font-size: 0.78rem;
  letter-spacing: 0.02em;
}
.prop__cta {
  display: inline-flex; align-items: center; gap: 0.4rem;
  margin-top: var(--space-2);
  color: var(--c-primary);
  font-weight: 600;
  font-size: 0.9rem;
  letter-spacing: 0.04em;
}
.prop__cta::after { content: "→"; transition: transform 0.2s; }
.prop:hover .prop__cta::after { transform: translateX(4px); }

/* ---------- Contact / dark band ---------- */
.contact { text-align: center; }
.contact .lead { max-width: 540px; margin: 0 auto var(--space-3); color: var(--c-on-dark); opacity: 0.9; }
.btn {
  display: inline-flex; align-items: center; gap: 0.6rem;
  padding: 0.85rem 1.4rem;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  text-decoration: none;
  border: 0;
  transition: transform 0.15s, box-shadow 0.15s;
}
.btn--whatsapp {
  background: var(--c-whatsapp);
  color: white;
}
.btn--whatsapp:hover {
  background: var(--c-whatsapp-dark);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(37, 211, 102, 0.35);
}
.btn-icon { width: 18px; height: 18px; flex-shrink: 0; }

/* ---------- Footer ---------- */
.site-footer {
  padding: var(--space-4) 0 var(--space-5);
  text-align: center;
  font-size: 0.85rem;
  color: var(--c-ink-mute);
}
.site-footer a { color: var(--c-ink-soft); }

/* ---------- Section heading helper ---------- */
.section-head { text-align: center; margin-bottom: var(--space-5); }
.section-head .eyebrow { display: inline-block; }

/* ---------- Responsive tweaks ---------- */
@media (max-width: 640px) {
  .section { padding: var(--space-6) 0; }
  .hero { padding: var(--space-5) 0 var(--space-5); }
  .site-header__inner { padding: var(--space-2); }
}
