/* Typefaces, served from this site's own fonts/ folder.
   Besley and Schibsted Grotesk are both under the SIL Open Font License. */

@font-face {
  font-family: "Besley";
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
  src: url("fonts/besley-latin-wght-normal.woff2") format("woff2");
}

@font-face {
  font-family: "Schibsted Grotesk";
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
  src: url("fonts/schibsted-grotesk-latin-wght-normal.woff2") format("woff2");
}

/* Norwegian Elkhound Club of Ohio
   Layout: one left-aligned column, 70rem wide. The home page opens with the
   headline beside the club burgee, hung vertically. Inner pages are a
   reading column, with a facts panel beside it where there are facts to show. */

:root {
  /* The Norwegian flag's colors. Fixed in both themes. */
  --flag-red: #BA0C2F;
  --flag-blue: #00205B;
  --flag-white: #FFFFFF;

  /* Theme colors. The neutrals lean toward the breed's silver-gray coat. */
  --bg: #FFFFFF;
  --band: #EDF0F5;
  --ink: #1B2640;
  --heading: #00205B;
  --muted: #55607A;
  --line: #D3D9E4;
  --accent: #BA0C2F;
  --accent-strong: #970A26;
  --on-accent: #FFFFFF;
  --focus: #2F6BFF;
  --paper: #FFFFFF;
  --paper-ink: #1B2640;
  --footer-bg: #00205B;
  --footer-ink: #EEF2F8;
  --footer-muted: #B4BFD6;
  --footer-line: #24407E;

  /* Type: an American Clarendon for display, a Norwegian grotesque for text. */
  --font-display: "Besley", Rockwell, "Roboto Slab", Georgia, serif;
  --font-body: "Schibsted Grotesk", "Helvetica Neue", Helvetica, Arial, sans-serif;

  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #071229;
    --band: #0C1B3D;
    --ink: #DDE4F0;
    --heading: #FFFFFF;
    --muted: #A3AFC6;
    --line: #25355C;
    --accent: #D21F3F;
    --accent-strong: #E0425E;
    --on-accent: #FFFFFF;
    --focus: #8FB1FF;
    --paper: #FFFFFF;
    --paper-ink: #1B2640;
    --footer-bg: #040B1C;
    --footer-ink: #DDE4F0;
    --footer-muted: #93A0BA;
    --footer-line: #1B2947;
    color-scheme: dark;
  }
}

:root[data-theme="dark"] {
  --bg: #071229;
  --band: #0C1B3D;
  --ink: #DDE4F0;
  --heading: #FFFFFF;
  --muted: #A3AFC6;
  --line: #25355C;
  --accent: #D21F3F;
  --accent-strong: #E0425E;
  --on-accent: #FFFFFF;
  --focus: #8FB1FF;
  --paper: #FFFFFF;
  --paper-ink: #1B2640;
  --footer-bg: #040B1C;
  --footer-ink: #DDE4F0;
  --footer-muted: #93A0BA;
  --footer-line: #1B2947;
  color-scheme: dark;
}

/* ---------- Base ---------- */

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

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.6;
}

@media (min-width: 48em) {
  body {
    font-size: 1.125rem;
  }
}

[hidden] {
  display: none !important;
}

img,
svg {
  max-width: 100%;
}

h1,
h2,
h3 {
  margin: 0;
  color: var(--heading);
  font-family: var(--font-display);
  font-weight: 650;
  text-wrap: balance;
}

h1 {
  font-size: clamp(2.2rem, 1.6rem + 2.7vw, 3.5rem);
  line-height: 1.05;
  letter-spacing: -0.015em;
}

h2 {
  font-size: clamp(1.55rem, 1.3rem + 1.1vw, 2.1rem);
  line-height: 1.15;
  letter-spacing: -0.01em;
}

h3 {
  font-family: var(--font-body);
  font-size: 1.15em;
  font-weight: 700;
  line-height: 1.3;
}

p,
ul,
dl,
dd {
  margin: 0;
}

a {
  color: var(--heading);
  text-decoration-line: underline;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 2px;
  text-underline-offset: 0.2em;
}

a:hover {
  text-decoration-thickness: 3px;
}

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

[id] {
  scroll-margin-top: 1rem;
}

@media (min-width: 30em) {
  .keep {
    white-space: nowrap;
  }
}

.wrap {
  max-width: 70rem;
  margin-inline: auto;
  padding-inline: clamp(1rem, 4vw, 2.5rem);
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -5rem;
  z-index: 10;
  padding: 0.6rem 1rem;
  background: var(--heading);
  color: var(--bg);
  text-decoration: none;
  font-weight: 600;
}

.skip-link:focus {
  top: 0.75rem;
}

.sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

/* ---------- Header ---------- */

/* The flag's stripe sequence from hoist to fly: red, white, blue, white, red
   in the flag's own 6 : 1 : 2 : 1 : 12 proportions. */
.flag-strip {
  height: 6px;
  background: linear-gradient(
    to right,
    var(--flag-red) 0 27.27%,
    var(--flag-white) 27.27% 31.82%,
    var(--flag-blue) 31.82% 40.91%,
    var(--flag-white) 40.91% 45.45%,
    var(--flag-red) 45.45% 100%
  );
}

.site-header {
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}

.header-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 1.5rem;
  padding-block: 0.85rem;
}

.brand {
  display: flex;
  flex: 1 1 0;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
  color: var(--heading);
  text-decoration: none;
}

.brand-mark {
  flex: none;
  width: 3.25rem;
  height: 2rem;
  color: var(--heading);
}

.brand-name {
  font-family: var(--font-display);
  font-size: 1.0625rem;
  font-weight: 650;
  line-height: 1.15;
  letter-spacing: -0.005em;
}

.brand-name span {
  display: block;
}

@media (max-width: 25.99em) {
  .header-row {
    column-gap: 0.9rem;
  }

  .brand {
    gap: 0.55rem;
  }

  .brand-mark {
    width: 2.6rem;
    height: 1.6rem;
  }

  .brand-name {
    font-size: 0.95rem;
  }
}

@media (max-width: 22.49em) {
  .brand-mark {
    width: 2.2rem;
    height: 1.35rem;
  }

  .brand-name {
    font-size: 0.82rem;
  }

  .nav-toggle {
    padding-inline: 0.7rem;
  }
}

.nav-toggle {
  flex: none;
  padding: 0.4rem 0.9rem;
  border: 2px solid var(--heading);
  border-radius: 3px;
  background: transparent;
  color: var(--heading);
  font: inherit;
  font-size: 1rem;
  font-weight: 650;
  cursor: pointer;
}

.site-nav {
  flex-basis: 100%;
}

.site-nav ul {
  display: flex;
  flex-direction: column;
  padding: 0;
  list-style: none;
}

.site-nav a {
  display: block;
  padding-block: 0.8rem;
  border-top: 1px solid var(--line);
  color: var(--heading);
  font-size: 1.0625rem;
  font-weight: 600;
  text-decoration: none;
}

.site-nav a[aria-current="page"] {
  box-shadow: inset 4px 0 0 var(--accent);
  padding-left: 0.85rem;
}

/* Until the script runs, the menu stays open so it works without it. */
.js .site-nav {
  display: none;
}

.js .site-nav.is-open {
  display: block;
}

@media (min-width: 62em) {
  .brand {
    flex: 0 1 auto;
  }

  .nav-toggle {
    display: none !important;
  }

  .site-nav,
  .js .site-nav {
    display: block;
    flex-basis: auto;
  }

  .site-nav ul {
    flex-direction: row;
    gap: clamp(1.1rem, 2.2vw, 2rem);
  }

  .site-nav a {
    padding-block: 0.35rem;
    border-top: 0;
    border-bottom: 3px solid transparent;
    font-size: 1rem;
  }

  .site-nav a:hover {
    border-bottom-color: var(--line);
  }

  .site-nav a[aria-current="page"] {
    box-shadow: none;
    padding-left: 0;
    border-bottom-color: var(--accent);
  }
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-block;
  padding: 0.85em 1.3em;
  border: 2px solid transparent;
  border-radius: 3px;
  font: inherit;
  font-weight: 650;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}

.btn-primary {
  background: var(--accent);
  color: var(--on-accent);
}

.btn-primary:hover {
  background: var(--accent-strong);
}

.btn-quiet {
  border-color: var(--heading);
  background: transparent;
  color: var(--heading);
}

.btn-quiet:hover {
  background: var(--heading);
  color: var(--bg);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* ---------- Home hero ---------- */

.hero {
  overflow: hidden;
  background: var(--band);
}

.hero-grid {
  display: grid;
  gap: 2.75rem;
  align-items: center;
  padding-block: clamp(2.5rem, 6vw, 5rem) clamp(3rem, 6vw, 5rem);
}

.hero-copy {
  display: grid;
  gap: 1.5rem;
  min-width: 0;
}

.hero h1 {
  font-size: clamp(2.2rem, 1.35rem + 2.75vw, 3.5rem);
}

.lede {
  max-width: 34em;
  font-size: 1.2em;
  line-height: 1.5;
}

.status {
  max-width: 36em;
  color: var(--muted);
  font-size: 0.95em;
}

/* The club burgee hangs beside the headline, and below it on a phone. Its
   outline takes the heading color, as in the club's profile picture: blue on
   the light band, white on the dark one. */
.hero-art {
  width: clamp(7.5rem, 34vw, 9.5rem);
  color: var(--heading);
}

.hero-burgee {
  display: block;
  width: 100%;
  height: auto;
}

@media (min-width: 48em) {
  .hero-grid {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: clamp(2rem, 5vw, 4rem);
  }

  .hero-art {
    width: clamp(10rem, 21vw, 13rem);
  }
}

@media (min-width: 62em) {
  .hero-grid {
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 0.7fr);
  }

  .hero-art {
    width: clamp(13.5rem, 20vw, 16.5rem);
    justify-self: end;
  }
}

/* ---------- Sections ---------- */

.section {
  padding-block: clamp(2.75rem, 6vw, 5rem);
}

.section-band {
  background: var(--band);
}

.page-head {
  padding-block: clamp(2.25rem, 5vw, 4rem);
  background: var(--band);
}

.page-head h1 {
  font-size: clamp(2.1rem, 1.6rem + 2.4vw, 3.25rem);
}

.page-head .lede {
  margin-top: 1.1rem;
}

.page-head-action {
  margin-top: 1.5rem;
}

.cols-3 {
  display: grid;
  gap: 2.5rem;
}

.cols-3 > * {
  display: grid;
  gap: 0.7rem;
  align-content: start;
  min-width: 0;
}

.cols-3 h2 {
  font-size: 1.5rem;
}

@media (min-width: 48em) {
  .cols-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(1.75rem, 4vw, 3.5rem);
  }
}

.split {
  display: grid;
  gap: 2.5rem;
}

.split > * {
  min-width: 0;
}

@media (min-width: 62em) {
  .split {
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 0.7fr);
    gap: clamp(2.5rem, 6vw, 5rem);
    align-items: start;
  }
}

.prose {
  max-width: 38em;
}

.prose > * + * {
  margin-top: 1.1em;
}

.prose > h2 {
  margin-top: 2.2em;
}

.prose > h2:first-child {
  margin-top: 0;
}

.prose > h2 + * {
  margin-top: 0.7em;
}

.prose > h3 {
  margin-top: 1.6em;
}

.prose > h2 + h3 {
  margin-top: 0.9em;
}

.prose > h3 + * {
  margin-top: 0.3em;
}

.prose ul {
  padding-left: 1.2em;
}

.prose li + li {
  margin-top: 0.5em;
}

.stack > * + * {
  margin-top: 1.5rem;
}

.stack-lg > * + * {
  margin-top: clamp(2rem, 4vw, 3rem);
}

.intro-grid {
  display: grid;
  gap: 1.25rem;
}

.intro-grid > * {
  min-width: 0;
}

.intro-head {
  display: grid;
  gap: 0.9rem;
  align-content: start;
}

@media (min-width: 62em) {
  .intro-grid {
    grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
    gap: clamp(2.5rem, 6vw, 5rem);
  }
}

/* A row of facts under a heavy rule, used on the home page. */
.facts-strip {
  padding-top: 1.4rem;
  border-top: 5px solid var(--heading);
}

.facts-strip dl {
  display: grid;
  gap: 1.4rem 2rem;
}

.facts-strip dl > div {
  min-width: 0;
}

.facts-strip dt {
  color: var(--heading);
  font-size: 0.92em;
  font-weight: 700;
}

.facts-strip .note {
  margin-top: 1.4rem;
}

@media (min-width: 30em) {
  .facts-strip dl {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 62em) {
  .facts-strip dl {
    grid-template-columns: 0.7fr 1.15fr 1.25fr 0.6fr;
  }
}

.mission {
  max-width: 27em;
  color: var(--heading);
  font-family: var(--font-display);
  font-size: clamp(1.3rem, 1.1rem + 0.9vw, 1.7rem);
  font-weight: 500;
  line-height: 1.35;
}

.note {
  color: var(--muted);
  font-size: 0.92em;
}

/* ---------- Facts panel and terms list ---------- */

.facts {
  padding: 1.5rem 1.6rem 1.25rem;
  border-top: 5px solid var(--heading);
  background: var(--band);
}

.section-band .facts {
  background: var(--bg);
}

.facts h2 {
  font-family: var(--font-body);
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0;
}

.facts > * + * {
  margin-top: 0.9rem;
}

.facts dt {
  padding-top: 0.75rem;
  border-top: 1px solid var(--line);
  color: var(--heading);
  font-size: 0.92em;
  font-weight: 700;
}

.facts dd {
  padding-bottom: 0.75rem;
}

.facts .note {
  padding-top: 0.75rem;
  border-top: 1px solid var(--line);
}

.terms {
  max-width: 52rem;
  border-bottom: 1px solid var(--line);
}

.terms > div {
  display: grid;
  gap: 0.2rem 2rem;
  padding-block: 1rem;
  border-top: 1px solid var(--line);
}

.terms dt {
  color: var(--heading);
  font-weight: 700;
}

@media (min-width: 40em) {
  .terms > div {
    grid-template-columns: 11rem minmax(0, 1fr);
  }
}

/* ---------- Membership form ---------- */

.form-shell {
  max-width: 52rem;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--paper);
  color: var(--paper-ink);
}

.form-shell iframe {
  display: block;
  width: 100%;
  height: 68rem;
  border: 0;
}

.preview-note {
  max-width: 52rem;
  display: grid;
  gap: 1rem;
  justify-items: start;
  padding: 1.4rem 1.5rem;
  border: 2px dashed var(--muted);
  border-radius: 4px;
}

.preview-bar {
  padding-block: 0.5rem;
  background: var(--heading);
  color: var(--bg);
  font-size: 0.9rem;
  font-weight: 600;
}

/* ---------- Footer ---------- */

.site-footer {
  padding-block: clamp(2.5rem, 5vw, 3.75rem) 1.75rem;
  background: var(--footer-bg);
  color: var(--footer-ink);
}

.site-footer a {
  color: var(--footer-ink);
  text-decoration-color: var(--footer-muted);
}

.footer-grid {
  display: grid;
  gap: 2.25rem;
}

.footer-grid > * {
  min-width: 0;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--footer-ink);
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 650;
  line-height: 1.2;
}

.footer-brand .brand-mark {
  color: var(--footer-ink);
}

.footer-about p + p {
  margin-top: 0.9rem;
  max-width: 24em;
  color: var(--footer-muted);
}

.footer-label {
  margin-bottom: 0.6rem;
  color: var(--footer-muted);
  font-size: 0.9rem;
  font-weight: 700;
}

.site-footer ul {
  display: grid;
  gap: 0.45rem;
  padding: 0;
  list-style: none;
}

.footer-base {
  margin-top: 2.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--footer-line);
  color: var(--footer-muted);
  font-size: 0.9rem;
}

@media (min-width: 48em) {
  .footer-grid {
    grid-template-columns: minmax(0, 1.5fr) minmax(0, 0.8fr) minmax(0, 1fr);
    gap: clamp(2rem, 5vw, 4rem);
  }
}
