/* ============================================================
   DENTO — Clínica Dental
   Sistema visual basado en Dento_Cambios.pdf
   ============================================================ */

/* ---------- Fuentes autohospedadas ---------- */
@font-face { font-family: 'Montserrat'; font-style: normal; font-weight: 600; font-display: swap; src: url('../assets/fonts/montserrat-600.woff2') format('woff2'); }
@font-face { font-family: 'Montserrat'; font-style: normal; font-weight: 700; font-display: swap; src: url('../assets/fonts/montserrat-700.woff2') format('woff2'); }
@font-face { font-family: 'Montserrat'; font-style: normal; font-weight: 800; font-display: swap; src: url('../assets/fonts/montserrat-800.woff2') format('woff2'); }
@font-face { font-family: 'Mulish'; font-style: normal; font-weight: 400; font-display: swap; src: url('../assets/fonts/mulish-400.woff2') format('woff2'); }
@font-face { font-family: 'Mulish'; font-style: normal; font-weight: 600; font-display: swap; src: url('../assets/fonts/mulish-600.woff2') format('woff2'); }
@font-face { font-family: 'Mulish'; font-style: normal; font-weight: 700; font-display: swap; src: url('../assets/fonts/mulish-700.woff2') format('woff2'); }

/* ---------- Tokens ---------- */
:root {
  --navy: #2c4e8a;
  --navy-deep: #1f3a6e;
  --navy-btn: #44639f;
  --navy-btn-hover: #375288;
  --blue-mid: #5b7fc0;
  --blue-soft: #dce7f5;
  --blue-pale: #eef4fb;
  --ink: #2b3a52;
  --body: #4a5a74;
  --white: #ffffff;
  --font-display: 'Montserrat', 'Segoe UI', sans-serif;
  --font-body: 'Mulish', 'Segoe UI', sans-serif;
  --radius-card: 14px;
  --radius-btn: 10px;
  --shadow-card: 0 10px 30px rgba(44, 78, 138, 0.10);
  --container: 1200px;
}

/* ---------- Reset básico ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  color: var(--body);
  background: var(--white);
}
img { max-width: 100%; display: block; }
h1, h2, h3, h4 { font-family: var(--font-display); color: var(--navy); margin: 0 0 0.5em; line-height: 1.15; }
p { margin: 0 0 1em; }
a { color: var(--navy); }

.container { max-width: var(--container); margin: 0 auto; padding: 0 24px; }

/* ---------- Botones ---------- */
.btn {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 16px;
  text-decoration: none;
  text-align: center;
  padding: 16px 34px;
  border-radius: var(--radius-btn);
  border: none;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.2s ease, background 0.2s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px) scale(0.98); }
.btn-primary {
  background: linear-gradient(180deg, #4f6ea9 0%, var(--navy-btn) 100%);
  color: var(--white);
  box-shadow: 0 8px 20px rgba(44, 78, 138, 0.25);
}
.btn-primary:hover { background: var(--navy-btn-hover); }
.btn-light {
  background: var(--white);
  color: var(--ink);
  font-weight: 600;
  box-shadow: 0 8px 20px rgba(44, 78, 138, 0.12);
}
.btn-light:hover { background: var(--blue-pale); }

/* ---------- Header / Navbar ---------- */
.site-header {
  background:
    radial-gradient(120% 160% at 85% 0%, rgba(140, 178, 226, 0.55) 0%, rgba(255, 255, 255, 0) 55%),
    linear-gradient(90deg, #c9d9ee 0%, #f4f8fd 30%, #ffffff 55%, #dfeaf7 100%);
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: 0 2px 14px rgba(44, 78, 138, 0.10);
}
.nav-wrap {
  display: flex;
  align-items: center;
  gap: 36px;
  height: 84px;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}
.brand { display: flex; align-items: center; flex-shrink: 0; }
.brand img { height: 72px; width: auto; }
.nav-sep { width: 1px; height: 44px; background: var(--navy); opacity: 0.5; }
.main-nav { display: flex; align-items: center; gap: 34px; }
.main-nav a {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 16px;
  color: var(--navy);
  text-decoration: none;
  padding: 6px 0;
}
.main-nav a:hover { color: var(--navy-deep); text-decoration: underline; text-underline-offset: 6px; }
.main-nav a.active { font-weight: 700; }
.nav-toggle {
  display: none;
  margin-left: auto;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}
.nav-toggle span { display: block; width: 26px; height: 3px; background: var(--navy); margin: 5px 0; border-radius: 2px; }

/* ---------- Hero genérico ---------- */
.hero { position: relative; overflow: hidden; }

/* Hero de Inicio */
.hero-home {
  background: url('../assets/doctora-hero.jpg') center / cover no-repeat;
  aspect-ratio: 2752 / 1536;
  min-height: 500px;
  display: flex;
  align-items: center;
}
@media (min-width: 769px) and (max-width: 1040px) {
  .hero-home { aspect-ratio: auto; min-height: 560px; background-position: 72% center; }
}
.hero-home::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(238, 244, 251, 0.88) 0%, rgba(238, 244, 251, 0.45) 45%, rgba(238, 244, 251, 0) 70%);
}
.hero-home .container { position: relative; z-index: 1; width: 100%; }
.hero-home h1 {
  font-size: clamp(32px, 4.2vw, 52px);
  font-weight: 800;
  text-transform: uppercase;
  max-width: 19ch;
  letter-spacing: 0.5px;
}
.hero-home p { max-width: 46ch; font-size: 18px; margin-bottom: 34px; }
.hero-actions { display: flex; gap: 18px; flex-wrap: wrap; }

/* ---------- Secciones comunes ---------- */
.section { padding: 90px 0; }
.section-tight { padding: 64px 0; }

/* Imagen ancha + intro (Inicio) */
.intro-section {
  background: linear-gradient(180deg, #f6f9fd 0%, var(--blue-soft) 70%, #cfdcf0 100%);
  padding-bottom: 90px;
}
.intro-photo {
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
  width: 100%;
  height: auto;
  transform: translateY(-70px);
  margin-bottom: -30px;
}
.intro-copy { max-width: 640px; margin: 0 auto; text-align: center; }
.intro-copy h2 { font-size: 26px; font-weight: 700; margin-bottom: 28px; }

/* ¿Por qué elegir DENTO? */
.why-section {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(90% 120% at 100% 100%, rgba(255, 255, 255, 0.55) 0%, rgba(255, 255, 255, 0) 45%),
    linear-gradient(135deg, #e9f0f9 0%, #b7c8e4 45%, #6d87b6 100%);
}
.why-section::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 52%;
  background: url('../img/Professional_female_dentist_smiling_and.jpeg') center right / cover no-repeat;
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 42%);
  mask-image: linear-gradient(90deg, transparent 0%, #000 42%);
  z-index: 0;
  pointer-events: none;
}
.why-section .container { position: relative; z-index: 1; }
.why-section h2 { font-size: 26px; font-weight: 700; margin-bottom: 40px; }
.why-cards { display: grid; gap: 22px; max-width: 620px; }
.why-card {
  background: var(--white);
  border-radius: var(--radius-card);
  padding: 26px 32px;
  box-shadow: var(--shadow-card);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 18px;
  color: var(--ink);
}

/* Banner azul */
.banner {
  background: linear-gradient(180deg, #a8c4e4 0%, #4d6ba3 55%, var(--navy-deep) 100%);
  text-align: center;
  padding: 90px 0;
}
.banner h2 { color: var(--white); font-size: 26px; font-weight: 700; }
.banner p { color: #e7eefb; max-width: 88ch; margin: 0 auto; }

/* CTA final (Inicio) */
.cta-section { background: linear-gradient(180deg, #ffffff 0%, #eef4fb 100%); }
.cta-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.cta-grid img { border-radius: var(--radius-card); }
.cta-copy { text-align: center; }
.cta-copy h2 { font-size: clamp(24px, 2.6vw, 32px); font-weight: 800; text-transform: uppercase; }
.cta-copy p { max-width: 42ch; margin: 0 auto 30px; }

/* ---------- Hero Servicios ---------- */
.hero-services {
  background: linear-gradient(180deg, #ffffff 0%, #dbe7f5 35%, #7f97c1 70%, var(--navy) 100%);
  text-align: center;
  padding: 130px 0 80px;
}
.hero-services h1 { color: var(--white); font-size: clamp(30px, 4vw, 46px); font-weight: 800; max-width: 24ch; margin: 0 auto 24px; }
.hero-services .lead { color: var(--white); font-family: var(--font-display); font-weight: 700; font-size: 20px; margin-bottom: 6px; }
.scroll-arrow { color: var(--white); font-size: 26px; line-height: 1; }

/* Carrusel de servicios */
.carousel-section { background: var(--white); }
.carousel-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 36px; }
.carousel-head h2 { font-size: 24px; font-weight: 800; margin: 0; }
.carousel-nav { display: flex; gap: 14px; }
.carousel-btn {
  width: 54px; height: 54px;
  border-radius: 50%;
  border: 1.5px solid #9db4d6;
  background: var(--white);
  color: var(--navy);
  font-size: 20px;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
  display: grid;
  place-items: center;
}
.carousel-btn:hover:not(:disabled) { background: var(--navy-btn); color: var(--white); border-color: var(--navy-btn); }
.carousel-btn:disabled { opacity: 0.4; cursor: default; }
.carousel-viewport { overflow: hidden; }
.carousel-track { display: flex; gap: 26px; transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1); }
.service-card {
  position: relative;
  flex: 0 0 calc((100% - 52px) / 3);
  min-height: 430px;
  border-radius: var(--radius-card);
  overflow: hidden;
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: flex-end;
  box-shadow: var(--shadow-card);
}
.service-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.05) 30%, rgba(47, 73, 122, 0.85) 100%);
  transition: background 0.3s;
}
.service-card h3 {
  position: relative;
  z-index: 1;
  color: var(--white);
  font-size: 22px;
  font-weight: 700;
  text-transform: uppercase;
  text-align: center;
  width: 100%;
  padding: 0 20px 34px;
  margin: 0;
  letter-spacing: 0.5px;
}
.service-card .service-detail {
  position: relative;
  z-index: 1;
  display: none;
  color: var(--white);
  text-align: center;
  padding: 0 26px 30px;
}
.service-card.is-active::before { background: linear-gradient(180deg, rgba(59, 84, 131, 0.55) 0%, rgba(38, 60, 104, 0.9) 100%); }
.service-card.is-active { align-items: center; }
.service-card.is-active .service-inner { position: relative; z-index: 1; width: 100%; display: flex; flex-direction: column; justify-content: center; gap: 8px; padding: 30px 0; }
.service-card.is-active h3 { padding-bottom: 10px; }
.service-card.is-active .service-detail { display: block; }
.service-detail .btn { margin-top: 14px; }
.carousel-counter {
  text-align: center;
  margin-top: 36px;
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--navy);
}
.carousel-counter .bar { display: block; width: 56px; height: 4px; background: var(--navy); margin: 0 auto 10px; border-radius: 2px; }
.carousel-counter .total { color: #9aa9c4; }

/* ---------- Hero Nosotros ---------- */
.hero-about {
  background:
    radial-gradient(100% 140% at 0% 0%, rgba(255, 255, 255, 0.5) 0%, rgba(255, 255, 255, 0) 40%),
    linear-gradient(135deg, #d7e2f2 0%, #9db3d6 45%, #647fb0 100%);
  text-align: center;
  padding: 110px 0;
}
.hero-about h1 {
  color: var(--white);
  font-size: clamp(28px, 3.6vw, 42px);
  font-weight: 800;
  text-transform: uppercase;
  max-width: 26ch;
  margin: 0 auto;
}

.about-grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: 56px; align-items: center; }
.about-grid img { border-radius: var(--radius-card); box-shadow: var(--shadow-card); }

.doctor-section { background: linear-gradient(180deg, #ffffff 0%, #eef4fb 100%); }
.doctor-grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: 56px; align-items: center; }
.doctor-grid img { border-radius: var(--radius-card); box-shadow: var(--shadow-card); }
.doctor-info h2 { font-size: 26px; font-weight: 800; margin-bottom: 24px; }
.doctor-info ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 18px; }
.doctor-info li { position: relative; padding-left: 22px; }
.doctor-info li::before {
  content: '';
  position: absolute;
  left: 4px;
  top: 0.62em;
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--navy);
}

/* ---------- Hero FAQ ---------- */
.hero-faq {
  background: linear-gradient(180deg, #0b0d12 0%, #101725 45%, #27406e 80%, #3d5c96 100%);
  text-align: center;
  padding: 150px 0 90px;
}
.hero-faq .eyebrow {
  color: #cdd9ec;
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: 1px;
  display: inline-block;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.45);
  margin-bottom: 22px;
  min-width: 320px;
}
.hero-faq h1 { color: var(--white); font-size: clamp(34px, 4.4vw, 52px); font-weight: 800; margin: 0; }

.faq-section {
  background: url('../assets/fondo-ondas.jpg') center / cover no-repeat;
}
.faq-list { max-width: 980px; margin: 0 auto; }
.faq-item { border-bottom: 1px solid #c3d0e4; padding: 30px 0; }
.faq-item:last-child { border-bottom: none; }
.faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 21px;
  color: var(--navy);
  padding: 0;
}
.faq-icon {
  flex-shrink: 0;
  width: 34px; height: 34px;
  border-radius: 50%;
  background: var(--navy-btn);
  color: var(--white);
  display: grid;
  place-items: center;
  font-size: 19px;
  font-weight: 400;
  transition: transform 0.25s ease, background 0.25s ease;
}
.faq-item.open .faq-icon { transform: rotate(45deg); background: #8fa6cd; }
.faq-answer { max-height: 0; overflow: hidden; transition: max-height 0.35s ease; }
.faq-answer p { padding-top: 16px; margin: 0; max-width: 75ch; }

/* ---------- Hero Contacto ---------- */
.hero-contact {
  background: url('../assets/recepcion.jpg') center / cover no-repeat;
  text-align: center;
  padding: 120px 0;
  position: relative;
}
.hero-contact::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(97, 126, 175, 0.78) 0%, rgba(120, 148, 194, 0.72) 100%);
}
.hero-contact .container { position: relative; z-index: 1; }
.hero-contact h1 { color: var(--white); font-size: clamp(32px, 4.4vw, 50px); font-weight: 800; margin-bottom: 20px; }
.hero-contact p { color: #f0f5fc; max-width: 52ch; margin: 0 auto 1em; }
.hero-contact .hero-actions { justify-content: center; margin-top: 30px; }

.contact-section { background: var(--white); }
.contact-grid { display: grid; grid-template-columns: 1fr 1.15fr; gap: 48px; align-items: start; }
.contact-info h2 { font-size: 26px; font-weight: 800; margin-bottom: 26px; }
.contact-lines { list-style: none; padding: 0; margin: 0 0 30px; display: grid; gap: 16px; }
.contact-lines li { display: flex; align-items: flex-start; gap: 12px; font-weight: 700; color: var(--ink); }
.contact-lines svg { flex-shrink: 0; margin-top: 3px; }
.contact-map {
  width: 100%;
  height: 330px;
  border: 0;
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
}
.form-card {
  background: #e8eef7;
  border-radius: 22px;
  padding: 44px 42px;
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; margin-bottom: 22px; }
.form-field label {
  display: block;
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 10px;
  font-size: 16px;
}
.form-field input, .form-field textarea {
  width: 100%;
  border: none;
  border-radius: 999px;
  padding: 15px 22px;
  font-family: var(--font-body);
  font-size: 15px;
  color: var(--ink);
  background: #f7f9fd;
  box-shadow: inset 0 1px 3px rgba(44, 78, 138, 0.08);
}
.form-field textarea { border-radius: 18px; min-height: 150px; resize: vertical; }
.form-field input::placeholder, .form-field textarea::placeholder { color: #93a2bd; }
.form-field input:focus, .form-field textarea:focus { outline: 2px solid var(--navy-btn); }
.form-msg { display: none; margin-top: 18px; font-weight: 700; color: #1d6b3a; }
.form-msg.error { color: #a3253a; }
.form-msg.show { display: block; }

/* ---------- Footer ---------- */
.site-footer {
  background:
    radial-gradient(60% 90% at 15% 20%, rgba(255, 255, 255, 0.75) 0%, rgba(255, 255, 255, 0) 60%),
    radial-gradient(50% 80% at 80% 70%, rgba(255, 255, 255, 0.6) 0%, rgba(255, 255, 255, 0) 55%),
    linear-gradient(135deg, #93a9cf 0%, #b9c9e4 35%, #d4e0f1 60%, #a8bcdc 100%);
  padding: 70px 0 30px;
  color: var(--ink);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1.2fr 0.8fr 0.7fr;
  gap: 40px;
  align-items: start;
}
.footer-brand { text-align: center; }
.footer-brand img { height: 150px; width: auto; margin: 0 auto 14px; }
.footer-brand p { margin-bottom: 10px; }
.footer-brand .tagline { font-family: var(--font-display); font-weight: 700; color: var(--ink); }
.footer-col h3 { font-size: 18px; font-weight: 700; color: var(--ink); margin-bottom: 22px; }
.footer-col ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; }
.footer-col a { color: var(--ink); text-decoration: none; }
.footer-col a:hover { text-decoration: underline; }
.footer-contact li { display: flex; gap: 10px; align-items: flex-start; }
.footer-contact svg { flex-shrink: 0; margin-top: 4px; }
.social-links { display: flex; gap: 16px; }
.social-links a { display: block; }
.social-links img, .social-links svg { width: 38px; height: 38px; }
.footer-bottom {
  border-top: 1px solid rgba(44, 78, 138, 0.25);
  margin-top: 50px;
  padding-top: 22px;
  text-align: center;
  font-size: 15px;
}

/* ---------- Responsive ---------- */
@media (max-width: 992px) {
  .cta-grid, .about-grid, .doctor-grid, .contact-grid { grid-template-columns: 1fr; }
  .doctor-grid img { order: -1; }
  .service-card { flex: 0 0 calc((100% - 26px) / 2); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
  .nav-toggle { display: block; }
  .nav-sep { display: none; }
  .main-nav {
    position: absolute;
    top: 84px;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    background: var(--white);
    box-shadow: 0 14px 24px rgba(44, 78, 138, 0.15);
    display: none;
  }
  .main-nav.open { display: flex; }
  .main-nav a { padding: 16px 24px; width: 100%; text-align: center; }
  .brand img { height: 58px; }
  .hero-home { aspect-ratio: auto; min-height: 540px; background-position: 72% center; }
  .hero-home::before { background: rgba(238, 244, 251, 0.82); }
  .why-section::before { display: none; }
  .intro-photo { transform: translateY(-40px); }
  .section { padding: 64px 0; }
  .service-card { flex: 0 0 100%; }
  .form-row { grid-template-columns: 1fr; }
  .form-card { padding: 32px 24px; }
  .footer-grid { grid-template-columns: 1fr; text-align: center; }
  .footer-contact li, .footer-col ul { justify-items: center; }
  .footer-contact li { justify-content: center; }
  .social-links { justify-content: center; }
}
