/* =========================================================================
   HomeCloser.ai — design system
   Inspired by envoy.com + spac.io: warm cream surfaces, deep ink text,
   editorial serif headlines, generous whitespace, soft cards.
   ========================================================================= */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,400;9..144,500;9..144,600;9..144,700&family=Inter:wght@400;500;600;700&display=swap');

:root {
  /* Palette */
  --cream:        #faf7f0;
  --cream-soft:   #f5f1e6;
  --paper:        #ffffff;
  --ink:          #0d0d0d;
  --ink-soft:     #2a2a2a;
  --muted:        #6b6962;
  --line:         #e8e3d6;
  --line-soft:    #f0ece1;

  --sage:         #1f5f4a;   /* primary brand */
  --sage-dark:    #16463a;
  --sage-soft:    #e6efe9;
  --amber:        #d97706;   /* secondary accent */
  --amber-soft:   #fef3e2;
  --blush:        #f4e4d6;   /* tertiary surface */
  --sky:          #dde8ee;

  --danger:       #b42318;
  --success:      #1f5f4a;
  --warning:      #b45309;

  --radius-sm:    8px;
  --radius:       14px;
  --radius-lg:    22px;
  --radius-pill:  999px;

  --shadow-xs:    0 1px 2px rgba(13,13,13,0.04);
  --shadow-sm:    0 2px 8px rgba(13,13,13,0.05);
  --shadow:       0 12px 40px rgba(13,13,13,0.08);
  --shadow-lg:    0 24px 80px rgba(13,13,13,0.12);

  --font-sans:    'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-serif:   'Fraunces', 'Iowan Old Style', 'Apple Garamond', Georgia, serif;
}

/* ---------- Reset & base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font-sans);
  background: var(--cream);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
a { color: var(--ink); text-decoration: none; transition: color 0.15s ease; }
a:hover { color: var(--sage); }
img, svg { max-width: 100%; display: block; }

h1, h2, h3, h4 {
  font-family: var(--font-serif);
  font-weight: 500;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin: 0 0 0.5em;
  line-height: 1.1;
}
h1 { font-size: clamp(2rem, 4.4vw, 3.4rem); }
h2 { font-size: clamp(1.5rem, 2.6vw, 2.1rem); }
h3 { font-size: 1.25rem; font-family: var(--font-sans); font-weight: 600; letter-spacing: -0.01em; }
h4 { font-size: 1rem; font-family: var(--font-sans); font-weight: 600; }
p  { margin: 0 0 1em; }

::selection { background: var(--sage); color: var(--cream); }

/* ---------- Top bar ---------- */
.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 32px;
  background: rgba(250, 247, 240, 0.85);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 100;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-serif);
  font-weight: 600;
  font-size: 20px;
  letter-spacing: -0.02em;
  color: var(--ink);
}
.brand-mark {
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  background: var(--sage);
  color: var(--cream);
}
.brand-mark svg { width: 18px; height: 18px; }
.topbar nav { display: flex; gap: 6px; align-items: center; }
.topbar nav a:not(.btn) {
  color: var(--ink-soft);
  font-size: 14px;
  font-weight: 500;
  padding: 8px 14px;
  border-radius: var(--radius-pill);
  transition: background 0.15s ease, color 0.15s ease;
}
.topbar nav a:not(.btn):hover { background: var(--cream-soft); color: var(--ink); }

/* ---------- Layout ---------- */
.container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 40px 32px 80px;
}
.container-narrow { max-width: 760px; margin: 0 auto; padding: 40px 32px 80px; }
.section { padding: 80px 0; }
.section-tight { padding: 48px 0; }

/* ---------- Flash messages ---------- */
.flash {
  padding: 12px 18px;
  border-radius: var(--radius);
  margin-bottom: 16px;
  font-size: 14px;
  font-weight: 500;
  border: 1px solid transparent;
}
.flash.error   { background: #fdecea; color: var(--danger); border-color: #f5c4be; }
.flash.success { background: var(--sage-soft); color: var(--sage-dark); border-color: #c3dccd; }
.flash.warning { background: var(--amber-soft); color: var(--warning); border-color: #f5d8a8; }

/* ---------- Buttons ---------- */
.btn, button.btn, input[type=submit].btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  background: var(--ink);
  color: var(--cream);
  border: 1px solid var(--ink);
  border-radius: var(--radius-pill);
  cursor: pointer;
  text-decoration: none;
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.01em;
  transition: transform 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
  white-space: nowrap;
}
.btn:hover { background: var(--sage-dark); border-color: var(--sage-dark); color: var(--cream); transform: translateY(-1px); box-shadow: var(--shadow-sm); }
.btn.primary { background: var(--sage); border-color: var(--sage); }
.btn.primary:hover { background: var(--sage-dark); border-color: var(--sage-dark); }
.btn.secondary { background: var(--paper); color: var(--ink); border: 1px solid var(--line); }
.btn.secondary:hover { background: var(--cream-soft); color: var(--ink); border-color: var(--ink); }
.btn.ghost { background: transparent; color: var(--ink); border: 1px solid transparent; }
.btn.ghost:hover { background: var(--cream-soft); color: var(--ink); }
.btn.danger { background: var(--danger); border-color: var(--danger); }
.btn.danger:hover { background: #8c190f; border-color: #8c190f; }
.btn.lg { padding: 16px 28px; font-size: 15px; }
.btn .arrow { transition: transform 0.15s ease; }
.btn:hover .arrow { transform: translateX(2px); }

button.link {
  background: none;
  border: 0;
  color: var(--ink-soft);
  cursor: pointer;
  padding: 8px 14px;
  font-family: inherit;
  font-size: 14px;
  font-weight: 500;
  border-radius: var(--radius-pill);
}
button.link:hover { background: var(--cream-soft); color: var(--ink); }
.inline { display: inline; }

/* ---------- Forms ---------- */
form.stacked { display: flex; flex-direction: column; gap: 16px; max-width: 480px; }
form.stacked label {
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-soft);
  display: flex;
  flex-direction: column;
  gap: 6px;
}
form.stacked input,
form.stacked textarea,
form.stacked select {
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  font-family: var(--font-sans);
  font-size: 15px;
  color: var(--ink);
  background: var(--paper);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
form.stacked input:focus,
form.stacked textarea:focus,
form.stacked select:focus {
  outline: none;
  border-color: var(--sage);
  box-shadow: 0 0 0 3px rgba(31,95,74,0.12);
}

/* Inline option labels: keep radio/checkbox on the same row as their text. */
form.stacked label.radio,
form.stacked label.checkbox-inline {
  flex-direction: row;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  font-weight: 400;
  color: var(--ink);
  cursor: pointer;
}
form.stacked label.radio input,
form.stacked label.checkbox-inline input {
  width: auto;
  padding: 0;
  margin: 0;
  accent-color: var(--sage);
}

/* Calling-hour windows: pill-shaped checkboxes that highlight when active. */
.hours-windows {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.hours-window {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-pill);
  background: var(--paper);
  cursor: pointer;
  user-select: none;
  font-size: 14px;
  font-weight: 500;
  color: var(--ink);
  transition: border-color 0.15s ease, background 0.15s ease;
}
.hours-window input { width: 16px; height: 16px; margin: 0; accent-color: var(--sage); }
.hours-window:has(input:checked) {
  border-color: var(--sage);
  background: var(--sage-soft);
}

/* Open-house multi-date picker: chips for selected dates + weekend quick-picks. */
.oh-date-picker { display: flex; flex-direction: column; gap: 12px; }
.oh-quickpicks { display: flex; flex-wrap: wrap; gap: 8px; }
.oh-quickpicks .btn { font-size: 13px; padding: 8px 14px; }
.oh-add-date { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.oh-add-date input[type="date"] { flex: 0 1 200px; }
.oh-date-chips { display: flex; flex-wrap: wrap; gap: 8px; min-height: 24px; }
.oh-date-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 8px 6px 12px;
  border: 1px solid var(--sage);
  border-radius: var(--radius-pill);
  background: var(--sage-soft);
  font-size: 13px;
  font-weight: 500;
  color: var(--ink);
}
.oh-date-chip-x {
  background: transparent;
  border: 0;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 16px;
  line-height: 1;
  color: var(--muted);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.oh-date-chip-x:hover { background: rgba(0,0,0,0.06); color: var(--ink); }
.oh-date-empty { font-size: 13px; }

/* "Working with an agent?" style fieldset — used both on the kiosk and on
   listing-detail visitor forms. Kiosk-specific overrides live further below. */
.agent-q {
  border: 1.5px solid var(--line);
  border-radius: 12px;
  padding: 14px 16px;
  margin: 0;
  background: var(--cream-soft);
}
.agent-q legend {
  float: left;
  width: 100%;
  padding: 0;
  margin-bottom: 10px;
  font-size: 13px;
  color: var(--muted);
  font-weight: 500;
}
.agent-q legend + * { clear: left; }
.agent-q .radio { margin-right: 20px; }

/* ---------- Cards ---------- */
.card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 18px;
  box-shadow: var(--shadow-xs);
}
.card-soft {
  background: var(--cream-soft);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  padding: 24px;
}

/* ---------- Open-house stats row ---------- */
.oh-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 14px;
  margin-bottom: 28px;
}
.oh-stat {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px 20px;
  box-shadow: var(--shadow-xs);
}
.oh-stat .num {
  font-family: var(--font-serif);
  font-size: 2rem;
  font-weight: 600;
  color: var(--sage);
  line-height: 1;
}
.oh-stat .label {
  margin-top: 6px;
  font-size: 12px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* ---------- Tables ---------- */
table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
th, td {
  text-align: left;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line-soft);
  font-size: 14px;
}
th {
  background: var(--cream-soft);
  color: var(--muted);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: 11px;
}
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: var(--cream); }

/* ---------- Utility ---------- */
.muted { color: var(--muted); font-size: 14px; }
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--sage);
}
.eyebrow::before {
  content: "";
  display: inline-block;
  width: 24px;
  height: 1px;
  background: var(--sage);
}
.row { display: flex; gap: 20px; flex-wrap: wrap; }
.row > * { flex: 1; min-width: 240px; }
.tag {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  background: var(--sage-soft);
  color: var(--sage-dark);
  font-size: 12px;
  font-weight: 500;
}
.tag.amber { background: var(--amber-soft); color: var(--warning); }
.tag.gray  { background: var(--cream-soft); color: var(--muted); }

/* =========================================================================
   LANDING PAGE
   ========================================================================= */

.hero {
  padding: 72px 32px 60px;
  position: relative;
  overflow: hidden;
}
.hero-grid {
  max-width: 1240px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 64px;
  align-items: center;
}
.hero h1 {
  font-size: clamp(2.6rem, 5.4vw, 4.8rem);
  line-height: 1.02;
  letter-spacing: -0.035em;
  margin-bottom: 22px;
}
.hero h1 em {
  font-style: italic;
  color: var(--sage);
  font-weight: 400;
}
.hero-lead {
  font-size: 18px;
  line-height: 1.55;
  color: var(--ink-soft);
  max-width: 540px;
  margin-bottom: 32px;
}
.hero-cta {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 28px;
}
.hero-meta {
  display: flex;
  align-items: center;
  gap: 18px;
  color: var(--muted);
  font-size: 13px;
}
.hero-meta .dot { width: 4px; height: 4px; border-radius: 50%; background: var(--muted); }

.hero-art {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 480px;
}
.hero-art .blob {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.hero-art .ipad-stage {
  position: relative;
  z-index: 1;
}

/* logo strip */
.logo-strip {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--cream-soft);
  padding: 28px 32px;
}
.logo-strip-inner {
  max-width: 1180px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 36px;
  flex-wrap: wrap;
  justify-content: space-between;
}
.logo-strip .label {
  font-size: 12px;
  font-weight: 500;
  color: var(--muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.logo-strip ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 36px;
  flex-wrap: wrap;
  align-items: center;
}
.logo-strip li {
  font-family: var(--font-serif);
  color: var(--muted);
  font-size: 18px;
  font-weight: 500;
  letter-spacing: -0.01em;
  opacity: 0.8;
}

/* feature blocks */
.feature-block {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
  padding: 60px 0;
}
.feature-block.reverse { direction: rtl; }
.feature-block.reverse > * { direction: ltr; }
.feature-block h2 {
  font-size: clamp(1.8rem, 3.2vw, 2.6rem);
  margin-bottom: 18px;
}
.feature-block .lead {
  font-size: 17px;
  color: var(--ink-soft);
  margin-bottom: 24px;
}
.feature-list {
  list-style: none;
  margin: 0 0 28px;
  padding: 0;
}
.feature-list li {
  display: flex;
  gap: 12px;
  padding: 10px 0;
  font-size: 15px;
  color: var(--ink-soft);
}
.feature-list li::before {
  content: "";
  flex: 0 0 18px;
  width: 18px;
  height: 18px;
  margin-top: 3px;
  background: var(--sage);
  border-radius: 50%;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 18 18' fill='none'><path d='M5 9.5l3 3 5-7' stroke='%23faf7f0' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/></svg>");
  background-position: center;
  background-repeat: no-repeat;
}
.feature-art {
  position: relative;
  border-radius: var(--radius-lg);
  padding: 36px;
  background: var(--cream-soft);
  min-height: 360px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.feature-art.sage   { background: linear-gradient(135deg, #e6efe9, #c8dccd); }
.feature-art.blush  { background: linear-gradient(135deg, #f4e4d6, #ecc8a8); }
.feature-art.sky    { background: linear-gradient(135deg, #dde8ee, #b8cdd8); }

/* steps */
.steps {
  background: var(--ink);
  color: var(--cream);
  border-radius: var(--radius-lg);
  padding: 64px 48px;
  margin: 40px 0;
}
.steps h2 { color: var(--cream); }
.steps .grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  margin-top: 36px;
}
.step {
  border-top: 1px solid rgba(250,247,240,0.18);
  padding-top: 24px;
}
.step-num {
  font-family: var(--font-serif);
  font-size: 32px;
  color: var(--amber);
  margin-bottom: 12px;
}
.step h3 { color: var(--cream); margin-bottom: 8px; }
.step p { color: rgba(250,247,240,0.7); font-size: 14px; margin: 0; }

/* testimonial */
.quote {
  max-width: 880px;
  margin: 0 auto;
  text-align: center;
  padding: 60px 32px;
}
.quote blockquote {
  margin: 0;
  font-family: var(--font-serif);
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  line-height: 1.3;
  letter-spacing: -0.02em;
  color: var(--ink);
  font-weight: 400;
}
.quote cite {
  display: block;
  margin-top: 28px;
  font-style: normal;
  font-size: 14px;
  color: var(--muted);
}

/* big cta */
.big-cta {
  background: var(--sage);
  color: var(--cream);
  border-radius: var(--radius-lg);
  padding: 64px 48px;
  text-align: center;
  margin: 40px 0 0;
  position: relative;
  overflow: hidden;
}
.big-cta h2 {
  color: var(--cream);
  font-size: clamp(2rem, 4vw, 3rem);
  margin-bottom: 16px;
}
.big-cta p {
  color: rgba(250,247,240,0.85);
  font-size: 17px;
  max-width: 560px;
  margin: 0 auto 28px;
}
.big-cta .btn { background: var(--cream); color: var(--sage-dark); border-color: var(--cream); }
.big-cta .btn:hover { background: var(--paper); color: var(--ink); border-color: var(--paper); }

/* footer */
.footer {
  background: var(--cream-soft);
  border-top: 1px solid var(--line);
  padding: 36px 32px;
  margin-top: 80px;
}
.footer-inner {
  max-width: 1180px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--muted);
}
.footer-inner a { color: var(--muted); text-decoration: underline; text-underline-offset: 3px; }
.footer-inner a:hover { color: var(--ink); }
.footer-inner .dot {
  display: inline-block;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--muted);
  vertical-align: middle;
  margin: 0 10px 2px;
  opacity: 0.6;
}

/* =========================================================================
   LEGAL PAGES (Terms, Privacy, etc.)
   ========================================================================= */

.legal-page h1 { margin-top: 12px; }
.legal-page h2 {
  font-family: 'Fraunces', Georgia, serif;
  font-size: 22px;
  font-weight: 500;
  margin: 36px 0 12px;
  color: var(--ink);
}
.legal-page p, .legal-page ul { font-size: 15px; line-height: 1.65; color: #2a2a28; }
.legal-page ul { padding-left: 22px; margin: 12px 0 18px; }
.legal-page ul li { margin-bottom: 8px; }
.legal-page .lead { font-size: 16px; color: #2a2a28; }
.legal-page .muted { font-size: 13px; color: var(--muted); }

/* T&C acceptance checkbox on signup */
label.checkbox.terms-accept {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  line-height: 1.5;
  color: var(--muted);
  margin-top: 4px;
  cursor: pointer;
}
label.checkbox.terms-accept input[type="checkbox"] {
  margin-top: 3px;
  accent-color: var(--sage);
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}
label.checkbox.terms-accept a {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* =========================================================================
   KIOSK (iPad)
   ========================================================================= */

body.kiosk-page { background: linear-gradient(180deg, #faf7f0 0%, #efe6d6 100%); min-height: 100vh; }
body.kiosk-page .topbar { display: none; }

.kiosk-shell {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
}
.kiosk {
  width: 100%;
  max-width: 720px;
  background: var(--paper);
  border-radius: 28px;
  padding: 56px 56px 48px;
  box-shadow: var(--shadow-lg);
  position: relative;
  overflow: hidden;
}
.kiosk::before {
  content: "";
  position: absolute;
  top: -120px;
  right: -120px;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: var(--sage-soft);
  opacity: 0.6;
  z-index: 0;
}
.kiosk-brand {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-serif);
  font-weight: 600;
  font-size: 17px;
  color: var(--ink);
  margin-bottom: 36px;
}
.kiosk-eyebrow {
  position: relative;
  z-index: 1;
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--sage);
  font-weight: 600;
  margin-bottom: 10px;
}
.kiosk h1 {
  position: relative;
  z-index: 1;
  font-size: clamp(2rem, 4.4vw, 2.8rem);
  line-height: 1.05;
  margin-bottom: 14px;
}
.kiosk .lead {
  position: relative;
  z-index: 1;
  font-size: 18px;
  color: var(--muted);
  margin-bottom: 36px;
}
.kiosk form.stacked { max-width: none; gap: 22px; position: relative; z-index: 1; }
.kiosk form.stacked label { font-size: 14px; gap: 8px; }
.kiosk form.stacked input {
  font-size: 22px;
  padding: 18px 20px;
  border-radius: 14px;
  border: 1.5px solid var(--line);
}
.kiosk form.stacked input:focus { border-color: var(--sage); box-shadow: 0 0 0 4px rgba(31,95,74,0.14); }
.kiosk .agent-q { border-radius: 14px; padding: 18px 20px; }
.kiosk .agent-q legend { margin-bottom: 12px; font-size: 14px; }
.kiosk .agent-q .radio { font-size: 18px; margin-right: 32px; }
.kiosk .agent-q .radio input { transform: scale(1.5); }
.kiosk .btn {
  font-size: 18px;
  padding: 20px 24px;
  width: 100%;
  background: var(--sage);
  border-color: var(--sage);
  margin-top: 8px;
  border-radius: 14px;
}
.kiosk .btn:hover { background: var(--sage-dark); border-color: var(--sage-dark); }
.kiosk-exit { position: relative; z-index: 1; text-align: center; margin-top: 28px; font-size: 13px; }
.kiosk-exit a { color: var(--muted); }

/* thanks */
.kiosk.thanks {
  text-align: center;
  padding: 72px 56px;
}
.kiosk.thanks .check {
  width: 96px;
  height: 96px;
  margin: 0 auto 24px;
  border-radius: 50%;
  background: var(--sage);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 1;
  animation: pop 0.4s ease;
}
@keyframes pop {
  0% { transform: scale(0.6); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}
.kiosk.thanks h1 { margin-bottom: 12px; }
.kiosk.thanks .lead { margin-bottom: 32px; }
.kiosk.thanks .countdown { font-size: 13px; color: var(--muted); margin-top: 24px; }

/* =========================================================================
   AUTH PAGES (split)
   ========================================================================= */

body.auth-page { background: var(--cream); }
body.auth-page .container { padding: 0; max-width: none; }
.auth-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: calc(100vh - 76px);
}
.auth-form-side {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px;
}
.auth-form-side .inner { width: 100%; max-width: 380px; }
.auth-form-side h1 { font-size: 2rem; margin-bottom: 8px; }
.auth-form-side .lead { color: var(--muted); margin-bottom: 28px; font-size: 15px; }
.auth-form-side form.stacked { max-width: none; }
.auth-form-side .btn { width: 100%; padding: 14px; font-size: 15px; }
.auth-form-side .alt { font-size: 14px; color: var(--muted); margin-top: 22px; text-align: center; }

.auth-art-side {
  background: linear-gradient(160deg, #1f5f4a 0%, #16463a 100%);
  color: var(--cream);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 48px;
  position: relative;
  overflow: hidden;
}
.auth-art-side::before {
  content: "";
  position: absolute;
  bottom: -200px;
  right: -200px;
  width: 500px;
  height: 500px;
  border-radius: 50%;
  background: rgba(217,119,6,0.18);
  filter: blur(40px);
}
.auth-art-side::after {
  content: "";
  position: absolute;
  top: -100px;
  left: -100px;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: rgba(250,247,240,0.08);
  filter: blur(30px);
}
.auth-art-side .auth-art-content {
  position: relative;
  z-index: 1;
  max-width: 440px;
}
.auth-art-side .eyebrow {
  color: var(--amber);
}
.auth-art-side .eyebrow::before {
  background: var(--amber);
}
.auth-art-side h2 {
  color: var(--cream);
  font-size: 2.2rem;
  margin: 16px 0 18px;
  line-height: 1.1;
}
.auth-art-side p { color: rgba(250,247,240,0.8); font-size: 16px; }
.auth-stat-card {
  position: relative;
  z-index: 1;
  background: rgba(250,247,240,0.08);
  border: 1px solid rgba(250,247,240,0.12);
  border-radius: 14px;
  padding: 22px;
  backdrop-filter: blur(8px);
}
.auth-stat-card .num {
  font-family: var(--font-serif);
  font-size: 2.4rem;
  color: var(--amber);
  line-height: 1;
}
.auth-stat-card .label {
  margin-top: 6px;
  font-size: 14px;
  color: rgba(250,247,240,0.8);
}

/* =========================================================================
   DASHBOARD & INTERNAL
   ========================================================================= */

.page-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 28px;
  gap: 18px;
  flex-wrap: wrap;
}
.page-head h1 { margin-bottom: 4px; }
.page-head .sub { color: var(--muted); font-size: 15px; margin: 0; }

.section-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 36px 0 16px;
}
.section-title h2 { margin: 0; font-size: 1.4rem; }

.listing-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 24px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  margin-bottom: 12px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}
.listing-card:hover {
  border-color: var(--ink);
  box-shadow: var(--shadow-sm);
  transform: translateY(-1px);
}
.listing-card .info strong { font-family: var(--font-serif); font-size: 18px; font-weight: 600; }
.listing-card .info strong a { color: var(--ink); }
.listing-card .info .meta { color: var(--muted); font-size: 13px; margin-top: 4px; }
.listing-card .meta-tags { display: flex; gap: 8px; }

.empty-state {
  text-align: center;
  padding: 64px 32px;
  background: var(--cream-soft);
  border-radius: var(--radius);
  border: 1px dashed var(--line);
}
.empty-state svg { margin: 0 auto 18px; }
.empty-state h3 { font-family: var(--font-serif); font-size: 1.4rem; margin-bottom: 8px; font-weight: 500; }
.empty-state p { color: var(--muted); margin-bottom: 20px; }

/* Required-field marker */
.req { color: var(--danger); font-weight: 700; margin-left: 2px; }

/* Inline informational tip card (e.g. post-create kiosk explanation) */
.info-tip {
  background: var(--sage-soft);
  border: 1px solid #c9dccf;
  border-left: 4px solid var(--sage);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin-bottom: 18px;
  color: var(--sage-dark);
  font-size: 14px;
}
.info-tip strong { color: var(--sage-dark); }
.info-tip ol, .info-tip ul { margin: 6px 0; }

.kiosk-actions { display: inline-flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }
.kiosk-help summary { font-size: 13px; }
.kiosk-help summary::marker { color: var(--muted); }
.kiosk-help[open] summary { color: var(--ink); }

/* Slick on/off pills for per-session toggles (visitor email + AI follow-up).
   Click flips state through a tiny POST form — no JS required. */
.session-toggles {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
  margin-top: 12px;
}
.toggle-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px 6px 8px;
  border-radius: var(--radius-pill);
  border: 1.5px solid var(--line);
  background: var(--paper);
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease, color 0.15s ease;
}
.toggle-pill:hover { border-color: var(--sage); }
.toggle-pill .toggle-track {
  position: relative;
  width: 30px;
  height: 18px;
  border-radius: var(--radius-pill);
  background: var(--line);
  transition: background 0.18s ease;
  flex: 0 0 auto;
}
.toggle-pill .toggle-knob {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--paper);
  box-shadow: 0 1px 2px rgba(13,13,13,0.25);
  transition: left 0.18s ease;
}
.toggle-pill.on { color: var(--sage-dark); border-color: var(--sage); background: var(--sage-soft); }
.toggle-pill.on .toggle-track { background: var(--sage); }
.toggle-pill.on .toggle-knob  { left: 14px; }
.toggle-pill.off { color: var(--muted); }

/* Strip the browser-default × clear button from date/time fields. WebKit and
   Edge both render a tiny black X flush to the right edge that has no padding
   and clashes with our editorial form style. The native picker still works. */
input[type="date"]::-webkit-clear-button,
input[type="time"]::-webkit-clear-button,
input[type="date"]::-webkit-inner-spin-button,
input[type="time"]::-webkit-inner-spin-button {
  display: none;
  -webkit-appearance: none;
  margin: 0;
}
input[type="date"]::-ms-clear,
input[type="time"]::-ms-clear { display: none; width: 0; height: 0; }

/* Collapsed "N days" header on session cards. Expands to a chip-list of the
   actual scheduled_dates so a five-day open house doesn't dominate the card. */
.date-summary { display: inline-block; margin-bottom: 6px; }
.date-summary > summary {
  list-style: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0;
}
.date-summary > summary::-webkit-details-marker { display: none; }
.date-summary > summary::after {
  content: "▾";
  font-size: 11px;
  color: var(--muted);
  transition: transform 0.15s ease;
  margin-left: 2px;
}
.date-summary[open] > summary::after { transform: rotate(180deg); }
.date-summary-hint { font-size: 12px; color: var(--muted); }
.date-summary[open] .date-summary-hint { color: var(--ink); }
.date-chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
  padding: 10px 12px;
  background: var(--cream-soft);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-sm);
}
.date-chip {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  background: var(--paper);
  border: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}

/* Onboarding tour — shown to new users on the dashboard */
.tour {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 28px 32px;
  margin-bottom: 28px;
  box-shadow: var(--shadow-xs);
}
.tour h2 { font-size: 1.4rem; margin: 0 0 6px; }
.tour .tour-lead { color: var(--muted); margin: 0 0 20px; }
.tour ol.tour-steps {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  counter-reset: tour;
}
.tour ol.tour-steps li {
  background: var(--cream-soft);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  padding: 18px 16px;
  position: relative;
  counter-increment: tour;
}
.tour ol.tour-steps li::before {
  content: counter(tour);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: var(--sage);
  color: var(--cream);
  font-weight: 600;
  font-size: 13px;
  margin-bottom: 10px;
}
.tour ol.tour-steps li strong { display: block; margin-bottom: 4px; font-size: 15px; }
.tour ol.tour-steps li span { color: var(--muted); font-size: 13px; line-height: 1.45; }
.tour-actions { display: flex; gap: 10px; align-items: center; margin-top: 18px; flex-wrap: wrap; }
.tour-dismiss {
  background: transparent; border: 0; color: var(--muted); font-size: 13px; cursor: pointer; padding: 4px 8px;
}
.tour-dismiss:hover { color: var(--ink); }
@media (max-width: 880px) {
  .tour ol.tour-steps { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 520px) {
  .tour ol.tour-steps { grid-template-columns: 1fr; }
}

/* responsive */
@media (max-width: 880px) {
  .hero { padding: 36px 24px; }
  .hero-grid { grid-template-columns: 1fr; gap: 36px; }
  .hero-art { min-height: 360px; }
  .feature-block { grid-template-columns: 1fr; gap: 32px; padding: 36px 0; }
  .feature-block.reverse { direction: ltr; }
  .steps { padding: 40px 28px; }
  .steps .grid { grid-template-columns: 1fr; gap: 24px; }
  .auth-split { grid-template-columns: 1fr; }
  .auth-art-side { display: none; }
  .container { padding: 24px 20px 60px; }
  .topbar { padding: 14px 20px; }
  .topbar nav a:not(.btn):not(.nav-signin) { display: none; }
  .topbar nav a.nav-signin { padding: 8px 12px; font-size: 14px; }
  .kiosk { padding: 36px 28px 32px; border-radius: 22px; }
  .big-cta { padding: 40px 28px; }
}

/* admin */
.admin-subnav {
  display: flex;
  gap: 4px;
  background: var(--cream);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 6px;
  margin-top: 16px;
  flex-wrap: wrap;
}
.admin-subnav a {
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  color: var(--muted);
  text-decoration: none;
}
.admin-subnav a:hover { color: var(--ink); background: rgba(0,0,0,0.03); }
.admin-subnav a.is-active { background: var(--sage); color: var(--cream); }
.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 12px;
}
.stat-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px 18px;
}
.stat-num { font-size: 28px; font-weight: 700; color: var(--ink); line-height: 1.1; }
.stat-label { font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: 0.04em; margin-top: 4px; }
