/* ==========================================================================
   Spruce Gallery - Stylesheet
   Fonts: Space Grotesk + Inter
   Palette: Deep Black #0D0D0D, Warm White #F5F0EB, Muted Gold #C4A265,
            Soft Charcoal #2C2C2C, Light Stone #E8E0D6
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600;700&family=Inter:wght@300;400;500;600&display=swap');

/* ---------- Reset & Base ---------- */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --black: #0D0D0D;
  --white: #F5F0EB;
  --gold: #C4A265;
  --charcoal: #2C2C2C;
  --stone: #E8E0D6;
  --font-heading: 'Space Grotesk', sans-serif;
  --font-body: 'Inter', sans-serif;
  --max-width: 1200px;
  --transition: 0.3s ease;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  background-color: var(--white);
  color: var(--charcoal);
  line-height: 1.7;
  overflow-x: hidden;
}

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

a {
  text-decoration: none;
  color: inherit;
  transition: color var(--transition);
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 600;
  line-height: 1.2;
  color: var(--black);
}

.container {
  width: 90%;
  max-width: var(--max-width);
  margin: 0 auto;
}

/* ---------- Fade-in Animations ---------- */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- Header / Navbar ---------- */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  padding: 1rem 0;
  transition: background var(--transition), padding var(--transition), box-shadow var(--transition);
  background: transparent;
}

.header.scrolled {
  background: var(--black);
  padding: 0.6rem 0;
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
}

.header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--white);
  letter-spacing: 2px;
  text-transform: uppercase;
}

.logo span {
  color: var(--gold);
}

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

.nav-links a {
  color: var(--white);
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 400;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  position: relative;
  padding-bottom: 4px;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--gold);
  transition: width var(--transition);
}

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

.nav-links a.active {
  color: var(--gold);
}

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  cursor: pointer;
  gap: 5px;
}

.hamburger span {
  width: 25px;
  height: 2px;
  background: var(--white);
  transition: var(--transition);
}

.hamburger.open span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.hamburger.open span:nth-child(2) {
  opacity: 0;
}

.hamburger.open span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* ---------- Breadcrumb ---------- */
.breadcrumb {
  padding: 6.5rem 0 1rem;
  background: var(--black);
}

.breadcrumb-list {
  display: flex;
  list-style: none;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: rgba(245, 240, 235, 0.5);
}

.breadcrumb-list a {
  color: var(--gold);
}

.breadcrumb-list a:hover {
  text-decoration: underline;
}

.breadcrumb-list li::after {
  content: '/';
  margin-left: 0.5rem;
  color: rgba(245, 240, 235, 0.3);
}

.breadcrumb-list li:last-child::after {
  content: '';
}

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

.hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  filter: brightness(0.35);
  transform: scale(1.05);
}

.hero-content {
  position: relative;
  text-align: center;
  color: var(--white);
  max-width: 700px;
  padding: 0 1rem;
}

.hero-content h1 {
  font-size: 3.5rem;
  color: var(--white);
  margin-bottom: 1rem;
  letter-spacing: 3px;
  text-transform: uppercase;
}

.hero-content h1 span {
  color: var(--gold);
}

.hero-content p {
  font-size: 1.15rem;
  color: var(--stone);
  margin-bottom: 2rem;
  font-weight: 300;
  line-height: 1.8;
}

.btn {
  display: inline-block;
  padding: 0.85rem 2.2rem;
  font-family: var(--font-heading);
  font-size: 0.9rem;
  font-weight: 500;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  border: 2px solid var(--gold);
  color: var(--gold);
  background: transparent;
  cursor: pointer;
  transition: all var(--transition);
}

.btn:hover {
  background: var(--gold);
  color: var(--black);
}

.btn-filled {
  background: var(--gold);
  color: var(--black);
}

.btn-filled:hover {
  background: transparent;
  color: var(--gold);
}

/* ---------- Section Styles ---------- */
.section {
  padding: 5rem 0;
}

.section-dark {
  background: var(--black);
  color: var(--white);
}

.section-dark h2,
.section-dark h3 {
  color: var(--white);
}

.section-stone {
  background: var(--stone);
}

.section-title {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  text-align: center;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.section-subtitle {
  text-align: center;
  color: var(--gold);
  font-family: var(--font-heading);
  font-size: 0.85rem;
  letter-spacing: 3px;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

.section-desc {
  text-align: center;
  max-width: 650px;
  margin: 0 auto 3rem;
  color: rgba(44, 44, 44, 0.7);
  font-size: 1rem;
}

.section-dark .section-desc {
  color: rgba(245, 240, 235, 0.6);
}

/* ---------- Highlight Cards ---------- */
.highlights-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
}

.highlight-card {
  position: relative;
  overflow: hidden;
  border-radius: 4px;
  aspect-ratio: 4/3;
}

.highlight-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.highlight-card:hover img {
  transform: scale(1.08);
}

.highlight-card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(13, 13, 13, 0.85) 0%, transparent 60%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.5rem;
}

.highlight-card-overlay h3 {
  color: var(--white);
  font-size: 1.3rem;
  margin-bottom: 0.4rem;
}

.highlight-card-overlay p {
  color: var(--stone);
  font-size: 0.85rem;
  margin-bottom: 0.8rem;
}

.highlight-card-overlay .card-link {
  color: var(--gold);
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 1px;
  text-transform: uppercase;
}

/* ---------- About Preview ---------- */
.about-preview {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.about-preview-img {
  border-radius: 4px;
  overflow: hidden;
}

.about-preview-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.about-preview-text h2 {
  font-size: 2.2rem;
  margin-bottom: 1rem;
}

.about-preview-text p {
  margin-bottom: 1.5rem;
  color: rgba(44, 44, 44, 0.75);
}

/* ---------- CTA Section ---------- */
.cta-section {
  padding: 5rem 0;
  text-align: center;
  background: var(--black);
  color: var(--white);
}

.cta-section h2 {
  color: var(--white);
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.cta-section p {
  color: var(--stone);
  max-width: 500px;
  margin: 0 auto 2rem;
}

/* ---------- Page Header ---------- */
.page-header {
  padding: 8rem 0 4rem;
  background: var(--black);
  text-align: center;
  color: var(--white);
}

.page-header h1 {
  color: var(--white);
  font-size: 3rem;
  letter-spacing: 3px;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.page-header p {
  color: rgba(245, 240, 235, 0.6);
  max-width: 600px;
  margin: 0 auto;
}

/* ---------- About Page ---------- */
.about-story {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  margin-bottom: 4rem;
}

.about-story.reverse {
  direction: rtl;
}

.about-story.reverse > * {
  direction: ltr;
}

.about-story-img {
  border-radius: 4px;
  overflow: hidden;
}

.about-story-img img {
  width: 100%;
  object-fit: cover;
}

.about-story-text h2 {
  font-size: 2rem;
  margin-bottom: 1rem;
}

.about-story-text p {
  margin-bottom: 1rem;
  color: rgba(44, 44, 44, 0.75);
}

.values-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.value-card {
  text-align: center;
  padding: 2rem;
  background: var(--white);
  border-radius: 4px;
}

.section-dark .value-card {
  background: var(--charcoal);
}

.value-card h3 {
  font-size: 1.3rem;
  margin-bottom: 0.8rem;
}

.value-icon {
  font-size: 2rem;
  color: var(--gold);
  margin-bottom: 1rem;
}

/* ---------- Exhibitions ---------- */
.exhibition-card {
  display: grid;
  grid-template-columns: 350px 1fr;
  gap: 2rem;
  margin-bottom: 3rem;
  background: var(--white);
  border-radius: 4px;
  overflow: hidden;
  box-shadow: 0 2px 15px rgba(0, 0, 0, 0.06);
}

.section-dark .exhibition-card {
  background: var(--charcoal);
}

.exhibition-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.exhibition-info {
  padding: 2rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.exhibition-date {
  color: var(--gold);
  font-family: var(--font-heading);
  font-size: 0.8rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

.exhibition-info h3 {
  font-size: 1.5rem;
  margin-bottom: 0.8rem;
}

.exhibition-info p {
  color: rgba(44, 44, 44, 0.7);
  font-size: 0.95rem;
}

.section-dark .exhibition-info p {
  color: rgba(245, 240, 235, 0.6);
}

/* ---------- Gallery Grid ---------- */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1rem;
}

.gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: 4px;
  cursor: pointer;
  aspect-ratio: 3/2;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

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

.gallery-item-overlay {
  position: absolute;
  inset: 0;
  background: rgba(13, 13, 13, 0);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background var(--transition);
}

.gallery-item:hover .gallery-item-overlay {
  background: rgba(13, 13, 13, 0.3);
}

.gallery-item-overlay span {
  color: var(--white);
  font-size: 2rem;
  opacity: 0;
  transition: opacity var(--transition);
}

.gallery-item:hover .gallery-item-overlay span {
  opacity: 1;
}

/* ---------- Lightbox ---------- */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(13, 13, 13, 0.95);
  z-index: 2000;
  display: none;
  align-items: center;
  justify-content: center;
}

.lightbox.active {
  display: flex;
}

.lightbox-content {
  position: relative;
  max-width: 90vw;
  max-height: 90vh;
}

.lightbox-content img {
  max-width: 90vw;
  max-height: 85vh;
  object-fit: contain;
  border-radius: 4px;
}

.lightbox-close {
  position: absolute;
  top: -40px;
  right: 0;
  color: var(--white);
  font-size: 2rem;
  cursor: pointer;
  background: none;
  border: none;
  font-family: var(--font-body);
}

.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  color: var(--white);
  font-size: 2.5rem;
  cursor: pointer;
  background: rgba(13, 13, 13, 0.5);
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  transition: background var(--transition);
}

.lightbox-nav:hover {
  background: rgba(196, 162, 101, 0.8);
}

.lightbox-prev {
  left: 1rem;
}

.lightbox-next {
  right: 1rem;
}

/* ---------- Contact ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}

.form-group label {
  display: block;
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-bottom: 0.4rem;
  color: var(--black);
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 0.8rem 1rem;
  border: 1px solid var(--stone);
  background: var(--white);
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--charcoal);
  border-radius: 4px;
  transition: border-color var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--gold);
}

.form-group textarea {
  min-height: 150px;
  resize: vertical;
}

.contact-info h3 {
  font-size: 1.3rem;
  margin-bottom: 1.5rem;
}

.contact-detail {
  margin-bottom: 1.5rem;
}

.contact-detail h4 {
  font-size: 0.85rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.3rem;
}

.contact-detail p {
  color: rgba(44, 44, 44, 0.75);
}

.contact-detail a {
  color: var(--gold);
}

.contact-detail a:hover {
  text-decoration: underline;
}

.map-container {
  margin-top: 2rem;
  border-radius: 4px;
  overflow: hidden;
}

.map-container iframe {
  width: 100%;
  height: 300px;
  border: 0;
}

.social-links {
  display: flex;
  gap: 1rem;
  margin-top: 1rem;
}

.social-links a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: 1px solid var(--gold);
  border-radius: 50%;
  color: var(--gold);
  font-size: 1rem;
  transition: all var(--transition);
}

.social-links a:hover {
  background: var(--gold);
  color: var(--black);
}

/* ---------- Artists ---------- */
.artist-card {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 2rem;
  margin-bottom: 2.5rem;
  padding: 2rem;
  background: var(--white);
  border-radius: 4px;
  box-shadow: 0 2px 15px rgba(0, 0, 0, 0.06);
  align-items: center;
}

.section-dark .artist-card {
  background: var(--charcoal);
}

.artist-card img {
  width: 200px;
  height: 200px;
  object-fit: cover;
  border-radius: 50%;
}

.artist-info h3 {
  font-size: 1.4rem;
  margin-bottom: 0.5rem;
}

.artist-info p {
  color: rgba(44, 44, 44, 0.7);
  font-size: 0.95rem;
}

.section-dark .artist-info p {
  color: rgba(245, 240, 235, 0.6);
}

/* ---------- Testimonials ---------- */
.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.testimonial-card {
  background: var(--white);
  padding: 2rem;
  border-radius: 4px;
  border-left: 3px solid var(--gold);
}

.testimonial-card p {
  font-style: italic;
  margin-bottom: 1rem;
  color: rgba(44, 44, 44, 0.8);
}

.testimonial-card cite {
  font-style: normal;
  font-family: var(--font-heading);
  font-size: 0.85rem;
  color: var(--gold);
  letter-spacing: 1px;
}

/* ---------- Footer ---------- */
.footer {
  background: var(--black);
  color: var(--stone);
  padding: 4rem 0 2rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 3rem;
}

.footer h4 {
  color: var(--white);
  font-size: 1rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.footer p {
  font-size: 0.9rem;
  color: rgba(245, 240, 235, 0.5);
  line-height: 1.8;
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: 0.5rem;
}

.footer-links a {
  font-size: 0.9rem;
  color: rgba(245, 240, 235, 0.5);
  transition: color var(--transition);
}

.footer-links a:hover {
  color: var(--gold);
}

.footer-bottom {
  border-top: 1px solid rgba(245, 240, 235, 0.1);
  padding-top: 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-bottom p {
  font-size: 0.8rem;
}

.footer-social {
  display: flex;
  gap: 1rem;
}

.footer-social a {
  color: rgba(245, 240, 235, 0.5);
  font-size: 1.1rem;
  transition: color var(--transition);
}

.footer-social a:hover {
  color: var(--gold);
}

/* ---------- Responsive ---------- */
@media (max-width: 768px) {
  .hamburger {
    display: flex;
  }

  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background: var(--black);
    flex-direction: column;
    padding: 5rem 2rem;
    gap: 1.5rem;
    transition: right 0.4s ease;
    box-shadow: -5px 0 30px rgba(0, 0, 0, 0.5);
  }

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

  .hero-content h1 {
    font-size: 2.2rem;
  }

  .about-preview,
  .about-story,
  .about-story.reverse,
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .about-story.reverse {
    direction: ltr;
  }

  .exhibition-card {
    grid-template-columns: 1fr;
  }

  .exhibition-card img {
    height: 250px;
  }

  .highlights-grid {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }

  .section-title {
    font-size: 1.8rem;
  }

  .page-header h1 {
    font-size: 2rem;
  }

  .artist-card {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .artist-card img {
    margin: 0 auto;
  }

  .gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  }

  .lightbox-nav {
    font-size: 1.5rem;
    padding: 0.3rem 0.6rem;
  }
}

@media (max-width: 480px) {
  .hero-content h1 {
    font-size: 1.8rem;
  }

  .hero-content p {
    font-size: 1rem;
  }

  .section {
    padding: 3rem 0;
  }

  .gallery-grid {
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
  }
}
