/* ============================================
   MARCY FACUNDO-MOYA PHOTOGRAPHY
   Dusk Palette — Editorial Design
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,400;0,500;0,600;1,400;1,500&family=Jost:wght@300;400;500&display=swap');

/* --- Variables --- */
:root {
  --midnight-navy: #1C3557;
  --dusty-blush: #D4A5A5;
  --warm-white: #F7F3EF;
  --slate-teal: #7B9E9E;
  --near-black: #2C2C2C;
  --divider: #e0dbd4;
  --card-bg: #ece6dd;
  --placeholder-light: #c4bab0;
  --placeholder-dark: #b8ada3;

  --font-heading: 'Cormorant Garamond', Georgia, serif;
  --font-body: 'Jost', 'Helvetica Neue', sans-serif;

  --max-width: 1200px;
  --content-width: 800px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 16px;
  line-height: 1.7;
  color: var(--near-black);
  background-color: var(--warm-white);
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

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

/* --- Typography --- */
h1, h2, h3 {
  font-family: var(--font-heading);
  font-weight: 500;
  color: var(--midnight-navy);
}

h1 {
  font-size: 2.4rem;
  line-height: 1.3;
}

h2 {
  font-size: 1.8rem;
  line-height: 1.4;
}

h3 {
  font-size: 1.3rem;
  line-height: 1.5;
}

.tagline {
  font-family: var(--font-heading);
  font-style: italic;
  color: var(--midnight-navy);
}

.subline {
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  color: var(--slate-teal);
}

/* --- Navigation --- */
.nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.2rem 2.5rem;
  border-bottom: 0.5px solid var(--divider);
  position: sticky;
  top: 0;
  background: var(--warm-white);
  z-index: 100;
}

.nav-name {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  font-weight: 500;
  color: var(--midnight-navy);
  letter-spacing: 0.03em;
}

.nav-links {
  display: flex;
  gap: 1.5rem;
  align-items: center;
  list-style: none;
}

.nav-links a {
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--near-black);
  transition: color 0.3s;
}

.nav-links a:hover {
  color: var(--dusty-blush);
}

.nav-links .nav-contact {
  background: var(--midnight-navy);
  color: var(--warm-white);
  padding: 0.4rem 1.2rem;
  border-radius: 24px;
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  transition: background 0.3s;
}

.nav-links .nav-contact:hover {
  background: #244a73;
}

/* Projects dropdown */
.nav-dropdown {
  position: relative;
}

.nav-dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: var(--warm-white);
  border: 0.5px solid var(--divider);
  border-radius: 8px;
  padding: 0.5rem 0;
  min-width: 200px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  z-index: 200;
}

.nav-dropdown:hover .nav-dropdown-menu {
  display: block;
}

.nav-dropdown-menu a {
  display: block;
  padding: 0.5rem 1.2rem;
  font-size: 0.8rem;
  letter-spacing: 0.03em;
  text-transform: none;
}

.nav-dropdown-menu a:hover {
  background: var(--card-bg);
}

/* --- Hero Section --- */
.hero {
  padding: 2rem;
}

.hero-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 8px;
}

.hero-main {
  border-radius: 6px;
  overflow: hidden;
  position: relative;
  min-height: 400px;
}

.hero-side {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.hero-side-img {
  flex: 1;
  border-radius: 6px;
  overflow: hidden;
  position: relative;
}

.hero-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 8px;
  margin-top: 8px;
}

.hero-row-img {
  border-radius: 6px;
  overflow: hidden;
  min-height: 160px;
  position: relative;
}

/* Placeholder images */
.img-placeholder {
  background: var(--placeholder-light);
  width: 100%;
  height: 100%;
  min-height: 160px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  color: var(--slate-teal);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.img-placeholder.dark {
  background: var(--placeholder-dark);
}

.img-placeholder.round {
  border-radius: 50%;
  min-height: unset;
}

/* Gradient overlay for category images */
.img-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 40%, rgba(28,53,87,0.55) 100%);
  pointer-events: none;
}

.img-overlay-left {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(28,53,87,0.5) 0%, transparent 60%);
  pointer-events: none;
}

/* --- Tagline Section --- */
.tagline-section {
  text-align: center;
  padding: 3rem 3rem;
}

.tagline-section .tagline {
  font-size: 1.6rem;
  line-height: 1.5;
  margin-bottom: 0.6rem;
}

/* --- Section Divider --- */
.divider {
  border: none;
  border-top: 0.5px solid var(--divider);
  margin: 0 2.5rem;
}

/* --- Section Label --- */
.section-label {
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  color: var(--slate-teal);
  text-transform: uppercase;
  text-align: center;
  margin-bottom: 1.2rem;
}

/* --- Portfolio Categories (Homepage 2x2) --- */
.categories {
  padding: 2rem;
}

.categories-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.category-card {
  border-radius: 6px;
  overflow: hidden;
  position: relative;
  min-height: 240px;
  cursor: pointer;
  transition: transform 0.3s;
}

.category-card:hover {
  transform: scale(1.01);
}

.category-label {
  position: absolute;
  bottom: 1rem;
  left: 1rem;
  z-index: 2;
}

.category-label h3 {
  color: var(--warm-white);
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 1rem;
  margin-bottom: 2px;
}

.category-label span {
  font-size: 0.7rem;
  color: var(--dusty-blush);
  letter-spacing: 0.04em;
}

/* --- About Teaser --- */
.about-teaser {
  padding: 2.5rem;
  display: flex;
  gap: 1.5rem;
  align-items: center;
}

.about-teaser-photo {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  border: 2px solid var(--dusty-blush);
  overflow: hidden;
  flex-shrink: 0;
}

.about-teaser-text h3 {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  margin-bottom: 0.5rem;
}

.about-teaser-text p {
  font-size: 0.9rem;
  line-height: 1.7;
  margin-bottom: 0.5rem;
}

.about-teaser-link {
  font-size: 0.8rem;
  color: var(--dusty-blush);
  letter-spacing: 0.04em;
  transition: color 0.3s;
}

.about-teaser-link:hover {
  color: var(--midnight-navy);
}

/* --- CTA Section --- */
.cta {
  text-align: center;
  padding: 3rem 2rem;
}

.cta .tagline {
  font-size: 1.4rem;
  margin-bottom: 0.4rem;
}

.cta .subline {
  margin-bottom: 1.5rem;
}

.btn-primary {
  display: inline-block;
  background: var(--midnight-navy);
  color: var(--warm-white);
  font-family: var(--font-body);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.85rem 2.2rem;
  border-radius: 28px;
  border: none;
  cursor: pointer;
  transition: background 0.3s;
}

.btn-primary:hover {
  background: #244a73;
}

/* --- Footer --- */
.footer {
  background: var(--midnight-navy);
  padding: 1.8rem 2.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-left p {
  font-family: var(--font-heading);
  font-size: 0.9rem;
  color: var(--warm-white);
  margin-bottom: 0.2rem;
}

.footer-left span {
  font-size: 0.75rem;
  color: var(--slate-teal);
}

.footer-right {
  text-align: right;
}

.footer-right a {
  display: block;
  font-size: 0.75rem;
  color: var(--dusty-blush);
  margin-bottom: 0.2rem;
  transition: color 0.3s;
}

.footer-right a:hover {
  color: var(--warm-white);
}

.footer-right span {
  font-size: 0.75rem;
  color: var(--slate-teal);
}

/* --- Page Header (non-home pages) --- */
.page-header {
  text-align: center;
  padding: 3rem 3rem 2rem;
}

.page-header h1 {
  font-style: italic;
}

.page-header p {
  font-size: 0.95rem;
  color: var(--near-black);
  line-height: 1.7;
  max-width: 500px;
  margin: 0.8rem auto 0;
}

/* --- About Page --- */
.about-hero-img {
  margin: 0 2rem;
  border-radius: 6px;
  overflow: hidden;
  min-height: 350px;
}

.about-bio {
  max-width: 620px;
  margin: 0 auto;
  padding: 2.5rem 2rem;
}

.about-bio h2 {
  font-size: 1.4rem;
  margin-bottom: 1rem;
}

.about-bio p {
  font-size: 0.95rem;
  line-height: 1.8;
  margin-bottom: 1rem;
}

.about-portfolio-img {
  margin: 0 2rem;
  border-radius: 6px;
  overflow: hidden;
  min-height: 280px;
}

/* --- Services Page --- */
.service-section {
  padding: 2.5rem;
  display: flex;
  gap: 1.5rem;
  align-items: flex-start;
}

.service-section.reverse {
  flex-direction: row-reverse;
}

.service-img {
  width: 280px;
  min-height: 240px;
  border-radius: 6px;
  overflow: hidden;
  flex-shrink: 0;
}

.service-content {
  flex: 1;
}

.service-number {
  font-size: 0.68rem;
  color: var(--slate-teal);
  letter-spacing: 0.1em;
  margin-bottom: 0.4rem;
}

.service-content h3 {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  margin-bottom: 0.6rem;
}

.service-content p {
  font-size: 0.9rem;
  line-height: 1.7;
  margin-bottom: 0.6rem;
}

.service-detail {
  font-size: 0.85rem;
  color: var(--dusty-blush);
  letter-spacing: 0.04em;
}

/* What to Expect */
.expect {
  padding: 2.5rem;
  text-align: center;
}

.expect-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 1rem;
}

.expect-item {
  padding: 1rem;
}

.expect-number {
  font-family: var(--font-heading);
  font-size: 2rem;
  color: var(--midnight-navy);
  margin-bottom: 0.4rem;
}

.expect-item p {
  font-size: 0.85rem;
  line-height: 1.6;
}

/* Every Session Includes */
.includes {
  padding: 0 2.5rem 2.5rem;
}

.includes-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.includes-card {
  border-radius: 6px;
  overflow: hidden;
  border: 0.5px solid var(--divider);
}

.includes-card-bar {
  height: 4px;
  background: var(--dusty-blush);
}

.includes-card p {
  padding: 1rem;
  font-size: 0.9rem;
  color: var(--midnight-navy);
}

/* --- Contact Form --- */
.contact-form-section {
  padding: 2.5rem;
}

.contact-form-header {
  text-align: center;
  margin-bottom: 1.8rem;
}

.contact-form-header h2 {
  font-style: italic;
  font-size: 1.4rem;
  margin-bottom: 0.4rem;
}

.contact-form-header p {
  font-size: 0.9rem;
  color: var(--slate-teal);
}

.contact-form {
  max-width: 560px;
  margin: 0 auto;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 10px;
}

.form-input {
  width: 100%;
  background: #fff;
  border: 0.5px solid var(--divider);
  border-radius: 6px;
  padding: 0.85rem 1rem;
  font-family: var(--font-body);
  font-size: 0.85rem;
  color: var(--near-black);
  outline: none;
  transition: border-color 0.3s;
}

.form-input::placeholder {
  color: #b0a89e;
}

.form-input:focus {
  border-color: var(--dusty-blush);
}

.form-input.full {
  margin-bottom: 10px;
}

textarea.form-input {
  min-height: 100px;
  resize: vertical;
  margin-bottom: 1rem;
}

.form-submit {
  text-align: center;
}

/* --- Portfolio Gallery Index --- */
.portfolio-grid {
  padding: 2rem;
}

.portfolio-row-1 {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 10px;
  margin-bottom: 10px;
}

.portfolio-card {
  border-radius: 6px;
  overflow: hidden;
  position: relative;
  cursor: pointer;
  transition: transform 0.3s;
}

.portfolio-card:hover {
  transform: scale(1.01);
}

.portfolio-card.tall {
  min-height: 380px;
}

.portfolio-card.wide {
  min-height: 220px;
}

.portfolio-row-2 {
  display: grid;
  grid-template-columns: 1fr;
}

/* --- Projects Page --- */
.project-header {
  max-width: 680px;
  margin: 0 auto;
  padding: 3rem 2rem 2rem;
}

.project-header h1 {
  font-size: 2rem;
  margin-bottom: 1.2rem;
}

.project-header p {
  font-size: 0.95rem;
  line-height: 1.8;
  margin-bottom: 1rem;
}

.project-gallery {
  padding: 0 2rem 2rem;
  columns: 2;
  column-gap: 10px;
}

.project-gallery-img {
  break-inside: avoid;
  margin-bottom: 10px;
  border-radius: 6px;
  overflow: hidden;
}

/* --- Contact Page --- */
.contact-page {
  max-width: 540px;
  margin: 0 auto;
  padding: 3rem 2rem;
}

.contact-page h1 {
  font-style: italic;
  text-align: center;
  margin-bottom: 0.6rem;
}

.contact-page > p {
  text-align: center;
  font-size: 0.95rem;
  color: var(--near-black);
  margin-bottom: 2.5rem;
}

/* --- Responsive --- */
@media (max-width: 768px) {
  .nav {
    padding: 1rem 1.5rem;
  }

  .nav-links {
    gap: 0.8rem;
  }

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

  .hero-main {
    min-height: 280px;
  }

  .hero-side {
    flex-direction: row;
  }

  .hero-row {
    grid-template-columns: 1fr 1fr;
  }

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

  .category-card {
    min-height: 200px;
  }

  .about-teaser {
    flex-direction: column;
    text-align: center;
  }

  .service-section,
  .service-section.reverse {
    flex-direction: column;
  }

  .service-img {
    width: 100%;
    min-height: 200px;
  }

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

  .form-row {
    grid-template-columns: 1fr;
  }

  .portfolio-row-1 {
    grid-template-columns: 1fr 1fr;
  }

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

  .footer-right {
    text-align: center;
  }

  .project-gallery {
    columns: 1;
  }
}

@media (max-width: 480px) {
  .nav-links {
    gap: 0.5rem;
    font-size: 0.65rem;
  }

  .nav-name {
    font-size: 1rem;
  }

  h1 {
    font-size: 1.8rem;
  }

  .tagline-section .tagline {
    font-size: 1.3rem;
  }

  .portfolio-row-1 {
    grid-template-columns: 1fr;
  }
}

/* --- Mobile Hamburger Menu --- */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  z-index: 300;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--midnight-navy);
  margin: 5px 0;
  transition: transform 0.3s, opacity 0.3s;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

@media (max-width: 768px) {
  .nav-toggle {
    display: block;
  }

  .nav-links {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--warm-white);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 1.8rem;
    z-index: 200;
  }

  .nav-links.nav-open {
    display: flex;
  }

  .nav-links a {
    font-size: 1rem;
  }

  .nav-links .nav-contact {
    font-size: 0.85rem;
    padding: 0.6rem 1.8rem;
  }

  .nav-dropdown-menu {
    position: static;
    box-shadow: none;
    border: none;
    min-width: unset;
    padding: 0;
    text-align: center;
  }

  .nav-dropdown-menu a {
    padding: 0.3rem 0;
    font-size: 0.9rem;
  }
}

/* --- Gallery Pages --- */
.gallery-section {
  padding: 2rem;
}

.gallery-grid {
  columns: 3;
  column-gap: 10px;
}

.gallery-item {
  break-inside: avoid;
  margin-bottom: 10px;
  border-radius: 6px;
  overflow: hidden;
  cursor: pointer;
  transition: opacity 0.3s;
}

.gallery-item:hover {
  opacity: 0.88;
}

.gallery-item img {
  width: 100%;
  display: block;
  background: var(--placeholder-light);
  min-height: 200px;
}

.gallery-back {
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  color: var(--slate-teal);
  text-transform: uppercase;
  display: inline-block;
  margin-bottom: 0.8rem;
  transition: color 0.2s;
}

.gallery-back:hover {
  color: var(--midnight-navy);
}

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

.lightbox.is-open {
  display: flex;
}

.lightbox-figure {
  max-width: 90vw;
  max-height: 88vh;
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lightbox-img {
  max-width: 90vw;
  max-height: 88vh;
  object-fit: contain;
  border-radius: 3px;
  background: transparent;
  min-height: unset;
  height: auto;
}

.lightbox-close,
.lightbox-prev,
.lightbox-next {
  background: none;
  border: none;
  color: var(--warm-white);
  cursor: pointer;
  opacity: 0.65;
  transition: opacity 0.2s;
  line-height: 1;
  padding: 0.75rem;
}

.lightbox-close:hover,
.lightbox-prev:hover,
.lightbox-next:hover {
  opacity: 1;
}

.lightbox-close {
  position: absolute;
  top: 1rem;
  right: 1.2rem;
  font-size: 1.8rem;
}

.lightbox-prev,
.lightbox-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.5rem;
}

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

/* --- Image object-fit rules --- */
.hero-main img,
.hero-side-img img,
.hero-row-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  background: var(--placeholder-light);
}

.hero-main img { min-height: 400px; }
.hero-side-img img { min-height: 196px; }
.hero-row-img img { min-height: 160px; }

.category-card > img {
  width: 100%;
  min-height: 240px;
  object-fit: cover;
  display: block;
  background: var(--placeholder-light);
}

.portfolio-card > img {
  width: 100%;
  object-fit: cover;
  display: block;
  background: var(--placeholder-light);
}

.portfolio-card.tall > img { min-height: 380px; }
.portfolio-card.wide > img { min-height: 220px; }

.service-img img {
  width: 100%;
  height: 100%;
  min-height: 240px;
  object-fit: cover;
  display: block;
  background: var(--placeholder-light);
}

.about-hero-img img {
  width: 100%;
  min-height: 350px;
  object-fit: cover;
  display: block;
  background: var(--placeholder-light);
}

.about-portfolio-img img {
  width: 100%;
  min-height: 280px;
  object-fit: cover;
  display: block;
  background: var(--placeholder-light);
}

.about-teaser-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  background: var(--placeholder-light);
}

.project-gallery-img img {
  width: 100%;
  display: block;
  background: var(--placeholder-light);
}

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

@media (max-width: 480px) {
  .gallery-grid { columns: 1; }
  .lightbox-prev,
  .lightbox-next { font-size: 1.2rem; padding: 0.5rem; }
}

/* --- Skip to Content (Accessibility) --- */
.skip-link {
  position: absolute;
  top: -100%;
  left: 0;
  background: var(--midnight-navy);
  color: var(--warm-white);
  padding: 0.5rem 1rem;
  z-index: 999;
  font-size: 0.85rem;
}

.skip-link:focus {
  top: 0;
}
