/* =====================================================
   MAMB — Museo de Arte Moderno de Barranquilla
   CSS Principal · mamb-interactivo
   ===================================================== */

/* ---- TOKENS ---- */
:root {
  --dark:     #12102A;
  --dark-mid: #1A1835;
  --cream:    #F5F0E8;
  --cream-2:  #EDE7DA;
  --gold:     #C9A84C;
  --gold-lt:  #E2C97A;
  --gold-dk:  #9A7A2E;
  --white:    #FFFFFF;
  --text-dk:  #0E0C20;
  --text-md:  #3A3650;
  --text-lt:  #8A879A;
  --red-tag:  #C0392B;

  --font-serif: 'Playfair Display', Georgia, serif;
  --font-body:  'DM Sans', system-ui, sans-serif;
  --font-alt:   'Cormorant Garamond', Georgia, serif;

  --r-sm: 8px;
  --r-md: 16px;
  --r-lg: 24px;
  --r-xl: 40px;

  --shadow: 0 4px 32px rgba(18,16,42,.18);
  --shadow-lg: 0 12px 60px rgba(18,16,42,.28);
}

/* ---- RESET ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body {
  font-family: var(--font-body);
  background: var(--cream);
  color: var(--text-dk);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
a { text-decoration: none; color: inherit; }
img { display: block; width: 100%; }
button { cursor: pointer; font-family: inherit; border: none; background: none; }
.hidden { display: none !important; }

/* =====================================================
   SPLASH SCREEN
   ===================================================== */
#splash {
  position: fixed; inset: 0; z-index: 9999;
  background: var(--dark);
  display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 16px;
  transition: opacity .6s ease, visibility .6s ease;
}
#splash.gone { opacity: 0; visibility: hidden; pointer-events: none; }
.splash-icon { animation: splashPulse 2s ease infinite; }
.splash-title {
  font-family: var(--font-serif);
  font-size: clamp(2rem, 6vw, 3.5rem);
  color: var(--white);
  letter-spacing: .04em;
}
.splash-sub {
  font-size: .85rem;
  color: var(--gold);
  letter-spacing: .12em;
  text-transform: uppercase;
}
@keyframes splashPulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.08); opacity: .8; }
}

/* =====================================================
   NAVBAR
   ===================================================== */
#navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: rgba(18,16,42,.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(201,168,76,.15);
  transition: transform .3s ease;
}
.nav-inner {
  max-width: 1200px; margin: 0 auto;
  display: flex; align-items: center; gap: 32px;
  padding: 0 24px; height: 64px;
}
.nav-logo {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--font-serif); font-size: 1.15rem;
  color: var(--white); letter-spacing: .06em;
}
.nav-links {
  display: flex; list-style: none; gap: 28px; margin: 0 auto;
}
.nav-links a {
  color: rgba(255,255,255,.7); font-size: .85rem;
  letter-spacing: .08em; text-transform: uppercase;
  transition: color .2s;
}
.nav-links a:hover { color: var(--gold); }
.nav-cta {
  font-size: .8rem; letter-spacing: .1em; text-transform: uppercase;
  color: var(--gold); border: 1px solid var(--gold);
  padding: 8px 20px; border-radius: 40px;
  transition: background .2s, color .2s;
  white-space: nowrap;
}
.nav-cta:hover { background: var(--gold); color: var(--dark); }
.burger {
  display: none; flex-direction: column; gap: 5px; padding: 4px; margin-left: auto;
}
.burger span {
  display: block; width: 22px; height: 2px;
  background: var(--white); border-radius: 2px;
  transition: transform .3s, opacity .3s;
}
.mobile-menu {
  display: none; flex-direction: column;
  padding: 16px 24px 20px; gap: 12px;
  border-top: 1px solid rgba(201,168,76,.1);
}
.mobile-menu a {
  color: rgba(255,255,255,.8); font-size: .95rem;
  letter-spacing: .06em; padding: 6px 0;
}
.mobile-menu .mobile-cta {
  margin-top: 8px; color: var(--gold);
  font-weight: 500; letter-spacing: .1em;
}
@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-cta { display: none; }
  .burger { display: flex; }
  .mobile-menu.open { display: flex; }
}

/* =====================================================
   BUTTONS
   ===================================================== */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 10px; font-family: var(--font-body); font-size: .8rem;
  font-weight: 500; letter-spacing: .14em; text-transform: uppercase;
  padding: 16px 32px; border-radius: var(--r-xl);
  transition: transform .2s, box-shadow .2s, background .2s, color .2s;
  cursor: pointer;
}
.btn:active { transform: scale(.97); }
.btn-primary {
  background: var(--dark); color: var(--white);
  box-shadow: 0 2px 20px rgba(18,16,42,.3);
}
.btn-primary:hover {
  background: var(--dark-mid);
  box-shadow: 0 4px 32px rgba(18,16,42,.45);
}
.btn-secondary {
  background: transparent; color: var(--dark);
  border: 1.5px solid var(--dark);
}
.btn-secondary:hover { background: var(--dark); color: var(--white); }
.btn-outline-light {
  background: transparent; color: var(--white);
  border: 1.5px solid rgba(255,255,255,.5);
}
.btn-outline-light:hover { background: rgba(255,255,255,.1); border-color: var(--white); }
.btn-outline {
  background: transparent; color: var(--dark);
  border: 1.5px solid var(--dark);
}
.btn-gold {
  background: var(--gold); color: var(--dark);
  font-weight: 600;
  box-shadow: 0 2px 20px rgba(201,168,76,.35);
}
.btn-gold:hover { background: var(--gold-lt); box-shadow: 0 4px 32px rgba(201,168,76,.5); }
.btn-ghost {
  background: transparent; color: var(--dark);
  font-size: .78rem; letter-spacing: .12em;
}
.btn-ghost:hover { color: var(--text-md); }
.btn-full { width: 100%; }
.btn-large { padding: 20px 48px; font-size: .9rem; }

/* =====================================================
   HERO
   ===================================================== */
.hero {
  min-height: 100vh;
  position: relative;
  display: flex; align-items: center;
  padding: 120px 24px 80px;
  overflow: hidden;
  background: var(--dark);
}
.hero-bg {
  position: absolute; inset: 0; pointer-events: none;
}
.hero-grain {
  position: absolute; inset: 0;
  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.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.06'/%3E%3C/svg%3E");
  opacity: .5;
}
.hero-orb {
  position: absolute; border-radius: 50%;
  filter: blur(80px); pointer-events: none;
}
.orb-1 {
  width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(201,168,76,.12) 0%, transparent 70%);
  top: -150px; right: -100px;
}
.orb-2 {
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(60,50,120,.3) 0%, transparent 70%);
  bottom: 0; left: 0;
}
.hero-lines {
  position: absolute; inset: 0; display: flex;
  flex-direction: column; justify-content: space-evenly;
  padding: 0 10%;
}
.h-line {
  width: 100%; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(201,168,76,.08), transparent);
}
.hero-content {
  position: relative; z-index: 2;
  max-width: 720px; margin: 0 auto;
}
.hero-eyebrow {
  font-size: .8rem; letter-spacing: .2em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 20px;
}
.hero-title {
  font-family: var(--font-serif);
  font-size: clamp(3rem, 8vw, 6.5rem);
  font-weight: 900; color: var(--white);
  line-height: 1.05; margin-bottom: 28px;
}
.hero-title em {
  font-style: italic; color: var(--gold);
}
.hero-body {
  font-size: 1.1rem; color: rgba(255,255,255,.65);
  max-width: 480px; line-height: 1.7; margin-bottom: 40px;
}
.hero-actions {
  display: flex; gap: 16px; flex-wrap: wrap;
}
.hero-scroll {
  position: absolute; bottom: 40px; left: 50%; transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 10px;
  color: rgba(255,255,255,.4); font-size: .72rem;
  letter-spacing: .15em; text-transform: uppercase;
}
.scroll-line {
  width: 1px; height: 48px;
  background: linear-gradient(to bottom, rgba(255,255,255,.3), transparent);
  animation: scrollDrop 2s ease infinite;
}
@keyframes scrollDrop {
  0% { opacity: 0; transform: scaleY(0); transform-origin: top; }
  50% { opacity: 1; transform: scaleY(1); }
  100% { opacity: 0; transform: scaleY(1); transform-origin: bottom; }
}

/* =====================================================
   STRIP
   ===================================================== */
.strip {
  background: var(--gold); padding: 14px 0;
  overflow: hidden; white-space: nowrap;
}
.strip-track {
  display: inline-flex; gap: 32px; align-items: center;
  animation: marquee 28s linear infinite;
  font-size: .78rem; font-weight: 500;
  letter-spacing: .1em; text-transform: uppercase;
  color: var(--dark);
}
.strip-track span:nth-child(even) { opacity: .5; }
@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* =====================================================
   INTERACTIVE BANNER
   ===================================================== */
.interactive-banner {
  background: var(--cream);
  padding: 100px 24px;
}
.ib-inner {
  max-width: 1100px; margin: 0 auto;
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 80px; align-items: center;
}
.ib-eyebrow {
  font-size: .78rem; letter-spacing: .18em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 16px;
}
.ib-title {
  font-family: var(--font-serif);
  font-size: clamp(2.2rem, 5vw, 3.8rem);
  font-weight: 900; line-height: 1.08;
  color: var(--text-dk); margin-bottom: 24px;
}
.ib-title em { font-style: italic; color: var(--dark); }
.ib-body {
  font-size: 1rem; color: var(--text-md);
  line-height: 1.7; max-width: 400px; margin-bottom: 36px;
}
.ib-visual {
  position: relative; height: 380px;
  display: flex; align-items: center; justify-content: center;
}
.ib-card {
  position: absolute; border-radius: var(--r-lg);
  overflow: hidden; box-shadow: var(--shadow-lg);
}
.ib-card-back {
  width: 220px; height: 280px;
  top: 20px; right: 0;
  transform: rotate(6deg);
  z-index: 1;
}
.ib-card-front {
  width: 240px; height: 300px;
  bottom: 20px; left: 0;
  transform: rotate(-4deg);
  z-index: 2;
}
.ib-card-art {
  width: 100%; height: 100%; background-size: cover; background-position: center;
}
.ib-art-1 {
  background: linear-gradient(135deg, #1a5c8a 0%, #0e3d5e 30%, #1a8a6b 60%, #0e5e3d 100%);
  position: relative;
}
.ib-art-1::after {
  content: '';
  position: absolute; inset: 0;
  background: repeating-linear-gradient(
    45deg, transparent, transparent 8px,
    rgba(255,255,255,.05) 8px, rgba(255,255,255,.05) 9px
  );
}
.ib-art-2 {
  background: linear-gradient(135deg, #d4732a 0%, #a84b18 40%, #e8a855 100%);
}
.ib-card-label {
  position: absolute; bottom: 0; left: 0; right: 0;
  background: rgba(255,255,255,.95);
  padding: 12px 14px;
}
.ib-label-num {
  display: block; font-size: .62rem; letter-spacing: .15em;
  text-transform: uppercase; color: var(--red-tag); margin-bottom: 2px;
}
.ib-label-title {
  display: block; font-family: var(--font-serif);
  font-size: .9rem; font-weight: 700; color: var(--text-dk);
}
.ib-badge {
  position: absolute; top: 30px; right: 30px; z-index: 3;
  width: 72px; height: 72px; border-radius: 50%;
  background: var(--dark); border: 2px solid var(--gold);
  display: flex; align-items: center; justify-content: center;
  animation: rotateBadge 12s linear infinite;
}
.ib-badge-inner {
  display: flex; flex-direction: column;
  align-items: center; gap: 1px;
  font-size: .55rem; letter-spacing: .12em;
  text-transform: uppercase; color: var(--gold);
  font-weight: 500;
}
@keyframes rotateBadge {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}
@media (max-width: 768px) {
  .ib-inner { grid-template-columns: 1fr; gap: 40px; }
  .ib-visual { height: 280px; order: -1; }
  .ib-card-front { width: 180px; height: 220px; left: 20px; }
  .ib-card-back { width: 160px; height: 200px; right: 10px; }
}

/* =====================================================
   SECTION HEADERS
   ===================================================== */
.section-header {
  max-width: 1100px; margin: 0 auto 60px;
  padding: 0 24px;
}
.section-eyebrow {
  font-size: .78rem; letter-spacing: .2em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 12px;
}
.section-title {
  font-family: var(--font-serif);
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 900; line-height: 1.12; color: var(--text-dk);
}
.section-header.light .section-title { color: var(--white); }
.section-header.light .section-eyebrow { color: var(--gold-lt); }

/* =====================================================
   COLLECTION
   ===================================================== */
.collection {
  padding: 100px 24px;
  background: var(--dark);
}
.collection .section-header { color: var(--white); }
.collection .section-title { color: var(--white); }
.collection-grid {
  max-width: 1100px; margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: auto auto;
  gap: 20px;
}
.col-item {
  border-radius: var(--r-lg); overflow: hidden;
  position: relative; cursor: pointer;
  transition: transform .3s;
}
.col-item:hover { transform: translateY(-4px); }
.col-item--large {
  grid-row: span 2;
}
.col-img {
  width: 100%; height: 220px; position: relative;
}
.col-item--large .col-img { height: 100%; min-height: 460px; }
.col-texture {
  position: absolute; inset: 0;
  background-image: radial-gradient(circle at 30% 40%, rgba(255,255,255,.08) 0%, transparent 60%);
}
.col-info {
  position: absolute; bottom: 0; left: 0; right: 0;
  background: linear-gradient(to top, rgba(18,16,42,.95) 0%, transparent 100%);
  padding: 40px 20px 20px;
  color: var(--white);
}
.col-tag {
  font-size: .7rem; letter-spacing: .14em; text-transform: uppercase;
  color: var(--gold); display: block; margin-bottom: 6px;
}
.col-info h3 {
  font-family: var(--font-serif); font-size: 1.2rem;
  font-weight: 700; margin-bottom: 2px;
}
.col-info p { font-size: .85rem; color: rgba(255,255,255,.65); }
@media (max-width: 600px) {
  .collection-grid { grid-template-columns: 1fr; }
  .col-item--large { grid-row: span 1; }
  .col-item--large .col-img { min-height: 240px; }
}

/* =====================================================
   ARTISTS
   ===================================================== */
.artists {
  padding: 100px 24px;
  background: var(--dark-mid);
}
.artists-grid {
  max-width: 1100px; margin: 0 auto;
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.artist-card {
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(201,168,76,.12);
  border-radius: var(--r-lg); overflow: hidden;
  transition: transform .3s, border-color .3s;
}
.artist-card:hover {
  transform: translateY(-6px);
  border-color: rgba(201,168,76,.35);
}
.artist-portrait {
  height: 220px; background-size: cover; background-position: center top;
}
.a1 { background: linear-gradient(160deg, #1a3a2a, #2d6b4a, #1a3a2a); }
.a2 { background: linear-gradient(160deg, #2a1a1a, #6b2d2d, #2a1a1a); }
.a3 { background: linear-gradient(160deg, #1a2a3a, #2d4a6b, #1a2a3a); }
.artist-info { padding: 24px; }
.artist-info h3 {
  font-family: var(--font-serif); font-size: 1.2rem;
  color: var(--white); margin-bottom: 4px;
}
.artist-dates { font-size: .78rem; color: var(--gold); margin-bottom: 12px; }
.artist-bio { font-size: .88rem; color: rgba(255,255,255,.65); line-height: 1.6; margin-bottom: 16px; }
.artist-tag {
  font-size: .68rem; letter-spacing: .12em; text-transform: uppercase;
  border: 1px solid rgba(201,168,76,.3); color: var(--gold);
  padding: 4px 12px; border-radius: 40px; display: inline-block;
}
@media (max-width: 768px) {
  .artists-grid { grid-template-columns: 1fr; }
}

/* =====================================================
   VISIT
   ===================================================== */
.visit {
  padding: 100px 24px;
  background: var(--cream-2);
}
.visit-inner {
  max-width: 1100px; margin: 0 auto;
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 80px; align-items: center;
}
.visit .section-title em { font-style: italic; color: var(--dark); }
.visit-details { margin-top: 40px; display: flex; flex-direction: column; gap: 28px; }
.visit-item {
  display: flex; gap: 20px; align-items: flex-start;
}
.visit-icon {
  font-size: 1.5rem; color: var(--gold);
  min-width: 32px; margin-top: 2px;
}
.visit-item strong { display: block; font-size: .8rem; letter-spacing: .12em; text-transform: uppercase; margin-bottom: 6px; color: var(--text-dk); }
.visit-item p { font-size: .9rem; color: var(--text-md); line-height: 1.6; }
.visit-map {
  border-radius: var(--r-lg); overflow: hidden;
  height: 380px; background: #c8d6e0;
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow);
  position: relative;
}
.map-placeholder {
  display: flex; flex-direction: column;
  align-items: center; gap: 12px; text-align: center;
  color: var(--text-md);
}
.map-placeholder p { font-size: .9rem; line-height: 1.5; }
/* Map embed: make iframe fill the visit-map container exactly */
.map-embed {
  width: 100%;
  height: 100%;
}
.map-embed iframe {
  width: 100%;
  height: 100%;
  display: block;
  border: 0;
}
@media (max-width: 768px) {
  .visit-inner { grid-template-columns: 1fr; gap: 40px; }
  .visit-map { height: 240px; }
}

/* =====================================================
   ABOUT TABS
   ===================================================== */
.about {
  background: var(--dark);
  padding: 100px 24px;
}
.about-inner {
  max-width: 800px; margin: 0 auto;
}
.about-tabs {
  display: flex; gap: 0; border-bottom: 1px solid rgba(201,168,76,.2);
  margin-bottom: 48px;
}
.tab-btn {
  font-family: var(--font-body);
  font-size: .78rem; letter-spacing: .14em; text-transform: uppercase;
  color: rgba(255,255,255,.45); padding: 12px 24px;
  border-bottom: 2px solid transparent; margin-bottom: -1px;
  transition: color .25s, border-color .25s;
}
.tab-btn.active { color: var(--gold); border-color: var(--gold); }
.tab-pane { display: none; animation: fadeIn .3s ease; }
.tab-pane.active { display: block; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.tab-pane h2 {
  font-family: var(--font-serif); font-size: clamp(1.8rem, 5vw, 2.8rem);
  color: var(--white); margin-bottom: 16px;
}
.tab-lead {
  font-family: var(--font-alt); font-size: 1.3rem;
  color: rgba(255,255,255,.8); margin-bottom: 20px; font-style: italic;
}
.tab-pane p {
  font-size: .95rem; color: rgba(255,255,255,.6);
  line-height: 1.75; margin-bottom: 16px;
}
.about-map {
  width: 100%;
  height: 360px;
  margin-top: 34px;
  border: 1px solid rgba(201,168,76,.22);
  border-radius: var(--r-lg);
  overflow: hidden;
  background: rgba(255,255,255,.08);
  box-shadow: 0 24px 70px rgba(0,0,0,.24);
}
@media (max-width: 768px) {
  .about-map { height: 260px; }
}

/* =====================================================
   FINAL CTA
   ===================================================== */
.final-cta {
  background: var(--cream);
  padding: 120px 24px;
  text-align: center;
}
.fct-inner { max-width: 640px; margin: 0 auto; }
.fct-inner h2 {
  font-family: var(--font-serif);
  font-size: clamp(2.2rem, 6vw, 4rem);
  font-weight: 900; line-height: 1.1;
  color: var(--text-dk); margin-bottom: 20px;
}
.fct-inner h2 em { font-style: italic; color: var(--dark); }
.fct-inner p {
  font-size: 1rem; color: var(--text-md);
  line-height: 1.7; margin-bottom: 40px;
}
.fct-inner .section-eyebrow { text-align: center; }

/* =====================================================
   FOOTER
   ===================================================== */
.footer {
  background: var(--dark);
  padding: 60px 24px 40px;
  border-top: 1px solid rgba(201,168,76,.12);
}
.footer-inner {
  max-width: 1100px; margin: 0 auto;
  display: flex; flex-wrap: wrap;
  align-items: center; gap: 40px;
  justify-content: space-between;
}
.footer-brand {
  display: flex; align-items: center; gap: 14px;
}
.footer-brand strong {
  display: block; font-family: var(--font-serif);
  font-size: 1.1rem; color: var(--white);
}
.footer-brand p { font-size: .8rem; color: rgba(255,255,255,.45); }
.footer-links {
  display: flex; gap: 28px; flex-wrap: wrap;
}
.footer-links a {
  font-size: .8rem; letter-spacing: .1em; text-transform: uppercase;
  color: rgba(255,255,255,.5); transition: color .2s;
}
.footer-links a:hover { color: var(--gold); }
.footer-copy {
  width: 100%; font-size: .75rem;
  color: rgba(255,255,255,.3); text-align: center;
  margin-top: 20px;
}

/* =====================================================
   ===================================================== 
   APP — INTERACTIVO (interactivo.html)
   ===================================================== 
   ===================================================== */
.app-body {
  background: var(--dark);
  min-height: 100vh;
}
.app-splash {
  position: fixed; inset: 0; z-index: 9999;
  background: var(--dark);
  display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 16px;
  transition: opacity .6s ease, visibility .6s ease;
}
.app-splash.gone { opacity: 0; visibility: hidden; pointer-events: none; }
.app-wrapper {
  position: relative; min-height: 100vh;
  max-width: 430px; margin: 0 auto;
  background: var(--cream);
  box-shadow: 0 0 80px rgba(0,0,0,.4);
}
/* Show app in full width on small screens */
@media (max-width: 500px) {
  .app-wrapper { max-width: 100%; box-shadow: none; }
}

/* ---- SCREENS ---- */
.app-screen {
  display: none;
  min-height: 100vh;
  position: relative;
  flex-direction: column;
}
.app-screen.active { display: flex; }
.screen-scroll-inner {
  display: flex; flex-direction: column;
  overflow-y: auto; min-height: 100vh;
}

/* ---- SCREEN: HOME ---- */
#screen-home {
  background: var(--cream);
  flex-direction: column;
  justify-content: space-between;
}
.screen-home-inner {
  display: flex; flex-direction: column;
  justify-content: space-between; min-height: 100vh;
  padding: 24px;
}
.home-header {
  display: flex; align-items: center;
  justify-content: space-between; padding-top: 8px;
}
.home-logo {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--font-serif); font-size: 1rem;
  color: var(--text-dk); font-weight: 700;
}
.home-back {
  font-size: .72rem; letter-spacing: .1em; text-transform: uppercase;
  color: var(--gold); border: 1px solid var(--gold);
  padding: 6px 14px; border-radius: 40px;
}
.home-hero {
  flex: 1; display: flex; flex-direction: column;
  justify-content: center; padding: 40px 0;
}
.home-eyebrow {
  font-size: .75rem; letter-spacing: .2em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 16px;
}
.home-title {
  font-family: var(--font-serif);
  font-size: clamp(2.8rem, 12vw, 3.8rem);
  font-weight: 900; line-height: 1.05;
  color: var(--text-dk);
}
.home-title em { font-style: italic; }
.home-body {
  font-size: .95rem; color: var(--text-md);
  margin-top: 16px; line-height: 1.6;
}
.home-actions { display: flex; flex-direction: column; gap: 12px; padding-bottom: 32px; }

/* ---- SCREEN HEADER ---- */
.screen-header {
  display: flex; align-items: center;
  justify-content: space-between;
  padding: 20px 24px 16px;
}
.screen-header.dark { background: #0a0a0a; }
.screen-header.light { background: var(--cream); border-bottom: 1px solid rgba(0,0,0,.08); }
.screen-header h2 {
  font-family: var(--font-serif);
  font-size: 1.1rem; font-weight: 700;
}
.screen-header.dark h2 { color: var(--white); }
.screen-header.light h2 { color: var(--text-dk); }
.back-btn {
  font-size: .85rem; font-weight: 600;
  color: var(--white); padding: 7px 14px;
  background: rgba(0,0,0,.45); border-radius: 20px;
  border: 1px solid rgba(255,255,255,.2);
  letter-spacing: .02em;
}
.back-btn.dark {
  color: var(--text-dk); background: rgba(0,0,0,.1);
  border: 1px solid rgba(0,0,0,.15);
}

/* ---- SCREEN: CAMERA ---- */
#screen-camera {
  background: #000; min-height: 100vh;
  flex-direction: column;
}
.camera-area {
  flex: 1; display: flex; flex-direction: column;
  align-items: center; padding: 20px;
  gap: 24px;
}
.camera-frame {
  width: 100%; flex: 1; max-height: 560px;
  border: 2px solid var(--gold);
  border-radius: var(--r-lg);
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: 16px; cursor: pointer;
  position: relative; overflow: hidden;
  background: rgba(255,255,255,.03);
  min-height: 340px;
}
.camera-hint { font-size: .82rem; color: rgba(255,255,255,.4); text-align: center; }
.camera-video {
  width: 100%; height: 100%;
  object-fit: cover; border-radius: var(--r-lg);
}
.camera-icon { color: rgba(255,255,255,.3); }
.preview-img {
  position: absolute; inset: 0;
  object-fit: cover; width: 100%; height: 100%;
  border-radius: var(--r-lg);
}
.camera-options {
  width: 100%; display: flex; flex-direction: column;
  gap: 12px; padding-bottom: 8px;
}
.camera-controls {
  width: 100%; display: flex; flex-direction: column;
  align-items: center; gap: 16px; padding-bottom: 8px;
}
.shutter-btn {
  width: 72px; height: 72px; border-radius: 50%;
  border: 3px solid rgba(255,255,255,.6);
  display: flex; align-items: center; justify-content: center;
  transition: transform .15s;
}
.shutter-btn:active { transform: scale(.9); }
.shutter-inner {
  width: 54px; height: 54px; border-radius: 50%;
  background: var(--white);
}

/* ---- SCREEN: FORM ---- */
#screen-form { background: var(--cream); }
.form-preview-img-wrap {
  width: 100%; aspect-ratio: 4/3; overflow: hidden;
}
.form-preview-img {
  width: 100%; height: 100%; object-fit: cover;
}
.form-card {
  background: var(--cream);
  padding: 28px 24px 40px; flex: 1;
}
.form-title {
  font-family: var(--font-serif);
  font-size: 2rem; font-weight: 900;
  color: var(--text-dk); margin-bottom: 28px;
}
.form-group {
  margin-bottom: 24px;
}
.form-group label {
  display: block; font-size: .68rem; letter-spacing: .16em;
  text-transform: uppercase; color: var(--red-tag);
  font-weight: 600; margin-bottom: 8px;
}
.form-group input {
  width: 100%; border: none; border-bottom: 1.5px solid var(--gold);
  background: transparent; padding: 10px 0;
  font-family: var(--font-body); font-size: 1rem; color: var(--text-dk);
  outline: none; transition: border-color .2s;
}
.form-group input::placeholder { color: var(--text-lt); }
.form-group input:focus { border-color: var(--dark); }
.style-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 10px; margin-top: 4px;
}
.style-chip {
  display: flex; align-items: center; gap: 8px;
  border: 1.5px solid rgba(0,0,0,.15);
  border-radius: 8px; padding: 10px 12px;
  font-size: .8rem; cursor: pointer; color: var(--text-md);
  transition: border-color .2s, background .2s;
}
.style-chip.active {
  border-color: var(--dark);
  background: rgba(18,16,42,.06); color: var(--text-dk);
  font-weight: 500;
}
.chip-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
#btnGenerar { margin-top: 8px; margin-bottom: 12px; }

.ai-style-card {
  border: 1.5px solid rgba(18,16,42,.16);
  border-radius: var(--r-sm);
  background: rgba(255,255,255,.45);
  padding: 14px;
}
.ai-style-kicker {
  display: block;
  color: var(--red-tag);
  font-size: .62rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  margin-bottom: 6px;
}
.ai-style-card strong {
  display: block;
  color: var(--text-dk);
  font-family: var(--font-serif);
  font-size: 1.35rem;
  line-height: 1.1;
  margin-bottom: 6px;
}
.ai-style-card p {
  color: var(--text-md);
  font-size: .82rem;
  line-height: 1.45;
  margin-bottom: 12px;
}
.ai-predictions {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.ai-prediction-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--text-md);
  font-size: .76rem;
  border-top: 1px solid rgba(18,16,42,.08);
  padding-top: 6px;
}
.ai-prediction-row strong {
  font-family: var(--font-body);
  font-size: .76rem;
  margin: 0;
}

/* ---- SCREEN: LOADING ---- */
#screen-loading {
  background: #000;
  align-items: center; justify-content: center;
}
.loading-inner {
  display: flex; flex-direction: column;
  align-items: center; gap: 20px; text-align: center;
  padding: 40px;
}
.loading-spinner {
  width: 64px; height: 64px;
  border: 2px solid rgba(201,168,76,.2);
  border-top-color: var(--gold);
  border-radius: 50%;
  animation: spin 1.2s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.loading-title {
  font-family: var(--font-serif);
  font-size: 2rem; color: var(--gold); font-weight: 700;
}
.loading-dots { color: rgba(255,255,255,.4); font-size: 1.2rem; }
.loading-sub { font-size: .82rem; color: rgba(255,255,255,.4); letter-spacing: .08em; }

/* ---- SCREEN: RESULT ---- */
#screen-result { background: var(--cream); }
.result-img-wrap {
  width: 100%; padding: 16px;
}
.result-img {
  width: 100%; border-radius: var(--r-md);
  box-shadow: var(--shadow-lg);
  object-fit: cover; max-height: 480px;
}
.result-card { padding: 16px 24px 48px; }

/* ---- SCREEN: GALLERY ---- */
#screen-museo { background: var(--cream); }
.gallery-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 12px; padding: 16px 16px 100px;
}
.gallery-item {
  border-radius: var(--r-sm); overflow: hidden;
  cursor: pointer; 
  position: relative; transition: transform .2s;
  background: var(--cream-2);
  display: flex;
  flex-direction: column;
}
.gallery-item:nth-child(odd) { margin-top: 20px; }
.gallery-item:hover { transform: scale(.98); }
.gallery-item img {
  width: 100%; aspect-ratio: 4/3; object-fit: cover;
  display: block; flex-shrink: 0;
}
.gallery-item > div:first-child {
  width: 100%; aspect-ratio: 4/3; object-fit: cover;
  display: block; flex-shrink: 0;
}

/* Info visible debajo de la imagen */
.gallery-item-info {
  padding: 12px 11px 14px;
  background: #fff;
  flex: 1; display: flex; flex-direction: column;
}
.gallery-item-autor {
  font-size: .66rem;
  color: var(--red-tag, #c0392b);
  letter-spacing: .08em;
  text-transform: uppercase;
  margin-bottom: 4px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  font-weight: 500;
}
.gallery-item-title {
  font-family: var(--font-serif);
  font-size: .82rem; font-weight: 700;
  color: var(--text-dk);
  margin-bottom: 5px; line-height: 1.2;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.gallery-item-desc {
  font-size: .68rem; color: var(--text-md);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.gallery-item-overlay {
  position: absolute; bottom: 0; left: 0; right: 0;
  background: linear-gradient(to top, rgba(18,16,42,.85), transparent);
  padding: 20px 10px 10px;
  opacity: 0; transition: opacity .2s;
  display: none;
}
.gallery-item:hover .gallery-item-overlay { opacity: 1; }
.gallery-item-overlay span {
  font-size: .72rem; color: var(--white);
  font-weight: 500; display: block;
}
/* Gallery states */
.gallery-loading {
  grid-column: 1 / -1;
  text-align: center;
  padding: 60px 24px;
  color: var(--text-lt);
  font-size: .9rem;
  letter-spacing: .06em;
}
.gallery-placeholder {
  border-radius: var(--r-sm); overflow: hidden;
  aspect-ratio: 4/3; position: relative;
}

/* ---- SCREEN: DETAIL ---- */
#screen-detail { background: var(--cream); overflow-y: auto; }
.detail-img-wrap {
  width: 100%; padding: 0;
}
.detail-img-wrap img {
  width: 100%; object-fit: cover; max-height: 400px;
  box-shadow: 0 8px 40px rgba(0,0,0,.2);
}
.detail-card { padding: 24px 24px 140px; }
.detail-num {
  font-size: .68rem; letter-spacing: .18em; text-transform: uppercase;
  color: var(--red-tag); margin-bottom: 8px;
}
.detail-title {
  font-family: var(--font-serif);
  font-size: 2rem; font-weight: 900;
  color: var(--text-dk); margin-bottom: 6px;
}
.detail-autor { font-size: .9rem; color: var(--text-lt); margin-bottom: 20px; }
.detail-sep { border: none; border-top: 1px solid var(--cream-2); margin: 20px 0; }
.detail-desc { font-size: .95rem; color: var(--text-md); line-height: 1.7; margin-bottom: 32px; }
.similar-section h3 {
  font-family: var(--font-serif); font-size: 1.4rem;
  color: var(--text-dk); margin-bottom: 16px;
}
.similar-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.similar-item {
  display: block;
  width: 100%;
  aspect-ratio: 4/3;
  border-radius: var(--r-sm);
  overflow: hidden;
  background: var(--cream-2);
}
.similar-grid img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  cursor: pointer;
  transition: transform .2s;
}
.similar-item:hover img { transform: scale(.97); }

/* ---- BOTTOM NAV ---- */
.bottom-nav {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%);
  width: 100%; max-width: 430px;
  background: var(--white); border-top: 1px solid var(--cream-2);
  display: flex; justify-content: space-around;
  padding: 12px 0 20px;
  box-shadow: 0 -4px 20px rgba(0,0,0,.08);
  z-index: 50;
}
@media (max-width: 500px) {
  .bottom-nav { max-width: 100%; }
}
.bnav-btn {
  display: flex; align-items: center; justify-content: center;
  width: 48px; height: 40px; border-radius: 12px;
  color: var(--text-lt); transition: color .2s, background .2s;
}
.bnav-btn.active { color: var(--dark); background: rgba(18,16,42,.06); }
.bnav-btn:hover { color: var(--dark); }

/* =====================================================
   SISTEMA DE PESTAÑAS — PÁGINA PRINCIPAL
   ===================================================== */

#siteWrapper { min-height: 100vh; }

.site-tab { display: none; min-height: calc(100vh - 64px); animation: tabFadeIn .28s ease; }
.site-tab.active { display: block; }

@keyframes tabFadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: none; }
}

.tab-page-section { padding-top: 100px; }

/* Barra indicadora */
.tab-indicator-bar {
  position: fixed; top: 64px; left: 0; right: 0; z-index: 99;
  height: 2px; background: rgba(201,168,76,.12);
}
.tab-indicator {
  height: 100%; background: var(--gold);
  transition: width .35s cubic-bezier(.4,0,.2,1), left .35s cubic-bezier(.4,0,.2,1);
  position: absolute; top: 0;
}

/* nav-logo como botón */
.nav-logo { background: none; border: none; cursor: pointer; }

/* Botones del navbar como tabs */
.nav-links .nav-tab-btn {
  font-family: var(--font-body);
  font-size: .82rem; letter-spacing: .08em; text-transform: uppercase;
  color: rgba(255,255,255,.6);
  padding: 6px 2px; background: none; border: none; cursor: pointer;
  position: relative; transition: color .2s;
}
.nav-links .nav-tab-btn::after {
  content: ''; position: absolute; bottom: -4px; left: 0; right: 0;
  height: 2px; background: var(--gold);
  transform: scaleX(0); transition: transform .2s;
}
.nav-links .nav-tab-btn:hover { color: rgba(255,255,255,.9); }
.nav-links .nav-tab-btn.active { color: var(--gold); }
.nav-links .nav-tab-btn.active::after { transform: scaleX(1); }

/* Botones mobile */
.mob-tab-btn {
  background: none; border: none; cursor: pointer;
  color: rgba(255,255,255,.8); font-size: .95rem;
  letter-spacing: .06em; padding: 6px 0;
  text-align: left; font-family: var(--font-body); transition: color .2s;
}
.mob-tab-btn:hover, .mob-tab-btn.active { color: var(--gold); }

/* Botones footer */
.footer-tab-btn {
  background: none; border: none; cursor: pointer;
  font-family: var(--font-body);
  font-size: .8rem; letter-spacing: .1em; text-transform: uppercase;
  color: rgba(255,255,255,.5); transition: color .2s;
}
.footer-tab-btn:hover { color: var(--gold); }

/* Hero dentro de tab-inicio: padding normal del navbar */
#tab-inicio .hero { padding-top: 120px; }

/* btn-secondary con data-tab */
.btn-secondary[data-tab] { cursor: pointer; }

/* =====================================================
   GALERÍA INTERACTIVA — DESCRIPCIONES SIEMPRE VISIBLES
   ===================================================== */

.gallery-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  padding: 16px 14px 100px;
}

/* Reset stagger para que sea uniforme */
.gallery-item:nth-child(odd) { margin-top: 0; }

.gallery-item {
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  position: relative;
  transition: transform .2s, box-shadow .2s;
  background: var(--cream-2);
  display: flex;
  flex-direction: column;
}
.gallery-item:active { transform: scale(.97); }

/* Imagen en la parte superior — ahora gestionado por .gallery-thumb-wrap */

/* Info visible debajo de la imagen */
.gallery-item-info {
  padding: 9px 10px 11px;
  background: #fff;
  flex: 1;
}
.gallery-item-autor {
  font-size: .66rem;
  color: var(--red-tag, #c0392b);
  letter-spacing: .08em;
  text-transform: uppercase;
  margin-bottom: 3px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.gallery-item-title {
  font-family: var(--font-serif);
  font-size: .8rem; font-weight: 700;
  color: var(--text-dk);
  margin-bottom: 4px; line-height: 1.2;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.gallery-item-desc {
  font-size: .68rem; color: var(--text-md);
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Ocultar el overlay antiguo de hover */
.gallery-item-overlay { display: none; }


/* ══════════════════════════════════════════════════
   RESULTADO DE CLASIFICACIÓN — nuevos estilos
   ══════════════════════════════════════════════════ */

/* Contenedor de la imagen en resultado (muestra la original) */
.result-img-wrap {
  width: 100%;
  max-height: 340px;
  overflow: hidden;
  background: #111;
  display: flex;
  align-items: center;
  justify-content: center;
}
.result-img {
  width: 100%;
  max-height: 340px;
  object-fit: contain;
  display: block;
}

/* ── Badge principal del artista detectado ── */
.result-artist-badge {
  margin: 0 16px;
  margin-top: -1px;
}
.result-badge-inner {
  border-radius: 14px;
  padding: 18px 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  color: #fff;
  box-shadow: 0 4px 20px rgba(0,0,0,0.25);
}
.result-badge-emoji {
  font-size: 2.4rem;
  flex-shrink: 0;
  line-height: 1;
}
.result-badge-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.result-badge-label {
  font-size: .65rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  opacity: .75;
}
.result-badge-name {
  font-family: var(--font-serif, Georgia, serif);
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.1;
}
.result-badge-period {
  font-size: .7rem;
  opacity: .7;
  margin-top: 2px;
}
.result-badge-confidence {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  flex-shrink: 0;
}
.result-confidence-num {
  font-size: 1.6rem;
  font-weight: 800;
  line-height: 1;
}
.result-confidence-sub {
  font-size: .6rem;
  opacity: .7;
  text-transform: uppercase;
  letter-spacing: .07em;
}

/* ── Descripción del artista ── */
.result-desc-card {
  margin: 14px 16px 0;
  background: var(--bg-card, #fff);
  border-radius: 12px;
  padding: 14px 16px;
  border: 1px solid var(--border, #e8e0d0);
}
.result-desc-card p {
  font-size: .82rem;
  line-height: 1.6;
  color: var(--text-md, #555);
  margin: 0;
}

/* ── Barras de predicción ── */
.result-predictions-card {
  margin: 12px 16px 0;
  background: var(--bg-card, #fff);
  border-radius: 12px;
  padding: 14px 16px;
  border: 1px solid var(--border, #e8e0d0);
}
.result-pred-title {
  font-size: .7rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--text-lt, #999);
  margin: 0 0 12px;
  font-weight: 600;
}
.result-pred-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}
.result-pred-row:last-child { margin-bottom: 0; }
.result-pred-name {
  font-size: .75rem;
  color: var(--text-dk, #111);
  width: 155px;
  flex-shrink: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.result-pred-bar-wrap {
  flex: 1;
  height: 8px;
  background: var(--bg-lt, #f0ebe3);
  border-radius: 99px;
  overflow: hidden;
}
.result-pred-bar {
  height: 100%;
  border-radius: 99px;
  transition: width .6s ease;
  min-width: 3px;
}
.result-pred-pct {
  font-size: .72rem;
  font-weight: 700;
  color: var(--text-md, #555);
  width: 32px;
  text-align: right;
  flex-shrink: 0;
}
.result-pred-top .result-pred-name {
  font-weight: 700;
  color: var(--text-dk, #111);
}
.result-pred-top .result-pred-pct {
  color: var(--text-dk, #111);
}

/* Acción guardar */
.result-card {
  margin: 14px 16px 32px;
}

/* ── Badge en la galería (sobre la miniatura) ── */
.gallery-thumb-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;  /* recorta la imagen */
  flex-shrink: 0;
}
.gallery-thumb-wrap img,
.gallery-thumb-wrap > div:first-child {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .3s;
}
.gallery-item:hover .gallery-thumb-wrap img { transform: scale(1.04); }
/* El badge sale del overflow del thumb para no quedar cortado */
.gallery-thumb-wrap .gallery-style-badge {
  overflow: visible;
  z-index: 3;
}

/* .gallery-style-badge eliminado */

/* ── Texto artista en detalle ── */
.detail-artist-label {
  font-size: .8rem;
  color: var(--text-md, #666);
}
.detail-artist-label strong {
  color: var(--text-dk, #111);
}