﻿/* Bark Valley Stables
   Palette is lifted from the logo (valley purple, blossom pink, sky blue)
   with one warm note, bandana orange, taken from the dogs in the photos. */
:root {
  --ink: #2b2150;
  --ink-soft: #5d5483;
  --purple: #8e72db;
  --purple-deep: #6a4fc0;
  --lilac: #d9cffa;
  --mist: #f4f1fd;
  --pink: #f78fb3;
  --pink-soft: #ffe3ee;
  --sky: #86b9f2;
  --sky-soft: #dcebfd;
  --orange: #ea5b1f;
  --orange-deep: #c94710;
  --white: #fff;
  --line: #e1daf6;
  --ok: #1f7a4d;
  --ok-bg: #dff3e7;
  --warn: #8a5300;
  --warn-bg: #fff0cf;
  --bad: #b3261e;
  --bad-bg: #fde4e1;
  --radius: 14px;
  --display: "Bricolage Grotesque", "Arial Black", system-ui, sans-serif;
  --body: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--body);
  font-size: 1rem;
  line-height: 1.55;
  color: var(--ink);
  background: var(--mist);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
h1, h2, h3, h4 { font-family: var(--display); line-height: 1.08; margin: 0 0 .5em; letter-spacing: -.01em; }
h1 { font-size: clamp(2.5rem, 6vw, 4.6rem); font-weight: 800; }
h2 { font-size: clamp(1.8rem, 3.6vw, 2.7rem); font-weight: 800; }
h3 { font-size: 1.3rem; font-weight: 700; }
h4 { font-size: 1.05rem; font-weight: 700; }
p { margin: 0 0 1em; max-width: 62ch; }
a { color: var(--purple-deep); }
:focus-visible { outline: 3px solid var(--sky); outline-offset: 2px; border-radius: 6px; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #fff; padding: .6rem 1rem; z-index: 100; border-radius: 8px; }
.skip:focus { left: 8px; }
.muted { color: var(--ink-soft); }
.small { font-size: .875rem; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- top bar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 30;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: .6rem clamp(1rem, 4vw, 3rem);
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: .7rem; text-decoration: none; color: var(--purple-deep); }
.badge {
  --s: 46px;
  width: var(--s); height: var(--s); border-radius: 50%; flex: none;
  background: url("../images/logo.png") no-repeat;
  background-size: calc(var(--s) * 1.4) auto;
  background-position: calc(var(--s) * -.19) calc(var(--s) * -.04);
}
.brand-name { font-family: var(--display); font-weight: 800; font-size: 1.25rem; letter-spacing: -.01em; line-height: 1; }
.brand-name span { color: var(--pink); }
#nav { display: flex; align-items: center; gap: .25rem; flex-wrap: wrap; justify-content: flex-end; }
#nav a, #nav button.linklike {
  font: inherit; font-weight: 600; color: var(--ink); text-decoration: none; background: none; border: 0; cursor: pointer;
  padding: .5rem .8rem; border-radius: 999px;
}
#nav a:hover, #nav button.linklike:hover { background: var(--mist); }
#nav a[aria-current="page"] { background: var(--lilac); }
#nav .btn { margin-left: .3rem; }
.count { display: inline-grid; place-items: center; min-width: 1.4em; height: 1.4em; padding: 0 .35em; margin-left: .35em; background: var(--orange); color: #fff; border-radius: 999px; font-size: .78rem; }

/* ---------- buttons & forms ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  font: inherit; font-weight: 700; text-decoration: none; cursor: pointer;
  padding: .7rem 1.25rem; border-radius: 999px; border: 2px solid transparent;
  background: var(--orange); color: #fff; transition: background .15s, transform .15s;
}
.btn:hover { background: var(--orange-deep); }
.btn:active { transform: translateY(1px); }
.btn.purple { background: var(--purple); }
.btn.purple:hover { background: var(--purple-deep); }
.btn.ghost { background: transparent; color: var(--purple-deep); border-color: var(--purple); }
.btn.ghost:hover { background: var(--lilac); }
.btn.danger { background: var(--white); color: var(--bad); border-color: var(--bad); }
.btn.danger:hover { background: var(--bad-bg); }
.btn.small { padding: .4rem .85rem; font-size: .875rem; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }
.link { background: none; border: 0; padding: 0; font: inherit; color: var(--purple-deep); text-decoration: underline; cursor: pointer; }
.link.bad { color: var(--bad); }

label { display: block; font-weight: 600; font-size: .92rem; margin-bottom: .3rem; }
input[type=text], input[type=email], input[type=tel], input[type=password], input[type=number], input[type=date], input[type=search], select, textarea {
  width: 100%; font: inherit; color: var(--ink);
  padding: .65rem .8rem; background: #fff; border: 1.5px solid #cfc5f0; border-radius: 10px;
}
input:focus, select:focus, textarea:focus { outline: 3px solid var(--sky); outline-offset: 0; border-color: var(--purple); }
textarea { min-height: 90px; resize: vertical; }
.field { margin-bottom: 1rem; }
.field .hint { font-size: .85rem; color: var(--ink-soft); margin-top: .25rem; }
.grid2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0 1rem; }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0 1rem; }
.check { display: flex; align-items: center; gap: .6rem; font-weight: 500; padding: .45rem 0; cursor: pointer; margin: 0; }
.check input { width: 1.15rem; height: 1.15rem; accent-color: var(--purple); flex: none; }
.row { display: flex; gap: .6rem; flex-wrap: wrap; align-items: center; }
.row.between { justify-content: space-between; }
.stack > * + * { margin-top: 1rem; }

.chip { display: inline-block; padding: .15rem .65rem; border-radius: 999px; font-size: .8rem; font-weight: 700; background: var(--lilac); color: var(--purple-deep); }
.chip.ok { background: var(--ok-bg); color: var(--ok); }
.chip.warn { background: var(--warn-bg); color: var(--warn); }
.chip.bad { background: var(--bad-bg); color: var(--bad); }
.chip.sky { background: var(--sky-soft); color: #25568f; }

.notice { padding: .8rem 1rem; border-radius: 10px; background: var(--sky-soft); color: #1d466f; margin-bottom: 1rem; }
.notice.warn { background: var(--warn-bg); color: var(--warn); }
.notice.bad { background: var(--bad-bg); color: var(--bad); }
.notice.ok { background: var(--ok-bg); color: var(--ok); }
.notice ul { margin: .3rem 0 0; padding-left: 1.2rem; }

/* ---------- layout ---------- */
.wrap { width: min(1160px, 100% - 2rem); margin-inline: auto; }
.section { padding: clamp(3rem, 7vw, 5.5rem) 0; }
.page { padding: 2rem 0 4rem; min-height: 70vh; }
.page > .wrap > h1 { font-size: clamp(2rem, 4vw, 3rem); }

/* ---------- hero ---------- */
.hero {
  position: relative; overflow: hidden;
  background: linear-gradient(180deg, #c9e0ff 0%, #ddd6fb 55%, #ecdff8 100%);
  padding: clamp(2rem, 5vw, 4rem) 0 0;
}
.hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 2rem; align-items: center; position: relative; z-index: 2; padding-bottom: clamp(5rem, 11vw, 9rem); }
.hero h1 { color: var(--ink); max-width: 11ch; }
.hero p.lead { font-size: 1.2rem; max-width: 40ch; color: #3f3566; }
.hero .row { margin-top: 1.6rem; }
.hero-photo { justify-self: center; position: relative; width: min(440px, 88vw); aspect-ratio: 1; }
.hero-photo .ring { position: absolute; inset: 0; border-radius: 50%; background: var(--purple); padding: 12px; }
.hero-photo .ring::after { content: ""; position: absolute; inset: 12px; border-radius: 50%; border: 5px solid var(--pink); pointer-events: none; z-index: 2; }
.hero-photo img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 62%; border-radius: 50%; }
.ridge { position: absolute; left: 0; right: 0; bottom: -1px; width: 100%; height: clamp(90px, 14vw, 190px); z-index: 1; }

/* ---------- home sections ---------- */
.services { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(1rem, 3vw, 2rem); align-items: start; }
.service img { width: 100%; aspect-ratio: 4/5; object-fit: cover; }
.service:nth-child(1) img { border-radius: 999px 999px 18px 18px; }
.service:nth-child(2) img { border-radius: 18px; margin-top: 2.5rem; }
.service:nth-child(3) img { border-radius: 18px 18px 999px 999px; }
.service h3 { margin-top: 1rem; }
.service p { color: var(--ink-soft); margin-bottom: .4rem; }
.service .from { font-weight: 700; color: var(--purple-deep); }

.band { background: var(--white); border-block: 1px solid var(--line); }
.rates-grid { display: grid; grid-template-columns: .8fr 1.2fr; gap: clamp(1.5rem, 5vw, 4rem); align-items: start; }
.rates { width: 100%; border-collapse: collapse; }
.rates td, .rates th { padding: .8rem 0; border-bottom: 1px solid var(--line); text-align: left; vertical-align: baseline; }
.rates td:last-child, .rates th:last-child { text-align: right; font-weight: 700; white-space: nowrap; }
.rates .per { color: var(--ink-soft); font-weight: 500; font-size: .9rem; }

.avail-grid { display: grid; grid-template-columns: .8fr 1.2fr; gap: clamp(1.5rem, 5vw, 4rem); align-items: center; }

.gallery { columns: 4; column-gap: 1rem; }
.gallery img { width: 100%; margin-bottom: 1rem; border-radius: 16px; break-inside: avoid; }
.gallery img:nth-child(3n) { border-radius: 90px 16px 16px 16px; }
.gallery img:nth-child(4n+2) { border-radius: 16px 90px 16px 16px; }

.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; counter-reset: s; }
.steps li { counter-increment: s; padding-top: 1rem; border-top: 4px solid var(--pink); }
.steps li::before { content: counter(s); font-family: var(--display); font-weight: 800; font-size: 2rem; color: var(--purple); display: block; line-height: 1; margin-bottom: .4rem; }
.steps strong { display: block; margin-bottom: .2rem; }
.steps span { color: var(--ink-soft); font-size: .95rem; }

.footer { background: var(--ink); color: #e9e3ff; padding: 3rem 0 2rem; }
.footer .wrap { display: grid; grid-template-columns: auto 1fr auto; gap: 2rem; align-items: center; }
.footer img { width: 130px; border-radius: 16px; }
.footer a { color: #fff; }
.footer .admin-link { opacity: .7; font-size: .875rem; }

/* ---------- panels ---------- */
.panel { background: var(--white); border: 1px solid var(--line); border-radius: 18px; padding: clamp(1rem, 3vw, 1.75rem); }
.panel + .panel { margin-top: 1.25rem; }
.panel h3 { margin-bottom: .75rem; }
.tabs { display: flex; gap: .3rem; flex-wrap: wrap; margin: 1rem 0 1.5rem; border-bottom: 2px solid var(--line); }
.tabs a { padding: .6rem 1rem; font-weight: 700; text-decoration: none; color: var(--ink-soft); border-bottom: 3px solid transparent; margin-bottom: -2px; }
.tabs a[aria-current="page"] { color: var(--purple-deep); border-bottom-color: var(--purple); }
.tabs a:hover { color: var(--ink); }

.auth { max-width: 460px; margin-inline: auto; }
.seg { display: flex; background: var(--lilac); border-radius: 999px; padding: 4px; margin-bottom: 1.25rem; }
.seg a { flex: 1; text-align: center; text-decoration: none; font-weight: 700; color: var(--purple-deep); padding: .5rem; border-radius: 999px; }
.seg a[aria-current="page"] { background: #fff; box-shadow: 0 1px 3px rgba(43,33,80,.15); }

.dogs { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1rem; }
.dog { background: var(--white); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; display: flex; flex-direction: column; }
.dog-photo { aspect-ratio: 4/3; background: var(--lilac); display: grid; place-items: center; font-family: var(--display); font-weight: 800; font-size: 3.5rem; color: var(--purple); overflow: hidden; }
.dog-photo img { width: 100%; height: 100%; object-fit: cover; }
.dog-body { padding: 1rem 1.1rem 1.1rem; flex: 1; display: flex; flex-direction: column; gap: .5rem; }
.dog-body h3 { margin: 0; }
.recs { list-style: none; margin: 0; padding: 0; display: grid; gap: .35rem; font-size: .9rem; }
.recs li { display: flex; justify-content: space-between; gap: .5rem; align-items: center; }
.dog-actions { margin-top: auto; padding-top: .5rem; }

.table { width: 100%; border-collapse: collapse; }
.table th { text-align: left; font-size: .85rem; color: var(--ink-soft); font-weight: 600; padding: .5rem .6rem; border-bottom: 2px solid var(--line); }
.table td { padding: .7rem .6rem; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table tr.click { cursor: pointer; }
.table tr.click:hover td { background: var(--mist); }
.table td.num, .table th.num { text-align: right; }
.table input, .table select { padding: .45rem .55rem; }
.scroll-x { overflow-x: auto; }

.list { list-style: none; margin: 0; padding: 0; }
.list li { padding: .85rem 0; border-bottom: 1px solid var(--line); display: flex; gap: 1rem; justify-content: space-between; align-items: center; flex-wrap: wrap; }
.list li:last-child { border: 0; }

.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 1rem; margin-bottom: 1.25rem; }
.stat { background: var(--white); border: 1px solid var(--line); border-radius: 16px; padding: 1rem 1.2rem; }
.stat strong { display: block; font-family: var(--display); font-size: 2rem; font-weight: 800; line-height: 1.1; }

/* ---------- calendar ---------- */
.cal { background: var(--white); border: 1px solid var(--line); border-radius: 20px; padding: 1rem; }
.cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: .6rem; }
.cal-head h3 { margin: 0; font-size: 1.35rem; }
.cal-nav { width: 2.4rem; height: 2.4rem; border-radius: 50%; border: 1.5px solid var(--purple); background: #fff; color: var(--purple-deep); font-size: 1.2rem; cursor: pointer; line-height: 1; }
.cal-nav:hover { background: var(--lilac); }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.cal-dow { text-align: center; font-size: .78rem; font-weight: 700; color: var(--ink-soft); padding: .3rem 0; }
.day {
  position: relative; font: inherit; color: var(--ink); text-align: left;
  min-height: 64px; padding: .35rem .45rem; border-radius: 10px; border: 2px solid transparent;
  background: #e5f5ec; cursor: pointer; display: flex; flex-direction: column; justify-content: space-between;
}
.day .n { font-weight: 700; }
.day .m { font-size: .72rem; line-height: 1.15; color: #276447; font-weight: 600; }
.day.limited { background: var(--warn-bg); }
.day.limited .m { color: var(--warn); }
.day.full { background: #f9d6d2; }
.day.full .m { color: var(--bad); }
.day.blocked { background: repeating-linear-gradient(135deg, #ece7fa 0 6px, #f6f3ff 6px 12px); }
.day.blocked .m { color: var(--ink-soft); }
.day.past { background: transparent; color: #aaa3c4; cursor: default; }
.day.past .m { color: transparent; }
.day.blank { background: none; border: 0; cursor: default; }
.day.inrange { border-color: var(--purple); background: var(--lilac); }
.day.inrange .m { color: var(--purple-deep); }
.day.edge { background: var(--purple); color: #fff; border-color: var(--purple); }
.day.edge .m { color: #fff; }
.day.today .n::after { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--orange); margin-left: 4px; vertical-align: middle; }
.day.selday { outline: 3px solid var(--ink); outline-offset: -3px; }
.day .pend { position: absolute; top: 6px; right: 7px; width: 9px; height: 9px; border-radius: 50%; background: var(--orange); }
.legend { display: flex; gap: 1rem; flex-wrap: wrap; font-size: .82rem; color: var(--ink-soft); margin-top: .8rem; }
.legend i { display: inline-block; width: 12px; height: 12px; border-radius: 3px; margin-right: .35rem; vertical-align: -1px; }

.book-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 1.5rem; align-items: start; }
.quote { background: var(--mist); border-radius: 14px; padding: 1rem 1.1rem; }
.quote table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.quote td { padding: .3rem 0; vertical-align: top; }
.quote td:last-child { text-align: right; white-space: nowrap; padding-left: 1rem; font-variant-numeric: tabular-nums; }
.quote tr.sub td { border-top: 1px solid var(--line); padding-top: .5rem; }
.quote tr.total td { font-family: var(--display); font-weight: 800; font-size: 1.4rem; border-top: 2px solid var(--ink); padding-top: .5rem; }
.quote tr.neg td:last-child { color: var(--ok); }

/* ---------- modal ---------- */
.overlay { position: fixed; inset: 0; z-index: 60; background: rgba(43,33,80,.55); display: grid; place-items: start center; overflow-y: auto; padding: 4vh 1rem; }
.modal { background: #fff; border-radius: 22px; width: min(720px, 100%); padding: clamp(1.2rem, 3vw, 2rem); position: relative; }
.modal.wide { width: min(980px, 100%); }
.modal-close { position: absolute; top: .8rem; right: .8rem; width: 2.2rem; height: 2.2rem; border-radius: 50%; border: 0; background: var(--mist); font-size: 1.3rem; cursor: pointer; color: var(--ink); }
.modal h2 { font-size: 1.7rem; padding-right: 2.5rem; }
.modal-actions { display: flex; gap: .6rem; flex-wrap: wrap; margin-top: 1.25rem; justify-content: flex-end; }
.file-item { display: flex; align-items: center; gap: .6rem; justify-content: space-between; padding: .5rem .7rem; background: var(--mist); border-radius: 10px; margin-top: .4rem; font-size: .92rem; }
.thumb { width: 64px; height: 64px; border-radius: 12px; object-fit: cover; background: var(--lilac); }

#toast { position: fixed; left: 50%; bottom: 1.5rem; transform: translate(-50%, 20px); opacity: 0; pointer-events: none; z-index: 80; background: var(--ink); color: #fff; padding: .7rem 1.2rem; border-radius: 999px; font-weight: 600; transition: opacity .2s, transform .2s; max-width: 92vw; }
#toast.show { opacity: 1; transform: translate(-50%, 0); }
#toast.error { background: var(--bad); }

/* invoice */
.invoice h2 { margin-bottom: .2rem; }
.invoice .meta { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin: 1rem 0; }

@media print {
  body.printing > *:not(#modal-root) { display: none !important; }
  body.printing #modal-root .overlay { position: static; background: none; padding: 0; display: block; }
  body.printing .modal { box-shadow: none; width: 100%; padding: 0; }
  body.printing .modal-close, body.printing .modal-actions { display: none; }
}

@media (max-width: 900px) {
  .hero-grid, .rates-grid, .avail-grid, .book-grid { grid-template-columns: 1fr; }
  .hero h1 { max-width: none; }
  .hero-photo { order: -1; width: min(300px, 70vw); }
  .services { grid-template-columns: 1fr; max-width: 420px; margin-inline: auto; }
  .service:nth-child(2) img { margin-top: 0; }
  .gallery { columns: 2; }
  .steps { grid-template-columns: 1fr 1fr; }
  .footer .wrap { grid-template-columns: 1fr; text-align: center; justify-items: center; }
}
@media (max-width: 560px) {
  .grid2, .grid3 { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .brand-name { font-size: .95rem; }
  .topbar { padding-block: .4rem; }
  #nav a, #nav button.linklike { padding: .35rem .6rem; font-size: .9rem; }
  .day { min-height: 54px; padding: .25rem .3rem; }
  .day .m { font-size: .62rem; }
  .table.stack-m thead { display: none; }
  .table.stack-m tr { display: block; padding: .6rem 0; border-bottom: 1px solid var(--line); }
  .table.stack-m td { display: flex; justify-content: space-between; border: 0; padding: .2rem .4rem; }
  .table.stack-m td::before { content: attr(data-l); color: var(--ink-soft); font-size: .85rem; margin-right: 1rem; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}


/* ---------- policies, request details, waiver ---------- */
.policies { list-style: none; margin: 0 0 1.25rem; padding: 0; display: grid; gap: .75rem; }
.policies li { padding: .8rem 1rem; border-left: 5px solid var(--pink); background: var(--white); border-radius: 0 12px 12px 0; }
.panel .policies li { background: var(--mist); }
.req-set { border: 1.5px solid var(--line); border-radius: 14px; padding: .9rem 1rem .4rem; margin: 0 0 1.1rem; background: var(--white); }
.req-set legend { font-family: var(--display); font-weight: 700; padding: 0 .5rem; }
.waiver { max-height: 9.5rem; overflow-y: auto; padding: .8rem 1rem; margin-bottom: .6rem; background: var(--mist); border-radius: 10px; font-size: .92rem; line-height: 1.5; }

/* ---------- facility, footer address, messages, photo manager ---------- */
.facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(1rem, 3vw, 2.5rem); margin-top: 1.5rem; }
.fact { padding-top: 1rem; border-top: 6px solid var(--purple); }
.fact:nth-child(2) { border-top-color: var(--pink); }
.fact:nth-child(3) { border-top-color: var(--sky); }
.fact h3 { margin-bottom: .4rem; }
.fact p { color: var(--ink-soft); margin: 0; }
.footer .footer-base { display: flex; justify-content: center; gap: .5rem 1.5rem; flex-wrap: wrap; margin-top: 2rem; padding-top: 1.25rem; border-top: 1px solid rgba(255,255,255,.2); text-align: center; font-weight: 600; }

.msg-grid { display: grid; grid-template-columns: 1.3fr .7fr; gap: 1.25rem; align-items: start; }
.msg-grid.admin { grid-template-columns: .8fr 1.2fr; }
.msg-grid .panel + .panel { margin-top: 0; }
.thread { display: flex; flex-direction: column; gap: .6rem; max-height: 420px; overflow-y: auto; padding: .3rem .2rem 1rem; margin-bottom: 1rem; }
.bubble { max-width: 85%; padding: .6rem .9rem; border-radius: 16px; background: var(--mist); align-self: flex-start; overflow-wrap: anywhere; }
.bubble.mine { align-self: flex-end; background: var(--purple); color: #fff; }
.bubble.arrived { background: var(--warn-bg); color: var(--ink); border: 2px solid var(--orange); }
.bubble time { display: block; font-size: .75rem; opacity: .7; margin-top: .2rem; }
.conv { margin-top: .5rem; }
.conv a { display: block; text-decoration: none; color: var(--ink); width: 100%; }
.conv li { padding: 0; }
.conv a { padding: .75rem .4rem; border-radius: 10px; }
.conv a:hover, .conv a[aria-current="true"] { background: var(--mist); }

.slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1.25rem; }
.slot { display: flex; gap: 1rem; align-items: center; }
.slot-img { width: 96px; height: 96px; flex: none; border-radius: 50%; overflow: hidden; background: var(--lilac); }
.slot-img img { width: 100%; height: 100%; object-fit: cover; }
.g-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 1rem; }
.g-item { display: flex; flex-direction: column; gap: .5rem; }
.g-item img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 14px; background: var(--lilac); }
.g-item input { padding: .4rem .55rem; font-size: .9rem; }
.link[disabled] { opacity: .4; cursor: default; text-decoration: none; }

@media (max-width: 900px) {
  .facts, .msg-grid, .msg-grid.admin { grid-template-columns: 1fr; }
}

.facility-photos { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(1rem, 3vw, 2rem); margin-top: 2.5rem; }
.facility-photos img { width: 100%; aspect-ratio: 3/4; object-fit: cover; border-radius: 18px; background: var(--lilac); }
.facility-photos img:nth-child(1) { border-radius: 999px 999px 18px 18px; }
.facility-photos img:nth-child(3) { border-radius: 18px 18px 999px 999px; }
@media (max-width: 900px) { .facility-photos { grid-template-columns: 1fr; max-width: 420px; margin-inline: auto; } }

/* ---------- payment ---------- */
.pay-opt { display: flex; gap: .8rem; align-items: flex-start; padding: .7rem .8rem; margin-bottom: .6rem; border: 1.5px solid var(--line); border-radius: 12px; cursor: pointer; font-weight: 500; }
.pay-opt:has(input:checked) { border-color: var(--purple); background: var(--mist); }
.pay-opt input { margin-top: .25rem; width: 1.15rem; height: 1.15rem; accent-color: var(--purple); }
.bubble.notice-msg { background: var(--ok-bg); color: var(--ink); border: 2px solid #9fd5b6; }
.bubble.notice-msg.mine { background: var(--ok-bg); color: var(--ink); }
.notice-link { font-weight: 700; color: var(--purple-deep); }

/* ---------- phone refinements ---------- */
.book-grid > *, .msg-grid > *, .hero-grid > *, .rates-grid > *, .avail-grid > * { min-width: 0; }
.cal-grid { grid-template-columns: repeat(7, minmax(0, 1fr)); }
@media (max-width: 640px) {
  .topbar { position: static; flex-wrap: wrap; row-gap: .3rem; }
  #nav { width: 100%; flex-wrap: nowrap; overflow-x: auto; justify-content: flex-start; margin-inline: -.4rem; padding-bottom: .2rem; scrollbar-width: none; }
  #nav::-webkit-scrollbar { display: none; }
  #nav a, #nav button.linklike { white-space: nowrap; flex: none; }
  .btn { min-height: 46px; }
  .btn.small { min-height: 40px; }
  .link { padding: .5rem .2rem; }
  .check { padding: .7rem 0; }
  .modal-actions { flex-direction: column-reverse; align-items: stretch; }
  .modal-actions .btn { width: 100%; }
  .modal-actions [style*="margin-right:auto"] { margin-right: 0 !important; }
  .overlay { padding: 0; }
  .modal { border-radius: 0; min-height: 100vh; }
  .tabs a { padding: .7rem .8rem; }
}

@media (max-width: 640px) {
  .tabs { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .tabs::-webkit-scrollbar { display: none; }
  .tabs a { white-space: nowrap; flex: none; }
}

.tier-row td { background: var(--mist); }
.tiers { display: flex; gap: 1rem 1.25rem; flex-wrap: wrap; align-items: flex-end; }
.tiers strong { flex-basis: 100%; }
.tiers label { margin: 0; font-weight: 600; }
.tiers input { width: 7rem; display: block; margin-top: .25rem; }

.facility-photos img:nth-child(3n+1) { border-radius: 999px 999px 18px 18px; }
.facility-photos img:nth-child(3n+2) { border-radius: 18px; }
.facility-photos img:nth-child(3n) { border-radius: 18px 18px 999px 999px; }

.sched-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; align-items: start; }
.sched-grid .panel + .panel { margin-top: 0; }
.sel-row td { background: var(--lilac) !important; }
@media (max-width: 900px) { .sched-grid { grid-template-columns: 1fr; } }

/* ---------- printable dog profile ---------- */
.ds-head { display: flex; gap: 1.25rem; align-items: center; margin-bottom: 1rem; }
.ds-photo { width: 190px; height: 190px; border-radius: 16px; object-fit: cover; flex: none; background: var(--lilac); }
.ds-none { display: grid; place-items: center; font-family: var(--display); font-weight: 800; font-size: 4rem; color: var(--purple); }
.dogsheet h3 { margin: 1.2rem 0 .4rem; font-size: 1.1rem; border-bottom: 2px solid var(--line); padding-bottom: .25rem; }
.ds-list { margin: 0; }
.ds-row { display: grid; grid-template-columns: 11rem 1fr; gap: .5rem 1rem; padding: .35rem 0; }
.ds-row dt { font-weight: 700; }
.ds-row dd { margin: 0; }
.ds-recs { list-style: none; margin: 0; padding: 0; }
.ds-recs li { display: flex; justify-content: space-between; gap: 1rem; padding: .3rem 0; border-bottom: 1px solid var(--line); }
@media (max-width: 560px) { .ds-head { flex-direction: column; align-items: flex-start; } .ds-row { grid-template-columns: 1fr; } }
@media print {
  .ds-photo { width: 150px; height: 150px; }
  body.printing .dogsheet { font-size: 12pt; color: #000; }
  body.printing .ds-row, body.printing .ds-recs li { break-inside: avoid; }
}
