/* Rich Lee Fine Art Portfolio */
:root {
  --bg: #f7f5f0;
  --surface: #fff;
  --border: #ddd;
  --text: #333;
  --muted: #6b6b6b;
  --accent: #7a5f38;
  --white: #fff;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: Verdana, 'Times New Roman', serif;
  font-size: 17px;
  line-height: 1.7;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; /* display: block; */ }


/* ---- SKIP LINK ---- */
.skip-link {
  position: fixed;
  top: 0;
  left: 1rem;
  z-index: 9999;
  padding: 0.5rem 1rem;
  background: var(--accent);
  color: #fff;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 0.9rem;
  border-radius: 0 0 4px 4px;
  text-decoration: none;
  transform: translateY(-100%);
  transition: transform 0.15s ease;
}
.skip-link:focus {
  transform: translateY(0);
}

/* ---- FOCUS STYLES ---- */
a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 2px;
}

.art-item:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

#lightbox-close:focus-visible,
#lightbox-prev:focus-visible,
#lightbox-next:focus-visible,
#lightbox-cta:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 4px;
  border-radius: 2px;
}

/* ---- NAV / SIDEBAR ---- */
.site-layout {
  display: flex;
  min-height: 100vh;
}

.sidebar {
  width: 200px;
  min-width: 200px;
  background: var(--surface);
  border-right: 1px solid var(--border);
  padding: 2.5rem 1.5rem;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}

.sidebar .logo {
  font-size: .9rem;

  color: #222;
  display: block;
  margin-bottom: 2rem;
  text-decoration: none;
}

.sidebar .logo strong {  font-weight: bold; }
  
  
.sidebar nav a {
  display: block;
  color: var(--muted);
  font-size: 0.88rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.75rem;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-weight: 500;
}

.sidebar nav a:hover,
.sidebar nav a.active {
  color: #222;
  text-decoration: none;
}

/* ---- MAIN ---- */
main {
  flex: 1;
  padding: 3rem 2.5rem;
  max-width: 1200px;
}

/* ---- INTRO PAGE ---- */
.splash {
  max-width: 800px;
  margin: 3rem auto;
  text-align: center;
}

.splash h1 {
  font-size: 2.5rem;
  color: #222;
  margin-bottom: 1.5rem;
  font-weight: normal;
  letter-spacing: 0.02em;
}

.splash p {
  font-size: 1.05rem;
  margin-bottom: 1rem;
  color: var(--text);
}

.btn {
  display: inline-block;
  margin-top: 1.5rem;
  padding: 0.65rem 2rem;
  background: var(--accent);
  color: #fff;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  border-radius: 4px;
  letter-spacing: 0.04em;
}

.btn:hover { background: #6e5535; text-decoration: none; }

/* ---- ART PAGE ---- */
.page-header {
  margin-bottom: 2rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--border);
}

.page-header h1 {
  font-size: 1.8rem;
  color: #222;
  font-weight: normal;
  margin-bottom: 0.5rem;
}

.intro-text {
  max-width: 720px;
  margin-bottom: 2.5rem;
  font-size: 0.97rem;
  color: #555;
}

.intro-text a { color: var(--accent); }

/* Masonry-style art grid */
.art-grid {
  columns: 4 220px;
  column-gap: 1rem;
}

.art-item {
  break-inside: avoid;
  margin-bottom: 1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 3px;
  overflow: hidden;
  cursor: zoom-in;
}

.art-item img {
  width: 100%;
  display: block;
  transition: opacity 0.2s;
}

.art-item:hover img { opacity: 0.92; }

.art-caption {
  padding: 0.4rem 0.6rem 0.5rem;
  font-size: 0.78rem;
  color: var(--muted);
  font-style: italic;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  text-align: center;
}

/* Footer */
footer {
  text-align: center;
  padding: 2rem 2.5rem;
  color: var(--muted);
  font-size: 0.8rem;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  border-top: 1px solid var(--border);
  margin-top: 3rem;
}
/* ---- HAMBURGER (hidden at desktop) ---- */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  width: 1.375rem;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.25rem 0;
  flex-shrink: 0;
}

.nav-toggle .bar {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--accent);
  border-radius: 2px;
  transition: transform 0.22s ease, opacity 0.22s ease;
}

.sidebar.nav-open .nav-toggle .bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.sidebar.nav-open .nav-toggle .bar:nth-child(2) { opacity: 0; transform: scaleX(0); }
.sidebar.nav-open .nav-toggle .bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---- RESPONSIVE ---- */
@media (max-width: 700px) {
  .site-layout { flex-direction: column; }

  .sidebar {
    width: 100%;
    min-width: unset;
    height: auto;
    position: static;
    padding: 0.75rem 1.25rem;
    border-right: none;
    border-bottom: 1px solid var(--border);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0;
  }

  .sidebar .logo { margin-bottom: 0; }

  .nav-toggle { display: flex; }

  .sidebar nav {
    flex-direction: column;
    gap: 0;
    width: 100%;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.28s ease-out, opacity 0.18s ease;
  }

  .sidebar.nav-open nav {
    max-height: 20rem;
    opacity: 1;
  }

  .sidebar nav a {
    margin-bottom: 0;
    padding: 0.75rem 0;
    border-top: 1px solid var(--border);
    min-height: 44px;
    display: flex;
    align-items: center;
  }

  main { padding: 1.5rem; }
  .art-grid { columns: 2 160px; }
}

/* ---- REDUCED MOTION ---- */
@media (prefers-reduced-motion: reduce) {
  .art-item img { transition: none; }
  .skip-link { transition: none; }
  .nav-toggle .bar { transition: none; }
  .sidebar nav { transition: none; }
}

/* ---- LIGHTBOX ---- */
#lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.88);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  cursor: zoom-out;
}
#lightbox.open { display: flex; }
#lightbox-img {
  max-width: 92vw;
  max-height: 88vh;
  object-fit: contain;
  border-radius: 3px;
  box-shadow: 0 8px 40px rgba(0,0,0,0.6);
  cursor: default;
}
#lightbox-footer {
  position: fixed;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
  pointer-events: auto;
}
#lightbox-caption {
  color: rgba(255,255,255,0.7);
  font-size: 0.85rem;
  font-style: italic;
  font-family: Georgia, serif;
  letter-spacing: 0.03em;
  margin-bottom: 0.5rem;
}
#lightbox-cta {
  display: inline-block;
  color: #fff;
  font-size: 0.78rem;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-style: normal;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-bottom: 1px solid rgba(255,255,255,0.4);
  padding-bottom: 1px;
  text-decoration: none;
}
#lightbox-cta:hover { border-bottom-color: #fff; color: #fff; }
#lightbox-close {
  position: fixed;
  top: 1.25rem;
  right: 1.5rem;
  color: rgba(255,255,255,0.7);
  font-size: 1.8rem;
  cursor: pointer;
  line-height: 1;
  font-family: sans-serif;
  font-weight: 300;
  user-select: none;
}
#lightbox-close:hover { color: #fff; }
#lightbox-prev, #lightbox-next {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  color: rgba(255,255,255,0.6);
  font-size: 2.5rem;
  cursor: pointer;
  padding: 1rem;
  user-select: none;
  font-family: sans-serif;
  font-weight: 300;
  line-height: 1;
}
#lightbox-prev:hover, #lightbox-next:hover { color: #fff; }
#lightbox-prev { left: 0.5rem; }
#lightbox-next { right: 0.5rem; }
