/* --- Variables & Base --- */
:root{
  --bg: #F5F5F5;          /* neutral background */
  --text: #333333;        /* dark grey text */
  --accent: #005B96;      /* deep blue accent */
  --max-width: 980px;
  --gap: 1.25rem;
  --header-h: 64px;
  --radius: 8px;
  --transition-time: 400ms;
  --shadow: 0 6px 24px rgba(0,0,0,0.06);
}

*{box-sizing:border-box}
html,body{height:100%}
body {
  margin: 0;
  font-family: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing:antialiased;
  -moz-osx-font-smoothing:grayscale;
  line-height:1.5;
  font-size:16px;
}

/* Utility container */
.container{
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

/* Screen-reader only */
.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

/* --- Header / Navigation --- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-h);
  background: rgba(245,245,245,0.9);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid rgba(0,0,0,0.04);
  z-index: 40;
}

.header-inner{
  display:flex;
  align-items:center;
  justify-content:space-between;
  height:100%;
}

.logo {
  color: var(--text);
  text-decoration: none;
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.02em;
}

.site-nav {
  display:flex;
  gap: 16px;
}

.site-nav .nav-link {
  color: var(--text);
  text-decoration: none;
  font-weight: 600;
  padding: 8px 10px;
  border-radius: 6px;
  transition: background 180ms ease, color 180ms ease;
}

.site-nav .nav-link:hover,
.site-nav .nav-link:focus {
  background: rgba(0, 91, 150, 0.06);
  color: var(--accent);
  outline: none;
}

/* Space for fixed header */
.page-main {
  padding-top: calc(var(--header-h) + 24px);
  min-height: calc(100vh - var(--header-h));
  transition: transform var(--transition-time) ease, opacity var(--transition-time) ease;
  will-change: transform, opacity;
}

/* --- Page transition states --- */
.page-main.is-entering {
  transform: translateX(24px);
  opacity: 0;
  animation: content-enter var(--transition-time) ease forwards;
}
.page-main.is-exiting {
  animation: content-exit var(--transition-time) ease forwards;
}
@keyframes content-enter {
  from { transform: translateX(24px); opacity: 0; }
  to   { transform: translateX(0);    opacity: 1; }
}
@keyframes content-exit {
  from { transform: translateX(0);    opacity: 1; }
  to   { transform: translateX(-24px); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .page-main { transition: none !important; animation: none !important; transform: none !important; opacity: 1 !important; }
}

/* --- Hero / Intro --- */
.hero {
  text-align:center;
  padding: 30px 0 10px;
}
.site-title {
  margin: 0;
  font-size: clamp(1.6rem, 3.6vw, 2.8rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
}
.lede {
  margin-top: 12px;
  color: #4a4a4a;
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}

/* --- Grid utilities --- */
.grid {
  display:grid;
  gap: var(--gap);
}

/* Featured grid on homepage: responsive 2x2 or single column on mobile */
.featured-grid {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  margin-top: 20px;
}

/* Card (shared) */
.featured-card,
.card {
  display:block;
  background: white;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  text-decoration: none;
  color: inherit;
}

/* Buttons inside cards to make them accessible and clickable */
.card .card-button, .featured-card {
  display:block;
  border: 0;
  background: transparent;
  padding: 0;
  text-align: left;
  width: 100%;
  cursor: pointer;
  color: inherit;
}

/* Images inside cards scale nicely */
.featured-card img,
.card img {
  width:100%;
  height: 240px;
  object-fit: cover;
  display:block;
}

/* Caption */
.card-caption, .card-body {
  padding: 12px 14px;
}
.card-caption .caption-sub {
  margin: 6px 0 0;
  color: #666;
  font-size: 0.95rem;
}

/* --- Gallery grid --- */
.masonry {
  grid-template-columns: repeat(3, 1fr);
}
.card-title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
}
.card-desc {
  margin: 6px 0 0;
  color: #555;
  font-size: 0.95rem;
}

/* Hidden state for filtering */
.card.hidden {
  opacity: 0;
  transform: scale(0.98);
  pointer-events: none;
  height: 0;
  margin: 0;
  padding: 0;
  transition: opacity 300ms ease, transform 300ms ease;
}

/* Responsive breakpoints */
@media (max-width: 920px) {
  .masonry { grid-template-columns: repeat(2, 1fr); }
  .featured-grid .featured-card img { height: 200px; }
}
@media (max-width: 600px) {
  .masonry { grid-template-columns: 1fr; }
  .featured-grid { gap: 12px; }
  .featured-card img { height: 160px; }
  .site-nav { display: none; } /* keep header minimal on very small screens; you can add a burger menu later */
}

/* --- About two-column layout --- */
.about-grid {
  display:grid;
  grid-template-columns: 320px 1fr;
  gap: 28px;
  align-items: start;
  padding-bottom: 36px;
}
.headshot {
  width: 100%;
  height: auto;
  border-radius: 10px;
  display:block;
  object-fit: cover;
}
@media (max-width: 820px) {
  .about-grid { grid-template-columns: 1fr; }
  .about-left { order: -1; }
}

/* --- Footer --- */
.site-footer {
  margin-top: 28px;
  padding: 18px 0;
  color: #666;
  font-size: 0.95rem;
}

/* --- Small print / links --- */
a { color: var(--accent); }
a:hover, a:focus { text-decoration: underline; }
.page-heading { font-size: 1.4rem; font-weight:800; margin: 6px 0 0; }
.header-inner .logo { display:inline-block; vertical-align:middle; }

/* ========== Album controls ========== */
/* Container */
.album-controls-wrap { margin-top: 14px; margin-bottom: 6px; }
.album-controls {
  display:flex;
  gap: 10px;
  overflow-x: auto;
  padding: 6px;
  align-items:center;
}

/* buttons */
.album-btn {
  border: 1px solid rgba(0,0,0,0.06);
  background: white;
  padding: 8px 12px;
  border-radius: 999px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 160ms ease, box-shadow 160ms ease;
}
.album-btn:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(0,0,0,0.06); }
.album-btn.active {
  background: var(--accent);
  color: white;
  border-color: rgba(0,91,150,0.9);
}

/* make controls scannable on small screens */
@media (max-width: 520px) {
  .album-controls { gap: 8px; padding-left: 8px; padding-right: 8px; }
  .album-btn { padding: 8px 10px; font-size: 0.95rem; }
}

/* ========== Album Modal ========== */
.album-modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(10,10,10,0.6);
  opacity: 0;
  visibility: hidden;
  transition: opacity 240ms ease, visibility 240ms;
  z-index: 200;
  padding: 24px;
}
.album-modal.open {
  opacity: 1;
  visibility: visible;
}
.album-modal-inner {
  max-width: 920px;
  width: 100%;
  background: #fff;
  border-radius: 12px;
  padding: 18px;
  position: relative;
  box-shadow: 0 20px 60px rgba(0,0,0,0.25);
  display:flex;
  flex-direction:column;
  gap: 12px;
}
.modal-close {
  position: absolute;
  right: 10px;
  top: 8px;
  border: 0;
  background: transparent;
  font-size: 28px;
  cursor: pointer;
}
.modal-slide-wrap {
  display:flex;
  align-items:center;
  justify-content:center;
  gap: 12px;
}
.modal-image img {
  max-width: 100%;
  max-height: calc(80vh - 160px);
  object-fit: contain;
  display:block;
  margin: 0 auto;
  border-radius: 8px;
}
.modal-nav {
  border: 0;
  background: transparent;
  font-size: 32px;
  cursor: pointer;
  width: 48px;
  height: 48px;
  display:flex;
  align-items:center;
  justify-content:center;
}

/* caption */
.modal-caption {
  color: #444;
  font-size: 0.95rem;
  padding: 6px 2px;
  text-align: center;
}

/* mobile adjustments */
@media (max-width: 760px) {
  .album-modal-inner { padding: 12px; border-radius: 8px; }
  .modal-nav { font-size: 24px; width: 40px; height: 40px; }
  .modal-image img { max-height: calc(60vh - 120px); }
}

/* reduced-motion class applied by JS if needed */
.reduced-motion .album-modal,
.reduced-motion .card,
.reduced-motion .album-btn {
  transition: none !important;
}

/* End of stylesheet */
