:root {
  --cream: #EFE8DE;
  --stone: #8B8477;
  --accent: #8B8477;
  --dark: #2C2A26;
  --darker: #1E1D1A;
  --light: #F7F3ED;
  --accent-light: rgba(139, 132, 119, 0.15);
  --accent-glow: rgba(139, 132, 119, 0.3);
  --gold: #B8A88A;
  --gold-light: rgba(184, 168, 138, 0.2);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 95px;
}

body {
  font-family: 'Figtree', sans-serif;
  background-color: var(--cream);
  color: var(--dark);
  line-height: 1.7;
  overflow-x: hidden;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ===== HEADER ===== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background: var(--cream);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--accent-light);
  transition: background 0.3s, box-shadow 0.3s;
}

.header.scrolled {
  background: var(--cream);
  box-shadow: 0 4px 30px rgba(44, 42, 38, 0.08);
}

.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 87px;
}

.logo-link {
  display: flex;
  align-items: center;
}

.header-logo {
  height: 82px;
  width: auto;
  transition: transform 0.3s;
}

.header-logo:hover {
  transform: scale(1.05);
}

.main-nav {
  display: flex;
  gap: 32px;
}

.nav-link {
  font-family: 'Figtree', sans-serif;
  font-weight: 500;
  font-size: 0.9rem;
  color: var(--dark);
  text-decoration: none;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  position: relative;
  padding: 4px 0;
  transition: color 0.3s;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--accent);
  transition: width 0.3s;
}

.nav-link:hover {
  color: var(--stone);
}

.nav-link:hover::after {
  width: 100%;
}

.header-cta {
  font-family: 'Figtree', sans-serif;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--cream);
  background: var(--stone);
  padding: 10px 24px;
  text-decoration: none;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border: 1px solid var(--stone);
  transition: all 0.3s;
}

.header-cta:hover {
  background: var(--dark);
  border-color: var(--dark);
  transform: translateY(-1px);
}

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

.mobile-toggle span {
  width: 24px;
  height: 2px;
  background: var(--dark);
  transition: all 0.3s;
}

.mobile-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.mobile-toggle.active span:nth-child(2) {
  opacity: 0;
}

.mobile-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

.mobile-nav {
  display: none;
  position: fixed;
  top: 77px;
  left: 0;
  width: 100%;
  background: var(--cream);
  backdrop-filter: blur(12px);
  padding: 24px;
  flex-direction: column;
  gap: 16px;
  z-index: 999;
  border-bottom: 1px solid var(--accent-light);
}

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

.mobile-nav-link {
  font-family: 'Figtree', sans-serif;
  font-weight: 500;
  font-size: 1rem;
  color: var(--dark);
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 8px 0;
  border-bottom: 1px solid var(--accent-light);
}

.mobile-nav-cta {
  font-family: 'Figtree', sans-serif;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--cream);
  background: var(--stone);
  padding: 14px 24px;
  text-decoration: none;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 8px;
}

/* ===== HERO ===== */
.hero-section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  background: linear-gradient(165deg, rgba(30,29,26,0.82) 0%, rgba(44,42,38,0.78) 40%, rgba(58,55,48,0.75) 100%), url('fotos/sonrisa.jpg') center/cover no-repeat;
  overflow: hidden;
  padding: 120px 24px 80px;
}

.hero-deco {
  position: absolute;
  left: 0;
  width: 100%;
  height: 60px;
  z-index: 1;
}

.hero-deco-top {
  top: 0;
  background: linear-gradient(180deg, var(--cream) 0%, transparent 100%);
  opacity: 0.05;
}

.hero-deco-bottom {
  bottom: 0;
  background: linear-gradient(0deg, var(--cream) 0%, transparent 100%);
  opacity: 0.05;
}

.hero-content {
  text-align: center;
  position: relative;
  z-index: 2;
  max-width: 900px;
}

.hero-badge {
  display: inline-block;
  font-family: 'Figtree', sans-serif;
  font-weight: 500;
  font-size: 0.85rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  border: 1px solid var(--gold-light);
  padding: 8px 24px;
  margin-bottom: 40px;
}

.hero-title {
  font-family: 'Unbounded', sans-serif;
  font-weight: 700;
  font-size: clamp(3rem, 7vw, 6rem);
  color: var(--cream);
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin-bottom: 32px;
}

.hero-letter {
  display: inline-block;
  opacity: 0;
  transform: translateY(30px);
  animation: letterReveal 0.5s forwards;
}

.hero-space {
  width: 0.3em;
}

.hero-break {
  display: block;
  height: 0;
}

.hero-letter.hero-accent {
  color: var(--gold);
}

@keyframes letterReveal {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-subtitle {
  font-family: 'Figtree', sans-serif;
  font-size: 1.15rem;
  color: rgba(239, 232, 222, 0.7);
  max-width: 600px;
  margin: 0 auto 48px;
  line-height: 1.8;
}

.hero-cta-group {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

.hero-line-art {
  position: absolute;
  right: -40px;
  bottom: -40px;
  width: 300px;
  height: 300px;
  opacity: 0.15;
  z-index: 1;
}

.hero-geo {
  width: 100%;
  height: 100%;
  animation: geoSpin 40s linear infinite;
}

@keyframes geoSpin {
  to { transform: rotate(360deg); }
}

/* ===== BUTTONS ===== */
.btn-primary {
  display: inline-block;
  font-family: 'Figtree', sans-serif;
  font-weight: 600;
  font-size: 0.9rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--cream);
  background: var(--stone);
  padding: 16px 36px;
  text-decoration: none;
  border: 2px solid var(--stone);
  transition: all 0.3s;
  cursor: pointer;
}

.btn-primary:hover {
  background: var(--dark);
  border-color: var(--dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(44, 42, 38, 0.3);
}

.btn-secondary {
  display: inline-block;
  font-family: 'Figtree', sans-serif;
  font-weight: 600;
  font-size: 0.9rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--cream);
  background: transparent;
  padding: 16px 36px;
  text-decoration: none;
  border: 1px solid rgba(239, 232, 222, 0.3);
  transition: all 0.3s;
}

.btn-secondary:hover {
  border-color: var(--cream);
  background: rgba(239, 232, 222, 0.08);
  transform: translateY(-2px);
}

.btn-lg {
  padding: 18px 48px;
  font-size: 0.95rem;
}

.btn-full {
  width: 100%;
  text-align: center;
}

/* ===== DECO DIVIDERS ===== */
.deco-divider {
  padding: 20px 0;
  overflow: hidden;
}

.deco-svg {
  width: 100%;
  height: 40px;
}

/* ===== SECTIONS COMMON ===== */
.section-header {
  text-align: center;
  margin-bottom: 64px;
}

.section-tag {
  display: inline-block;
  font-family: 'Figtree', sans-serif;
  font-weight: 600;
  font-size: 0.8rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--stone);
  margin-bottom: 16px;
}

.section-title {
  font-family: 'Unbounded', sans-serif;
  font-weight: 700;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  color: var(--dark);
  margin-bottom: 20px;
  letter-spacing: -0.01em;
}

.section-desc {
  font-family: 'Figtree', sans-serif;
  font-size: 1.05rem;
  color: var(--stone);
  max-width: 640px;
  margin: 0 auto;
  line-height: 1.8;
}

/* ===== SERVICES ===== */
.section-services {
  padding: 80px 0;
  background: var(--cream);
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.service-card {
  background: var(--light);
  border: 1px solid rgba(139, 132, 119, 0.12);
  padding: 40px 28px;
  text-align: center;
  transition: all 0.4s;
  position: relative;
  overflow: hidden;
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  opacity: 0;
  transition: opacity 0.4s;
}

.service-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 40px rgba(44, 42, 38, 0.1);
  border-color: var(--accent-light);
}

.service-card:hover::before {
  opacity: 1;
}

.service-icon {
  width: 60px;
  height: 60px;
  margin: 0 auto 20px;
}

.service-icon svg {
  width: 100%;
  height: 100%;
}

.service-name {
  font-family: 'Unbounded', sans-serif;
  font-weight: 600;
  font-size: 1rem;
  color: var(--dark);
  margin-bottom: 12px;
  letter-spacing: 0.01em;
}

.service-desc {
  font-family: 'Figtree', sans-serif;
  font-size: 0.92rem;
  color: var(--stone);
  line-height: 1.7;
}

/* ===== ABOUT ===== */
.section-about {
  padding: 80px 0;
  background: var(--light);
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.about-image-wrap {
  position: relative;
}

.about-image-deco {
  position: absolute;
  top: -12px;
  left: -12px;
  width: 100%;
  height: 100%;
  border: 1px solid var(--accent);
  opacity: 0.3;
}

.about-image {
  width: 100%;
  height: auto;
  display: block;
  position: relative;
  z-index: 1;
  filter: grayscale(10%);
}

.about-image-frame {
  position: absolute;
  bottom: -12px;
  right: -12px;
  width: 100%;
  height: 100%;
  border: 1px solid var(--accent);
  opacity: 0.2;
}

.about-text .section-tag {
  text-align: left;
  display: block;
}

.about-text .section-title {
  text-align: left;
}

.about-desc {
  font-family: 'Figtree', sans-serif;
  font-size: 1rem;
  color: var(--stone);
  margin-bottom: 20px;
  line-height: 1.8;
}

.about-stats {
  display: flex;
  gap: 40px;
  margin-top: 32px;
  padding-top: 32px;
  border-top: 1px solid var(--accent-light);
}

.stat-number {
  display: block;
  font-family: 'Unbounded', sans-serif;
  font-weight: 700;
  font-size: 2rem;
  color: var(--dark);
}

.stat-label {
  font-family: 'Figtree', sans-serif;
  font-size: 0.85rem;
  color: var(--stone);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ===== OFFICE ===== */
.section-office {
  padding: 40px 0 80px;
  background: var(--light);
}

.office-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.office-card {
  overflow: hidden;
  position: relative;
}

.office-card::after {
  content: '';
  position: absolute;
  inset: 0;
  border: 1px solid var(--accent-light);
  pointer-events: none;
}

.office-img {
  width: 100%;
  height: 300px;
  object-fit: cover;
  display: block;
  transition: transform 0.6s;
}

.office-card:hover .office-img {
  transform: scale(1.04);
}

/* ===== TESTIMONIALS ===== */
.section-testimonials {
  padding: 80px 0;
  background: var(--cream);
}

.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.testimonial-card {
  background: var(--light);
  border: 1px solid rgba(139, 132, 119, 0.1);
  padding: 36px 28px;
  transition: all 0.4s;
  position: relative;
}

.testimonial-card::before {
  content: '\201C';
  font-family: 'Unbounded', sans-serif;
  font-size: 4rem;
  color: var(--accent-light);
  position: absolute;
  top: 12px;
  left: 20px;
  line-height: 1;
}

.testimonial-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(44, 42, 38, 0.08);
}

.testimonial-stars {
  display: flex;
  gap: 4px;
  margin-bottom: 16px;
}

.star {
  width: 16px;
  height: 16px;
}

.testimonial-text {
  font-family: 'Figtree', sans-serif;
  font-size: 0.95rem;
  color: var(--dark);
  line-height: 1.7;
  margin-bottom: 20px;
  font-style: italic;
}

.testimonial-author {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.author-name {
  font-family: 'Unbounded', sans-serif;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--dark);
}

.author-detail {
  font-family: 'Figtree', sans-serif;
  font-size: 0.8rem;
  color: var(--stone);
}

/* ===== GALLERY ===== */
.section-gallery {
  padding: 80px 0;
  background: var(--light);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.gallery-item {
  overflow: hidden;
  cursor: pointer;
  position: relative;
  border: 1px solid var(--accent-light);
}

.gallery-item::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 60%, rgba(44, 42, 38, 0.4) 100%);
  opacity: 0;
  transition: opacity 0.4s;
  pointer-events: none;
}

.gallery-item:hover::after {
  opacity: 1;
}

.gallery-img {
  width: 100%;
  height: 240px;
  object-fit: cover;
  display: block;
  transition: transform 0.5s;
}

.gallery-item:hover .gallery-img {
  transform: scale(1.05);
}

/* ===== LIGHTBOX ===== */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(30, 29, 26, 0.95);
  z-index: 2000;
  align-items: center;
  justify-content: center;
  padding: 40px;
}

.lightbox.active {
  display: flex;
}

.lightbox-img {
  max-width: 90vw;
  max-height: 85vh;
  object-fit: contain;
}

.lightbox-close,
.lightbox-prev,
.lightbox-next {
  position: absolute;
  background: none;
  border: none;
  color: var(--cream);
  font-size: 2rem;
  cursor: pointer;
  padding: 12px;
  transition: opacity 0.3s;
  z-index: 2001;
}

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

.lightbox-close {
  top: 20px;
  right: 24px;
  font-size: 2.5rem;
}

.lightbox-prev {
  left: 20px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 2.5rem;
}

.lightbox-next {
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 2.5rem;
}

/* ===== FAQ ===== */
.section-faq {
  padding: 80px 0;
  background: var(--cream);
}

.faq-list {
  max-width: 760px;
  margin: 0 auto;
}

.faq-item {
  border-bottom: 1px solid var(--accent-light);
}

.faq-question {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px 0;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  font-family: 'Unbounded', sans-serif;
  font-weight: 500;
  font-size: 1rem;
  color: var(--dark);
  transition: color 0.3s;
}

.faq-question:hover {
  color: var(--stone);
}

.faq-chevron {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  transition: transform 0.3s;
}

.faq-item.active .faq-chevron {
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, padding 0.4s;
}

.faq-item.active .faq-answer {
  max-height: 300px;
  padding-bottom: 24px;
}

.faq-answer p {
  font-family: 'Figtree', sans-serif;
  font-size: 0.95rem;
  color: var(--stone);
  line-height: 1.8;
}

/* ===== CTA SECTION ===== */
.section-cta {
  padding: 100px 0;
  background: linear-gradient(165deg, var(--darker) 0%, var(--dark) 50%, #3a3730 100%);
  position: relative;
  overflow: hidden;
}

.cta-content {
  text-align: center;
  position: relative;
  z-index: 1;
}

.cta-title {
  font-family: 'Unbounded', sans-serif;
  font-weight: 700;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  color: var(--cream);
  margin-bottom: 20px;
}

.cta-desc {
  font-family: 'Figtree', sans-serif;
  font-size: 1.05rem;
  color: rgba(239, 232, 222, 0.65);
  max-width: 500px;
  margin: 0 auto 40px;
  line-height: 1.8;
}

.cta-deco-left,
.cta-deco-right {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 80px;
  height: 80px;
  opacity: 0.2;
}

.cta-deco-left {
  left: 10%;
}

.cta-deco-right {
  right: 10%;
}

/* ===== CONTACT ===== */
.section-contact {
  padding: 80px 0;
  background: var(--light);
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-label {
  display: block;
  font-family: 'Figtree', sans-serif;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--dark);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 8px;
}

.form-input {
  width: 100%;
  padding: 14px 16px;
  font-family: 'Figtree', sans-serif;
  font-size: 0.95rem;
  color: var(--dark);
  background: var(--cream);
  border: 1px solid var(--accent-light);
  outline: none;
  transition: border-color 0.3s, box-shadow 0.3s;
}

.form-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-light);
}

.form-input::placeholder {
  color: rgba(139, 132, 119, 0.5);
}

textarea.form-input {
  resize: vertical;
  min-height: 100px;
}

select.form-input {
  cursor: pointer;
  appearance: none;
  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='%238B8477' stroke-width='1.5' fill='none'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 40px;
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.info-card {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  padding: 20px;
  background: var(--cream);
  border: 1px solid var(--accent-light);
  transition: transform 0.3s;
}

.info-card:hover {
  transform: translateX(4px);
}

.info-icon {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.info-icon svg {
  width: 24px;
  height: 24px;
}

.info-title {
  font-family: 'Unbounded', sans-serif;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--dark);
  margin-bottom: 4px;
}

.info-text {
  font-family: 'Figtree', sans-serif;
  font-size: 0.9rem;
  color: var(--stone);
  line-height: 1.6;
}

.info-text a {
  color: var(--stone);
  text-decoration: none;
  transition: color 0.3s;
}

.info-text a:hover {
  color: var(--dark);
}

.social-links {
  display: flex;
  gap: 16px;
  padding-top: 8px;
}

.social-link {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--accent-light);
  transition: all 0.3s;
}

.social-link:hover {
  background: var(--stone);
  border-color: var(--stone);
}

.social-link:hover svg {
  fill: var(--cream);
}

.social-link svg {
  width: 20px;
  height: 20px;
  transition: fill 0.3s;
}

/* ===== FOOTER ===== */
.footer {
  background: var(--darker);
  padding: 60px 0 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr 1.5fr;
  gap: 40px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(239, 232, 222, 0.1);
}

.footer-logo {
  height: 82px;
  width: auto;
  margin-bottom: 16px;
  /* Usa logo-footer.png, cuyo fondo ya es el color del footer (#1E1D1A),
     por lo que se mezcla sin dejar recuadro. */
}

.footer-desc {
  font-family: 'Figtree', sans-serif;
  font-size: 0.9rem;
  color: rgba(239, 232, 222, 0.5);
  line-height: 1.7;
}

.footer-heading {
  font-family: 'Unbounded', sans-serif;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--cream);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 16px;
}

.footer-text {
  font-family: 'Figtree', sans-serif;
  font-size: 0.88rem;
  color: rgba(239, 232, 222, 0.5);
  line-height: 1.7;
}

.footer-text a {
  color: rgba(239, 232, 222, 0.5);
  text-decoration: none;
  transition: color 0.3s;
}

.footer-text a:hover {
  color: var(--cream);
}

.footer-map {
  border: 1px solid rgba(239, 232, 222, 0.1);
  overflow: hidden;
}

.footer-map iframe {
  display: block;
  height: 200px;
}

.footer-bottom {
  padding: 24px 0;
  text-align: center;
}

.footer-bottom p {
  font-family: 'Figtree', sans-serif;
  font-size: 0.8rem;
  color: rgba(239, 232, 222, 0.3);
}

/* ===== CHAT WIDGET ===== */
.chat-widget {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 1500;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}

.chat-toggle {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: var(--stone);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(44, 42, 38, 0.3);
  transition: background 0.3s;
  position: relative;
  z-index: 2;
}

.chat-toggle:hover {
  background: var(--dark);
}

.chat-toggle svg {
  width: 26px;
  height: 26px;
  color: var(--cream);
}

.chat-icon-close {
  display: none;
}

.chat-widget.open .chat-icon-open {
  display: none;
}

.chat-widget.open .chat-icon-close {
  display: block;
}

.chat-toggle.pulse {
  animation: chatPulse 2s ease-in-out infinite;
}

@keyframes chatPulse {
  0%, 100% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(1.08);
    opacity: 0.85;
  }
}

.chat-tooltip {
  position: absolute;
  bottom: 72px;
  right: 0;
  background: var(--light);
  color: var(--dark);
  font-family: 'Figtree', sans-serif;
  font-size: 0.85rem;
  font-weight: 500;
  padding: 10px 16px;
  border: 1px solid var(--accent-light);
  white-space: nowrap;
  box-shadow: 0 4px 16px rgba(44, 42, 38, 0.1);
  opacity: 1;
  transition: opacity 0.3s;
}

.chat-tooltip::after {
  content: '';
  position: absolute;
  bottom: -6px;
  right: 24px;
  width: 12px;
  height: 12px;
  background: var(--light);
  border-right: 1px solid var(--accent-light);
  border-bottom: 1px solid var(--accent-light);
  transform: rotate(45deg);
}

.chat-widget.open .chat-tooltip {
  opacity: 0;
  pointer-events: none;
}

.chat-panel {
  display: none;
  width: 360px;
  height: 480px;
  background: var(--light);
  border: 1px solid var(--accent-light);
  box-shadow: 0 12px 40px rgba(44, 42, 38, 0.2);
  flex-direction: column;
  margin-bottom: 12px;
  overflow: hidden;
}

.chat-widget.open .chat-panel {
  display: flex;
}

.chat-header {
  background: var(--stone);
  padding: 16px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.chat-header-title {
  font-family: 'Unbounded', sans-serif;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--cream);
}

.chat-close {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--cream);
  padding: 2px;
  opacity: 0.7;
  transition: opacity 0.3s;
}

.chat-close:hover {
  opacity: 1;
}

.chat-close svg {
  width: 18px;
  height: 18px;
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.chat-messages::-webkit-scrollbar {
  width: 4px;
}

.chat-messages::-webkit-scrollbar-track {
  background: transparent;
}

.chat-messages::-webkit-scrollbar-thumb {
  background: var(--accent-light);
  border-radius: 2px;
}

.chat-msg {
  max-width: 85%;
  padding: 10px 14px;
  font-family: 'Figtree', sans-serif;
  font-size: 0.88rem;
  line-height: 1.6;
  word-wrap: break-word;
}

.chat-msg.assistant {
  background: var(--cream);
  color: var(--dark);
  align-self: flex-start;
  border: 1px solid var(--accent-light);
  border-radius: 0 12px 12px 12px;
}

.chat-msg.user {
  background: var(--stone);
  color: var(--cream);
  align-self: flex-end;
  border-radius: 12px 0 12px 12px;
}

.chat-msg a {
  color: inherit;
  text-decoration: underline;
  word-break: break-all;
}

.chat-msg.assistant a {
  color: var(--stone);
}

.chat-typing {
  display: flex;
  gap: 4px;
  padding: 10px 14px;
  background: var(--cream);
  align-self: flex-start;
  border: 1px solid var(--accent-light);
  border-radius: 0 12px 12px 12px;
}

.chat-typing span {
  width: 6px;
  height: 6px;
  background: var(--stone);
  border-radius: 50%;
  animation: typingDot 1.4s ease-in-out infinite;
}

.chat-typing span:nth-child(2) {
  animation-delay: 0.2s;
}

.chat-typing span:nth-child(3) {
  animation-delay: 0.4s;
}

@keyframes typingDot {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.4; }
  30% { transform: translateY(-6px); opacity: 1; }
}

.chat-input-area {
  display: flex;
  border-top: 1px solid var(--accent-light);
  padding: 12px;
  gap: 8px;
}

.chat-input {
  flex: 1;
  padding: 10px 14px;
  font-family: 'Figtree', sans-serif;
  font-size: 0.88rem;
  color: var(--dark);
  background: var(--cream);
  border: 1px solid var(--accent-light);
  outline: none;
  border-radius: 4px;
  transition: border-color 0.3s;
}

.chat-input:focus {
  border-color: var(--accent);
}

.chat-send {
  width: 40px;
  height: 40px;
  background: var(--stone);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  transition: background 0.3s;
}

.chat-send:hover {
  background: var(--dark);
}

.chat-send svg {
  width: 18px;
  height: 18px;
  color: var(--cream);
}

/* ===== REVEAL ANIMATIONS ===== */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .testimonials-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }

  .cta-deco-left,
  .cta-deco-right {
    display: none;
  }
}

@media (max-width: 768px) {
  .main-nav,
  .header-cta {
    display: none;
  }

  .mobile-toggle {
    display: flex;
  }

  .header-inner {
    height: 77px;
  }

  /* En movil el header es mas bajo; reducimos el logo para que no se salga
     de la barra y conserve aire arriba y abajo. */
  .header-logo {
    height: 60px;
  }

  .hero-section {
    padding: 100px 20px 60px;
    min-height: 90vh;
  }

  .hero-title {
    font-size: clamp(1.8rem, 8vw, 3rem);
    /* Evita que las letras (spans inline-block) partan una palabra a media línea.
       El salto entre líneas lo sigue dando el <br> de .hero-break. */
    white-space: nowrap;
  }

  .hero-line-art {
    width: 200px;
    height: 200px;
    right: -20px;
    bottom: -20px;
  }

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

  .about-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .about-text .section-tag,
  .about-text .section-title {
    text-align: center;
  }

  .about-desc {
    text-align: center;
  }

  .about-stats {
    justify-content: center;
  }

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

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

  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }

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

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .chat-panel {
    width: calc(100vw - 48px);
    height: 420px;
  }

  .section-services,
  .section-about,
  .section-testimonials,
  .section-gallery,
  .section-faq,
  .section-contact,
  .section-cta {
    padding: 60px 0;
  }
}

@media (max-width: 480px) {
  .hero-cta-group {
    flex-direction: column;
    align-items: center;
  }

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

  .about-stats {
    flex-direction: column;
    align-items: center;
    gap: 24px;
  }

  .stat-item {
    text-align: center;
  }
}