:root {
  --ink: #12262b;
  --ink-soft: #3a555c;
  --paper: #f3fafb;
  --ocean: #0e7490;
  --ocean-deep: #155e75;
  --card: #ffffff;
  --font-display: "Fraunces", Georgia, serif;
  --font-body: "Source Sans 3", "Segoe UI", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  min-height: 100vh;
  color: var(--ink);
  font-family: var(--font-body);
  background:
    radial-gradient(ellipse 80% 50% at 10% 0%, rgba(14, 116, 144, 0.14), transparent 50%),
    radial-gradient(ellipse 60% 40% at 100% 20%, rgba(231, 213, 181, 0.55), transparent 45%),
    linear-gradient(180deg, #f7fcfd 0%, #eef7f9 40%, #e7f1f3 100%);
}

.hero {
  padding: clamp(2.5rem, 7vw, 5rem) clamp(1.5rem, 5vw, 4rem) 1.5rem;
  max-width: 64rem;
  margin: 0 auto;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.eyebrow {
  margin: 0 0 0.5rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: 0.85rem;
  color: var(--ocean);
  animation: rise 0.75s ease both;
}

.brand {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(3.8rem, 12vw, 6.2rem);
  font-weight: 700;
  line-height: 0.95;
  color: var(--ocean-deep);
  animation: rise 0.85s ease both 0.1s;
}

.lead {
  margin: 1rem 0 0;
  max-width: 34rem;
  font-size: clamp(1.1rem, 2.2vw, 1.35rem);
  line-height: 1.5;
  color: var(--ink-soft);
  animation: rise 0.85s ease both 0.2s;
}

.content {
  padding: 0 clamp(1.5rem, 5vw, 4rem) 3rem;
  max-width: 64rem;
  margin: 0 auto;
}

.toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.toolbar h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--ocean-deep);
}

.hint {
  margin: 0;
  font-size: 0.95rem;
  color: var(--ink-soft);
}

.hint code {
  font-size: 0.9em;
  padding: 0.1rem 0.35rem;
  border-radius: 0.35rem;
  background: rgba(14, 116, 144, 0.1);
}

.trip-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(16.5rem, 1fr));
  gap: 1.1rem;
}

.trip-card {
  display: flex;
  flex-direction: column;
  background: var(--card);
  border-radius: 1.1rem;
  overflow: hidden;
  border: 1px solid rgba(21, 94, 117, 0.12);
  box-shadow: 0 10px 28px rgba(18, 38, 43, 0.06);
}

.trip-open {
  position: relative;
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: #d9eef3;
  cursor: pointer;
}

.trip-open:focus-visible {
  outline: 3px solid var(--ocean);
  outline-offset: -3px;
}

.trip-cover {
  aspect-ratio: 16 / 10;
  width: 100%;
  object-fit: cover;
  background: #d9eef3;
  display: block;
}

.photo-count {
  position: absolute;
  right: 0.7rem;
  bottom: 0.7rem;
  padding: 0.25rem 0.55rem;
  border-radius: 999px;
  background: rgba(18, 38, 43, 0.72);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 600;
}

.trip-body {
  padding: 1rem 1.1rem 1.15rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  flex: 1;
}

.trip-dates {
  margin: 0;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ocean);
}

.trip-body h3 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.35rem;
  color: var(--ink);
}

.trip-place {
  margin: 0;
  font-weight: 600;
  color: var(--ocean-deep);
  font-size: 0.95rem;
}

.trip-blurb {
  margin: 0.35rem 0 0;
  color: var(--ink-soft);
  line-height: 1.45;
  font-size: 0.98rem;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.75rem;
  padding: 0;
  list-style: none;
}

.tags li {
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  background: rgba(14, 116, 144, 0.1);
  color: var(--ocean-deep);
  font-size: 0.78rem;
  font-weight: 600;
}

.gallery-trigger {
  margin-top: 0.9rem;
  align-self: flex-start;
  border: 0;
  border-radius: 999px;
  padding: 0.45rem 0.9rem;
  background: var(--ocean);
  color: #fff;
  font: inherit;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
}

.gallery-trigger:hover,
.gallery-trigger:focus-visible {
  background: var(--ocean-deep);
  outline: none;
}

.gallery-dialog {
  width: min(96vw, 56rem);
  max-height: 92vh;
  margin: auto;
  padding: 0;
  border: 0;
  border-radius: 1.1rem;
  background: #0f1f24;
  color: #e8f4f7;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
}

.gallery-dialog::backdrop {
  background: rgba(8, 18, 22, 0.72);
}

.gallery-shell {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 1rem 1rem 1.1rem;
}

.gallery-header {
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: center;
  gap: 0.75rem;
}

.gallery-header h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.35rem;
}

.gallery-counter {
  margin: 0;
  font-size: 0.9rem;
  color: #9ec4cf;
}

.gallery-close {
  border: 0;
  border-radius: 999px;
  padding: 0.4rem 0.85rem;
  background: rgba(255, 255, 255, 0.12);
  color: inherit;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}

.gallery-close:hover,
.gallery-close:focus-visible {
  background: rgba(255, 255, 255, 0.22);
  outline: none;
}

.gallery-stage {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: min(52vh, 28rem);
  background: #081418;
  border-radius: 0.75rem;
  overflow: hidden;
}

.gallery-stage-image {
  max-width: 100%;
  max-height: min(52vh, 28rem);
  object-fit: contain;
  display: block;
}

.gallery-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 2.5rem;
  height: 2.5rem;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
}

.gallery-nav:hover,
.gallery-nav:focus-visible {
  background: rgba(255, 255, 255, 0.28);
  outline: none;
}

.gallery-nav-prev {
  left: 0.6rem;
}

.gallery-nav-next {
  right: 0.6rem;
}

.gallery-thumbs {
  display: flex;
  gap: 0.45rem;
  overflow-x: auto;
  padding-bottom: 0.15rem;
}

.gallery-thumb {
  flex: 0 0 auto;
  width: 4.25rem;
  height: 3rem;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 0.45rem;
  overflow: hidden;
  background: #12313a;
  cursor: pointer;
}

.gallery-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.gallery-thumb.is-active,
.gallery-thumb:focus-visible {
  border-color: #5ec8e0;
  outline: none;
}

.empty {
  padding: 2rem;
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.7);
  color: var(--ink-soft);
}

.footer {
  padding: 1rem clamp(1.5rem, 5vw, 4rem) 2rem;
  color: var(--ocean);
  font-size: 0.9rem;
  text-align: center;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .eyebrow,
  .brand,
  .lead {
    animation: none;
  }
}
