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

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
  color: #1f2933;
  background-color: #f5f7fa;
}

/* Layout helpers */
.section {
  padding: 4rem 1.5rem;
}

.section-inner {
  max-width: 1100px;
  margin: 0 auto;
}

.two-column {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 2.5rem;
  align-items: start;
}

.subsection {
  margin-bottom: 3rem;
}

/* Header and nav */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: #ffffffee;
  backdrop-filter: blur(6px);
  box-shadow: 0 1px 4px rgba(15, 23, 42, 0.08);
}

.site-header .section-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  font-weight: 700;
  font-size: 1.1rem;
  padding: 0.75rem 1.5rem;
}

.main-nav {
  display: flex;
  align-items: center;
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 1rem;
  margin: 0;
  padding: 0 1.5rem 0 0;
}

.nav-links a {
  text-decoration: none;
  color: #1f2933;
  font-size: 0.95rem;
  padding: 0.5rem 0.75rem;
  border-radius: 999px;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.nav-links a:hover,
.nav-links a:focus-visible {
  background-color: #dde7f3;
  color: #102a43;
}

.nav-toggle {
  display: none;
  margin-right: 1rem;
  border: none;
  background: none;
  font-size: 1.5rem;
  cursor: pointer;
}

/* Hero */
.hero {
  padding-top: 5rem;
  background: radial-gradient(circle at top left, #e3f2ff 0, #f5f7fa 50%, #f5f7fa 100%);
}

.hero-content {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
  gap: 3rem;
  align-items: center;
}

.hero-text h1 {
  font-size: 2.4rem;
  margin-bottom: 1rem;
}

.hero-lead {
  font-size: 1.1rem;
  margin-bottom: 1rem;
}

.hero-links {
  margin-top: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* Hero photos: single image, swap on hover */
.hero-photo {
  position: relative;
  width: 100%;
  max-width: 320px;
  margin: 0 auto;
  border-radius: 1.5rem;
  overflow: hidden;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.35);
  aspect-ratio: 4 / 5;
}

.hero-photo-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.hero-photo-img--hover {
  opacity: 0;
}

.hero-photo:hover .hero-photo-img--hover {
  opacity: 1;
}

.hero-photo:hover .hero-photo-img--primary {
  opacity: 0;
}

/* Headings */
h1,
h2,
h3 {
  color: #102a43;
  margin-top: 0;
}

h2 {
  font-size: 1.7rem;
  margin-bottom: 1rem;
}

h3 {
  font-size: 1.2rem;
  margin-bottom: 0.75rem;
}

/* Paragraphs and lists */
p {
  margin: 0 0 0.75rem 0;
}

ul {
  padding-left: 1.2rem;
  margin-top: 0;
}

/* Image frames and gallery */
.image-frame {
  border-radius: 1.2rem;
  overflow: hidden;
  background: #d9e2ec;
}

.image-frame.tall {
  max-height: 420px;
}

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

.image-frame.center {
  display: flex;
  align-items: center;
  justify-content: center;
}

.image-frame.space-bottom {
  margin-bottom: 1.5rem;
}

/* Make image links feel clickable */
.image-frame a img {
  transition: transform 0.2s ease;
}

.image-frame a:hover img {
  transform: scale(1.03);
}

/* Generic photo grid */
.photo-gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 1rem;
  margin-top: 1.5rem;
}

.photo-gallery-grid figure {
  margin: 0;
  border-radius: 1.2rem;
  overflow: hidden;
  background-color: #d9e2ec;
}

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

/* Family specific styling */
.family-section {
  align-items: stretch;
}

.family-image {
  display: flex;
  height: 100%;
}

.family-main-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Family row gallery, horizontal scroll */
.family-gallery {
  display: flex !important;
  flex-wrap: nowrap !important;
  overflow-x: auto;
  gap: 1rem;
  padding-bottom: 0.5rem;
}

.family-gallery figure {
  min-width: 200px;
  height: 200px;
  border-radius: 1.2rem;
  overflow: hidden;
}

.family-gallery img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.family-gallery {
  scroll-behavior: smooth;
}

/* E-bike Videos */
.video-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.video-large iframe,
.video-small-grid iframe {
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 1rem;
  box-shadow: 0 10px 25px rgba(15, 23, 42, 0.25);
}

.video-small-grid {
  display: grid;
  grid-template-rows: 1fr 1fr;
  gap: 1.5rem;
}

/* Search box */
.search-box {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 0.5rem;
}

.search-box input {
  flex: 1;
  min-width: 180px;
  padding: 0.5rem 0.75rem;
  border-radius: 999px;
  border: 1px solid #9fb3c8;
  font-size: 0.95rem;
}

.search-box button {
  padding: 0.5rem 1rem;
  border-radius: 999px;
  border: 1px solid #2563eb;
  background-color: #2563eb;
  color: #ffffff;
  font-size: 0.9rem;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}

.search-box button:hover {
  background-color: #1d4ed8;
  border-color: #1d4ed8;
}

.search-status {
  font-size: 0.85rem;
  color: #52606d;
  margin-top: 0.5rem;
}

/* Highlighted section, search result */
.section.highlighted {
  background-color: #e3f2ff;
  box-shadow: inset 0 0 0 1px #9fb3c8;
}

/* Footer */
.site-footer {
  background-color: #0b1727;
  color: #d9e2ec;
  padding: 2rem 1.5rem;
}

.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  font-size: 0.9rem;
}

.disclaimer {
  color: #9fb3c8;
  margin-top: 0.5rem;
}

/* Responsive */
@media (max-width: 900px) {
  .hero-content {
    grid-template-columns: 1fr;
  }

  .two-column {
    grid-template-columns: 1fr;
  }

  .site-header .section-inner {
    padding-inline: 0;
  }

  .nav-toggle {
    display: block;
  }

  .nav-links {
    position: absolute;
    right: 0;
    top: 100%;
    background-color: #ffffff;
    flex-direction: column;
    align-items: flex-start;
    padding: 0.75rem 1.2rem;
    margin-top: 0.25rem;
    border-radius: 0 0 0 1rem;
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.15);
    display: none;
  }

  .nav-links.open {
    display: flex;
  }
}

@media (max-width: 600px) {
  .section {
    padding: 3rem 1.25rem;
  }

  .hero-text h1 {
    font-size: 2rem;
  }
}
