/* ==========================================================================
   Sight Scotland Clone - Design Tokens & Base Styles
   ========================================================================== */
:root {
  --purple: #3c1053;
  --purple-dark: #2a0a3b;
  --teal: #00c7b1;
  --teal-dark: #00a997;
  --lime: #c4d600;
  --lime-hover: #b2c300;
  --white: #ffffff;
  --light-bg: #f8f9fa;
  --charcoal: #212529;
  --muted: #495057;
  --border-light: rgba(255, 255, 255, 0.22);
  --shadow-sm: 0 4px 14px rgba(24, 9, 36, 0.08);
  --shadow-md: 0 10px 28px rgba(24, 9, 36, 0.14);
  --radius-card: 1rem;
  --font-sans: "FSMe", "Lexend", "Nunito", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  --container-max: 1180px;
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--charcoal);
  background-color: var(--white);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: inherit;
}

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

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--lime);
  color: var(--charcoal);
  font-weight: 700;
  padding: 0.75rem 1.25rem;
  z-index: 2000;
  text-decoration: none;
}

.skip-link:focus {
  left: 1rem;
  top: 1rem;
  border-radius: 0.5rem;
}

.container {
  width: min(var(--container-max), calc(100% - 2.5rem));
  margin-inline: auto;
}

/* ==========================================================================
   Sticky Helpline Badge
   ========================================================================== */
.helpline-badge {
  position: fixed;
  right: 0;
  top: 42%;
  transform: translateY(-50%);
  z-index: 950;
  background-color: var(--teal);
  color: var(--purple-dark);
  text-decoration: none;
  padding: 0.85rem 1.15rem;
  border-radius: 0.85rem 0 0 0.85rem;
  box-shadow: var(--shadow-md);
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  max-width: 195px;
  transition: transform 0.2s ease, background-color 0.2s ease;
}

.helpline-badge:hover {
  background-color: #00d8c0;
  transform: translateY(-50%) translateX(-4px);
}

.helpline-label {
  font-size: 0.82rem;
  font-weight: 700;
  line-height: 1.25;
}

.helpline-number {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 1rem;
  font-weight: 800;
  color: var(--purple);
}

.icon-phone {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

/* ==========================================================================
   Header & Navigation
   ========================================================================== */
.site-header {
  background-color: var(--purple);
  color: var(--white);
  position: relative;
  z-index: 900;
}

.header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.15rem 0 0.9rem;
  gap: 1rem;
}

.brand-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  text-decoration: none;
  color: var(--white);
}

.eye-mark {
  width: 62px;
  height: 40px;
  flex-shrink: 0;
}

.brand-name {
  font-weight: 800;
  font-size: 1.25rem;
  line-height: 1.02;
  letter-spacing: -0.02em;
}

.header-utilities {
  display: flex;
  align-items: center;
  gap: 1.15rem;
}

.utility-link,
.utility-btn {
  background: none;
  border: none;
  color: var(--white);
  font-family: inherit;
  font-size: 0.92rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.35rem;
  transition: color 0.15s ease;
}

.utility-link:hover,
.utility-btn:hover {
  color: var(--teal);
  text-decoration: underline;
}

.cart-count {
  background-color: var(--teal);
  color: var(--purple-dark);
  font-size: 0.75rem;
  font-weight: 800;
  min-width: 1.25rem;
  height: 1.25rem;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 0.3rem;
}

.btn-donate {
  background-color: var(--lime);
  color: var(--charcoal);
  font-weight: 800;
  font-size: 0.95rem;
  text-decoration: none;
  padding: 0.5rem 1.2rem;
  border-radius: 999px;
  transition: background-color 0.2s ease, transform 0.15s ease;
  white-space: nowrap;
}

.btn-donate:hover {
  background-color: var(--lime-hover);
  transform: translateY(-1px);
}

/* Search Drawer */
.search-drawer {
  background-color: var(--purple-dark);
  padding: 1rem 0;
  border-top: 1px solid var(--border-light);
}

.search-form {
  display: flex;
  gap: 0.75rem;
  align-items: center;
}

.search-form input {
  flex: 1;
  padding: 0.7rem 1rem;
  border-radius: 999px;
  border: 2px solid transparent;
  font-family: inherit;
  font-size: 1rem;
}

.btn-search-submit {
  background-color: var(--teal);
  color: var(--purple-dark);
  border: none;
  border-radius: 999px;
  padding: 0.7rem 1.4rem;
  font-family: inherit;
  font-weight: 800;
  cursor: pointer;
}

.btn-search-close {
  background: none;
  border: none;
  color: var(--white);
  font-size: 1.75rem;
  line-height: 1;
  cursor: pointer;
  padding: 0 0.4rem;
}

/* Main Navigation */
.main-nav {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.nav-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1.75rem;
}

.nav-item {
  position: relative;
}

.nav-link {
  background: none;
  border: none;
  color: var(--white);
  font-family: inherit;
  font-size: 1rem;
  font-weight: 700;
  text-decoration: none;
  padding: 0.85rem 0;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  cursor: pointer;
  border-bottom: 3px solid transparent;
  transition: border-color 0.2s ease, color 0.2s ease;
}

.nav-link:hover,
.nav-item.open > .nav-link {
  color: var(--teal);
  border-bottom-color: var(--teal);
}

.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 270px;
  background-color: var(--white);
  color: var(--purple);
  list-style: none;
  margin: 0;
  padding: 0.5rem 0;
  border-radius: 0 0 0.75rem 0.75rem;
  box-shadow: var(--shadow-md);
  display: none;
  z-index: 950;
}

.nav-item.has-dropdown:hover > .dropdown-menu,
.nav-item.has-dropdown.open > .dropdown-menu {
  display: block;
}

.dropdown-menu a {
  display: block;
  padding: 0.6rem 1.15rem;
  text-decoration: none;
  font-size: 0.94rem;
  font-weight: 600;
  color: var(--purple);
  transition: background-color 0.15s ease;
}

.dropdown-menu a:hover {
  background-color: #eefbf9;
  text-decoration: underline;
}

.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.35rem;
  flex-direction: column;
  gap: 5px;
}

.mobile-menu-toggle span {
  display: block;
  width: 24px;
  height: 3px;
  background: var(--white);
  border-radius: 2px;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero-section {
  background-color: var(--purple);
  color: var(--white);
  position: relative;
  padding: 2.5rem 0 4.5rem;
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  align-items: center;
  gap: 2.5rem;
  position: relative;
  z-index: 2;
}

.hero-content h1 {
  font-size: clamp(2.1rem, 4vw, 2.85rem);
  font-weight: 800;
  line-height: 1.14;
  margin: 0;
  max-width: 15ch;
}

.hero-media {
  display: flex;
  justify-content: flex-end;
}

.hero-image-frame {
  position: relative;
  width: min(460px, 100%);
  aspect-ratio: 4 / 3;
  border-radius: 65% 35% 42% 58% / 55% 45% 55% 45%;
  overflow: hidden;
  border-left: 14px solid var(--lime);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.28);
  background-color: var(--purple-dark);
}

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

.hero-wave {
  position: absolute;
  bottom: -1px;
  left: 0;
  width: 100%;
  height: 72px;
  pointer-events: none;
}

/* ==========================================================================
   Urgent Callout Banner
   ========================================================================== */
.callout-section {
  padding: 2.25rem 0 3.25rem;
  background-color: var(--white);
}

.callout-card {
  position: relative;
  background-color: var(--purple);
  color: var(--white);
  border-radius: var(--radius-card);
  padding: 3rem 2.5rem;
  box-shadow: var(--shadow-md);
  overflow: hidden;
  text-align: center;
}

.callout-arc {
  position: absolute;
  width: 135px;
  height: 135px;
  pointer-events: none;
}

.callout-arc-tr {
  top: 0;
  right: 0;
}

.callout-arc-bl {
  bottom: 0;
  left: 0;
}

.callout-content {
  position: relative;
  z-index: 2;
  max-width: 720px;
  margin-inline: auto;
}

.callout-content h2 {
  margin: 0 0 0.85rem;
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  font-weight: 800;
}

.callout-content p {
  margin: 0 auto 1.6rem;
  font-size: 1.12rem;
  max-width: 58ch;
  color: rgba(255, 255, 255, 0.94);
}

.btn-callout {
  display: inline-block;
  background-color: var(--white);
  color: var(--purple);
  font-weight: 800;
  font-size: 1rem;
  text-decoration: none;
  padding: 0.85rem 1.75rem;
  border-radius: 999px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.18s ease, background-color 0.18s ease;
}

.btn-callout:hover {
  background-color: var(--lime);
  color: var(--charcoal);
  transform: translateY(-2px);
}

/* ==========================================================================
   Quick Pathways / Guidance Band
   ========================================================================== */
.pathways-section {
  background-color: var(--teal);
  padding: 3.25rem 0;
}

.pathways-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.75rem 2.25rem;
}

.pathway-pill {
  position: relative;
  display: flex;
  align-items: center;
  gap: 1.15rem;
  background-color: var(--white);
  border-radius: 999px;
  padding: 1.15rem 1.75rem 1.15rem 1.25rem;
  text-decoration: none;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.pathway-pill:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.pathway-pill-centered {
  grid-column: 1 / -1;
  max-width: 540px;
  width: 100%;
  justify-self: center;
}

.pathway-icon {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background-color: var(--purple);
  color: var(--teal);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.pathway-icon svg {
  width: 26px;
  height: 26px;
}

.pathway-text {
  color: var(--purple);
  font-weight: 700;
  font-size: 1.03rem;
  text-decoration: underline;
  text-underline-offset: 3px;
  line-height: 1.38;
}

/* ==========================================================================
   Shared Section Headings & 3-Column Card Grids
   ========================================================================== */
.section-heading {
  text-align: center;
  color: var(--purple);
  font-size: clamp(1.85rem, 3vw, 2.3rem);
  font-weight: 800;
  margin: 0 0 2.5rem;
}

.cards-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.85rem;
}

/* Teal Wave Cards (What we do & Policy and Campaigns) */
.what-we-do-section,
.campaigns-section {
  padding: 4rem 0;
  background-color: var(--white);
}

.teal-wave-card {
  background-color: var(--teal);
  border-radius: var(--radius-card);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.teal-wave-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.card-media {
  position: relative;
  height: 225px;
  background-color: #e9ecef;
  overflow: hidden;
}

.card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.concave-cut {
  position: absolute;
  bottom: -1px;
  left: 0;
  width: 100%;
  height: 30px;
  pointer-events: none;
}

.card-body-teal {
  padding: 1.1rem 1.5rem 1.75rem;
  color: var(--purple-dark);
  flex: 1;
}

.card-body-teal h3 {
  margin: 0 0 0.65rem;
  font-size: 1.35rem;
  font-weight: 800;
  line-height: 1.25;
}

.card-body-teal h3 a {
  color: var(--purple);
  text-decoration: none;
}

.card-body-teal h3 a:hover {
  text-decoration: underline;
}

.card-body-teal p {
  margin: 0;
  font-size: 1rem;
  line-height: 1.52;
  color: #162426;
}

/* ==========================================================================
   Latest News Section
   ========================================================================== */
.news-section {
  position: relative;
  background-color: var(--teal);
  padding: 4rem 0;
  overflow: hidden;
}

.watermark-arcs {
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 240px;
  height: 480px;
  pointer-events: none;
}

.news-container {
  position: relative;
  z-index: 2;
}

.news-card {
  background-color: var(--white);
  border-radius: var(--radius-card);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.news-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.news-card-media {
  height: 220px;
  overflow: hidden;
  background-color: #e9ecef;
}

.news-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.news-card-body {
  padding: 1.5rem;
  flex: 1;
}

.news-card-body h3 {
  margin: 0 0 0.75rem;
  font-size: 1.28rem;
  font-weight: 800;
  line-height: 1.3;
}

.news-card-body h3 a {
  color: var(--purple);
  text-decoration: none;
}

.news-card-body h3 a:hover {
  text-decoration: underline;
}

.news-card-body p {
  margin: 0;
  font-size: 0.98rem;
  color: var(--charcoal);
}

/* ==========================================================================
   Newsletter Section
   ========================================================================== */
.newsletter-section {
  background-color: var(--teal);
  padding: 3.75rem 0;
}

.newsletter-container {
  max-width: 780px;
}

.newsletter-container h3 {
  text-align: center;
  color: var(--purple);
  font-size: clamp(1.5rem, 2.5vw, 1.9rem);
  font-weight: 800;
  margin: 0 0 1.75rem;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.15rem 1.5rem;
  margin-bottom: 1.25rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.form-group label {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--purple-dark);
}

.required {
  color: #8b0000;
}

.form-group input {
  padding: 0.75rem 0.95rem;
  border: 2px solid transparent;
  border-radius: 0.5rem;
  font-family: inherit;
  font-size: 1rem;
  background-color: var(--white);
  color: var(--charcoal);
}

.form-group input.input-error {
  border-color: #b00020;
}

.form-checkbox {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  margin-bottom: 1rem;
}

.form-checkbox input {
  width: 20px;
  height: 20px;
  margin-top: 2px;
  accent-color: var(--purple);
  flex-shrink: 0;
}

.form-checkbox label {
  font-weight: 700;
  font-size: 0.96rem;
  color: var(--purple-dark);
}

.privacy-note {
  font-size: 0.9rem;
  color: #162426;
  margin: 0 0 1.25rem;
}

.privacy-note a {
  color: var(--purple);
  font-weight: 700;
}

.form-feedback {
  min-height: 1.35rem;
  margin-bottom: 0.85rem;
  font-weight: 700;
  font-size: 0.96rem;
}

.form-feedback.error {
  color: #7d0017;
}

.form-feedback.success {
  color: var(--purple-dark);
  background: rgba(255, 255, 255, 0.85);
  padding: 0.65rem 1rem;
  border-radius: 0.5rem;
}

.btn-submit {
  display: inline-block;
  background-color: var(--purple);
  color: var(--white);
  border: none;
  border-radius: 999px;
  padding: 0.8rem 2.2rem;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 800;
  cursor: pointer;
  transition: background-color 0.2s ease, transform 0.15s ease;
}

.btn-submit:hover {
  background-color: var(--purple-dark);
  transform: translateY(-1px);
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
  background-color: var(--purple);
  color: var(--white);
  padding: 3rem 0 2.5rem;
}

.footer-brand {
  margin-bottom: 1.5rem;
}

.footer-divider {
  border: 0;
  border-top: 1px solid var(--border-light);
  margin: 1.5rem 0;
}

.footer-nav-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 1.75rem;
}

.footer-col h4 {
  margin: 0 0 0.85rem;
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--white);
}

.footer-col ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.footer-col a {
  text-decoration: none;
  font-size: 0.92rem;
  color: rgba(255, 255, 255, 0.88);
}

.footer-col a:hover {
  color: var(--teal);
  text-decoration: underline;
}

.footer-social-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.social-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.25rem;
}

.follow-label {
  font-weight: 700;
}

.social-links a {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.94rem;
}

.social-links a:hover {
  color: var(--teal);
  text-decoration: underline;
}

.accreditations {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.accreditations img {
  max-height: 54px;
  width: auto;
  object-fit: contain;
}

.legal-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
  font-size: 0.88rem;
  margin-bottom: 1.25rem;
}

.legal-links a {
  text-decoration: none;
  color: rgba(255, 255, 255, 0.9);
  position: relative;
}

.legal-links a:not(:last-child)::after {
  content: "|";
  margin-left: 1.25rem;
  color: rgba(255, 255, 255, 0.35);
}

.legal-links a:hover {
  color: var(--teal);
  text-decoration: underline;
}

.charity-note {
  margin: 0;
  font-size: 0.86rem;
  color: rgba(255, 255, 255, 0.82);
}

/* ==========================================================================
   Donate Modal
   ========================================================================== */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background-color: rgba(24, 9, 36, 0.72);
  display: grid;
  place-items: center;
  padding: 1.25rem;
  z-index: 1500;
}

.modal-backdrop[hidden] {
  display: none;
}

.modal-card {
  background-color: var(--white);
  color: var(--charcoal);
  border-radius: var(--radius-card);
  max-width: 460px;
  width: 100%;
  padding: 2rem;
  position: relative;
  box-shadow: var(--shadow-md);
  text-align: center;
}

.modal-card h2 {
  margin: 0 0 0.5rem;
  color: var(--purple);
}

.modal-close {
  position: absolute;
  top: 0.85rem;
  right: 1rem;
  background: none;
  border: none;
  font-size: 1.75rem;
  cursor: pointer;
  color: var(--purple);
}

.donation-amounts {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.65rem;
  margin: 1.25rem 0;
}

.amount-btn {
  padding: 0.7rem 0.5rem;
  border: 2px solid var(--purple);
  background: var(--white);
  color: var(--purple);
  font-family: inherit;
  font-weight: 800;
  font-size: 1rem;
  border-radius: 0.5rem;
  cursor: pointer;
}

.amount-btn.active {
  background-color: var(--purple);
  color: var(--white);
}

/* ==========================================================================
   Responsive Breakpoints
   ========================================================================== */
@media (max-width: 980px) {
  .cards-grid-3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .footer-nav-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .hero-grid {
    grid-template-columns: 1fr;
    text-align: left;
  }

  .hero-media {
    justify-content: flex-start;
  }
}

@media (max-width: 768px) {
  .utility-link {
    display: none;
  }

  .mobile-menu-toggle {
    display: flex;
  }

  .main-nav {
    display: none;
  }

  .main-nav.is-open {
    display: block;
    padding-bottom: 1rem;
  }

  .nav-list {
    flex-direction: column;
    gap: 0;
  }

  .dropdown-menu {
    position: static;
    box-shadow: none;
    background-color: rgba(255, 255, 255, 0.08);
    border-radius: 0.5rem;
  }

  .dropdown-menu a {
    color: var(--white);
  }

  .dropdown-menu a:hover {
    background-color: rgba(255, 255, 255, 0.14);
  }

  .pathways-grid,
  .cards-grid-3,
  .form-grid,
  .footer-nav-grid {
    grid-template-columns: 1fr;
  }

  .pathway-pill {
    border-radius: 1.25rem;
  }

  .helpline-badge {
    top: auto;
    bottom: 1rem;
    transform: none;
    border-radius: 0.85rem 0 0 0.85rem;
  }

  .helpline-badge:hover {
    transform: translateX(-4px);
  }
}
