:root {
  --paper: #faf9f6;
  --ink: #111111;
  --muted: #6e6e6e;
  --line: rgba(30, 33, 29, .14);
  --accent: #a84d34;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: "Inter", sans-serif; -webkit-font-smoothing: antialiased; }
body.lightbox-open { overflow: hidden; }
a { color: inherit; }
img { max-width: 100%; }
button { font: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }

.shell { width: min(1320px, calc(100% - 64px)); margin: 0 auto; }
.site-header { display: flex; justify-content: space-between; align-items: center; min-height: 76px; border-bottom: 1px solid var(--line); }
.back-link { color: var(--muted); font-size: 11px; font-weight: 500; letter-spacing: .02em; text-decoration: none; }
.back-link:hover { color: var(--ink); }
.albums-page { padding-top: 34px; }
.landing-header { padding: 64px 0 72px; }
.landing-header h1 { max-width: 900px; margin: 0; font-size: clamp(44px, 6vw, 80px); font-weight: 400; line-height: .95; letter-spacing: -.05em; }
.landing-header p { max-width: 520px; margin: 20px 0 0; color: var(--muted); font-size: 16px; line-height: 1.6; }
.album-list { display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px 18px; padding: 0 0 80px; }
.album-card { display: block; min-width: 0; text-decoration: none; }
.album-cover { position: relative; aspect-ratio: 3 / 2; overflow: hidden; background: #ece9e3; }
.album-cover img { width: 100%; height: 100%; display: block; object-fit: cover; transition: opacity .25s ease; }
.album-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 28px;
  opacity: 0;
  color: var(--ink);
  text-align: center;
  transition: opacity .25s ease;
}
.album-overlay h2 {
  margin: 0;
  font-family: "Inter", sans-serif;
  font-size: clamp(18px, 2vw, 28px);
  font-weight: 300;
  font-style: italic;
  line-height: 1.2;
}
.album-overlay p { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 15px; margin: 16px 0 0; color: var(--ink); font-size: 12.5px; font-weight: 100; line-height: 1.5; letter-spacing: .01em; }
.album-card:hover .album-cover img,
.album-card:focus-visible .album-cover img { opacity: 0; }
.album-card:hover .album-overlay,
.album-card:focus-visible .album-overlay { opacity: 1; }

.album-header { padding: 70px 0 60px; }
.album-header h1 { max-width: 900px; margin: 0 0 22px; font-family: "Inter", sans-serif; font-size: clamp(48px, 7vw, 96px); font-weight: 400; line-height: .95; letter-spacing: -.05em; }
.album-details { margin: 0; color: var(--muted); font-size: 11px; font-weight: 400; line-height: 1.6; }
.album-technical { margin: 6px 0 0; color: var(--muted); font-size: 11px; font-weight: 300; line-height: 1.6; }
.album-description { max-width: 520px; margin: 0 0 28px; color: var(--muted); font-size: 14px; font-weight: 400; line-height: 1.7; }
.photo-grid { display: grid; grid-template-columns: repeat(4, 1fr); align-items: start; gap: 12px; padding-bottom: 100px; }
.photo-button { display: block; width: 100%; padding: 0; border: 0; background: #e6e3da; cursor: zoom-in; }
.photo-button img { display: block; width: 100%; height: auto; }

.lightbox { width: 100vw; max-width: none; height: 100vh; max-height: none; margin: 0; padding: 0; border: 0; background: rgba(16, 17, 15, .98); color: white; }
.lightbox::backdrop { background: #10110f; }
.lightbox-inner { display: grid; place-items: center; width: 100%; height: 100%; padding: 64px 86px; }
.lightbox-image { display: block; max-width: 100%; max-height: calc(100vh - 128px); object-fit: contain; }
.lightbox button { position: fixed; z-index: 2; display: grid; place-items: center; border: 0; background: transparent; color: white; cursor: pointer; }
.lightbox-close { top: 20px; right: 22px; width: 46px; height: 46px; font-size: 28px; }
.lightbox-prev, .lightbox-next { top: 50%; width: 56px; height: 70px; transform: translateY(-50%); font-size: 25px; }
.lightbox-prev { left: 10px; }.lightbox-next { right: 10px; }
.lightbox-counter { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); color: rgba(255,255,255,.55); font-size: 11px; }

@media (max-width: 760px) {
  .shell { width: min(100% - 32px, 600px); }
  .albums-page { padding-top: 20px; }
  .landing-header { padding: 52px 0 58px; }
  .album-list { grid-template-columns: repeat(2, 1fr); gap: 24px 14px; }
  .album-header { padding: 58px 0 45px; }
  .photo-grid { grid-template-columns: repeat(3, 1fr); gap: 8px; }
  .lightbox-inner { padding: 60px 12px; }
  .lightbox-prev, .lightbox-next { top: auto; bottom: 6px; transform: none; }
}

@media (hover: none) {
  .album-cover { display: flex; flex-direction: column; aspect-ratio: auto; background: transparent; }
  .album-cover img { aspect-ratio: 3 / 2; object-fit: cover; }
  .album-overlay { position: static; display: block; padding: 12px 0 0; opacity: 1; text-align: left; }
  .album-overlay h2 { font-size: 14px; }
  .album-overlay p { justify-content: flex-start; margin-top: 7px; }
}

@media (max-width: 420px) {
  .album-list { grid-template-columns: 1fr; }
  .photo-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; animation: none !important; }
}
