/* ============================================================
   TRIP REPORT SITE, design tokens
   Theme: field-notebook / topo-map. Not a portfolio, a logbook.
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,400;9..144,600;9..144,700&family=Source+Serif+4:ital,wght@0,400;0,600;1,400&family=IBM+Plex+Mono:wght@400;500;600&display=swap');

:root{
  --ink:        #1e2a28;   /* spruce-black, primary text */
  --ink-soft:   #445450;   /* muted body text */
  --paper:      #eae4d4;   /* topo parchment, page background */
  --paper-dim:  #ddd5bf;   /* card / panel background */
  --line:       #a49d86;   /* contour hairline */
  --line-soft:  #cdc6ae;   /* faint rules */
  --teal:       #3c6b5e;   /* alpine-lake accent */
  --teal-deep:  #274b41;
  --rust:       #a1522c;   /* used sparingly, hazard / difficulty */
  --white:      #faf8f1;

  --display: 'Fraunces', serif;
  --body: 'Source Serif 4', Georgia, serif;
  --mono: 'IBM Plex Mono', ui-monospace, monospace;

  --max: 780px;
}

*{ box-sizing:border-box; }

html{ scroll-behavior:smooth; }

body{
  margin:0;
  background:var(--paper);
  color:var(--ink);
  font-family:var(--body);
  font-size:17px;
  line-height:1.65;
  -webkit-font-smoothing:antialiased;
}

a{ color:var(--teal-deep); text-decoration-thickness:1px; text-underline-offset:2px; }
a:hover{ color:var(--rust); }

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

/* ---------- contour-line motif (the signature element) ----------
   A hairline squiggle used as section dividers and as decoration
   behind the masthead, stands in for a topo map's contour lines. */
.contour-rule{
  width:100%; height:14px;
  background-repeat:repeat-x;
  background-size:56px 14px;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='56' height='14' viewBox='0 0 56 14'%3E%3Cpath d='M0 7 C 8 1, 16 13, 28 7 S 48 1, 56 7' stroke='%23a49d86' stroke-width='1' fill='none'/%3E%3C/svg%3E");
  opacity:.9;
  margin:2.5rem 0;
}

/* ---------- masthead ---------- */
.masthead{
  background:var(--ink);
  color:var(--paper);
  padding:2.6rem 1.5rem 2.2rem;
}
.masthead-inner{
  max-width:var(--max); margin:0 auto;
  display:flex; align-items:baseline; justify-content:space-between; gap:1rem; flex-wrap:wrap;
}
.masthead h1{
  font-family:var(--display);
  font-weight:600;
  font-size:1.9rem;
  margin:0;
  letter-spacing:.01em;
}
.masthead h1 a{ color:var(--paper); text-decoration:none; }
.masthead .tag{
  font-family:var(--mono);
  font-size:.75rem;
  letter-spacing:.06em;
  text-transform:uppercase;
  color:#b9c4bd;
}
.masthead nav a{
  color:#c9d0c7; font-family:var(--mono); font-size:.8rem;
  margin-left:1.2rem; text-decoration:none; letter-spacing:.03em;
}
.masthead nav a:hover{ color:var(--white); }

/* ---------- shared page frame ---------- */
main{ max-width:var(--max); margin:0 auto; padding:2.5rem 1.5rem 5rem; }

/* ---------- homepage: the log ---------- */
.log-intro{ max-width:var(--max); margin:0 auto; padding:2rem 1.5rem 0; }
.log-intro p{ color:var(--ink-soft); max-width:56ch; }

.log-entry{
  display:grid;
  grid-template-columns:100px 1fr;
  gap:1.3rem;
  padding:1.6rem 0;
  border-top:1px solid var(--line-soft);
  text-decoration:none;
  color:inherit;
}
.log-entry:first-of-type{ border-top:none; }
.log-thumb-col{ display:flex; flex-direction:column; gap:.5rem; }
.log-thumb{
  width:100%; aspect-ratio:4/3; object-fit:cover;
  border-radius:2px; border:1px solid var(--line-soft);
}
.log-date{
  font-family:var(--mono); font-size:.78rem; color:var(--ink-soft);
  padding-top:.3rem; letter-spacing:.02em;
}
.log-body h2{
  font-family:var(--display); font-weight:600; font-size:1.35rem;
  margin:0 0 .35rem;
  color:var(--ink);
}
.log-meta{
  font-family:var(--mono); font-size:.72rem; text-transform:uppercase;
  letter-spacing:.05em; color:var(--teal-deep); margin-bottom:.5rem;
}
.log-meta span:not(:last-child)::after{ content:'·'; margin:0 .5em; color:var(--line); }
.log-body p{ margin:0; color:var(--ink-soft); font-size:.98rem; }
.log-entry:hover .log-body h2{ color:var(--rust); }

/* ---------- report stat block, styled like a GPS/altimeter readout ---------- */
.statblock{
  font-family:var(--mono);
  background:var(--ink);
  color:var(--white);
  border-radius:2px;
  padding:1rem 1.2rem;
  display:grid;
  grid-template-columns:repeat(auto-fit, minmax(110px,1fr));
  gap:.9rem 1.4rem;
  margin:1.6rem 0 2rem;
}
.statblock div{ display:flex; flex-direction:column; gap:.2rem; }
.statblock div.wide{ grid-column:1 / -1; }
.statblock .k{ font-size:.65rem; text-transform:uppercase; letter-spacing:.08em; color:#9fb3ab; }
.statblock .v{ font-size:.95rem; color:var(--white); }

/* ---------- day-by-day breakdown table ---------- */
.day-breakdown{ margin:1.6rem 0 2rem; }
.day-breakdown .table-scroll{ overflow-x:auto; }
.day-breakdown table{
  width:100%; border-collapse:collapse;
  font-family:var(--mono); font-size:.82rem; white-space:nowrap;
}
.day-breakdown th{
  text-align:left; font-size:.65rem; text-transform:uppercase; letter-spacing:.07em;
  color:var(--ink-soft); border-bottom:1px solid var(--line); padding:.5rem .7rem;
}
.day-breakdown td{
  padding:.6rem .7rem; border-bottom:1px solid var(--line-soft); white-space:normal;
}
.day-breakdown td:first-child, .day-breakdown th:first-child{ white-space:nowrap; }
.day-breakdown .day-num{ color:var(--teal-deep); font-weight:600; }
.day-breakdown-note{
  font-family:var(--mono); font-size:.72rem; color:var(--ink-soft);
  margin-top:.6rem; line-height:1.5;
}

/* ---------- per-section quick stats, e.g. under a day's <h2> ---------- */
.section-stats{
  font-family:var(--mono); font-size:.78rem; color:var(--teal-deep);
  letter-spacing:.03em; margin:-.5rem 0 1.4rem;
}

/* ---------- optional full-bleed hero image behind a report's title ---------- */
.report-hero{
  height:360px;
  background-size:cover;
  background-position:center;
  position:relative;
  display:flex;
  align-items:flex-end;
}
.report-hero::after{
  content:'';
  position:absolute; inset:0;
  background:linear-gradient(to top, rgba(30,42,40,.88), rgba(30,42,40,.05) 65%);
}
.report-hero-inner{
  position:relative; z-index:1;
  max-width:var(--max); margin:0 auto; width:100%;
  padding:0 1.5rem 1.7rem;
}
.report-hero .report-region{ color:#cfe0d8; }
.report-hero h1{
  font-family:var(--display); font-weight:700; font-size:2.1rem;
  margin:.3rem 0 0; line-height:1.15; color:var(--white);
}

/* ---------- report header ---------- */
.report-header{ margin-bottom:.2rem; }
.report-region{
  font-family:var(--mono); font-size:.75rem; text-transform:uppercase;
  letter-spacing:.06em; color:var(--teal-deep);
}
.report-header h1{
  font-family:var(--display); font-weight:700; font-size:2.1rem;
  margin:.3rem 0 0; line-height:1.15;
}

/* ---------- map ---------- */
#map{
  width:100%; height:380px;
  border:1px solid var(--line-soft);
  filter:sepia(8%) saturate(85%);
  margin:1.5rem 0;
}
.map-note{ font-family:var(--mono); font-size:.72rem; color:var(--ink-soft); margin-top:-1rem; margin-bottom:1.5rem;}

/* ---------- article body ---------- */
.report-body h2{
  font-family:var(--display); font-size:1.3rem; margin-top:2.2rem;
}
.report-body p{ color:var(--ink); }
.report-body blockquote{
  margin:1.4rem 0; padding-left:1rem; border-left:2px solid var(--rust);
  color:var(--ink-soft); font-style:italic;
}

/* ---------- photo gallery ---------- */
.gallery{
  display:grid; grid-template-columns:repeat(auto-fill, minmax(190px,1fr));
  gap:.6rem; margin:1.8rem 0;
}
.gallery img{
  width:100%; height:170px; object-fit:cover; border-radius:2px;
  cursor:zoom-in; border:1px solid var(--line-soft);
}
.gallery figure{ margin:0; }
.gallery figcaption{ font-family:var(--mono); font-size:.68rem; color:var(--ink-soft); margin-top:.3rem; }

/* lightbox */
.lightbox{
  position:fixed; inset:0; background:rgba(20,26,25,.92);
  display:none; align-items:center; justify-content:center; z-index:50; padding:2rem;
}
.lightbox.open{ display:flex; }
.lightbox img{ max-height:88vh; max-width:92vw; object-fit:contain; }
.lightbox-close{
  position:absolute; top:1.2rem; right:1.6rem; color:var(--white);
  font-family:var(--mono); font-size:.85rem; cursor:pointer; letter-spacing:.05em;
}

/* ---------- gear / footer notes ---------- */
.notebox{
  background:var(--paper-dim); border:1px solid var(--line-soft);
  padding:1.1rem 1.3rem; margin:2rem 0; border-radius:2px;
}
.notebox h3{
  font-family:var(--mono); font-size:.75rem; text-transform:uppercase;
  letter-spacing:.06em; margin:0 0 .6rem; color:var(--teal-deep);
}
.notebox ul{ margin:0; padding-left:1.2rem; }

footer{
  text-align:center; padding:2.5rem 1.5rem 3rem;
  font-family:var(--mono); font-size:.72rem; color:var(--ink-soft);
}

@media (max-width:560px){
  .log-entry{ grid-template-columns:1fr; gap:.3rem; }
  .masthead-inner{ flex-direction:column; align-items:flex-start; }
  .report-header h1{ font-size:1.6rem; }
  .report-hero{ height:220px; }
  .report-hero h1{ font-size:1.6rem; }
}

/* ---------- inline photo, dropped mid-paragraph in the article body ---------- */
.inline-figure{
  max-width:440px;
  margin:1.8rem auto;
}
.inline-figure img{
  width:100%;
  max-height:380px;
  object-fit:cover;
  border-radius:2px;
  border:1px solid var(--line-soft);
  cursor:zoom-in;
}
.inline-figure figcaption{
  font-family:var(--mono);
  font-size:.72rem;
  color:var(--ink-soft);
  margin-top:.4rem;
  text-align:center;
}

/* ---------- two photos side by side, e.g. for a before/after or comparison ---------- */
.figure-pair{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:1rem;
  margin:1.8rem 0;
}
.figure-pair figure{ margin:0; }
.figure-pair img{
  width:100%;
  height:260px;
  object-fit:cover;
  border-radius:2px;
  border:1px solid var(--line-soft);
  cursor:zoom-in;
}
.figure-pair figcaption{
  font-family:var(--mono);
  font-size:.72rem;
  color:var(--ink-soft);
  margin-top:.4rem;
  text-align:center;
}
@media (max-width:560px){
  .figure-pair{ grid-template-columns:1fr; }
}