/* ==========================================================================
   VARIABLES & CONFIGURACIÓN BASE (Estética Estudio de Arte & Lino)
   ========================================================================== */
:root {
  --bg-ivory: #FAF7F2;
  --bg-linen: #F2ECE1;
  --text-charcoal: #1E1B18;
  --text-muted: #5C554E;
  --gold-primary: #C5A059;
  --gold-dark: #9E7B36;
  --gold-light: #E6D5B8;
  --frame-wood: #2C221E;
  --white-glass: rgba(255, 255, 255, 0.72);
  --border-glass: rgba(197, 160, 89, 0.28);
  --shadow-soft: 0 20px 45px rgba(30, 27, 24, 0.08);
  --shadow-canvas: 0 28px 60px rgba(28, 22, 18, 0.22);
  --font-serif: 'Cormorant Garamond', Georgia, serif;
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --transition: all 0.35s cubic-bezier(0.25, 0.8, 0.25, 1);
}

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

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg-ivory);
  color: var(--text-charcoal);
  font-family: var(--font-sans);
  line-height: 1.65;
  overflow-x: hidden;
  position: relative;
}

/* Textura sutil que simula el entramado de un lienzo */
.canvas-texture {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 999;
  opacity: 0.25;
  background-image: 
    repeating-linear-gradient(0deg, rgba(0,0,0,0.015) 0px, rgba(0,0,0,0.015) 1px, transparent 1px, transparent 3px),
    repeating-linear-gradient(90deg, rgba(0,0,0,0.015) 0px, rgba(0,0,0,0.015) 1px, transparent 1px, transparent 3px);
}

.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
}

h1, h2, h3 {
  font-family: var(--font-serif);
  font-weight: 600;
  line-height: 1.15;
  color: var(--text-charcoal);
}

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

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

/* ==========================================================================
   COMPONENTES REUTILIZABLES (Botones, Glass Cards, Etiquetas)
   ========================================================================== */
.glass-card {
  background: var(--white-glass);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--border-glass);
  border-radius: 16px;
  box-shadow: var(--shadow-soft);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.9rem 1.8rem;
  border-radius: 50px;
  font-size: 0.92rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  cursor: pointer;
  transition: var(--transition);
  border: 1px solid transparent;
}

.btn-primary {
  background: var(--text-charcoal);
  color: var(--bg-ivory);
}

.btn-primary:hover {
  background: var(--gold-dark);
  transform: translateY(-2px);
}

.btn-gold {
  background: var(--gold-primary);
  color: #fff;
}

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

.btn-outline {
  background: transparent;
  border-color: var(--gold-primary);
  color: var(--text-charcoal);
}

.btn-outline:hover {
  background: var(--gold-primary);
  color: #fff;
}

.btn-sm {
  padding: 0.6rem 1.25rem;
  font-size: 0.85rem;
}

.btn-full {
  width: 100%;
}

/* ==========================================================================
   NAVBAR
   ========================================================================== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  padding: 1.2rem 0;
  transition: var(--transition);
}

.navbar.scrolled {
  background: rgba(250, 247, 242, 0.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--border-glass);
}

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

.brand {
  display: flex;
  flex-direction: column;
}

.brand-title {
  font-family: var(--font-serif);
  font-size: 1.85rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1;
}

.brand-subtitle {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--gold-dark);
  margin-top: 2px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav-links a:not(.btn) {
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 500;
}

.nav-links a:not(.btn):hover {
  color: var(--gold-dark);
}

.menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  flex-direction: column;
  gap: 5px;
}

.menu-toggle span {
  width: 24px;
  height: 2px;
  background: var(--text-charcoal);
  transition: var(--transition);
}

/* ==========================================================================
   HERO SECTION & BASTIDOR 3D
   ========================================================================== */
.hero {
  padding: 9rem 0 5rem;
  min-height: 92vh;
  display: flex;
  align-items: center;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 4rem;
  align-items: center;
}

.badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.4rem 1rem;
  border-radius: 50px;
  background: var(--bg-linen);
  border: 1px solid var(--gold-light);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--gold-dark);
  margin-bottom: 1.4rem;
}

.dot-live {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold-primary);
  box-shadow: 0 0 0 4px rgba(197, 160, 89, 0.25);
}

.hero h1 {
  font-size: clamp(2.6rem, 4.5vw, 4.1rem);
  margin-bottom: 1.3rem;
}

.hero h1 em {
  color: var(--gold-dark);
  font-style: italic;
  font-weight: 400;
}

.hero-lead {
  font-size: 1.08rem;
  color: var(--text-muted);
  margin-bottom: 2.2rem;
  max-width: 540px;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 3rem;
}

.hero-metrics {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding-top: 1.8rem;
  border-top: 1px solid var(--gold-light);
}

.metric-item {
  display: flex;
  flex-direction: column;
}

.metric-item strong {
  font-family: var(--font-serif);
  font-size: 1.45rem;
  color: var(--text-charcoal);
}

.metric-item span {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.metric-divider {
  width: 1px;
  height: 36px;
  background: var(--gold-light);
}

/* Showcase del Cuadro Principal */
.hero-showcase {
  position: relative;
  display: flex;
  justify-content: center;
}

.canvas-frame-outer {
  background: var(--frame-wood);
  padding: 14px;
  border-radius: 6px;
  box-shadow: var(--shadow-canvas);
  border: 2px solid var(--gold-primary);
  transform: perspective(1000px) rotateY(-4deg) rotateX(2deg);
  transition: var(--transition);
}

.canvas-frame-outer:hover {
  transform: perspective(1000px) rotateY(0deg) rotateX(0deg);
}

.canvas-frame-inner {
  position: relative;
  border: 6px solid #F7F3EB;
  overflow: hidden;
  aspect-ratio: 4 / 5;
  max-width: 400px;
}

.hero-painting-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.floating-badge-top {
  position: absolute;
  top: -18px;
  left: -20px;
  padding: 0.85rem 1.1rem;
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.palette-dots {
  display: flex;
  gap: 4px;
}

.palette-dots span {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.8);
}

.floating-text {
  display: flex;
  flex-direction: column;
}

.floating-text strong {
  font-size: 0.82rem;
}

.floating-text small {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.floating-badge-bottom {
  position: absolute;
  bottom: -22px;
  right: -15px;
  padding: 1rem 1.3rem;
  display: flex;
  flex-direction: column;
}

.badge-tag {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--gold-dark);
  font-weight: 600;
}

/* ==========================================================================
   SECCIONES GENERALES & PROCESO
   ========================================================================== */
.section {
  padding: 6rem 0;
}

.bg-linen {
  background-color: var(--bg-linen);
}

.section-header {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 3.5rem;
}

.section-eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--gold-dark);
  font-weight: 600;
  margin-bottom: 0.6rem;
}

.section-header h2 {
  font-size: clamp(2.1rem, 3.5vw, 3rem);
  margin-bottom: 0.9rem;
}

.section-header p {
  color: var(--text-muted);
}

.process-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.8rem;
}

.process-card {
  padding: 2.2rem 1.8rem;
  transition: var(--transition);
}

.process-card:hover {
  transform: translateY(-6px);
}

.step-number {
  font-family: var(--font-serif);
  font-size: 2.5rem;
  color: var(--gold-primary);
  display: block;
  margin-bottom: 0.8rem;
  line-height: 1;
}

.process-card h3 {
  font-size: 1.45rem;
  margin-bottom: 0.7rem;
}

.process-card p {
  font-size: 0.92rem;
  color: var(--text-muted);
}

/* ==========================================================================
   GALERÍA DE CUADROS CON MARCOS FLOTANTES
   ========================================================================== */
.gallery-filters {
  display: flex;
  justify-content: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 2.8rem;
}

.filter-btn {
  background: transparent;
  border: 1px solid var(--gold-light);
  padding: 0.55rem 1.3rem;
  border-radius: 50px;
  font-family: var(--font-sans);
  font-size: 0.86rem;
  color: var(--text-muted);
  cursor: pointer;
  transition: var(--transition);
}

.filter-btn.active,
.filter-btn:hover {
  background: var(--text-charcoal);
  color: var(--bg-ivory);
  border-color: var(--text-charcoal);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 2.5rem;
}

.gallery-item {
  cursor: pointer;
  transition: var(--transition);
}

.gallery-item.hidden {
  display: none;
}

.painting-frame {
  position: relative;
  background: var(--frame-wood);
  padding: 12px;
  border: 1px solid var(--gold-primary);
  box-shadow: var(--shadow-soft);
  aspect-ratio: 4 / 5;
  overflow: hidden;
}

.painting-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border: 4px solid #FAF7F2;
  transition: transform 0.6s ease;
}

.gallery-item:hover .painting-frame img {
  transform: scale(1.04);
}

.painting-overlay {
  position: absolute;
  inset: 16px;
  background: rgba(28, 25, 23, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: var(--transition);
}

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

.view-icon {
  background: var(--bg-ivory);
  color: var(--text-charcoal);
  padding: 0.6rem 1.2rem;
  border-radius: 50px;
  font-size: 0.82rem;
  font-weight: 500;
}

.painting-caption {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding-top: 1rem;
}

.painting-caption h3 {
  font-size: 1.35rem;
}

.painting-caption p {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.canvas-dimension {
  font-size: 0.78rem;
  padding: 0.25rem 0.65rem;
  background: var(--bg-linen);
  border: 1px solid var(--gold-light);
  border-radius: 6px;
  color: var(--gold-dark);
  font-weight: 600;
}

/* ==========================================================================
   SOBRE LA ARTISTA
   ========================================================================== */
.artist-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 4rem;
  align-items: center;
}

.artist-image-wrapper {
  position: relative;
}

.artist-frame {
  border-radius: 180px 180px 16px 16px;
  overflow: hidden;
  border: 6px solid #fff;
  box-shadow: var(--shadow-soft);
  aspect-ratio: 4 / 5;
}

.artist-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.artist-quote-card {
  position: absolute;
  bottom: -20px;
  right: -20px;
  max-width: 290px;
  padding: 1.2rem;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.15rem;
}

.artist-bio h2 {
  font-size: clamp(2rem, 3.2vw, 2.8rem);
  margin-bottom: 1.2rem;
}

.artist-bio p {
  color: var(--text-muted);
  margin-bottom: 1rem;
}

.artist-features {
  list-style: none;
  margin-top: 1.5rem;
}

.artist-features li {
  margin-bottom: 0.65rem;
  font-size: 0.95rem;
  color: var(--text-charcoal);
}

/* ==========================================================================
   COLECCIONES Y DIMENSIONES
   ========================================================================== */
.packages-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  align-items: stretch;
}

.package-card {
  padding: 2.5rem 2rem;
  display: flex;
  flex-direction: column;
  position: relative;
}

.package-featured {
  border: 2px solid var(--gold-primary);
  transform: translateY(-8px);
}

.popular-ribbon {
  position: absolute;
  top: -13px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--gold-primary);
  color: #fff;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  padding: 0.3rem 1rem;
  border-radius: 50px;
  font-weight: 600;
}

.canvas-scale-visual {
  height: 110px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.2rem;
}

.scale-box {
  border: 2px solid var(--gold-dark);
  background: var(--bg-linen);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-serif);
  font-weight: 700;
  color: var(--gold-dark);
  box-shadow: inset 0 0 0 4px #fff;
}

.scale-sm { width: 64px; height: 82px; font-size: 0.75rem; }
.scale-md { width: 78px; height: 98px; font-size: 0.82rem; }
.scale-lg { width: 92px; height: 112px; font-size: 0.88rem; }

.package-card h3 {
  font-size: 1.65rem;
  text-align: center;
  margin-bottom: 0.6rem;
}

.package-desc {
  text-align: center;
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

.package-list {
  list-style: none;
  margin-bottom: 2rem;
  flex-grow: 1;
}

.package-list li {
  padding: 0.55rem 0;
  border-bottom: 1px dashed var(--gold-light);
  font-size: 0.9rem;
}

/* ==========================================================================
   COTIZADOR & WHATSAPP PREVIEW
   ========================================================================== */
.quote-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 2.5rem;
  align-items: start;
}

.quote-form-wrapper {
  padding: 2.8rem;
}

.quote-form-wrapper h2 {
  font-size: 2.2rem;
  margin-bottom: 0.5rem;
}

.quote-form-wrapper > p {
  color: var(--text-muted);
  margin-bottom: 2rem;
  font-size: 0.94rem;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.2rem;
}

.form-group {
  margin-bottom: 1.3rem;
  display: flex;
  flex-direction: column;
}

.form-group label {
  font-size: 0.82rem;
  font-weight: 600;
  margin-bottom: 0.45rem;
}

.form-group input,
.form-group select,
.form-group textarea {
  padding: 0.8rem 1rem;
  border-radius: 10px;
  border: 1px solid var(--gold-light);
  background: rgba(255, 255, 255, 0.9);
  font-family: var(--font-sans);
  font-size: 0.92rem;
  color: var(--text-charcoal);
}

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

.quote-preview {
  padding: 2.2rem;
}

.quote-preview h3 {
  font-size: 1.5rem;
  margin: 0.4rem 0 0.6rem;
}

.preview-helper {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-bottom: 1.2rem;
}

.wa-preview-box {
  background: #FAF6EE;
  border-left: 3px solid var(--gold-primary);
  padding: 1rem;
  border-radius: 8px;
  font-size: 0.88rem;
  white-space: pre-line;
  margin-bottom: 1.5rem;
}

.contact-direct-info {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  font-size: 0.86rem;
  border-top: 1px solid var(--gold-light);
  padding-top: 1.2rem;
}

.contact-direct-info div {
  display: flex;
  flex-direction: column;
}

/* ==========================================================================
   LIGHTBOX MODAL & FOOTER
   ========================================================================== */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(20, 18, 16, 0.92);
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

.lightbox.open {
  display: flex;
}

.lightbox-content {
  max-width: 720px;
  width: 100%;
  text-align: center;
}

.lightbox-content img {
  max-height: 75vh;
  margin: 0 auto;
  border: 8px solid #FAF7F2;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}

.lightbox-caption {
  color: #FAF7F2;
  margin-top: 1rem;
}

.lightbox-caption h3 {
  color: #FAF7F2;
  font-size: 1.6rem;
}

.lightbox-caption p {
  color: var(--gold-light);
  font-size: 0.9rem;
}

.lightbox-close {
  position: absolute;
  top: 24px;
  right: 32px;
  background: none;
  border: none;
  color: #fff;
  font-size: 2.6rem;
  cursor: pointer;
}

.footer {
  background: var(--text-charcoal);
  color: var(--bg-linen);
  padding: 3rem 0;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.footer .brand-title {
  color: var(--gold-primary);
}

.footer-copy {
  font-size: 0.85rem;
  color: #A39B93;
}

/* ==========================================================================
   RESPONSIVE DESIGN (Móviles y Tablets)
   ========================================================================== */
@media (max-width: 960px) {
  .hero-grid,
  .artist-grid,
  .quote-grid {
    grid-template-columns: 1fr;
  }

  .hero {
    padding-top: 7.5rem;
  }

  .package-featured {
    transform: none;
  }

  .menu-toggle {
    display: flex;
  }

  .nav-links {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: var(--bg-ivory);
    flex-direction: column;
    padding: 1.5rem;
    border-bottom: 1px solid var(--gold-light);
    display: none;
  }

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

@media (max-width: 600px) {
  .form-row {
    grid-template-columns: 1fr;
  }

  .hero-metrics {
    flex-direction: column;
    align-items: flex-start;
  }

  .metric-divider {
    display: none;
  }
}