/* natecordero.com. Drawn like a USGS quadrangle: black ink, brown contours, green woodland,
   blue water, red for the surveyed line. Overpass is the open cousin of the US highway-sign
   alphabet; Source Serif does the reading text. Both are served from this site. */

@font-face { font-family: "Overpass"; src: url("/fonts/overpass-latin-wght-normal.woff2") format("woff2");
             font-weight: 100 900; font-display: swap; }
@font-face { font-family: "Source Serif 4"; src: url("/fonts/source-serif-4-latin-wght-normal.woff2") format("woff2");
             font-weight: 200 900; font-display: swap; }
@font-face { font-family: "Source Serif 4"; src: url("/fonts/source-serif-4-latin-wght-italic.woff2") format("woff2");
             font-weight: 200 900; font-style: italic; font-display: swap; }

:root {
  --paper: #ffffff; --ink: #000000; --grey: #5a5a52;
  --wood: #d3e6bd; --contour: #a9703c; --water: #1c66a8; --survey: #d0202e; --revised: #7b3f98;
  --sign: "Overpass", "Highway Gothic", "Arial Narrow", Arial, sans-serif;
  --text: "Source Serif 4", "Iowan Old Style", Georgia, serif;
  --sheet: 1240px; --gutter: 28px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 19px/1.62 var(--text); }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--water); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:visited { color: var(--revised); }
a:hover { text-decoration-thickness: 2px; }
a:focus-visible { outline: 3px solid var(--survey); outline-offset: 3px; }
h1, h2 { font-family: var(--sign); font-weight: 800; letter-spacing: -0.022em; margin: 0; }
p { margin: 0 0 1em; }

.top, main, .collar-foot { max-width: var(--sheet); margin: 0 auto; padding: 0 var(--gutter); }

/* Top margin of the sheet */
.top { display: flex; justify-content: space-between; align-items: baseline; gap: 20px; padding-top: 22px; padding-bottom: 16px;
       font: 600 16px/1.2 var(--sign); }
.brand { font-weight: 800; font-size: 19px; color: var(--ink); text-decoration: none; letter-spacing: -0.01em; }
.brand:visited { color: var(--ink); }
.top nav { display: flex; gap: 26px; }
.top nav a, .top nav a:visited { color: var(--ink); text-decoration: none; }
.top nav a:hover { text-decoration: underline; text-decoration-thickness: 2px; }

/* The map */
.neatline { position: relative; border: 2.5px solid var(--ink); aspect-ratio: 2 / 1; overflow: hidden; background: var(--wood); }
.quad { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.quad .wood { fill: var(--wood); }
.quad .clear { fill: var(--paper); }
.quad .contour { fill: none; stroke: var(--contour); stroke-width: 1; opacity: 0.72; }
.quad .contour.index { stroke-width: 2.3; opacity: 0.92; }
.quad .elev { font: 500 17px var(--sign); fill: #7d4e22; text-anchor: middle; paint-order: stroke; stroke: var(--wood); stroke-width: 6px; }
.quad .water { fill: none; stroke: var(--water); stroke-width: 2.2; stroke-linecap: round; }
.quad .water.main { stroke-width: 3.4; }
.quad .hydro { font: italic 500 27px var(--text); fill: var(--water); letter-spacing: 0.06em; }
.quad .road-case { fill: none; stroke: var(--ink); stroke-width: 7; stroke-dasharray: 14 7; }
.quad .road-fill { fill: none; stroke: var(--paper); stroke-width: 3.4; }
.quad .radio { fill: none; stroke: var(--survey); stroke-width: 4.5; stroke-linecap: round; }
.quad .radio-label { font: 700 23px var(--sign); fill: var(--survey); paint-order: stroke; stroke: var(--paper); stroke-width: 6px;
                     stroke-linejoin: round; }
.quad .bldg { fill: var(--ink); }
.quad .feature { font: 700 21px var(--sign); fill: var(--ink); paint-order: stroke; stroke: var(--paper); stroke-width: 5px;
                 stroke-linejoin: round; }
.quad .spot { font-weight: 500; font-size: 19px; }
.quad .tower-mark circle { fill: var(--paper); stroke: var(--ink); stroke-width: 2.6; }
.quad .tower-mark .dot { fill: var(--ink); stroke: none; }
.quad .knob { font: italic 400 30px var(--text); letter-spacing: 0.22em; fill: var(--ink); }

/* One moment of motion: the line is surveyed from the house to the tower when the page opens. */
@media (prefers-reduced-motion: no-preference) {
  .quad .radio { stroke-dasharray: 1; stroke-dashoffset: 1; animation: survey 1.5s cubic-bezier(0.6, 0, 0.2, 1) 0.5s forwards; }
  .quad .radio-label { opacity: 0; animation: appear 0.5s ease 1.9s forwards; }
  @keyframes survey { to { stroke-dashoffset: 0; } }
  @keyframes appear { to { opacity: 1; } }
}

/* The legend is the way around the site */
.legend { position: absolute; right: 18px; bottom: 18px; background: var(--paper); border: 1.5px solid var(--ink);
          padding: 12px 16px 8px; font: 500 15px/1.3 var(--sign); width: 300px; }
.legend-title { font-weight: 800; margin: 0 0 6px; }
.legend a { display: grid; grid-template-columns: 44px 1fr; gap: 12px; align-items: center; padding: 7px 0; color: var(--ink);
            text-decoration: none; border-top: 1px solid #cfcfc8; }
.legend a:visited { color: var(--ink); }
.legend svg { width: 44px; height: 16px; }
.legend b { display: block; font-weight: 500; color: var(--grey); font-size: 13px; }
.legend a:hover span { text-decoration: underline; text-decoration-thickness: 2px; }

/* The collar: title block under the map */
.collar { display: grid; grid-template-columns: 1fr auto; gap: 40px; align-items: start; padding-top: 22px; }
.collar h1 { font-size: clamp(38px, 6.1vw, 86px); line-height: 0.98; max-width: 13em; text-wrap: balance; }
.collar-data { display: flex; gap: 26px; align-items: flex-end; font: 500 13px/1.3 var(--sign); padding-top: 8px; }
.declination { width: 62px; height: 85px; }
.declination line { stroke: var(--ink); stroke-width: 1.4; }
.declination .solid { fill: var(--ink); }
.declination text { font: 600 11px var(--sign); }
.scale { width: calc((min(100vw, var(--sheet)) - 2 * var(--gutter)) * 0.239); }   /* one mile at the map's scale */
.scale-bar { display: grid; grid-template-columns: repeat(4, 1fr); border: 1.5px solid var(--ink); height: 9px; }
.scale-bar i:nth-child(odd) { background: var(--ink); }
.scale-ends { display: flex; justify-content: space-between; margin-top: 3px; }
.scale p { margin: 6px 0 0; color: var(--grey); }

.intro { max-width: 33em; margin: 34px 0 0; font-size: clamp(20px, 2vw, 24px); line-height: 1.5; }

/* Sections */
.part { margin-top: 112px; }
.part h2 { font-size: clamp(32px, 4.2vw, 56px); line-height: 1; padding-top: 18px; border-top: 2.5px solid var(--ink); margin-bottom: 30px; }
.cut { margin: 0 0 30px; }
.profile { width: 100%; height: auto; display: block; }
.profile .grid { stroke: #dcdcd4; stroke-width: 1; }
.profile .axis { font: 500 14px var(--sign); fill: var(--grey); }
.profile .trees { fill: #b9d79d; }
.profile .ground { fill: #efe3cf; }
.profile .ground-line { fill: none; stroke: var(--contour); stroke-width: 2.2; }
.profile .zone { fill: none; stroke: var(--survey); stroke-width: 1.4; stroke-dasharray: 6 5; }
.profile .ray { stroke: var(--survey); stroke-width: 3.2; stroke-linecap: round; }
.profile .mast { stroke: var(--ink); stroke-width: 3; }
.profile .note { font: 700 15px var(--sign); fill: var(--ink); }
figcaption { font: 500 14px/1.4 var(--sign); color: var(--grey); margin-top: 8px; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; }
.two p { max-width: 31em; }
.two strong { font-family: var(--sign); font-weight: 800; }
.button, .button:visited { display: inline-block; font: 700 17px/1 var(--sign); color: var(--paper); background: var(--survey);
          padding: 15px 22px 13px; text-decoration: none; margin-top: 6px; }
.button:hover { background: var(--ink); }

/* Trip reports */
.trips { list-style: none; margin: 0; padding: 0; }
.trips a { display: grid; grid-template-columns: auto 1fr auto; gap: 26px; align-items: center; padding: 20px 0; color: var(--ink);
           text-decoration: none; border-bottom: 1px solid var(--ink); }
.trips a:visited { color: var(--ink); }
.trips img { width: 150px; height: 100px; object-fit: cover; }
.trip-text { display: block; grid-column: 2; }
.trip-title { display: block; font: 800 clamp(22px, 2.4vw, 30px)/1.12 var(--sign); letter-spacing: -0.015em; }
.trips a:hover .trip-title { text-decoration: underline; text-decoration-thickness: 3px; text-decoration-color: var(--survey); }
.trip-summary { display: block; color: var(--grey); margin-top: 5px; max-width: 38em; }
.trips time, .dateline { font: 500 15px var(--sign); color: var(--grey); font-variant-numeric: tabular-nums; }
.empty { color: var(--grey); font-style: italic; }
.more { font: 600 17px var(--sign); margin-top: 22px; }
.draft { font: 700 13px var(--sign); color: var(--revised); font-style: normal; border: 1.5px solid var(--revised); padding: 1px 6px;
         vertical-align: middle; }

/* Reading pages */
.page-head { padding: 56px 0 30px; }
.page-head h1, .report h1 { font-size: clamp(38px, 5.4vw, 72px); line-height: 1; text-wrap: balance; }
.page-head p { color: var(--grey); margin-top: 14px; font-size: 21px; }
.report { max-width: 720px; padding: 48px 0 24px; }
.back { font: 600 15px var(--sign); margin-bottom: 22px; }
.dateline { margin-top: 14px; }
.cover { width: 100%; max-height: 72vh; object-fit: cover; margin: 28px 0 0; }
.prose { margin-top: 30px; font-size: 20px; line-height: 1.68; }
.prose h2 { font-size: 30px; margin: 46px 0 10px; }
.prose h3 { font: 800 22px var(--sign); margin: 32px 0 6px; }
.prose img { margin: 30px auto 8px; max-height: 88vh; width: auto; }
.prose blockquote { margin: 26px 0; padding-left: 20px; border-left: 4px solid var(--contour); font-style: italic; }
.prose code { font-size: 0.86em; background: #f1f1ec; padding: 2px 5px; }
.prose hr { border: 0; border-top: 1px solid var(--ink); margin: 42px 0; }
.prose ul, .prose ol { padding-left: 1.2em; }
.prose li { margin-bottom: 0.35em; }

/* Bottom margin of the sheet */
.collar-foot { margin-top: 120px; padding-bottom: 44px; font-family: var(--sign); }
.collar-foot::before { content: ""; display: block; border-top: 2.5px solid var(--ink); margin-bottom: 18px; }
.foot-name { font-weight: 800; font-size: 26px; letter-spacing: -0.02em; margin: 0 0 4px; }
.foot-links { display: flex; gap: 22px; margin: 0 0 14px; font-weight: 600; font-size: 16px; }
.foot-note { font-size: 13px; color: var(--grey); margin: 0; }

@media (max-width: 860px) {
  :root { --gutter: 16px; }
  body { font-size: 18px; }
  .top { padding-top: 14px; padding-bottom: 12px; font-size: 15px; flex-wrap: wrap; }
  .top nav { gap: 16px; }
  .neatline { aspect-ratio: auto; overflow: visible; background: none; border: 0; }
  .quad { position: static; aspect-ratio: 5 / 4; border: 2.5px solid var(--ink); }
  .legend { position: static; width: auto; border-top: 0; }
  .quad .feature { font-size: 34px; }
  .quad .spot, .quad .elev { display: none; }
  .quad .radio-label { font-size: 36px; }
  .quad .hydro { font-size: 38px; }
  .quad .knob { font-size: 40px; letter-spacing: 0.12em; }
  .quad .radio { stroke-width: 7; }
  .collar { grid-template-columns: 1fr; gap: 14px; }
  .collar-data { display: none; }
  .part { margin-top: 76px; }
  .two { grid-template-columns: 1fr; gap: 8px; }
  .cut { padding-left: 30px; }
  .profile { overflow: visible; }
  .profile .axis { font-size: 30px; }
  .profile .note { font-size: 30px; }
  .profile .grid ~ .axis:nth-of-type(even) { display: none; }
  .trips a { grid-template-columns: 1fr; gap: 10px; }
  .trip-text { grid-column: 1; }
  .trips img { width: 100%; height: 190px; }
  .collar-foot { margin-top: 80px; }
}
