/* Campaign site template (based on Jesse Smith, Town Council D3).
   Per-candidate theme values are set in an inline :root block in index.html:
   --navy (primary), --red (accent), --on-accent, --accent-text, --tint, --accent-light, --shadow, --slab, --sans, --motif */
:root {
  --white: #ffffff;
  --cream: #f6f7fb;
  --ink: #1a1f2e;
  --muted: #5a6275;
  --radius: 6px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
  font-family: var(--sans);
  color: var(--ink);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; }

.container { width: min(1140px, 100% - 32px); margin-inline: auto; }
.center { text-align: center; }
.section { padding: 88px 0; }

h2 {
  font-family: var(--slab);
  font-weight: var(--heading-weight, 400);
  font-size: clamp(2rem, 4.5vw, 3rem);
  line-height: 1.1;
  color: var(--navy);
  margin-bottom: 20px;
}
h3 { font-family: var(--slab); font-weight: var(--heading-weight, 400); color: var(--navy); font-size: 1.3rem; margin-bottom: 8px; }

.kicker {
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .2em;
  font-size: .85rem;
  color: var(--accent-text);
  margin-bottom: 10px;
}
.kicker.light { color: var(--accent-light); }
.star { color: var(--red); }

/* ===== Buttons ===== */
.btn {
  display: inline-block;
  font-family: var(--sans);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .1em;
  text-decoration: none;
  padding: 14px 30px;
  border-radius: var(--radius);
  border: 2px solid transparent;
  cursor: pointer;
  font-size: .95rem;
  transition: transform .15s, background .15s, color .15s;
}
.btn:hover { transform: translateY(-2px); }
.btn-red { background: var(--red); color: var(--on-accent); }
.btn-red:hover { background: var(--red-dark); }
.btn-outline { border-color: var(--white); color: var(--white); }
.btn-outline:hover { background: var(--white); color: var(--navy); }
.btn-sm { padding: 8px 18px; font-size: .8rem; }

/* ===== Header ===== */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: var(--navy);
  border-bottom: 4px solid var(--red);
}
.nav-wrap { display: flex; align-items: center; justify-content: space-between; height: 70px; }
.brand { display: grid; grid-template-columns: auto 1fr; column-gap: 10px; text-decoration: none; color: var(--white); line-height: 1.1; }
.brand-star { grid-row: span 2; color: var(--red); font-size: 1.8rem; align-self: center; }
.brand-name { font-family: var(--slab); font-size: 1.35rem; }
.brand-sub { font-size: .7rem; text-transform: uppercase; letter-spacing: .15em; opacity: .8; }

.site-nav { display: flex; align-items: center; gap: 28px; }
.site-nav a:not(.btn) {
  color: var(--white); text-decoration: none; font-weight: 600;
  font-size: .95rem; position: relative;
}
.site-nav a:not(.btn)::after {
  content: ""; position: absolute; left: 0; bottom: -4px; height: 2px; width: 0;
  background: var(--red); transition: width .2s;
}
.site-nav a:not(.btn):hover::after { width: 100%; }

.nav-toggle { display: none; background: none; border: 0; cursor: pointer; padding: 8px; }
.nav-toggle span { display: block; width: 26px; height: 3px; background: var(--white); margin: 5px 0; border-radius: 2px; }

/* ===== Hero ===== */
.hero {
  position: relative;
  background:
    radial-gradient(circle at 80% 20%, rgba(255,255,255,.08), transparent 50%),
    var(--navy);
  color: var(--white);
  overflow: hidden;
}
.hero-grid {
  display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center;
  padding: 72px 0 96px;
}
.hero-copy { min-width: 0; }
.hero-name > span { white-space: nowrap; } /* lets the name-fit script measure the real column width */
.hero-title { width: fit-content; }
.eyebrow {
  font-weight: 800; letter-spacing: .5em; text-transform: uppercase; font-size: 1.1rem; margin-bottom: 8px;
  text-align: center;
  padding-left: .5em; /* balances the trailing letter-spacing so it centers true */
}
.hero-name { font-family: var(--slab); font-weight: var(--heading-weight, 400); line-height: .92; margin-bottom: 18px; text-transform: uppercase; }
.hero-name > span {
  display: block; font-size: calc(clamp(3.5rem, 9vw, 7rem) * var(--name-scale, 1)); color: var(--white);
  text-shadow: 4px 4px 0 var(--red);
  text-align: center;
}
.hero-name small {
  display: flex; align-items: center; gap: 14px;
  font-size: clamp(1rem, 2vw, 1.4rem); letter-spacing: .5em; color: var(--tint); margin: 10px 0;
}
.hero-name small::before, .hero-name small::after { content: ""; height: 3px; flex: 1; background: var(--red); }
.hero-name small .middle { padding-left: .5em; } /* balances trailing letter-spacing */
.hero-office {
  display: inline-block; font-family: var(--slab); font-size: clamp(1.2rem, 2.5vw, 1.7rem);
  background: var(--white); color: var(--navy); padding: 6px 16px; border-radius: 4px; margin-bottom: 22px;
}
.hero-lede { max-width: 520px; font-size: clamp(1.25rem, 2.4vw, 1.6rem); font-weight: 600; font-style: italic; margin-bottom: 30px; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }

.hero-photo { position: relative; }
.hero-photo::before {
  content: ""; position: absolute; inset: 18px -18px -18px 18px;
  border: 4px solid var(--red); border-radius: var(--radius);
}
.hero-photo img {
  position: relative; border-radius: var(--radius); border: 6px solid var(--white);
  box-shadow: 0 20px 50px rgba(0,0,0,.35); aspect-ratio: 1; object-fit: cover; width: 100%;
}
.stripe { height: 10px; background: linear-gradient(var(--red) 0 50%, var(--white) 50% 100%); }

/* ===== Date bar ===== */
.date-bar { background: var(--white); border-bottom: 1px solid #e3e6ef; }
.date-inner { display: flex; align-items: center; justify-content: center; gap: 16px; padding: 18px 0; flex-wrap: wrap; text-align: center; }
.date-inner p { font-weight: 600; color: var(--navy); }
.date-link { color: var(--accent-text); font-weight: 800; text-decoration: none; margin-left: 12px; }
.date-link:hover { text-decoration: underline; }

/* ===== About ===== */
.about { background: var(--cream); }
.about-grid { display: grid; grid-template-columns: .85fr 1.15fr; gap: 64px; align-items: center; }
.about-photo img {
  border-radius: var(--radius); box-shadow: var(--shadow);
  aspect-ratio: 4 / 5; object-fit: cover; object-position: center 70%; width: 100%;
  border-bottom: 8px solid var(--red);
}
.about-photo figcaption { font-size: .85rem; color: var(--muted); margin-top: 10px; text-align: center; font-style: italic; }
.about-copy p { margin-bottom: 16px; color: #333a4d; }
.about-copy .kicker { color: var(--accent-text); margin-bottom: 10px; }
.facts { list-style: none; margin-top: 24px; display: grid; gap: 12px; }
.facts li { padding-left: 30px; position: relative; }
.facts li::before { content: var(--motif); position: absolute; left: 0; color: var(--red); }
.facts strong { color: var(--navy); }

/* ===== Quote ===== */
.quote { background: var(--red); color: var(--on-accent); padding: 64px 0; text-align: center; }
.quote blockquote {
  font-family: var(--slab); font-size: clamp(1.4rem, 3vw, 2.1rem); line-height: 1.3;
  max-width: 860px; margin-inline: auto;
}
.quote cite { display: block; font-family: var(--sans); font-style: normal; font-weight: 600; font-size: 1rem; margin-top: 18px; letter-spacing: .1em; text-transform: uppercase; }

/* ===== Priorities ===== */
.section-lede { max-width: 680px; margin: 0 auto; text-align: center; color: var(--muted); font-size: 1.05rem; }
.card-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; margin-top: 40px; }
.card {
  background: var(--white); border: 1px solid #e3e6ef; border-top: 5px solid var(--navy);
  border-radius: var(--radius); padding: 30px 26px; transition: transform .2s, box-shadow .2s, border-color .2s;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-top-color: var(--red); }
.card-num {
  font-family: var(--slab); font-size: 2.4rem; line-height: 1; color: var(--red); margin-bottom: 12px;
}
.card p { color: var(--muted); font-size: .97rem; margin-bottom: 16px; }
.card-list { list-style: none; display: grid; gap: 8px; padding-top: 16px; border-top: 1px solid #e3e6ef; }
.card h3 + .card-list { border-top: 0; padding-top: 6px; } /* no description: points sit right under the title */
.card-list li { position: relative; padding-left: 24px; font-weight: 600; color: var(--ink); font-size: .95rem; }
.card-list li::before { content: var(--motif); position: absolute; left: 0; color: var(--red); font-size: .85rem; top: 1px; }

/* ===== Get Involved ===== */
.involved { background: var(--navy); color: var(--white); }
.involved h2 { color: var(--white); }
.involved-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }
.involved-copy > p { opacity: .9; margin-bottom: 26px; }
.signup { display: grid; gap: 14px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.signup label { display: grid; gap: 6px; font-size: .85rem; font-weight: 600; letter-spacing: .03em; }
.signup input[type="text"], .signup input[type="email"] {
  font: inherit; font-weight: 400; font-size: 1rem; padding: 12px 14px;
  border: 2px solid transparent; border-radius: var(--radius); background: var(--white); color: var(--ink);
}
.signup input:focus { outline: none; border-color: var(--red); }
.checks { border: 0; display: flex; flex-wrap: wrap; gap: 8px 20px; margin: 4px 0 8px; }
.checks legend { font-size: .85rem; font-weight: 600; margin-bottom: 8px; }
.checks label { display: flex; align-items: center; gap: 8px; font-weight: 400; font-size: .95rem; cursor: pointer; }
.checks input { accent-color: var(--red); width: 18px; height: 18px; }
.signup .btn { justify-self: start; }
.form-note { color: var(--accent-light); font-weight: 600; }
.hp-field { position: absolute; left: -9999px; }
.signup .btn:disabled { opacity: .6; cursor: wait; transform: none; }

.involved-sign img, .involved-sign svg {
  display: block; width: 100%; height: auto;
  border-radius: 4px; box-shadow: 0 25px 60px rgba(0,0,0,.4);
  transform: rotate(-2deg); transition: transform .3s;
}
.involved-sign img:hover, .involved-sign svg:hover { transform: rotate(0) scale(1.02); }
.sign-caption { text-align: center; margin-top: 22px; opacity: .8; font-style: italic; }

/* ===== Vote ===== */
.vote { background: var(--cream); padding: 64px 0; }
.vote-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.vote-item { background: var(--white); padding: 28px; border-radius: var(--radius); border-left: 6px solid var(--red); }
.vote-item p { color: var(--muted); margin-bottom: 12px; }
.vote-link { color: var(--accent-text); font-weight: 800; text-decoration: none; }
.vote-link:hover { text-decoration: underline; }

/* ===== Footer ===== */
.site-footer { background: var(--navy-dark); color: var(--tint); padding-top: 56px; border-top: 6px solid var(--red); }
.footer-grid { display: grid; grid-template-columns: 1fr auto; align-items: end; gap: 32px; padding-bottom: 56px; }
.footer-name { font-family: var(--slab); font-size: 2rem; color: var(--white); }
.footer-office { text-transform: uppercase; letter-spacing: .15em; font-size: .8rem; }
.footer-head { color: var(--white); font-weight: 800; text-transform: uppercase; letter-spacing: .15em; font-size: .8rem; margin-bottom: 8px; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { color: var(--white); text-decoration: underline; }

/* ===== Template variants ===== */
@media (min-width: 900px) { .card-grid.count-3 { grid-template-columns: repeat(3, 1fr); } }
.hero-grid.no-photo, .about-grid.no-photo { grid-template-columns: 1fr; }
.about-grid.no-photo .about-copy { max-width: 760px; margin-inline: auto; }
.involved-grid.no-sign { grid-template-columns: 1fr; max-width: 680px; }
.hero-name small.rule { display: block; height: 3px; background: var(--red); margin: 14px 0; }
.hero-name small.rule::before, .hero-name small.rule::after { display: none; }
.signup input[type="tel"] {
  font: inherit; font-weight: 400; font-size: 1rem; padding: 12px 14px;
  border: 2px solid transparent; border-radius: var(--radius); background: var(--white); color: var(--ink);
}
.disclaimer { border-top: 1px solid rgba(255,255,255,.12); padding: 18px 0 26px; font-size: .8rem; text-align: center; }
.disclaimer p { display: inline-block; border: 1px solid rgba(255,255,255,.35); padding: 6px 14px; }

/* ===== Responsive ===== */
@media (max-width: 900px) {
  .hero-grid, .about-grid, .involved-grid { grid-template-columns: 1fr; gap: 40px; }
  .hero-grid { padding: 48px 0 72px; }
  .hero-photo { max-width: 380px; width: calc(100% - 18px); margin-inline: auto; }
  .about-photo { max-width: 440px; margin-inline: auto; }
  .vote-grid { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  .nav-toggle { display: block; }
  .site-nav {
    position: absolute; top: 74px; left: 0; right: 0; flex-direction: column; gap: 0;
    background: var(--navy); border-bottom: 4px solid var(--red);
    max-height: 0; overflow: hidden; transition: max-height .3s;
  }
  .site-nav.open { max-height: 400px; }
  .site-nav a:not(.btn) { padding: 14px 0; width: 100%; text-align: center; border-top: 1px solid rgba(255,255,255,.1); }
  .site-nav .btn { margin: 14px 0 18px; }
}

@media (max-width: 560px) {
  .section { padding: 64px 0; }
  .card-grid, .field-row { grid-template-columns: 1fr; }
  .eyebrow { letter-spacing: .35em; }
  .hero-photo::before { inset: 12px -12px -12px 12px; }
  .footer-grid { grid-template-columns: 1fr; }
  .date-link { margin-left: 0; }
}

/* ===== Demo / preview banner ===== */
.demo-banner {
  background: #1a1f2e; color: #e8ebf2; text-align: center; font-size: .85rem;
  padding: 8px 16px; line-height: 1.4; position: relative; z-index: 60;
}
.demo-banner a { color: #fff; font-weight: 700; }

/* =====================================================================
   Style: modern (light, airy, rounded, sans-serif)
   ===================================================================== */
.style-modern { --radius: 16px; }
.style-modern .site-header { background: #fff; border-bottom: 1px solid #e6e9ee; }
.style-modern .brand { color: var(--ink); }
.style-modern .brand-name { color: var(--navy); }
.style-modern .brand-sub { color: var(--muted); opacity: 1; }
.style-modern .site-nav a:not(.btn) { color: var(--ink); }
.style-modern .nav-toggle span { background: var(--navy); }
.style-modern .btn { border-radius: 999px; text-transform: none; letter-spacing: 0; font-size: 1rem; }
.style-modern .btn-outline { border-color: var(--navy); color: var(--navy); }
.style-modern .btn-outline:hover { background: var(--navy); color: #fff; }

.style-modern .hero { background: color-mix(in srgb, var(--navy) 7%, #fff); color: var(--ink); }
.style-modern .hero-title { width: auto; }
.style-modern .eyebrow { text-align: left; padding-left: 0; letter-spacing: .22em; font-size: .9rem; color: var(--accent-text); }
.style-modern .eyebrow .star { display: none; }
.style-modern .hero-name { text-transform: none; line-height: 1; letter-spacing: -.02em; }
.style-modern .hero-name > span { text-align: left; color: var(--navy); text-shadow: none; }
.style-modern .hero-name small, .style-modern .hero-name small.rule { display: none; }
.style-modern .hero-office {
  background: var(--navy); color: #fff; border-radius: 999px; padding: 6px 18px;
  font-family: var(--sans); font-weight: 800; font-size: 1rem; margin-top: 8px;
}
.style-modern .hero-lede { font-style: normal; font-weight: 400; color: var(--muted); }
.style-modern .hero-photo::before {
  inset: auto; top: auto; left: auto; right: -22px; bottom: -22px; width: 72%; height: 72%;
  border: 0; border-radius: 32px; background: var(--red);
}
.style-modern .hero-photo img { border: 0; border-radius: 28px; box-shadow: 0 30px 60px rgba(0,0,0,.16); }
.style-modern .stripe { display: none; }
.style-modern .date-bar { background: var(--navy); border: 0; }
.style-modern .date-inner p { color: #fff; }
.style-modern .date-link { color: var(--accent-light); }
.style-modern .about { background: #fff; }
.style-modern .about-photo img { border-bottom: 0; border-radius: 24px; }
.style-modern .quote { background: var(--navy); color: #fff; }
.style-modern .priorities { background: color-mix(in srgb, var(--navy) 5%, #fff); }
.style-modern .card { border: 0; border-radius: 20px; box-shadow: 0 8px 30px rgba(0,0,0,.06); }
.style-modern .card:hover { border-top-color: transparent; }
.style-modern .card-num {
  display: inline-grid; place-items: center; width: 52px; height: 52px; border-radius: 14px;
  background: color-mix(in srgb, var(--red) 16%, #fff); color: var(--accent-text);
  font-family: var(--sans); font-weight: 800; font-size: 1.2rem;
}
.style-modern .signup input[type="text"], .style-modern .signup input[type="email"], .style-modern .signup input[type="tel"] { border-radius: 12px; }
.style-modern .involved-sign img, .style-modern .involved-sign svg { transform: none; border-radius: 16px; }
.style-modern .vote { background: #fff; }
.style-modern .vote-item { border-left: 0; border-radius: 20px; background: color-mix(in srgb, var(--navy) 6%, #fff); }
.style-modern .site-footer { border-top: 0; }

/* =====================================================================
   Style: hometown (warm serif, cream paper, arched photo)
   ===================================================================== */
body.style-hometown { background: #fbf8f1; }
.style-hometown .site-header { background: #fbf8f1; border-bottom: 3px double var(--navy); }
.style-hometown .brand { color: var(--navy); }
.style-hometown .brand-sub { color: var(--muted); opacity: 1; }
.style-hometown .site-nav a:not(.btn) { color: var(--ink); }
.style-hometown .nav-toggle span { background: var(--navy); }
.style-hometown .btn { border-radius: 2px; letter-spacing: .14em; font-size: .85rem; }
.style-hometown .btn-red { background: var(--navy); color: #fff; }
.style-hometown .btn-red:hover { background: var(--navy-dark); }
.style-hometown .involved .btn-red { background: var(--red); color: var(--on-accent); }
.style-hometown .involved .btn-red:hover { background: var(--red-dark); }
.style-hometown .btn-outline { border-color: var(--navy); color: var(--navy); }
.style-hometown .btn-outline:hover { background: var(--navy); color: #fff; }

.style-hometown .hero { background: #f5eedd; color: var(--ink); }
.style-hometown .hero-grid { grid-template-columns: .85fr 1.15fr; }
.style-hometown .hero-photo { order: -1; }
.style-hometown .eyebrow { color: var(--accent-text); letter-spacing: .35em; font-size: .95rem; }
.style-hometown .hero-name { text-transform: none; line-height: 1.02; }
.style-hometown .hero-name > span { color: var(--navy); text-shadow: none; }
.style-hometown .hero-name small { color: var(--accent-text); font-family: var(--sans); font-size: .85rem; letter-spacing: .35em; }
.style-hometown .hero-name small::before, .style-hometown .hero-name small::after { height: 1px; }
.style-hometown .hero-name small.rule { height: 1px; }
.style-hometown .hero-office {
  background: transparent; color: var(--navy); border-radius: 0; padding: 8px 2px;
  border-top: 1px solid var(--navy); border-bottom: 1px solid var(--navy); font-style: italic;
}
.style-hometown .hero-lede { color: var(--muted); font-weight: 400; }
.style-hometown .hero-photo::before { inset: -14px; border: 2px solid var(--red); border-radius: 999px 999px 8px 8px; }
.style-hometown .hero-photo img { border: 0; border-radius: 999px 999px 6px 6px; aspect-ratio: 4 / 5; box-shadow: none; }
.style-hometown .stripe { height: 7px; background: linear-gradient(var(--navy) 0 2px, transparent 2px 5px, var(--navy) 5px 7px); }
.style-hometown .date-bar { background: #fbf8f1; border-bottom-color: #e4dccb; }
.style-hometown .about { background: #fbf8f1; }
.style-hometown .about-photo img {
  border-bottom: 0; border-radius: 3px;
  box-shadow: 0 0 0 10px #fff, 0 0 0 11px #e4dccb, 0 24px 40px rgba(0,0,0,.12);
}
.style-hometown .quote { background: #f5eedd; color: var(--navy); border-block: 1px solid #e4dccb; }
.style-hometown .quote blockquote { font-style: italic; }
.style-hometown .quote cite { color: var(--accent-text); }
.style-hometown .priorities { background: #fbf8f1; }
.style-hometown .card { background: transparent; border: 0; border-top: 2px solid var(--navy); border-radius: 0; padding: 24px 4px 6px; }
.style-hometown .card:hover { transform: none; box-shadow: none; border-top-color: var(--red); }
.style-hometown .card-num { font-family: var(--sans); font-weight: 800; font-size: .95rem; letter-spacing: .25em; }
.style-hometown .card-list { border-top: 1px dashed #d8cfbb; }
.style-hometown .involved-sign img, .style-hometown .involved-sign svg { transform: rotate(1.5deg); border-radius: 2px; }
.style-hometown .vote { background: #f5eedd; }
.style-hometown .vote-item { background: #fffdf8; border-left: 0; border-top: 4px solid var(--red); border-radius: 2px; }

@media (max-width: 900px) {
  .style-hometown .hero-photo { order: 0; }
}
@media (max-width: 760px) {
  .style-modern .site-nav { background: #fff; border-bottom: 1px solid #e6e9ee; }
  .style-hometown .site-nav { background: #fbf8f1; border-bottom: 3px double var(--navy); }
  .style-modern .site-nav a:not(.btn), .style-hometown .site-nav a:not(.btn) { border-top-color: rgba(0,0,0,.08); }
}
@media (max-width: 560px) {
  .style-hometown .hero-photo::before { inset: -10px; }
  .style-modern .hero-photo::before { right: -12px; bottom: -12px; }
}
