/*
 * Safer Choices - Common Stylesheet
 * Save as: css/style.css
 */

:root {
  --navy: #163247;
  --navy-dark: #102638;
  --teal: #6f8d8a;
  --cream: #f5f2eb;
  --paper: #ffffff;
  --gold: #c7933d;
  --ink: #233647;
  --muted: #64727d;
  --line: #e7e2d8;
  --max-width: 1180px;
  --text-width: 930px;
}

/* ---------- Reset / base ---------- */

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Arial, Helvetica, sans-serif;
  line-height: 1.7;
}

a {
  color: inherit;
  text-decoration: none;
}

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

/* ---------- Header ---------- */
.site-logo {
    width: 250px;
    height: auto;
    display: block;
}

.site-header {
  background: #fff;
  border-bottom: 1px solid #ececec;
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-inner {
  max-width: var(--max-width);
  min-height: 82px;
  margin: 0 auto;
  padding: 0 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: max-content;
}

.brand-mark {
  width: 42px;
  height: 42px;
  position: relative;
}

.brand-mark span {
  position: absolute;
  display: block;
  width: 14px;
  height: 28px;
  background: var(--teal);
  border-radius: 100% 0 100% 0;
  transform-origin: bottom center;
}

.brand-mark .leaf-a {
  left: 14px;
  top: 1px;
  transform: rotate(42deg);
}

.brand-mark .leaf-b {
  left: 3px;
  top: 11px;
  transform: rotate(-24deg);
}

.brand-mark .leaf-c {
  left: 21px;
  top: 15px;
  transform: rotate(66deg);
}

.brand-name {
  color: var(--navy);
  font-size: 26px;
  font-weight: 700;
  letter-spacing: 1.6px;
  line-height: 1.05;
}

.brand-tagline {
  margin-top: 5px;
  color: #7e8b93;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 2px;
}

.nav-wrap {
  display: flex;
  align-items: center;
  gap: 28px;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 28px;
  font-size: 14px;
  font-weight: 600;
}

.main-nav a {
  padding: 28px 0;
  border-bottom: 2px solid transparent;
}

.main-nav a:hover,
.main-nav a:focus,
.main-nav a[aria-current="page"] {
  color: var(--gold);
  border-bottom-color: var(--gold);
}

.header-cta {
  padding: 18px 21px;
  background: var(--navy);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  line-height: 1.4;
  text-align: center;
  text-transform: uppercase;
}

/* ---------- General page layout ---------- */

.page-shell {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 28px;
}

.text-content {
  max-width: var(--text-width);
  margin: 62px auto 0;
  padding: 0 28px;
}

.text-content h1,
.text-content h2,
.text-content h3 {
  color: var(--navy);
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 500;
}

.text-content h1 {
  margin: 0 0 18px;
  font-size: clamp(42px, 5vw, 58px);
  line-height: 1.1;
}

.text-content h2 {
  margin: 45px 0 16px;
  font-size: 36px;
  line-height: 1.2;
}

.text-content h3 {
  margin: 36px 0 12px;
  font-size: 27px;
  line-height: 1.25;
}

.text-content p {
  margin: 0 0 24px;
  color: #314355;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 20px;
  line-height: 1.7;
}

.text-content ul,
.text-content ol {
  margin: 0 0 26px;
  padding-left: 28px;
  color: #314355;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 20px;
}

.text-content li {
  margin-bottom: 10px;
}

.eyebrow {
  margin: 0 0 18px;
  color: var(--navy-dark);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 4px;
  text-transform: uppercase;
}

.eyebrow::after,
.gold-rule {
  content: "";
  display: block;
  width: 48px;
  height: 3px;
  margin-top: 14px;
  background: var(--gold);
}

.gold-rule {
  margin: 22px 0 30px;
}

/* ---------- 4:3 page hero ---------- */

.page-hero {
  max-width: var(--max-width);
  margin: 44px auto 0;
  padding: 0 28px;
}

.hero-frame {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: #d8d9d5;
  box-shadow: 0 14px 40px rgba(28, 46, 59, 0.08);
}

.hero-frame > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(245, 242, 235, 0.72) 0%,
    rgba(245, 242, 235, 0.28) 48%,
    rgba(16, 38, 56, 0.06) 100%
  );
  pointer-events: none;
}

.hero-copy {
  position: absolute;
  left: 10%;
  top: 24%;
  z-index: 2;
  width: min(520px, 54%);
  color: var(--navy-dark);
}

.hero-copy h1 {
  margin: 0 0 18px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(42px, 6vw, 72px);
  font-weight: 500;
  letter-spacing: -1.5px;
  line-height: 0.98;
}

.hero-copy p {
  max-width: 500px;
  margin: 0;
  font-size: 18px;
  line-height: 1.55;
}

/* ---------- Article / information pages ---------- */

.article-header {
  max-width: var(--text-width);
  margin: 58px auto 30px;
  padding: 0 28px;
}

.article-header h1 {
  margin: 0 0 18px;
  color: var(--navy);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(42px, 6vw, 64px);
  font-weight: 500;
  line-height: 1.08;
}

.article-intro {
  color: var(--muted);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 22px;
  line-height: 1.6;
}

.article-meta {
  margin-top: 18px;
  color: var(--muted);
  font-size: 13px;
  letter-spacing: 0.5px;
}

.callout {
  margin: 36px 0;
  padding: 26px 30px;
  border-left: 4px solid var(--gold);
  background: var(--cream);
}

.callout-title {
  margin: 0 0 8px;
  color: var(--navy);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
}

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

/* ---------- Cards ---------- */

.card-grid {
  max-width: var(--max-width);
  margin: 48px auto;
  padding: 0 28px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
}

.card {
  padding: 30px;
  border: 1px solid var(--line);
  background: #fff;
}

.card h2,
.card h3 {
  margin-top: 0;
  color: var(--navy);
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 500;
}

.card a {
  color: var(--navy);
  font-weight: 700;
}

.card a:hover {
  color: var(--gold);
}

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

.site-footer {
  margin-top: 76px;
  background: var(--navy-dark);
  color: #dfe7eb;
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 34px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
  font-size: 13px;
}

.footer-brand {
  color: #fff;
  font-weight: 700;
  letter-spacing: 1.4px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 22px;
}

.footer-links a:hover {
  color: #fff;
}

/* ---------- Responsive ---------- */

@media (max-width: 900px) {
  .header-inner {
    flex-wrap: wrap;
    padding-top: 16px;
    padding-bottom: 16px;
  }

  .nav-wrap {
    width: 100%;
    justify-content: space-between;
  }

  .main-nav {
    gap: 18px;
    overflow-x: auto;
  }

  .main-nav a {
    padding: 10px 0;
  }

  .header-cta {
    display: none;
  }

  .page-hero {
    margin-top: 24px;
  }

  .hero-copy {
    left: 8%;
    top: 19%;
    width: 70%;
  }

  .hero-copy p {
    font-size: 16px;
  }

  .card-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 620px) {
  .brand-name {
    font-size: 21px;
  }

  .brand-tagline {
    font-size: 8px;
  }

  .page-hero,
  .text-content,
  .article-header,
  .card-grid {
    padding-left: 18px;
    padding-right: 18px;
  }

  .hero-copy {
    left: 8%;
    top: 15%;
    width: 78%;
  }

  .hero-copy h1 {
    font-size: 38px;
  }

  .hero-copy p {
    font-size: 14px;
  }

  .eyebrow {
    font-size: 11px;
  }

  .text-content {
    margin-top: 42px;
  }

  .text-content p,
  .text-content ul,
  .text-content ol {
    font-size: 18px;
  }

  .card-grid {
    grid-template-columns: 1fr;
  }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
  }
}
