/* Even Datum — harbourmaster's dock tickets
   One stylesheet. No web fonts, no external requests, no image files.
   Every ornament below is pure CSS or an inline SVG data URI. */

:root {
  --bg: #efe9dd;
  --text: #22303a;
  --accent: #b23b2e;
  --accent-2: #5c7385;
  --card: #fbf8f2;
  --display: "Palatino Linotype", "Iowan Old Style", Georgia, serif;
  --body: -apple-system, "Segoe UI", Helvetica, Arial, sans-serif;
  --mono: "Courier New", "SF Mono", Menlo, Consolas, monospace;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.65;
}

/* ---------- skip link ---------- */

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--accent);
  color: #ffffff;
  font-family: var(--mono);
  padding: 0.6rem 0.9rem;
  z-index: 50;
}
.skip:focus { left: 0; }

/* ---------- header ---------- */

.masthead {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--bg);
  border-bottom: 2px solid var(--text);
}

.masthead-inner {
  max-width: 660px;
  margin: 0 auto;
  padding: 0.7rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.wordmark {
  font-family: var(--display);
  font-size: 1.22rem;
  letter-spacing: -0.01em;
  color: var(--text);
  text-decoration: none;
  white-space: nowrap;
}
.wordmark .wordmark-rule {
  display: block;
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  border-top: 2px solid var(--accent-2);
  margin-top: 2px;
  padding-top: 2px;
}

.menu-button {
  display: none;
  font-family: var(--mono);
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  background: var(--card);
  color: var(--text);
  border: 2px solid var(--text);
  border-radius: 0;
  padding: 0.4rem 0.7rem;
  cursor: pointer;
}

.site-nav ul {
  list-style: none;
  display: flex;
  gap: 1.1rem;
  margin: 0;
  padding: 0;
}
.site-nav a {
  font-family: var(--mono);
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  padding-bottom: 2px;
}
.site-nav a:hover,
.site-nav a[aria-current="page"] { border-bottom-color: var(--accent); }

/* ---------- layout ---------- */

main { display: block; }

.column {
  max-width: 660px;
  margin: 0 auto;
  padding: 0 1rem;
}

.lede { padding-top: 2.4rem; }

/* ---------- type ---------- */

h1, h2, h3, h4 {
  font-family: var(--display);
  font-weight: 400;
  line-height: 1.15;
  letter-spacing: -0.015em;
  margin: 0 0 0.6rem;
}
h1 { font-size: 2.1rem; }
h2 { font-size: 1.5rem; margin-top: 2.1rem; }
h3 { font-size: 1.18rem; margin-top: 1.6rem; }
h4 { font-size: 1.02rem; margin-top: 1.2rem; }

p { margin: 0 0 1.05rem; }

a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }
a:hover { text-decoration-thickness: 2px; }

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

strong { font-weight: 700; }

code, .mono { font-family: var(--mono); font-size: 0.93em; }

/* ---------- the ticket (every homepage section, and boxed units) ---------- */

.ticket {
  position: relative;
  background: var(--card);
  border: 2px solid var(--text);
  border-radius: 0;
  margin: 1.6rem 0;
  padding: 1.3rem 1.4rem 1.3rem 2.7rem;
}
.ticket::before {
  content: "";
  position: absolute;
  left: 0.85rem;
  top: 0.2rem;
  bottom: 0.2rem;
  width: 10px;
  background-image: radial-gradient(circle at 5px 7px, var(--bg) 3.6px, rgba(0,0,0,0) 4.1px);
  background-size: 10px 14px;
  background-repeat: repeat-y;
}

.berth {
  display: inline-block;
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text);
  border-bottom: 2px solid var(--accent-2);
  padding-bottom: 2px;
  margin-bottom: 0.8rem;
}

.ticket h2 { margin-top: 0; }

/* ---------- step header stub ---------- */

.step-head {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin: 2.4rem 0 0.4rem;
}
.stub {
  flex: 0 0 auto;
  background: var(--accent);
  color: #ffffff;
  font-family: var(--mono);
  font-size: 1.5rem;
  line-height: 1;
  padding: 0.75rem 0.8rem;
  border-radius: 0;
}
.stub span {
  display: block;
  font-size: 0.56rem;
  letter-spacing: 0.16em;
  margin-bottom: 0.35rem;
}
.step-head h1 { margin: 0; }

.step-of {
  font-family: var(--mono);
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  border-top: 2px solid var(--accent-2);
  border-bottom: 2px solid var(--accent-2);
  padding: 0.35rem 0;
  margin: 0 0 1.6rem;
}

/* ---------- lists with the bollard bullet ---------- */

ul.bollard, ul.checklist {
  list-style: none;
  margin: 0 0 1.2rem;
  padding: 0;
}
ul.bollard > li, ul.checklist > li {
  position: relative;
  padding-left: 1.6rem;
  margin-bottom: 0.6rem;
}
ul.bollard > li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.48em;
  width: 13px;
  height: 13px;
  background-repeat: no-repeat;
  background-size: 13px 13px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M1.6 1.3h8.8v2.3H7.3v7.1H4.7V3.6H1.6z' fill='%23b23b2e'/%3E%3C/svg%3E");
}

ol { padding-left: 1.3rem; }
ol > li { margin-bottom: 0.6rem; }
ol.steps-outline { font-family: var(--body); }

.contents {
  border-top: 2px solid var(--text);
  border-bottom: 2px solid var(--text);
  padding: 0.9rem 0;
  margin: 1.4rem 0 2rem;
}
.contents p {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  margin: 0 0 0.5rem;
}
.contents ol { margin: 0; }
.contents li { margin-bottom: 0.25rem; }

/* ---------- checklist printed boxes ---------- */

ul.checklist > li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.33em;
  width: 14px;
  height: 14px;
  border: 2px solid var(--text);
  background: var(--card);
}

.checklist-block {
  background: var(--card);
  border: 2px solid var(--text);
  padding: 1.2rem 1.3rem;
  margin: 1.8rem 0;
}
.checklist-block h2, .checklist-block h3 { margin-top: 0; }

/* ---------- disclosure box ---------- */

.disclosure {
  background: var(--card);
  border: 2px solid var(--accent);
  border-left-width: 10px;
  padding: 1.1rem 1.2rem;
  margin: 1.8rem 0;
  font-size: 1rem;
}
.disclosure p:last-child { margin-bottom: 0; }
.disclosure .berth { border-bottom-color: var(--accent); }

.link-note {
  font-family: var(--mono);
  font-size: 0.82rem;
  line-height: 1.5;
  border-left: 2px solid var(--accent-2);
  padding-left: 0.8rem;
  margin: 0.4rem 0 1.2rem;
}

/* ---------- callout ---------- */

.callout {
  border-top: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  padding: 1rem 0;
  margin: 1.7rem 0;
}
.callout h3 { margin-top: 0; }
.callout p:last-child { margin-bottom: 0; }

/* ---------- summary strip ---------- */

.before-you-move-on {
  background: var(--card);
  border: 2px solid var(--text);
  padding: 1.1rem 1.2rem;
  margin: 2rem 0;
}
.before-you-move-on h3 { margin-top: 0; }

/* ---------- tables ---------- */

.table-wrap { overflow-x: auto; margin: 1.4rem 0; }
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}
caption {
  text-align: left;
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding-bottom: 0.5rem;
}
th, td {
  text-align: left;
  padding: 0.55rem 0.6rem;
  border-bottom: 1px solid var(--accent-2);
  vertical-align: top;
}
thead th { border-bottom: 2px solid var(--text); }

/* ---------- glossary strip ---------- */

dl.glossary { margin: 1.4rem 0; }
dl.glossary dt {
  font-family: var(--mono);
  font-size: 0.86rem;
  letter-spacing: 0.04em;
  border-top: 1px solid var(--accent-2);
  padding-top: 0.6rem;
  margin-top: 0.6rem;
  font-weight: 700;
}
dl.glossary dd { margin: 0.25rem 0 0; }

/* ---------- pros and cons ---------- */

.weighing { margin: 1.5rem 0; }
.weighing h3 { margin-top: 1.2rem; }

/* ---------- pager ---------- */

.pager {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  border-top: 2px solid var(--text);
  margin-top: 2.4rem;
  padding-top: 1rem;
  font-family: var(--mono);
  font-size: 0.85rem;
}

.print-button {
  font-family: var(--mono);
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  background: var(--accent);
  color: #ffffff;
  border: 2px solid var(--accent);
  border-radius: 0;
  padding: 0.55rem 0.9rem;
  cursor: pointer;
}

/* ---------- tide note + footer ---------- */

.tide-note {
  border-top: 2px solid var(--accent);
  margin-top: 3rem;
  padding: 0.8rem 0 0;
  font-family: var(--mono);
  font-size: 0.76rem;
  line-height: 1.6;
}
.tide-note b {
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.site-footer {
  border-top: 2px solid var(--text);
  margin-top: 1.6rem;
  padding: 1.6rem 0 3rem;
  font-size: 0.9rem;
}
.site-footer .publisher {
  font-style: normal;
  margin-bottom: 0.9rem;
}
.site-footer .publisher span { display: block; }
.site-footer .publisher .name { font-family: var(--display); font-size: 1.05rem; }
.site-footer .footer-links { margin-bottom: 0.9rem; }
.site-footer .trademark { margin-bottom: 0.9rem; }
.site-footer .reviewed {
  font-family: var(--mono);
  font-size: 0.78rem;
  margin: 0;
}

/* ---------- small screens ---------- */

@media (max-width: 620px) {
  .menu-button { display: inline-block; }
  .site-nav {
    display: none;
    width: 100%;
    order: 3;
  }
  .site-nav.is-open { display: block; }
  .site-nav ul {
    flex-direction: column;
    gap: 0.1rem;
    border-top: 2px solid var(--text);
    margin-top: 0.7rem;
    padding-top: 0.7rem;
  }
  .site-nav a { display: block; padding: 0.45rem 0; }
  .masthead-inner { flex-wrap: wrap; }
  h1 { font-size: 1.72rem; }
  .step-head { flex-direction: column; gap: 0.7rem; }
  .ticket { padding-left: 2.4rem; }
}

/* ---------- print ---------- */

@media print {
  body {
    background: #ffffff;
    color: #000000;
    font-size: 12pt;
  }
  .masthead, .site-nav, .menu-button, .print-button, .pager, .skip, .no-print { display: none !important; }
  .column { max-width: none; padding: 0; }
  .ticket, .checklist-block, .disclosure, .before-you-move-on {
    background: #ffffff;
    border: 1pt solid #000000;
    page-break-inside: avoid;
  }
  .ticket::before { display: none; }
  .stub { background: #ffffff; color: #000000; border: 1pt solid #000000; }
  ul.checklist > li::before { border-color: #000000; background: #ffffff; }
  a { color: #000000; text-decoration: none; }
  a[href^="http"]::after { content: " (" attr(href) ")"; font-size: 9pt; }
  .tide-note, .site-footer { border-color: #000000; }
  h2, h3 { page-break-after: avoid; }
}
