/*
  The closed site (resources/views/closed/*, and the few old pages that stay open: password reset, privacy policy).
  Written by hand: no build step, nothing from the old stylesheets, no fonts or files from anywhere else.

  The look: the page is a guestbook. The old navy header band, the farewell as the last entry in the
  Name / Date / Message table (.entry), and what is left of the control panel in boxes with a navy title bar (.box).
  Georgia for what is said, Verdana for what is used. Square corners, light only.
*/

:root {
  color-scheme: light;
  --navy: #0c356a;
  --band: #347ba2;
  --blue: #175386;
  --blue-deep: #0e3c64;
  --ink: #0f151d;
  --text: #2a333f;
  --muted: #5c6774;
  --hair: #c9d2dd;
  --field: #7d8a99;
  --page: #ffffff;
  --wash: #eef3f8;
  --red: #a3261c;
  --red-deep: #7c1a12;
  --display: Georgia, "Iowan Old Style", "Times New Roman", serif;
  --body: Verdana, Geneva, "DejaVu Sans", Tahoma, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { margin: 0; background: var(--page); color: var(--text); font: 14px/1.65 var(--body); }
a { color: var(--blue); text-underline-offset: 3px; }
a:hover { color: var(--blue-deep); }
:focus-visible { outline: 3px solid var(--band); outline-offset: 2px; }
b, strong { color: var(--ink); }
hr { height: 0; margin: 24px 0; border: 0; border-top: 1px solid var(--hair); }

/* ---- the frame: header band, page column, footer ---- */

.top { background: var(--navy); border-bottom: 6px solid var(--band); }
.top-in, .main, .foot-wrap { max-width: 1120px; margin: 0 auto; padding-left: 32px; padding-right: 32px; }
.top-in { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 84px; }
.top a { display: block; }
.top img { display: block; width: 168px; height: 57px; }
.top span { color: #c8ddef; font-size: 11px; font-weight: bold; letter-spacing: .16em; text-transform: uppercase; white-space: nowrap; }
.wide { font-style: normal; }

.main { display: grid; grid-template-columns: minmax(0, 1.75fr) minmax(300px, 1fr); gap: 48px; align-items: start; padding-top: 56px; padding-bottom: 64px; }
.main-solo { grid-template-columns: minmax(0, 620px); }
.main-wide { grid-template-columns: minmax(0, 760px); }
.side { display: grid; gap: 24px; }

.foot { padding-top: 18px; padding-bottom: 40px; border-top: 1px solid var(--hair); color: var(--muted); font-size: 12px; display: flex; flex-wrap: wrap; gap: 6px 24px; justify-content: space-between; }
.foot p { margin: 0; }

.kicker { margin: 0 0 12px; color: var(--muted); font-size: 11px; font-weight: bold; letter-spacing: .16em; text-transform: uppercase; }
.kicker a { color: inherit; }
.small { margin: 14px 0 0; font-size: 12px; }

/* ---- the last entry ---- */

.entry { margin: 0; border: 2px solid var(--ink); padding: 28px 32px 32px; }
.entry dl { margin: 0; display: grid; grid-template-columns: 104px minmax(0, 1fr); row-gap: 6px; }
.entry dt { color: var(--ink); font-weight: bold; }
.entry dd { margin: 0; color: var(--ink); }
.entry .msg { padding-top: 22px; margin-top: 16px; border-top: 1px solid var(--hair); }
.entry h1 { margin: -6px 0 20px; font: bold 66px/1.02 var(--display); letter-spacing: -.022em; color: var(--ink); text-wrap: balance; }
.entry p { margin: 0 0 14px; max-width: 30em; font: 21px/1.5 var(--display); color: var(--text); }
.entry p:last-child { margin-bottom: 0; }
.smile { width: 30px; height: 30px; margin-left: 6px; vertical-align: -6px; image-rendering: pixelated; }

/* ---- control-panel boxes ---- */

.box { border: 1px solid var(--navy); background: var(--page); }
.box-title { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 2px 16px; margin: 0; padding: 9px 16px; background: var(--navy); color: #fff; font: bold 12px/1.65 var(--body); letter-spacing: .04em; }
.box-title span { font-weight: normal; letter-spacing: 0; color: #c8ddef; overflow-wrap: anywhere; }
.box-title a { color: #fff; }
.box-body { padding: 20px 20px 22px; background: var(--wash); }
.box-body > p { margin: 0 0 18px; }
.box-body > :last-child { margin-bottom: 0; }
.box-big .box-body { padding: 26px 28px 30px; }

.box-body h1, .sheet h1 { margin: 0 0 14px; font: bold 38px/1.08 var(--display); letter-spacing: -.015em; color: var(--ink); text-wrap: balance; }
.box-body h2, .sheet h2 { margin: 28px 0 8px; font: bold 22px/1.2 var(--display); color: var(--ink); }
.side .box-body h2 { margin-top: 0; }
.lead { font: 18px/1.5 var(--display); color: var(--text); }
.box-body .lead { margin-bottom: 20px; }

/* a page of text: the privacy policy */
.sheet h1 { font-size: 52px; margin-bottom: 24px; }
.sheet h2 { margin-top: 36px; padding-top: 18px; border-top: 1px solid var(--hair); }
.sheet p { margin: 0 0 14px; }

/* ---- forms: the class names of the old pages, so their markup is used as it is ---- */

.ug-form { margin: 0; }
.ug-form-row { margin: 0 0 14px; }
.ug-label, .ug-form-row > label { display: block; margin: 0 0 5px; color: var(--ink); font-size: 12px; font-weight: bold; }
.ug-input, .ug-input-error {
  display: block; width: 100%; height: 40px; padding: 0 10px;
  border: 1px solid var(--field); border-radius: 0; background: #fff; color: var(--ink); font: 16px var(--body);
  -webkit-appearance: none; appearance: none;
}
.ug-input:focus, .ug-input-error:focus { outline: 3px solid var(--band); outline-offset: 0; border-color: var(--navy); }
.ug-input-error { border: 2px solid var(--red); }
.ug-field-error { margin-top: 5px; color: var(--red-deep); font-size: 12px; font-weight: bold; }
.ug-hint { margin-top: 5px; color: var(--muted); font-size: 12px; }

.ug-button {
  display: inline-block; min-height: 44px; margin-top: 4px; padding: 11px 24px;
  border: 0; border-radius: 0; background: var(--blue); color: #fff;
  font: bold 14px/22px var(--body); text-align: center; text-decoration: none; cursor: pointer;
  -webkit-appearance: none; appearance: none;
}
.ug-button:hover { background: var(--blue-deep); color: #fff; }
.ug-button-danger { background: var(--red); }
.ug-button-danger:hover { background: var(--red-deep); }
.box-side .ug-button { display: block; width: 100%; }

.ug-notice, .ug-errors { margin: 0 0 18px; padding: 10px 14px; background: #fff; border: 1px solid var(--hair); border-left: 5px solid var(--band); color: var(--ink); }
.ug-errors { border-left-color: var(--red); color: var(--red-deep); font-weight: bold; }
.ug-notice p, .ug-errors p { margin: 0; }
.ug-notice b, .ug-errors b { color: inherit; }
.ug-errors ul { margin: 0; padding-left: 18px; }

.ug-form-row > .check { display: flex; gap: 10px; align-items: flex-start; margin: 4px 0 0; color: var(--ink); font-size: 14px; font-weight: normal; cursor: pointer; }
.check input { flex: none; width: 18px; height: 18px; margin: 3px 0 0; accent-color: var(--navy); }
.mt-4 { margin-top: 16px; }

/* ---- the download page ---- */

.count { color: var(--muted); }
.downloads { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.download { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 16px; align-items: baseline; padding: 14px 16px 15px; background: #fff; border: 1px solid var(--field); color: var(--text); text-decoration: none; }
.download:hover { border-color: var(--navy); box-shadow: inset 4px 0 0 var(--navy); color: var(--text); }
.download-title { font: bold 20px/1.25 var(--display); color: var(--blue); text-decoration: underline; text-underline-offset: 3px; }
.download:hover .download-title { color: var(--blue-deep); }
.download-kind { grid-column: 2; grid-row: 1; padding: 1px 7px; border: 1px solid var(--navy); color: var(--navy); font-size: 11px; font-weight: bold; letter-spacing: .12em; }
.download-text { grid-column: 1 / -1; font-size: 13px; }

.who { overflow-wrap: anywhere; }
.books { list-style: none; margin: 0 0 18px; padding: 0; border-bottom: 1px solid var(--hair); }
.books li { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 8px 0; border-top: 1px solid var(--hair); }
.books form { margin: 0; flex: none; }
.book-name { min-width: 0; overflow-wrap: anywhere; color: var(--ink); }
.is-current .book-name { font-weight: bold; }
.book-state { flex: none; color: var(--muted); font-size: 12px; }
.link-button { padding: 0; border: 0; background: none; color: var(--blue); font: 14px/1.65 var(--body); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.link-button:hover { color: var(--blue-deep); }

/* ---- phones ---- */

@media (max-width: 860px) {
  .wide { display: none; }
  .top-in, .main, .foot-wrap { padding-left: 16px; padding-right: 16px; }
  .top img { width: 132px; height: 45px; }
  .top-in { min-height: 68px; }
  .main { grid-template-columns: minmax(0, 1fr); gap: 32px; padding-top: 32px; padding-bottom: 40px; }
  .entry { padding: 20px 18px 24px; }
  .entry dl { grid-template-columns: 76px minmax(0, 1fr); }
  .entry .msg { grid-column: 1 / -1; }
  .entry dt.msg { padding-bottom: 0; border-top: 1px solid var(--hair); }
  .entry dd.msg { border-top: 0; margin-top: 0; padding-top: 10px; }
  .entry h1 { margin-top: 0; font-size: 40px; }
  .entry p { font-size: 18px; }
  .box-big .box-body { padding: 20px 16px 22px; }
  .box-body h1 { font-size: 30px; }
  .sheet h1 { font-size: 36px; }
  .ug-button { display: block; width: 100%; }
}
