/* =====================================================================
   Baribeau Pediatric Dental Specialists - brand layer
   Design tokens, typography, header, footer, buttons.
   Loaded on every page so the whole site shares one identity.
   ===================================================================== */

@font-face{
  font-family:"Plus Jakarta Sans";
  src:url("../fonts/jakarta-var.woff2") format("woff2-variations"),
      url("../fonts/jakarta-var.woff2") format("woff2");
  font-weight:200 800;
  font-style:normal;
  font-display:swap;
}

:root{
  /* colour */
  --c-navy:#16324F;
  --c-navy-dark:#102A43;
  --c-teal:#39B7B3;
  --c-teal-light:#E7F8F7;
  --c-blue-light:#EAF7FB;
  --c-cream:#FFF9F3;
  --c-coral:#FF806F;
  --c-coral-ink:#C0432F;      /* coral darkened for text on light grounds */
  --c-yellow:#F5C95D;
  --c-text:#243746;
  --c-muted:#687985;
  --c-border:#E4EDF2;
  --c-white:#FFFFFF;
  --c-surface:#FFFFFF;
  --c-teal-ink:#17706D;        /* teal darkened to pass AA on white */

  /* layout */
  --container:1240px;
  --container-narrow:820px;

  /* radius */
  --radius-sm:10px;
  --radius-md:18px;
  --radius-lg:30px;
  --radius-pill:999px;

  /* elevation */
  --shadow-soft:0 12px 35px rgba(16,42,67,.08);
  --shadow-card:0 2px 6px rgba(16,42,67,.05), 0 14px 40px rgba(16,42,67,.07);
  --shadow-nav:0 2px 18px rgba(16,42,67,.10);

  /* motion */
  --ease:cubic-bezier(.22,.61,.36,1);
  --t-fast:180ms var(--ease);
  --t-med:240ms var(--ease);

  /* rhythm */
  --section-y:110px;
  --gap:clamp(1.5rem,3vw,2.5rem);
}
@media (max-width:1024px){ :root{ --section-y:80px; } }
@media (max-width:640px){  :root{ --section-y:62px; } }

*,*::before,*::after{ box-sizing:border-box; }

html{ -webkit-text-size-adjust:100%; scroll-behavior:smooth; }
@media (prefers-reduced-motion:reduce){ html{ scroll-behavior:auto; } }

body{
  margin:0;
  background:var(--c-white);
  color:var(--c-text);
  font-family:"Plus Jakarta Sans",-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;
  font-size:17px;
  line-height:1.65;
  font-synthesis-weight:none;
  overflow-x:hidden;
}
img{ max-width:100%; height:auto; }

h1,h2,h3,h4{ margin:0; line-height:1.15; color:var(--c-navy); font-weight:800; letter-spacing:-.02em; text-wrap:balance; }
h1{ font-size:clamp(2.35rem,1.7rem + 2.6vw,4.05rem); }
h2{ font-size:clamp(1.85rem,1.4rem + 1.7vw,2.85rem); }
h3{ font-size:clamp(1.2rem,1.08rem + .5vw,1.55rem); font-weight:700; }
h4{ font-size:1.05rem; font-weight:700; }
p{ margin:0; }

a{ color:var(--c-teal-ink); }
a:hover{ color:var(--c-navy); }

:where(a,button,input,select,textarea,summary,[tabindex]):focus-visible{
  outline:3px solid var(--c-coral-ink);
  outline-offset:3px;
  border-radius:6px;
}

.dkx-container{ width:min(100% - 2.5rem, var(--container)); margin-inline:auto; }
@media (max-width:640px){ .dkx-container{ width:min(100% - 2rem, var(--container)); } }

.dkx-sr{
  position:absolute!important; width:1px; height:1px; padding:0; margin:-1px;
  overflow:hidden; clip:rect(0 0 0 0); white-space:nowrap; border:0;
}

.dkx-skip{
  position:absolute; left:-9999px; top:0; z-index:200;
  background:var(--c-white); color:var(--c-navy); font-weight:700;
  padding:.85rem 1.35rem; border:3px solid var(--c-coral-ink); border-radius:0 0 10px 0;
}
.dkx-skip:focus{ left:0; }

/* ---------------------------------------------------------------
   Buttons
--------------------------------------------------------------- */
.dkx-btn{
  display:inline-flex; align-items:center; justify-content:center; gap:.5rem;
  text-wrap:balance;
  font:inherit; font-size:1rem; font-weight:700; line-height:1.2;
  padding:.95rem 1.7rem; border-radius:var(--radius-sm);
  border:2px solid transparent; cursor:pointer; text-decoration:none;
  transition:background-color var(--t-fast), color var(--t-fast),
             border-color var(--t-fast), transform var(--t-fast), box-shadow var(--t-fast);
}
.dkx-btn svg{ width:1.15em; height:1.15em; flex:none; }
.dkx-btn--primary{ background:var(--c-coral-ink); color:var(--c-white); }
.dkx-btn--primary:hover,.dkx-btn--primary:focus-visible{
  background:#a63823; color:var(--c-white); transform:translateY(-2px);
  box-shadow:0 10px 22px rgba(192,67,47,.28);
}
.dkx-btn--secondary{ background:var(--c-white); color:var(--c-navy); border-color:var(--c-border); }
.dkx-btn--secondary:hover,.dkx-btn--secondary:focus-visible{
  border-color:var(--c-teal); color:var(--c-navy); transform:translateY(-2px); box-shadow:var(--shadow-soft);
}
.dkx-btn--navy{ background:var(--c-navy); color:var(--c-white); }
.dkx-btn--navy:hover,.dkx-btn--navy:focus-visible{ background:var(--c-navy-dark); color:var(--c-white); transform:translateY(-2px); }
.dkx-btn--ghost{ background:transparent; color:var(--c-white); border-color:rgba(255,255,255,.55); }
.dkx-btn--ghost:hover,.dkx-btn--ghost:focus-visible{ background:rgba(255,255,255,.14); color:var(--c-white); border-color:var(--c-white); }
.dkx-btn--sm{ padding:.62rem 1.05rem; font-size:.9rem; white-space:nowrap; }
@media (prefers-reduced-motion:reduce){ .dkx-btn:hover{ transform:none; } }

.dkx-link-arrow{
  display:inline-flex; align-items:center; gap:.45rem;
  font-weight:700; text-decoration:none; color:var(--c-teal-ink);
}
.dkx-link-arrow svg{ width:1.05em; height:1.05em; transition:transform var(--t-fast); }
.dkx-link-arrow:hover svg,.dkx-link-arrow:focus-visible svg{ transform:translateX(4px); }
.dkx-link-arrow:hover{ color:var(--c-navy); }

.dkx-eyebrow{
  display:inline-block;
  font-size:.78rem; font-weight:700; letter-spacing:.14em; text-transform:uppercase;
  color:var(--c-teal-ink);
}

/* ---------------------------------------------------------------
   Header - slim info bar + sticky nav
--------------------------------------------------------------- */
.dkx-topbar{ background:var(--c-navy-dark); color:#D6E3EE; font-size:.86rem; }
.dkx-topbar__inner{
  display:flex; align-items:center; justify-content:space-between; gap:1rem;
  flex-wrap:wrap; padding:.55rem 0; min-height:40px;
}
.dkx-topbar__group{ display:flex; align-items:center; gap:1.4rem; flex-wrap:wrap; }
.dkx-topbar__item{ display:inline-flex; align-items:center; gap:.45rem; min-height:26px; color:#D6E3EE; text-decoration:none; }
.dkx-topbar__item svg{ width:15px; height:15px; flex:none; color:var(--c-teal); }
.dkx-topbar a.dkx-topbar__item:hover,.dkx-topbar a.dkx-topbar__item:focus-visible{ color:var(--c-white); text-decoration:underline; }
.dkx-topbar__note{ display:inline-flex; align-items:center; gap:.45rem; color:#BFD4E4; }
.dkx-topbar__note svg{ width:15px; height:15px; color:var(--c-yellow); }
@media (max-width:900px){
  .dkx-topbar__inner{ justify-content:center; row-gap:.2rem; }
  .dkx-topbar__group{ gap:1rem; justify-content:center; }
  .dkx-topbar__addr{ display:none; }
}

.dkx-header{ position:relative; z-index:90; }
.dkx-nav{
  background:var(--c-white);
  border-bottom:1px solid var(--c-border);
  transition:box-shadow var(--t-med);
}
.dkx-nav.is-stuck{ box-shadow:var(--shadow-nav); border-bottom-color:transparent; }
body.dkx-sticky .dkx-nav{ position:sticky; top:0; z-index:95; }

.dkx-nav__inner{ display:flex; align-items:center; justify-content:space-between; gap:1rem; padding:.7rem 0; flex-wrap:nowrap; }
.dkx-logo{ display:inline-flex; align-items:center; flex:none; text-decoration:none; }
.dkx-logo img{ display:block; width:auto; height:56px; }
@media (max-width:640px){ .dkx-logo img{ height:46px; } }

.dkx-menu{ display:flex; align-items:center; gap:.05rem; list-style:none; margin:0; padding:0; }
.dkx-menu > li{ position:relative; }
.dkx-menu > li > a{
  display:inline-flex; align-items:center; gap:.3rem;
  padding:.7rem .66rem; border-radius:8px;
  color:var(--c-navy); font-weight:600; font-size:.95rem; text-decoration:none;
  white-space:nowrap;                 /* never let a label break across lines */
  transition:background-color var(--t-fast), color var(--t-fast);
}
.dkx-menu > li > a:hover,.dkx-menu > li > a:focus-visible{ background:var(--c-blue-light); color:var(--c-navy); }
.dkx-menu > li > a[aria-current="page"]{ color:var(--c-teal-ink); }
.dkx-menu > li > a[aria-current="page"]::after{
  content:""; position:absolute; left:.66rem; right:.66rem; bottom:.28rem;
  height:2px; border-radius:2px; background:var(--c-teal);
}
.dkx-caret{ width:14px; height:14px; transition:transform var(--t-fast); }
.dkx-menu li[data-open="true"] > a .dkx-caret{ transform:rotate(180deg); }

.dkx-submenu{
  position:absolute; top:calc(100% + .35rem); left:0; min-width:250px;
  background:var(--c-white); border:1px solid var(--c-border);
  border-radius:var(--radius-sm); box-shadow:var(--shadow-card);
  list-style:none; margin:0; padding:.4rem; z-index:60;
  display:none;
}
.dkx-menu li[data-open="true"] > .dkx-submenu{ display:block; }
.dkx-submenu a{
  display:block; padding:.6rem .75rem; border-radius:7px;
  color:var(--c-text); text-decoration:none; font-size:.94rem; font-weight:600;
}
.dkx-submenu a:hover,.dkx-submenu a:focus-visible{ background:var(--c-teal-light); color:var(--c-navy); }
.dkx-submenu .dkx-submenu__desc{ display:block; font-weight:400; font-size:.83rem; color:var(--c-muted); margin-top:.1rem; }

.dkx-nav__actions{ display:flex; align-items:center; gap:.6rem; flex:0 1 auto; min-width:0; }
.dkx-nav__phone{
  display:inline-flex; align-items:center; gap:.45rem;
  color:var(--c-navy); font-weight:700; text-decoration:none; font-size:.95rem;
  padding:.6rem .75rem; border-radius:8px; white-space:nowrap;
}
.dkx-nav__phone svg{ width:18px; height:18px; color:var(--c-teal-ink); }
.dkx-nav__phone:hover,.dkx-nav__phone:focus-visible{ background:var(--c-teal-light); color:var(--c-navy); }

.dkx-burger{
  display:none; align-items:center; gap:.5rem;
  background:var(--c-white); border:2px solid var(--c-border); border-radius:9px;
  color:var(--c-navy); font:inherit; font-weight:700; font-size:.92rem;
  padding:.6rem .85rem; cursor:pointer;
}
.dkx-burger:hover{ border-color:var(--c-teal); }
.dkx-burger__bars{ position:relative; width:18px; height:2px; background:currentColor; border-radius:2px; display:inline-block; }
.dkx-burger__bars::before,.dkx-burger__bars::after{
  content:""; position:absolute; left:0; width:18px; height:2px; background:currentColor; border-radius:2px;
  transition:transform var(--t-fast), top var(--t-fast);
}
.dkx-burger__bars::before{ top:-6px; } .dkx-burger__bars::after{ top:6px; }
.dkx-burger[aria-expanded="true"] .dkx-burger__bars{ background:transparent; }
.dkx-burger[aria-expanded="true"] .dkx-burger__bars::before{ top:0; transform:rotate(45deg); }
.dkx-burger[aria-expanded="true"] .dkx-burger__bars::after{ top:0; transform:rotate(-45deg); }

@media (max-width:1180px){
  .dkx-burger{ display:inline-flex; }
  .dkx-nav__desktop{ display:none; }
  .dkx-nav__actions .dkx-nav__phone{ display:none; }
}
/* Below this the logo, the CTA and the burger cannot share one row without
   pushing the page wider than the screen. The fixed bottom bar already
   carries Call and Request, so the header keeps just the menu. */
@media (max-width:620px){
  .dkx-nav__actions .dkx-btn{ display:none; }
}
@media (max-width:380px){
  .dkx-burger span:not(.dkx-burger__bars){ display:none; }
  .dkx-burger{ padding:.6rem .7rem; }
}

/* Mobile drawer */
.dkx-drawer{
  display:none; position:fixed; inset:0; z-index:120;
  background:rgba(16,42,67,.45);
}
.dkx-drawer.is-open{ display:block; }
.dkx-drawer__panel{
  position:absolute; inset:0 0 0 auto; width:min(88vw,400px);
  background:var(--c-white); padding:1.1rem 1.25rem 2rem;
  overflow-y:auto; display:flex; flex-direction:column; gap:.6rem;
  box-shadow:-8px 0 40px rgba(16,42,67,.2);
}
.dkx-drawer__head{ display:flex; align-items:center; justify-content:space-between; gap:1rem; padding-bottom:.5rem; }
.dkx-drawer__close{
  background:var(--c-white); border:2px solid var(--c-border); border-radius:9px;
  width:42px; height:42px; cursor:pointer; color:var(--c-navy);
  display:inline-flex; align-items:center; justify-content:center;
}
.dkx-drawer__close:hover{ border-color:var(--c-teal); }
.dkx-drawer__close svg{ width:18px; height:18px; }
.dkx-drawer ul{ list-style:none; margin:0; padding:0; }
.dkx-drawer > .dkx-drawer__panel > ul > li{ border-bottom:1px solid var(--c-border); }
.dkx-drawer a{
  display:block; padding:.85rem .25rem; color:var(--c-navy);
  font-weight:700; font-size:1.02rem; text-decoration:none;
}
.dkx-drawer a:hover,.dkx-drawer a:focus-visible{ color:var(--c-teal-ink); }
.dkx-drawer details > summary{
  list-style:none; cursor:pointer; padding:.85rem .25rem;
  font-weight:700; font-size:1.02rem; color:var(--c-navy);
  display:flex; align-items:center; justify-content:space-between;
}
.dkx-drawer details > summary::-webkit-details-marker{ display:none; }
.dkx-drawer details > summary svg{ width:16px; height:16px; transition:transform var(--t-fast); }
.dkx-drawer details[open] > summary svg{ transform:rotate(180deg); }
.dkx-drawer details ul{ padding:0 0 .5rem .8rem; }
.dkx-drawer details a{ font-weight:500; font-size:.96rem; padding:.55rem .25rem; }
.dkx-drawer__cta{ display:grid; gap:.6rem; margin-top:1rem; }

/* ---------------------------------------------------------------
   Footer
--------------------------------------------------------------- */
.dkx-footer{ background:var(--c-navy-dark); color:#C9D9E6; padding:var(--section-y) 0 0; }
.dkx-footer__grid{
  display:grid; gap:2.5rem;
  grid-template-columns:1fr;
  padding-bottom:2.5rem;
}
@media (min-width:700px){ .dkx-footer__grid{ grid-template-columns:1fr 1fr; } }
@media (min-width:1024px){ .dkx-footer__grid{ grid-template-columns:1.5fr 1fr 1fr 1.3fr; gap:2rem; } }
.dkx-footer h2{ color:var(--c-white); font-size:1.02rem; font-weight:700; letter-spacing:.04em; text-transform:uppercase; margin-bottom:1.1rem; }
.dkx-footer ul{ list-style:none; margin:0; padding:0; display:grid; gap:.6rem; }
.dkx-footer a{ color:#C9D9E6; text-decoration:none; }
.dkx-footer a:hover,.dkx-footer a:focus-visible{ color:var(--c-white); text-decoration:underline; }
.dkx-footer__brandtext{ margin:1.1rem 0 1.25rem; font-size:.95rem; color:#AFC4D6; max-width:36ch; }
.dkx-footer__logo img{ height:64px; width:auto; background:var(--c-white); border-radius:12px; padding:.5rem .7rem; }
.dkx-footer address{ font-style:normal; display:grid; gap:.75rem; font-size:.95rem; }
.dkx-footer__row{ display:flex; align-items:flex-start; gap:.65rem; }
.dkx-footer__row svg{ width:17px; height:17px; flex:none; margin-top:.28rem; color:var(--c-teal); }
.dkx-hours{ display:grid; gap:.25rem; margin-top:.15rem; font-size:.92rem; }
.dkx-hours div{ display:flex; justify-content:space-between; gap:1rem; max-width:250px; }
.dkx-hours dt,.dkx-hours dd{ margin:0; }
.dkx-hours dd{ font-variant-numeric:tabular-nums; color:var(--c-white); }
.dkx-social{ display:flex; gap:.5rem; margin-top:.25rem; }
.dkx-social a{
  width:40px; height:40px; border-radius:10px; background:rgba(255,255,255,.09);
  display:inline-flex; align-items:center; justify-content:center;
}
.dkx-social a:hover,.dkx-social a:focus-visible{ background:var(--c-teal); }
.dkx-social svg{ width:19px; height:19px; color:var(--c-white); }
.dkx-footer__bottom{
  border-top:1px solid rgba(255,255,255,.14);
  padding:1.35rem 0 1.6rem;
  display:flex; flex-wrap:wrap; gap:.6rem 1.4rem; justify-content:space-between;
  font-size:.87rem; color:#9FB6C9;
}
.dkx-footer__bottom ul{ display:flex; flex-wrap:wrap; gap:.6rem 1.4rem; }

/* ---------------------------------------------------------------
   Mobile sticky action bar
--------------------------------------------------------------- */
.dkx-mobilebar{
  display:none;
  position:fixed; left:0; right:0; bottom:0; z-index:110;
  background:var(--c-white);
  border-top:1px solid var(--c-border);
  box-shadow:0 -6px 24px rgba(16,42,67,.12);
  padding:.55rem .75rem calc(.55rem + env(safe-area-inset-bottom));
  gap:.55rem;
}
.dkx-mobilebar .dkx-btn{ flex:1; padding:.85rem .5rem; font-size:.95rem; }
@media (max-width:768px){
  .dkx-mobilebar{ display:flex; }
  body{ padding-bottom:74px; }
}

/* ---------------------------------------------------------------
   Reveal-on-scroll (opt-in, motion-safe)
--------------------------------------------------------------- */
@media (prefers-reduced-motion:no-preference){
  .dkx-reveal{ opacity:0; transform:translateY(16px); transition:opacity 520ms var(--ease), transform 520ms var(--ease); }
  .dkx-reveal.is-in{ opacity:1; transform:none; }
}

@media print{
  .dkx-topbar,.dkx-nav,.dkx-footer,.dkx-mobilebar,.dkx-drawer,.dkx-skip{ display:none!important; }
}
