:root {
  /* colors */
  --color-red: IndianRed;
  --color-yellow: Moccasin;
  --color-pink: #FFAABB; --color-pink-hover: #FFBBAA;
  --color-orange: Coral;
  --color-purple: SlateBlue;
  --color-green: #BBFFAA; --color-green-hover: #AAFFBB;
  --color-blue: #AABBFF; --color-blue-hover: #BBAAFF;
  --color-brown: RosyBrown;
  --color-white: WhiteSmoke;
  --color-gray1: Gainsboro;
  --color-gray2: DarkGray;
  --color-gray3: DimGray;
  --color-gray4: rgb(41, 37, 36);
  --color-gray5: #0E0C0C;
  --color-black: black;
  --color-border-major: white;
  --color-border-minor: white;
  --color-primary: var(--color-blue);
  --color-primary-hover: var(--color-blue-hover);
  --color-secondary: var(--color-green);
  --color-secondary-hover: var(--color-green-hover);
  --color-tertiary: var(--color-pink);
  --color-text-dark: var(--color-gray5);
  --color-text-light: var(--color-white);
  /* sizes */
  --size--1: clamp(0.825rem, 0.787rem + 0.203vw, 1rem);
  --size-0: clamp(1rem, 0.882rem + 0.588vw, 1.5rem);
  --size-0: clamp(1rem, 0.882rem + 0.588vw, 1.5rem);
  --size-1: clamp(1.25rem, 1.074rem + 0.882vw, 2rem);
  --size-2: clamp(1.5rem, 1.324rem + 0.882vw, 2.25rem);
  --size-3: clamp(1.75rem, 1.574rem + 0.882vw, 2.5rem);
  --size-4: clamp(2rem, 1.824rem + 0.882vw, 2.75rem);
  --size-5: clamp(2.25rem, 2.074rem + 0.882vw, 3rem);
  --size-6: clamp(2.5rem, 2.324rem + 0.882vw, 3.25rem);
  --size-7: clamp(2.75rem, 2.574rem + 0.882vw, 3.5rem);
  --size-8: clamp(3rem, 2.824rem + 0.882vw, 3.75rem);
  --size-9: clamp(3.25rem, 3.074rem + 0.882vw, 4rem);
  --size-sm: 14px;
  /* fonts */
  --font-family-serif: "Times", "Times New Roman", "Georgia", serif;
  --font-family-sans-serif: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
  --font-family-heavy: sans-serif;
  --font-hero-heading-size: clamp(2rem, 1.059rem + 4.706vw, 6rem);
  --font-title-heading-size: clamp(1.8rem, 1.282rem + 2.588vw, 4rem);
  --font-title-heading-entries-size: calc(var(--size-1) * 0.8);
  --font-body-size: clamp(1rem, 0.882rem + 0.588vw, 1.5rem);
  --kerning-tight: -1px;
  --kerning-normal: 0;
  --kerning-loose: 1px;
  /* borders */
  --border-size-xl: 10px;
  --border-size-lg: 8px;
  --border-size-md: 4px;
  --border-size-sm: 1px;
  /* containers */
  --container-max-width: 1680px;
  --content-max-width: 75ch;
}

/* *****************************************
 * begin reset
 * */
/* Box sizing rules */
*,
*::before,
*::after {
  box-sizing: border-box;
}

/* Prevent font size inflation */
html {
  -moz-text-size-adjust: none;
  -webkit-text-size-adjust: none;
  text-size-adjust: none;
}

/* Remove default margin in favour of better control in authored CSS */
body, h1, h2, h3, h4, p,
figure, blockquote, dl, dd {
  margin-block-end: 0;
}

/* Remove list styles on ul, ol elements with a list role, which suggests default styling will be removed */
ul[role='list'],
ol[role='list'] {
  list-style: none;
}

/* Set core body defaults */
body {
  min-height: 100vh;
  line-height: 1.5;
}

/* Set shorter line heights on headings and interactive elements */
h1, h2, h3, h4,
button, input, label {
  line-height: 1.1;
}

/* Balance text wrapping on headings */
h1, h2,
h3, h4 {
  text-wrap: balance;
}

/* A elements that don't have a class get default styles */
/*
a:not([class]) {
  text-decoration-skip-ink: auto;
  color: currentColor;
}
*/

/* Make images easier to work with */
img,
picture {
  max-width: 100%;
  display: block;
}

/* Inherit fonts for inputs and buttons */
input, button,
textarea, select {
  font-family: inherit;
  font-size: inherit;
}

/* Make sure textareas without a rows attribute are not tiny */
textarea:not([rows]) {
  min-height: 10em;
}

/* Anything that has been anchored to should have extra scroll margin */
:target {
  scroll-margin-block: 5ex;
}
/* ...end reset */

/* *****************************************
 * Colors: https://htmlcolorcodes.com
 * */
.bg-red { background-color: var(--color-red); }
.bg-yellow { background-color: var(--color-yellow); }
.bg-pink { background-color: var(--color-pink); }
.bg-orange { background-color: var(--color-orange); }
.bg-purple { background-color: var(--color-purple); }
.bg-green { background-color: var(--color-green); }
.bg-blue { background-color: var(--color-blue); }
.bg-brown { background-color: var(--color-brown); }
.bg-white { background-color: var(--color-white); }
.bg-gray1 { background-color: var(--color-gray1); }
.bg-gray2 { background-color: var(--color-gray2); }
.bg-gray3 { background-color: var(--color-gray3); }
.bg-gray4 { background-color: var(--color-gray4); }
.bg-gray5 { background-color: var(--color-gray5); }
.bg-black { background-color: var(--color-black); }
.bg-primary { background-color: var(--color-primary); }
.bg-secondary { background-color: var(--color-secondary); }
.bg-tertiary { background-color: var(--color-tertiary); }

body {
  background-color: var(--color-text-dark);
  color: var(--color-text-light);
}

.color-swatches {
  display: flex;
  flex-direction: row;
  width: 200px;
}
.color-swatches .color {
  flex-basis: 20px;
  height: 20px;
}


/* *****************************************
 * Fonts
 * */

body {
  font-family: var(--font-family-sans-serif);
  font-size: var(--font-body-size);
}

a {
  color: var(--color-pink);
  text-decoration: none;
}
a:hover,
a:visited:hover,
a:active {
  color: var(--color-secondary);
  text-decoration: underline;
}
a:visited {color: var(--color-primary);}
p a {
  color: var(--color-primary);
  text-decoration: none;
  border-bottom: 1px solid var(--color-primary);
}
p a:hover,
p a:visited:hover,
p a:active {
  color: var(--color-secondary);
  text-decoration: none;
  border-bottom: 1px solid var(--color-secondary);
}

h1,
h2,
h3,
h4,
h5 {
  font-family: var(--font-family-serif);
}
h1 { font-size: var(--size-6); }
h2 { font-size: var(--size-5); }
h3 { font-size: var(--size-4); }
h4 { font-size: var(--size-3); }
h5 { font-size: var(--size-2); }
h6 { font-size: var(--size-1); }

.title-hero h1, .title-section h1 {
  font-size: var(--font-hero-heading-size);
  font-family: var(--font-family-heavy);
  font-weight: 900;
  text-transform: uppercase;
}
.title-hero mark { background-color: transparent; }
.title-hero h2, .title-section h2 { font-size: var(--size-9); }
.title-hero h3, .title-section h3 { font-size: var(--size-8); }

.title-page h1 { font-size: var(--font-title-heading-size); }
.title-page h2 { font-size: var(--size-8); }
.title-page h3 { font-size: var(--size-7); }
.title-page time,
.title-page mark {
  background-color: transparent;
  font-size: var(--size--1);
  color: var(--color-gray2);
}

.logo-tagline {
  font-family: var(--font-family-serif);
}
.logo {
  font-size: var(--size-6);
  letter-spacing: var(--kerning-tight);
  font-weight: 900;
}
.logo a { color: var(--color-white); text-decoration: none }
.tagline {
  font-family: var(--font-family-sans-serif);
  font-size: var(--size--1);
  letter-spacing: var(--kerning-normal);
  color: var(--color-gray2);
  text-transform: smallcaps;
  border-top: var(--border-size-sm) solid var(--color-gray2);
}

.content-leader {
    font-size: var(--font-hero-heading-size);
    margin: 0 0.75rem 0.75rem 0;
    background-color: var(--color-secondary);
    float: left;
}


/* *****************************************
 * Utilities
 * */
:root {
  --wrapper-max-width: 1680px;
  --gutter: clamp(1rem, 1rem + 1.5vi, 1.5rem);
}

.major-section-background {
  background-color: var(--color-gray5);
}

/* *****************************************
 * Layout:
 */
body {margin: 0; padding: 0;}
.wrapper {
  display: grid;
  grid-template-columns: auto;
  grid-template-rows: auto auto 1fr auto;
  grid-template-areas:
    "logo logo"
    "nav nav"
    "content content"
    "footer footer";
  min-height: 100vh;
  gap: var(--size-0);
  margin-inline: auto;
  max-width: var(--wrapper-max-width);
  padding-inline: var(--size-2);
  position: relative;
}

.logo-tagline {
  grid-area: logo;
  align-content: center;
  padding: var(--size-3) var(--size-3) 0 var(--size-3);
}
.logo,
.tagline {
    max-width: max-content;
    text-align: center;
}
.logo {
    line-height: 1;
}
.tagline {
  display: block;
}
.nav {
  grid-area: nav;
  text-align: center;
  display: flex;
  flex-direction: row;
  gap: var(--size-0);
  padding: var(--size-0);
}
.nav a {
    width: 100%;
    padding: 5px 10px;
    /*background-color: var(--color-gray2);*/
    /*color: var(--color-black);*/
    border-bottom: 1px solid var(--color-primary);
    text-align: center;
    text-decoration: none;
    margin: 2px 0;
}
.nav a:hover {
    background-color: var(--color-primary);
    color: var(--color-black);
}
.nav a.active {
  background-color: var(--color-secondary);
  color: var(--color-black);
}

main {
    grid-area: content;
}

footer.bottom {
  padding: var(--size-3);
  grid-area: footer;
  padding: 1rem;
  margin-top: var(--size-5);
  display: flex;
  gap: 1rem;
  flex-direction: column;
  font-size: 14px;
  border-top: var(--border-size-sm) solid var(--color-primary);
  justify-content: space-between;
}

/* *****************************************
 * Layout: Nav
 * */

/* Layout: Titles and Heros */
.title-hero,
.title-section,
.title-page {
    display: block;
}

.title-hero {
    /*background-color: var(--color-primary);*/
    color: var(--color-text-dark);
    display: flex;
    flex-direction: column;
}
.title-hero h1 {
  background-color: var(--color-primary);
  padding: var(--size--1);
  margin-top: 0;
  order: 0;
  box-shadow: -2px -2px var(--color-secondary);
  text-shadow: 2px 2px var(--color-secondary);
}
.title-hero a {
  background-color: var(--color-gray5);
  padding: 0 2px;
}
.title-hero a:hero,
.title-hero a:visited,
.title-hero a:active {
  color: var(--color-secondary);
}
.title-hero p {
  text-align: left;
  margin-top: 0;
  border-right: var(--border-size-sm) solid var(--color-gray3);
  border-left: var(--border-size-sm) solid var(--color-gray3);
  border-bottom: var(--border-size-sm) solid var(--color-gray3);
  color: var(--color-text-light);
  padding: var(--size--1);
  order: 3;
}

.title-hero img {
  width: 100%;
  height: auto;
  order: 1;
  border: var(--border-size-sm) solid var(--color-gray3);
}
.title-section,
.title-page {
    border-top: var(--border-size-xl) solid var(--color-primary);
}
.title-section h1 {
  text-shadow: 2px 2px var(--color-secondary);
  color: var(--color-primary);
}

.title-page {
    margin-bottom: var(--size-2);
}

/* *****************************************
 * Layout: Callouts
 * */
.callout {
  background-color: var(--color-gray4);
  font-size: var(--size--1);
  color: var(--color-gray2);
}
.callout h2 {
  font-size: var(--size-1);
  font-family: var(--font-family-sans-serif);
  margin: 0;
  padding: 0;
  text-transform: uppercase;
}
.frontmatter h2 {
  font-size: var(--size-1);
}
.frontmatter h2 mark {
    box-shadow: unset;
    text-shadow: unset;
    background-color: var(--color-gray2);
    color: var(--color-text-dark);
    margin-bottom: 0;
}
.frontmatter ul {
  margin: 0;
  padding: 0;
}
.frontmatter li {
  margin: 0 0 0 40px;
  padding: 5px 5px 5px 0;
}
.frontmatter li span {
  color: var(--color-text-light);
}

/* *****************************************
 * Layout: Content
 * */

.content-grid {
  display: grid;
  grid-template-columns:
      [full-width-start] minmax(var(--size-0),1fr)
        [popout-start] minmax(0,var(--size-5))
            [content-start] min(var(--content-max-width),100% - var(--size-1) * 2)
            [content-end] minmax(0,var(--size-1))
        [popout-end] minmax(var(--size-5),1fr)
      [full-width-end];
}
.content-grid > * {
  grid-column: content;
}
.popout-content {
    grid-column: popout;
}
.content-grid > figure {
    grid-column: popout;
}

.entries h2,
.section-heading {
    font-family: var(--font-family-sans-serif);
    border-bottom: var(--border-size-sm) solid var(--color-border-minor);
    line-height: 1;
  text-transform: uppercase;
  letter-spacing: var(--kerning-tight);
}
.entries h2 mark,
.section-heading mark {
  background-color: var(--color-primary);
  display: inline-block;
  line-height: 1;
  padding: 0 5px;
  box-shadow: -2px -2px var(--color-secondary);
  text-shadow: 1px 1px var(--color-secondary);
}

.newswire mark { background-color: transparent; font-style: oblique; }

.section-heading {
    margin-bottom: var(--size-0);
}
.entries .entry {
  display: grid;
  grid-template-rows: max-content auto min-content;
  border: var(--border-size-sm) solid var(--color-gray3);
}
.entry h3 {
  padding: var(--size--1);
}

.entry .excerpt {
  padding: var(--size--1);
  margin: 0;
  font-size: var(--size--1);
}

.art-single footer,
.entry footer {
  font-size: var(--size--1);
  color: var(--color-gray2);
  align-self: end;
}

.art-single footer {
  margin-top: var(--size--1);
}

.art-single footer div,
.entry footer div {
  padding: 5px 10px 5px 25px;
  position: relative;
}

.art-single footer div::before,
.entry footer div::before {
  content: '\2022';
  position: absolute;
  left: 10px;
  top: 6px;
}
.entry > div {
  display: block;
}
.entries h3 {
    font-family: var(--font-family-sans-serif);
    font-size: var(--font-title-heading-entries-size);
  font-weight: normal;
  margin: 0;
}
.entries h3 a { display: block; }
.entries .entry > figure {
  margin-bottom: 0;
}
.entries-grid .entry img {
  width: 100%;
}
.entries-archive h2 {
  margin-bottom: var(--size-1);
}
.entries-archive .entry img {
  width: 100%;
}

figure {
  margin: 0 0 var(--size-0) 0;
}
/* transition doesn't look right on a hue-rotate - it stutters.
figure img {
  transition: all 0.2s linear;
}
*/
figure img:hover {
  filter: hue-rotate(3.14rad);
}

figcaption {
    max-width: 50ch;
    padding: var(--size-1) 0;
}
figcaption h2,
figcaption h3 {
    font-family: var(--font-family-sans-serif);
    font-size: var(--size-1);
    margin-top: var(--size-0);
    margin-top: 0;
}
figcaption .section-heading {
  border-bottom-color: var(--color-gray2);
}
figcaption .section-heading mark {
    box-shadow: unset;
    text-shadow: unset;
    background-color: var(--color-gray2);
    color: var(--color-text-dark);
    margin-bottom: 0;
}

article {
    margin-bottom: var(--size-1);
}

.entry figure {
  border: var(--border-size-sm) solid var(--color-gray3);
}


/* *****************************************
 * Layout: Image story full
 * */
.art-single figure {
  display: flex;
  flex-direction: column;
  flex-wrap: wrap;
}
.art-single figure img {
  border: var(--border-size-sm) solid var(--color-gray3);
}
figure mark {
  background-color: var(--color-gray4);
  color: var(--color-text-light);
  padding: 2px 5px;
  margin: 10px 0;
  display: block;
}

.dateline p { font-size: 16px; text-transform: uppercase; color: var(--color-gray4); }
.newswire {
    background: var(--color-gray1);
    color: var(--color-black);
    font-family: var(--font-family-serif);
    max-width: var(--content-max-width);
    padding: var(--size-1);
    position: relative;
    border: 2px dashed var(--color-black);
}

.elsewhere-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
}
.elsewhere-nav .section-heading,
.elsewhere-nav  nav {
  flex-basis: 100%;
}
.elsewhere-nav nav a {
  display: block;
  padding: var(--size--1) 0;
}

/* Media Queries */
@media (min-width: 768px) {
  .wrapper {
    grid-template-columns: 1fr auto;
    grid-template-rows: auto 1fr auto;
    grid-template-areas:
        "logo nav"
        "content content"
        "footer footer";
    min-height: 100vh;
  }

  .nav {
    padding-right: 0;
  }
  .logo-tagline { padding-bottom: var(--size-3); }

  .title-hero {
    padding: 0;
    display: grid;
    grid-template-rows: 1fr max-content;
    grid-template-columns: repeat(5, 20%);
  }
  .title-hero img {
    order: unset;
    grid-row-start: 1;
    grid-row-end: 2;
    grid-column-start: 4;
    grid-column-end: 6;
    align-self: end;
  }
  .title-hero h1 {
    order: unset;
    margin-top: 0;
    grid-row-start: 1;
    grid-row-end: 2;
    grid-column-start: 1;
    grid-column-end: 4;
    display: flex;
    flex-direction: column;
    justify-content: center;
  }
  .title-hero p {
    order: unset;
    grid-row-start: 2;
    grid-row-end: 3;
    grid-column-start: 4;
    grid-column-end: 6;
    margin: 0;
    align-self: start;
  }

  .entries-grid {
      display: flex;
      flex-wrap: wrap;
    gap: var(--size-2);
    justify-content: space-around;
  }
  .entries-grid h2 { flex-basis: 100%; }
  .entries-grid .entry {
    flex-basis: 30%;
  }
  .entries-grid figure {
    border-bottom: var(--border-size-sm) solid var(--color-gray3);
  }

  .archive-sections {
    display: flex;
    gap: var(--size-2);
  }
  .archive-sections > section {
    width: 100%;
    max-width: var(--content-max-width);
  }
  .entries-archive .entry {
    display: grid;
    grid-template-columns: 300px auto;
  }
  .entries-archive figure {
    flex-basis: 300px;
    flex-shrink: 0;
    grid-row-start: 1;
    grid-row-end: 4;
    grid-column-start: 1;
    grid-column-end: 2;
  }
  .entries-archive h3 {
    grid-row-start: 1;
    grid-row-end: 2;
    grid-column-start: 2;
    grid-column-end: 3;
  }
  .entries-archive .excerpt {
    grid-row-start: 2;
    grid-row-end: 3;
    grid-column-start: 2;
    grid-column-end: 3;
  }
  .entries-archive footer {
    grid-row-start: 3;
    grid-row-end: 4;
    grid-column-start: 2;
    grid-column-end: 3;
  }
  .entry h3 {
    text-wrap: auto;
  }
  footer.bottom {
    flex-direction: row;
  }

  .imagestory-grid figure {
    flex-direction: row;
  }
  .imagestory-grid figure figcaption {
    flex-basis: 33%;
    padding: 0 var(--size-1) var(--size-1) var(--size-1);
  }
  .imagestory-grid figure a {
      flex-basis: 66%;
  }
  .imagestory-grid figure img {
      max-width: 100%;
  }

  .imagestory-archive {
    margin-top: var(--size-1);
    display: grid;
    gap: var(--size-0);
    grid-template-columns: 50% auto;
    grid-template-areas:
      "frontmatter story"
      "images story"
  }
  .imagestory-archive .frontmatter {
    grid-area: frontmatter;
  }
  .imagestory-archive .figures {
    grid-area: images;
  }
  .imagestory-archive .figures figcaption {
    max-width: 40ch;
  }
  .imagestory-archive .story {
    grid-area: story;
  }
  .elsewhere-nav nav {
    flex-basis: max-content;
  }
}

@media (min-width: 1200px) {
  figure {
    flex-wrap: nowrap;
  }
}