/* voterobanders.ca, v2 "traditional": EB Garamond on ivory paper, the Alberta mark used small like a crest,
   hairline rules, small caps, roman numerals. Colours: Rob Anders VI v1 (Socred Navy #2B458C, Socred Green
   #66CC33). Green is only for hairlines and small ornaments, never for type on light grounds (2.0:1).
   v1 (bold Inter, navy hero) is in git history: commit a81deba. */
@font-face {
  font-family: "EB Garamond";
  src: url("/assets/fonts/ebgaramond.woff2") format("woff2");
  font-weight: 400 800;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "EB Garamond";
  src: url("/assets/fonts/ebgaramond-italic.woff2") format("woff2");
  font-weight: 400 800;
  font-style: italic;
  font-display: swap;
}
:root {
  --navy: #2B458C;
  --navy-deep: #1E3166;
  --green: #66CC33;
  --ink: #1B2440;
  --muted: #5A6380;
  --paper: #FBF9F3;
  --desk: #EEE7D6;          /* alabaster cream: the surface the page rests on, a shade deeper than the paper */
  --rule: #D9D3C3;
  --serif: "EB Garamond", Garamond, "Times New Roman", Georgia, serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--serif);
  font-size: 1.25rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--desk);
  font-variant-numeric: oldstyle-nums proportional-nums;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; display: block; }

/* a thin double border, like a printed bill or a certificate */
.frame {
  max-width: 54rem;
  margin: clamp(0.75rem, 3vw, 2.5rem) auto;
  padding: clamp(2rem, 6vw, 4rem) clamp(1rem, 5vw, 4rem) clamp(1.5rem, 4vw, 3rem);
  border: 1px solid var(--navy);
  outline: 1px solid var(--navy);
  outline-offset: -7px;
  background: var(--paper);
}
@media (max-width: 30rem) { .frame { margin: 0.75rem; outline-offset: -5px; } }

.masthead { text-align: center; }
.eyebrow {
  margin: 0 0 1.75rem;
  font-variant: all-small-caps;
  letter-spacing: 0.16em;
  font-size: 1rem;
  color: var(--muted);
}
/* portrait in a double-ruled mat. The outer rule has no bottom: the emblem's SVG draws that line, and the
   middle of it becomes the logo mark as you scroll (assets/emblem.js) */
.portrait {
  position: relative;
  margin: 0 auto;
  width: min(18rem, 70vw);
  padding: 0.55rem;
  border: 1px solid var(--navy);
  background: #fff;
}
.portrait::before {
  content: ""; position: absolute; inset: -6px; border: 1px solid var(--navy); pointer-events: none;
}
.portrait img { width: 100%; height: auto; }          /* the whole photograph, never cropped */
h1 { margin: 0; font-weight: 400; color: var(--navy); line-height: 1.05; }
.name {
  display: block;
  font-size: clamp(2rem, 9.4vw, 5rem);
  white-space: nowrap;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-right: -0.08em;          /* balance the tracking on the last letter */
}
.for {
  display: block;
  margin-top: 0.6rem;
  font-style: italic;
  font-size: clamp(1.35rem, 4.2vw, 1.85rem);
  color: var(--ink);
}
.ornament { display: flex; align-items: center; justify-content: center; gap: 0.9rem; margin: 1.6rem auto 0; max-width: 22rem; }
.ornament .chev { flex: none; display: block; }
.ornament span { flex: 1; height: 1px; background: var(--navy); }
.ornament .chev { flex: none; display: block; }
.when {
  margin: 0 0 2.2rem;
  font-variant: all-small-caps;
  letter-spacing: 0.12em;
  font-size: 1.35rem;
  line-height: 1.45;
  color: var(--navy);
}
.when span { color: var(--muted); font-size: 1.15rem; }
.btn {
  display: inline-block;
  font-family: var(--serif);
  font-variant: all-small-caps;
  letter-spacing: 0.14em;
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--paper);
  background: var(--navy);
  text-decoration: none;
  padding: 0.75rem 1.9rem 0.85rem;
  border: 1px solid var(--navy);
  outline: 1px solid var(--navy);
  outline-offset: 3px;
  min-height: 3rem;
}
.btn:hover { background: var(--navy-deep); }
@media (max-width: 30rem) {
  .btn { font-size: 1.05rem; letter-spacing: 0.08em; padding: 0.7rem 1.1rem 0.8rem; }
  .eyebrow { letter-spacing: 0.1em; }
}
.btn:focus-visible { outline: 2px solid var(--green); outline-offset: 4px; }


/* intro: quote on the left, portrait on the right, on every screen size */
.intro {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-areas: "quote portrait";
  align-items: center;
  gap: clamp(1rem, 4vw, 3rem);
  margin-top: clamp(2.25rem, 6vw, 3.25rem);
}
.intro .portrait { grid-area: portrait; }
.quote { grid-area: quote; margin: 0; text-align: left; }
@media (max-width: 47.99rem) {
  .intro .portrait { width: 38vw; padding: 0.3rem; }
  .intro .portrait::before { inset: -4px; }
  .quote p { font-size: clamp(1.05rem, 4.6vw, 1.45rem); line-height: 1.35; }
  .quote footer { font-size: 0.95rem; margin-top: 0.7rem; }
  .quote .tagline { font-size: 0.85rem; letter-spacing: 0.08em; }
}
.quote p {
  margin: 0;
  font-style: italic;
  font-size: clamp(1.45rem, 3.4vw, 1.9rem);
  line-height: 1.4;
  color: var(--navy);
  text-wrap: pretty;
}
.quote footer {
  margin-top: 1.1rem;
  font-variant: all-small-caps;
  letter-spacing: 0.16em;
  font-size: 1.15rem;
  color: var(--ink);
}
.quote footer::before { content: "— "; letter-spacing: 0; }
.quote .tagline {
  margin-top: 1rem;
  font-style: normal;
  font-variant: all-small-caps;
  letter-spacing: 0.14em;
  font-size: 1.05rem;
  color: var(--muted);
}

/* experience in three figures */
.facts {
  list-style: none; margin: 1rem 0 1.75rem; padding: 1.4rem 0;
  border-top: 1px solid var(--navy); border-bottom: 1px solid var(--navy);
  display: grid; grid-template-columns: repeat(2, 1fr); text-align: center; row-gap: 1.2rem;
}
@media (min-width: 40rem) { .facts { grid-template-columns: repeat(4, 1fr); } }
.facts li:nth-child(3) { border-left: 0; }
@media (min-width: 40rem) { .facts li:nth-child(3) { border-left: 1px solid var(--rule); } }
.facts li + li { border-left: 1px solid var(--rule); }
.facts strong { display: block; font-weight: 500; font-size: clamp(1.5rem, 4.5vw, 2.1rem); color: var(--navy); line-height: 1.1; font-variant-numeric: lining-nums; }
.facts span { display: block; margin-top: 0.3rem; font-variant: all-small-caps; letter-spacing: 0.1em; font-size: 0.95rem; color: var(--muted); line-height: 1.3; padding: 0 0.3rem; }

.vote-when { text-align: center; margin-top: clamp(2.25rem, 6vw, 3rem); }
.vote-when .when { margin: 0; }

/* video in the same double-ruled mat */
.video { margin-top: clamp(3rem, 8vw, 4.5rem); padding-top: clamp(2.5rem, 6vw, 3.5rem); border-top: 1px solid var(--rule); }
.video-frame { padding: 0.5rem; border: 1px solid var(--navy); outline: 1px solid var(--navy); outline-offset: 4px; background: #fff; }
.video-frame video { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; background: var(--navy-deep); }

/* contact: the green >> from the video's close */
.contact { margin-top: clamp(3rem, 8vw, 4.5rem); padding-top: clamp(2.5rem, 6vw, 3.5rem); border-top: 1px solid var(--rule); text-align: center; }
.contact h2 { margin-bottom: 1rem; }
.contact-lead { margin: 0 auto 1.75rem; max-width: 32rem; font-style: italic; color: var(--muted); }
.contact-lines { list-style: none; margin: 0; padding: 0; display: grid; gap: 1rem; justify-content: center; }
.contact-lines li { display: flex; align-items: center; gap: 0.8rem; }
.contact-lines .chev-r { flex: none; display: block; }
.contact-lines a {
  font-size: clamp(1.3rem, 4.6vw, 1.7rem);
  color: var(--navy);
  text-decoration: none;
  border-bottom: 1px solid var(--rule);
  font-variant-numeric: lining-nums;
}
.contact-lines a:hover { border-bottom-color: var(--navy); }
.contact-lines a:focus-visible { outline: 2px solid var(--green); outline-offset: 3px; }

/* the emblem sits on the frame: its SVG line y = 0 is the outer bottom rule (6px below the inner border) */
.ornament-em { position: absolute; left: -6px; right: -6px; top: calc(100% + 5.5px); transform: translateY(-11.667%); }
.emblem-svg { display: block; width: 100%; height: auto; overflow: visible; }

/* what he will do: the green >> list */
.plan { margin-top: clamp(3rem, 8vw, 4.5rem); padding-top: clamp(2.5rem, 6vw, 3.5rem); border-top: 1px solid var(--rule); }
.chev-list { list-style: none; margin: 0 auto; padding: 0; max-width: 36rem; display: grid; gap: 0.9rem; }
.chev-list li { position: relative; padding-left: 2.1rem; font-size: 1.2rem; line-height: 1.45; }
.chev-list li::before {
  content: ""; position: absolute; left: 0; top: 0.32em; width: 1.25rem; height: 0.9rem;
  background: url("/assets/img/chev-r.svg") no-repeat left center / contain;
}
.plan-note { margin: 1.75rem auto 0; max-width: 36rem; font-style: italic; color: var(--muted); text-align: center; }

/* steps */
.steps { margin-top: clamp(3rem, 8vw, 4.5rem); padding-top: clamp(2.5rem, 6vw, 3.5rem); border-top: 1px solid var(--rule); }
h2 {
  text-align: center;
  font-weight: 500;
  font-size: clamp(1.8rem, 5vw, 2.4rem);
  color: var(--navy);
  margin: 0 0 2.25rem;
  line-height: 1.15;
}
.steps ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 2rem; }
@media (min-width: 48rem) {
  .steps ol { grid-template-columns: repeat(3, 1fr); gap: 0; }
  .steps li + li { border-left: 1px solid var(--rule); }
  .steps li { padding: 0 1.5rem; }
}
.steps li { text-align: center; }
.n {
  display: block;
  font-size: 1.6rem;
  font-weight: 500;
  color: var(--navy);
  letter-spacing: 0.06em;
  line-height: 1;
  margin-bottom: 0.7rem;
}
.n::after { content: ""; display: block; width: 1.75rem; height: 1px; background: var(--green); margin: 0.7rem auto 0; }
h3 {
  margin: 0 0 0.5rem;
  font-weight: 600;
  font-size: 1.3rem;
  color: var(--ink);
  line-height: 1.25;
}
.steps p { margin: 0; font-size: 1.1rem; line-height: 1.55; color: #343D5A; }
.steps strong { font-weight: 700; color: var(--navy); }
.steps p + p { margin-top: 0.6rem; }
.step-link a {
  display: inline-block; font-variant: all-small-caps; letter-spacing: 0.12em; font-weight: 600; font-size: 1.1rem;
  color: var(--paper); background: var(--navy); text-decoration: none; padding: 0.35rem 1rem 0.45rem;
  outline: 1px solid var(--navy); outline-offset: 2px;
}
.step-link a:hover { background: var(--navy-deep); }

.soon { margin-top: clamp(2.5rem, 6vw, 3.5rem); text-align: center; }
.soon p { margin: 0; font-style: italic; font-size: 1.2rem; color: var(--muted); }

/* footer */
.foot { background: var(--navy); color: #E8ECF6; text-align: center; padding: 2.5rem 1rem 2.75rem; }
.foot img { width: 2.75rem; margin: 0 auto 0.9rem; }
.foot p { margin: 0; }
.foot-name { font-size: 1.35rem; text-transform: uppercase; letter-spacing: 0.14em; font-weight: 500; color: #fff; }
.foot-for { font-style: italic; font-size: 1.1rem; }
.foot-url { margin-top: 0.8rem !important; font-variant: all-small-caps; letter-spacing: 0.16em; font-size: 1.05rem; color: #C9D2EA; }

a { color: var(--navy); }

/* preview passcode page (src/worker.js) */
.gate { background: var(--desk); }
.gate-box { min-height: 100vh; display: grid; align-items: center; justify-items: center; padding: 1rem; }
.gate-box .wrap { background: var(--paper); width: 100%; max-width: 26rem; text-align: center; border: 1px solid var(--navy); outline: 1px solid var(--navy); outline-offset: -7px; padding: 2.5rem 1.75rem; }
.gate .when { margin: 0 0 1.5rem; color: var(--navy); }
.gate .when strong { font-variant: normal; letter-spacing: 0.04em; font-weight: 600; }
.gate form { display: grid; gap: 0.6rem; text-align: left; }
.gate label { font-variant: all-small-caps; letter-spacing: 0.14em; color: var(--muted); }
.gate input[type=password] {
  font: inherit; font-size: 1.1rem; padding: 0.6rem 0.8rem; border: 1px solid var(--navy); background: #fff; color: var(--ink); border-radius: 0;
}
.gate input[type=password]:focus { outline: 2px solid var(--green); outline-offset: 1px; }
.gate .btn { cursor: pointer; margin-top: 0.6rem; }
.gate-err { margin: 0; font-style: italic; color: #7A1F1F; }

/* contact form */
.contact-form { max-width: 34rem; margin: 0 auto 2rem; text-align: left; display: grid; gap: 0.9rem; }
.contact-form label { display: grid; gap: 0.25rem; font-variant: all-small-caps; letter-spacing: 0.1em; color: var(--muted); font-size: 1.05rem; }
.contact-form label span { letter-spacing: 0.04em; }
.contact-form input, .contact-form textarea {
  font: inherit; font-size: 1.1rem; font-variant: normal; letter-spacing: 0; color: var(--ink); background: #fff;
  border: 1px solid #B8BDCB; border-radius: 0; padding: 0.55rem 0.7rem; width: 100%;
}
.contact-form input:focus, .contact-form textarea:focus { outline: 2px solid var(--green); outline-offset: 1px; border-color: var(--navy); }
.contact-form .f2 { display: grid; gap: 0.9rem; }
@media (min-width: 40rem) { .contact-form .f2 { grid-template-columns: 1fr 1fr; } }
.contact-form .check { display: flex; gap: 0.6rem; align-items: center; font-variant: normal; letter-spacing: 0; font-size: 1.1rem; color: var(--ink); }
.contact-form .check input { width: 1.15rem; height: 1.15rem; accent-color: var(--navy); }
.contact-form .hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.contact-form .btn { justify-self: center; cursor: pointer; }
.form-note { margin: 0; font-size: 1rem; font-style: italic; color: var(--muted); text-align: center; }
.form-msg { display: none; margin: 0; padding: 0.6rem 0.8rem; background: #fff; border-left: 3px solid #A33; font-style: italic; color: #7A1F1F; }
.form-msg.on { display: block; }
.contact .or { margin: 0 0 1rem; font-style: italic; color: var(--muted); }

/* section menu under the masthead */
.sections { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.4rem 1.6rem; margin: 1.6rem 0 0; }
.sections a { display: inline-flex; align-items: center; gap: 0.45rem; text-decoration: none; color: var(--navy);
  font-variant: all-small-caps; letter-spacing: 0.12em; font-size: 1.15rem; font-weight: 500; padding: 0.3rem 0; border-bottom: 1px solid transparent; }
.sections a:hover { border-bottom-color: var(--navy); }
.chev-r { flex: none; display: block; }

/* the three parts */
.part { margin-top: clamp(1.75rem, 5vw, 2.5rem); padding-top: clamp(1.5rem, 4vw, 2rem); border-top: 1px solid var(--navy); scroll-margin-top: 1rem; }
.hero-video + main > .part:first-child { margin-top: clamp(3rem, 8vw, 4rem); }
.part-title { display: flex; align-items: center; justify-content: flex-start; gap: 0.7rem; text-align: left; cursor: pointer; list-style: none; }
.part-title::-webkit-details-marker { display: none; }
.part-title::marker { content: ""; }
.part-title h2 { margin: 0; display: flex; align-items: center; gap: 0.7rem; text-align: left; }
.part-title .chev-r { transition: transform 0.25s ease; }
.part[open] > .part-title .chev-r { transform: rotate(90deg); }
.part-title:hover h2 { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 0.25em; }
.part-title:focus-visible { outline: 2px solid var(--green); outline-offset: 4px; }
.part[open] > .part-title { margin-bottom: 0.5rem; }
.part-title .chev-r { width: 1.3rem; height: auto; }
.sub { margin-top: clamp(2.25rem, 6vw, 3rem); scroll-margin-top: 1rem; }
.sub h3 { text-align: center; font-variant: all-small-caps; letter-spacing: 0.16em; font-weight: 600; font-size: 1.35rem; color: var(--navy); margin: 0 0 0.9rem; }
.sub h3::after { content: ""; display: block; width: 2rem; height: 1px; background: var(--green); margin: 0.6rem auto 0; }
.sub-lead { text-align: center; font-style: italic; color: var(--muted); margin: 0 0 1.5rem; }
.sub-body { max-width: 38rem; margin: 0 auto 1rem; }
.sub-body.center { text-align: center; font-style: italic; color: var(--muted); }

.values { list-style: none; margin: 0; padding: 0; display: grid; gap: 1.25rem; }
@media (min-width: 44rem) { .values { grid-template-columns: repeat(2, 1fr); gap: 1.5rem 2rem; } .values li:last-child { grid-column: 1 / -1; max-width: 26rem; justify-self: center; } }
.values li { border-top: 1px solid var(--rule); padding-top: 0.9rem; text-align: center; }
.values h4 { margin: 0 0 0.3rem; font-size: 1.3rem; font-weight: 600; color: var(--navy); }
.values p { margin: 0; font-size: 1.12rem; color: #343D5A; }

.purpose { text-align: center; font-style: italic; color: var(--navy); font-size: clamp(1.6rem, 4.6vw, 2.2rem); line-height: 1.25; margin: 0 auto 1.2rem; max-width: 30rem; }
.mission { margin: 0 auto 1.6rem; max-width: 36rem; text-align: center; }
.mission p { margin: 0; font-style: italic; color: var(--navy); font-size: clamp(1.3rem, 3.4vw, 1.6rem); line-height: 1.4; }
.sub .chev-list { margin-bottom: 2rem; }
.video-cap { text-align: center; font-variant: all-small-caps; letter-spacing: 0.16em; color: var(--muted); margin: 0 0 0.9rem; }

.topics { list-style: none; margin: 0 auto; padding: 0; max-width: 36rem; columns: 2; column-gap: 2.5rem; }
@media (max-width: 30rem) { .topics { column-gap: 1.25rem; } }
.topics li { break-inside: avoid; position: relative; padding: 0.2rem 0 0.2rem 1.1rem; font-size: 1.08rem; line-height: 1.35; color: var(--ink); }
.topics li::before { content: ""; position: absolute; left: 0; top: 0.72em; width: 0.4rem; height: 1px; background: var(--green); }

#vote .when { text-align: center; margin: 0 0 1rem; }
#vote .steps { margin-top: 0; padding-top: 0; border-top: 0; }
.sub.contact { text-align: center; margin-top: clamp(2.25rem, 6vw, 3rem); padding-top: 0; border-top: 0; }

/* the ballot "1", as on bradlaforge.com: a white square with a heavy rule and a bold numeral */
.box {
  flex: none; display: inline-grid; place-items: center; width: 1.7em; height: 1.7em;
  border: 3px solid var(--navy); color: var(--navy); background: #fff;
  font-family: var(--serif); font-weight: 700; font-variant-numeric: lining-nums; line-height: 1;
}
.ballot {
  display: flex; align-items: center; justify-content: center; gap: 1.1rem; margin: 1.5rem auto 2rem; padding: 1rem 0;
  max-width: 34rem; border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule);
}
.ballot .box { font-size: 2.2rem; }
.ballot p { margin: 0; font-size: 1.3rem; line-height: 1.35; color: var(--ink); text-align: left; }
.ballot strong { color: var(--navy); font-weight: 700; }
.ballot .sub { color: var(--muted); font-style: italic; }
.box--sm { display: grid; font-size: 1.5rem; margin: 0 auto 0.7rem; border-width: 2px; }
@media (max-width: 30rem) { .ballot { gap: 0.8rem; } .ballot .box { font-size: 1.8rem; } .ballot p { font-size: 1.15rem; } }

.ballot p, .steps strong, .steps p { font-variant-numeric: lining-nums proportional-nums; }

/* his video, right under the quote and portrait */
.hero-video { margin: clamp(2.5rem, 7vw, 3.5rem) auto 0; max-width: 46rem; }

/* the video's cover: a translucent navy veil with his logo and a big translucent green play button
   (assets/video.js hides it while the video plays) */
.video-frame { position: relative; }
.play-cover {
  position: absolute; inset: 0.5rem; display: grid; place-items: center; align-content: center; gap: clamp(0.6rem, 2vw, 1.1rem);
  border: 0; padding: 0; cursor: pointer; background: rgba(30, 49, 102, 0.18); transition: opacity 0.25s ease;
}
.play { width: clamp(3.5rem, 12vw, 6rem); height: clamp(3.5rem, 12vw, 6rem); display: block; transition: transform 0.2s ease; }
.play svg { display: block; width: 100%; height: 100%; }
.play circle { transition: fill-opacity 0.2s ease; }
.play-cover:hover .play { transform: scale(1.06); }
.play-cover:hover .play circle { fill-opacity: 0.72; }
.play-cover:focus-visible { outline: 3px solid var(--green); outline-offset: 2px; }
.video-frame.playing .play-cover { opacity: 0; pointer-events: none; }
/* while the video plays: his logo mark, small, in the top-right corner (like a broadcast mark) */
.video-bug { position: absolute; top: 1.1rem; right: 1.2rem; width: clamp(1.6rem, 4.5%, 2.4rem); height: auto;
  opacity: 0; transition: opacity 0.4s ease; pointer-events: none; z-index: 1; }
.video-frame.playing .video-bug { opacity: 0.85; }

.sections .chev-r { transition: transform 0.25s ease; }
.sections a.open .chev-r { transform: rotate(90deg); }

/* share his message, under the video: one click copies the link and a small pop-up confirms it */
.share { position: relative; margin: 1.2rem auto 0; text-align: center; }
.share-btn { display: inline-flex; align-items: center; gap: 0.55rem; background: none; border: 0; padding: 0.3rem 0.2rem; cursor: pointer;
  color: var(--navy); font-family: var(--serif); font-variant: all-small-caps; letter-spacing: 0.12em; font-size: 1.25rem; font-weight: 600; }
.share-btn:hover { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 0.25em; }
.share-btn:focus-visible { outline: 2px solid var(--green); outline-offset: 3px; }
.share-pop { position: absolute; left: 50%; bottom: calc(100% + 0.5rem); transform: translate(-50%, 0.3rem); margin: 0; white-space: nowrap;
  background: var(--navy); color: #fff; font-size: 1rem; padding: 0.5rem 0.9rem; border-bottom: 3px solid var(--green);
  opacity: 0; transition: opacity 0.2s ease, transform 0.2s ease; pointer-events: none; z-index: 3; }
.share-pop.on { opacity: 1; transform: translate(-50%, 0); }
.share-pop b { font-weight: 600; }
@media (max-width: 30rem) { .share-pop { white-space: normal; width: 86vw; text-align: center; } }
