/* ============================================================
   Mexico City Trip — Casa Azul aesthetic
   Cobalt + marigold + terracotta on warm paper. Mobile-first.
   ============================================================ */

:root {
  --cobalt:      #1c4aa0;
  --cobalt-deep: #14336f;
  --cobalt-ink:  #0d2646;
  --marigold:    #f2a63b;
  --marigold-dk: #d98a1f;
  --terracotta:  #c0562f;
  --leaf:        #3a7d5d;
  --cream:       #f6efe1;
  --cream-2:     #efe6d4;
  --card:        #fffdf7;
  --ink:         #1b232e;
  --muted:       #5c6875;
  --line:        #e4dcc9;
  --line-strong: #d6cbb2;
  --shadow:      0 1px 2px rgba(20,40,80,.05), 0 8px 24px rgba(20,40,80,.06);
  --shadow-lg:   0 2px 6px rgba(20,40,80,.08), 0 18px 40px rgba(20,40,80,.12);
  --radius:      16px;
  --radius-sm:   10px;
  --container:   860px;
  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--sans);
  color: var(--ink);
  background: var(--cream);
  line-height: 1.6;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; display: block; }

a { color: var(--cobalt); text-decoration: none; }
a:hover { text-decoration: underline; }

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 20px;
}

/* ---------- Typography ---------- */
h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.12; margin: 0; letter-spacing: -0.01em; }
.kicker {
  font-family: var(--sans);
  font-weight: 600;
  font-size: 12.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--marigold-dk);
}
.section-num {
  font-family: var(--serif);
  font-style: italic;
  color: var(--terracotta);
  font-size: 15px;
}
.today-pill {
  display: inline-block; margin-left: 8px; padding: 2px 9px; vertical-align: 2px;
  font-family: var(--sans); font-style: normal; font-weight: 700; font-size: 11px;
  letter-spacing: .1em; text-transform: uppercase;
  background: var(--marigold); color: #3a2708; border-radius: 999px;
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  background:
    radial-gradient(120% 80% at 85% -10%, #2a63c4 0%, rgba(42,99,196,0) 55%),
    linear-gradient(160deg, var(--cobalt) 0%, var(--cobalt-deep) 100%);
  color: #fbf7ec;
  overflow: hidden;
  padding: 64px 0 76px;
}
.hero::after {
  /* subtle marigold horizon line */
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 6px;
  background: linear-gradient(90deg, var(--terracotta), var(--marigold) 45%, var(--leaf));
}
.hero .leaf {
  position: absolute;
  right: -40px; top: -30px;
  width: 260px; height: 260px;
  opacity: .16;
  color: #cfe0ff;
  transform: rotate(8deg);
  pointer-events: none;
}
.hero h1 {
  font-size: clamp(52px, 13vw, 92px);
  font-weight: 600;
  margin: 10px 0 6px;
  letter-spacing: -0.02em;
}
.hero .sub {
  font-family: var(--serif);
  font-style: italic;
  /* scales with the screen so the tagline stays on one line — it's ~26em wide; re-measure if the text changes */
  font-size: clamp(12px, calc((100vw - 40px) / 26.6), 25px);
  color: #dfe8ff;
  margin: 0 0 22px;
}
.hero .home {
  font-size: 15px;
  color: #cdd9f2;
  margin: 0 0 26px;
  display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: center;
}
.hero .home strong { color: #fff; font-weight: 600; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--sans);
  font-weight: 600; font-size: 15px;
  padding: 12px 20px;
  border-radius: 999px;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: transform .12s ease, background .15s ease, border-color .15s ease, color .15s ease;
  text-decoration: none;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn-primary { background: var(--marigold); color: #3a2708; }
.btn-primary:hover { background: #ffb949; }
.btn-ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,.5); }
.btn-ghost:hover { border-color: #fff; background: rgba(255,255,255,.08); }
.btn-solid { background: var(--cobalt); color: #fff; }
.btn-solid:hover { background: var(--cobalt-deep); }
.btn-sm { padding: 8px 14px; font-size: 13.5px; }

/* ---------- Sticky day nav ---------- */
.daynav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(246,239,225,.92);
  backdrop-filter: saturate(1.4) blur(8px);
  -webkit-backdrop-filter: saturate(1.4) blur(8px);
  border-bottom: 1px solid var(--line-strong);
}
.daynav-inner {
  display: flex; gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
  padding: 10px 16px;
  max-width: var(--container);
  margin: 0 auto;
}
.daynav-inner::-webkit-scrollbar { display: none; }
.daynav a {
  flex: 0 0 auto;
  font-weight: 600; font-size: 14px;
  color: var(--muted);
  padding: 7px 14px;
  border-radius: 999px;
  white-space: nowrap;
  border: 1.5px solid transparent;
  transition: all .15s ease;
}
.daynav a:hover { color: var(--cobalt); text-decoration: none; background: var(--cream-2); }
.daynav a.active {
  color: var(--cobalt);
  background: #fff;
  border-color: var(--line-strong);
  box-shadow: var(--shadow);
}
.daynav a.today::after {
  content: ""; display: inline-block;
  width: 6px; height: 6px; margin-left: 6px; vertical-align: 2px;
  border-radius: 50%; background: var(--marigold);
}

/* ---------- Sections ---------- */
section { padding: 46px 0; }
.section-head { margin-bottom: 24px; }
.section-head h2 { font-size: clamp(28px, 6.5vw, 38px); margin-top: 6px; }
.section-head .theme { color: var(--muted); font-family: var(--serif); font-style: italic; font-size: 18px; margin-top: 4px; }
.day-section { scroll-margin-top: 62px; }
.day-section + .day-section { border-top: 1px solid var(--line); }
#glance, #options, #logistics { scroll-margin-top: 62px; }

/* alternate very subtle band */
.band { background: linear-gradient(180deg, var(--cream) 0%, var(--cream-2) 100%); }

/* ---------- At a glance ---------- */
.glance-grid { display: flex; flex-direction: column; gap: 10px; }
.glance-day { }
.glance-day h3 {
  font-size: 14px; font-family: var(--sans); font-weight: 700;
  letter-spacing: .12em; text-transform: uppercase; color: var(--cobalt);
  margin-bottom: 8px; padding-bottom: 6px; border-bottom: 2px solid var(--line-strong);
}
.glance-row {
  display: grid; grid-template-columns: 82px 1fr; gap: 12px;
  padding: 7px 0; align-items: baseline;
}
.glance-row .t { color: var(--terracotta); font-weight: 600; font-size: 14px; font-variant-numeric: tabular-nums; }
.glance-row .p { font-size: 15.5px; }
.glance-row .p .where { color: var(--muted); font-size: 13.5px; }

/* ---------- Timeline / day cards ---------- */
.timeline { display: flex; flex-direction: column; gap: 16px; }
.event {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px 18px 16px;
  position: relative;
}
.event .time {
  display: inline-block;
  font-weight: 600; font-size: 13px;
  color: #fff; background: var(--cobalt);
  padding: 3px 10px; border-radius: 999px;
  margin-bottom: 10px;
  font-variant-numeric: tabular-nums;
}
.event.free .time { background: var(--leaf); }
.event h3 { font-size: 21px; margin-bottom: 4px; }
.event .meta {
  display: flex; flex-wrap: wrap; gap: 6px 14px;
  font-size: 13.5px; color: var(--muted);
  margin: 6px 0 10px;
}
.event .meta a { font-weight: 600; }
.event p { margin: 8px 0; font-size: 15.5px; }
.event .notes { margin-top: 10px; display: flex; flex-direction: column; gap: 6px; }
.event .note {
  font-size: 14px; color: #46402f;
  background: #fbf0d8; border: 1px solid #f0dda9;
  border-radius: var(--radius-sm); padding: 8px 12px;
}
.event .note b { color: var(--terracotta); }

/* tags */
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.tag {
  font-size: 12px; font-weight: 600;
  padding: 3px 10px; border-radius: 999px;
  background: var(--cream-2); color: var(--muted);
  border: 1px solid var(--line-strong);
}
.tag.res { background: #e8f0e6; color: #2f5b3d; border-color: #cbe0c8; }
.tag.ticket { background: #fde0d6; color: var(--terracotta); border-color: #f6c6b2; }
.tag.transport { background: #e5edfb; color: var(--cobalt); border-color: #c9d9f5; }

/* option list */
.options { display: flex; flex-direction: column; gap: 14px; }
.option {
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 16px 18px; box-shadow: var(--shadow);
}
.option h3 { font-size: 18px; margin-bottom: 4px; }
.option .lbl { color: var(--terracotta); font-family: var(--serif); font-style: italic; font-size: 14px; }
.option p { margin: 6px 0 0; font-size: 15px; color: #38424e; }
.sun-list { display: flex; flex-direction: column; gap: 14px; }
.sun-list .sun-more { align-self: flex-start; }

/* ---------- Footer / logistics ---------- */
.footer { background: var(--cobalt-deep); color: #dce6fb; padding: 44px 0 40px; }
.footer h2 { color: #fff; font-size: 26px; margin-bottom: 18px; }
.footer .log-grid { display: flex; flex-direction: column; gap: 18px; }
.log-item h4 { font-family: var(--sans); font-size: 12.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--marigold); margin: 0 0 6px; }
.log-item p { margin: 0; font-size: 15px; color: #d4dffa; }
.log-item a { color: #fff; font-weight: 600; }

/* ---------- Responsive ---------- */
@media (min-width: 620px) {
  .glance-row { grid-template-columns: 100px 1fr; }
  .footer .log-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px 32px; }
}
