/* ============================
   CAROLINA TORRES FISIODERMA
   ============================ */

:root {
  --marmol: #FAF8F4;
  --marmol-2: #F1EAD9;
  --dorado: #C9A24B;
  --dorado-oscuro: #A9813A;
  --negro: #1A1A1A;
  --teal: #2F5F58;
  --teal-claro: #E4EEEC;
  --texto-suave: #4A4A46;

  --font-display: 'Cormorant Garamond', serif;
  --font-body: 'Work Sans', sans-serif;

  --radius: 6px;
  --shadow-soft: 0 12px 30px rgba(26,26,26,0.08);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  color: var(--negro);
  background: var(--marmol);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

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

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

em {
  font-style: italic;
  color: var(--dorado-oscuro);
}

.eyebrow {
  font-family: var(--font-body);
  font-size: 0.78rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--teal);
  font-weight: 500;
  margin-bottom: 12px;
}
.eyebrow.center { text-align: center; }

.section-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 500;
  line-height: 1.15;
  margin-bottom: 20px;
}
.section-title.center { text-align: center; margin-left: auto; margin-right: auto; max-width: 720px; }

/* Botones */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 30px;
  border-radius: var(--radius);
  font-weight: 500;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  transition: all 0.25s ease;
  cursor: pointer;
  border: 1.5px solid transparent;
}
.btn-gold {
  background: var(--dorado);
  color: #fff;
}
.btn-gold:hover { background: var(--dorado-oscuro); transform: translateY(-2px); }
.btn-outline {
  border-color: var(--negro);
  color: var(--negro);
}
.btn-outline:hover { background: var(--negro); color: #fff; }
.btn-full { width: 100%; }

/* ============ HEADER ============ */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: rgba(250, 248, 244, 0.9);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(26,26,26,0.06);
  transition: box-shadow 0.3s ease;
}
.site-header.scrolled { box-shadow: 0 4px 20px rgba(0,0,0,0.05); }

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 24px;
}

.brand-logo { height: 96px; width: auto; }

.main-nav {
  display: flex;
  gap: 32px;
}
.main-nav a {
  font-size: 0.9rem;
  font-weight: 500;
  position: relative;
  padding-bottom: 4px;
}
.main-nav a::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0;
  width: 0; height: 1.5px;
  background: var(--dorado);
  transition: width 0.25s ease;
}
.main-nav a:hover::after { width: 100%; }

.nav-cta { padding: 10px 22px; font-size: 0.85rem; }

.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
}
.menu-toggle span {
  width: 24px; height: 2px;
  background: var(--negro);
}

/* ============ HERO ============ */
.hero {
  position: relative;
  padding: 190px 0 100px;
  overflow: hidden;
}

.hero-ribbon {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  z-index: 0;
  opacity: 0.5;
}
.hero-ribbon svg { width: 100%; height: 100%; }

.ribbon-path {
  fill: none;
  stroke: var(--dorado);
  stroke-width: 1.5;
  opacity: 0.35;
}

.ribbon-glow {
  fill: none;
  stroke: url(#ribbonGlow);
  stroke-width: 3.5;
  stroke-linecap: round;
  stroke-dasharray: 450 3000;
  animation: none;
}

@keyframes ribbon-glow-move {
  to { stroke-dashoffset: -3260; }
}

.hero-inner {
  position: relative;
  z-index: 1;
  max-width: 1180px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
}

.hero-brand-col { display: flex; flex-direction: column; padding-bottom: 10px; }

.hero-brand-script {
  font-family: var(--font-display);
  font-style: italic;
  font-size: clamp(1.3rem, 2vw, 1.7rem);
  color: var(--dorado-oscuro);
  margin-bottom: 4px;
}

.hero-brand {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(3.4rem, 7vw, 6.2rem);
  letter-spacing: 0.03em;
  line-height: 1;
  margin: 0 0 6px;
  background: linear-gradient(100deg,
    var(--dorado-oscuro) 0%,
    var(--dorado) 25%,
    #fff5da 45%,
    var(--dorado) 65%,
    var(--dorado-oscuro) 100%);
  background-size: 250% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
 animation: none;
}

@keyframes shimmer {
  0% { background-position: 0% center; }
  100% { background-position: -250% center; }
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 500;
  line-height: 1.3;
  margin-bottom: 22px;
  color: var(--negro);
}

.hero-sub {
  font-size: 1.08rem;
  color: var(--texto-suave);
  max-width: 520px;
  margin-bottom: 34px;
}

.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; }

.hero-media-wrap {
  position: relative;
  z-index: 1;
  margin-top: 60px;
  overflow: hidden;
  contain: layout;
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 6%, #000 94%, transparent 100%);
  mask-image: linear-gradient(90deg, transparent 0%, #000 6%, #000 94%, transparent 100%);
}

.hero-media-track {
  display: flex;
  gap: 20px;
  width: max-content;
  animation: hero-scroll 45s linear infinite;
  will-change: transform;
}

.hero-media-track img {
  height: 380px;
  width: auto;
  max-width: none;
  object-fit: contain;
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
  flex-shrink: 0;
  padding: 4px;
}

@keyframes hero-scroll {
  from { transform: translate3d(0, 0, 0); }
  to   { transform: translate3d(-50%, 0, 0); }
}

@media (max-width: 900px) {
  .hero-media-track img { height: 200px; width: 280px; max-width: none; }
}

/* ============ SERVICIOS ============ */
.servicios { padding: 110px 0; background: var(--marmol-2); }

.servicios-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 28px;
  margin-top: 60px;
}

.servicio-card {
  background: #fff;
  padding: 36px 30px;
  border-radius: var(--radius);
  border: 1px solid rgba(26,26,26,0.05);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.servicio-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-soft);
}

.servicio-icon {
  width: 48px; height: 48px;
  color: var(--dorado);
  margin-bottom: 18px;
}
.servicio-icon svg { width: 100%; height: 100%; }

.servicio-card h3 {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 600;
  margin-bottom: 10px;
}
.servicio-card p {
  color: var(--texto-suave);
  font-size: 0.95rem;
}

/* ============ RESULTADOS / PACIENTES ============ */
.resultados-strip { margin-top: 60px; }

.resultados-label {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.15rem;
  color: var(--dorado-oscuro);
  text-align: center;
  margin-bottom: 24px;
}

.resultados-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.resultados-item {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  aspect-ratio: 3/4;
  line-height: 0;
}
.resultados-item img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.resultados-item:hover img { transform: scale(1.06); }

@media (max-width: 900px) {
  .resultados-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ============ TIPS ============ */
.tips { padding: 110px 0; }

.tips-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: flex-start;
  gap: 28px;
  margin-top: 60px;
}
.tips-item {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  transition: transform 0.3s ease;
  height: 368px;
  line-height: 0;
}
.tips-item:hover { transform: translateY(-6px); }
.tips-item img { height: 100%; width: auto; display: block; }

/* ============ GALERIA ============ */
.galeria { padding: 110px 0; }

.galeria-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: 200px;
  gap: 14px;
  margin-top: 60px;
}
.galeria-item {
  overflow: hidden;
  border-radius: var(--radius);
  position: relative;
}
.galeria-item.span-2 { grid-column: span 2; grid-row: span 2; }
.galeria-item img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.galeria-item:hover img { transform: scale(1.08); }

/* ============ NOSOTROS ============ */
.nosotros { padding: 110px 0; background: var(--marmol-2); }

.nosotros-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 70px;
  align-items: center;
}

.nosotros-media img {
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
}

.nosotros-text p {
  color: var(--texto-suave);
  margin-bottom: 24px;
}

.nosotros-list { list-style: none; }
.nosotros-list li {
  padding: 10px 0 10px 30px;
  position: relative;
  font-weight: 500;
  border-top: 1px solid rgba(26,26,26,0.08);
}
.nosotros-list li:before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--teal);
  font-weight: 700;
}

/* ============ ESPECIALISTA ============ */
.especialista { padding: 110px 0; background: #fff; }

.especialista-inner {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 70px;
  align-items: center;
}

.especialista-text p {
  color: var(--texto-suave);
  margin-bottom: 0;
}

.especialista-media {
  position: relative;
}
.especialista-media img {
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
  width: 100%;
  aspect-ratio: 4/5;
  object-fit: cover;
}
.especialista-media::before {
  content: '';
  position: absolute;
  top: -18px; right: -18px;
  width: 100%; height: 100%;
  border: 2px solid var(--dorado);
  border-radius: var(--radius);
  z-index: -1;
}

/* ============ AGENDA ============ */
.agenda { padding: 110px 0; background: var(--negro); color: #fff; }

.agenda-inner {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 70px;
  align-items: start;
}

.agenda-text .eyebrow { color: var(--dorado); }
.agenda-text p { color: rgba(255,255,255,0.7); }

.agenda-form {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: var(--radius);
  padding: 36px;
  display: grid;
  gap: 18px;
}

.form-row { display: flex; flex-direction: column; gap: 6px; }
.form-row label { font-size: 0.85rem; color: rgba(255,255,255,0.6); }
.form-row input,
.form-row select,
.form-row textarea {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: var(--radius);
  padding: 12px 14px;
  color: #fff;
  font-family: var(--font-body);
  font-size: 0.95rem;
}
.form-row input::placeholder,
.form-row textarea::placeholder { color: rgba(255,255,255,0.35); }
.form-row select option { color: #000; }
.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus {
  outline: none;
  border-color: var(--dorado);
}

/* ============ FOOTER ============ */
.site-footer { background: var(--marmol-2); padding: 70px 0 0; }

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  flex-wrap: wrap;
  padding-bottom: 50px;
  border-bottom: 1px solid rgba(26,26,26,0.08);
}

.footer-brand { flex-shrink: 0; }

.footer-logo { height: 88px; margin-bottom: 12px; }
.footer-brand p { color: var(--texto-suave); font-style: italic; }

/* --- Tarjeta de ubicación (logo | mapa | redes en una sola fila) --- */
.location-card {
  flex: 1 1 420px;
  max-width: 480px;
  background: var(--negro);
  border-radius: var(--radius);
  padding: 24px;
}

.location-title {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dorado);
  margin-bottom: 14px;
}

.location-address {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #fff;
  font-weight: 500;
  font-size: 0.95rem;
  margin-bottom: 16px;
}

.location-card .footer-map {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: none;
  border: none;
  margin-top: 0;
}
.location-card .footer-map iframe {
  height: 200px;
  width: 100%;
  filter: none;
  display: block;
  border: 0;
}

.location-social-block { flex-shrink: 0; text-align: center; }
.location-social-block .social-icons {
  display: flex;
  flex-direction: row;
  gap: 14px;
}

.footer-col h4 {
  font-family: var(--font-display);
  font-size: 1.1rem;
  margin-bottom: 14px;
}
.footer-col a { display: block; color: var(--texto-suave); margin-bottom: 8px; }
.footer-col a:hover { color: var(--dorado-oscuro); }

.social-icons { display: flex; gap: 14px; }
.social-icon {
  width: 40px; height: 40px;
  border-radius: 50%;
  border: 1.5px solid var(--negro);
  display: flex; align-items: center; justify-content: center;
  color: var(--negro);
  transition: all 0.25s ease;
}
.social-icon svg { width: 18px; height: 18px; }
.social-icon:hover { background: var(--dorado); border-color: var(--dorado); color: #fff; }

.footer-bottom {
  text-align: center;
  padding: 24px 0;
  font-size: 0.82rem;
  color: var(--texto-suave);
}

/* ============ WHATSAPP FLOTANTE ============ */
.whatsapp-float {
  position: fixed;
  bottom: 26px; right: 26px;
  width: 60px; height: 60px;
  background: #25D366;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 8px 24px rgba(0,0,0,0.2);
  z-index: 200;
  animation: pulse 2.4s infinite;
}
.whatsapp-float svg { width: 30px; height: 30px; color: #25D366; }

/* Botón flotante versión de Cristian (SVG ya trae el círculo verde incluido) */
.whatsapp-float-corregido {
  position: fixed;
  bottom: 26px; right: 26px;
  width: 60px; height: 60px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 8px 24px rgba(0,0,0,0.2);
  z-index: 200;
  animation: pulse 2.4s infinite;
}
.whatsapp-float-corregido svg { width: 100%; height: 100%; }

@keyframes pulse {
  0% { box-shadow: 0 8px 24px rgba(0,0,0,0.2), 0 0 0 0 rgba(37,211,102,0.5); }
  70% { box-shadow: 0 8px 24px rgba(0,0,0,0.2), 0 0 0 14px rgba(37,211,102,0); }
  100% { box-shadow: 0 8px 24px rgba(0,0,0,0.2), 0 0 0 0 rgba(37,211,102,0); }
}

/* ============ RESPONSIVE ============ */
@media (max-width: 900px) {
  .main-nav {
    position: fixed;
    top: 72px; left: 0; right: 0;
    background: var(--marmol);
    flex-direction: column;
    align-items: center;
    gap: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease;
    border-bottom: 1px solid rgba(26,26,26,0.06);
  }
  .main-nav.open { max-height: 400px; }
  .main-nav a {
    width: 100%;
    text-align: center;
    padding: 16px 0;
    border-top: 1px solid rgba(26,26,26,0.06);
  }
  .nav-cta { display: none; }
  .menu-toggle { display: flex; }
  .menu-toggle.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .menu-toggle.active span:nth-child(2) { opacity: 0; }
  .menu-toggle.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

  .nosotros-inner, .agenda-inner, .especialista-inner { grid-template-columns: 1fr; }
  .galeria-grid { grid-template-columns: repeat(2, 1fr); }
  .galeria-item.span-2 { grid-column: span 2; grid-row: span 1; }
  .tips-grid { grid-template-columns: 1fr; }
  .tips-item { width: 100%; height: auto; }
  .tips-item img { width: 100%; height: auto; }

  .footer-inner { flex-direction: column; align-items: center; text-align: center; }
  .location-card { width: 100%; max-width: 100%; flex: none; }
  .social-icons { justify-content: center; }

  .hero-media { flex-direction: column; }
  .hero-img-1, .hero-img-2 { width: 100%; margin-top: 0; }
  .hero-inner { grid-template-columns: 1fr; text-align: left; }
}

@media (max-width: 1100px) and (min-width: 901px) {
  .footer-inner { justify-content: center; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}

/* ============ PORTAFOLIO (carrusel de servicios) ============ */
.portafolio { padding: 100px 0 110px; background: var(--marmol); }

.portafolio-wrap {
  position: relative;
  margin-top: 50px;
  overflow: hidden;
  contain: layout;
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 6%, #000 94%, transparent 100%);
  mask-image: linear-gradient(90deg, transparent 0%, #000 6%, #000 94%, transparent 100%);
}

.portafolio-track {
  display: flex;
  gap: 18px;
  width: max-content;
  animation: portafolio-scroll 40s linear infinite;
  will-change: transform;
}

.portafolio-track img {
  height: 360px;
  width: auto;
  max-width: none;
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
  flex-shrink: 0;
  padding: 4px;
}

@keyframes portafolio-scroll {
  from { transform: translate3d(0, 0, 0); }
  to   { transform: translate3d(-50%, 0, 0); }
}

@media (max-width: 900px) {
  .portafolio-track img { height: 280px; width: auto; max-width: none; }
}
.location-social-block {
    position: relative;
    z-index: 20;
}
form, 
.form-row, 
form input, 
form select, 
form textarea, 
form button {
    position: relative !important;
    z-index: 9999 !important;
    pointer-events: auto !important;
}