/* ---------------------------------------------------------------
   Anastasija — painter portfolio
   White, minimal, typography-led.
   --------------------------------------------------------------- */

:root {
  --white: #ffffff;
  --ink: #1a1a1a;
  --ink-soft: #6b6b6b;
  --ink-faint: #9a9a9a;
  --hairline: #ebebeb;
  --display: "Familjen Grotesk", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --max-width: 1180px;
  --gutter: clamp(1.25rem, 4vw, 3rem);
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--white);
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 300;
  font-size: 1rem;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; }

a { color: inherit; }

/* ---- header ---------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 1.4rem var(--gutter);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
}

.wordmark {
  font-family: var(--display);
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  text-decoration: none;
}

.wordmark-role {
  color: var(--ink-faint);
  font-weight: 400;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.site-nav a {
  font-size: 0.8rem;
  font-weight: 400;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--ink-soft);
  margin-left: 2rem;
  transition: color 0.25s ease;
}

.site-nav a:hover { color: var(--ink); }

@media (max-width: 560px) {
  .site-header { display: block; text-align: center; padding-bottom: 1rem; }
  .site-nav { margin-top: 0.5rem; }
  .site-nav a { margin: 0 0.8rem; }
}

/* ---- gallery --------------------------------------------------- */

.gallery-section {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: clamp(2rem, 6vh, 4rem) var(--gutter) 5rem;
}

.gallery {
  columns: 3;
  column-gap: 2.2rem;
}

@media (max-width: 900px) { .gallery { columns: 2; } }
@media (max-width: 560px) { .gallery { columns: 1; } }

.artwork {
  break-inside: avoid;
  margin-bottom: 2.6rem;
  cursor: pointer;
  border: 0;
  background: none;
  width: 100%;
  text-align: left;
  font: inherit;
  color: inherit;
  padding: 0;
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.artwork.is-visible {
  opacity: 1;
  transform: none;
}

.artwork-frame {
  overflow: hidden;
  background: #f6f6f5;
}

.artwork img {
  width: 100%;
  height: auto;
  transition: transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}

.artwork:hover img { transform: scale(1.025); }

/* ---- about / contact ------------------------------------------- */

.about,
.contact {
  max-width: 640px;
  margin: 0 auto;
  padding: 4.5rem var(--gutter);
  border-top: 1px solid var(--hairline);
  text-align: center;
}

.section-title {
  font-family: var(--display);
  font-weight: 500;
  font-size: 1.5rem;
  letter-spacing: 0.02em;
  margin-bottom: 1.8rem;
}

.about-portrait {
  max-width: 300px;
  margin: 0 auto 2.4rem;
}

.about-portrait img {
  width: 100%;
  height: auto;
}

.about-body p + p { margin-top: 1.1rem; }

.about-body,
.contact-line {
  color: var(--ink-soft);
  font-size: 0.98rem;
}

.contact-link {
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid var(--ink);
  padding-bottom: 1px;
  transition: opacity 0.25s ease;
}

.contact-link:hover { opacity: 0.6; }

.contact-phone { margin-top: 1.2rem; }

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

.site-footer {
  border-top: 1px solid var(--hairline);
  padding: 2.2rem var(--gutter);
  text-align: center;
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  color: var(--ink-faint);
}

/* ---- lightbox --------------------------------------------------- */

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.97);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.lightbox[hidden] { display: none; }

.lightbox.is-open { opacity: 1; }

.lightbox-figure {
  max-width: min(82vw, 1000px);
  max-height: 84vh;
  text-align: center;
}

.lightbox-img {
  max-width: 100%;
  max-height: 72vh;
  margin: 0 auto;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.12);
}

.lightbox-caption {
  margin-top: 1.4rem;
  font-family: var(--display);
  font-size: 0.95rem;
  font-weight: 400;
  color: var(--ink-soft);
}

.lightbox button {
  position: absolute;
  background: none;
  border: 0;
  cursor: pointer;
  color: var(--ink-soft);
  font-size: 1.6rem;
  line-height: 1;
  padding: 1rem;
  transition: color 0.25s ease;
}

.lightbox button:hover { color: var(--ink); }

.lightbox-close { top: 1rem; right: 1.2rem; font-size: 2.2rem; font-weight: 200; }
.lightbox-prev { left: 1rem; top: 50%; transform: translateY(-50%); }
.lightbox-next { right: 1rem; top: 50%; transform: translateY(-50%); }

@media (max-width: 560px) {
  .lightbox-prev { left: 0.2rem; }
  .lightbox-next { right: 0.2rem; }
}

/* ---- reduced motion --------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .artwork { opacity: 1; transform: none; transition: none; }
  .artwork img { transition: none; }
}
