/* Spacing is on an 8px grid: 8, 16, 24, 32, 48, 64. */
:root {
  --bg: #fbf8f3;
  --ink: #221d17;
  --soft: #74695d;
  --line: #e9e1d5;
  --card: #ffffff;
  --accent: #b5441a;
  --accent-ink: #ffffff;
  --focus: #b5441a66;
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  --serif: ui-serif, "New York", "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1b1814;
    --ink: #f2ece3;
    --soft: #a99d8f;
    --line: #342e28;
    --card: #24201b;
    --accent: #e57a4a;
    --accent-ink: #1b1814;
    --focus: #e57a4a77;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 17px/1.55 var(--sans);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}
main {
  max-width: 640px;
  margin: 0 auto;
  padding: 24px max(24px, env(safe-area-inset-right)) 64px max(24px, env(safe-area-inset-left));
}
a { color: var(--accent); text-underline-offset: 3px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 6px; }

.mark {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 64px;
  color: var(--ink);
  font-weight: 600;
  text-decoration: none;
}

h1, h2 { font-family: var(--serif); font-weight: 600; line-height: 1.15; text-wrap: balance; }
h1 { font-size: clamp(2.25rem, 7vw, 3rem); letter-spacing: -0.015em; margin: 0 0 16px; }
h2 { font-size: 1.375rem; margin: 64px 0 16px; }
p, li { text-wrap: pretty; }
.lead { font-size: 1.1875rem; color: var(--soft); margin: 0; }

.button, button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 50px;
  font: 600 1.0625rem var(--sans);
  background: var(--accent);
  color: var(--accent-ink);
  border: 1px solid var(--accent);
  border-radius: 12px;
  padding: 0 24px;
  text-decoration: none;
  cursor: pointer;
  transition: filter 0.15s;
}
.button:hover, button:hover { filter: brightness(1.06); }
.button:active, button:active { filter: brightness(0.94); }
button.quiet { background: transparent; color: var(--accent); }
@media (min-width: 560px) { .button, button { width: auto; display: inline-flex; } }

ul, ol { margin: 0; padding: 0; list-style: none; }
.lines li, ol li { position: relative; padding: 12px 0 12px 24px; border-top: 1px solid var(--line); }
.lines li:last-child, ol li:last-child { border-bottom: 1px solid var(--line); }
.lines li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 23px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}
ol { counter-reset: step; }
ol li { counter-increment: step; padding-left: 32px; }
ol li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 12px;
  color: var(--accent);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

/* home page: wider than the 640px text column */
.wrap {
  max-width: 1040px;
  margin: 0 auto;
  padding: 24px max(24px, env(safe-area-inset-right)) 64px max(24px, env(safe-area-inset-left));
}
.wrap main { max-width: none; padding: 0; }
.narrow { max-width: 640px; margin-left: auto; margin-right: auto; }
.top { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 48px; }
.top .mark { margin: 0; }
.top nav { display: flex; gap: 24px; font-size: 0.9375rem; }
.top nav a { color: var(--soft); text-decoration: none; }
.top nav a:hover { color: var(--ink); }
@media (max-width: 480px) { .top nav a:not([href="#plans"]) { display: none; } }

.hero { display: grid; gap: 48px; align-items: center; }
.hero .lead { margin-bottom: 32px; }
.phone img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--line);
  border-radius: 32px;
  box-shadow: 0 24px 48px -24px #2a211840;
}
.hero .phone { width: min(300px, 80%); margin: 0 auto; }
@media (min-width: 860px) {
  .hero { grid-template-columns: 1fr 300px; gap: 64px; padding: 24px 0; }
  .hero .phone { width: 300px; }
  h1 { font-size: 3.25rem; }
}

.note { color: var(--soft); margin: 0; }
.gallery {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 240px;
  gap: 24px;
  margin: 32px calc(-1 * max(24px, env(safe-area-inset-left))) 0;
  padding: 0 max(24px, env(safe-area-inset-left)) 16px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding: 0 24px;
  scrollbar-width: none;
}
.gallery::-webkit-scrollbar { display: none; }
.gallery li { scroll-snap-align: start; }
.gallery img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--card);
}
.gallery p { margin: 16px 0 0; font-size: 0.9375rem; color: var(--soft); }
.gallery strong { color: var(--ink); }
@media (min-width: 1000px) {
  .gallery { grid-auto-flow: row; grid-template-columns: repeat(4, 1fr); margin: 32px 0 0; padding: 0; overflow: visible; }
}

.plans { display: grid; gap: 24px; }
@media (min-width: 720px) { .plans { grid-template-columns: 1fr 1fr; } }
.plan {
  display: flex;
  flex-direction: column;
  padding: 32px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 20px;
  scroll-margin-top: 24px;
}
.plan h3 { font-family: var(--serif); font-size: 1.5rem; margin: 0 0 8px; }
.plan .amount { margin: 0 0 16px; color: var(--soft); }
.plan .amount strong { color: var(--ink); font-size: 1.75rem; font-weight: 600; }
.plan > p { margin: 0 0 16px; }
.plan ul { margin: 0 0 32px; flex: 1; }
.plan ul li { position: relative; padding: 6px 0 6px 28px; }
.plan ul li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 12px;
  width: 12px;
  height: 7px;
  border-left: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  transform: rotate(-45deg);
}
.plan button { width: 100%; }
h3 { font-size: 1.0625rem; margin: 32px 0 8px; }

details { border-top: 1px solid var(--line); }
details:last-of-type { border-bottom: 1px solid var(--line); }
summary {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 0;
  cursor: pointer;
  font-weight: 600;
  list-style: none;
}
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; color: var(--soft); font-weight: 400; transition: transform 0.2s; }
details[open] summary::after { transform: rotate(45deg); }
details p { margin: 0 0 16px; color: var(--soft); }

footer { margin-top: 64px; color: var(--soft); font-size: 0.9375rem; }
footer a { color: inherit; }

/* intake form */
form.intake h2 { margin-top: 48px; }
form.intake label { display: block; font-weight: 600; margin: 24px 0 8px; }
form.intake fieldset { border: 0; padding: 0; margin: 24px 0 0; }
form.intake legend { font-weight: 600; padding: 0; margin-bottom: 8px; }
form.intake fieldset label { display: inline-flex; align-items: center; gap: 8px; font-weight: 400; margin: 0 24px 8px 0; }
input[type=text], input[type=url], input[type=email], input[type=tel], textarea {
  display: block;
  width: 100%;
  min-height: 48px;
  font: inherit;
  color: var(--ink);
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 12px 16px;
  appearance: none;
}
textarea { min-height: 96px; resize: vertical; }
input:focus, textarea:focus { outline: 3px solid var(--focus); outline-offset: 0; border-color: var(--accent); }
input[type=checkbox], input[type=radio] { width: 20px; height: 20px; margin: 0; accent-color: var(--accent); }
form.intake button { margin-top: 48px; }
.hp { position: absolute; left: -9999px; }
.wrap h2 { font-size: 1.75rem; }
