/* Jesse J. Camacho, concept 4: TWO DOORS
   Locked palette, Literata only, radius 0, no shadows. */

:root {
  --ink:      #15171A;
  --navy:     #1E3A5F;
  --navy-deep:#16304E;
  --band:     #F6F6F4;
  --hairline: #E4E5E2;
  --white:    #FFFFFF;

  --measure: 66ch;
  --gutter: 3.25rem;
}

*, *::before, *::after { box-sizing: border-box; }

html {
  font-size: 118.75%; /* 19px at a 16px default, and still scales with the reader's setting */
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--white);
  color: var(--ink);
  font-family: "Literata", Georgia, "Century Schoolbook", serif;
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.62;
  overflow-wrap: break-word;
}

/* ---------- links ---------- */

a {
  color: var(--navy);
  text-decoration: underline;
  text-underline-offset: 0.18em;
  text-decoration-thickness: 1px;
  transition: color 180ms ease;
}
a:hover { color: var(--navy-deep); text-decoration-thickness: 2px; }

a:focus-visible,
:focus-visible {
  outline: 3px solid var(--navy);
  outline-offset: 3px;
}

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--navy);
  color: var(--white);
  padding: 0.9rem 1.4rem;
  min-height: 44px;
  z-index: 50;
  text-decoration: underline;
}
.skip:focus {
  left: 0;
  outline: 3px solid var(--ink);
  outline-offset: 0;
  color: var(--white);
}

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

.wrap {
  max-width: 1260px;
  margin: 0 auto;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}
.wrap.narrow { max-width: 46rem; }

/* ---------- masthead: the one introduction, above the split ---------- */

.masthead {
  padding-top: 4.25rem;
  padding-bottom: 3.5rem;
}

.masthead-in {
  display: grid;
  grid-template-columns: 7fr 4fr;
  column-gap: var(--gutter);
  align-items: end;
}

.eyebrow {
  margin: 0 0 1.1rem;
  font-size: 0.9rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--navy);
}

h1 {
  font-size: 2.3rem;
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.025em;
  margin: 0 0 0.7rem;
}

.tagline {
  margin: 0 0 1.6rem;
  font-size: 1.25rem;
  line-height: 1.35;
  color: var(--navy);
}

.masthead-p {
  margin: 0;
  max-width: 62ch;
}

.masthead-portrait img {
  display: block;
  width: 100%;
  max-width: 360px;
  height: auto;
  margin-left: auto;
  border-bottom: 3px solid var(--navy);
}

/* ---------- the pivot into the split ---------- */

.opening {
  padding-top: 0;
  padding-bottom: 2.75rem;
}

.opening h2 { max-width: 24ch; }

.lede {
  margin: 0;
  max-width: var(--measure);
}

.doors {
  margin-top: 2.6rem;
  max-width: 46rem;
}
.doors ul { list-style: none; margin: 0; padding: 0; }
.doors li { border-top: 1px solid var(--hairline); }
.doors li:last-child { border-bottom: 1px solid var(--hairline); }
.doors a {
  display: flex;
  align-items: center;
  min-height: 56px;
  padding: 0.85rem 0;
  font-size: 1.15rem;
}

/* ---------- the split ---------- */

.split { padding-bottom: 1rem; }

/* sticky column labels, decorative: the real labels live inside each side */
.rail {
  position: sticky;
  top: 0;
  z-index: 5;
  background: var(--white);
  border-top: 1px solid var(--hairline);
  border-bottom: 1px solid var(--hairline);
}
.rail-in {
  display: grid;
  grid-template-columns: 1fr 1fr;
}
.rail-a, .rail-b {
  display: block;
  padding: 0.7rem 0;
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--navy);
}
.rail-a { padding-right: var(--gutter); }
.rail-b { padding-left: var(--gutter); border-left: 1px solid var(--hairline); }

.grid {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  column-gap: 0;
  row-gap: 0;
}

.side { display: contents; }

/* the per-side label is carried in the DOM for assistive tech and for mobile;
   on desktop the sticky rail above shows it instead */
.sidelabel {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: 0;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.cell {
  padding-top: 2.6rem;
  padding-bottom: 2.9rem;
}
.col-a { grid-column: 1; padding-right: var(--gutter); }
.col-b { grid-column: 2; padding-left: var(--gutter); border-left: 1px solid var(--hairline); }

.r1 { grid-row: 1; }
.r2 { grid-row: 2; }
.r3 { grid-row: 3; }
.r4 { grid-row: 4; }
.r5 { grid-row: 5; }
.r6 { grid-row: 6; }
.r7 { grid-row: 7; }
.r8 { grid-row: 8; }

.cell:not(.r1) { border-top: 1px solid var(--hairline); }

.cell.r1 { padding-top: 2.2rem; }

/* ---------- headings and text inside the split ---------- */

h2 {
  font-size: 1.5rem;
  font-weight: 600;
  line-height: 1.22;
  margin: 0 0 0.9rem;
  scroll-margin-top: 5.5rem;
}

h3 {
  font-size: 1.15rem;
  font-weight: 600;
  line-height: 1.3;
  margin: 0 0 1rem;
  color: var(--navy);
}

p { margin: 0 0 1.15rem; }
p:last-child { margin-bottom: 0; }

.standfirst { color: var(--navy); }

.cell ul, .cell ol {
  margin: 0 0 1.15rem;
  padding-left: 1.35rem;
}
.cell li { margin-bottom: 0.9rem; }
.cell li:last-child { margin-bottom: 0; }
.cell li::marker { color: var(--navy); }

.cell .asks { list-style: none; padding-left: 0; }
.cell .asks li {
  border-left: 2px solid var(--navy);
  padding-left: 1rem;
  color: var(--navy);
  margin-bottom: 1rem;
}
.cell .asks li:last-child { margin-bottom: 0; }

strong { font-weight: 600; }

/* ---------- quotes ---------- */

.quotelabel {
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--navy);
  margin-bottom: 1.1rem;
}

blockquote {
  margin: 0 0 1.1rem;
  padding: 0;
}
blockquote p {
  font-size: 1.15rem;
  line-height: 1.5;
}

.attrib {
  font-size: 0.95rem;
  color: var(--ink);
  margin-bottom: 0;
}

/* ---------- shared band ---------- */

.shared {
  background: var(--band);
  border-top: 1px solid var(--hairline);
  border-bottom: 1px solid var(--hairline);
  padding: 4.5rem 0;
  margin-top: 1rem;
}
.shared h2 { margin-bottom: 1.6rem; }
blockquote.wide p { font-size: 1.15rem; }
.verify { margin-top: 1.9rem; font-size: 0.95rem; }
.verify a { min-height: 44px; display: inline-block; padding: 0.6rem 0; }

.small {
  font-size: 0.95rem;
  line-height: 1.65;
}

/* ---------- contact ---------- */

.contact {
  padding: 4rem 0;
  border-bottom: 1px solid var(--hairline);
}
.contact h2 { margin-bottom: 1rem; }
.contact p { max-width: var(--measure); }

.contact-list {
  list-style: none;
  margin: 2rem 0 1.4rem;
  padding: 0;
}
.contact-list li { border-top: 1px solid var(--hairline); }
.contact-list li:last-child { border-bottom: 1px solid var(--hairline); }
.contact-list a {
  display: flex;
  align-items: center;
  min-height: 52px;
  padding: 0.7rem 0;
}

/* ---------- site navigation: hairlines, like everything else ---------- */

.sitenav {
  border-bottom: 1px solid var(--hairline);
  background: var(--white);
}
.sitenav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
}
.sitenav li + li { border-left: 1px solid var(--hairline); }
.sitenav a {
  display: flex;
  align-items: center;
  min-height: 52px;
  padding: 0.55rem 0.78rem;
  font-size: 0.86rem;
  line-height: 1.3;
  color: var(--ink);
  text-decoration: none;
  border-bottom: 3px solid transparent;
}
.sitenav li:first-child a { padding-left: 0; }
.sitenav a:hover {
  color: var(--navy-deep);
  text-decoration: underline;
  text-underline-offset: 0.18em;
}
.sitenav a[aria-current="page"] {
  color: var(--navy);
  font-weight: 600;
  border-bottom-color: var(--navy);
}

/* ---------- compact banner for the interior pages ---------- */

.banner {
  padding: 2.9rem 0 2.1rem;
  border-bottom: 1px solid var(--hairline);
}
.banner h1 {
  max-width: 22ch;
  margin-bottom: 0.7rem;
}
.banner-line {
  margin: 0;
  max-width: 58ch;
  font-size: 1.1rem;
  line-height: 1.45;
  color: var(--navy);
}

/* ---------- the spine: heading in the margin, a vertical hairline, body ---------- */

.row {
  display: grid;
  grid-template-columns: 16rem minmax(0, 1fr);
  border-top: 1px solid var(--hairline);
}
.row:first-of-type { border-top: 0; }

.row-label {
  padding: 2.4rem var(--gutter) 2.7rem 0;
}
.row-label h2 {
  font-size: 1.3rem;
  margin: 0 0 0.5rem;
}
.row-label > :last-child { margin-bottom: 0; }

.rowmark {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.5;
  color: var(--navy);
}

.row-body {
  padding: 2.4rem 0 2.7rem var(--gutter);
  border-left: 1px solid var(--hairline);
}
.row-body > :last-child { margin-bottom: 0; }
.row-body p { max-width: var(--measure); }

.row-body ul, .row-body ol {
  margin: 0 0 1.15rem;
  padding-left: 1.2rem;
  max-width: var(--measure);
}
.row-body li { margin-bottom: 0.9rem; }
.row-body li:last-child { margin-bottom: 0; }
.row-body li::marker { color: var(--navy); }
.row-body h3 { margin-top: 1.8rem; }
.row-body > h3:first-child { margin-top: 0; }

.row-body .contact-list { padding-left: 0; margin: 1.5rem 0; max-width: var(--measure); }
.row-body .contact-list li { margin-bottom: 0; }

.row-body blockquote p { max-width: var(--measure); }

/* a quoted voice inside a spine row, marked the way the question lists are */
.row-body blockquote.pull {
  border-left: 2px solid var(--navy);
  padding-left: 1.15rem;
  margin: 1.7rem 0 0.9rem;
}
.row-body blockquote.pull p { color: var(--navy); }

.rows { padding: 1rem 0 2.5rem; }

/* ---------- a photograph that does not exist yet ---------- */

.place {
  background: var(--band);
  border: 1px dashed var(--navy);
  padding: 1.5rem 1.4rem;
  margin: 1.6rem 0 0;
  max-width: var(--measure);
}
.place p {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--navy);
}

/* ---------- the legal block ---------- */

.notice {
  background: var(--band);
  border-top: 1px solid var(--hairline);
  border-bottom: 1px solid var(--hairline);
  padding: 3rem 0;
}
.notice h2 { margin-bottom: 1.1rem; }
.notice p { max-width: var(--measure); }

/* ---------- footer ---------- */

footer {
  border-top: 1px solid var(--hairline);
  padding: 2.6rem 0 4rem;
}
footer .small { margin-bottom: 0.9rem; max-width: var(--measure); }
footer .small:last-child { margin-bottom: 0; }

.footer-routes {
  list-style: none;
  margin: 0 0 1.7rem;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  column-gap: 2.2rem;
}
.footer-routes a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-size: 0.95rem;
}

/* ---------- larger screens ---------- */

@media (min-width: 1100px) {
  html { font-size: 125%; } /* 20px */
  h1 { font-size: 2.2rem; } /* 44px */
}

/* ---------- phone and small tablet: one side fully, then the other ---------- */

@media (max-width: 900px) {
  :root { --gutter: 0rem; }

  .rail { display: none; }

  .grid { display: block; position: static; }
  .side { display: block; }

  .sidelabel {
    position: sticky;
    top: 0;
    z-index: 5;
    width: auto;
    height: auto;
    overflow: visible;
    clip-path: none;
    white-space: normal;
    background: var(--white);
    border-top: 1px solid var(--hairline);
    border-bottom: 1px solid var(--hairline);
    padding: 0.75rem 0;
    margin: 0;
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--navy);
  }

  /* no gap between the two labels, so one hands over to the other cleanly
     and the reader never sees both at once */
  .side-a .cell:last-child { padding-bottom: 3.75rem; }

  .cell {
    padding-top: 2.1rem;
    padding-bottom: 2.3rem;
    padding-left: 0;
    padding-right: 0;
    border-left: 0;
  }
  .cell.r1 { padding-top: 2.1rem; }
  .cell:not(.r1) { border-top: 1px solid var(--hairline); }

  h2 { scroll-margin-top: 4rem; }

  .masthead {
    padding-top: 2.75rem;
    padding-bottom: 2.75rem;
  }
  .masthead-in {
    grid-template-columns: 1fr;
    row-gap: 2rem;
  }
  .masthead-portrait { grid-row: 1; }
  .masthead-text { grid-row: 2; }
  .masthead-portrait img {
    width: 70%;
    max-width: 280px;
    margin-left: 0;
  }

  h1 { font-size: 2rem; }
  .opening { padding-top: 0; }
  .doors { margin-top: 2.2rem; }
  .shared { padding: 3.25rem 0; }
  .contact { padding: 3.25rem 0; }

  /* navigation wraps rather than stacking, so it never buries the page.
     dividers come off so every wrapped row still starts on the same left edge */
  .sitenav li + li { border-left: 0; }
  .sitenav a,
  .sitenav li:first-child a {
    padding: 0.4rem 1.3rem 0.4rem 0;
    min-height: 48px;
    font-size: 0.88rem;
  }

  .banner { padding: 2rem 0 1.6rem; }
  .banner h1 { font-size: 1.75rem; }
  .banner-line { font-size: 1.05rem; }

  .row { display: block; }
  .row-label { padding: 1.9rem 0 0.85rem; }
  .row-body { padding: 0 0 2.2rem; border-left: 0; }
  .rows { padding: 0 0 1.5rem; }
  .notice { padding: 2.4rem 0; }

  .footer-routes { display: block; }
  .footer-routes a { min-height: 48px; }
}

/* ---------- motion ---------- */

/* nothing that contains the sticky rail is animated with a transform,
   so sticky positioning is never re-parented */
@media (prefers-reduced-motion: no-preference) {
  .masthead, .opening, .banner, .shared, .contact {
    animation: rise 420ms ease-out both;
  }
  .opening { animation-delay: 90ms; }
}

@keyframes rise {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}
