/* ───────────────────────────────────────────────────────────
   Eco-Samaná Base Styles – universal, responsive, accessible
   Works with Jekyll (Markdown pages + HTML pages)
   ---------------------------------------------------------- */
/* ✅ Make all images responsive */
img {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 0 auto;
}
/* ✅ Hero image styling */
.hero-image {
  max-width: 800px;
  width: 100%;
  margin: 0 auto;
  border-radius: 12px;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

@media (max-width: 600px) {
  .hero-image {
    max-width: 100%;
    border-radius: 6px;
  }
}

/* 1) Modern CSS Reset (lightweight) */
*, *::before, *::after { box-sizing: border-box; }
html:focus-within { scroll-behavior: smooth; }
html, body { height: 100%; }
body { margin: 0; text-rendering: optimizeLegibility; -webkit-font-smoothing: antialiased; }
img, picture, video, canvas, svg { display: block; max-width: 100%; }
input, button, textarea, select { font: inherit; }
a { text-decoration: none; color: inherit; }
:target { scroll-margin-top: 6rem; } /* anchor links clear the header */

/* 2) Theme tokens */
:root{
  --brand: #0a7a6b;          /* primary */
  --brand-2: #15a392;        /* accent */
  --ink: #1d2330;            /* text */
  --muted: #5b647a;          /* secondary text */
  --bg: #ffffff;             /* page bg */
  --card: #f7faf9;           /* card bg */
  --line: #e8eeec;           /* subtle borders */
  --focus: #ffb703;          /* focus ring */
  --radius: 14px;
  --shadow: 0 8px 24px rgba(0,0,0,.08);
  --container: 1100px;
}

@media (prefers-color-scheme: dark){
  :root{
    --ink:#e8eef0;
    --muted:#9db1b6;
    --bg:#0c1211;
    --card:#141b1a;
    --line:#25302e;
    --shadow: 0 10px 30px rgba(0,0,0,.35);
  }
}

/* 3) Typography */
body{
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, "Helvetica Neue", Arial, "Noto Sans", "Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol";
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  font-size: 16px;
}

h1,h2,h3,h4{
  line-height: 1.25;
  margin: 1.2em 0 .5em;
  font-weight: 700;
}
h1{ font-size: clamp(2rem, 3.5vw, 2.6rem); }
h2{ font-size: clamp(1.5rem, 2.5vw, 1.9rem); }
h3{ font-size: clamp(1.2rem, 2vw, 1.4rem); }
p{ margin: .85em 0; color: var(--ink); }
.lead{ font-size: 1.1rem; color: var(--muted); }

/* 4) Layout helpers */
.container{
  width: min(100% - 2rem, var(--container));
  margin-inline: auto;
}
section{ padding-block: clamp(1.5rem, 4vw, 3rem); }
hr{ border: 0; height: 1px; background: var(--line); margin: 2rem 0; }

/* 5) Header & Nav */
.site-header{
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in oklab, var(--bg) 92%, white);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(6px);
}
.navbar{ display:flex; align-items:center; justify-content:space-between; gap:1rem; padding: .9rem 0; }
.brand{
  display:flex; align-items:center; gap:.6rem; font-weight:800; color:var(--brand);
  letter-spacing:.2px;
}
.nav{
  display:flex; align-items:center; gap:1rem; flex-wrap:wrap;
}
.nav a{
  padding:.5rem .75rem; border-radius:10px; color:var(--muted);
}
.nav a[aria-current="page"], .nav a:hover{
  color: var(--brand); background: color-mix(in oklab, var(--brand) 12%, transparent);
}

/* 6) Footer */
.site-footer{
  border-top: 1px solid var(--line);
  padding: 2rem 0; color: var(--muted); font-size:.95rem;
}

/* 7) Hero image / page headers */
.hero{
  padding: clamp(2rem, 6vw, 4rem) 0;
  background: linear-gradient(180deg, color-mix(in oklab, var(--brand) 6%, transparent), transparent);
}
.hero h1{ margin: 0 0 .4rem; }
.hero .sub{ color: var(--muted); max-width: 60ch; }

.hero-image{ 
  max-width: 80%; border-radius: var(--radius); margin: 1rem auto; display:block; 
  box-shadow: var(--shadow);
}

/* 8) Buttons & links */
.btn, .cta-button{
  display:inline-flex; align-items:center; justify-content:center; gap:.5rem;
  background: var(--brand); color:white; border-radius: 999px;
  padding:.7rem 1.1rem; font-weight:600; border:1px solid transparent;
  box-shadow: 0 6px 16px rgba(10,122,107,.25);
  transition: transform .08s ease, box-shadow .2s ease, background .2s ease;
}
.btn:hover, .cta-button:hover{ transform: translateY(-1px); background: var(--brand-2); }
.btn:active, .cta-button:active{ transform: translateY(0); }
.btn.outline{
  background: transparent; color: var(--brand); border-color: var(--brand);
  box-shadow:none;
}

/* 9) Cards & grids (used by tour cards) */
.card{
  background: var(--card); border:1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1rem;
}
.card > img{ border-radius: calc(var(--radius) - 4px); }

.card-grid{
  display:grid; gap: clamp(1rem, 2.8vw, 1.6rem);
  grid-template-columns: repeat(12, 1fr);
}
.card-grid > *{ grid-column: span 12; }
@media (min-width:700px){
  .card-grid.compact > *{ grid-column: span 6; }
}
@media (min-width:1024px){
  .card-grid.compact > *{ grid-column: span 4; } /* 3-up */
}

/* Tour card anchor block */
.tour-card a{
  display:block; background: var(--card); border:1px solid var(--line);
  border-radius: var(--radius); overflow:hidden; box-shadow: var(--shadow);
  transition: transform .12s ease, box-shadow .2s ease;
  color: inherit;
}
.tour-card a:hover{ transform: translateY(-2px); box-shadow: 0 12px 30px rgba(0,0,0,.12); }
.tour-card img{ width:100%; height:auto; aspect-ratio: 16/10; object-fit: cover; }
.tour-card h3{ margin: .9rem .9rem .2rem; }
.tour-card p{ margin: 0 .9rem 1rem; color: var(--muted); }

/* 10) Forms (Contact page) */
form{ display:grid; gap:.9rem; max-width: 720px; }
input[type="text"], input[type="email"], input[type="tel"], textarea, select{
  width:100%; padding:.75rem .9rem; border-radius:12px; border:1px solid var(--line);
  background: var(--bg); color: var(--ink); outline: none;
}
textarea{ min-height: 140px; resize: vertical; }
input:focus, textarea:focus, select:focus{
  border-color: var(--brand-2); box-shadow: 0 0 0 3px color-mix(in oklab, var(--brand-2) 30%, transparent);
}

/* 11) Markdown content (about.md, faq.md, etc.) */
.prose{
  max-width: 72ch;
}
.prose img{ border-radius: var(--radius); box-shadow: var(--shadow); margin: 1rem auto; }
.prose ul, .prose ol{ padding-left: 1.2rem; }
.prose li{ margin: .35rem 0; }
.prose blockquote{
  margin: 1rem 0; padding: .8rem 1rem; border-left: 4px solid var(--brand); background: color-mix(in oklab, var(--brand) 8%, transparent);
}

/* 12) Tables (if you add any) */
table{ width:100%; border-collapse: collapse; font-size: .98rem; }
th, td{ padding:.7rem .6rem; border-bottom:1px solid var(--line); text-align:left; }
thead th{ background: color-mix(in oklab, var(--brand) 10%, transparent); }

/* 13) Utility classes */
.center{ text-align:center; }
.m-0{ margin:0!important; }
.mt-1{ margin-top:.5rem!important; } .mt-2{ margin-top:1rem!important; } .mt-3{ margin-top:1.5rem!important; }
.mb-1{ margin-bottom:.5rem!important; } .mb-2{ margin-bottom:1rem!important; } .mb-3{ margin-bottom:1.5rem!important; }
.grid{ display:grid; gap:1rem; }
.grid-2{ grid-template-columns: repeat(2, 1fr); }
.grid-3{ grid-template-columns: repeat(3, 1fr); }
@media (max-width:700px){
  .grid-2, .grid-3{ grid-template-columns: 1fr; }
}

/* 14) Accessibility: focus styles */
:where(a, button, input, select, textarea):focus-visible{
  outline: none; box-shadow: 0 0 0 3px var(--focus);
  border-radius: 10px;
}

/* 15) Print tweaks */
@media print{
  .site-header, .site-footer, .btn, .cta-button{ display:none !important; }
  a::after{ content:" (" attr(href) ")"; font-size: .9em; color: #666; }
}
/* Centered, readable page width */
.container { max-width: 1100px; margin: 0 auto; padding: 0 1rem; }

/* Default page spacing */
.page { padding: 2rem 0; }
.page-header { text-align: center; margin-bottom: 1.25rem; }
.page-header .lead { margin-top: .5rem; opacity: .8; }

/* Make common content look centered/clean */
.page-content img { display: block; max-width: 100%; height: auto; margin: 1rem auto; border-radius: 10px; }
.page-content p, .page-content ul, .page-content ol { line-height: 1.7; }
.text-center, .center { text-align: center; }

/* Optional: scale down huge first images on pages */
.hero-image { max-width: 900px; width: 100%; margin: 0 auto; border-radius: 10px; }

/* Cards/grids you already use elsewhere still work */
.grid { display: grid; gap: 1rem; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 700px){ .grid-3 { grid-template-columns: 1fr; } }
.social-links {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-top: 1.5rem;
}

.social-links a {
  color: #333;
  font-size: 1.5rem;
  transition: color 0.3s ease;
}

.social-links a:hover {
  color: #028a0f; /* or your brand color */
}
