:root {
  --ink: #17324d;
  --muted: #63758a;
  --blue: #27a9e1;
  --blue-dark: #0877b5;
  --aqua: #27d2c6;
  --lime: #a8cf37;
  --yellow: #ffd84d;
  --coral: #ff6b78;
  --purple: #8569d8;
  --soft: #f4fbff;
  --white: #ffffff;
  --shadow: 0 18px 45px rgba(17, 76, 112, .12);
  --radius: 26px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--white);
  font-family: "Nunito", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.7;
  overflow-x: hidden;
}
body.loading { overflow: hidden; }
body { transition:opacity .26s ease, filter .26s ease; }
body.page-leaving { opacity:.12; filter:saturate(1.6) blur(2px); }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
h1, h2, h3, h4 { font-family: "Fredoka", "Nunito", sans-serif; font-weight: 650; line-height: 1.16; }
h1 { font-size: clamp(2.4rem, 5vw, 5rem); letter-spacing: -.035em; }
h2 { font-size: clamp(2rem, 3.6vw, 3.45rem); letter-spacing: -.025em; }
h3 { font-size: 1.35rem; }
p { margin: 0 0 1rem; }
.text-muted { color: var(--muted) !important; }
.small-caps { color: var(--blue-dark); font-weight: 900; letter-spacing: .13em; text-transform: uppercase; font-size: .78rem; }
.section { padding: 90px 0; position: relative; }
.section-soft { background: var(--soft); }
.section-yellow { background: #fff9de; }
.section-title { max-width: 760px; margin: 0 auto 44px; text-align: center; }
.section-title p { color: var(--muted); font-size: 1.05rem; }
.section-title h2 { margin: .4rem 0 1rem; }
.text-gradient { background: linear-gradient(120deg, var(--blue-dark), var(--purple)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.blob { position: absolute; border-radius: 50%; filter: blur(2px); opacity: .16; pointer-events: none; }
.blob-one { width: 180px; height: 180px; background: var(--yellow); top: 5%; left: -70px; }
.blob-two { width: 220px; height: 220px; background: var(--aqua); bottom: 0; right: -90px; }

/* Loader */
#site-loader { position: fixed; inset: 0; z-index: 9999; background: linear-gradient(135deg,#eefbff,#fffbe8); display: grid; place-items: center; transition: opacity .45s ease, visibility .45s ease; }
#site-loader.hide { opacity: 0; visibility: hidden; }
.loader-tooth { width: 82px; height: 90px; background: var(--white); border: 5px solid var(--blue); border-radius: 48% 48% 45% 45%; box-shadow: var(--shadow); position: relative; animation: toothBounce .9s ease-in-out infinite alternate; }
.loader-tooth::before, .loader-tooth::after { content:""; position:absolute; bottom:-20px; width:27px; height:42px; background:white; border:5px solid var(--blue); border-top:0; border-radius:0 0 20px 20px; }
.loader-tooth::before { left:6px; transform:rotate(8deg); }
.loader-tooth::after { right:6px; transform:rotate(-8deg); }
.loader-smile { position:absolute; left:22px; top:35px; width:30px; height:16px; border-bottom:4px solid var(--coral); border-radius:50%; }
@keyframes toothBounce { to { transform: translateY(-14px) rotate(3deg); } }

/* Header */
.topbar { background: var(--ink); color: white; font-size: .9rem; }
.topbar a { color: white; opacity: .92; }
.topbar a:hover { color: var(--yellow); }
.rainbow-rule { height: 6px; position: sticky; top: 0; z-index: 1032; background: linear-gradient(90deg,#ff6b78 0 12%,#ffd84d 12% 25%,#a8cf37 25% 38%,#27d2c6 38% 55%,#27a9e1 55% 70%,#8569d8 70% 84%,#ff93c7 84%); }
.site-header { background: linear-gradient(110deg,rgba(255,255,255,.97),rgba(255,254,181,.96)); box-shadow: 0 8px 28px rgba(19,66,98,.11), inset 0 1px 0 rgba(255,255,255,.9); position: sticky; top: 6px; z-index: 1030; backdrop-filter: blur(16px); }
.navbar-brand img { width: 245px; height: auto; }
.navbar-nav { gap: 0; }
.nav-link { font-weight: 900; color: #111 !important; padding: .86rem .72rem !important; border-radius: 0; white-space: nowrap; position: relative; }
.nav-link::after { content:""; position:absolute; left:50%; right:50%; bottom:.45rem; height:3px; border-radius:3px; background:linear-gradient(90deg,var(--coral),var(--purple)); transition:.25s; }
.nav-link:hover, .nav-link.active { color: #ef304c !important; background: rgba(255,255,255,.45); }
.nav-link:hover::after, .nav-link.active::after { left:.72rem; right:.72rem; }
@media (min-width:1200px){ .nav-item + .nav-item { border-left:2px solid rgba(255,255,255,.95); } }
.navbar-toggler { border: 0; box-shadow: none !important; }
.btn { border: 0; border-radius: 999px; padding: .82rem 1.25rem; font-weight: 900; transition: transform .2s ease, box-shadow .2s ease, background .2s ease; }
.btn:hover { transform: translateY(-2px); box-shadow: 0 12px 26px rgba(14,99,148,.18); }
.btn-primary { background: linear-gradient(120deg, var(--blue), var(--blue-dark)); }
.btn-coral { background: linear-gradient(120deg, #ff7b84, #f04463); color: white; }
.btn-coral:hover { color: white; }
.btn-lime { background: var(--lime); color: #22370c; }
.btn-outline-brand { border: 2px solid var(--blue); color: var(--blue-dark); background: white; }

/* Hero */
.hero { min-height: 690px; display: grid; align-items: center; background: linear-gradient(130deg,#e9faff 0%,#fff 48%,#fff7cc 100%); position: relative; overflow: hidden; }
.hero::before { content:""; position:absolute; inset:0; background-image: radial-gradient(circle at 16% 20%,rgba(39,210,198,.18) 0 7%,transparent 7.2%),radial-gradient(circle at 85% 16%,rgba(255,107,120,.12) 0 8%,transparent 8.2%); }
.hero-copy { position: relative; z-index: 2; padding: 70px 0; }
.hero-copy h1 { margin: .75rem 0 1.2rem; max-width: 720px; }
.hero-copy .lead { font-size: clamp(1.05rem,2vw,1.25rem); color: var(--muted); max-width: 650px; }
.hero-actions { display:flex; flex-wrap:wrap; gap:.8rem; margin-top:1.7rem; }
.hero-badge { display:inline-flex; align-items:center; gap:.55rem; padding:.55rem .9rem; border-radius:999px; background:white; box-shadow:0 10px 30px rgba(17,85,124,.12); font-weight:900; color:var(--blue-dark); }
.hero-badge i { color: var(--coral); }
.hero-visual { position:relative; z-index:2; }
.hero-frame { border-radius: 38px 38px 100px 38px; overflow:hidden; background:white; padding:10px; box-shadow: 0 30px 70px rgba(30,119,163,.22); transform: rotate(1.3deg); }
.hero-frame img { width:100%; height:420px; object-fit:cover; border-radius:30px 30px 92px 30px; }
.hero-note { position:absolute; left:-25px; bottom:25px; background:white; border-radius:20px; padding:14px 18px; box-shadow:var(--shadow); font-weight:900; animation:float 3s ease-in-out infinite; }
.hero-note i { color:var(--yellow); margin-right:.4rem; }
@keyframes float { 50% { transform:translateY(-10px); } }
.hero-carousel { position:relative; overflow:hidden; background:#15334c; }
.hero-carousel .carousel-item { min-height:670px; position:relative; }
.hero-carousel .carousel-item::after { content:""; position:absolute; inset:0; background:linear-gradient(90deg,rgba(8,44,69,.84) 0%,rgba(8,44,69,.55) 48%,rgba(8,44,69,.08) 100%); }
.hero-carousel .hero-slide-image { position:absolute; inset:0; width:100%; height:100%; object-fit:cover; transform:scale(1.04); animation:heroZoom 7s ease both; }
.hero-carousel .carousel-item.active .hero-slide-image { animation:heroZoom 7s ease both; }
.hero-slide-content { min-height:670px; display:flex; flex-direction:column; justify-content:center; align-items:flex-start; position:relative; z-index:2; color:white; max-width:760px; padding:80px 0 110px; }
.hero-slide-content h1 { margin:.7rem 0 1rem; text-shadow:0 5px 26px rgba(0,0,0,.24); }
.hero-slide-content .lead { max-width:650px; color:rgba(255,255,255,.92); }
.hero-carousel .carousel-indicators { bottom:28px; gap:9px; }
.hero-carousel .carousel-indicators button { width:44px; height:7px; border:0; border-radius:10px; background:#fff; }
.hero-carousel .carousel-control-prev,.hero-carousel .carousel-control-next { width:7%; }
.mirror-chip { display:inline-flex; gap:.55rem; align-items:center; padding:.6rem 1rem; border:1px solid rgba(255,255,255,.7); border-radius:999px; background:linear-gradient(120deg,rgba(255,255,255,.3),rgba(255,255,255,.08)); box-shadow:inset 0 1px 0 rgba(255,255,255,.65),0 12px 30px rgba(0,0,0,.14); backdrop-filter:blur(12px); font-weight:900; }
@keyframes heroZoom { from{transform:scale(1.09)} to{transform:scale(1)} }

/* Cards */
.feature-strip { margin-top:-46px; position:relative; z-index:5; }
.feature-card { height:100%; color:white; border-radius:24px; padding:28px; box-shadow:var(--shadow); transition:transform .25s ease; }
.feature-card:hover { transform:translateY(-7px); }
.feature-card i { font-size:2rem; margin-bottom:15px; }
.feature-card h3 { margin-bottom:.5rem; }
.feature-blue { background:linear-gradient(135deg,#29b3e7,#0878b7); }
.feature-coral { background:linear-gradient(135deg,#ff8890,#ef4668); }
.feature-purple { background:linear-gradient(135deg,#9c7ae8,#6548b8); }
.service-card { height:100%; border:0; background:white; border-radius:var(--radius); overflow:hidden; box-shadow:0 15px 38px rgba(18,77,111,.1); transition:transform .25s ease,box-shadow .25s ease; }
.service-card:hover { transform:translateY(-8px); box-shadow:0 24px 52px rgba(18,77,111,.17); }
.service-card img { width:100%; height:220px; object-fit:cover; }
.service-card .card-body { padding:25px; }
.service-card h3 { margin-bottom:.7rem; }
.icon-bubble { width:56px; height:56px; display:grid; place-items:center; border-radius:18px; background:#eaf8ff; color:var(--blue-dark); font-size:1.5rem; margin-bottom:1rem; }
.info-card { background:white; border-radius:var(--radius); padding:30px; height:100%; box-shadow:var(--shadow); }
.doctor-card { background:white; border-radius:30px; overflow:hidden; box-shadow:var(--shadow); height:100%; }
.doctor-card img { width:100%; height:390px; object-fit:cover; object-position:top center; background:#e8f8ff; }
.doctor-card .content { padding:24px; text-align:center; }
.doctor-card .role { color:var(--blue-dark); font-weight:900; }
.review-card { height:100%; background:white; border-radius:24px; padding:28px; box-shadow:var(--shadow); }
.stars { color:#ffbc23; letter-spacing:.15rem; margin-bottom:.8rem; }
.gallery-item { border-radius:24px; overflow:hidden; box-shadow:var(--shadow); position:relative; }
.gallery-item img { width:100%; height:270px; object-fit:cover; transition:transform .45s ease; }
.gallery-item:hover img { transform:scale(1.06); }

/* Inner pages */
.page-hero { padding:110px 0 85px; text-align:center; color:white; position:relative; overflow:hidden; background:linear-gradient(125deg,var(--blue-dark),var(--aqua)); }
.page-hero::before { content:""; position:absolute; inset:0; background:radial-gradient(circle at 10% 25%,rgba(255,255,255,.18) 0 8%,transparent 8.2%),radial-gradient(circle at 92% 76%,rgba(255,216,77,.25) 0 12%,transparent 12.2%); }
.page-hero .container { position:relative; z-index:1; }
.page-hero h1 { margin:.5rem 0 1rem; }
.breadcrumbs { font-weight:800; opacity:.9; }
.content-image { border-radius:34px; box-shadow:var(--shadow); width:100%; max-height:570px; object-fit:cover; }
.treatment-row { padding:30px; border-radius:28px; background:white; box-shadow:var(--shadow); margin-bottom:28px; }
.treatment-row img { width:100%; height:250px; object-fit:cover; border-radius:20px; }
.accordion-item { border:0; border-radius:18px !important; overflow:hidden; box-shadow:0 10px 28px rgba(19,75,107,.09); margin-bottom:14px; }
.accordion-button { font-weight:900; font-size:1.05rem; color:var(--ink); padding:1.2rem 1.35rem; }
.accordion-button:not(.collapsed) { background:#eaf9ff; color:var(--blue-dark); box-shadow:none; }
.video-card { background:white; border-radius:24px; overflow:hidden; box-shadow:var(--shadow); height:100%; }
.ratio iframe { border:0; }
.video-card h3 { padding:20px 22px 12px; }
.video-card p { padding:0 22px 20px; color:var(--muted); }
.video-slider { border-radius:34px; overflow:hidden; background:linear-gradient(130deg,#112e49,#195e85); box-shadow:0 25px 65px rgba(9,65,99,.25); }
.video-slider .carousel-item { padding:42px 70px 70px; color:white; }
.video-slider .ratio { border-radius:22px; overflow:hidden; box-shadow:0 18px 46px rgba(0,0,0,.28); }
.video-slider .carousel-indicators { bottom:20px; }
.video-slider .carousel-indicators button { width:34px; height:6px; border-radius:8px; border:0; }
.mirror-card { background:linear-gradient(145deg,rgba(255,255,255,.96),rgba(228,250,255,.82)); border:1px solid rgba(255,255,255,.95); box-shadow:inset 0 1px 0 white,0 20px 52px rgba(21,87,124,.15); backdrop-filter:blur(10px); }
.blog-card { background:white; border-radius:24px; padding:28px; box-shadow:var(--shadow); height:100%; border-top:6px solid var(--aqua); }
.blog-card:nth-child(2n) { border-color:var(--yellow); }
.blog-card:nth-child(3n) { border-color:var(--coral); }

/* Forms and contact */
.contact-wrap { border-radius:34px; overflow:hidden; box-shadow:var(--shadow); background:white; }
.contact-panel { padding:38px; background:linear-gradient(150deg,var(--blue-dark),#15517d); color:white; height:100%; }
.contact-panel a:hover { color:var(--yellow); }
.form-panel { padding:38px; }
.form-control, .form-select { border:1px solid #d9e6ee; border-radius:14px; padding:.86rem 1rem; min-height:50px; }
.form-control:focus, .form-select:focus { border-color:var(--blue); box-shadow:0 0 0 .22rem rgba(39,169,225,.13); }
.map-frame { width:100%; min-height:430px; border:0; border-radius:30px; box-shadow:var(--shadow); }

/* Footer */
.site-footer { background:#132f49; color:#dbeaf4; padding:70px 0 90px; }
.site-footer h3 { color:white; font-size:1.2rem; margin-bottom:1.2rem; }
.footer-logo { background:white; border-radius:18px; padding:12px; width:235px; margin-bottom:1rem; }
.footer-links { list-style:none; padding:0; margin:0; }
.footer-links li { margin:.55rem 0; }
.footer-links a:hover { color:var(--yellow); }
.copyright { border-top:1px solid rgba(255,255,255,.13); margin-top:40px; padding-top:24px; font-size:.92rem; }
.copyright a { color:var(--yellow); font-weight:900; }
.socials { display:flex; gap:.65rem; margin-top:1rem; }
.socials a { width:42px; height:42px; display:grid; place-items:center; background:rgba(255,255,255,.1); border-radius:50%; }
.socials a:hover { background:var(--blue); color:white; }

/* Floating actions */
.whatsapp-float { position:fixed; right:22px; bottom:22px; z-index:1040; width:60px; height:60px; display:grid; place-items:center; border-radius:50%; background:#22c55e; color:white; font-size:1.8rem; box-shadow:0 14px 30px rgba(0,100,45,.3); animation:pulse 2.2s infinite; }
.whatsapp-float:hover { color:white; transform:translateY(-3px); }
@keyframes pulse { 0%,100%{box-shadow:0 14px 30px rgba(0,100,45,.3)} 50%{box-shadow:0 14px 35px rgba(0,100,45,.3),0 0 0 12px rgba(34,197,94,.1)} }
.mobile-actions { display:none; }
.back-top { position:fixed; left:20px; bottom:22px; width:46px; height:46px; border:0; border-radius:50%; background:var(--ink); color:white; z-index:1030; opacity:0; pointer-events:none; transition:.25s; }
.back-top.show { opacity:1; pointer-events:auto; }
#tooth-progress { position:fixed; left:0; right:0; top:0; height:6px; z-index:1100; pointer-events:none; }
#tooth-progress span { position:absolute; top:1px; left:0; color:white; font-size:18px; filter:drop-shadow(0 2px 3px rgba(0,0,0,.28)); transition:left .08s linear; }
.tooth-pop { position:fixed; z-index:3000; pointer-events:none; transform:translate(-50%,-50%); font-size:1.7rem; animation:toothPop .82s ease-out forwards; filter:drop-shadow(0 4px 8px rgba(0,0,0,.2)); }
@keyframes toothPop { 0%{opacity:0; transform:translate(-50%,-20%) scale(.45) rotate(-18deg)} 25%{opacity:1} 100%{opacity:0; transform:translate(-50%,-150%) scale(1.25) rotate(22deg)} }

/* Reveal */
.reveal { opacity:0; transform:translateY(24px); transition:opacity .7s ease, transform .7s ease; }
.reveal.visible { opacity:1; transform:none; }

@media (max-width: 1199.98px) {
  .navbar-brand img { width:210px; }
  .nav-link { padding:.65rem .5rem !important; font-size:.92rem; }
}
@media (max-width: 991.98px) {
  .topbar { display:none; }
  .navbar-collapse { padding:1rem 0 1.3rem; }
  .nav-link { padding:.75rem 1rem !important; }
  .header-appointment { display:none; }
  .hero { min-height:auto; }
  .hero-carousel .carousel-item,.hero-slide-content { min-height:620px; }
  .hero-copy { padding:75px 0 30px; text-align:center; }
  .hero-copy .lead { margin-inline:auto; }
  .hero-actions { justify-content:center; }
  .hero-visual { padding-bottom:80px; max-width:680px; margin:auto; }
  .feature-strip { margin-top:-35px; }
  .section { padding:72px 0; }
}
@media (max-width: 767.98px) {
  body { padding-bottom:70px; }
  .navbar-brand img { width:190px; }
  h1 { font-size:clamp(2.35rem,11vw,3.7rem); }
  h2 { font-size:clamp(1.9rem,8vw,2.75rem); }
  .hero-frame img { height:300px; }
  .hero-note { left:10px; bottom:55px; font-size:.88rem; }
  .feature-strip { margin-top:-25px; }
  .section { padding:62px 0; }
  .page-hero { padding:76px 0 62px; }
  .hero-carousel .carousel-item,.hero-slide-content { min-height:590px; }
  .hero-carousel .carousel-item::after { background:linear-gradient(90deg,rgba(8,44,69,.86),rgba(8,44,69,.55)); }
  .hero-slide-content { text-align:center; align-items:center; padding:70px 14px 100px; }
  .hero-slide-content .hero-actions { justify-content:center; }
  .video-slider .carousel-item { padding:24px 18px 62px; }
  .contact-panel,.form-panel { padding:28px 22px; }
  .site-footer { padding-bottom:36px; }
  .whatsapp-float { bottom:84px; width:54px; height:54px; right:16px; }
  .back-top { bottom:88px; left:16px; }
  .mobile-actions { position:fixed; bottom:0; left:0; right:0; z-index:1050; display:grid; grid-template-columns:repeat(3,1fr); background:white; box-shadow:0 -8px 28px rgba(15,57,83,.16); padding-bottom:env(safe-area-inset-bottom); }
  .mobile-actions a { min-height:66px; display:flex; flex-direction:column; align-items:center; justify-content:center; gap:2px; font-size:.72rem; font-weight:900; color:white; }
  .mobile-actions a:nth-child(1){background:var(--blue-dark)}
  .mobile-actions a:nth-child(2){background:#20b85a}
  .mobile-actions a:nth-child(3){background:var(--coral)}
  .mobile-actions i{font-size:1.25rem}
  .gallery-item img { height:230px; }
  .doctor-card img { height:330px; }
}
@media (max-width: 390px) {
  .navbar-brand img { width:165px; }
  .hero-actions .btn { width:100%; }
  .hero-badge { font-size:.82rem; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration:.01ms !important; animation-iteration-count:1 !important; scroll-behavior:auto !important; transition-duration:.01ms !important; }
  .reveal { opacity:1; transform:none; }
}
