/* ============================================
   Artsy Linda — Artist Portfolio
   Aesthetic: Warm impressionist garden
   ============================================ */

:root {
  --cream: #FAF7F2;
  --cream-warm: #F5F0E8;
  --sage-light: #EDF2E8;
  --sage: #7B8F6B;
  --sage-dark: #4A5640;
  --olive: #5C6B4F;
  --teal: #6B9E9E;
  --teal-muted: #8DB5B0;
  --rose: #C4917B;
  --rose-light: #D9B5A5;
  --lavender: #B8A9C8;
  --charcoal: #3A3630;
  --charcoal-light: #5A5650;
  --warm-white: #FFFDF9;
  --shadow: rgba(58, 54, 48, 0.08);
  --shadow-md: rgba(58, 54, 48, 0.12);
  --shadow-lg: rgba(58, 54, 48, 0.18);

  --font-display: 'Cormorant', Georgia, serif;
  --font-body: 'Karla', -apple-system, sans-serif;

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
}

/* ---- Reset & Base ---- */

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

body {
  font-family: var(--font-body);
  font-weight: 300;
  color: var(--charcoal);
  background: var(--cream);
  line-height: 1.7;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: var(--sage-dark);
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: var(--teal);
}

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.2;
}

/* ---- Navigation ---- */

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 3rem;
  transition: all 0.5s var(--ease-out);
}

.nav.scrolled {
  background: rgba(250, 247, 242, 0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 1px 0 var(--shadow);
  padding: 0.6rem 3rem;
}

.nav-logo-img {
  height: 40px;
  width: auto;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.nav.scrolled .nav-logo-img {
  opacity: 1;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 2.5rem;
}

.nav-links a {
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 400;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--warm-white);
  transition: color 0.3s ease, opacity 0.3s ease;
  position: relative;
}

.nav.scrolled .nav-links a {
  color: var(--charcoal);
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--sage);
  transition: width 0.3s var(--ease-out);
}

.nav-links a:hover::after {
  width: 100%;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  z-index: 110;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 1.5px;
  background: var(--warm-white);
  transition: all 0.3s ease;
}

.nav.scrolled .nav-toggle span {
  background: var(--charcoal);
}

/* ---- Hero ---- */

.hero {
  position: relative;
  height: 100vh;
  min-height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-bg-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
  transform: scale(1.05);
  animation: heroZoom 20s var(--ease-in-out) infinite alternate;
}

@keyframes heroZoom {
  from { transform: scale(1.05); }
  to { transform: scale(1.12); }
}

.hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(to bottom,
      rgba(58, 54, 48, 0.25) 0%,
      rgba(58, 54, 48, 0.15) 40%,
      rgba(58, 54, 48, 0.35) 100%
    );
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  color: var(--warm-white);
  padding: 2rem;
}

.hero-signature {
  height: 90px;
  width: auto;
  margin: 0 auto 1.5rem;
  filter: brightness(0) invert(1);
  opacity: 0;
  animation: fadeUp 1s var(--ease-out) 0.3s forwards;
}

.hero-tagline {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 3.5vw, 2.4rem);
  font-weight: 300;
  font-style: italic;
  letter-spacing: 0.02em;
  margin-bottom: 0.75rem;
  opacity: 0;
  animation: fadeUp 1s var(--ease-out) 0.6s forwards;
}

.hero-sub {
  font-size: 0.8rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  font-weight: 300;
  opacity: 0;
  animation: fadeUp 1s var(--ease-out) 0.9s forwards;
}

.scroll-hint {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  color: var(--warm-white);
  opacity: 0;
  animation: fadeUp 1s var(--ease-out) 1.2s forwards, bounce 2.5s ease-in-out 2s infinite;
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.scroll-hint {
  animation: fadeUp 1s var(--ease-out) 1.2s forwards;
}

@keyframes bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(8px); }
}

/* ---- Sections shared ---- */

.section-header {
  text-align: center;
  margin-bottom: 3rem;
}

.section-header h2 {
  font-size: clamp(2rem, 5vw, 3.2rem);
  color: var(--sage-dark);
  margin-bottom: 1rem;
  font-weight: 300;
}

.section-intro {
  max-width: 560px;
  margin: 0 auto;
  color: var(--charcoal-light);
  font-size: 1.05rem;
}

/* ---- Gallery ---- */

.gallery {
  padding: 6rem 2rem;
  background: var(--cream);
}

.gallery-filters {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 3rem;
}

.filter-btn {
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 400;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.55rem 1.3rem;
  border: 1px solid var(--sage);
  border-radius: 100px;
  background: transparent;
  color: var(--sage-dark);
  cursor: pointer;
  transition: all 0.3s ease;
}

.filter-btn:hover {
  background: var(--sage-light);
}

.filter-btn.active {
  background: var(--sage-dark);
  border-color: var(--sage-dark);
  color: var(--warm-white);
}

.gallery-grid {
  max-width: 1400px;
  margin: 0 auto;
  columns: 4;
  column-gap: 1rem;
}

.gallery-item {
  break-inside: avoid;
  margin-bottom: 1rem;
  position: relative;
  border-radius: 4px;
  overflow: hidden;
  cursor: pointer;
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s var(--ease-out), transform 0.6s var(--ease-out);
}

.gallery-item.visible {
  opacity: 1;
  transform: translateY(0);
}

.gallery-item.hiding {
  opacity: 0;
  transform: scale(0.95);
  position: absolute;
  pointer-events: none;
}

.gallery-item img {
  width: 100%;
  display: block;
  transition: transform 0.7s var(--ease-out);
}

.gallery-item:hover img {
  transform: scale(1.03);
}

.gallery-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 2.5rem 1rem 1rem;
  background: linear-gradient(to top, rgba(58, 54, 48, 0.7) 0%, transparent 100%);
  opacity: 0;
  transition: opacity 0.4s ease;
}

.gallery-item:hover .gallery-caption {
  opacity: 1;
}

.gallery-caption span {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-style: italic;
  color: var(--warm-white);
  letter-spacing: 0.02em;
}

/* ---- About ---- */

.about {
  padding: 7rem 2rem;
  background: var(--sage-light);
  position: relative;
  overflow: hidden;
}

.about::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--sage), transparent);
}

.about-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 5rem;
  align-items: center;
}

.about-images {
  position: relative;
}

.about-photo-main img {
  border-radius: 6px;
  box-shadow: 0 20px 60px var(--shadow-lg);
  width: 100%;
  max-width: 380px;
  aspect-ratio: 3/4;
  object-fit: cover;
  object-position: center top;
}

.about-photo-secondary {
  position: absolute;
  bottom: -2rem;
  right: -1rem;
  width: 55%;
  max-width: 220px;
}

.about-photo-secondary img {
  border-radius: 6px;
  box-shadow: 0 15px 40px var(--shadow-md);
  border: 4px solid var(--cream);
  aspect-ratio: 3/4;
  object-fit: cover;
}

.about-text h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  color: var(--sage-dark);
  margin-bottom: 1.5rem;
  font-weight: 300;
}

.about-lead {
  font-size: 1.15rem;
  color: var(--charcoal);
  font-weight: 400;
  margin-bottom: 1.25rem;
}

.about-text p {
  margin-bottom: 1rem;
  color: var(--charcoal-light);
  font-size: 1rem;
}

.about-signature {
  margin-top: 1.5rem;
}

.about-signature img {
  height: 45px;
  width: auto;
  opacity: 0.6;
}

/* ---- Contact ---- */

.contact {
  padding: 7rem 2rem;
  background: var(--cream);
  text-align: center;
}

.contact-inner {
  max-width: 900px;
  margin: 0 auto;
}

.contact-inner h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  color: var(--sage-dark);
  margin-bottom: 1rem;
  font-weight: 300;
}

.contact-intro {
  color: var(--charcoal-light);
  font-size: 1.05rem;
  margin-bottom: 3rem;
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.contact-card {
  padding: 2.5rem 1.5rem;
  background: var(--warm-white);
  border-radius: 8px;
  border: 1px solid rgba(123, 143, 107, 0.12);
  transition: transform 0.3s var(--ease-out), box-shadow 0.3s ease;
}

.contact-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px var(--shadow);
}

.contact-icon {
  width: 32px;
  height: 32px;
  margin: 0 auto 1rem;
  color: var(--sage);
}

.contact-card h3 {
  font-size: 0.75rem;
  font-family: var(--font-body);
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--charcoal-light);
  margin-bottom: 0.5rem;
}

.contact-card a,
.contact-card span {
  font-family: var(--font-display);
  font-size: 1.15rem;
  color: var(--charcoal);
}

.contact-card a:hover {
  color: var(--teal);
}

/* ---- Footer ---- */

.footer {
  padding: 3rem 2rem;
  background: var(--sage-dark);
  text-align: center;
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
}

.footer-logo {
  height: 35px;
  width: auto;
  margin: 0 auto 1rem;
  filter: brightness(0) invert(1);
  opacity: 0.7;
}

.footer p {
  font-size: 0.8rem;
  color: rgba(255, 253, 249, 0.5);
  letter-spacing: 0.05em;
}

/* ---- Lightbox ---- */

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(30, 28, 25, 0.94);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s ease, visibility 0.4s ease;
}

.lightbox.active {
  opacity: 1;
  visibility: visible;
}

.lightbox-content {
  max-width: 90vw;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.lightbox-img {
  max-width: 90vw;
  max-height: 78vh;
  object-fit: contain;
  border-radius: 4px;
  transform: scale(0.95);
  transition: transform 0.4s var(--ease-out);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.4);
}

.lightbox.active .lightbox-img {
  transform: scale(1);
}

.lightbox-caption {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-style: italic;
  color: rgba(255, 253, 249, 0.8);
  margin-top: 1.25rem;
  letter-spacing: 0.02em;
}

.lightbox-close {
  position: absolute;
  top: 1.5rem;
  right: 2rem;
  background: none;
  border: none;
  color: rgba(255, 253, 249, 0.6);
  font-size: 2rem;
  cursor: pointer;
  transition: color 0.3s ease;
  line-height: 1;
  z-index: 10;
}

.lightbox-close:hover {
  color: var(--warm-white);
}

.lightbox-prev,
.lightbox-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: rgba(255, 253, 249, 0.5);
  cursor: pointer;
  padding: 1rem;
  transition: color 0.3s ease;
  z-index: 10;
}

.lightbox-prev { left: 1rem; }
.lightbox-next { right: 1rem; }

.lightbox-prev:hover,
.lightbox-next:hover {
  color: var(--warm-white);
}

/* ---- Scroll Reveal ---- */

.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out);
}

.reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}

/* ---- Responsive ---- */

@media (max-width: 1100px) {
  .gallery-grid {
    columns: 3;
  }
}

@media (max-width: 900px) {
  .nav {
    padding: 1rem 1.5rem;
  }

  .nav.scrolled {
    padding: 0.5rem 1.5rem;
  }

  .about-inner {
    grid-template-columns: 1fr;
    gap: 3rem;
    text-align: center;
  }

  .about-images {
    display: flex;
    justify-content: center;
  }

  .about-photo-main img {
    max-width: 280px;
  }

  .about-photo-secondary {
    right: auto;
    left: 55%;
    bottom: -1rem;
  }

  .about-signature {
    display: flex;
    justify-content: center;
  }

  .contact-grid {
    grid-template-columns: 1fr;
    max-width: 360px;
    margin: 0 auto;
  }
}

@media (max-width: 768px) {
  .gallery-grid {
    columns: 2;
    column-gap: 0.75rem;
  }

  .gallery-item {
    margin-bottom: 0.75rem;
  }

  .gallery-caption {
    opacity: 1;
    padding: 1.5rem 0.75rem 0.75rem;
  }

  .gallery-caption span {
    font-size: 0.95rem;
  }

  .nav-toggle {
    display: flex;
  }

  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background: var(--cream);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    transition: right 0.4s var(--ease-out);
    box-shadow: -10px 0 40px var(--shadow-lg);
  }

  .nav-links.open {
    right: 0;
  }

  .nav-links a {
    color: var(--charcoal) !important;
    font-size: 1rem;
  }

  .hero-signature {
    height: 65px;
  }

  .gallery {
    padding: 4rem 1rem;
  }

  .about {
    padding: 4rem 1.5rem;
  }

  .contact {
    padding: 4rem 1.5rem;
  }

  .lightbox-prev,
  .lightbox-next {
    display: none;
  }
}

@media (max-width: 480px) {
  .gallery-grid {
    columns: 2;
    column-gap: 0.5rem;
  }

  .gallery-item {
    margin-bottom: 0.5rem;
  }

  .filter-btn {
    font-size: 0.7rem;
    padding: 0.45rem 0.9rem;
  }

  .hero-sub {
    font-size: 0.7rem;
  }

  .about-photo-main img {
    max-width: 220px;
  }

  .about-photo-secondary {
    width: 45%;
    max-width: 160px;
  }
}

/* ---- Paint texture overlay (subtle) ---- */

.gallery::after,
.about::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.015;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 256px 256px;
}

.gallery, .about {
  position: relative;
}
