/* ================================================
   CLÍNICA DENTAL PASCUAL-GIL  |  styles.css v2.0
   ================================================ */

/* === VARIABLES === */
:root {
  --navy:       #1B3A5C;
  --navy-dark:  #0F2340;
  --navy-light: #2A5080;
  --gold:       #C9A96E;
  --gold-light: #DFC08A;
  --gold-dark:  #A8854A;
  --teal:       #4A90A4;
  --light:      #F8F9FA;
  --light-2:    #EEF2F7;
  --text:       #2D3748;
  --text-light: #718096;
  --white:      #FFFFFF;
  --border:     #E2E8F0;
  --green:      #38A169;

  --font-heading: 'Playfair Display', Georgia, serif;
  --font-body:    'Inter', system-ui, -apple-system, sans-serif;

  --shadow-sm: 0 2px 8px rgba(27,58,92,.08);
  --shadow-md: 0 8px 24px rgba(27,58,92,.12);
  --shadow-lg: 0 20px 60px rgba(27,58,92,.16);
  --shadow-xl: 0 32px 80px rgba(27,58,92,.20);

  --radius-sm: 8px;
  --radius:    12px;
  --radius-lg: 20px;
  --radius-xl: 32px;

  --transition:      0.3s ease;
  --transition-slow: 0.5s ease;

  --container:  1200px;
  --navbar-h:   80px;
}

/* === RESET === */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body { font-family: var(--font-body); color: var(--text); background: var(--white); line-height: 1.6; overflow-x: hidden; }
img  { max-width: 100%; height: auto; display: block; }
a    { color: inherit; text-decoration: none; transition: color var(--transition); }
ul   { list-style: none; }

/* === TIPOGRAFÍA === */
h1, h2, h3, h4, h5 { font-family: var(--font-heading); line-height: 1.2; color: var(--navy); }
h1 { font-size: clamp(2.4rem, 5vw, 3.8rem); font-weight: 700; }
h2 { font-size: clamp(1.9rem, 4vw, 2.8rem); font-weight: 600; }
h3 { font-size: clamp(1.3rem, 3vw, 1.7rem); font-weight: 600; }
h4 { font-size: 1.1rem; font-weight: 600; }
p  { color: var(--text-light); line-height: 1.8; }

/* === UTILIDADES === */
.container   { max-width: var(--container); margin: 0 auto; padding: 0 24px; }
.section     { padding: 100px 0; }
.section-sm  { padding: 60px 0; }
.text-center { text-align: center; }
.text-white  { color: var(--white) !important; }
.text-gold   { color: var(--gold) !important; }
.bg-light    { background: var(--light); }
.bg-navy     { background: var(--navy); }

.section-header { text-align: center; max-width: 680px; margin: 0 auto 64px; }
.section-tag    {
  display: inline-block; color: var(--gold); font-size: .82rem;
  font-weight: 600; letter-spacing: 2.5px; text-transform: uppercase; margin-bottom: 12px;
}
.section-header h2 { margin-bottom: 16px; }
.section-header p  { font-size: 1.05rem; }

/* === BOTONES === */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 13px 30px; border-radius: 50px;
  font-family: var(--font-body); font-size: .92rem; font-weight: 600;
  cursor: pointer; border: 2px solid transparent;
  transition: all var(--transition); text-decoration: none; white-space: nowrap;
}
.btn-primary { background: var(--navy); color: var(--white); border-color: var(--navy); }
.btn-primary:hover { background: var(--navy-dark); transform: translateY(-2px); box-shadow: var(--shadow-md); }

.btn-gold { background: var(--gold); color: var(--white); border-color: var(--gold); }
.btn-gold:hover { background: var(--gold-dark); border-color: var(--gold-dark); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(201,169,110,.4); }

.btn-outline { background: transparent; color: var(--navy); border-color: var(--navy); }
.btn-outline:hover { background: var(--navy); color: var(--white); transform: translateY(-2px); }

.btn-outline-white { background: transparent; color: var(--white); border-color: rgba(255,255,255,.6); }
.btn-outline-white:hover { background: var(--white); color: var(--navy); border-color: var(--white); transform: translateY(-2px); }

.btn-lg { padding: 17px 42px; font-size: 1rem; }
.btn-sm { padding: 9px 20px; font-size: .85rem; }
.btn-block { width: 100%; justify-content: center; }

/* === NAVBAR === */
.navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  height: var(--navbar-h); transition: all var(--transition);
}
.navbar.transparent  { background: transparent; }
.navbar.scrolled     { background: rgba(255,255,255,.97); backdrop-filter: blur(12px); box-shadow: var(--shadow-sm); }

.navbar.transparent .logo-text { color: var(--white); }
.navbar.transparent .logo-sub  { color: rgba(255,255,255,.6); }
.navbar.transparent .nav-links > li > a { color: rgba(255,255,255,.9); }
.navbar.transparent .hamburger span { background: var(--white); }

.navbar.scrolled .logo-text    { color: var(--navy); }
.navbar.scrolled .logo-sub     { color: var(--text-light); }
.navbar.scrolled .nav-links > li > a { color: var(--text); }
.navbar.scrolled .hamburger span { background: var(--navy); }

.nav-container {
  max-width: var(--container); margin: 0 auto; padding: 0 24px;
  height: 100%; display: flex; align-items: center; gap: 4px;
}
.nav-logo          { display: flex; flex-direction: column; text-decoration: none; margin-right: auto; }
.logo-text         { font-family: var(--font-heading); font-size: 2.1rem; font-weight: 700; line-height: 1; transition: color var(--transition); }
.logo-accent       { color: var(--gold); }
.logo-sub          { font-size: .68rem; letter-spacing: 2.5px; text-transform: uppercase; transition: color var(--transition); }

.nav-links         { display: flex; align-items: center; gap: 2px; }
.nav-links > li > a {
  display: block; padding: 8px 12px; font-size: .88rem; font-weight: 500;
  border-radius: var(--radius-sm); transition: all var(--transition);
}
.nav-links > li > a:hover { background: rgba(27,58,92,.08); color: var(--navy) !important; }
.navbar.transparent .nav-links > li > a:hover { background: rgba(255,255,255,.15); color: var(--white) !important; }

/* Dropdown */
.dropdown { position: relative; }
/* Invisible bridge above the menu so moving mouse from nav item to dropdown
   doesn't lose hover state (the ::before covers the visual gap) */
.dropdown-menu {
  position: absolute; top: 100%; left: 50%;
  transform: translateX(-50%) translateY(6px);
  background: var(--white); border-radius: var(--radius);
  box-shadow: var(--shadow-lg); padding: 8px; min-width: 210px;
  opacity: 0; visibility: hidden; pointer-events: none;
  transition: opacity .2s ease, visibility .2s ease, transform .2s ease;
}
.dropdown-menu::before {
  content: ''; position: absolute; top: -12px; left: 0; right: 0; height: 12px;
}
.dropdown:hover .dropdown-menu {
  opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0); pointer-events: all;
}
.dropdown-menu li a {
  display: block; padding: 9px 14px; color: var(--text); font-size: .88rem;
  border-radius: var(--radius-sm); transition: all var(--transition);
}
.dropdown-menu li a:hover { background: var(--light); color: var(--navy); padding-left: 18px; }

.nav-cta { margin-left: 12px; flex-shrink: 0; }

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

/* === HERO (portada) === */
.hero {
  position: relative; height: 100vh; min-height: 600px;
  display: flex; align-items: center; justify-content: center; overflow: hidden;
}
.hero-bg {
  position: absolute; inset: 0; background-size: cover; background-position: center;
  will-change: transform;
}
.hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(11,30,55,.88) 0%, rgba(27,58,92,.72) 55%, rgba(74,144,164,.45) 100%);
}
.hero-content {
  position: relative; z-index: 2; text-align: center;
  color: var(--white); max-width: 820px; padding: 0 24px;
}
.hero-eyebrow {
  color: var(--gold-light); font-size: .82rem; font-weight: 500;
  letter-spacing: 3px; text-transform: uppercase; margin-bottom: 20px;
  opacity: 0; animation: fadeInUp .8s ease .2s forwards;
}
.hero-content h1 {
  color: var(--white); margin-bottom: 24px;
  opacity: 0; animation: fadeInUp .8s ease .4s forwards;
}
.hero-content h1 em { font-style: italic; color: var(--gold-light); }
.hero-sub {
  color: rgba(255,255,255,.85); font-size: 1.1rem; margin-bottom: 40px; line-height: 1.7;
  opacity: 0; animation: fadeInUp .8s ease .6s forwards;
}
.hero-actions {
  display: flex; gap: 16px; justify-content: center; flex-wrap: wrap;
  opacity: 0; animation: fadeInUp .8s ease .8s forwards;
}
.hero-scroll {
  position: absolute; bottom: 36px; left: 0; right: 0;
  z-index: 2; display: flex; flex-direction: column; align-items: center; gap: 8px;
  color: rgba(255,255,255,.55); font-size: .68rem; letter-spacing: 2.5px; text-transform: uppercase;
  opacity: 0; animation: fadeInUp 1s ease 1.1s forwards;
  pointer-events: none;
}
.scroll-line {
  width: 1px; height: 40px;
  background: linear-gradient(to bottom, rgba(255,255,255,.55), transparent);
  animation: scrollPulse 1.6s ease infinite;
}
@keyframes scrollPulse { 0%,100%{opacity:1;transform:scaleY(1)} 50%{opacity:.3;transform:scaleY(.5)} }

/* === PAGE HERO (páginas interiores) === */
.page-hero {
  position: relative; min-height: 360px;
  display: flex; align-items: flex-end; padding-bottom: 64px;
  padding-top: var(--navbar-h); overflow: hidden;
}
.page-hero-bg   { position: absolute; inset: 0; background-size: cover; background-position: center; }
.page-hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(11,30,55,.92), rgba(42,80,128,.70));
}
.page-hero-content {
  position: relative; z-index: 2; color: var(--white);
  max-width: var(--container); margin: 0 auto; width: 100%; padding: 0 24px;
}
.breadcrumb {
  display: flex; align-items: center; gap: 8px;
  color: rgba(255,255,255,.55); font-size: .82rem; margin-bottom: 16px;
}
.breadcrumb a       { color: rgba(255,255,255,.55); }
.breadcrumb a:hover { color: var(--gold-light); }
.breadcrumb-sep     { color: rgba(255,255,255,.3); }
.page-hero-content h1 { color: var(--white); font-size: clamp(1.9rem,4vw,2.8rem); margin-bottom: 10px; }
.page-hero-content .lead { color: rgba(255,255,255,.78); font-size: 1.05rem; max-width: 540px; }

/* === STATS === */
.stats-bar   { background: var(--navy); padding: 52px 0; }
.stats-grid  { display: grid; grid-template-columns: repeat(4,1fr); gap: 24px; }
.stat-item   { text-align: center; display: flex; flex-direction: column; align-items: center; }
.stat-row    { display: flex; align-items: baseline; gap: 2px; }
.stat-num    { font-family: var(--font-heading); font-size: 3rem; font-weight: 700; color: var(--gold-light); line-height: 1; }
.stat-suffix { font-family: var(--font-heading); font-size: 2rem; color: var(--gold-light); }
.stat-label  { font-size: .82rem; color: rgba(255,255,255,.6); margin-top: 8px; letter-spacing: .3px; }

/* === SERVICES GRID === */
.services-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 26px; }
.service-card  {
  background: var(--white); border-radius: var(--radius-lg); padding: 38px 30px;
  box-shadow: var(--shadow-sm); border: 1px solid var(--border);
  transition: all var(--transition); position: relative; overflow: hidden;
}
.service-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--navy), var(--gold));
  transform: scaleX(0); transform-origin: left; transition: transform var(--transition);
}
.service-card:hover { transform: translateY(-8px); box-shadow: var(--shadow-lg); border-color: transparent; }
.service-card:hover::before { transform: scaleX(1); }

.service-icon { width: 60px; height: 60px; background: var(--light-2); border-radius: var(--radius); display: flex; align-items: center; justify-content: center; margin-bottom: 22px; transition: all var(--transition); }
.service-icon svg { width: 28px; height: 28px; color: var(--navy); transition: color var(--transition); }
.service-card:hover .service-icon { background: var(--navy); }
.service-card:hover .service-icon svg { color: var(--gold-light); }

.service-card h3 { font-size: 1.2rem; margin-bottom: 10px; }
.service-card p  { font-size: .88rem; margin-bottom: 18px; line-height: 1.7; }
.service-link    { display: inline-flex; align-items: center; gap: 6px; color: var(--navy); font-size: .88rem; font-weight: 600; transition: all var(--transition); }
.service-card:hover .service-link { gap: 10px; color: var(--gold-dark); }

/* === PILLARS === */
.pillars-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 28px; }
.pillar {
  text-align: center; padding: 44px 28px;
  background: var(--white); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm); transition: all var(--transition);
}
.pillar:hover { box-shadow: var(--shadow-md); transform: translateY(-4px); }
.pillar-icon {
  width: 76px; height: 76px; border-radius: 50%;
  background: linear-gradient(135deg, var(--navy), var(--navy-light));
  display: flex; align-items: center; justify-content: center; margin: 0 auto 22px;
}
.pillar-icon svg { width: 34px; height: 34px; color: var(--gold-light); }
.pillar h3 { margin-bottom: 14px; font-size: 1.3rem; }

/* === TEAM === */
.team-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 24px; }
.team-card {
  background: var(--white); border-radius: var(--radius-lg); overflow: hidden;
  box-shadow: var(--shadow-sm); border: 1px solid var(--border); transition: all var(--transition);
}
.team-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.team-photo          { position: relative; height: 270px; overflow: hidden; }
.team-photo img      { width: 100%; height: 100%; object-fit: cover; object-position: top center; transition: transform var(--transition-slow); }
.team-card:hover .team-photo img { transform: scale(1.06); }
.team-overlay        { position: absolute; inset: 0; background: linear-gradient(to top, rgba(11,30,55,.85), transparent 55%); opacity: 0; transition: opacity var(--transition); }
.team-card:hover .team-overlay { opacity: 1; }
.team-info           { padding: 18px 22px 22px; }
.team-info h4        { font-size: .98rem; margin-bottom: 4px; }
.team-specialty      { color: var(--gold); font-size: .75rem; font-weight: 600; letter-spacing: .8px; text-transform: uppercase; }
.team-degree         { color: var(--text-light); font-size: .78rem; margin-top: 8px; line-height: 1.5; }

/* === GALLERY === */
.gallery-grid { display: grid; grid-template-columns: repeat(4,1fr); grid-auto-rows: 190px; gap: 10px; }
.gallery-item {
  position: relative; overflow: hidden; border-radius: var(--radius-sm);
  cursor: pointer; background: var(--light-2);
}
.gallery-item img { width: 100%; height: 100%; object-fit: cover; transition: transform var(--transition-slow); }
.gallery-item:hover img { transform: scale(1.08); }
.gallery-overlay {
  position: absolute; inset: 0; background: rgba(27,58,92,.45);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; transition: opacity var(--transition);
}
.gallery-item:hover .gallery-overlay { opacity: 1; }
.gallery-icon {
  width: 44px; height: 44px; border-radius: 50%;
  background: rgba(255,255,255,.9); display: flex; align-items: center; justify-content: center; color: var(--navy);
}

/* === LIGHTBOX === */
.lightbox {
  position: fixed; inset: 0; z-index: 9999; background: rgba(0,0,0,.96);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; visibility: hidden; transition: all var(--transition);
}
.lightbox.active { opacity: 1; visibility: visible; }
.lightbox-img { max-width: 90vw; max-height: 85vh; object-fit: contain; border-radius: var(--radius); }
.lightbox-close, .lightbox-prev, .lightbox-next {
  position: absolute; background: rgba(255,255,255,.12); border: none;
  border-radius: 50%; cursor: pointer; display: flex; align-items: center; justify-content: center;
  color: var(--white); transition: background var(--transition);
}
.lightbox-close { top: 20px; right: 20px; width: 44px; height: 44px; font-size: 1.3rem; }
.lightbox-prev  { top: 50%; left: 20px; transform: translateY(-50%); width: 52px; height: 52px; font-size: 1.6rem; }
.lightbox-next  { top: 50%; right: 20px; transform: translateY(-50%); width: 52px; height: 52px; font-size: 1.6rem; }
.lightbox-close:hover, .lightbox-prev:hover, .lightbox-next:hover { background: rgba(255,255,255,.22); }
.lightbox-counter {
  position: absolute; bottom: 24px; left: 50%; transform: translateX(-50%);
  color: rgba(255,255,255,.7); font-size: .82rem; letter-spacing: 1.5px;
  font-weight: 500; padding: 6px 14px; background: rgba(255,255,255,.08);
  border-radius: 50px;
}

/* === CTA SECTION === */
.cta-section {
  background: linear-gradient(135deg, var(--navy-dark) 0%, var(--navy) 60%, var(--navy-light) 100%);
  padding: 100px 0; position: relative; overflow: hidden;
}
.cta-section::before {
  content: ''; position: absolute; top: -40%; right: -8%; width: 480px; height: 480px;
  background: radial-gradient(circle, rgba(201,169,110,.18), transparent 70%); pointer-events: none;
}
.cta-section::after {
  content: ''; position: absolute; bottom: -40%; left: -5%; width: 360px; height: 360px;
  background: radial-gradient(circle, rgba(74,144,164,.15), transparent 70%); pointer-events: none;
}
.cta-inner { text-align: center; color: var(--white); position: relative; }
.cta-inner h2 { color: var(--white); margin-bottom: 14px; }
.cta-inner > p { color: rgba(255,255,255,.72); font-size: 1.08rem; margin-bottom: 36px; max-width: 560px; margin-left: auto; margin-right: auto; }
.cta-actions { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }
.cta-phone {
  display: flex; align-items: center; gap: 10px;
  padding: 13px 24px; border-radius: 50px;
  background: rgba(255,255,255,.1); color: var(--white);
  font-weight: 600; font-size: .92rem; border: 2px solid rgba(255,255,255,.25);
  transition: all var(--transition);
}
.cta-phone:hover { background: rgba(255,255,255,.18); border-color: rgba(255,255,255,.45); }
.cta-phone svg { width: 18px; height: 18px; }

/* === CONTACT === */
.contact-grid { display: grid; grid-template-columns: 1fr 1.6fr; gap: 64px; align-items: start; }
.contact-info-title { font-size: 1.5rem; margin-bottom: 28px; }
.contact-item { display: flex; gap: 16px; margin-bottom: 26px; }
.contact-item-icon {
  width: 46px; height: 46px; background: var(--light-2); border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0; color: var(--navy);
}
.contact-item-icon svg { width: 20px; height: 20px; }
.contact-item-text strong {
  display: block; color: var(--navy); font-size: .75rem; font-weight: 600;
  letter-spacing: 1.2px; text-transform: uppercase; margin-bottom: 4px;
}
.contact-item-text a { color: var(--text-light); }
.contact-item-text a:hover { color: var(--navy); }
.map-embed { margin-top: 28px; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-md); }
.map-embed iframe { display: block; width: 100%; height: 240px; border: 0; }

/* === FORMULARIO === */
.form-card    { background: var(--light); border-radius: var(--radius-lg); padding: 40px; }
.form-title   { font-size: 1.5rem; margin-bottom: 24px; }
.form-group   { margin-bottom: 18px; }
.form-row     { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-group label {
  display: block; font-size: .82rem; font-weight: 600; color: var(--navy); margin-bottom: 6px;
}
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%; padding: 11px 14px; border: 2px solid var(--border);
  border-radius: var(--radius-sm); font-family: var(--font-body); font-size: .92rem;
  color: var(--text); background: var(--white); transition: border-color var(--transition); outline: none;
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus { border-color: var(--navy); }
.form-group textarea { resize: vertical; min-height: 110px; }
.form-consent { display: flex; align-items: flex-start; gap: 10px; margin-bottom: 22px; }
.form-consent input[type="checkbox"] { width: auto; flex-shrink: 0; margin-top: 3px; accent-color: var(--navy); }
.form-consent label { font-size: .78rem; color: var(--text-light); line-height: 1.5; margin: 0; }
.form-consent a { color: var(--navy); text-decoration: underline; }

/* === FOOTER === */
.footer { background: var(--navy-dark); color: rgba(255,255,255,.65); padding: 80px 0 32px; }
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1.5fr; gap: 48px;
  padding-bottom: 48px; border-bottom: 1px solid rgba(255,255,255,.08); margin-bottom: 28px;
}
.footer-brand .logo-text { color: var(--white); font-size: 1.8rem; }

/* Sidebar specialist photo */
.sidebar-specialist-wrap { display: flex; align-items: center; gap: 14px; margin-bottom: 12px; }
.sidebar-specialist-photo { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; object-position: top center; border: 2px solid var(--gold); flex-shrink: 0; }
.sidebar-specialist-info .specialist-name { font-size: .92rem; color: var(--navy); font-weight: 600; margin-bottom: 3px; }
.sidebar-specialist-info .specialist-detail { font-size: .78rem; color: var(--text-light); line-height: 1.45; }
.footer-brand .logo-sub  { color: rgba(255,255,255,.4); }
.footer-desc     { margin-top: 14px; font-size: .88rem; line-height: 1.7; color: rgba(255,255,255,.5); }
.footer-sanitary { margin-top: 14px; font-size: .72rem; color: rgba(255,255,255,.28); }
.footer-heading  { font-family: var(--font-heading); font-size: .98rem; color: var(--white); margin-bottom: 18px; }
.footer-links    { display: flex; flex-direction: column; gap: 9px; }
.footer-links a  { font-size: .88rem; color: rgba(255,255,255,.5); transition: color var(--transition); }
.footer-links a:hover { color: var(--gold-light); }

.footer-contact-item { display: flex; gap: 10px; margin-bottom: 12px; font-size: .88rem; color: rgba(255,255,255,.55); }
.footer-contact-item svg { width: 15px; height: 15px; color: var(--gold); flex-shrink: 0; margin-top: 3px; }

.footer-bottom {
  display: flex; align-items: center; justify-content: space-between;
  font-size: .78rem; color: rgba(255,255,255,.3); flex-wrap: wrap; gap: 10px;
}
.footer-legal a { color: rgba(255,255,255,.3); text-decoration: underline; }
.footer-legal a:hover { color: rgba(255,255,255,.6); }

/* === FOOTER BANNER (Kit Digital) === */
.footer-banner {
  border-top: 1px solid rgba(255,255,255,.08);
  margin-top: 28px;
  padding-top: 28px;
  margin-bottom: 24px;
  text-align: center;
}
.footer-banner-name {
  font-size: .78rem;
  color: rgba(255,255,255,.55);
  letter-spacing: 1.6px;
  font-weight: 600;
  text-transform: uppercase;
  margin-bottom: 14px;
}
.footer-banner-img {
  display: inline-block;
  max-width: 100%;
  background: var(--white);
  padding: 12px 18px;
  border-radius: var(--radius-sm);
}
.footer-banner-img img {
  display: block;
  max-width: 720px;
  width: 100%;
  height: auto;
}
@media (max-width: 768px) {
  .footer-banner-img { padding: 10px 12px; }
  .footer-banner-name { font-size: .72rem; letter-spacing: 1.2px; }
}

/* === SCROLL TO TOP BUTTON === */
.scroll-top-btn {
  position: fixed; bottom: 28px; left: 28px; z-index: 500;
  width: 46px; height: 46px; border-radius: 50%;
  background: var(--navy); color: var(--white); border: none;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow-md);
  opacity: 0; visibility: hidden; transform: translateY(12px);
  transition: opacity .3s, transform .3s, visibility .3s, background .2s;
}
.scroll-top-btn.visible { opacity: 1; visibility: visible; transform: translateY(0); }
.scroll-top-btn:hover  { background: var(--gold-dark); transform: translateY(-3px); }
.scroll-top-btn svg    { width: 22px; height: 22px; stroke: currentColor; fill: none; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
@media (max-width: 768px) {
  .scroll-top-btn { bottom: 16px; left: 16px; width: 42px; height: 42px; }
  .scroll-top-btn svg { width: 19px; height: 19px; }
}

/* === FLOATING BUTTONS === */
.float-cta { position: fixed; bottom: 28px; right: 28px; z-index: 500; display: flex; flex-direction: column; gap: 10px; align-items: flex-end; }
.float-btn {
  display: flex; align-items: center; gap: 9px; padding: 11px 18px;
  border-radius: 50px; font-size: .88rem; font-weight: 600;
  cursor: pointer; border: none; box-shadow: var(--shadow-md); transition: all var(--transition); text-decoration: none;
}
.float-btn-phone     { background: var(--navy); color: var(--white); }
.float-btn-whatsapp  { background: #25D366; color: var(--white); }
.float-btn:hover     { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.float-btn svg       { width: 18px; height: 18px; flex-shrink: 0; }

/* === FAQ === */
.faq { display: flex; flex-direction: column; gap: 10px; }
.faq-item { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.faq-question {
  width: 100%; background: none; border: none; cursor: pointer; padding: 18px 22px;
  display: flex; align-items: center; justify-content: space-between; text-align: left;
  font-family: var(--font-body); font-size: .95rem; font-weight: 600; color: var(--navy); transition: background var(--transition);
}
.faq-question:hover { background: var(--light); }
.faq-icon { width: 22px; height: 22px; border-radius: 50%; background: var(--light-2); display: flex; align-items: center; justify-content: center; flex-shrink: 0; transition: all var(--transition); }
.faq-icon svg { transition: transform var(--transition); }
.faq-item.open .faq-icon { background: var(--navy); }
.faq-item.open .faq-icon svg { transform: rotate(45deg); fill: var(--white); }
.faq-answer { max-height: 0; overflow: hidden; transition: max-height .4s ease; }
.faq-answer-inner { padding: 4px 22px 18px; color: var(--text-light); line-height: 1.75; font-size: .92rem; }

/* === TREATMENT DETAIL === */
.treatment-layout { display: grid; grid-template-columns: 1fr 300px; gap: 56px; align-items: start; }
.treatment-content h2 { font-size: 1.7rem; margin: 44px 0 18px; }
.treatment-content h2:first-child { margin-top: 0; }
.treatment-content p  { margin-bottom: 14px; }

.treatment-steps { display: flex; flex-direction: column; gap: 16px; margin: 22px 0; }
.treatment-step  { display: flex; gap: 14px; padding: 18px; background: var(--light); border-radius: var(--radius); align-items: flex-start; }
.step-num        { width: 32px; height: 32px; background: var(--navy); color: var(--white); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: .8rem; flex-shrink: 0; }
.step-content strong { display: block; color: var(--navy); margin-bottom: 4px; font-size: .92rem; }
.step-content p  { font-size: .88rem; margin: 0; }

.treatment-sidebar { position: sticky; top: calc(var(--navbar-h) + 20px); }
.sidebar-card      { background: var(--light); border-radius: var(--radius-lg); padding: 28px; margin-bottom: 20px; }
.sidebar-cta       { background: var(--navy); color: var(--white); text-align: center; }
.sidebar-cta h4    { color: var(--white); margin-bottom: 10px; }
.sidebar-cta p     { color: rgba(255,255,255,.7); font-size: .88rem; margin-bottom: 18px; }
.sidebar-card h4   { margin-bottom: 14px; font-size: 1rem; }
.sidebar-links     { display: flex; flex-direction: column; gap: 8px; }
.sidebar-links a   { font-size: .88rem; color: var(--navy); display: flex; align-items: center; gap: 6px; transition: gap var(--transition); }
.sidebar-links a:hover { gap: 10px; color: var(--gold-dark); }

.highlight-box     { background: linear-gradient(135deg, var(--navy), var(--navy-light)); color: var(--white); border-radius: var(--radius-lg); padding: 36px; margin: 36px 0; }
.highlight-box h3  { color: var(--white); margin-bottom: 10px; font-size: 1.3rem; }
.highlight-box p   { color: rgba(255,255,255,.78); }

.benefits-list  { display: flex; flex-direction: column; gap: 12px; margin: 20px 0; }
.benefit-item   { display: flex; gap: 12px; align-items: flex-start; }
.benefit-check  {
  width: 22px; height: 22px; background: var(--gold); border-radius: 50%;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0; color: var(--white); margin-top: 2px;
}
.benefit-check svg { width: 12px; height: 12px; }
.benefit-item p { margin: 0; font-size: .92rem; }

/* === PACIENTES === */
.recursos-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 24px; }
.recurso-card {
  background: var(--white); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 28px; transition: all var(--transition); display: flex; flex-direction: column; gap: 12px;
}
.recurso-card:hover { box-shadow: var(--shadow-md); transform: translateY(-4px); border-color: transparent; }
.recurso-icon { width: 48px; height: 48px; background: var(--light-2); border-radius: var(--radius); display: flex; align-items: center; justify-content: center; color: var(--navy); }
.recurso-icon svg { width: 22px; height: 22px; }
.recurso-card h4 { font-size: .95rem; }
.recurso-card p  { font-size: .85rem; flex: 1; }

/* === SCROLL REVEAL === */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .7s ease, transform .7s ease; }
.reveal.revealed { opacity: 1; transform: translateY(0); }
.reveal-delay-1 { transition-delay: .1s; }
.reveal-delay-2 { transition-delay: .2s; }
.reveal-delay-3 { transition-delay: .3s; }
.reveal-delay-4 { transition-delay: .4s; }
.reveal-delay-5 { transition-delay: .5s; }
.reveal-delay-6 { transition-delay: .6s; }

/* === ANIMACIONES === */
@keyframes fadeInUp { from{opacity:0;transform:translateY(24px)} to{opacity:1;transform:translateY(0)} }
@keyframes fadeIn   { from{opacity:0} to{opacity:1} }

/* === PAGE LOAD FADE === */
@keyframes pageFadeIn { from { opacity: 0; } to { opacity: 1; } }
body { animation: pageFadeIn .4s ease; }

/* === HERO STAGGERED REVEAL === */
@keyframes heroSlideUp {
  from { opacity: 0; transform: translateY(36px); }
  to   { opacity: 1; transform: translateY(0); }
}
.page-home .hero-eyebrow { animation: heroSlideUp .8s cubic-bezier(.16,1,.3,1) .1s both; }
.page-home .hero-content h1 { animation: heroSlideUp .9s cubic-bezier(.16,1,.3,1) .25s both; }
.page-home .hero-sub { animation: heroSlideUp .9s cubic-bezier(.16,1,.3,1) .45s both; }
.page-home .hero-actions { animation: heroSlideUp .9s cubic-bezier(.16,1,.3,1) .62s both; }

/* Inner page hero stagger */
.page-hero-content .breadcrumb { animation: heroSlideUp .7s cubic-bezier(.16,1,.3,1) .1s both; }
.page-hero-content h1 { animation: heroSlideUp .85s cubic-bezier(.16,1,.3,1) .25s both; }
.page-hero-content .lead { animation: heroSlideUp .85s cubic-bezier(.16,1,.3,1) .4s both; }

/* === SECTION TAG SHIMMER === */
@keyframes shimmer {
  0%   { background-position: -200% center; }
  100% { background-position: 200% center; }
}
.section-tag {
  background: linear-gradient(90deg, var(--gold-dark) 0%, var(--gold-light) 40%, var(--gold) 60%, var(--gold-dark) 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: shimmer 5s linear infinite;
  color: var(--gold); /* fallback */
}

/* === ANIMATED UNDERLINE ON SECTION HEADERS === */
.section-header h2 { position: relative; }
.section-header h2::after {
  content: ''; display: block;
  width: 52px; height: 3px;
  background: linear-gradient(90deg, var(--gold), var(--gold-light));
  border-radius: 2px; margin: 16px auto 0;
  transform: scaleX(0); transform-origin: center;
  transition: transform .7s cubic-bezier(.16,1,.3,1) .25s;
}
.section-header.revealed h2::after { transform: scaleX(1); }

/* === SCROLL PROGRESS BAR === */
#scroll-progress {
  position: fixed; top: 0; left: 0; height: 3px;
  background: linear-gradient(90deg, var(--gold-dark), var(--gold-light));
  width: 0%; z-index: 9999; pointer-events: none;
  transition: width .08s linear;
}

/* === 3D CARD TILT BASE === */
.service-card { will-change: transform; }

/* === DIVISOR DECORATIVO === */
.divider { display: flex; align-items: center; gap: 16px; margin: 32px 0; }
.divider::before, .divider::after { content:''; flex:1; height:1px; background: var(--border); }
.divider span { color: var(--gold); font-size: .8rem; letter-spacing: 2px; text-transform: uppercase; font-weight: 600; white-space: nowrap; }

/* === ALERT / NOTICE === */
.notice { background: var(--light-2); border-left: 4px solid var(--gold); border-radius: var(--radius-sm); padding: 16px 20px; margin: 20px 0; }
.notice p { color: var(--text); font-size: .9rem; margin: 0; }

/* === MOBILE SCROLL ZOOM (Ken Burns ligado a scroll) === */
@media (max-width: 767px) {
  .mobile-zoom-img,
  .team-detail-photo img {
    will-change: transform;
    transform-origin: center center;
    backface-visibility: hidden;
  }
}

/* === RESPONSIVE === */
@media (max-width: 1024px) {
  .services-grid { grid-template-columns: repeat(2,1fr); }
  .team-grid     { grid-template-columns: repeat(2,1fr); }
  .gallery-grid  { grid-template-columns: repeat(3,1fr); }
  .footer-grid   { grid-template-columns: 1fr 1fr; }
  .treatment-layout { grid-template-columns: 1fr; }
  .treatment-sidebar { position: static; }
  .stats-grid    { grid-template-columns: repeat(2,1fr); }
  .recursos-grid { grid-template-columns: repeat(2,1fr); }
}

@media (max-width: 768px) {
  :root { --navbar-h: 68px; }
  .section { padding: 68px 0; }

  .hamburger  { display: flex; }
  .nav-links  {
    position: fixed; top: var(--navbar-h); left: 0; right: 0; background: var(--white);
    flex-direction: column; align-items: stretch; padding: 12px; gap: 2px;
    box-shadow: var(--shadow-lg); transform: translateY(-110%); opacity: 0; pointer-events: none;
    transition: all var(--transition); max-height: calc(100vh - var(--navbar-h)); overflow-y: auto;
    z-index: 999;
  }
  .nav-links.open { transform: translateY(0); opacity: 1; pointer-events: all; }
  /* forzar texto oscuro en móvil siempre, independientemente del estado del navbar */
  .nav-links > li > a,
  .navbar.transparent .nav-links > li > a,
  .navbar.scrolled   .nav-links > li > a { color: var(--navy) !important; padding: 11px 14px; font-size: .95rem; }
  /* hover/focus en móvil: mantener navy sobre fondo claro (no blanco sobre blanco) */
  .nav-links > li > a:hover,
  .nav-links > li > a:focus,
  .navbar.transparent .nav-links > li > a:hover,
  .navbar.transparent .nav-links > li > a:focus,
  .navbar.scrolled   .nav-links > li > a:hover,
  .navbar.scrolled   .nav-links > li > a:focus {
    color: var(--navy) !important;
    background: rgba(27,58,92,.08) !important;
  }
  .dropdown-menu li a:hover,
  .dropdown-menu li a:focus { color: var(--navy) !important; background: var(--white) !important; }
  /* submenú móvil */
  .dropdown-menu {
    position: static !important; transform: none !important; box-shadow: none;
    background: var(--light); margin-top: 4px; border-radius: var(--radius-sm);
    opacity: 1 !important; visibility: visible !important; display: none !important;
    pointer-events: all; min-width: auto; transition: none;
  }
  .dropdown.open > .dropdown-menu { display: block !important; }
  .dropdown:hover .dropdown-menu { display: none !important; }   /* desactivar hover en móvil */
  .dropdown.open:hover > .dropdown-menu { display: block !important; }
  .nav-cta { display: none; }

  .pillars-grid { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; gap: 36px; }
  .footer-grid  { grid-template-columns: 1fr; gap: 28px; }
  .hero-actions { flex-direction: column; align-items: center; }
  .form-row     { grid-template-columns: 1fr; }
  .cta-actions  { flex-direction: column; align-items: center; }

  .float-cta { bottom: 16px; right: 16px; }
  .float-btn span { display: none; }
  .float-btn  { width: 52px; height: 52px; padding: 0; border-radius: 50%; justify-content: center; }

  .footer-bottom { flex-direction: column; text-align: center; }
  .gallery-grid  { grid-template-columns: repeat(2,1fr); }

  .form-card { padding: 24px; }
}

@media (max-width: 480px) {
  .team-grid  { grid-template-columns: 1fr; }
  .services-grid { grid-template-columns: 1fr; }
  .gallery-grid  { grid-template-columns: 1fr; }
  .recursos-grid { grid-template-columns: 1fr; }
  .stats-grid    { grid-template-columns: 1fr 1fr; }
}

/* ===================== COOKIE BANNER ===================== */
#cookie-banner {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  background: var(--navy-dark);
  color: var(--white);
  padding: 20px 32px;
  z-index: 10000;
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
  box-shadow: 0 -4px 24px rgba(0,0,0,.3);
  transform: translateY(0);
  transition: transform .4s cubic-bezier(.16,1,.3,1), opacity .4s ease;
  border-top: 2px solid var(--gold);
}
#cookie-banner.hide {
  transform: translateY(110%);
  opacity: 0;
  pointer-events: none;
}
.cookie-text {
  flex: 1;
  min-width: 260px;
  font-size: .88rem;
  line-height: 1.5;
  color: rgba(255,255,255,.88);
}
.cookie-text strong { color: var(--gold-light); }
.cookie-text a { color: var(--gold-light); text-decoration: underline; }
.cookie-text a:hover { color: var(--white); }
.cookie-actions {
  display: flex;
  gap: 12px;
  flex-shrink: 0;
  flex-wrap: wrap;
}
.cookie-btn {
  padding: 10px 22px;
  border-radius: var(--radius-sm);
  font-size: .85rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all var(--transition);
  line-height: 1;
}
.cookie-btn-accept {
  background: var(--gold);
  color: var(--navy-dark);
}
.cookie-btn-accept:hover { background: var(--gold-light); }
.cookie-btn-reject {
  background: transparent;
  color: rgba(255,255,255,.7);
  border: 1px solid rgba(255,255,255,.3);
}
.cookie-btn-reject:hover {
  background: rgba(255,255,255,.08);
  color: var(--white);
}
.cookie-btn-settings {
  background: transparent;
  color: rgba(255,255,255,.55);
  font-size: .78rem;
  padding: 8px 14px;
  border: 1px solid rgba(255,255,255,.18);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.cookie-btn-settings:hover {
  background: rgba(255,255,255,.06);
  color: rgba(255,255,255,.8);
}
@media (max-width: 640px) {
  #cookie-banner {
    flex-direction: column;
    align-items: stretch;
    padding: 14px 16px;
    gap: 12px;
  }
  .cookie-text {
    min-width: unset;
    font-size: .83rem;
  }
  .cookie-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    width: 100%;
  }
  .cookie-btn-accept { order: 1; }
  .cookie-btn-reject { order: 2; }
  .cookie-btn-settings {
    grid-column: 1 / -1;
    order: 3;
    font-size: .76rem;
    padding: 8px;
    text-align: center;
  }
}

/* ===================== LEGAL PAGES ===================== */
.legal-content {
  max-width: 860px;
  margin: 0 auto;
}
.legal-content h2 {
  font-family: var(--font-heading);
  font-size: 1.45rem;
  color: var(--navy);
  margin: 40px 0 14px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--gold);
}
.legal-content h2:first-child { margin-top: 0; }
.legal-content h3 {
  font-size: 1.05rem;
  color: var(--navy);
  margin: 24px 0 8px;
}
.legal-content p {
  color: var(--text);
  margin-bottom: 14px;
  line-height: 1.75;
  font-size: .95rem;
}
.legal-content ul {
  list-style: none;
  padding: 0;
  margin-bottom: 16px;
}
.legal-content ul li {
  padding: 5px 0 5px 20px;
  position: relative;
  font-size: .94rem;
  color: var(--text);
  line-height: 1.6;
}
.legal-content ul li::before {
  content: '›';
  color: var(--gold);
  font-weight: 700;
  position: absolute;
  left: 4px;
}
.legal-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0;
  font-size: .88rem;
}
.legal-content table th {
  background: var(--navy);
  color: var(--white);
  padding: 10px 14px;
  text-align: left;
  font-weight: 600;
}
.legal-content table td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
  line-height: 1.5;
}
.legal-content table tr:nth-child(even) td { background: var(--light); }
.legal-info-box {
  background: var(--light-2);
  border-left: 3px solid var(--gold);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: 18px 22px;
  margin: 20px 0;
  font-size: .9rem;
}
.legal-info-box strong { color: var(--navy); }
