/* ==========================================================================
   ZM Dental Studio — Base: reset, custom properties, typography
   ========================================================================== */

:root {
  /* Colors */
  --ink: #16202b;
  --ink-soft: #3a4552;
  --body: #5b6672;
  --muted: #8993a1;
  --line: #e6e9ec;
  --line-soft: #f0f2f4;
  --bg: #ffffff;
  --bg-soft: #f6f7f8;
  --bg-soft-2: #f1f3f4;

  --accent: #2f8f8a;
  --accent-dark: #226e6a;
  --accent-soft: #e6f2f1;
  --accent-ink: #0d3a37;

  --white: #ffffff;

  /* Glass */
  --glass-bg: rgba(255, 255, 255, 0.14);
  --glass-bg-strong: rgba(255, 255, 255, 0.22);
  --glass-border: rgba(255, 255, 255, 0.35);
  --glass-dark-bg: rgba(22, 32, 43, 0.35);

  /* Typography */
  --font-sans:
    -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue",
    Arial, sans-serif;

  /* Spacing scale */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.5rem;
  --space-6: 1.75rem;
  --space-7: 2.5rem;
  --space-8: 3.25rem;
  --space-9: 4.5rem;
  --space-10: 6rem;

  /* Layout */
  --container-w: 1200px;
  --container-pad: clamp(1.25rem, 4vw, 2.5rem);
  /* left inset of .container content — used to line up full-bleed sections
     (e.g. the hero photo) with the rest of the page's left margin */
  --container-inset: max(var(--container-pad), calc((100vw - var(--container-w)) / 2 + var(--container-pad)));
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-pill: 999px;

  /* Motion */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --dur-fast: 0.2s;
  --dur-base: 0.4s;
  --dur-slow: 0.7s;

  --shadow-sm: 0 1px 2px rgba(22, 32, 43, 0.06), 0 1px 1px rgba(22, 32, 43, 0.04);
  --shadow-md: 0 8px 24px rgba(22, 32, 43, 0.08), 0 2px 6px rgba(22, 32, 43, 0.04);
  --shadow-lg: 0 24px 60px rgba(22, 32, 43, 0.14), 0 8px 20px rgba(22, 32, 43, 0.06);
  /* zero-alpha twins of the shadows above, same layer structure — used as
     the resting state so hover-in/hover-out interpolates the shadow
     smoothly instead of snapping from "none" */
  --shadow-md-0: 0 8px 24px rgba(22, 32, 43, 0), 0 2px 6px rgba(22, 32, 43, 0);
  --shadow-lg-0: 0 24px 60px rgba(22, 32, 43, 0), 0 8px 20px rgba(22, 32, 43, 0);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--body);
  background: var(--bg);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

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

img {
  height: auto;
}

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

ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

button {
  font-family: inherit;
  cursor: pointer;
}

input,
textarea,
select,
button {
  font: inherit;
  color: inherit;
}

/* Custom cursor — only on mouse/trackpad devices; text fields keep the
   native caret cursor since the dot/ring can't show precise text position */
@media (hover: hover) and (pointer: fine) {
  body,
  a,
  button,
  .btn {
    cursor: none;
  }
  input,
  textarea,
  select {
    cursor: auto;
  }
}

h1,
h2,
h3,
h4,
h5,
h6 {
  margin: 0;
  color: var(--ink);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
}

p {
  margin: 0;
}

h1 {
  font-size: clamp(1.9rem, 1.5rem + 1.9vw, 3rem);
}

h2 {
  font-size: clamp(1.5rem, 1.25rem + 1.1vw, 2.1rem);
}

h3 {
  font-size: clamp(1.15rem, 1.05rem + 0.5vw, 1.4rem);
}

.container {
  width: 100%;
  max-width: var(--container-w);
  margin-inline: auto;
  padding-inline: var(--container-pad);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-dark);
}

.eyebrow::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--space-5);
  margin-bottom: var(--space-7);
}

.section-head__text {
  max-width: 640px;
}

.section-head p {
  margin-top: var(--space-3);
  font-size: 1.05rem;
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: var(--space-4);
  top: -60px;
  background: var(--ink);
  color: var(--white);
  padding: var(--space-3) var(--space-5);
  border-radius: var(--radius-sm);
  z-index: 1000;
  transition: top var(--dur-fast) var(--ease-out);
}

.skip-link:focus {
  top: var(--space-4);
}

::selection {
  background: var(--accent);
  color: var(--white);
}
