:root {
  --ink: #1c1c1c;
  --ink-soft: #555;
  --paper: #ffffff;
  --paper-dim: #f7f6f4;
  --line: #e6e4e0;
  --accent: #a85c32;
  --max-width: 1180px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
}

h1, h2, h3, .logo, .card-title, .post-title {
  font-family: "Fraunces", Georgia, serif;
  font-weight: 600;
  letter-spacing: -0.01em;
}

a { color: inherit; text-decoration: none; }

.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* Header */
.site-header {
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(6px);
  z-index: 50;
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  padding: 14px 0;
}
.logo-block {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.logo {
  font-size: 1.5rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.tagline {
  margin-top: 2px;
  font-size: 0.68rem;
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0.02em;
  color: var(--ink-soft);
  white-space: nowrap;
}
.tagline strong {
  color: var(--accent);
  font-weight: 600;
}
.main-nav {
  display: flex;
  align-items: center;
  gap: 32px;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.nav-dropdown { position: relative; }
.dropdown-panel {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: var(--paper);
  border: 1px solid var(--line);
  min-width: 200px;
  padding: 8px 0;
  box-shadow: 0 12px 24px rgba(0,0,0,0.06);
}
.nav-dropdown:hover .dropdown-panel { display: block; }
.dropdown-panel a {
  display: block;
  padding: 8px 18px;
  font-size: 0.8rem;
  text-transform: none;
  letter-spacing: normal;
}
.dropdown-panel a:hover { background: var(--paper-dim); color: var(--accent); }

/* Places mega-menu: spans the full header width (like anywhereweroam.com's
   Places menu) rather than a small box under the nav link. Achieved by
   removing positioning from this specific dropdown's wrapper so the panel's
   containing block becomes .site-header (position: sticky) instead of the
   narrow nav-dropdown div. */
.nav-dropdown--places { position: static; }
.dropdown-panel--places {
  left: 0;
  right: 0;
  width: 100%;
  min-width: 0;
  border-left: none;
  border-right: none;
  border-top: none;
  padding: 0;
}
.dropdown-panel--places.is-open { display: block; }
.dropdown-panel-inner {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 6px 24px;
  padding: 28px 24px;
}
.dropdown-col { padding: 0 10px; }
.dropdown-heading {
  display: block;
  padding: 4px 8px;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
  margin-bottom: 2px;
}
.dropdown-panel--places a { padding: 6px 8px; }

/* Mobile nav */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 32px;
  height: 32px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  flex-shrink: 0;
}
.nav-toggle span {
  display: block;
  height: 2px;
  width: 100%;
  background: var(--ink);
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.site-header.mobile-nav-open .nav-toggle span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.site-header.mobile-nav-open .nav-toggle span:nth-child(2) { opacity: 0; }
.site-header.mobile-nav-open .nav-toggle span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.mobile-nav {
  display: none;
  flex-direction: column;
  border-top: 1px solid var(--line);
  padding: 8px 24px 12px;
}
.mobile-nav a {
  padding: 14px 0;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  border-bottom: 1px solid var(--line);
}
.mobile-nav a:last-child { border-bottom: none; }

@media (max-width: 900px) {
  .main-nav { display: none; }
  .nav-toggle { display: flex; }
  .site-header.mobile-nav-open .mobile-nav { display: flex; }
}

/* Home hero */
.home-hero {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 85vh;
  padding: 60px 0;
  text-align: center;
  border-bottom: 1px solid var(--line);
  overflow: hidden;
  background-color: var(--paper-dim);
}
.home-hero-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 68%;
  z-index: 0;
}
.home-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,0.35), rgba(0,0,0,0.55));
  z-index: 1;
}
.home-hero .wrap { position: relative; z-index: 2; }
.home-hero h1 { font-size: 3rem; margin: 0 0 12px; color: #fff; }
.home-hero p { color: rgba(255,255,255,0.9); font-size: 1.15rem; margin: 0; }

/* Sections */
.section { padding: 64px 0; }
.section.narrow { max-width: 720px; }
.section.narrow h2 { margin-top: 2em; font-size: 1.6rem; }
.section.narrow h3 { margin-top: 1.6em; font-size: 1.2rem; color: var(--accent); }
.section.narrow p { margin: 1em 0; }
.section-title {
  font-size: 2rem;
  margin: 0 0 32px;
}
.breadcrumb {
  font-size: 0.85rem;
  color: var(--ink-soft);
  margin-bottom: 24px;
}
.breadcrumb a:hover { color: var(--accent); }
.empty-note { color: var(--ink-soft); font-style: italic; }

/* Card grid */
.card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}
@media (max-width: 900px) {
  .card-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .card-grid { grid-template-columns: 1fr; }
}
.card {
  display: block;
  color: var(--ink);
  border: 1px solid var(--line);
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 32px rgba(0,0,0,0.08);
}
.card-image {
  position: relative;
  height: 220px;
  overflow: hidden;
  background-color: var(--paper-dim);
}
.card-image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.card-body { padding: 20px; }
.card-eyebrow {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
}
.card-title {
  font-size: 1.2rem;
  margin: 8px 0;
}
.card-excerpt {
  font-size: 0.9rem;
  color: var(--ink-soft);
  margin: 0;
}

/* Pills */
.pill-row { display: flex; flex-wrap: wrap; gap: 12px; }
.pill {
  border: 1px solid var(--line);
  padding: 10px 20px;
  border-radius: 999px;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.pill:hover { border-color: var(--accent); color: var(--accent); }

/* Post */
.post-hero {
  position: relative;
  height: 60vh;
  min-height: 360px;
  overflow: hidden;
  background-color: var(--paper-dim);
}
.post-hero-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}
.post-hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  display: flex;
  align-items: flex-end;
  padding: 48px 0;
  background: linear-gradient(to top, rgba(0,0,0,0.65), rgba(0,0,0,0));
}
.post-eyebrow {
  color: #fff;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.8rem;
  margin: 0 0 8px;
}
.post-title {
  color: #fff;
  font-size: 2.5rem;
  margin: 0;
}
.post-body {
  max-width: 760px;
  padding: 48px 24px;
  font-size: 1.05rem;
}
.post-body h2 {
  margin-top: 2.2em;
  font-size: 1.5rem;
}
.post-body img {
  max-width: 100%;
  height: auto;
  margin: 24px 0;
  cursor: zoom-in;
}

/* Photo grids: two side by side, or two on top + one larger below, each
   with an optional caption underneath. Built with plain HTML pasted into
   the post body (see admin notes) so markdown authoring stays simple. */
.photo-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin: 32px 0 0;
}
.photo-grid img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  margin: 0;
}
.photo-grid--pair img,
.photo-grid--feature img {
  aspect-ratio: 4 / 3;
}
/* the image-optimization pipeline wraps each <img> in a <picture>, which
   becomes the actual grid item - so the "span both columns" rule has to
   target that wrapper, not the inner img with the .feature class */
.photo-grid--feature img.feature,
.photo-grid--feature picture:has(img.feature) {
  grid-column: 1 / -1;
}
.photo-grid--feature img.feature {
  aspect-ratio: 16 / 9;
}
.photo-grid--feature picture:has(img.feature) img {
  aspect-ratio: 16 / 9;
}
.photo-caption {
  margin: 10px 0 32px;
  font-size: 0.85rem;
  color: var(--ink-soft);
  text-align: center;
  font-style: italic;
}
@media (max-width: 600px) {
  .photo-grid { grid-template-columns: 1fr; }
}

/* Prev/next post navigation */
.post-nav {
  display: flex;
  gap: 24px;
  max-width: 760px;
  margin: 24px auto 0;
  padding: 32px 24px 0;
  border-top: 1px solid var(--line);
}
.post-nav-link {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 16px 20px;
  border: 1px solid var(--line);
  color: var(--ink);
  transition: border-color 0.2s ease, background 0.2s ease;
}
.post-nav-link:hover {
  border-color: var(--accent);
  background: var(--paper-dim);
}
.post-nav-next { text-align: right; }
.post-nav-spacer { flex: 1; }
.post-nav-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
}
.post-nav-title {
  font-family: "Fraunces", Georgia, serif;
  font-size: 1.05rem;
}
@media (max-width: 600px) {
  .post-nav { flex-direction: column; }
  .post-nav-next { text-align: left; }
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--line);
  padding: 32px 0;
  color: var(--ink-soft);
  font-size: 0.85rem;
}

/* Lightbox for post-body photos */
.lightbox-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 300;
  background: rgba(0, 0, 0, 0.92);
  align-items: center;
  justify-content: center;
  padding: 40px;
}
.lightbox-overlay.is-open { display: flex; }
.lightbox-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.5);
  cursor: default;
}
.lightbox-close {
  position: absolute;
  top: 20px;
  right: 24px;
  background: none;
  border: none;
  color: #fff;
  font-size: 2.5rem;
  line-height: 1;
  cursor: pointer;
  padding: 8px;
}
@media (max-width: 600px) {
  .lightbox-overlay { padding: 16px; }
}
