/* Roots Dental Clinic. The look and its rules: DESIGN.md. */
:root {
  --paper: #F2F5EF; --paper-2: #E4EBE0; --ink: #16201A; --ink-2: #4A564E; --rule: #CBD6C7;
  --leaf: #3E8E4F; --leaf-btn: #2E7A43; --leaf-deep: #21593A; --leaf-pale: #CFE3CF;
  --soil: #1E2A22; --soil-2: #2A3A2F; --night-text: #E9F0E6; --night-2: #A9B8AA; --neon: #5BE3B4;
  --font: "Readex", system-ui, -apple-system, "Segoe UI", Tahoma, sans-serif;
  --gutter: clamp(16px, 4.5vw, 56px); --max: 1180px; --sec: clamp(72px, 11vw, 140px);
  --r: 18px;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 84px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 17px/1.75 var(--font); -webkit-font-smoothing: antialiased; overflow-x: clip; }
[lang="en"] body, html[lang="en"] body { line-height: 1.6; }
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { margin: 0; font-weight: 600; line-height: 1.3; }
p { margin: 0; }
:focus-visible { outline: 3px solid var(--leaf); outline-offset: 3px; border-radius: 6px; }
.skip { position: absolute; inset-inline-start: 12px; top: -60px; background: var(--ink); color: #fff; padding: 8px 14px; border-radius: 8px; z-index: 50; }
.skip:focus { top: 12px; }
.preview-flag { position: fixed; top: 0; inset-inline: 0; z-index: 60; background: #8a4b00; color: #fff; text-align: center; padding: 6px; font-size: 14px; }
.i { width: 20px; height: 20px; flex: none; }

/* Buttons: pills, the only round things. */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 50px; padding: 10px 24px; border-radius: 999px; font: 600 16px/1.2 var(--font); text-decoration: none; border: 1.5px solid transparent; transition: background-color .2s, color .2s, border-color .2s, transform .15s; }
.btn:active { transform: scale(.98); }
.btn--leaf { background: var(--leaf-btn); color: #fff; }
@media (hover: hover) { .btn--leaf:hover { background: var(--leaf-deep); } .btn--line:hover { border-color: var(--ink); } }
.btn--line { border-color: var(--rule); color: var(--ink); background: transparent; }

/* Bar */
.bar { position: sticky; top: 0; z-index: 30; display: flex; align-items: center; gap: 24px; padding: 12px var(--gutter); background: rgba(242, 245, 239, .94); backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid transparent; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.brand__mark { width: 34px; height: 39px; flex: none; }
.brand__name { display: flex; flex-direction: column; line-height: 1.1; }
.brand__word { font-weight: 600; font-size: 22px; letter-spacing: .01em; }
.brand__sub { font-size: 12.5px; color: var(--ink-2); }
.bar__nav { display: flex; gap: 22px; margin-inline-start: auto; }
.bar__nav a { text-decoration: none; color: var(--ink-2); font-size: 15.5px; padding: 6px 2px; }
@media (hover: hover) { .bar__nav a:hover { color: var(--ink); } }
.bar__end { display: flex; align-items: center; gap: 14px; }
.bar__lang { font-size: 15px; color: var(--ink-2); text-decoration: none; padding: 8px 4px; }
.bar__book { min-height: 44px; padding: 8px 18px; font-size: 15px; }
@media (max-width: 900px) {
  .bar__nav { display: none; }
  .bar__end { margin-inline-start: auto; }
  .bar__book { display: none; }
}

/* Hero: words on paper, beside the clinic's own front at night. */
.hero { max-width: var(--max); margin: 0 auto; padding: clamp(28px, 5vw, 64px) var(--gutter) var(--sec); display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(28px, 5vw, 72px); align-items: center; }
.hero__mark { width: 74px; height: 85px; margin-bottom: 26px; }
.hero__title { font-size: clamp(40px, 6.4vw, 78px); line-height: 1.22; font-weight: 600; letter-spacing: -.01em; }
html[lang="en"] .hero__title { line-height: 1.08; letter-spacing: -.02em; }
.hero__lede { margin-top: 22px; font-size: clamp(17px, 1.6vw, 20px); color: var(--ink-2); max-width: 34em; }
.hero__acts { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.hero__hours { margin-top: 24px; font-size: 15px; color: var(--ink-2); }
.hero__hours b { color: var(--ink); font-weight: 600; margin-inline-start: 6px; }
.hero__night { margin: 0; position: relative; }
.hero__photo { width: 100%; aspect-ratio: 640 / 880; max-height: 78vh; object-fit: cover; border-radius: var(--r); background: var(--soil); }
.hero__night figcaption { margin-top: 10px; font-size: 14px; color: var(--ink-2); }
@media (max-width: 820px) {
  .hero { grid-template-columns: 1fr; padding-top: 20px; }
  .hero__mark { width: 54px; height: 62px; margin-bottom: 16px; }
  .hero__photo { aspect-ratio: 4 / 3.4; max-height: none; object-position: 50% 62%; }
  .hero__acts .btn { flex: 1 1 auto; }
}

/* Section heads */
.shead { max-width: 40em; margin-bottom: clamp(36px, 5vw, 64px); }
.shead__note { color: var(--leaf-deep); font-size: 15.5px; margin-bottom: 10px; }
.shead__title { font-size: clamp(30px, 4.2vw, 50px); line-height: 1.3; }
.shead__lede { margin-top: 14px; color: var(--ink-2); font-size: 18px; }
.sec { max-width: var(--max); margin: 0 auto; padding: var(--sec) var(--gutter) 0; }

/* The roots: one line down the page, a leaf for every treatment. */
.roots { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter) var(--sec); }
.roots__body { position: relative; }
.roots__line { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.roots__line path { fill: none; stroke: var(--ink); stroke-width: 2.25; stroke-linecap: round; stroke-linejoin: round; }
.svc { list-style: none; margin: 0; padding: 0; display: grid; gap: clamp(36px, 6vw, 72px); }
.svc__item { position: relative; display: grid; grid-template-columns: 96px 1fr minmax(0, 300px); gap: clamp(16px, 3vw, 40px); align-items: center; }
.svc__leaf { grid-column: 1; justify-self: end; width: 40px; height: 24px; }
.leaf { width: 40px; height: 24px; overflow: visible; }
.leaf path { fill: var(--leaf); }
.leaf .leaf__vein { fill: none; stroke: var(--paper); stroke-width: 1.4; stroke-linecap: round; }
html[dir="rtl"] .leaf { transform: scaleX(-1); }
.svc__text { grid-column: 2; max-width: 34em; }
.svc__title { font-size: clamp(22px, 2.5vw, 30px); }
.svc__body { margin-top: 8px; color: var(--ink-2); }
.svc__ask { display: inline-flex; align-items: center; gap: 8px; margin-top: 14px; min-height: 44px; color: var(--leaf-deep); font-weight: 600; text-decoration: none; border-bottom: 1.5px solid var(--leaf-pale); }
@media (hover: hover) { .svc__ask:hover { border-color: var(--leaf); } }
.svc__photo { grid-column: 3; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--r); background: var(--paper-2); }
@media (max-width: 760px) {
  .svc__item { grid-template-columns: 40px 1fr; align-items: start; }
  .svc__leaf { justify-self: start; margin-top: 8px; width: 28px; height: 17px; }
  .svc__leaf .leaf { width: 28px; height: 17px; }
  .svc__photo { grid-column: 2; max-width: 360px; }
}
/* The line draws itself; leaves open as their branch arrives. Without the script, all is there. */
.js-motion .svc__leaf .leaf { transform: scale(.2) rotate(-25deg); opacity: 0; transition: transform .7s cubic-bezier(.2, .9, .3, 1.3), opacity .4s; }
html[dir="rtl"].js-motion .svc__leaf .leaf { transform: scaleX(-1) scale(.2) rotate(-25deg); }
.js-motion .svc__item.is-grown .leaf { transform: none; opacity: 1; }
html[dir="rtl"].js-motion .svc__item.is-grown .leaf { transform: scaleX(-1); }

/* Whitening in four steps */
.whiten { background: var(--paper-2); }
.whiten { display: grid; grid-template-columns: 1fr minmax(0, 340px); gap: clamp(28px, 5vw, 72px); align-items: center; max-width: none; padding: var(--sec) max(var(--gutter), calc((100% - var(--max)) / 2 + var(--gutter))); }
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.steps li { display: grid; grid-template-columns: 52px 1fr; gap: 16px; align-items: center; padding: 18px 0; border-top: 1px solid var(--rule); }
.steps li:last-child { border-bottom: 1px solid var(--rule); }
.steps__n { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%; background: var(--paper); color: var(--leaf-deep); font-weight: 600; font-size: 18px; }
.steps h3 { font-size: 21px; }
.steps p { color: var(--ink-2); margin-top: 4px; }
.whiten__photo { width: 100%; max-width: 340px; aspect-ratio: 361 / 640; object-fit: cover; border-radius: var(--r); justify-self: center; }
@media (max-width: 760px) { .whiten { grid-template-columns: 1fr; } .whiten__photo { max-width: 300px; } }

/* The clinic's own work */
.work__list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: clamp(16px, 2.5vw, 28px); }
.work__list figure { margin: 0; }
.work__photo { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; border-radius: var(--r); background: var(--paper-2); }
.work__list figcaption { margin-top: 10px; font-size: 15px; color: var(--ink-2); }

/* Team */
.roster { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 28px; }
.roster__card { display: grid; gap: 4px; text-decoration: none; }
.roster__photo { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: var(--r); background: var(--paper-2); margin-bottom: 10px; }
.roster__photo--none { display: grid; place-items: center; }
.roster__photo--none svg { width: 30%; height: 40%; opacity: .5; }
.roster__name { font-weight: 600; font-size: 19px; }
.roster__role { color: var(--ink-2); font-size: 15px; }

/* Inside */
.inside__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.inside__grid img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; border-radius: var(--r); background: var(--paper-2); }
@media (max-width: 760px) { .inside__grid { grid-template-columns: repeat(2, 1fr); } }

/* Offers */
.offer { max-width: var(--max); margin: var(--sec) auto 0; padding: 0 var(--gutter); }
.offer h2 { font-size: clamp(26px, 3vw, 36px); }
.offer ul { margin: 16px 0 0; padding-inline-start: 1.2em; }
.offer li { padding: 4px 0; }
.offer li::marker { color: var(--leaf); }

/* Visit: the evening band. They open when the street lights come on. */
.visit { margin-top: var(--sec); background: var(--soil); color: var(--night-text); }
.visit__in { max-width: var(--max); margin: 0 auto; padding: var(--sec) var(--gutter); display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(32px, 5vw, 64px) clamp(32px, 6vw, 96px); }
.visit .shead { grid-column: 1 / -1; margin-bottom: 0; }
.visit .shead__lede { color: var(--night-2); }
.visit__label { color: var(--night-2); font-size: 15px; margin-bottom: 8px; }
.hours__line { font-size: clamp(22px, 2.6vw, 30px); line-height: 1.5; }
.hours__line b { display: block; font-size: clamp(40px, 6vw, 72px); line-height: 1.1; font-weight: 300; color: var(--neon); letter-spacing: .01em; }
.hours__line--off b { color: var(--night-2); }
.visit__ways { display: grid; gap: 10px; align-content: start; }
.way { display: grid; grid-template-columns: auto 1fr; column-gap: 12px; align-items: center; padding: 16px 20px; border-radius: 14px; border: 1px solid var(--soil-2); text-decoration: none; color: var(--night-text); transition: border-color .2s, background-color .2s; }
.way b { font-weight: 600; grid-column: 1 / -1; }
.way span { grid-column: 1 / -1; color: var(--night-2); font-size: 15px; }
.way--wa { background: var(--leaf-btn); border-color: var(--leaf-btn); color: #fff; grid-template-columns: 24px 1fr; }
.way--wa .i { grid-row: 1 / 3; width: 24px; height: 24px; }
.way--wa b, .way--wa span { grid-column: 2; }
.way--wa span { color: #E3F2E5; }
@media (hover: hover) { .way:hover { border-color: var(--night-2); } .way--wa:hover { background: var(--leaf-deep); } }
.visit__where address { font-style: normal; font-size: 19px; }
.visit .link { display: inline-block; margin-top: 10px; color: var(--neon); }
.visit__pay { margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--soil-2); color: var(--night-2); font-size: 15.5px; }
@media (max-width: 760px) { .visit__in { grid-template-columns: 1fr; } }

/* Foot */
.foot { background: var(--soil); color: var(--night-2); border-top: 1px solid var(--soil-2); }
.foot__in { max-width: var(--max); margin: 0 auto; padding: 32px var(--gutter) calc(32px + env(safe-area-inset-bottom)); display: grid; gap: 8px; font-size: 15px; }
.brand--light { color: var(--night-text); }
.brand--light .brand__sub { color: var(--night-2); }
.brand--light .brand__mark { filter: invert(.92) hue-rotate(180deg); }
.foot a { color: var(--night-text); }
.sep { display: inline-block; width: 4px; height: 4px; border-radius: 50%; background: var(--night-2); vertical-align: middle; margin: 0 8px; }

/* Phone dock: book and call, always under the thumb. */
.dock { display: none; }
@media (max-width: 900px) {
  .dock { display: flex; gap: 8px; position: fixed; inset-inline: 0; bottom: 0; z-index: 40; padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); background: rgba(242, 245, 239, .96); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-top: 1px solid var(--rule); }
  .dock a { min-height: 50px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; border-radius: 999px; text-decoration: none; font-weight: 600; }
  .dock__main { flex: 1; background: var(--leaf-btn); color: #fff; }
  .dock__call { padding: 0 22px; border: 1.5px solid var(--rule); }
  .foot__in { padding-bottom: calc(100px + env(safe-area-inset-bottom)); }
}

/* A dentist's page */
.dr { max-width: var(--max); margin: 0 auto; padding: 32px var(--gutter) var(--sec); }
.dr__hero { display: grid; grid-template-columns: minmax(0, 380px) 1fr; gap: clamp(24px, 5vw, 64px); align-items: end; }
.dr__photo { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: var(--r); background: var(--paper-2); }
.dr__back { color: var(--ink-2); font-size: 15px; }
.dr__name { font-size: clamp(32px, 4.6vw, 54px); margin: 14px 0 6px; }
.dr__role { color: var(--ink-2); font-size: 19px; margin-bottom: 24px; }
.dr__body { display: grid; grid-template-columns: 1.4fr 1fr; gap: 48px; margin-top: 56px; }
.dr__bio p + p { margin-top: 1em; }
.dr__treats h2 { font-size: 20px; margin-bottom: 10px; }
.dr__treats ul { margin: 0; padding-inline-start: 1.2em; }
.dr__nav { display: flex; justify-content: space-between; align-items: center; margin-top: 64px; padding-top: 20px; border-top: 1px solid var(--rule); }
.dr__nav a { text-decoration: none; display: grid; }
.dr__nav small { color: var(--ink-2); }
@media (max-width: 760px) { .dr__hero, .dr__body { grid-template-columns: 1fr; } }
