*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  min-height: 100vh;
  font-family: "Quicksand", system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", sans-serif;
  color: #3b3b3b;
  background-color: #f2eee8;
  background-image: url("../img/fabric-textured.jpg");
  background-size: 512px 512px;
  background-repeat: repeat;
  margin: 0;
}

/* ---------- TOP BAR & NAV ---------- */

.top-bar {
  position: relative;
  padding: 1rem 2rem 0.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand-mark {
  font-family: "Henny Penny", cursive;
  font-size: 1.3rem;
  color: #44507a;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.25);
}

.brand-mark a {
  color: inherit;
  text-decoration: none;
}

/* On landing page: no small logo, menu right-aligned */
.landing-page .top-bar {
  justify-content: flex-end;
}

.landing-page .brand-mark {
  display: none;
}

.main-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 1.25rem;
}

.main-nav a {
  text-decoration: none;
  font-size: 0.95rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: #4b4b4b;
  text-shadow: 0 1px 1px rgba(255, 255, 255, 0.7);
  position: relative;
}

.main-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -3px;
  width: 0;
  height: 2px;
  background: rgba(68, 80, 122, 0.85);
  transition: width 0.18s ease-out;
}

.main-nav a:hover::after,
.main-nav a.active::after {
  width: 100%;
}

/* ---------- LANDING LAYOUT ---------- */

.landing {
  max-width: 980px;
  margin: 0 auto;
  padding: 3.5rem 1.5rem 3rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.hero-logo {
  margin-bottom: 1.8rem;
}

.hero-logo h1 {
  margin: 0;
  font-family: "Henny Penny", cursive;
  font-size: clamp(48px, 7.2vw, 72px);
  color: #44507a;
  text-shadow: 0 6px 12px rgba(0, 0, 0, 0.3),
    0 0 2px rgba(255, 255, 255, 0.85);
}

/* ---------- ICON ROW (landing page) ---------- */

.hero-icons {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1.75rem;
  margin-bottom: 2.5rem;
}

.hero-icon-link {
  position: relative;
  display: inline-block;
  transform: scale(1);
  transition: transform 0.18s ease-out;
}

/* Tooltip under icons */
.hero-icon-link::after {
  content: attr(data-tooltip);
  position: absolute;
  left: 50%;
  bottom: -1.1rem;
  transform: translateX(-50%);
  font-size: 0.75rem;
  color: #3b3b3b;
  white-space: nowrap;
  text-shadow: 0 1px 1px rgba(255, 255, 255, 0.85);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.12s ease-out, transform 0.12s ease-out;
}

.hero-icon-link:hover::after {
  opacity: 1;
  transform: translateX(-50%);
}

/* Icon image itself */
.hero-icon {
  width: 66px;
  height: 66px;
  display: block;
  filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.25));
  transition: filter 0.18s ease-out;
}

.hero-icon-link:hover {
  transform: scale(1.2);
}

.hero-icon-link:hover .hero-icon {
  filter: drop-shadow(0 16px 32px rgba(0, 0, 0, 0.3));
}

/* ---------- LANDING HERO PHOTO & TEXT ---------- */

.landing,
.photos-main {
  max-width: 980px;
  margin: 0 auto;
  padding: 0 1.5rem 2.5rem;
  box-sizing: border-box;
}

/* landing hero photo: framed & centered */
.landing .hero-photo img,
.hero-photo img {
  max-width: 720px;
  width: 100%;
  display: block;
  margin: 1.5rem auto 0;
  border: 10px solid #ffffff;
  border-radius: 0;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.35);
  transition:
    transform 0.18s ease,
    box-shadow 0.18s ease;
}

/* hover: frame and photo enlarge together */
.hero-photo-link:hover img {
  transform: scale(1.03);
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.45);
}

/* Landing page: text under hero photo */
.invitation p {
  font-family: "Solitreo", cursive;
  font-size: 1.2rem;
  line-height: 1.6;
  text-align: center;
  margin: 1.2rem auto 0;
  max-width: 720px;
}

/* ---------- PHOTOS PAGE HEADER ---------- */

.photos-header h1 {
  font-family: "Henny Penny", cursive;
  font-size: 2.4rem;
  letter-spacing: 0.03em;
  margin: 1.5rem 0 0.25rem;
  text-align: left;
}

.photos-header .photos-subtitle {
  font-family: "Quicksand", sans-serif;
  font-size: 0.98rem;
  color: #444;
  margin: 0;
}

/* ---------- YEAR NAV STRIP ---------- */

.year-nav {
  max-width: 980px;
  margin: 1.25rem auto 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.year-nav__scroll {
  overflow-x: auto;
  flex: 1;
}

.year-nav__track {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.8rem;
  padding: 0.2rem 0.3rem;
}

/* each "year" is just an icon button */
.year-nav__year {
  border: none;
  background: transparent;
  padding: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  cursor: pointer;
}

/* calendar icons themselves */
.year-nav__icon {
  width: 48px;
  height: 48px;
  filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.25));
  transition: transform 0.15s ease, filter 0.15s ease;
}

/* hide text label under icons */
.year-nav__label {
  display: none !important;
}

/* active year gets a bit more “pop” */
.year-nav__year.active .year-nav__icon {
  transform: scale(1.08);
  filter: drop-shadow(0 7px 12px rgba(0, 0, 0, 0.35));
}

/* subtle hover effect on calendar icons */
.year-nav__year:hover .year-nav__icon {
  transform: scale(1.05);
  filter: drop-shadow(0 6px 10px rgba(0, 0, 0, 0.3));
}

/* ---------- ARROWS: SOLID BLUE BUTTONS ---------- */

.year-nav__arrow {
  border: 2px solid #44507a !important;
  background: #44507a !important;
  color: #ffffff !important;
  width: 2.1rem;
  height: 2.1rem;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.35);
  opacity: 1 !important;
  transition:
    background 0.15s ease,
    color 0.15s ease,
    box-shadow 0.15s ease,
    transform 0.15s ease;
}

/* arrow glyph inside */
.year-nav__arrow span {
  color: #ffffff !important;
}

.year-nav__arrow:hover:not(:disabled) {
  background: #ffffff !important;
  color: #44507a !important;
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.4);
  transform: translateY(-1px);
}

.year-nav__arrow:hover:not(:disabled) span {
  color: #44507a !important;
}

.year-nav__arrow:disabled {
  opacity: 0.5 !important;
  cursor: default;
  box-shadow: none;
}

/* ---------- GALLERY / SCATTERED TILES ---------- */

.gallery {
  max-width: 980px;
  margin: 1.5rem auto 0;
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  justify-content: flex-start;
}

.photo-block {
  width: 260px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.4rem;
}

.photo-block.hidden {
  display: none;
}

.photo-card {
  position: relative;
  background: #fdfdfd;
  padding: 0.5rem;
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.25);
  border-radius: 10px;
  transform-origin: center center;
  transform: translateY(var(--offset-y, 0px)) rotate(var(--tilt, 0deg));
  transition: transform 0.18s ease-out, box-shadow 0.18s ease-out;
}

.photo-card img {
  width: 100%;
  display: block;
  border-radius: 6px;
  object-fit: cover;
}

.photo-card:hover {
  transform: translateY(calc(var(--offset-y, 0px) - 4px))
    rotate(var(--tilt, 0deg)) scale(1.05);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.hero-caption {
  margin: 0.35rem 0 0;
  font-family: "Solitreo", "Quicksand", system-ui, sans-serif;
  font-size: 1.35rem;
  line-height: 1.4;
  color: #444343;
}

@media (max-width: 640px) {
  .hero-caption {
    font-size: 1.05rem;
  }
}

/* ---------- EVENT MODAL ---------- */

.event-modal.hidden {
  display: none;
}

.event-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
}

.event-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
}

.event-modal__content {
  position: relative;
  max-width: 960px;
  margin: 4vh auto;
  background: #ffffff;
  border-radius: 12px;
  padding: 1rem 1.5rem 1.5rem;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35);
}

.event-modal__image-wrap img {
  width: 100%;
  max-height: 65vh;
  object-fit: contain;
  border-radius: 8px;
}

.event-modal__caption {
  margin-top: 0.75rem;
  font-size: 1rem;
  font-family: "Solitreo", "Quicksand", system-ui, sans-serif;
}

.event-modal__clinical {
  font-size: 0.95rem;
  opacity: 0.85;
}

.event-modal__close,
.event-modal__nav,
.event-modal__back {
  cursor: pointer;
}

.event-modal__nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  border: none;
  background: rgba(255, 255, 255, 0.9);
  border-radius: 999px;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}

.event-modal__nav--prev {
  left: 0.5rem;
}

.event-modal__nav--next {
  right: 0.5rem;
}

.event-modal__close {
  position: absolute;
  top: 0.2rem;
  right: 0.6rem;
  border: none;
  background: transparent;
  font-size: 1.9rem;
  line-height: 1;
}

.event-modal__back {
  margin-top: 0.75rem;
  border: none;
  background: #edf0f7;
  padding: 0.3rem 0.8rem;
  border-radius: 999px;
  font-size: 0.9rem;
}

.event-modal__related {
  margin-top: 0.6rem;
  font-size: 0.9rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
  color: #444;
}

.event-modal__related-label {
  margin-right: 0.25rem;
}

.event-modal__related-year {
  border: none;
  background: #edf0f7;
  border-radius: 999px;
  padding: 0.15rem 0.6rem;
  font-size: 0.85rem;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.15s ease;
}

.event-modal__related-year:hover {
  background: #dde2f0;
  transform: translateY(-1px);
}

/* ---------- LOCK MODAL (Future Self video) ---------- */

.lock-modal.hidden {
  display: none;
}

.lock-modal {
  position: fixed;
  inset: 0;
  z-index: 1200;
}

.lock-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
}

.lock-modal__content {
  position: relative;
  max-width: 960px;
  margin: 4vh auto;
  background: #000;
  border-radius: 10px;
  padding: 0.75rem 0.75rem 1rem;
  box-shadow: 0 22px 48px rgba(0, 0, 0, 0.4);
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.lock-modal__video {
  width: 100%;
  max-height: 80vh;
  border-radius: 6px;
  background: #000;
}

.lock-modal__controls {
  display: flex;
  justify-content: flex-end;
}

.lock-modal__button {
  border: none;
  border-radius: 999px;
  padding: 0.4rem 0.9rem;
  font-size: 0.9rem;
  cursor: pointer;
  background: #edf0f7;
}

/* ---------- ROLE TOGGLE (Family / Team) ---------- */

.role-toggle {
  margin-top: 0.75rem;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: "Quicksand", sans-serif;
  font-size: 0.8rem;
}

.role-toggle__label {
  color: #444;
}

.role-toggle__btn {
  border: 1px solid #ccc;
  background: rgba(255, 255, 255, 0.9);
  border-radius: 999px;
  padding: 0.2rem 0.7rem;
  font-size: 0.78rem;
  cursor: pointer;
  font-family: "Quicksand", sans-serif;
  transition:
    background 0.15s ease,
    color 0.15s ease,
    box-shadow 0.15s ease,
    border-color 0.15s ease;
}

.role-toggle__btn--active {
  background: #44507a;
  color: #ffffff;
  border-color: #44507a;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.25);
}

/* ---------- CONTACT PAGE LAYOUT ---------- */

.contact-main {
  max-width: 980px;
  margin: 0 auto;
  padding: 0 1.5rem 2.5rem;
  box-sizing: border-box;
}

.contact-header h1 {
  font-family: "Henny Penny", cursive;
  font-size: 2.4rem;
  letter-spacing: 0.03em;
  margin: 1.5rem 0 0.25rem;
}

.contact-subtitle {
  font-family: "Quicksand", sans-serif;
  font-size: 0.98rem;
  color: #444;
  margin: 0 0 1.5rem;
}

.contact-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.contact-card {
  flex: 1 1 280px;
  background: rgba(255, 255, 255, 0.92);
  border-radius: 1.25rem;
  padding: 1.25rem 1.5rem;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.25);
  font-family: "Quicksand", sans-serif;
}

.contact-card h2 {
  margin: 0 0 0.5rem;
  font-size: 1.2rem;
  color: #44507a;
}

.contact-card p {
  margin: 0.3rem 0;
  font-size: 0.95rem;
}

.contact-email {
  font-family: "Solitreo", cursive;
  font-size: 1.05rem;
}

.contact-note {
  font-size: 0.86rem;
  color: #666;
}

.contact-form-section {
  margin-top: 0.5rem;
}

.contact-form-section h2 {
  font-size: 1.3rem;
  margin: 0 0 0.5rem;
  color: #44507a;
  font-family: "Quicksand", sans-serif;
}

.contact-form-note {
  font-size: 0.9rem;
  color: #555;
  margin: 0 0 1rem;
  font-family: "Quicksand", sans-serif;
}

.contact-form {
  max-width: 520px;
  background: rgba(255, 255, 255, 0.9);
  border-radius: 1.25rem;
  padding: 1.25rem 1.5rem 1.5rem;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.2);
}

.form-row {
  display: flex;
  flex-direction: column;
  margin-bottom: 0.9rem;
}

.form-row label {
  font-size: 0.85rem;
  margin-bottom: 0.25rem;
  color: #444;
  font-family: "Quicksand", sans-serif;
}

.form-row input,
.form-row textarea {
  font-family: "Quicksand", sans-serif;
  font-size: 0.95rem;
  padding: 0.5rem 0.6rem;
  border-radius: 0.5rem;
  border: 1px solid #ccc;
  outline: none;
  box-sizing: border-box;
}

.form-row input:focus,
.form-row textarea:focus {
  border-color: #44507a;
  box-shadow: 0 0 0 2px rgba(68, 80, 122, 0.2);
}

.contact-submit {
  margin-top: 0.3rem;
  border: none;
  border-radius: 999px;
  padding: 0.55rem 1.4rem;
  font-size: 0.95rem;
  font-family: "Quicksand", sans-serif;
  cursor: pointer;
  background: #44507a;
  color: #ffffff;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.3);
  transition:
    background 0.15s ease,
    transform 0.15s ease,
    box-shadow 0.15s ease;
}

.contact-submit:hover {
  background: #5a6598;
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.35);
}

/* ---------- VIDEOS PAGE ---------- */

.videos-main {
  max-width: 980px;
  margin: 0 auto;
  padding: 0 1.5rem 2.5rem;
  box-sizing: border-box;
}

.videos-header h1 {
  font-family: "Henny Penny", cursive;
  font-size: 2.4rem;
  letter-spacing: 0.03em;
  margin: 1.5rem 0 0.25rem;
}

.videos-subtitle {
  font-family: "Quicksand", sans-serif;
  font-size: 0.98rem;
  color: #444;
  margin: 0 0 1.5rem;
}

/* === VIDEOS GRID & FILM-STRIP TILES === */

.videos-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  justify-content: flex-start;
}

/* each tile: narrow, like a film strip */
.video-card {
  flex: 0 0 330px;        /* 270 window + sprockets baked into 330px filmstrip */
  max-width: 330px;
  background: transparent;
  border-radius: 0;
  padding: 0;
  font-family: "Quicksand", sans-serif;
  cursor: pointer;
}

/* hover = enlarge + stronger shadow, like landing icons */
.video-card:hover .video-thumb {
  transform: scale(1.08);
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.45);
}

/* FILM STRIP AREA */

.video-thumb {
  position: relative;
  width: 330px;           /* full filmstrip.png width */
  height: 200px;
  margin-bottom: 0.6rem;
  background: transparent;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.4);
  transform: scale(1);
  transform-origin: center center;
  transition:
    transform 0.18s ease-out,
    box-shadow 0.18s ease-out;
  overflow: visible;
}

/* the thumbnail image (270x200), centered in the inner window */
.video-thumb img,
.video-thumb-placeholder {
  position: relative;
  z-index: 1;
  display: block;
  width: 270px;
  height: 200px;
  border-radius: 0;
  object-fit: cover;
  margin-left: 30px;      /* 30px sprocket area baked into filmstrip */
}

/* text fallback if no thumbnail */
.video-thumb-placeholder {
  background: #222;
  color: #f5f5f5;
  font-size: 0.9rem;
  font-family: "Quicksand", sans-serif;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 0.5rem;
}

/* overlay: single filmstrip image (frame + sprockets + holes) */
.video-thumb::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background-image: url("../video/filmstrip.png");
  background-repeat: no-repeat;
  background-position: center center;
  background-size: 330px 200px;
}

/* TEXT UNDER THE STRIP */

.video-card h2 {
  margin: 0.35rem 0 0.2rem;
  font-size: 0.95rem;
  color: #44507a;
}

.video-meta {
  margin: 0;
  font-size: 0.85rem;
  color: #555;
}

/* ---------- DOCUMENTS PAGE ---------- */

.docs-main {
  max-width: 980px;
  margin: 0 auto;
  padding: 0 1.5rem 2.5rem;
  box-sizing: border-box;
}

.docs-header h1 {
  font-family: "Henny Penny", cursive;
  font-size: 2.4rem;
  letter-spacing: 0.03em;
  margin: 1.5rem 0 0.25rem;
}

.docs-subtitle {
  font-family: "Quicksand", sans-serif;
  font-size: 0.98rem;
  color: #444;
  margin: 0 0 1.5rem;
}

.docs-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.doc-card {
  background: rgba(255, 255, 255, 0.92);
  border-radius: 1.25rem;
  padding: 1rem 1.25rem;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.25);
  font-family: "Quicksand", sans-serif;
}

.doc-card h2 {
  margin: 0 0 0.3rem;
  font-size: 1.05rem;
  color: #44507a;
}

.doc-meta {
  margin: 0;
  font-size: 0.9rem;
  color: #555;
}

/* ---------- UNIFY TOP-LEFT LOGO ON INNER PAGES ---------- */

.photos-page .brand-mark a,
.videos-page .brand-mark a,
.documents-page .brand-mark a,
.contact-page .brand-mark a {
  font-family: "Henny Penny", cursive;
  font-size: 1.6rem;
  letter-spacing: 0.04em;
  line-height: 1;
  text-decoration: none;
}

/* ---------- UTILITIES ---------- */

.hidden {
  display: none;
}

/* ---------- RESPONSIVE ---------- */

@media (max-width: 640px) {
  .top-bar {
    padding: 0.75rem 1rem 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.4rem;
  }

  .main-nav ul {
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 0.75rem;
  }

  .landing {
    padding-top: 2.5rem;
  }

  .photos-main {
    padding-top: 2rem;
  }

  .gallery {
    justify-content: center;
  }
}
