/*
 * THE FAMILIES' SIDE (v1.383) - the old website's look, his answer of 19 Oct 2026 (14.89): "I like the look of this site. And if I
 * remember correctly, it sizes itself to mobile users pretty well." Its red side menu with the dolphin on a computer; on a phone a
 * red bar with the dolphin and a menu button (the menu opening beneath it); red title cards and red headings on white; light
 * only. Helvetica / Arial, 16 pixels - a phone does not zoom into a box of that size.
 */
:root {
  --red: #b71c1c;
  --red-deep: #8e1414;
  --red-light: #e53935;
  --red-wash: #fff5f5;
  --ink: #222;
  --ink-soft: #555;
  --line: #d6d6d6;
  --good: #2e7d32;
  --good-deep: #1b5e20; /* the paid invoices' words (v1.386) - the Paid chip's own green */
  --good-wash: #e8f5e9;
  --met: #3ea76a; /* Mockup 16's checklist green */
  --bad: #c62828;
  --bad-wash: #fdecea;
  --warn: #f9a825;
  --warn-wash: #fff8e1;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  background: #fff;
  color: var(--ink);
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.5;
}

a {
  color: var(--red);
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 3px solid var(--red-light);
  outline-offset: 2px;
}

/* ---- the frame: the side menu on a computer ------------------------------------------------------------------------ */
.shell {
  display: flex;
  min-height: 100vh;
}

.side {
  flex: 0 0 250px;
  background: linear-gradient(180deg, var(--red) 0%, var(--red-light) 100%);
  color: #fff;
}

.brand {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px 16px 10px;
}

.logo-link {
  display: block;
  line-height: 0;
}

.logo {
  width: 210px;
  height: auto;
  display: block;
}

.menu-button {
  display: none;
}

.menu {
  display: flex;
  flex-direction: column;
  padding: 8px 0 24px;
}

.menu a,
.menu button {
  display: block;
  width: 100%;
  padding: 12px 24px;
  color: #fff;
  text-decoration: none;
  font: inherit;
  font-size: 16px;
  text-align: left;
  background: none;
  border: 0;
  border-left: 4px solid transparent;
  cursor: pointer;
}

.menu a:hover,
.menu button:hover {
  background: rgba(255, 255, 255, 0.12);
}

.menu a.here {
  background: rgba(255, 255, 255, 0.2);
  border-left-color: #fff;
  font-weight: bold;
}

.menu .first-sign {
  display: inline-block;
  margin-left: 8px;
  padding: 0 7px;
  border-radius: 10px;
  background: #fff;
  color: var(--red);
  font-size: 12px;
  font-weight: bold;
  line-height: 20px;
  vertical-align: 1px;
}

.menu .gap {
  height: 1px;
  margin: 10px 24px;
  background: rgba(255, 255, 255, 0.35);
}

.main {
  flex: 1 1 auto;
  min-width: 0;
  padding: 28px 32px 48px;
  max-width: 900px;
}

/* ---- on a phone: a red bar with the dolphin and the menu button ------------------------------------------------------ */
@media (max-width: 760px) {
  /* The red bar stays at the top as the page scrolls - a box the browser scrolls to stops below it, never under it. */
  html {
    scroll-padding-top: 72px;
  }

  .shell {
    display: block;
  }

  .side {
    position: sticky;
    top: 0;
    z-index: 5;
    background: linear-gradient(90deg, #c0392b 0%, #e74c3c 100%);
  }

  .brand {
    justify-content: space-between;
    padding: 8px 12px;
  }

  .logo {
    width: auto;
    height: 44px;
  }

  .menu-button {
    display: block;
    width: 44px;
    height: 44px;
    border: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: 6px;
    background: transparent;
    color: #fff;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
  }

  .menu {
    display: none;
    padding: 0 0 8px;
    background: linear-gradient(180deg, var(--red) 0%, var(--red-light) 100%);
  }

  .menu.open {
    display: flex;
  }

  .main {
    padding: 18px 16px 40px;
  }
}

/* ---- the page's parts ------------------------------------------------------------------------------------------------ */
.loading {
  color: var(--ink-soft);
}

.title {
  margin: 0 0 20px;
  padding: 16px 20px;
  border-radius: 8px;
  background: linear-gradient(90deg, var(--red) 0%, var(--red-light) 100%);
  color: #fff;
}

.title h1 {
  margin: 0;
  font-size: 24px;
  line-height: 1.25;
}

.title p {
  margin: 4px 0 0;
  opacity: 0.95;
}

.card {
  margin: 0 0 18px;
  padding: 18px 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.card h2 {
  margin: 0 0 10px;
  padding: 6px 12px;
  border-left: 4px solid var(--red-light);
  background: var(--red-wash);
  color: var(--red);
  font-size: 18px;
}

.narrow {
  max-width: 440px;
}

.note {
  color: var(--ink-soft);
}

.box {
  margin: 0 0 16px;
  padding: 12px 14px;
  border-left: 4px solid;
  border-radius: 4px;
}

.box.problem {
  border-color: var(--bad);
  background: var(--bad-wash);
  color: var(--red-deep);
}

.box.ok {
  border-color: var(--good);
  background: var(--good-wash);
  color: #1b5e20;
}

.box.due {
  border-color: var(--warn);
  background: var(--warn-wash);
  color: #5d4300;
}

.box p {
  margin: 0;
}

.box p + p {
  margin-top: 6px;
}

/* the school's own words - the waiver, the Policies, the Course Description, About */
.words h2 {
  margin: 0 0 12px;
  color: var(--red);
  font-size: 22px;
}

.words h3 {
  margin: 22px 0 10px;
  padding: 6px 12px;
  border-left: 4px solid var(--red-light);
  background: var(--red-wash);
  color: var(--red);
  font-size: 18px;
}

.words table {
  border-collapse: collapse;
  margin: 0 0 12px;
}

.words td {
  padding: 6px 14px 6px 0;
  border-bottom: 1px solid var(--line);
}

.words ul {
  padding-left: 22px;
}

/* ---- forms ----------------------------------------------------------------------------------------------------------- */
label.field {
  display: block;
  margin: 0 0 4px;
}

label.field > span {
  font-weight: bold;
}

input[type='email'],
input[type='password'],
input[type='text'],
textarea {
  width: 100%;
  min-height: 48px;
  padding: 10px 12px;
  border: 1px solid #bdbdbd;
  border-radius: 6px;
  font: inherit;
  font-size: 16px;
  color: var(--ink);
  background: #fff;
}

textarea {
  min-height: 72px;
  resize: vertical;
}

.with-show {
  display: flex;
  gap: 8px;
}

.with-show input {
  flex: 1 1 auto;
  min-width: 0;
}

.tick {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin: 0 0 16px;
  cursor: pointer;
}

.tick input {
  flex: 0 0 auto;
  width: 22px;
  height: 22px;
  margin: 1px 0 0;
  accent-color: var(--red);
}

button.go,
a.go {
  display: inline-block;
  min-height: 48px;
  padding: 12px 22px;
  border: 0;
  border-radius: 6px;
  background: var(--red);
  color: #fff;
  font: inherit;
  font-weight: bold;
  text-decoration: none;
  text-align: center;
  cursor: pointer;
}

button.go:hover,
a.go:hover {
  background: var(--red-deep);
}

button.go:disabled {
  background: #bdbdbd;
  cursor: default;
}

button.plain,
a.plain {
  display: inline-block;
  min-height: 48px;
  padding: 11px 18px;
  border: 1px solid var(--red);
  border-radius: 6px;
  background: #fff;
  color: var(--red);
  font: inherit;
  font-weight: bold;
  text-decoration: none;
  cursor: pointer;
}

button.plain:hover,
a.plain:hover {
  background: var(--red-wash);
}

.full {
  width: 100%;
}

.row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.links {
  margin: 16px 0 0;
}

/* the password's checklist, turning green as each part is met (Mockup 16) */
.checklist {
  list-style: none;
  margin: -6px 0 14px;
  padding: 0;
  color: var(--ink-soft);
  font-size: 15px;
}

.checklist li::before {
  content: '\25CB';
  display: inline-block;
  width: 22px;
}

.checklist li.met {
  color: var(--met);
  font-weight: bold;
}

.checklist li.met::before {
  content: '\2713';
}

/* the waiver's details - the holder, each child, each child's notes */
.who {
  margin: 0 0 14px;
}

.who dt {
  font-weight: bold;
}

.who dd {
  margin: 0 0 4px;
}

.child {
  margin: 0 0 14px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 6px;
}

.child .name {
  font-weight: bold;
}

.sign {
  margin-top: 24px;
  padding-top: 18px;
  border-top: 2px solid var(--red-light);
}

.means {
  margin: 0 0 14px;
  color: var(--ink-soft);
}

/* ---- billing (1b, v1.384): what is owed, each invoice with Pay on its right ------------------------------------------ */
.card h3 {
  margin: 20px 0 6px;
  color: var(--red);
  font-size: 16px;
}

.owed-now {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 12px;
  margin: 4px 0 8px;
  font-size: 18px;
}

.owed-now b {
  color: var(--red-deep);
  font-size: 28px;
}

.owed-now.none {
  color: var(--good);
  font-weight: bold;
}

/* PAY ALL - to the right of Owed now (G2c-2, v1.398): the Pay link's own look, a little larger. */
.owed-now a.pay-all {
  font-size: 16px;
  margin-left: 4px;
}

.owed-line {
  margin: 0 0 10px;
}

.invs {
  list-style: none;
  margin: 0 0 12px;
  padding: 0;
}

.inv {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 16px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}

.inv:last-child {
  border-bottom: 0;
}

.inv-info {
  display: flex;
  flex: 1 1 260px;
  flex-direction: column;
  min-width: 0;
  color: var(--ink);
  text-decoration: none;
}

.inv-info:hover .inv-title {
  text-decoration: underline;
}

.inv-title {
  color: var(--red);
  font-weight: bold;
}

.inv-line {
  color: var(--ink-soft);
  font-size: 15px;
}

.inv-side {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 8px 12px;
}

.inv-owed b {
  font-size: 18px;
}

a.go.pay {
  min-width: 96px;
}

/* AUTOPAY (AP1, v1.401) - the Autopay page's state, its buttons, the password asked again. */
.ap-state {
  font-size: 1.05rem;
}
.ap-state.on b {
  color: #1f7a4d;
}
.ap-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-top: 12px;
}
form.ap-off {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid #ddd;
}
form.ap-off input {
  display: block;
  margin: 4px 0 8px;
}
.ap-line a {
  margin-left: 4px;
}
.chip {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: bold;
  white-space: nowrap;
}

.chip.paid {
  background: var(--good-wash);
  color: #1b5e20;
}

.chip.late {
  background: var(--bad-wash);
  color: var(--red-deep);
}

.chip.pending {
  background: var(--warn-wash);
  color: #5d4300;
}

.inv-said {
  flex: 1 1 100%;
}

/* THE PAID INVOICES APART (his request, 20 Oct 2026, v1.386): a thick black line above them, and their words in green, not
   red - the heading, each invoice's number and name, and Show older. */
.paid-part {
  margin-top: 22px;
  border-top: 3px solid #000;
}

.paid-part h3.paid-head {
  margin-top: 16px;
  color: var(--good-deep);
}

.paid-part .inv-title {
  color: var(--good-deep);
}

.paid-part button.plain {
  border-color: var(--good-deep);
  color: var(--good-deep);
}

.paid-part button.plain:hover {
  background: var(--good-wash);
}

.inv-said p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 15px;
}

/* On a phone the amount and Pay sit on their own line under the invoice, Pay on the right. */
@media (max-width: 760px) {
  .inv-side {
    width: 100%;
  }
}

/* ---- ABSENCES & MAKEUPS (part 2, v1.389) -------------------------------------------------------------------------------- */
/* an announcement, not a warning: white, the site's red edge, ordinary words (found walking it - the red wash read as a
   problem) */
.box.soon {
  border: 1px solid var(--line);
  border-left: 4px solid var(--red-light);
  background: #fff;
  color: var(--ink);
}

.box.soon b {
  color: var(--red);
}

.note.small,
.small {
  font-size: 14px;
}

button.plain.small {
  min-height: 36px;
  padding: 6px 12px;
  font-size: 14px;
}

.swimmer-abs {
  padding: 4px 0 14px;
  border-bottom: 1px solid var(--line);
}

.swimmer-abs:last-child {
  border-bottom: 0;
}

.swimmer-abs h3 {
  margin: 10px 0 8px;
  color: var(--ink);
  font-size: 18px;
}

.abs-class {
  margin: 0 0 12px;
}

.abs-where {
  margin: 0 0 4px;
}

.dchips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 8px;
}

.dchip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 44px;
  padding: 6px 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  font-weight: bold;
  cursor: pointer;
}

.dchip[hidden] {
  display: none;
}

.dchip input {
  width: 20px;
  height: 20px;
  margin: 0;
  accent-color: var(--red);
}

.dchip:has(input:checked) {
  border-color: var(--red);
  background: var(--red-wash);
  color: var(--red-deep);
}

/* out - the roster's tan, the family's doing */
.dchip.out {
  border-color: #c8a46e;
  background: #f3e3c3;
  color: #5b3d10;
  cursor: default;
}

.dchip.off {
  border-style: dashed;
  background: #f4f4f4;
  color: #777;
  font-weight: normal;
  cursor: default;
}

.dchip small {
  font-size: 12px;
  font-weight: normal;
}

.outs,
.mk-list {
  margin: 6px 0 8px;
  padding: 0;
  list-style: none;
}

.outs li {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 12px;
  padding: 6px 0;
}

.out-what {
  font-weight: bold;
}

.mk-list li {
  padding: 4px 0;
}

.abs-makeups h4 {
  margin: 8px 0 4px;
  font-size: 16px;
}

.abs-makeups p {
  margin: 4px 0;
}

.abs-past summary {
  margin: 8px 0 0;
  color: var(--red);
  font-weight: bold;
  cursor: pointer;
}

/* the Mark absent bar - in view at the foot of the screen while anything is ticked */
.mark-bar {
  position: sticky;
  bottom: 0;
  z-index: 5;
  margin: 18px 0 0;
  padding: 12px 14px;
  border: 2px solid var(--red);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.12);
}

.mark-bar[hidden] {
  display: none;
}

.mark-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.mark-count {
  font-weight: bold;
}

.mark-row select,
.mark-row input[type='text'] {
  min-height: 44px;
  padding: 8px 10px;
  border: 1px solid #999;
  border-radius: 6px;
  font: inherit;
}

.mark-row input[type='text'] {
  flex: 1 1 160px;
  width: auto;
}

.mark-row input[hidden] {
  display: none;
}

.mark-bar .box {
  margin-bottom: 10px;
}

/* a question over the page */
.ask-back {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(0, 0, 0, 0.45);
}

.ask-card {
  max-width: 460px;
  width: 100%;
  padding: 18px 20px;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.3);
}

.ask-card h2 {
  margin: 0 0 10px;
  color: var(--red);
  font-size: 18px;
}

.ask-card p {
  margin: 0 0 16px;
}

/* ---- printing: the waiver and the words, nothing else ---------------------------------------------------------------- */
@media print {
  .side,
  .no-print,
  button,
  .menu-button {
    display: none !important;
  }

  .shell {
    display: block;
  }

  .main {
    padding: 0;
    max-width: none;
  }

  .title {
    background: none;
    color: #000;
    padding: 0 0 8px;
    border-bottom: 2px solid #000;
    border-radius: 0;
  }

  .card,
  .child {
    border: 0;
    padding: 0;
  }
}
