/* Pamphlett-Tennyson Sea Scouts — site theme.
   All styling lives in this one file. Mobile-first. */

:root {
  --navy: #0b2b4c;        /* header, footer, headings */
  --navy-light: #14406e;  /* hover states, submenu */
  --gold: #f0b429;        /* accent — scout gold */
  --sea: #1e7f9e;         /* links */
  --ink: #24313f;         /* body text */
  --paper: #ffffff;
  --mist: #eef3f7;        /* subtle backgrounds */
}

* { box-sizing: border-box; }

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

.wrap {
  max-width: 62rem;
  margin: 0 auto;
  padding: 0 1rem;
}

/* ---------- header & navigation ---------- */

.site-header {
  background: var(--navy);
  border-bottom: 4px solid var(--gold);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  padding-top: 0.6rem;
  padding-bottom: 0.6rem;
}

.site-logo img {
  display: block;
  height: 52px;
  width: auto;
}

.site-nav { position: relative; }

.nav-toggle { display: none; }

.nav-toggle-label {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
  cursor: pointer;
}

.nav-toggle-label span {
  display: block;
  width: 26px;
  height: 3px;
  background: #fff;
  border-radius: 2px;
}

.nav-menu {
  display: none;
  list-style: none;
  margin: 0;
  padding: 0;
  width: 100%;
}

.nav-toggle:checked ~ .nav-menu { display: block; }

.nav-menu a {
  display: block;
  color: #fff;
  text-decoration: none;
  padding: 0.55rem 0.8rem;
}

.nav-menu a:hover,
.nav-menu li.current > a {
  color: var(--gold);
}

.submenu {
  list-style: none;
  margin: 0;
  padding-left: 1rem;
}

/* mobile: the toggle shows the full menu, submenus inline */
@media (max-width: 47.99rem) {
  .nav-menu { flex-basis: 100%; }
}

/* desktop: horizontal menu with hover/focus dropdowns */
@media (min-width: 48rem) {
  .nav-toggle-label { display: none; }

  .nav-menu {
    display: flex;
    width: auto;
  }

  .nav-menu > li { position: relative; }

  .submenu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 13rem;
    background: var(--navy-light);
    padding: 0.3rem 0;
    border-radius: 0 0 6px 6px;
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.25);
    z-index: 10;
  }

  .nav-menu > li:hover .submenu,
  .nav-menu > li:focus-within .submenu {
    display: block;
  }
}

/* ---------- content ---------- */

main {
  padding-top: 1.5rem;
  padding-bottom: 3rem;
}

h1, h2, h3 {
  color: var(--navy);
  line-height: 1.25;
}

a { color: var(--sea); }
a:hover { color: var(--navy-light); }

img {
  max-width: 100%;
  height: auto;
  border-radius: 6px;
}

table {
  border-collapse: collapse;
  width: 100%;
  margin: 1rem 0;
  font-size: 0.95rem;
}

th, td {
  border: 1px solid #cdd9e2;
  padding: 0.45rem 0.6rem;
  text-align: left;
}

th { background: var(--mist); color: var(--navy); }

/* wide tables scroll instead of breaking the page on phones */
.table-scroll { overflow-x: auto; }

blockquote {
  margin: 1rem 0;
  padding: 0.5rem 1rem;
  border-left: 4px solid var(--gold);
  background: var(--mist);
}

/* ---------- homepage hero ---------- */

.hero {
  margin: 0 0 1.5rem;
}

.hero img {
  width: 100%;
  border-radius: 8px;
}

.hero-title {
  margin: 1rem 0 0.25rem;
}

.tagline {
  font-size: 1.15rem;
  color: var(--navy-light);
  margin-top: 0;
}

/* call-to-action buttons on the homepage */
.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 1.5rem 0;
}

.button {
  display: inline-block;
  background: var(--navy);
  color: #fff;
  text-decoration: none;
  padding: 0.6rem 1.2rem;
  border-radius: 6px;
  font-weight: 600;
}

.button:hover { background: var(--navy-light); color: var(--gold); }

.button.gold {
  background: var(--gold);
  color: var(--navy);
}

.button.gold:hover { background: #d99e15; color: var(--navy); }

/* ---------- calendar page ---------- */

.calendar-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1rem 0;
}

.calendar-filter .button {
  padding: 0.4rem 0.9rem;
  font-size: 0.95rem;
}

/* the Google Calendar iframe: full width, tall enough for a month grid */
.calendar-embed {
  background: var(--mist);
  border-radius: 8px;
  overflow: hidden;
}

.calendar-embed iframe {
  display: block;
  width: 100%;
  height: 600px;
  border: 0;
}

@media (min-width: 48rem) {
  .calendar-embed iframe { height: 720px; }
}

.site-calendar { margin-bottom: 2rem; }
.site-calendar h2 { margin-bottom: 0.5rem; }

/* "Upcoming events" box on section pages */
.calendar-links {
  margin: 2rem 0;
  padding: 1rem 1.25rem;
  background: var(--mist);
  border-left: 4px solid var(--gold);
  border-radius: 6px;
}

.calendar-links h2 { margin-top: 0; }
.calendar-links ul { padding-left: 1.2rem; }
.calendar-links li { margin-bottom: 0.4rem; }

/* ---------- footer ---------- */

.site-footer {
  background: var(--navy);
  color: #d7e2ec;
  margin-top: 2rem;
  border-top: 4px solid var(--gold);
  font-size: 0.95rem;
}

.footer-inner {
  display: grid;
  gap: 1.25rem;
  padding-top: 1.5rem;
  padding-bottom: 1rem;
}

@media (min-width: 48rem) {
  .footer-inner { grid-template-columns: repeat(3, 1fr); }
}

.site-footer strong { color: #fff; }
.site-footer a { color: var(--gold); }

/* social links in the footer: icon + label, easy to add more later */
.social-links {
  list-style: none;
  margin: 0.75rem 0 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.social-link {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  color: var(--gold);
  text-decoration: none;
}

.social-link:hover,
.social-link:focus-visible { color: #fff; }

.social-icon {
  flex: none;
  display: block;
  width: 22px;
  height: 22px;
}

.footer-note {
  padding-bottom: 1.25rem;
  font-size: 0.85rem;
  color: #9fb3c6;
}
