/* AradSitters - desert light: sand-yellow accents, Dead Sea turquoise, dusk purple. */
:root {
  --sand: #f3d27e;
  --sea: #09babd;
  --sea-ink: #067b7d;
  --dusk: #9164a6;
  --dusk-deep: #7a5190;
  --ink: #2c2b2b;
  --ground: #f7fafa;
  --surface: #ffffff;
  --line: #dfe7e7;
  --danger: #b4233c;

  --font-display: "Fredoka Variable", "Assistant Variable", system-ui, sans-serif;
  --font-body: "Assistant Variable", system-ui, sans-serif;

  --bs-body-font-family: var(--font-body);
  --bs-body-color: var(--ink);
  --bs-body-bg: var(--ground);
  --bs-link-color-rgb: 6, 123, 125;
  --bs-link-hover-color-rgb: 9, 186, 189;
  --bs-form-invalid-color: var(--danger);
  --bs-form-invalid-border-color: var(--danger);
}

html, body { max-width: 100%; }

body {
  font-size: 1.0625rem;
  line-height: 1.6;
  background: var(--ground);
  color: var(--ink);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.2;
  color: var(--ink);
}

h1 { font-size: clamp(1.75rem, 1.3rem + 2vw, 2.6rem); margin-bottom: 0.75rem; }

p, li, label { overflow-wrap: anywhere; }

:focus-visible {
  outline: 3px solid var(--sea-ink);
  outline-offset: 2px;
}

.skip-link {
  position: absolute;
  inset-inline-start: 1rem;
  top: 0.5rem;
  z-index: 10;
  background: var(--surface);
  padding: 0.5rem 1rem;
}

/* Header: one sand line along the bottom, like the desert horizon. */
/* Pinned to the top while scrolling. */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1030;
  background: var(--surface);
  border-bottom: 3px solid var(--sand);
}

.brand {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.5rem;
  color: var(--sea-ink);
}

.brand:hover { color: var(--sea); }

.nav-link { color: var(--ink); font-weight: 600; }
.nav-link:hover, .nav-link:focus-visible { color: var(--sea-ink); }

.page { flex: 1; padding-block: 2rem 3rem; }

.site-footer {
  padding-block: 1.25rem;
  color: #5f5d5d;
  font-size: 0.9375rem;
  border-top: 1px solid var(--line);
}

.site-footer p { margin: 0; }

/* Secondary actions: an outline in the app's link blue (Bootstrap's gray is below 4.5:1). */
.btn-outline-secondary {
  --bs-btn-color: var(--sea-ink);
  --bs-btn-border-color: var(--sea-ink);
  --bs-btn-hover-bg: var(--sea-ink);
  --bs-btn-hover-border-color: var(--sea-ink);
  --bs-btn-active-bg: var(--sea-ink);
  --bs-btn-active-border-color: var(--sea-ink);
}

/* Delete actions: an outline in the app's darker red (Bootstrap's red is just under 4.5:1). */
.btn-outline-danger {
  --bs-btn-color: var(--danger);
  --bs-btn-border-color: var(--danger);
  --bs-btn-hover-bg: var(--danger);
  --bs-btn-hover-border-color: var(--danger);
  --bs-btn-active-bg: var(--danger);
  --bs-btn-active-border-color: var(--danger);
}

/* Buttons: purple for the main action on every screen. */
.btn-primary {
  --bs-btn-bg: var(--dusk);
  --bs-btn-border-color: var(--dusk);
  --bs-btn-hover-bg: var(--dusk-deep);
  --bs-btn-hover-border-color: var(--dusk-deep);
  --bs-btn-active-bg: var(--dusk-deep);
  --bs-btn-active-border-color: var(--dusk-deep);
  --bs-btn-focus-shadow-rgb: 145, 100, 166;
  font-weight: 700;
}

/* Day card - the building block of the calendar. Today's card is shown large on the home page. */
.day-card {
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--line);
  border-top: 6px solid var(--sand);
  border-radius: 14px;
  padding: 1rem 1.25rem 1.25rem;
}

.day-card__label {
  font-weight: 700;
  color: var(--sea-ink);
}

.day-card__number {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(5rem, 3rem + 10vw, 9rem);
  line-height: 1;
  color: var(--ink);
}

.day-card__date { color: #5f5d5d; font-weight: 600; }

.home-hero {
  display: grid;
  gap: 2rem;
  align-items: center;
}

.home-hero .day-card--today {
  max-width: 18rem;
  width: 100%;
}

.home-hero__text { max-width: 36rem; }

.lead-text { font-size: 1.1875rem; margin-bottom: 1.5rem; }

@media (min-width: 768px) {
  .home-hero { grid-template-columns: auto 1fr; gap: 3rem; padding-top: 1.5rem; }
}

/* The sunrise line draws across today's card once, on page load. */
@media (prefers-reduced-motion: no-preference) {
  .home-hero .day-card--today { position: relative; border-top-color: transparent; }
  .home-hero .day-card--today::before {
    content: "";
    position: absolute;
    inset-inline: -1px;
    top: -6px;
    height: 6px;
    border-radius: 14px 14px 0 0;
    background: var(--sand);
    transform-origin: right;
    animation: sunrise 900ms ease-out both;
  }
}

@keyframes sunrise {
  from { transform: scaleX(0); }
  to { transform: scaleX(1); }
}

/* Forms and message pages: one narrow column. */
.form-page, .message-page { max-width: 26rem; }

.stack-form { display: grid; gap: 1rem; }

.form-control:focus {
  border-color: var(--sea);
  box-shadow: 0 0 0 0.2rem rgba(9, 186, 189, 0.25);
}

.notice {
  background: #fdf6e3;
  border-inline-start: 4px solid var(--sand);
  padding: 0.75rem 1rem;
  border-radius: 6px;
}

.field-hint { color: #5f5d5d; font-size: 0.9375rem; margin: 0.25rem 0 0; }

.form-alert {
  background: #fbeff2;
  border-inline-start: 4px solid #b4233c;
  padding: 0.75rem 1rem;
  border-radius: 6px;
}

.form-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  margin-top: 1.25rem;
}

.form-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.5rem;
}

fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
legend.form-label { font-size: inherit; }

/* Role choice: two large tappable options instead of tiny radio dots. */
.role-choice { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; }

.role-option {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.75rem 1rem;
  background: var(--surface);
  cursor: pointer;
  font-weight: 600;
}

.role-option:has(input:checked) {
  border-color: var(--sea-ink);
  box-shadow: inset 0 0 0 1px var(--sea-ink);
}

.role-option input { accent-color: var(--dusk); }

.other-city[hidden] { display: none; }

.profile { display: grid; grid-template-columns: max-content 1fr; gap: 0.25rem 1rem; }
.profile dt { color: #5f5d5d; font-weight: 600; }
.profile dd { margin: 0; }

.link-list { padding: 0; list-style: none; display: grid; gap: 0.5rem; }

.danger-note { border-inline-start: 4px solid #b4233c; padding-inline-start: 1rem; }

.welcome { font-family: var(--font-display); font-size: 1.25rem; color: var(--sea-ink); }

/* Calendar: month bar, legend, and the grid of day cards (5 per row on desktop). */
.month-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.75rem;
}

.month-bar__center { text-align: center; }

.month-bar__title {
  margin: 0;
  text-align: center;
  font-size: clamp(1.5rem, 1.1rem + 1.6vw, 2.25rem);
}

.month-bar__city {
  display: block;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  color: var(--sea-ink);
}

.month-bar__arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--surface);
  font-size: 1.75rem;
  line-height: 1;
  color: var(--sea-ink);
  text-decoration: none;
  flex-shrink: 0;
}

.month-bar__arrow:hover { border-color: var(--sea); color: var(--sea); }
.month-bar__arrow--off { visibility: hidden; }

.legend { display: flex; flex-wrap: wrap; gap: 0.5rem 1.25rem; justify-content: center; font-size: 0.9375rem; color: #5f5d5d; }
.legend__item::before { content: ""; display: inline-block; width: 0.75rem; height: 0.75rem; border-radius: 3px; margin-inline-end: 0.4rem; vertical-align: -0.05rem; }
.legend__item--parent::before { background: var(--dusk); }
.legend__item--babysitter::before { background: var(--sea); }

/* Day cards have the exact size of the home page date card (207px wide, date part 241px tall).
   Days run left to right like an English calendar (1-5, then 6-10); text inside stays Hebrew.
   As many cards per row as fit, at most 5: 5 on computers, 3 on tablets, 1-2 on phones. */
.day-grid {
  --card-width: 207px;
  direction: ltr;
  display: grid;
  grid-template-columns: repeat(auto-fill, var(--card-width));
  justify-content: center;
  gap: 1rem;
  max-width: calc(5 * var(--card-width) + 4rem);
  margin-inline: auto;
}

.day-grid .day-card {
  direction: rtl;
  padding: 0;
  overflow: hidden;
  scroll-margin-top: 5rem; /* clear the pinned navbar when jumping to a day */
}

/* The date part repeats the home card exactly: same padding, label line, number and date line. */
.day-card__top {
  display: flex;
  flex-direction: column;
  padding: 1rem 1.25rem 1.25rem;
}

.day-card__toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  height: 1.7rem; /* the height of the home card's "היום" line */
  /* The big number's glyphs reach above its own line; keep the button on top so it stays clickable. */
  position: relative;
  z-index: 1;
}

.day-grid .day-card__number { font-size: 9rem; white-space: nowrap; }

.day-card__add { --bs-btn-padding-y: 0.1rem; --bs-btn-padding-x: 0.5rem; --bs-btn-font-size: 0.8125rem; white-space: nowrap; }

.day-grid .day-card--today { border-top-color: var(--sea); box-shadow: 0 0 0 2px rgba(9, 186, 189, 0.25); }

.day-card--past { background: #f1f4f4; border-top-color: var(--line); }
.day-card--past .day-card__number { color: #8a8888; }
.day-card--past .day-card__date { color: #5f5d5d; }
.day-card--past .day-card__body { color: #6f6d6d; }

.jump-today {
  display: inline-block;
  margin-top: 0.25rem;
  font-family: var(--font-body);
  font-size: 0.9375rem;
  font-weight: 700;
}

.day-card__body {
  border-top: 1px solid var(--line);
  padding: 0.65rem 0.75rem 0.75rem;
  font-size: 0.875rem;
  line-height: 1.4;
}

.day-card__empty { margin: 0; color: #6f6d6d; }

/* Between posts: Bootstrap's hr - the text color at 25% opacity, a light gray line. */
.post-sep { margin: 0.6rem 0; opacity: 0.25; }

.post-item__author { margin: 0; font-weight: 700; }
.post-item__author::before {
  content: "";
  display: inline-block;
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  margin-inline-end: 0.35rem;
  vertical-align: 0.05rem;
  background: var(--line);
}
.post-item--parent .post-item__author::before { background: var(--dusk); }
.post-item--babysitter .post-item__author::before { background: var(--sea); }

.post-item__mine {
  font-size: 0.75rem;
  font-weight: 600;
  background: #fdf6e3;
  border-radius: 4px;
  padding: 0 0.3rem;
  margin-inline-start: 0.25rem;
}

.post-item__text { margin: 0.15rem 0 0; overflow-wrap: anywhere; }

.post-item__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.25rem 0.85rem;
  margin: 0.3rem 0 0;
}

.post-item__edit, .post-item__comments { font-size: 0.8125rem; font-weight: 600; }

/* Distinct commenters: sand while nobody answered, turquoise once someone did. */
.comment-badge {
  background: var(--sand);
  color: var(--ink);
  font-size: 0.6875rem;
  min-width: 1.35rem;
  margin-inline-start: 0.15rem;
}
.comment-badge--active { background: var(--sea-ink); color: #fff; }

.show-more { --bs-btn-color: var(--sea-ink); --bs-btn-hover-color: var(--sea-ink); --bs-btn-active-color: var(--sea-ink);
  padding: 0; margin-top: 0.5rem; font-size: 0.8125rem; }

.post-form__date { font-weight: 700; color: var(--sea-ink); margin-top: -0.5rem; }

.danger-zone {
  margin-top: 2.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--line);
}

/* Disclaimer: a dialog over a dimmed page, closed only by agreeing. */
.disclaimer-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1050;
  background: rgba(44, 43, 43, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.disclaimer {
  background: var(--surface);
  border-top: 6px solid var(--sand);
  border-radius: 14px;
  width: 100%;
  max-width: 40rem;
  max-height: calc(100vh - 2rem);
  display: flex;
  flex-direction: column;
}

.disclaimer__title { font-size: 1.5rem; padding: 1.25rem 1.5rem 0; margin-bottom: 0.75rem; }

.disclaimer__list {
  overflow-y: auto;
  padding: 0 1.5rem 0 1.5rem;
  padding-inline-start: 2.75rem;
  margin: 0;
  display: grid;
  gap: 0.75rem;
}

.disclaimer__actions {
  padding: 1rem 1.5rem 1.25rem;
  border-top: 1px solid var(--line);
  margin-top: 1rem;
}

.disclaimer__actions .btn { width: 100%; }

.message-page__code {
  font-family: var(--font-display);
  font-size: 4rem;
  line-height: 1;
  color: var(--sea-ink);
  margin-bottom: 0.5rem;
}

/* Thread: the post on top, then the comments the viewer may see. */
.thread { max-width: 40rem; display: grid; gap: 1.5rem; }

.thread__back { font-weight: 700; justify-self: start; }
.thread__back::before { content: "›"; margin-inline-end: 0.35rem; }

.thread-post {
  background: var(--surface);
  border-top: 6px solid var(--sand);
  border-radius: 14px;
  padding: 1.25rem 1.5rem;
}

.thread-post__date {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--sea-ink);
  margin: 0 0 0.5rem;
}

.thread-post__text { margin: 0.35rem 0 0.5rem; white-space: pre-line; overflow-wrap: anywhere; }

.thread__comments .h4 { margin-bottom: 0.25rem; }
.thread__empty { margin: 1rem 0 0; color: #5f5d5d; }

.comment-list { list-style: none; padding: 0; margin: 1rem 0 0; display: grid; gap: 0.75rem; }

.comment-list__item {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.85rem 1rem;
  scroll-margin-top: 5rem;
}

/* The post author's reply hangs under the comment, marked by a turquoise line. */
.comment--reply {
  margin-top: 0.75rem;
  padding-inline-start: 0.85rem;
  border-inline-start: 3px solid var(--sea);
}

.comment__meta { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.15rem 0.6rem; margin: 0; }

.comment__name { font-weight: 700; }
.comment__name::before {
  content: "";
  display: inline-block;
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  margin-inline-end: 0.35rem;
  vertical-align: 0.05rem;
  background: var(--line);
}
.comment__name--parent::before { background: var(--dusk); }
.comment__name--babysitter::before { background: var(--sea); }
.comment__name--gone { color: #6f6d6d; font-weight: 600; }

.comment__tag {
  font-size: 0.75rem;
  font-weight: 600;
  background: #e6f7f7;
  color: var(--sea-ink);
  border-radius: 4px;
  padding: 0 0.3rem;
}

.comment__time { color: #5f5d5d; font-size: 0.8125rem; }

.comment__text { margin: 0.2rem 0 0; white-space: pre-line; overflow-wrap: anywhere; }

.comment__delete .btn { padding: 0; font-size: 0.8125rem; color: #8f2a3c; }

.reply-box { margin-top: 0.75rem; }
.reply-box > summary { list-style: none; }
.reply-box > summary::-webkit-details-marker { display: none; }
.reply-box[open] > summary { margin-bottom: 0.75rem; }

.comment-form {
  background: var(--surface);
  border-top: 4px solid var(--dusk);
  border-radius: 12px;
  padding: 1rem 1.25rem 1.25rem;
  margin-top: 1rem;
}

.reply-box__toggle {
  --bs-btn-color: var(--sea-ink);
  --bs-btn-border-color: var(--sea);
  --bs-btn-hover-bg: #e6f7f7;
  --bs-btn-hover-border-color: var(--sea);
  --bs-btn-hover-color: var(--sea-ink);
  font-weight: 700;
}

/* Dashboard email switches: purple when on, the label in bold, the hint underneath. */
.email-settings { margin: 1.5rem 0; }
.email-switch .form-check-label { font-weight: 600; }
.email-switch .form-check-input:checked { background-color: var(--dusk); border-color: var(--dusk); }
.email-switch .form-check-input:focus { border-color: var(--dusk); box-shadow: 0 0 0 0.2rem rgba(145, 100, 166, 0.25); }

/* Report: a quiet link on the post, and the reported post quoted on the report page. */
.post-item__report { font-size: 0.75rem; color: #6f6d6d; margin-inline-start: auto; }
.thread-post .post-item__report { font-size: 0.8125rem; }

.report-post {
  background: var(--surface);
  border-inline-start: 4px solid var(--line);
  border-radius: 8px;
  padding: 0.75rem 1rem;
  margin: 0 0 1rem;
}

/* Dashboard: my activity in the main column, profile and settings beside it on wide screens. */
.dashboard { max-width: 64rem; }
.dashboard__grid { display: grid; gap: 2rem; }
@media (min-width: 992px) {
  .dashboard__grid { grid-template-columns: minmax(0, 2fr) minmax(15rem, 1fr); align-items: start; }
  .dashboard__side { position: sticky; top: 5.5rem; }
}

.dash-section + .dash-section { margin-top: 2rem; }
.dash-section .h5 { margin-bottom: 0.15rem; }
.dash-empty { color: #5f5d5d; margin: 0.75rem 0 0; }

.dash-list { list-style: none; padding: 0; margin: 0.75rem 0 0; display: grid; gap: 0.6rem; }

.dash-item {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.75rem 1rem;
  scroll-margin-top: 5rem;
}

/* Something new since I last opened the thread: bold text and a sand marker at the start edge. */
.dash-item--unread { border-inline-start: 4px solid var(--sand); }
.dash-item--unread .dash-item__text { font-weight: 700; }

.dash-item--hidden { background: #f1f4f4; }
.dash-item--hidden .dash-item__text { color: #6f6d6d; }

.dash-item__head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.25rem 0.6rem; margin: 0; font-size: 0.9375rem; }
.dash-item__date { font-weight: 700; color: var(--sea-ink); }
.dash-item__new {
  font-size: 0.75rem;
  font-weight: 700;
  background: var(--sand);
  border-radius: 4px;
  padding: 0 0.35rem;
}
.dash-item__tag {
  font-size: 0.75rem;
  font-weight: 600;
  background: var(--line);
  border-radius: 4px;
  padding: 0 0.35rem;
}
.dash-item__by { margin: 0.1rem 0 0; font-size: 0.875rem; color: #5f5d5d; }
.dash-item__text {
  margin: 0.25rem 0 0;
  overflow-wrap: anywhere;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.dash-item__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 1rem;
  margin-top: 0.45rem;
  font-size: 0.875rem;
  font-weight: 600;
}
.dash-item__time { color: #5f5d5d; font-weight: 400; }

/* Show/hide: a form button drawn as a switch, so it works without JavaScript. */
.visibility-form { margin-inline-start: auto; }
.switch-button {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  border: 0;
  background: none;
  padding: 0;
  font: inherit;
  color: var(--ink);
}
.switch-button::before {
  content: "";
  width: 2.1rem;
  height: 1.2rem;
  border-radius: 1rem;
  background: var(--line) radial-gradient(circle, #fff 0.42rem, transparent 0.45rem) no-repeat right 0.05rem center / 1.1rem 1.1rem;
  transition: background-position 150ms ease;
}
.switch-button[aria-checked="true"]::before { background-color: var(--dusk); background-position: left 0.05rem center; }
.switch-button:focus-visible { outline: 2px solid var(--dusk); outline-offset: 3px; border-radius: 4px; }
@media (prefers-reduced-motion: reduce) { .switch-button::before { transition: none; } }

/* Analytics: one hero number, the site average beside it, then the monthly columns. */
.analytics { max-width: 44rem; display: grid; gap: 1.25rem; }
.analytics h1 { margin: 0; }

.stat-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr)); gap: 0.75rem; }
.stat {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.9rem 1.1rem;
}
.stat--hero { border-top: 4px solid var(--dusk); }
.stat__label { margin: 0; color: #5f5d5d; font-weight: 600; font-size: 0.9375rem; }
.stat__value { margin: 0.15rem 0 0; font-size: 1.5rem; font-weight: 700; line-height: 1.25; }
.stat--hero .stat__value { font-size: 2rem; }
.stat__note { margin: 0.2rem 0 0; color: #5f5d5d; font-size: 0.8125rem; }

.chart-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 1rem 1.1rem 0.5rem;
  margin: 0;
}
.column-chart { display: block; width: 100%; height: auto; font-family: var(--font-body); }
.column-chart__grid { stroke: var(--line); stroke-width: 1; }
.column-chart__axis { stroke: #b9c4c4; stroke-width: 1; }
.column-chart__tick { fill: #5f5d5d; font-size: 12px; font-variant-numeric: tabular-nums; }
.column-chart__unit { fill: #5f5d5d; font-size: 12px; font-weight: 600; }
.column-chart__bar { fill: var(--dusk); }
.column-chart__bar:hover, .column-chart__bar:focus { fill: var(--dusk-deep); outline: none; }
.column-chart__reference { stroke: #5f5d5d; stroke-width: 1; }
/* The chart scales down with the screen; its text is set larger in chart units so it stays readable. */
@media (max-width: 575px) {
  .column-chart__tick, .column-chart__unit { font-size: 21px; }
}

.chart-key { display: flex; align-items: center; gap: 0.4rem; margin: 0.25rem 0 0.5rem; color: #5f5d5d; font-size: 0.875rem; }
.chart-key__line { width: 1.25rem; border-top: 1px solid #5f5d5d; }

.chart-table summary { font-weight: 700; color: var(--sea-ink); cursor: pointer; }
.chart-table table { margin-top: 0.5rem; background: var(--surface); }
.chart-table__num { font-variant-numeric: tabular-nums; }

/* Dashboard heading with the way back to the calendar beside it (below it on phones). */
.dashboard__top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.5rem 1.5rem; margin-bottom: 1.25rem; }
.dashboard__title { margin: 0; }
.dashboard__go { display: flex; flex-direction: column; align-items: flex-start; gap: 0.25rem; }
.dashboard__go .field-hint { margin: 0; }
.nav-link[aria-current="page"] { color: var(--sea-ink); text-decoration: underline; text-decoration-color: var(--sand); text-decoration-thickness: 3px; text-underline-offset: 6px; }

.comment__gone-note { margin: 0.6rem 0 0; }

/* Search: a role-specific button by the month name, and a results page of posts separated by light rules. */

.search-page { max-width: 40rem; display: grid; gap: 1.25rem; }
.search-page h1 { margin: 0; }
.search-page__query { margin: 0; }
.search-results__summary { margin-bottom: 0.75rem; }
.search-results__list {
  background: var(--surface);
  border: 1px solid var(--line);
  border-top: 6px solid var(--sand);
  border-radius: 14px;
  padding: 1rem 1.25rem;
}
.search-results__list:empty { display: none; }
.search-result__date { margin: 0 0 0.15rem; font-weight: 700; font-size: 0.9375rem; }
.search-result__text { margin: 0.2rem 0 0; white-space: pre-line; overflow-wrap: anywhere; }
.search-result mark { background: #fbe7b0; color: inherit; padding: 0 0.1rem; border-radius: 2px; }
.search-results__more { justify-self: start; margin-top: 1rem; }
.search-results__summary .field-hint { font-weight: 400; margin-top: 0.15rem; }

/* Navbar search: right after the brand on wide screens, at the top of the menu on phones. */
.nav-search { display: flex; gap: 0.4rem; margin: 0.75rem 0 0.25rem; }
.nav-search .form-control { flex: 1; min-width: 0; }
@media (min-width: 768px) {
  .nav-search { margin: 0; margin-inline-start: 1.25rem; width: min(20rem, 100%); }
}
.navbar-nav .nav-link { white-space: nowrap; }
@media (min-width: 768px) and (max-width: 991.98px) {
  .nav-search { width: 12rem; margin-inline-start: 0.75rem; }
}

/* Navbar city menu: the browsed city, switchable without logging out. */
.nav-city { margin: 0.25rem 0 0.5rem; }
.nav-city__toggle {
  --bs-btn-color: var(--sea-ink);
  --bs-btn-border-color: var(--line);
  --bs-btn-hover-border-color: var(--sea);
  --bs-btn-hover-color: var(--sea-ink);
  --bs-btn-active-border-color: var(--sea);
  font-weight: 700;
}
.nav-city__menu { min-width: 15rem; padding-top: 0.25rem; }
.nav-city__hint { margin: 0 0 0.25rem; padding: 0.35rem 1rem 0.5rem; color: #5f5d5d; font-size: 0.8125rem; border-bottom: 1px solid var(--line); }
.nav-city__menu .dropdown-item.active, .nav-city__menu .dropdown-item:active { background: var(--sea-ink); color: #fff; }
.nav-city__home { font-size: 0.8125rem; }
@media (min-width: 768px) { .nav-city { margin: 0; margin-inline-start: 0.5rem; } }
@media (max-width: 767.98px) { .nav-city__menu { position: static; } }

/* Rating badge: a gold star with the average inside, right after a name (as in "rating badge.jpg"). */
.rating-badge { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 2.6em; height: 2.6em;
  vertical-align: middle; margin-block: -0.6em; margin-inline-start: 0.1rem; }
.rating-badge svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.rating-badge path { fill: #f2b52c; stroke: #c7881a; stroke-width: 1.3; stroke-linejoin: round; filter: drop-shadow(0 0 2px rgba(242, 181, 44, 0.45)); }
.rating-badge__value { position: relative; top: 0.1em; font-size: 0.74em; font-weight: 800; line-height: 1; color: #fff;
  text-shadow: 0 0 2px #9a6510, 0 0 1px #9a6510; font-variant-numeric: tabular-nums; }

/* Bookings: the author's "booked with" button and status under a comment, the other side's answer. */
.booking-box { display: flex; flex-wrap: wrap; align-items: center; gap: 0.25rem 0.75rem; margin: 0.75rem 0 0; font-size: 0.875rem; font-weight: 600; }
.booking-box__book { --bs-btn-color: var(--dusk-deep); --bs-btn-border-color: var(--dusk); --bs-btn-hover-bg: #f3ecf6;
  --bs-btn-hover-border-color: var(--dusk); --bs-btn-hover-color: var(--dusk-deep); font-weight: 700; }
.booking-box--pending { color: #8a6514; }
.booking-box--confirmed { color: var(--sea-ink); }
.booking-box--rejected { color: #6f6d6d; }
.booking-notice { display: grid; gap: 0.6rem; margin-top: 1rem; }
.booking-answer { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 0.6rem; }

/* Rating form on the dashboard: five numbered choices. */
.rating-form { margin-top: 0.75rem; display: grid; gap: 0.5rem; justify-items: start; }
.rating-form__legend { font-size: 0.9375rem; font-weight: 700; margin-bottom: 0.35rem; }
.rating-form__scores { display: flex; gap: 0.35rem; }
.rating-form__score input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.rating-form__score span { display: inline-flex; align-items: center; justify-content: center; width: 2.4rem; height: 2.4rem;
  border: 1px solid var(--line); border-radius: 50%; background: var(--surface); font-weight: 700; cursor: pointer; }
.rating-form__score input:checked + span { background: #f2b52c; border-color: #c7881a; color: #3b2a05; }
.rating-form__score input:focus-visible + span { outline: 2px solid var(--dusk); outline-offset: 2px; }

/* Local ads: a quiet "ממומן" card in the thread and at the bottom of the dashboard, and the popover after posting. */
.ad-card { position: relative; background: var(--surface); border: 1px dashed #c9d3d3; border-radius: 12px; padding: 0.6rem 0.85rem; }
.ad-card__tag { display: inline-block; margin: 0 0 0.35rem; font-size: 0.6875rem; font-weight: 700; color: #6f6d6d;
  background: #f1f4f4; border-radius: 4px; padding: 0 0.35rem; }
.ad-card__body { display: flex; align-items: center; gap: 0.75rem; color: var(--ink); text-decoration: none; }
a.ad-card__body:hover .ad-card__name { color: var(--sea-ink); text-decoration: underline; }
.ad-card__image { width: 4.5rem; height: 3rem; object-fit: cover; border-radius: 8px; flex-shrink: 0; }
.ad-card__name { font-weight: 700; }
.comment-list__ad { list-style: none; }
/* The banner's height is reserved while it loads, so the dashboard below it does not move; no ad, and it closes. */
.ad-slot--banner { min-height: 7.25rem; margin: 0 0 1.75rem; transition: min-height 200ms ease, margin 200ms ease; }
.ad-slot--banner.ad-slot--empty { min-height: 0; margin: 0; }
@media (prefers-reduced-motion: reduce) { .ad-slot--banner { transition: none; } }
.ad-card--banner .ad-card__image { width: 7rem; height: 4rem; }
/* One line for the name, so the banner keeps the reserved height on any screen. */
/* unicode-bidi: plaintext - an English name is cut at its end, like a Hebrew one. */
.ad-card--banner .ad-card__name { min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; unicode-bidi: plaintext; }
.ad-card--banner .ad-card__body { min-width: 0; }

.ad-popover { position: fixed; inset: 0; z-index: 1060; background: rgba(44, 43, 43, 0.6); display: flex; align-items: center;
  justify-content: center; padding: 1rem; }
.ad-popover__box { position: relative; background: var(--surface); border-top: 6px solid var(--sand); border-radius: 16px;
  width: min(26rem, 100%); max-height: calc(100vh - 2rem); overflow-y: auto; padding: 1.25rem 1.25rem 1.5rem;
  display: flex; flex-direction: column; align-items: center; gap: 0.6rem; text-align: center; }
.ad-popover__close { position: absolute; inset-inline-end: 0.6rem; top: 0.4rem; width: 2.5rem; height: 2.5rem; display: flex;
  align-items: center; justify-content: center; font-size: 1.75rem; line-height: 1; color: var(--ink); text-decoration: none; border-radius: 50%; }
.ad-popover__close:hover, .ad-popover__close:focus-visible { background: #f1f4f4; }
.ad-popover__title { margin: 0.25rem 0 0; font-family: var(--font-display); font-size: 1.35rem; font-weight: 600; color: var(--sea-ink); }
.ad-popover__ad { display: flex; flex-direction: column; align-items: center; gap: 0.5rem; color: var(--ink); text-decoration: none; }
.ad-popover__image { max-width: 100%; max-height: 60vh; object-fit: contain; border-radius: 10px; }
.ad-popover__name { font-weight: 700; font-size: 1.05rem; }
.ad-popover__continue { margin-top: 0.5rem; min-width: 10rem; }

/* Site numbers under the calendar: a quiet strip under a sand line, 4 in a row, 2 x 2 on phones. */
.site-stats { margin-top: 2.5rem; padding-top: 1.25rem; border-top: 3px solid var(--sand); }
.site-stats__title { margin: 0 0 0.75rem; text-align: center; font-family: var(--font-body); font-size: 1rem; font-weight: 600; color: #5f5d5d; }
.site-stats__list { margin: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0.75rem; }
.site-stats__item { display: flex; flex-direction: column-reverse; align-items: center; justify-content: flex-end; gap: 0.15rem;
  padding: 0.75rem 0.5rem; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; text-align: center; }
.site-stats__item dt { font-size: 0.875rem; font-weight: 400; color: #5f5d5d; }
.site-stats__item dd { margin: 0; font-family: var(--font-display); font-size: 1.75rem; font-weight: 600; line-height: 1.2; color: var(--sea-ink); }
.site-stats__item--time dd { font-size: 1.25rem; padding-block: 0.2rem; }
@media (max-width: 40rem) { .site-stats__list { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Offline page (shown by the service worker): no Bootstrap or web fonts, so it stands on this file alone. */
.offline-page { font-family: system-ui, sans-serif; align-items: center; justify-content: center; padding: 1.5rem 1rem; }
.offline { max-width: 26rem; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 0.5rem; }
.offline__icon { border-radius: 22px; }
.offline__brand { margin: 0.25rem 0 0; font-weight: 700; color: var(--sea-ink); }
.offline__title { margin: 0; font-size: 1.5rem; line-height: 1.3; }
.offline__text { margin: 0; color: #5f5d5d; }
.offline__retry { margin-top: 0.75rem; display: inline-block; padding: 0.6rem 1.5rem; border-radius: 999px;
  background: var(--dusk); color: #fff; font-weight: 700; text-decoration: none; }
.offline__retry:hover, .offline__retry:focus-visible { background: var(--dusk-deep); color: #fff; }

/* Install the app: a quiet card under a sand line, on the welcome page and in the dashboard's side column. */
.install-app { margin-top: 2rem; padding: 1rem 1.1rem; background: var(--surface); border: 1px solid var(--line);
  border-top: 3px solid var(--sand); border-radius: 12px; max-width: 36rem; }
.install-app[hidden] { display: none; }
.install-app__title { margin: 0 0 0.35rem; font-size: 1.125rem; color: var(--sea-ink); }
.install-app p { margin: 0 0 0.6rem; }
.install-app__steps-title { font-weight: 700; }
.install-app__steps { margin: 0 0 0.6rem; padding-inline-start: 1.25rem; }
.install-app__safety { font-size: 0.875rem; color: #5f5d5d; border-inline-start: 3px solid var(--sea); padding-inline-start: 0.6rem; }
.install-app .btn { margin-bottom: 0.75rem; }
.dashboard__side .install-app { margin-top: 1.5rem; }

/* Footer: the tagline and the accessibility statement link. */
.site-footer { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 0.5rem 1.5rem; }

/* The accessibility statement: a readable column of text. */
.statement { max-width: 44rem; }
.statement h2 { font-size: 1.25rem; margin: 1.75rem 0 0.5rem; color: var(--sea-ink); }
.statement ul { padding-inline-start: 1.25rem; }
.statement li { margin-bottom: 0.4rem; }
.statement__updated { margin-top: 2rem; color: #5f5d5d; font-size: 0.9375rem; }

/* The idle-logout notice: pinned to the bottom of the screen, above everything, under a sand line. */
.session-notice { position: fixed; inset-inline: 0; bottom: 0; z-index: 1090; background: var(--surface);
  border-top: 4px solid var(--sand); box-shadow: 0 -2px 0 rgba(44, 43, 43, 0.08);
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 0.75rem 1.25rem; padding: 1rem; }
.session-notice[hidden] { display: none; }
.session-notice__text { margin: 0; font-weight: 600; max-width: 36rem; }

/* The notice at registration: what happens with the user's details (a quiet box, like the install card). */
.data-notice { background: var(--surface); border: 1px solid var(--line); border-inline-start: 3px solid var(--sea-ink);
  border-radius: 10px; padding: 0.75rem 1rem; }
.data-notice__title { font-size: 1rem; margin: 0 0 0.4rem; color: var(--sea-ink); }
.data-notice__list { margin: 0; padding-inline-start: 1.1rem; font-size: 0.9375rem; color: #5f5d5d; }
.data-notice__list li { margin-bottom: 0.3rem; }

/* The children's privacy hint under the post text. */
.post-form__privacy { border-inline-start: 3px solid var(--sand); padding-inline-start: 0.5rem; }

/* Footer links (privacy policy, accessibility statement), and the policy's tables and date. */
.site-footer__links { display: flex; flex-wrap: wrap; gap: 0.5rem 1.25rem; }
.statement__updated--top { margin-top: -0.5rem; }
.statement__table { overflow-x: auto; }
.statement .table { --bs-table-bg: var(--surface); font-size: 0.9375rem; margin-bottom: 0.75rem; }
.statement .table th[scope="row"] { font-weight: 600; }
.data-notice__link { margin: 0.4rem 0 0; font-size: 0.9375rem; }

/* Babysitters' age question (Step 19): three choices in one row, wrapping on narrow phones. */
.age-field { display: grid; gap: 1rem; }
.age-field[hidden], .guardian-email[hidden] { display: none; }
.age-choice { display: grid; grid-template-columns: repeat(auto-fit, minmax(7.5rem, 1fr)); gap: 0.75rem; }
.guardian-approve__go { display: flex; flex-wrap: wrap; gap: 0.75rem; }
.guardian-approve__disclaimer { font-size: 0.95rem; }
/* A supervising parent's view starts well apart from their own lists, under a centered band in the notice color. */
.minors { margin-top: 3.5rem; }
.minor-activity + .minor-activity { margin-top: 3.5rem; }
.minor-activity .minor-activity__title {
  text-align: center;
  background: #fdf6e3;
  border-bottom: 3px solid var(--sand);
  border-radius: 6px;
  padding: 0.75rem 1rem;
  margin-bottom: 0.5rem;
}
.minor-activity h3 { margin-top: 1rem; }
.minor-end { margin-top: 1rem; }
.minor-end summary { cursor: pointer; font-weight: 600; color: var(--sea-ink); min-height: 24px; }
.minor-end__form { margin-top: 0.75rem; }
.minor-end__form .field-hint { margin: 0.25rem 0 0; }
/* "Under 18, with a parent's approval" under a name; in a flex row it takes a line of its own. */
.minor-line { display: block; flex-basis: 100%; font-size: 0.8rem; font-weight: 400; color: #5f5d5d; }
