/* ================================================
   CLÍNICA CALMA — Immersive 3D World
   ================================================ */

html, body { background: #060d1a; overflow-x: hidden; }

/* Canvas 3D de fondo fijo */
#bg-canvas {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  pointer-events: none;
  z-index: 0;
}

/* Contenido encima del canvas */
main, footer {
  position: relative;
  z-index: 1;
}

/* ── Navbar — backdrop-filter en ::before para no romper hijos fixed (Safari) */
.navbar {
  background: transparent !important;
  border-bottom: 1px solid rgba(201,169,110,0.12) !important;
}
.navbar::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(6, 13, 26, 0.72);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  z-index: -1;
  pointer-events: none;
}
.navbar.scrolled::before {
  background: rgba(4, 9, 20, 0.88);
}

/* Overlay del menú móvil — fondo 100% opaco, cubre viewport completo */
@media (max-width: 768px) {
  .nav-links {
    background: #060d1a !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }
  /* iOS Safari: min-height para cubrir toda la pantalla */
  .nav-links.open {
    min-height: 100vh;
    min-height: -webkit-fill-available;
  }
}

/* ── Secciones → dark glass más transparente ─── */
/* Enough transparency that the 3D world shows through */
.bg-white,
.bg-hueso {
  background: rgba(6, 13, 26, 0.58) !important;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.bg-azul {
  background: rgba(8, 18, 36, 0.65) !important;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

/* index.html section classes */
.section-frosted {
  background: rgba(6, 13, 26, 0.58) !important;
  backdrop-filter: blur(8px) !important;
  -webkit-backdrop-filter: blur(8px) !important;
}
.section-frosted-dark,
.section-frosted-mid {
  background: rgba(8, 20, 40, 0.65) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
}

/* ── Hero stats bar ──────────────────────────── */
.hero-stats {
  background: rgba(12, 25, 50, 0.70) !important;
  backdrop-filter: blur(10px) !important;
}

/* ── Footer ──────────────────────────────────── */
.footer-main {
  background: rgba(3, 7, 16, 0.88) !important;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-top: 1px solid rgba(255,255,255,0.06) !important;
}
.footer-bottom {
  background: rgba(2, 4, 10, 0.95) !important;
}

/* ── Page headers ────────────────────────────── */
.page-header {
  background: rgba(6, 13, 26, 0.72) !important;
  backdrop-filter: blur(14px) !important;
  -webkit-backdrop-filter: blur(14px) !important;
}
.page-header h1,
.page-header .subtitle { color: var(--blanco) !important; }
.page-header .breadcrumbs a,
.page-header .breadcrumbs span { color: rgba(255,255,255,0.50) !important; }

/* ── Texto: secciones claras → blanco ────────── */
.bg-white h2, .bg-white h3, .bg-white h4,
.bg-hueso h2, .bg-hueso h3, .bg-hueso h4 {
  color: var(--blanco) !important;
}
.bg-white p, .bg-hueso p,
.bg-white li, .bg-hueso li {
  color: rgba(255,255,255,0.78) !important;
}
.bg-white .label, .bg-hueso .label { color: var(--dorado) !important; }
.bg-white .divider::before,
.bg-hueso .divider::before { background: var(--dorado) !important; }
.about-text h2 { color: var(--blanco) !important; }
.about-text .label { color: var(--dorado) !important; }
.about-text p { color: rgba(255,255,255,0.78) !important; }

/* ── Section header ──────────────────────────── */
.section-header h2 { color: var(--blanco) !important; }
.section-header p   { color: rgba(255,255,255,0.72) !important; }
.section-header .label { color: var(--dorado) !important; }

/* ── Cards — dark glass ──────────────────────── */
.service-card {
  background: rgba(12, 24, 48, 0.65) !important;
  border: 1px solid rgba(255,255,255,0.10) !important;
  backdrop-filter: blur(6px);
}
.service-card h3 { color: var(--blanco) !important; }
.service-card p   { color: rgba(255,255,255,0.72) !important; }
.service-card .card-link { color: var(--dorado) !important; }
.service-card .icon {
  background: rgba(201,169,110,0.15) !important;
  color: var(--dorado) !important;
}
.service-card .icon svg { stroke: var(--dorado); }
.service-card:hover {
  background: rgba(16, 32, 64, 0.80) !important;
  border-color: rgba(201,169,110,0.25) !important;
}

/* Team */
.team-card {
  background: rgba(12, 24, 48, 0.65) !important;
  border: 1px solid rgba(255,255,255,0.10) !important;
  backdrop-filter: blur(6px);
}
.team-card h3   { color: var(--blanco) !important; }
.team-card p    { color: rgba(255,255,255,0.70) !important; }
.team-card .role { color: var(--dorado) !important; }
.team-avatar { background: linear-gradient(135deg, rgba(201,169,110,0.85), rgba(107,158,120,0.85)) !important; color: var(--blanco) !important; }

/* Testimonios */
.testimonial-card {
  background: rgba(12, 24, 48, 0.65) !important;
  border: 1px solid rgba(255,255,255,0.10) !important;
  backdrop-filter: blur(6px);
}
.testimonial-card p    { color: rgba(255,255,255,0.82) !important; }
.testimonial-card .name { color: var(--blanco) !important; }
.testimonial-card .meta { color: rgba(255,255,255,0.50) !important; }
.testimonial-card .testimonial-avatar {
  background: linear-gradient(135deg, var(--dorado), var(--verde-salvia)) !important;
  color: var(--blanco) !important;
}

/* Blog */
.blog-card {
  background: rgba(12, 24, 48, 0.65) !important;
  border: 1px solid rgba(255,255,255,0.10) !important;
  backdrop-filter: blur(6px);
}
.blog-card-body h3 a { color: var(--blanco) !important; }
.blog-card-body p    { color: rgba(255,255,255,0.72) !important; }
.blog-card-meta      { color: rgba(255,255,255,0.45) !important; }

/* Values */
.value-card {
  background: rgba(12, 24, 48, 0.65) !important;
  border: 1px solid rgba(255,255,255,0.10) !important;
  backdrop-filter: blur(6px);
}
.value-card h4 { color: var(--blanco) !important; }
.value-card p  { color: rgba(255,255,255,0.70) !important; }
.value-card .icon { color: var(--dorado) !important; }

/* Diff */
.diff-card {
  background: rgba(12, 24, 48, 0.65) !important;
  border: 1px solid rgba(255,255,255,0.12) !important;
  backdrop-filter: blur(6px);
}
.diff-card h3 { color: var(--blanco) !important; }
.diff-card p  { color: rgba(255,255,255,0.72) !important; }

/* ── Accordion ───────────────────────────────── */
.accordion-item {
  background: rgba(10, 20, 42, 0.62) !important;
  border: 1px solid rgba(255,255,255,0.09) !important;
  backdrop-filter: blur(6px);
}
.accordion-header h3 { color: var(--blanco) !important; }
.accordion-header .step-num { color: var(--dorado) !important; }
.accordion-icon { stroke: rgba(255,255,255,0.55) !important; }
.accordion-body-inner p,
.accordion-body-inner li { color: rgba(255,255,255,0.78) !important; }

/* ── Chips ───────────────────────────────────── */
.chip {
  background: rgba(201,169,110,0.14) !important;
  color: rgba(255,255,255,0.88) !important;
  border-color: rgba(201,169,110,0.30) !important;
}
.chip .dot { background: var(--dorado) !important; }

/* ── Gallery ─────────────────────────────────── */
.gallery-item {
  background: rgba(20,45,80,0.55) !important;
  border: 1px solid rgba(255,255,255,0.09) !important;
  backdrop-filter: blur(4px);
}
.gallery-label p { color: rgba(255,255,255,0.80) !important; }

/* ── About image placeholder ─────────────────── */
.about-image {
  background: rgba(27,58,92,0.40) !important;
  border: 1px solid rgba(201,169,110,0.20) !important;
}

/* ── CTA section ─────────────────────────────── */
.cta-section {
  background: rgba(8, 18, 38, 0.72) !important;
  backdrop-filter: blur(12px) !important;
}

/* ── Contact ─────────────────────────────────── */
.contact-info-card {
  background: rgba(12, 24, 48, 0.65) !important;
  border: 1px solid rgba(255,255,255,0.10) !important;
  backdrop-filter: blur(8px);
}
.contact-info-card h3     { color: var(--blanco) !important; }
.contact-info-card .label { color: var(--dorado) !important; }
.contact-info-card .value,
.contact-info-card .value a { color: rgba(255,255,255,0.85) !important; }
.contact-info-card .icon { background: rgba(201,169,110,0.15) !important; color: var(--dorado) !important; }

.contact-form-wrapper {
  background: rgba(10, 20, 42, 0.60) !important;
  border: 1px solid rgba(255,255,255,0.08) !important;
  backdrop-filter: blur(8px);
  border-radius: 12px;
  padding: 2.5rem !important;
}
.contact-form-wrapper h2 { color: var(--blanco) !important; }
.contact-form-wrapper > p { color: rgba(255,255,255,0.70) !important; }

.map-placeholder {
  background: rgba(10, 20, 42, 0.55) !important;
  border: 1px solid rgba(255,255,255,0.08) !important;
  color: rgba(255,255,255,0.60) !important;
}
.map-placeholder strong { color: var(--blanco) !important; }
.map-placeholder p { color: rgba(255,255,255,0.60) !important; }

/* ── Form controls ───────────────────────────── */
label { color: rgba(255,255,255,0.85) !important; }
.required { color: var(--dorado) !important; }
.checkbox-label { color: rgba(255,255,255,0.75) !important; }
.checkbox-label a { color: var(--dorado) !important; }
#mensaje-hint { color: rgba(255,255,255,0.40) !important; }

.form-control {
  background: rgba(255,255,255,0.07) !important;
  border-color: rgba(255,255,255,0.15) !important;
  color: var(--blanco) !important;
}
.form-control::placeholder { color: rgba(255,255,255,0.35) !important; }
.form-control:focus {
  border-color: var(--dorado) !important;
  background: rgba(255,255,255,0.11) !important;
  box-shadow: 0 0 0 3px rgba(201,169,110,0.15) !important;
  outline: none;
}
select.form-control option { background: #0d1e36; color: var(--blanco); }

/* ── Instalaciones hero ──────────────────────── */
.instalaciones-hero {
  background: rgba(6,13,26,0.72) !important;
}
.instalaciones-hero::before { display: none !important; }

/* ── Hero stat labels ────────────────────────── */
.hero-stat .label { color: rgba(255,255,255,0.60) !important; }

/* ── Article ─────────────────────────────────── */
.article-layout { color: rgba(255,255,255,0.82); }
.article-content h2, .article-content h3 { color: var(--blanco) !important; }
.article-content p, .article-content li { color: rgba(255,255,255,0.78) !important; }
.article-meta { color: rgba(255,255,255,0.50) !important; border-color: rgba(255,255,255,0.10) !important; }
.sidebar-cta {
  background: rgba(12, 24, 48, 0.65) !important;
  border: 1px solid rgba(255,255,255,0.10) !important;
  backdrop-filter: blur(8px);
}
.sidebar-cta h3 { color: var(--blanco) !important; }
.sidebar-cta p  { color: rgba(255,255,255,0.72) !important; }

/* ── Gallery placeholder text ────────────────── */
[style*="gris-piedra"] { color: rgba(255,255,255,0.40) !important; }
