/* ============================================================
   SOMBRA DENTAL — Estilos Personalizados
   ============================================================ */

:root {
  --gold:        #C9A84C;
  --gold-light:  #E2C27A;
  --gold-dark:   #9A7830;
  --gold-subtle: rgba(201, 168, 76, 0.1);
  --black:       #080808;
  --dark:        #111111;
  --dark-card:   #181818;
  --dark-border: #242424;
  --white:       #F8F6F0;
  --gray:        #666666;
  --gray-light:  #999999;
  --font-display: 'Unbounded', sans-serif;
  --font-body:    'Figtree', sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  background-color: var(--black);
  color: var(--white);
  font-family: var(--font-body);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: var(--dark); }
::-webkit-scrollbar-thumb { background: var(--gold-dark); border-radius: 3px; }

img { max-width: 100%; }

/* ── Utilidades ── */
.font-display { font-family: var(--font-display); }
.text-gold     { color: var(--gold); }
.text-gold-light { color: var(--gold-light); }

.gold-text {
  background: linear-gradient(135deg, var(--gold-dark) 0%, var(--gold) 55%, var(--gold-light) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.divider-gold {
  width: 56px; height: 3px;
  background: linear-gradient(90deg, var(--gold-dark), var(--gold-light));
  border-radius: 2px;
}

/* ── Botones ── */
.btn-primary {
  display: inline-flex; align-items: center; gap: .75rem;
  padding: 1rem 2.5rem;
  background: linear-gradient(135deg, var(--gold-dark) 0%, var(--gold) 100%);
  color: var(--black);
  font-family: var(--font-display); font-size: .7rem; font-weight: 700;
  letter-spacing: .1em; text-transform: uppercase; text-decoration: none;
  border-radius: 5px; border: none; cursor: pointer;
  box-shadow: 0 0 28px rgba(201,168,76,.45), 0 8px 30px rgba(0,0,0,.4);
  transition: all .3s ease;
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 45px rgba(201,168,76,.65), 0 12px 40px rgba(0,0,0,.5);
}

.btn-outline {
  display: inline-flex; align-items: center; gap: .75rem;
  padding: 1rem 2.5rem;
  background: transparent;
  color: var(--gold-light);
  font-family: var(--font-display); font-size: .7rem; font-weight: 600;
  letter-spacing: .1em; text-transform: uppercase; text-decoration: none;
  border: 1px solid rgba(201,168,76,.45); border-radius: 5px; cursor: pointer;
  transition: all .3s ease;
}
.btn-outline:hover {
  background: rgba(201,168,76,.08);
  border-color: var(--gold);
  color: var(--gold);
  transform: translateY(-2px);
}

/* ── Section común ── */
.section-tag {
  display: inline-block;
  font-family: var(--font-body); font-size: .68rem; font-weight: 600;
  letter-spacing: .22em; text-transform: uppercase;
  color: var(--gold); margin-bottom: .85rem;
}

.section-title {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(1.7rem, 3.5vw, 2.8rem); line-height: 1.15;
  color: var(--white); margin-bottom: .9rem;
}

.section-subtitle {
  font-family: var(--font-body); font-size: 1rem;
  color: var(--gray-light); line-height: 1.75; max-width: 580px;
}

/* ============================================================
   NAVBAR
   ============================================================ */
#navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  padding: 1.5rem 2rem;
  transition: all .35s ease;
}
#navbar.scrolled {
  background: rgba(8,8,8,.96);
  backdrop-filter: blur(24px);
  padding: .85rem 2rem;
  border-bottom: 1px solid rgba(201,168,76,.15);
  box-shadow: 0 4px 40px rgba(0,0,0,.5);
}

.nav-logo-text {
  font-family: var(--font-display); font-size: 1.1rem; font-weight: 900;
  letter-spacing: .08em; color: var(--white);
}
.nav-logo-text span { color: var(--gold); }

.nav-link {
  position: relative;
  font-family: var(--font-body); font-size: .8rem; font-weight: 500;
  color: rgba(248,246,240,.75); text-decoration: none;
  letter-spacing: .05em; transition: color .3s;
}
.nav-link::after {
  content: ''; position: absolute; bottom: -4px; left: 0;
  width: 0; height: 1px; background: var(--gold); transition: width .3s;
}
.nav-link:hover { color: var(--gold); }
.nav-link:hover::after { width: 100%; }

.nav-cta {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .55rem 1.25rem;
  background: linear-gradient(135deg, var(--gold-dark), var(--gold));
  color: var(--black);
  font-family: var(--font-display); font-size: .65rem; font-weight: 700;
  letter-spacing: .1em; text-transform: uppercase; text-decoration: none;
  border-radius: 4px;
  box-shadow: 0 0 20px rgba(201,168,76,.35);
  transition: all .3s;
}
.nav-cta:hover { transform: translateY(-1px); box-shadow: 0 0 30px rgba(201,168,76,.55); }

.hamburger {
  display: none; flex-direction: column; gap: 5px;
  background: none; border: none; cursor: pointer; padding: 4px;
}
.hamburger span {
  display: block; width: 24px; height: 2px;
  background: var(--white); border-radius: 2px; transition: all .3s;
}
.hamburger.open span:nth-child(1) { transform: rotate(45deg) translate(5px,5px); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: rotate(-45deg) translate(5px,-5px); }

@media (max-width: 1024px) {
  .nav-links { display: none; }
  .nav-cta-desk { display: none; }
  .hamburger { display: flex; }
}

/* ── Mobile menu ── */
#mobile-menu {
  display: none; position: fixed; inset: 0;
  background: rgba(8,8,8,.98); z-index: 999;
  flex-direction: column; align-items: center; justify-content: center; gap: 2.25rem;
}
#mobile-menu.open { display: flex; }

.mobile-nav-link {
  font-family: var(--font-display); font-size: 1.5rem; font-weight: 700;
  color: var(--white); text-decoration: none;
  text-transform: uppercase; letter-spacing: .05em; transition: color .3s;
}
.mobile-nav-link:hover { color: var(--gold); }

/* ============================================================
   HERO
   ============================================================ */
#hero {
  position: relative; height: 100vh; min-height: 680px;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
}

#hero-bg {
  position: absolute; inset: 0;
  background-image: url('fotos/consultorio-fachada.png');
  background-size: cover; background-position: center;
  transform: scale(1.06); transition: transform 9s ease;
}
#hero-bg.loaded { transform: scale(1); }

#hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(
    165deg,
    rgba(8,8,8,.45) 0%,
    rgba(8,8,8,.68) 40%,
    rgba(8,8,8,.92) 80%,
    rgba(8,8,8,.99) 100%
  );
}
#hero-overlay::after {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse at 72% 28%, rgba(201,168,76,.07) 0%, transparent 55%);
}

.hero-content { position: relative; z-index: 1; }

.hero-badge {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .4rem 1.1rem;
  border: 1px solid rgba(201,168,76,.35); border-radius: 100px;
  font-family: var(--font-body); font-size: .7rem; font-weight: 600;
  color: var(--gold-light); letter-spacing: .18em; text-transform: uppercase;
  backdrop-filter: blur(12px); background: rgba(201,168,76,.05);
  margin-bottom: 1.75rem;
}
.hero-badge-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 8px var(--gold);
  animation: dotPulse 2s ease-in-out infinite;
}
@keyframes dotPulse {
  0%,100% { opacity: 1; } 50% { opacity: .4; }
}

.hero-title {
  font-family: var(--font-display); font-weight: 900;
  font-size: clamp(3.8rem, 11vw, 9.5rem);
  line-height: .92; letter-spacing: -.02em;
  color: var(--white); margin-bottom: 1.5rem;
}
.hero-title .gold-line {
  display: block;
  background: linear-gradient(135deg, var(--gold-dark) 0%, var(--gold) 50%, var(--gold-light) 100%);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}

.hero-sub {
  font-family: var(--font-body); font-size: clamp(.95rem, 2vw, 1.2rem);
  font-weight: 300; color: rgba(248,246,240,.72);
  max-width: 480px; line-height: 1.75; margin-bottom: 2.5rem;
}

.hero-scroll {
  position: absolute; bottom: 2.5rem; left: 50%; transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: .5rem;
  color: rgba(248,246,240,.3); font-size: .65rem;
  letter-spacing: .18em; text-transform: uppercase; font-family: var(--font-body);
  animation: scrollFloat 2.2s ease-in-out infinite;
}
.hero-scroll svg { color: rgba(201,168,76,.5); }
@keyframes scrollFloat {
  0%,100% { transform: translateX(-50%) translateY(0); }
  50%      { transform: translateX(-50%) translateY(7px); }
}

/* ============================================================
   STATS
   ============================================================ */
#stats {
  background: var(--dark-card);
  border-top: 1px solid var(--dark-border);
  border-bottom: 1px solid var(--dark-border);
}

.stat-item { text-align: center; padding: 2.2rem 1.5rem; }
.stat-number {
  font-family: var(--font-display); font-weight: 900;
  font-size: clamp(2rem, 4vw, 2.8rem); line-height: 1;
  background: linear-gradient(135deg, var(--gold-dark), var(--gold-light));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
  margin-bottom: .4rem;
}
.stat-label {
  font-family: var(--font-body); font-size: .72rem; font-weight: 500;
  color: var(--gray-light); letter-spacing: .1em; text-transform: uppercase;
}
.stat-divider {
  width: 1px; background: var(--dark-border); align-self: stretch; margin: 1.5rem 0;
}

/* ============================================================
   SERVICIOS
   ============================================================ */
#servicios {
  background: var(--dark); position: relative; overflow: hidden;
}
#servicios::before {
  content: ''; position: absolute; top: -250px; right: -250px;
  width: 700px; height: 700px; border-radius: 50%;
  background: radial-gradient(circle, rgba(201,168,76,.04) 0%, transparent 70%);
  pointer-events: none;
}

.service-card {
  background: var(--dark-card);
  border: 1px solid var(--dark-border);
  border-radius: 14px; padding: 1.75rem;
  transition: all .35s ease; position: relative; overflow: hidden;
  cursor: default;
}
.service-card::before {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(201,168,76,.05) 0%, transparent 60%);
  opacity: 0; transition: opacity .35s;
}
.service-card:hover {
  border-color: rgba(201,168,76,.3);
  transform: translateY(-5px);
  box-shadow: 0 24px 60px rgba(0,0,0,.5), 0 0 35px rgba(201,168,76,.07);
}
.service-card:hover::before { opacity: 1; }

.service-icon {
  width: 50px; height: 50px;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, rgba(201,168,76,.12), rgba(201,168,76,.04));
  border: 1px solid rgba(201,168,76,.18); border-radius: 12px;
  color: var(--gold); margin-bottom: 1.2rem;
  transition: all .35s;
}
.service-card:hover .service-icon {
  background: linear-gradient(135deg, rgba(201,168,76,.25), rgba(201,168,76,.1));
  border-color: rgba(201,168,76,.5);
  box-shadow: 0 0 22px rgba(201,168,76,.2);
}

.service-name {
  font-family: var(--font-display); font-size: .78rem; font-weight: 700;
  color: var(--white); margin-bottom: .5rem; letter-spacing: -.01em;
}
.service-desc {
  font-family: var(--font-body); font-size: .82rem;
  color: var(--gray-light); line-height: 1.6;
}

/* ============================================================
   NOSOTROS
   ============================================================ */
#nosotros {
  background: var(--black); position: relative; overflow: hidden;
}
#nosotros::after {
  content: ''; position: absolute; bottom: -150px; left: -150px;
  width: 600px; height: 600px; border-radius: 50%;
  background: radial-gradient(circle, rgba(201,168,76,.03) 0%, transparent 70%);
  pointer-events: none;
}

.about-img-wrap {
  position: relative; border-radius: 18px; overflow: hidden;
  box-shadow: 0 30px 80px rgba(0,0,0,.6);
}
.about-img-wrap img {
  width: 100%; height: 520px;
  object-fit: cover; object-position: top center;
  display: block;
}
.about-img-caption {
  position: absolute; bottom: 0; left: 0; right: 0;
  background: linear-gradient(to top, rgba(8,8,8,.98) 0%, rgba(8,8,8,.6) 60%, transparent 100%);
  padding: 2.5rem 1.5rem 1.5rem;
}
.about-img-caption .tag {
  font-family: var(--font-body); font-size: .65rem;
  letter-spacing: .2em; text-transform: uppercase; color: var(--gold); margin-bottom: .2rem;
}
.about-img-caption .name {
  font-family: var(--font-display); font-size: 1rem; font-weight: 700; color: var(--white);
}

.about-team-img {
  border-radius: 14px; overflow: hidden;
  box-shadow: 0 20px 50px rgba(0,0,0,.5);
  border: 1px solid var(--dark-border);
}
.about-team-img img {
  width: 100%; height: 220px;
  object-fit: cover; display: block;
  transition: transform .5s;
}
.about-team-img:hover img { transform: scale(1.04); }

.feature-item {
  display: flex; gap: 1rem; align-items: flex-start;
}
.feature-icon {
  width: 40px; height: 40px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  background: var(--gold-subtle);
  border: 1px solid rgba(201,168,76,.2); border-radius: 10px;
  color: var(--gold);
}
.feature-text-title {
  font-family: var(--font-display); font-size: .78rem; font-weight: 700;
  color: var(--white); margin-bottom: .25rem;
}
.feature-text-sub {
  font-family: var(--font-body); font-size: .82rem; color: var(--gray-light); line-height: 1.5;
}

/* ============================================================
   TESTIMONIOS
   ============================================================ */
#testimonios { background: var(--dark); }

.testimonial-card {
  background: var(--dark-card);
  border: 1px solid var(--dark-border);
  border-radius: 18px; padding: 2rem;
  position: relative; transition: all .3s ease;
}
.testimonial-card:hover {
  border-color: rgba(201,168,76,.22);
  transform: translateY(-4px);
  box-shadow: 0 20px 50px rgba(0,0,0,.45);
}
.testimonial-quote-mark {
  position: absolute; top: 1.25rem; right: 1.5rem;
  font-family: serif; font-size: 6rem; line-height: 1;
  color: rgba(201,168,76,.07); font-weight: 900; pointer-events: none;
  user-select: none;
}
.stars { display: flex; gap: 3px; margin-bottom: 1rem; }
.star { color: var(--gold); font-size: 1rem; }
.testimonial-text {
  font-family: var(--font-body); font-size: .87rem;
  line-height: 1.78; color: rgba(248,246,240,.78); margin-bottom: 1.5rem;
}
.testimonial-author {
  font-family: var(--font-display); font-size: .75rem; font-weight: 700; color: var(--white);
}
.testimonial-service {
  font-family: var(--font-body); font-size: .72rem; color: var(--gold); margin-top: .2rem;
}

/* ============================================================
   GALERÍA
   ============================================================ */
#galeria { background: var(--black); }

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}
@media (max-width: 1024px) { .gallery-grid { grid-template-columns: repeat(3,1fr); } }
@media (max-width: 640px)  { .gallery-grid { grid-template-columns: repeat(2,1fr); } }

.gallery-item {
  position: relative; overflow: hidden;
  border-radius: 10px; aspect-ratio: 1; cursor: pointer;
  background: var(--dark-card);
}
.gallery-item img {
  width: 100%; height: 100%;
  object-fit: cover; display: block;
  transition: transform .5s ease;
}
.gallery-item:hover img { transform: scale(1.08); }
.gallery-overlay {
  position: absolute; inset: 0;
  background: rgba(8,8,8,.55);
  opacity: 0; transition: opacity .3s;
  display: flex; align-items: center; justify-content: center;
}
.gallery-item:hover .gallery-overlay { opacity: 1; }
.gallery-zoom-icon {
  width: 44px; height: 44px; border-radius: 50%;
  background: rgba(201,168,76,.9);
  display: flex; align-items: center; justify-content: center;
  color: var(--black);
  transform: scale(0); transition: transform .3s ease;
}
.gallery-item:hover .gallery-zoom-icon { transform: scale(1); }

/* Lightbox */
#lightbox {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.97); z-index: 9000;
  display: none; align-items: center; justify-content: center;
}
#lightbox.active { display: flex; }
#lightbox-img {
  max-width: 88vw; max-height: 85vh;
  object-fit: contain; border-radius: 10px;
  box-shadow: 0 0 100px rgba(0,0,0,.8);
}
.lb-btn {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 50px; height: 50px; border-radius: 50%;
  background: rgba(201,168,76,.1); border: 1px solid rgba(201,168,76,.3);
  color: var(--gold); display: flex; align-items: center; justify-content: center;
  cursor: pointer; transition: all .3s; z-index: 1;
}
.lb-btn:hover { background: rgba(201,168,76,.25); border-color: var(--gold); }
#lb-prev { left: 1.5rem; }
#lb-next { right: 1.5rem; }
#lb-close {
  position: absolute; top: 1.5rem; right: 1.5rem;
  width: 46px; height: 46px; border-radius: 50%;
  background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.12);
  color: var(--white); display: flex; align-items: center; justify-content: center;
  cursor: pointer; transition: all .3s; z-index: 1;
}
#lb-close:hover { background: rgba(255,255,255,.12); }
#lb-counter {
  position: absolute; bottom: 1.5rem; left: 50%; transform: translateX(-50%);
  font-family: var(--font-body); font-size: .75rem;
  color: rgba(255,255,255,.35); letter-spacing: .12em;
}

/* ============================================================
   CTA SECTION
   ============================================================ */
#cta {
  position: relative; overflow: hidden;
  background: var(--dark-card);
  border-top: 1px solid var(--dark-border);
  border-bottom: 1px solid var(--dark-border);
}
#cta::before {
  content: ''; position: absolute; inset: 0;
  background:
    radial-gradient(ellipse at 15% 50%, rgba(201,168,76,.07) 0%, transparent 55%),
    radial-gradient(ellipse at 85% 50%, rgba(201,168,76,.04) 0%, transparent 55%);
  pointer-events: none;
}
.cta-title {
  font-family: var(--font-display); font-weight: 900;
  font-size: clamp(1.8rem, 4vw, 3.2rem); line-height: 1.15;
  color: var(--white);
}

/* ============================================================
   CONTACTO
   ============================================================ */
#contacto { background: var(--dark); }

.form-label {
  display: block;
  font-family: var(--font-body); font-size: .7rem; font-weight: 600;
  letter-spacing: .1em; text-transform: uppercase;
  color: var(--gray-light); margin-bottom: .5rem;
}
.form-input, .form-select, .form-textarea {
  width: 100%;
  background: var(--dark-card); border: 1px solid var(--dark-border);
  border-radius: 9px; padding: .875rem 1rem;
  color: var(--white); font-family: var(--font-body); font-size: .9rem;
  outline: none; transition: border-color .3s, box-shadow .3s;
  appearance: none;
}
.form-input:focus, .form-select:focus, .form-textarea:focus {
  border-color: rgba(201,168,76,.5);
  box-shadow: 0 0 0 3px rgba(201,168,76,.08);
}
.form-input::placeholder, .form-textarea::placeholder { color: var(--gray); opacity: .6; }
.form-select { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23666' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 1rem center; padding-right: 2.5rem; }
.form-select option { background: var(--dark-card); color: var(--white); }
.form-textarea { min-height: 120px; resize: vertical; }

/* ============================================================
   FOOTER
   ============================================================ */
#footer { background: var(--black); border-top: 1px solid var(--dark-border); }

.footer-heading {
  font-family: var(--font-display); font-size: .7rem; font-weight: 700;
  letter-spacing: .18em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 1.25rem;
}
.footer-link {
  color: var(--gray-light); text-decoration: none;
  font-family: var(--font-body); font-size: .85rem;
  transition: color .3s; display: inline-block;
}
.footer-link:hover { color: var(--gold); }
.footer-contact-item {
  display: flex; align-items: flex-start; gap: .75rem;
  margin-bottom: .85rem; color: var(--gray-light);
  font-family: var(--font-body); font-size: .85rem;
}
.footer-contact-item svg { color: var(--gold); flex-shrink: 0; margin-top: 1px; }

.hours-row {
  display: flex; justify-content: space-between;
  padding: .45rem 0; border-bottom: 1px solid rgba(36,36,36,.8);
}
.hours-day  { font-family: var(--font-body); font-size: .8rem; color: var(--gray-light); }
.hours-time { font-family: var(--font-body); font-size: .8rem; color: var(--white); font-weight: 500; }

.map-wrap {
  border-radius: 12px; overflow: hidden;
  border: 1px solid var(--dark-border);
  box-shadow: 0 10px 40px rgba(0,0,0,.4);
}

.social-link {
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--dark-card); border: 1px solid var(--dark-border);
  display: flex; align-items: center; justify-content: center;
  color: var(--gray-light); text-decoration: none;
  transition: all .3s;
}
.social-link:hover {
  background: var(--gold-subtle); border-color: rgba(201,168,76,.4); color: var(--gold);
}

/* ============================================================
   CHAT WIDGET — Ayuda Activa
   ============================================================ */
#chat-widget {
  position: fixed; bottom: 2rem; right: 2rem;
  z-index: 8000;
  display: flex; flex-direction: column; align-items: flex-end; gap: .65rem;
}

#chat-tooltip {
  position: relative;
  background: var(--dark-card);
  border: 1px solid rgba(201,168,76,.3); border-radius: 12px;
  padding: .55rem 1rem;
  font-family: var(--font-body); font-size: .78rem; color: var(--white);
  white-space: nowrap;
  box-shadow: 0 8px 30px rgba(0,0,0,.45);
  animation: tooltipFloat 3s ease-in-out infinite;
}
#chat-tooltip::after {
  content: ''; position: absolute;
  bottom: -6px; right: 26px;
  width: 11px; height: 11px;
  background: var(--dark-card);
  border-right: 1px solid rgba(201,168,76,.3);
  border-bottom: 1px solid rgba(201,168,76,.3);
  transform: rotate(45deg);
}
@keyframes tooltipFloat {
  0%,100% { transform: translateY(0); } 50% { transform: translateY(-4px); }
}

#chat-btn {
  width: 62px; height: 62px; border-radius: 50%;
  background: linear-gradient(135deg, var(--gold-dark), var(--gold));
  border: none; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  color: var(--black);
  box-shadow: 0 8px 30px rgba(201,168,76,.45);
  transition: transform .3s ease;
  animation: chatPulse 2.8s ease-in-out infinite;
}
@keyframes chatPulse {
  0%,100% { box-shadow: 0 8px 30px rgba(201,168,76,.45), 0 0 0 0 rgba(201,168,76,.4); }
  60%      { box-shadow: 0 8px 30px rgba(201,168,76,.45), 0 0 0 18px rgba(201,168,76,0); }
}
#chat-btn:hover { transform: scale(1.1); animation-play-state: paused; }

#chat-panel {
  position: absolute; bottom: 74px; right: 0;
  width: 360px; height: 480px;
  background: var(--dark-card);
  border: 1px solid rgba(201,168,76,.2); border-radius: 20px;
  display: none; flex-direction: column; overflow: hidden;
  box-shadow: 0 24px 70px rgba(0,0,0,.7), 0 0 50px rgba(201,168,76,.06);
}
#chat-panel.open { display: flex; }

#chat-header {
  background: linear-gradient(135deg, #150f00, #111111);
  border-bottom: 1px solid rgba(201,168,76,.2);
  padding: 1rem 1.25rem;
  display: flex; align-items: center; justify-content: space-between;
}
.chat-title {
  font-family: var(--font-display); font-size: .82rem; font-weight: 700;
  color: var(--gold-light); letter-spacing: .05em;
}
.chat-sub {
  font-family: var(--font-body); font-size: .68rem; color: var(--gray); margin-top: .1rem;
}
.chat-header-dot {
  width: 7px; height: 7px; border-radius: 50%; background: #22c55e;
  box-shadow: 0 0 6px #22c55e;
}
.chat-close {
  width: 28px; height: 28px; border-radius: 50%;
  background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.1);
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  color: var(--gray); transition: all .2s;
}
.chat-close:hover { background: rgba(255,255,255,.1); color: var(--white); }

#chat-messages {
  flex: 1; overflow-y: auto; padding: 1rem;
  display: flex; flex-direction: column; gap: .75rem;
  scrollbar-width: thin; scrollbar-color: var(--dark-border) transparent;
}
#chat-messages::-webkit-scrollbar { width: 4px; }
#chat-messages::-webkit-scrollbar-thumb { background: var(--dark-border); border-radius: 2px; }

.msg {
  max-width: 85%; padding: .65rem .9rem;
  border-radius: 14px; font-family: var(--font-body); font-size: .82rem; line-height: 1.55;
}
.msg a { color: var(--gold-light); text-decoration: underline; }
.msg a:hover { color: var(--gold); }
.msg-bot {
  background: rgba(201,168,76,.08); border: 1px solid rgba(201,168,76,.15);
  color: rgba(248,246,240,.88); align-self: flex-start; border-bottom-left-radius: 4px;
}
.msg-user {
  background: linear-gradient(135deg, var(--gold-dark), var(--gold));
  color: var(--black); align-self: flex-end; font-weight: 500; border-bottom-right-radius: 4px;
}
.msg-typing {
  display: flex; gap: 4px; align-items: center;
  padding: .75rem 1rem;
  background: rgba(201,168,76,.08); border: 1px solid rgba(201,168,76,.15);
  border-radius: 14px; border-bottom-left-radius: 4px; align-self: flex-start;
}
.typing-dot {
  width: 6px; height: 6px; border-radius: 50%; background: var(--gold);
  animation: typingDot 1.3s ease-in-out infinite;
}
.typing-dot:nth-child(2) { animation-delay: .2s; }
.typing-dot:nth-child(3) { animation-delay: .4s; }
@keyframes typingDot {
  0%,80%,100% { transform: scale(.6); opacity: .4; }
  40%          { transform: scale(1); opacity: 1; }
}

#chat-input-area {
  border-top: 1px solid var(--dark-border);
  padding: .75rem; display: flex; gap: .5rem; align-items: flex-end;
}
#chat-input {
  flex: 1;
  background: rgba(255,255,255,.04); border: 1px solid var(--dark-border);
  border-radius: 10px; padding: .65rem .875rem;
  color: var(--white); font-family: var(--font-body); font-size: .82rem;
  outline: none; resize: none; min-height: 38px; max-height: 100px;
  line-height: 1.45; transition: border-color .2s;
}
#chat-input:focus { border-color: rgba(201,168,76,.4); }
#chat-send {
  width: 38px; height: 38px; flex-shrink: 0;
  background: linear-gradient(135deg, var(--gold-dark), var(--gold));
  border: none; border-radius: 10px; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  color: var(--black); transition: all .2s;
}
#chat-send:hover { transform: scale(1.07); box-shadow: 0 4px 16px rgba(201,168,76,.35); }
#chat-send:disabled { opacity: .5; cursor: not-allowed; transform: none; }

/* ============================================================
   SCROLL REVEAL
   ============================================================ */
.reveal, .reveal-left, .reveal-right {
  transition: opacity .75s ease, transform .75s ease;
}
.reveal       { opacity: 0; transform: translateY(34px); }
.reveal-left  { opacity: 0; transform: translateX(-42px); }
.reveal-right { opacity: 0; transform: translateX(42px); }
.reveal.visible, .reveal-left.visible, .reveal-right.visible {
  opacity: 1; transform: translate(0);
}
.d1 { transition-delay: .1s; }
.d2 { transition-delay: .2s; }
.d3 { transition-delay: .3s; }
.d4 { transition-delay: .4s; }
.d5 { transition-delay: .5s; }
.d6 { transition-delay: .6s; }
.d7 { transition-delay: .7s; }
.d8 { transition-delay: .8s; }

/* ============================================================
   RESPONSIVE EXTRAS
   ============================================================ */
@media (max-width: 768px) {
  #chat-panel { width: calc(100vw - 3rem); right: -1rem; }
  .about-img-wrap img { height: 380px; }
  .lb-btn { display: none; }
  #lb-close { top: 1rem; right: 1rem; }
}
@media (max-width: 480px) {
  .hero-title { font-size: 3.2rem; }
  .btn-primary, .btn-outline { padding: .875rem 1.75rem; }
}
