/* Wyatt Beaulieu, Maine House District 60
   Palette: navy, cream, red, gold (local campaign / palm card) */

:root {
  --cream: #f6f1e6;
  --cream-deep: #ebe3d4;
  --navy: #14213d;
  --navy-mid: #1f3254;
  --red: #9b2335;
  --red-deep: #7a1c2a;
  --gold: #b8942e;
  --gold-bright: #d4af37;
  --white: #ffffff;
  --text: #1a1a1a;
  --text-muted: #3d4454;
  --focus: #d4af37;
  --radius: 10px;
  --radius-sm: 6px;
  --shadow: 0 8px 24px rgba(20, 33, 61, 0.12);
  --font-sans: "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, "Roboto", "Helvetica Neue", sans-serif;
  --font-serif: Georgia, "Times New Roman", serif;
  --max-width: 72rem;
  --header-height: 4rem;
}

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

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--text);
  background: linear-gradient(180deg, var(--cream) 0%, var(--cream-deep) 100%);
  min-height: 100vh;
}

.skip-link {
  position: absolute;
  left: -9999px;
  z-index: 1000;
  padding: 0.75rem 1rem;
  background: var(--navy);
  color: var(--cream);
  font-weight: 600;
  text-decoration: none;
  border-radius: var(--radius-sm);
}

.skip-link:focus {
  left: 1rem;
  top: 1rem;
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* ----- Header ----- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--navy);
  color: var(--cream);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.2);
}

.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0.75rem 1.25rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.brand {
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: 1.125rem;
  color: var(--cream);
  text-decoration: none;
  letter-spacing: 0.02em;
}

.brand:hover,
.brand:focus-visible {
  color: var(--gold-bright);
}

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

.nav-toggle {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 0.85rem;
  min-height: 44px;
  min-width: 44px;
  border: 2px solid rgba(246, 241, 230, 0.5);
  border-radius: var(--radius-sm);
  background: var(--navy-mid);
  color: var(--cream);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}

.nav-toggle:hover {
  border-color: var(--gold-bright);
}

.nav-toggle:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

.nav-toggle-bars {
  display: block;
  width: 1.25rem;
  height: 2px;
  background: currentColor;
  box-shadow: 0 -6px 0 currentColor, 0 6px 0 currentColor;
}

.site-nav {
  width: 100%;
  flex-basis: 100%;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.25s ease;
}

.site-nav.is-open {
  max-height: 24rem;
}

.nav-list {
  list-style: none;
  margin: 0;
  padding: 0.5rem 0 0;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.nav-link {
  display: block;
  padding: 0.75rem 0.5rem;
  min-height: 44px;
  color: var(--cream);
  text-decoration: none;
  font-weight: 600;
  border-radius: var(--radius-sm);
}

.nav-link:hover {
  background: rgba(255, 255, 255, 0.08);
}

.nav-link:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

.nav-link--cta {
  color: var(--gold-bright);
}

@media (min-width: 768px) {
  .nav-toggle {
    display: none;
  }

  .site-nav {
    width: auto;
    flex-basis: auto;
    max-height: none !important;
    overflow: visible;
  }

  .nav-list {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 0.25rem 0.5rem;
    padding: 0;
  }

  .nav-link {
    padding: 0.5rem 0.65rem;
  }
}

/* ----- Layout ----- */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.25rem;
}

.container.narrow {
  max-width: 42rem;
}

.section {
  padding: 3rem 0;
}

.section--alt {
  background: rgba(255, 255, 255, 0.55);
}

.section--highlight {
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-mid) 100%);
  color: var(--cream);
}

.section-intro {
  margin: 0 0 1.5rem;
  font-size: 1.05rem;
  color: var(--text-muted);
}

.section--highlight .section-intro,
.section--highlight p {
  color: rgba(246, 241, 230, 0.95);
}

h1,
h2,
h3 {
  font-family: var(--font-serif);
  line-height: 1.2;
  font-weight: 700;
}

h1 {
  font-size: clamp(2rem, 5vw, 2.75rem);
  margin: 0 0 1rem;
  color: var(--navy);
}

h2 {
  font-size: clamp(1.5rem, 3.5vw, 2rem);
  margin: 0 0 1rem;
  color: var(--navy);
}

.section--highlight h2 {
  color: var(--cream);
}

h3 {
  font-size: 1.25rem;
  margin: 0 0 0.5rem;
  color: var(--navy-mid);
}

/* ----- Hero ----- */
.hero {
  padding: 2.5rem 0 3rem;
  border-bottom: 4px solid var(--gold);
}

.hero-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.25rem;
  display: grid;
  gap: 2rem;
  align-items: center;
}

@media (min-width: 900px) {
  .hero-inner {
    grid-template-columns: 1.1fr 0.9fr;
    gap: 3rem;
  }
}

.eyebrow {
  margin: 0 0 0.75rem;
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--red);
}

.hero-sub {
  margin: 0 0 1.5rem;
  font-size: 1.125rem;
  color: var(--text-muted);
  max-width: 38ch;
}

.hero-actions {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

@media (min-width: 480px) {
  .hero-actions {
    flex-direction: row;
    flex-wrap: wrap;
  }
}

.hero-media {
  justify-self: center;
  width: 100%;
  max-width: 22rem;
}

.hero-photo {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: center top;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

/* ----- Buttons ----- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 48px;
  padding: 0.75rem 1.25rem;
  font: inherit;
  font-weight: 700;
  text-align: center;
  text-decoration: none;
  border-radius: var(--radius-sm);
  border: 2px solid transparent;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease, transform 0.1s ease;
}

.btn:active {
  transform: translateY(1px);
}

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

.btn--primary {
  background: var(--red);
  color: var(--white);
  border-color: var(--red-deep);
}

.btn--primary:hover {
  background: var(--red-deep);
}

.btn--outline {
  background: transparent;
  color: var(--navy);
  border-color: var(--navy);
}

.btn--outline:hover {
  background: var(--navy);
  color: var(--cream);
}

.btn--secondary {
  background: var(--navy);
  color: var(--cream);
  border-color: var(--navy);
}

.btn--secondary:hover {
  background: var(--navy-mid);
}

.btn--gold {
  background: linear-gradient(180deg, var(--gold-bright) 0%, var(--gold) 100%);
  color: var(--navy);
  border-color: #9a7a1f;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
}

.btn--gold:hover {
  filter: brightness(1.05);
}

.btn--large {
  min-height: 52px;
  padding: 0.85rem 1.35rem;
  font-size: 1rem;
}

.btn--xl {
  min-height: 56px;
  padding: 1rem 1.5rem;
  font-size: 1.0625rem;
  width: 100%;
  max-width: 26rem;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

/* ----- Clean Elections ----- */
.clean-elections {
  padding: 2.75rem 0;
}

.clean-elections-grid {
  display: grid;
  gap: 2rem;
  align-items: start;
}

@media (min-width: 900px) {
  .clean-elections-grid {
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: 2.5rem;
  }
}

.clean-elections-copy p {
  margin: 0 0 1rem;
}

.clean-elections-copy strong {
  color: var(--gold-bright);
  font-weight: 700;
}

.reassure {
  padding: 0.85rem 1rem;
  background: rgba(255, 255, 255, 0.08);
  border-left: 4px solid var(--gold-bright);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.fine-print {
  font-size: 0.9rem;
  opacity: 0.9;
  margin-bottom: 0 !important;
}

.clean-elections-cta {
  display: flex;
  justify-content: center;
  padding: 0.5rem 0;
}

@media (min-width: 900px) {
  .clean-elections-cta {
    justify-content: flex-end;
    padding: 0;
  }
}

/* ----- About ----- */
.about-grid {
  display: grid;
  gap: 2rem;
  align-items: start;
}

@media (min-width: 768px) {
  .about-grid {
    grid-template-columns: 1.2fr 1fr;
    align-items: center;
  }
}

.about-img {
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  display: block;
}

.about-text p {
  margin: 0 0 1rem;
}

.about-text p:last-child {
  margin-bottom: 0;
}

/* ----- Issues ----- */
.issues h2 {
  text-align: center;
}

.issues .section-intro {
  text-align: center;
  max-width: 36rem;
  margin-left: auto;
  margin-right: auto;
}

.issue-cards {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 1.25rem;
}

@media (min-width: 700px) {
  .issue-cards {
    grid-template-columns: repeat(3, 1fr);
  }
}

.issue-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 1.5rem 1.25rem;
  box-shadow: var(--shadow);
  border-top: 4px solid var(--red);
}

.issue-card p {
  margin: 0;
  font-size: 1rem;
  color: var(--text-muted);
}

/* ----- Representing ----- */
.representing p {
  margin: 0 0 1rem;
}

.pullquote {
  margin: 1.5rem 0 0;
  padding: 1.25rem 1.5rem;
  border-left: 4px solid var(--gold);
  background: rgba(255, 255, 255, 0.7);
  border-radius: 0 var(--radius) var(--radius) 0;
}

.pullquote p {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--navy);
  font-style: italic;
}

/* ----- Contact ----- */
.contact h2 {
  text-align: center;
}

.contact .section-intro {
  text-align: center;
  max-width: 40rem;
  margin-left: auto;
  margin-right: auto;
}

.contact-list {
  list-style: none;
  margin: 0 auto 1.5rem;
  padding: 0;
  max-width: 28rem;
}

.contact-list li {
  display: grid;
  grid-template-columns: 5.5rem 1fr;
  gap: 0.75rem;
  padding: 0.85rem 0;
  border-bottom: 1px solid rgba(20, 33, 61, 0.15);
  align-items: start;
}

.contact-label {
  font-weight: 700;
  color: var(--navy);
}

.contact-list a {
  color: var(--red);
  font-weight: 600;
  word-break: break-word;
}

.contact-list a:hover {
  text-decoration: underline;
}

.contact-list a:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

.contact-mailto {
  text-align: center;
  margin: 0;
}

/* ----- Footer ----- */
.site-footer {
  background: var(--navy);
  color: var(--cream);
  padding: 2rem 1.25rem;
  margin-top: auto;
}

.footer-inner {
  text-align: center;
}

.footer-authority {
  margin: 0 0 0.5rem;
  font-weight: 700;
  font-family: var(--font-serif);
}

.footer-disclaimer {
  margin: 0 0 0.75rem;
  font-size: 0.9rem;
  opacity: 0.9;
}

.footer-social a {
  color: var(--gold-bright);
  font-weight: 600;
}

.footer-social a:hover {
  text-decoration: underline;
}

.footer-social a:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}
