/* =========================================================
   Mery Tamborrino Eventi — Wedding & Event Design
   ========================================================= */

:root {
  --cream: #faf6f1;
  --cream-alt: #f2ebe1;
  --ink: #3c332b;
  --ink-soft: #6b5f52;
  --brown-deep: #4a3b2f;
  --rose: #c8a79a;
  --rose-deep: #ad8172;
  --gold: #b8965a;
  --gold-soft: #d9c39a;
  --white: #ffffff;
  --line: rgba(60, 51, 43, 0.14);

  --font-display: "Playfair Display", "Georgia", serif;
  --font-body: "Jost", "Helvetica Neue", Arial, sans-serif;

  --container: 1180px;
  --gap: clamp(1.5rem, 3vw, 3rem);
  --radius: 2px;
  --shadow: 0 20px 50px -25px rgba(60, 51, 43, 0.45);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button { font: inherit; background: none; border: none; cursor: pointer; color: inherit; }
input, textarea { font: inherit; }

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

::selection { background: var(--rose); color: var(--white); }

:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
}

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 5vw, 2.5rem);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  font-family: var(--font-body);
  font-size: 0.78rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold);
  font-weight: 500;
}
.eyebrow::before {
  content: "";
  width: 28px;
  height: 1px;
  background: var(--gold);
  display: inline-block;
}

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 500;
  color: var(--brown-deep);
  line-height: 1.15;
}

h2 { font-size: clamp(2rem, 3.4vw, 2.85rem); }
h2 em, h1 em { font-style: italic; color: var(--rose-deep); }

p { color: var(--ink-soft); }
p + p { margin-top: 1em; }

.section {
  padding-block: clamp(4.5rem, 9vw, 7.5rem);
}
.section--alt { background: var(--cream-alt); }

.section-head {
  max-width: 640px;
  margin-bottom: clamp(2.5rem, 5vw, 3.5rem);
}
.section-head.center { margin-inline: auto; text-align: center; }
.section-head h2 { margin-top: 0.9rem; }
.section-head p { margin-top: 1.1rem; font-size: 1.05rem; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.95rem 2.1rem;
  font-family: var(--font-body);
  font-size: 0.85rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 500;
  border: 1px solid transparent;
  border-radius: var(--radius);
  transition: all 0.35s var(--ease);
  white-space: nowrap;
}
.btn-primary {
  background: var(--brown-deep);
  color: var(--cream);
  border-color: var(--brown-deep);
}
.btn-primary:hover { background: var(--ink); border-color: var(--ink); transform: translateY(-2px); }

.btn-ghost {
  background: transparent;
  color: var(--brown-deep);
  border-color: currentColor;
}
.btn-ghost:hover { background: var(--brown-deep); color: var(--cream); transform: translateY(-2px); }

.btn-light {
  background: var(--cream);
  color: var(--brown-deep);
  border-color: var(--cream);
}
.btn-light:hover { background: transparent; color: var(--cream); border-color: var(--cream); }

.btn svg { width: 15px; height: 15px; transition: transform 0.3s var(--ease); }
.btn:hover svg { transform: translateX(4px); }

/* ---------- Header ---------- */
.site-header {
  position: fixed;
  inset-inline: 0;
  top: 0;
  z-index: 100;
  padding-block: 1.6rem;
  transition: all 0.4s var(--ease);
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.site-header.is-scrolled {
  background: rgba(250, 246, 241, 0.92);
  backdrop-filter: blur(10px);
  box-shadow: 0 8px 30px -18px rgba(60, 51, 43, 0.35);
  padding-block: 1rem;
}

.brand {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.5rem;
  letter-spacing: 0.02em;
  color: var(--brown-deep);
}
.is-light .brand,
.is-light .nav-link,
.is-light .nav-toggle span { color: var(--cream); }
.site-header.is-scrolled.is-light .brand,
.site-header.is-scrolled.is-light .nav-link,
.site-header.is-scrolled.is-light .nav-toggle span { color: var(--brown-deep); }

.is-light .nav-cta {
  background: var(--cream);
  color: var(--brown-deep);
  border-color: var(--cream);
}
.site-header.is-scrolled.is-light .nav-cta {
  background: transparent;
  color: var(--brown-deep);
  border-color: var(--brown-deep);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: clamp(1.6rem, 3vw, 2.6rem);
}
.nav-link {
  font-size: 0.82rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--brown-deep);
  position: relative;
  padding-bottom: 4px;
}
.nav-link::after {
  content: "";
  position: absolute;
  left: 0; right: 100%; bottom: 0;
  height: 1px;
  background: currentColor;
  transition: right 0.35s var(--ease);
}
.nav-link:hover::after,
.nav-link.is-active::after { right: 0; }
.nav-link.is-active { color: var(--gold); }

.nav-cta { margin-left: 0.4rem; }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  width: 30px;
  z-index: 101;
}
.nav-toggle span {
  height: 1px;
  background: var(--brown-deep);
  transition: all 0.3s var(--ease);
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--cream);
  overflow: hidden;
}
.hero-media {
  position: absolute;
  inset: 0;
  z-index: -2;
}
.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 70%;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg, rgba(35, 28, 22, 0.55) 0%, rgba(35, 28, 22, 0.38) 45%, rgba(35, 28, 22, 0.72) 100%);
}
.hero-inner { max-width: 780px; padding-inline: 1.5rem; }
.hero .eyebrow { color: var(--gold-soft); justify-content: center; }
.hero .eyebrow::before { display: none; }
.hero h1 {
  color: var(--white);
  font-style: italic;
  font-size: clamp(2.6rem, 6.2vw, 4.6rem);
  margin-top: 1.1rem;
}
.hero-sub {
  color: rgba(250, 246, 241, 0.88);
  font-size: clamp(1rem, 1.6vw, 1.2rem);
  max-width: 560px;
  margin: 1.5rem auto 0;
}
.hero-actions {
  margin-top: 2.6rem;
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}
.hero-scroll {
  position: absolute;
  bottom: 2.2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  color: rgba(250, 246, 241, 0.8);
  font-size: 0.7rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}
.hero-scroll::after {
  content: "";
  width: 1px;
  height: 42px;
  background: linear-gradient(180deg, rgba(250,246,241,0.9), transparent);
  animation: scrollLine 2.2s var(--ease) infinite;
}
@keyframes scrollLine {
  0% { transform: scaleY(0); transform-origin: top; opacity: 0; }
  40% { transform: scaleY(1); transform-origin: top; opacity: 1; }
  60% { transform: scaleY(1); transform-origin: bottom; opacity: 1; }
  100% { transform: scaleY(0); transform-origin: bottom; opacity: 0; }
}

/* ---------- Page banner (Gallery / Contact) ---------- */
.page-banner {
  position: relative;
  min-height: 62vh;
  display: flex;
  align-items: flex-end;
  color: var(--cream);
  overflow: hidden;
}
.page-banner .hero-media img { object-position: center 60%; }
.page-banner::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg, rgba(35, 28, 22, 0.5) 0%, rgba(35, 28, 22, 0.18) 32%, rgba(35, 28, 22, 0.75) 100%);
}
.page-banner-inner {
  position: relative;
  padding-block: clamp(3rem, 7vw, 5rem) clamp(2.5rem, 5vw, 3.5rem);
  width: 100%;
}
.page-banner h1 {
  color: var(--white);
  font-style: italic;
  font-size: clamp(2.4rem, 5.2vw, 3.6rem);
  margin-top: 0.9rem;
}
.page-banner p {
  color: rgba(250, 246, 241, 0.85);
  max-width: 560px;
  margin-top: 1rem;
}

/* ---------- Intro / philosophy ---------- */
.intro {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(2.5rem, 6vw, 5rem);
  align-items: center;
}
.intro-media { position: relative; }
.intro-media img {
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 5;
  object-fit: cover;
}
.intro-media::before {
  content: "";
  position: absolute;
  top: -22px; left: -22px;
  width: 70%;
  height: 70%;
  border: 1px solid var(--gold);
  z-index: -1;
}
.intro-text .section-head { margin-bottom: 0; }
.intro-text .btn { margin-top: 2.2rem; }

@media (min-width: 860px) {
  .intro { grid-template-columns: 0.9fr 1.1fr; }
  .intro.reverse { grid-template-columns: 1.1fr 0.9fr; }
  .intro.reverse .intro-media { order: 2; }
}

/* ---------- Services ---------- */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}
.service-card {
  background: var(--cream);
  padding: clamp(2rem, 4vw, 2.6rem) clamp(1.6rem, 3vw, 2rem);
  transition: background 0.4s var(--ease);
}
.service-card:hover { background: var(--white); }
.service-num {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--gold);
  font-size: 1.05rem;
}
.service-card h3 {
  font-size: 1.3rem;
  margin-top: 1rem;
}
.service-card p { margin-top: 0.8rem; font-size: 0.96rem; }

/* ---------- Gallery grid ---------- */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(0.6rem, 1.6vw, 1.25rem);
}
.gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  cursor: zoom-in;
  background: var(--ink);
}
.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.7s var(--ease), filter 0.5s ease;
}
.gallery-item:hover img { transform: scale(1.06); }
.gallery-item::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(35,28,22,0.55) 100%);
  opacity: 0;
  transition: opacity 0.4s ease;
}
.gallery-item:hover::after { opacity: 1; }
.gallery-item .gallery-cap {
  position: absolute;
  left: 1.1rem; right: 1.1rem; bottom: 1rem;
  color: var(--cream);
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  opacity: 0;
  transform: translateY(8px);
  transition: all 0.4s ease;
}
.gallery-item:hover .gallery-cap { opacity: 1; transform: translateY(0); }

.gallery-preview .gallery-grid { grid-template-columns: repeat(4, 1fr); }
.gallery-preview .gallery-item:nth-child(1) { aspect-ratio: 3/4; }
.gallery-preview .gallery-item:nth-child(2) { aspect-ratio: 3/4; }
.gallery-preview .gallery-item:nth-child(3) { aspect-ratio: 3/4; }
.gallery-preview .gallery-item:nth-child(4) { aspect-ratio: 3/4; }

.gallery-full .gallery-item { aspect-ratio: 4/5; }

.gallery-card {
  display: flex;
  flex-direction: column;
  align-self: start;
}
.gallery-card figcaption {
  margin-top: 0.9rem;
  font-size: 0.92rem;
  line-height: 1.6;
  color: var(--ink-soft);
}
.gallery-card .gallery-title {
  display: block;
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.08rem;
  color: var(--brown-deep);
  margin-bottom: 0.35rem;
}

@media (min-width: 640px) {
  .gallery-full .gallery-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 639px) {
  .gallery-preview .gallery-grid { grid-template-columns: repeat(2, 1fr); }
}

.gallery-more { text-align: center; margin-top: clamp(2.5rem, 5vw, 3.5rem); }

/* ---------- About / story ---------- */
.story-quote {
  margin-top: 1.8rem;
  padding-left: 1.4rem;
  border-left: 2px solid var(--gold);
  font-family: var(--font-display);
  font-style: italic;
  color: var(--brown-deep);
  font-size: 1.2rem;
  line-height: 1.5;
}
.story-signature {
  margin-top: 1.8rem;
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.5rem;
  color: var(--rose-deep);
}

/* ---------- CTA band ---------- */
.cta-band {
  position: relative;
  color: var(--cream);
  text-align: center;
  overflow: hidden;
}
.cta-band .hero-media img { object-position: center 35%; }
.cta-band::after {
  content: "";
  position: absolute; inset: 0; z-index: -1;
  background: rgba(35, 28, 22, 0.68);
}
.cta-band-inner { padding-block: clamp(4.5rem, 9vw, 6.5rem); }
.cta-band .eyebrow { justify-content: center; color: var(--gold-soft); }
.cta-band .eyebrow::before { display: none; }
.cta-band h2 { color: var(--white); font-style: italic; margin-top: 1rem; }
.cta-band p { color: rgba(250,246,241,0.85); max-width: 480px; margin: 1.2rem auto 0; }
.cta-band .btn { margin-top: 2.2rem; }

/* ---------- Contact page ---------- */
.contact-wrap {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(2.5rem, 6vw, 4rem);
  align-items: start;
}
@media (min-width: 860px) {
  .contact-wrap { grid-template-columns: 1fr 0.9fr; }
}
.contact-list { margin-top: 2.2rem; display: flex; flex-direction: column; gap: 1.6rem; }
.contact-row {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding-bottom: 1.6rem;
  border-bottom: 1px solid var(--line);
}
.contact-row:last-child { border-bottom: none; }
.contact-row .ico {
  width: 22px; height: 22px; flex-shrink: 0; margin-top: 3px; color: var(--gold);
}
.contact-row .label {
  display: block;
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.3rem;
}
.contact-row a, .contact-row span.value {
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: var(--brown-deep);
}
.contact-row a:hover { color: var(--rose-deep); }
.contact-media { position: relative; }
.contact-media img {
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 5;
  object-fit: cover;
}
.contact-media::before {
  content: "";
  position: absolute; bottom: -22px; right: -22px;
  width: 60%; height: 60%;
  border: 1px solid var(--gold);
  z-index: -1;
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--brown-deep);
  color: rgba(250, 246, 241, 0.75);
  padding-block: clamp(3.5rem, 7vw, 5rem) 2rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid rgba(250, 246, 241, 0.14);
}
@media (min-width: 720px) {
  .footer-grid { grid-template-columns: 1.3fr 0.8fr 1fr; }
}
.footer-brand .brand { color: var(--cream); }
.footer-brand p { margin-top: 1rem; max-width: 320px; color: rgba(250,246,241,0.65); font-size: 0.95rem; }
.social-links { display: flex; gap: 0.8rem; margin-top: 1.6rem; }
.social-links a {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(250, 246, 241, 0.35);
  border-radius: 50%;
  color: var(--cream);
  transition: all 0.3s var(--ease);
}
.social-links a:hover {
  background: var(--gold-soft);
  border-color: var(--gold-soft);
  color: var(--brown-deep);
  transform: translateY(-2px);
}
.social-links svg { width: 17px; height: 17px; }
.footer-col h4 {
  font-family: var(--font-body);
  font-size: 0.76rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold-soft);
  margin-bottom: 1.1rem;
}
.footer-col ul { display: flex; flex-direction: column; gap: 0.7rem; }
.footer-col a { color: rgba(250,246,241,0.8); font-size: 0.95rem; transition: color 0.3s ease; }
.footer-col a:hover { color: var(--gold-soft); }
.footer-bottom {
  padding-top: 1.8rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 1.5rem;
  justify-content: space-between;
  font-size: 0.8rem;
  color: rgba(250,246,241,0.5);
}
.footer-credit {
  margin-top: 0.6rem;
  font-size: 0.75rem;
  color: rgba(250,246,241,0.5);
}
.footer-credit a { color: inherit; text-decoration: none; }
.footer-credit a:hover { text-decoration: underline; }

/* ---------- Reveal animation ---------- */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }

/* ---------- Lightbox ---------- */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(20, 16, 13, 0.94);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4vh 4vw;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s ease;
}
.lightbox.is-open { opacity: 1; visibility: visible; }
.lightbox img {
  max-width: 100%;
  max-height: 88vh;
  border-radius: var(--radius);
  box-shadow: 0 30px 80px rgba(0,0,0,0.5);
}
.lightbox-close, .lightbox-prev, .lightbox-next {
  position: absolute;
  color: var(--cream);
  width: 46px; height: 46px;
  display: flex; align-items: center; justify-content: center;
  border: 1px solid rgba(250,246,241,0.3);
  border-radius: 50%;
  transition: all 0.3s ease;
}
.lightbox-close:hover, .lightbox-prev:hover, .lightbox-next:hover {
  background: var(--cream); color: var(--ink);
}
.lightbox-close { top: 2.2rem; right: 2.2rem; }
.lightbox-prev { left: 2.2rem; top: 50%; transform: translateY(-50%); }
.lightbox-next { right: 2.2rem; top: 50%; transform: translateY(-50%); }
@media (max-width: 700px) {
  .lightbox-prev { left: 0.6rem; }
  .lightbox-next { right: 0.6rem; }
  .lightbox-close { top: 1rem; right: 1rem; }
}

/* ---------- Mobile nav ---------- */
@media (max-width: 860px) {
  .nav-toggle { display: flex; }
  .nav-links {
    position: fixed;
    inset: 0;
    background: var(--cream);
    flex-direction: column;
    justify-content: center;
    gap: 2.2rem;
    transform: translateX(100%);
    transition: transform 0.45s var(--ease);
  }
  body.nav-open .nav-links { transform: translateX(0); }
  .nav-links .nav-link { color: var(--brown-deep) !important; font-size: 1.1rem; }
  .nav-cta { margin-left: 0; }
  body.nav-open .nav-toggle span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
  body.nav-open .nav-toggle span:nth-child(2) { opacity: 0; }
  body.nav-open .nav-toggle span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
  body.nav-open .nav-toggle span { background: var(--brown-deep) !important; }
  body.nav-open { overflow: hidden; }
}
