:root {
  --bg: #ffffff;
  --fg: #1a1a1a;
  --muted: #9a9a9a;
  --line: #eeeeee;
  --maxw: 1500px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: "Inter", system-ui, -apple-system, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }

/* ---------- Trip header (Pixieset-style) ---------- */
.ghead {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 0.5px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px clamp(14px, 3vw, 40px);
}
.gtitle {
  font-family: "Fraunces", Georgia, serif;
  font-weight: 500;
  font-size: clamp(1.5rem, 2.9vw, 2.1rem);
  line-height: 1.12;
  margin: 0;
  letter-spacing: -0.01em;
}
.gsub {
  margin-top: 6px;
  font-size: 0.85rem;
  line-height: 1.5;
  color: var(--muted);
  max-width: 62ch;
}
.gsub .dl-inline {
  width: 1.15em;
  height: 1.15em;
  vertical-align: -0.25em;
  margin: 0 0.18em;
  color: #1a1a1a;
}
.gactions { display: flex; align-items: center; gap: 8px; }
.gact {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font: inherit;
  font-size: 0.85rem;
  color: #555;
  background: none;
  border: 0.5px solid transparent;
  border-radius: 6px;
  padding: 7px 12px;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}
.gact:hover { background: #f4f4f4; color: var(--fg); }
.gact svg { display: block; }

/* ---------- Videos ---------- */
.videos {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 18px clamp(8px, 1.5vw, 18px) 6px;
}
.vid-h {
  font-family: "Fraunces", Georgia, serif;
  font-weight: 500;
  font-size: 1.15rem;
  margin: 0 0 12px;
  text-align: center;
}
.vid-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 480px), 1fr));
  gap: 14px;
  max-width: 880px;
  margin: 0 auto;
}
.vid-embed {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 10px;
  overflow: hidden;
  background: #0f0f0f;
}
.vid-embed iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}
.vid-facade {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  cursor: pointer;
  background-color: #0f0f0f;
  background-size: cover;
  background-position: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  color: #fff;
}
.vid-play {
  width: 68px;
  height: 48px;
  border-radius: 14px;
  background: #f00;
  position: relative;
  transition: background 0.2s ease, transform 0.2s ease;
}
.vid-facade:hover .vid-play { background: #ff0000; transform: scale(1.06); }
.vid-play::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-40%, -50%);
  border-style: solid;
  border-width: 9px 0 9px 15px;
  border-color: transparent transparent transparent #fff;
}
.vid-cap {
  font-size: 0.9rem;
  letter-spacing: 0.01em;
  color: #fff;
  text-shadow: 0 1px 14px rgba(0, 0, 0, 0.6);
}
.vid-link {
  text-align: center;
  margin: 14px 0 0;
}
.vid-link a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: "Fraunces", Georgia, serif;
  font-size: 0.9rem;
  color: #fff;
  background: #c79a2e;
  border: 1px solid #c79a2e;
  border-radius: 999px;
  padding: 8px 20px;
  transition: background 0.15s ease, border-color 0.15s ease;
}
.vid-link a:hover {
  background: #ad831f;
  border-color: #ad831f;
}

/* ---------- Photo grid (equal-width masonry columns, left-to-right order) ---------- */
.gallery {
  --gap: 4px;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: var(--gap) clamp(8px, 1.5vw, 18px) 64px;
  display: flex;
  gap: var(--gap);
  align-items: flex-start;
}
.gallery .col {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: var(--gap);
}
.gallery a {
  display: block;
  width: 100%;
  overflow: hidden;
  background: #f2f2f2;
  position: relative;
}
.gallery a img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  opacity: 0;
  transition: opacity 0.5s ease, transform 0.6s cubic-bezier(0.2, 0.6, 0.2, 1);
}
.gallery a img.loaded { opacity: 1; }
.gallery a:hover img { transform: scale(1.04); }

/* ---------- Owner index ---------- */
.site-header { max-width: var(--maxw); margin: 0 auto; padding: 80px 24px 48px; text-align: center; }
.site-title {
  font-family: "Fraunces", Georgia, serif;
  font-weight: 500;
  font-size: clamp(2.2rem, 5vw, 3.4rem);
  margin: 0;
  letter-spacing: -0.01em;
}
.site-tagline { color: var(--muted); margin: 12px 0 0; }
.trips {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px 64px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 36px 26px;
}
.trip-cover { overflow: hidden; border-radius: 4px; background: #f4f4f4; }
.trip-cover img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.6s cubic-bezier(0.2,0.6,0.2,1); }
.trip-card:hover .trip-cover img { transform: scale(1.04); }
.trip-meta { display: flex; justify-content: space-between; align-items: baseline; margin-top: 12px; }
.trip-name { font-family: "Fraunces", Georgia, serif; font-size: 1.2rem; font-weight: 500; }
.trip-count { color: var(--muted); font-size: 0.85rem; }

/* ---------- Misc ---------- */
.empty { max-width: 600px; margin: 40px auto; padding: 0 24px; text-align: center; color: var(--muted); }
.gfoot {
  text-align: center;
  color: var(--muted);
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  padding: 40px 24px 64px;
}
.toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  transform: translate(-50%, 12px);
  background: #1a1a1a;
  color: #fff;
  font-size: 0.85rem;
  padding: 10px 18px;
  border-radius: 8px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 50;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- PhotoSwipe white theme ---------- */
.pswp {
  --pswp-bg: #ffffff;
  --pswp-icon-color: #1a1a1a;
  --pswp-icon-color-secondary: #ffffff;
  --pswp-icon-stroke-color: #ffffff;
  --pswp-icon-stroke-width: 0;
}
.pswp__counter {
  color: #1a1a1a;
  text-shadow: none;
  opacity: 0.7;
}
/* Download button (custom): dark, always visible in the toolbar */
.pswp__button--download {
  display: flex !important;
  align-items: center;
  justify-content: center;
  color: #1a1a1a;
  opacity: 0.75;
}
.pswp__button--download:hover { opacity: 1; }
