/*
  Dra. Naieli Sant'Ana — Dentista em Catanduva
  UI refinado: acessibilidade WCAG AA, scroll suave, hover states, focus visible, motion safe
*/

:root {
  --black: #282828;
  --dark: #1e1e1e;
  --muted: #a0a8a9;
  --blue: #5ba3bb;
  --blue-soft: #e1f1f8;
  --blue-mid: #ccdde4;
  --sage: #9CBBA8;
  --sage-dark: #789984;
  --cream: #f8f5ef;
  --white: #ffffff;
  --footer: #1e1e1e;
  --line: rgba(40, 40, 40, 0.12);
  --container: 1712px;
  --wa-green: #25D366;
}

/* ── Reset ── */
* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 96px;
}

body {
  margin: 0;
  font-family: "Plus Jakarta Sans", Arial, sans-serif;
  background: var(--white);
  color: var(--black);
  line-height: 1.55;
  overflow-x: hidden;
}

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

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

/* ── Acessibilidade: sr-only ── */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

/* ── Acessibilidade: focus visible ── */
:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 3px;
  border-radius: 2px;
}

/* ── Motion safe ── */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
  * {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }
}

/* ─────────────────────────────────────
   HEADER
───────────────────────────────────── */
.header {
  width: min(var(--container), calc(100% - 128px));
  height: 96px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 260px 1fr auto;
  align-items: center;
  gap: 40px;
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, .95);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.logo img {
  width: 220px;
  height: auto;
}

.menu {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 52px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.menu a {
  position: relative;
  color: var(--black);
  transition: color .2s ease;
  padding-bottom: 4px;
}

.menu a::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--blue);
  transition: width .25s ease;
}

.menu a:hover,
.menu a.active {
  color: var(--blue);
}

.menu a:hover::after,
.menu a.active::after {
  width: 100%;
}

/* ─────────────────────────────────────
   BUTTONS
───────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 26px;
  border: 0;
  font-family: inherit;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .07em;
  text-transform: uppercase;
  cursor: pointer;
  transition: transform .2s ease, background .2s ease, box-shadow .2s ease;
}

.btn:hover { transform: translateY(-2px); }

.btn-primary {
  color: var(--white);
  background: var(--blue);
}

.btn-primary:hover {
  background: #4e93a9;
  box-shadow: 0 8px 24px rgba(91,163,187,.3);
}

.btn-light {
  color: var(--black);
  background: var(--white);
}

.btn-light:hover {
  background: #f0f0f0;
}

.btn.small {
  min-width: 168px;
}

/* ─────────────────────────────────────
   MENU MOBILE
───────────────────────────────────── */
.menu-button {
  display: none;
  border: 0;
  background: transparent;
  width: 44px;
  height: 44px;
  cursor: pointer;
  padding: 0;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.menu-button span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--black);
  border-radius: 2px;
  transition: transform .3s ease, opacity .3s ease;
}

.menu-button[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.menu-button[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}
.menu-button[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.mobile-menu {
  display: none;
}

/* ─────────────────────────────────────
   HERO
───────────────────────────────────── */
.hero {
  width: min(var(--container), calc(100% - 128px));
  min-height: 860px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 39% 61%;
  grid-template-rows: 1fr auto;
  position: relative;
}

.hero-copy {
  padding-top: 100px;
  padding-bottom: 40px;
  position: relative;
  z-index: 4;
}

h1,
h2 {
  margin: 0;
  font-weight: 800;
  letter-spacing: -0.045em;
  line-height: .98;
}

h1 {
  max-width: 665px;
  font-size: clamp(64px, 5.3vw, 96px);
}

h2 {
  font-size: clamp(44px, 4vw, 64px);
  line-height: 1.08;
}

p {
  color: var(--muted);
  font-size: 18px;
  line-height: 2;
}

.hero-visual {
  position: relative;
  min-height: 860px;
}

.hero-bg {
  position: absolute;
  top: -53px;
  right: -56px;
  width: 72%;
  height: 556px;
  background: linear-gradient(240deg, var(--blue-mid) 6%, var(--blue-soft) 72%);
  opacity: .55;
}

.hero-photo {
  position: absolute;
  top: 96px;
  right: 0;
  width: 88%;
  height: 712px;
  object-fit: cover;
  object-position: center top;
}

.mosaic {
  position: absolute;
  top: 96px;
  right: 0;
  width: 88%;
  height: 712px;
  pointer-events: none;
}

.mosaic span {
  position: absolute;
  width: 144px;
  height: 144px;
  background: var(--blue);
  opacity: .5;
}

.mosaic .m1 { left: 0; top: 0; opacity: 1; clip-path: polygon(0 0, 100% 0, 0 100%); }
.mosaic .m2 { left: 0; top: 144px; }
.mosaic .m3 { left: 0; top: 288px; opacity: 1; }
.mosaic .m4 { left: 144px; top: 288px; }
.mosaic .m5 { left: 144px; bottom: 0; }
.mosaic .m6 { left: 288px; top: 0; }
.mosaic .m7 { right: 288px; bottom: 0; }
.mosaic .m8 { right: 144px; bottom: 144px; }

/* ── Social lateral ── */
.side-social {
  position: absolute;
  top: 168px;
  right: -46px;
  display: grid;
  gap: 14px;
}

.side-social a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  color: var(--black);
  transition: color .2s ease, transform .2s ease;
}

.side-social a:hover {
  color: var(--blue);
  transform: scale(1.15);
}

.side-social svg {
  width: 18px;
  height: 18px;
}

/* ── Hero services ── */
.hero-services {
  grid-column: 1 / 3;
  width: min(848px, 100%);
  min-height: 136px;
  background: var(--white);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  align-items: stretch;
  margin-top: -280px;
  position: relative;
  z-index: 5;
  box-shadow: 0 20px 50px rgba(40, 40, 40, .06);
}

.hero-service {
  padding: 20px 30px;
  display: grid;
  gap: 5px;
  transition: background .2s ease;
  border-bottom: 2px solid transparent;
}

.hero-service:hover {
  background: var(--blue-soft);
  border-bottom-color: var(--blue);
}

.hero-service:hover strong {
  color: var(--blue);
}

.hero-service span {
  color: var(--blue);
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.hero-service strong {
  font-size: 21px;
  letter-spacing: .03em;
  transition: color .2s ease;
}

.hero-service small {
  color: var(--muted);
  font-size: 14px;
}

/* ─────────────────────────────────────
   SECTIONS
───────────────────────────────────── */
.section {
  width: min(var(--container), calc(100% - 128px));
  margin: 0 auto;
  padding: 120px 0;
}

.about,
.doctor,
.location {
  display: grid;
  grid-template-columns: minmax(0, 704px) 1fr;
  gap: 160px;
  align-items: center;
}

.image-block {
  position: relative;
  min-height: 760px;
}

.soft-bg {
  position: absolute;
  top: -72px;
  left: -56px;
  width: 538px;
  height: 688px;
  background: linear-gradient(260deg, var(--blue-mid) 6%, var(--blue-soft) 72%);
  opacity: .55;
}

.image-block img {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 704px;
  height: 688px;
  object-fit: cover;
}

.text-block,
.doctor-copy,
.location-copy {
  max-width: 640px;
}

.text-block p,
.doctor-copy p,
.location-copy p {
  max-width: 560px;
}

.actions {
  display: flex;
  align-items: center;
  gap: 48px;
  margin-top: 42px;
}

.text-link {
  display: inline-block;
  border-bottom: 2px solid var(--blue);
  color: var(--blue);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .07em;
  text-transform: uppercase;
  padding-bottom: 6px;
  transition: opacity .2s ease;
}

.text-link:hover {
  opacity: .7;
}

/* ─────────────────────────────────────
   PATIENT STRIP
───────────────────────────────────── */
.patient-strip {
  width: min(var(--container), calc(100% - 128px));
  margin: -40px auto 80px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  background: var(--black);
  color: var(--white);
}

.patient-strip div {
  padding: 36px 42px;
  border-right: 1px solid rgba(255,255,255,.12);
  transition: background .25s ease;
}

.patient-strip div:hover {
  background: rgba(91,163,187,.08);
}

.patient-strip span {
  color: var(--blue);
  font-size: 24px;
  font-weight: 800;
}

.patient-strip strong {
  display: block;
  font-size: 21px;
  margin: 12px 0;
}

.patient-strip p {
  margin: 0;
  font-size: 15px;
  color: #a7adaf;
  line-height: 1.8;
}

/* ─────────────────────────────────────
   SERVICES
───────────────────────────────────── */
.services {
  width: 100%;
  padding: 132px 64px;
  display: grid;
  grid-template-columns: 516px 1fr;
  gap: 80px;
  background: linear-gradient(240deg, rgba(204,221,228,.55) 6%, rgba(225,241,248,.72) 72%);
}

.section-title {
  max-width: 516px;
}

.service-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(190px, 1fr));
  column-gap: 74px;
  row-gap: 72px;
}

.service-item {
  transition: transform .25s ease;
}

.service-item:hover {
  transform: translateY(-5px);
}

.service-item svg {
  width: 40px;
  height: 40px;
  stroke: var(--blue);
  stroke-width: 2.2;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.service-item h3 {
  margin: 22px 0 10px;
  font-size: 21px;
  font-weight: 500;
  letter-spacing: .03em;
}

.service-item p {
  margin: 0;
  font-size: 16px;
  line-height: 1.9;
}

/* ─────────────────────────────────────
   DOCTOR
───────────────────────────────────── */
.doctor {
  grid-template-columns: minmax(0, 560px) 1fr;
  gap: 224px;
}

.doctor-photo {
  position: relative;
}

.doctor-photo::after {
  content: "";
  position: absolute;
  left: 32px;
  top: 32px;
  width: 100%;
  height: 100%;
  border: 1px solid var(--blue);
  opacity: .5;
  z-index: -1;
}

.doctor-photo img {
  width: 560px;
  height: 688px;
  object-fit: cover;
  object-position: center top;
}

/* ─────────────────────────────────────
   CLINIC / FEATURED
───────────────────────────────────── */
.featured {
  display: grid;
  grid-template-columns: minmax(0, 560px) 1fr minmax(0, 560px);
  align-items: center;
  gap: 72px;
  padding-top: 40px;
}

.featured img {
  width: 100%;
  max-width: 560px;
  object-fit: cover;
}

.clinic-left img {
  height: 800px;
}

.clinic-right img {
  height: 688px;
}

.clinic-left,
.clinic-right {
  position: relative;
}

.featured small {
  position: absolute;
  writing-mode: vertical-rl;
  text-orientation: mixed;
  color: var(--black);
  font-size: 14px;
  font-weight: 600;
}

.clinic-left small {
  left: -34px;
  bottom: 0;
  transform: rotate(180deg);
}

.clinic-right small {
  right: -34px;
  top: 0;
}

.clinic-center h2 span {
  display: block;
  color: var(--blue);
}

blockquote {
  margin: 190px 0 0;
  font-family: "Playfair Display", serif;
  font-style: italic;
  font-size: 35px;
  line-height: 1.32;
  color: var(--blue);
}

cite {
  display: block;
  text-align: right;
  font-size: 23px;
  font-style: italic;
  margin-top: 18px;
}

/* ─────────────────────────────────────
   LOCATION
───────────────────────────────────── */
.location {
  grid-template-columns: minmax(0, 560px) 1fr;
  gap: 120px;
  padding-top: 70px;
}

address {
  margin: 34px 0;
  font-style: normal;
  color: var(--black);
  font-size: 18px;
  line-height: 1.8;
  font-weight: 700;
}

.map {
  border: 1px solid var(--line);
  min-height: 430px;
  overflow: hidden;
}

.map iframe {
  display: block;
}

/* ─────────────────────────────────────
   FOOTER
───────────────────────────────────── */
.footer {
  min-height: 432px;
  padding: 76px 64px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 272px)) 1fr;
  gap: 64px;
  background: var(--footer);
  color: var(--white);
}

.footer h3 {
  margin: 0 0 24px;
  font-size: 21px;
  font-weight: 500;
  letter-spacing: .03em;
}

.footer a,
.footer p {
  display: block;
  color: #a7adaf;
  font-size: 18px;
  line-height: 2;
  margin: 0;
  transition: color .2s ease;
}

.footer a:hover {
  color: var(--white);
}

.footer-brand {
  justify-self: end;
  max-width: 420px;
}

.footer-brand img {
  width: 300px;
  height: auto;
  filter: brightness(0) invert(1);
  opacity: .9;
  margin-bottom: 26px;
}

.footer-brand .btn {
  margin-top: 26px;
}

/* ─────────────────────────────────────
   FOOTER BOTTOM
───────────────────────────────────── */
.footer-bottom {
  background: #161616;
  padding: 18px 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  font-size: 13px;
  color: #606669;
}

.footer-bottom a {
  color: #a7adaf;
  font-weight: 600;
  transition: color .2s ease;
}

.footer-bottom a:hover {
  color: var(--white);
}

@media (max-width: 980px) {
  .footer-bottom {
    padding: 18px 22px;
    flex-direction: column;
    text-align: center;
    gap: 8px;
  }
}

/* ─────────────────────────────────────
   FLOATING WHATSAPP
───────────────────────────────────── */
.floating-whatsapp {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 60;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--wa-green);
  color: var(--white);
  box-shadow: 0 6px 24px rgba(37,211,102,.45);
  transition: transform .25s ease, box-shadow .25s ease;
}

.floating-whatsapp:hover {
  transform: scale(1.1);
  box-shadow: 0 10px 34px rgba(37,211,102,.6);
}

/* ─────────────────────────────────────
   REVEAL ANIMATION
───────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .75s ease, transform .75s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ─────────────────────────────────────
   RESPONSIVE — 1360px
───────────────────────────────────── */
@media (max-width: 1360px) {
  .header,
  .hero,
  .section,
  .patient-strip {
    width: min(1180px, calc(100% - 56px));
  }

  .menu {
    gap: 24px;
  }

  .hero {
    grid-template-columns: 45% 55%;
  }

  .hero-services {
    width: 760px;
  }

  .about,
  .doctor,
  .location {
    grid-template-columns: 1fr 1fr;
    gap: 80px;
  }

  .image-block img,
  .doctor-photo img {
    width: 100%;
  }

  .services {
    grid-template-columns: 1fr;
  }

  .service-list {
    grid-template-columns: repeat(2, minmax(220px, 1fr));
  }

  .featured {
    grid-template-columns: 1fr 1fr;
  }

  .clinic-center {
    grid-column: 1 / 3;
    order: -1;
  }

  blockquote {
    margin-top: 60px;
  }
}

/* ─────────────────────────────────────
   RESPONSIVE — 980px
───────────────────────────────────── */
@media (max-width: 980px) {
  html {
    scroll-padding-top: 82px;
  }

  .header {
    width: calc(100% - 32px);
    height: 82px;
    grid-template-columns: 1fr auto;
  }

  .logo img {
    width: 200px;
  }

  .menu,
  .header > .btn {
    display: none;
  }

  .menu-button {
    display: flex;
  }

  .mobile-menu {
    position: fixed;
    top: 82px;
    left: 0;
    right: 0;
    z-index: 45;
    padding: 22px;
    background: var(--white);
    border-top: 1px solid var(--line);
    box-shadow: 0 12px 40px rgba(40,40,40,.1);
  }

  .mobile-menu.open {
    display: grid;
    gap: 18px;
  }

  .mobile-menu a {
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .12em;
    text-transform: uppercase;
    padding: 8px 0;
    transition: color .2s ease;
  }

  .mobile-menu a:hover,
  .mobile-menu a.active {
    color: var(--blue);
  }

  .hero {
    width: 100%;
    display: block;
    min-height: auto;
    padding: 0 22px 70px;
  }

  .hero-copy {
    padding-top: 46px;
  }

  h1 {
    font-size: clamp(48px, 13vw, 74px);
  }

  .hero-visual {
    min-height: 470px;
    margin-top: 36px;
  }

  .hero-bg {
    top: 0;
    right: -22px;
    width: 72%;
    height: 360px;
  }

  .hero-photo,
  .mosaic {
    top: 38px;
    right: 0;
    width: 100%;
    height: 430px;
  }

  .mosaic span {
    width: 72px;
    height: 72px;
  }

  .mosaic .m2 { top: 72px; }
  .mosaic .m3 { top: 144px; }
  .mosaic .m4 { left: 72px; top: 144px; }
  .mosaic .m5 { left: 72px; }
  .mosaic .m6 { left: 144px; }

  .side-social {
    display: none;
  }

  .hero-services {
    width: 100%;
    grid-template-columns: 1fr;
    margin: 26px 0 0;
    box-shadow: 0 14px 36px rgba(40,40,40,.08);
  }

  .section,
  .patient-strip {
    width: calc(100% - 32px);
  }

  .about,
  .doctor,
  .location,
  .featured {
    grid-template-columns: 1fr;
    gap: 42px;
  }

  .image-block {
    min-height: auto;
  }

  .soft-bg {
    width: 70%;
    height: 75%;
  }

  .image-block img,
  .doctor-photo img {
    height: 480px;
  }

  .actions {
    flex-wrap: wrap;
    gap: 22px;
  }

  .patient-strip {
    grid-template-columns: 1fr;
    margin-bottom: 50px;
  }

  .patient-strip div {
    border-right: 0;
    border-bottom: 1px solid rgba(255,255,255,.12);
  }

  .services {
    padding: 80px 22px;
  }

  .service-list {
    grid-template-columns: 1fr;
    gap: 46px;
  }

  .clinic-center {
    grid-column: auto;
  }

  .clinic-left img,
  .clinic-right img {
    width: 100%;
    height: 480px;
  }

  .featured small {
    display: none;
  }

  blockquote {
    margin-top: 42px;
    font-size: 28px;
  }

  .footer {
    grid-template-columns: 1fr;
    padding: 60px 22px 100px;
  }

  .footer-brand {
    justify-self: start;
  }

  .floating-whatsapp {
    right: 16px;
    bottom: 16px;
    width: 54px;
    height: 54px;
  }
}

/* ─────────────────────────────────────
   RESPONSIVE — 560px
───────────────────────────────────── */
@media (max-width: 560px) {
  p {
    font-size: 16px;
    line-height: 1.8;
  }

  h2 {
    font-size: 42px;
  }

  .hero-photo {
    object-position: center top;
  }

  .hero-service {
    padding: 24px;
  }

  .btn {
    width: 100%;
  }

  .text-link {
    width: auto;
  }

  .footer-brand img {
    width: 240px;
  }
}
