/* ==========================================================================
   Stranraer Skills Station — single stylesheet
   Fonts are system Arial/Helvetica (as the original theme), so nothing is
   downloaded at runtime and there are no external requests.
   ========================================================================== */

:root {
  /* Brand */
  --purple:        #7f1494;
  --purple-dark:   #631073;
  --purple-darker: #4f0c5c;
  --green:         #9cbd39;
  --green-alt:     #a3c835;
  --blue-soft:     rgba(126, 215, 245, 0.9);

  /* Content */
  --bg:         #fff;
  --bg-alt:     #f5f5f5;
  --border:     #e8e8e8;
  --heading:    #1a1a1a;
  --text:       #333;
  --faded:      #999;
  --link:       #e95095;
  --link-hover: #7049ba;

  /* Typography */
  --font: Arial, Helvetica, sans-serif;
  --font-size: 19px;
  --line-height: 26px;

  /* Layout */
  --content-width: 1300px;
  --padding-inline: 2.5rem;
  --section-pad: 4rem;
  --radius: 0.3rem;
  --shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
}

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

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: var(--font-size);
  line-height: var(--line-height);
  -webkit-font-smoothing: antialiased;
}

img, svg, video { max-width: 100%; height: auto; }
img { border: 0; }

a { color: var(--link); text-decoration: none; }
a:hover, a:focus { color: var(--link-hover); text-decoration: underline; }

h1, h2, h3, h4, h5, h6 {
  margin: 0 0 0.6em;
  color: var(--heading);
  font-family: var(--font);
  line-height: 1.2;
}
h1 { font-size: max(3rem, 3vw); font-weight: 600; }
h2 { font-size: max(1.8rem, 1.8vw); font-weight: 400; }
h3 { font-size: max(1.4rem, 1.4vw); font-weight: 400; }
h4 { font-size: max(1.2rem, 1.2vw); font-weight: 400; }
h5 { font-size: max(1.1rem, 1.1vw); font-weight: 400; }
h6 { font-size: max(1rem, 1vw);     font-weight: 400; }

p { margin: 0 0 1.5rem; }
p:last-child { margin-bottom: 0; }

ul, ol { margin: 0 0 1.5rem; padding-left: 1.4em; }
li { margin-bottom: 0.4em; }

hr { border: 0; border-top: 1px solid var(--border); margin: 3rem 0; }

:focus-visible { outline: 2px solid var(--purple); outline-offset: 2px; }

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 999;
  background: var(--purple-dark); color: #fff; padding: 0.75rem 1.25rem;
}
.skip-link:focus { left: 0; color: #fff; }

.icon { width: 1em; height: 1em; display: inline-block; vertical-align: -0.125em; fill: currentColor; }

.wrap { width: 100%; max-width: var(--content-width); margin: 0 auto; }

/* --------------------------------------------------------------- sections */

.section {
  position: relative;
  padding: var(--section-pad) var(--padding-inline);
}
.section-purple { background: var(--purple-dark); color: #fff; }
.section-green  { background: var(--green); color: #000; }
.section-alt    { background: var(--bg-alt); }
.section-topline { border-top: 1px solid var(--border); }

.section-purple h1, .section-purple h2, .section-purple h3, .section-purple h4,
.section-green  h1, .section-green  h2, .section-green  h3, .section-green  h4 { color: inherit; }
.section-purple a { color: #fff; text-decoration: underline; }
.section-purple a:hover { color: #fff; }

.section-narrow { max-width: 900px; margin: 0 auto; }
.text-center { text-align: center; }

.cols { display: grid; gap: 2.5rem; align-items: start; }
.cols-2 { grid-template-columns: 1fr 1fr; }
.cols-2-wide { grid-template-columns: 2fr 1fr; }
.cols-2-narrow { grid-template-columns: 1fr 2fr; }
.cols-3 { grid-template-columns: repeat(3, 1fr); }

/* ---------------------------------------------------------------- buttons */

.btn {
  display: inline-flex; align-items: center; gap: 0.6em;
  padding: 1em 2.2em;
  border: 1px solid #9417ac;
  border-radius: 1.5em;
  background: linear-gradient(180deg, var(--purple), var(--purple-dark));
  color: #fff !important;
  font-size: 16px; font-weight: 700; line-height: 1.2;
  letter-spacing: 0.05em; text-transform: uppercase; text-decoration: none;
  transition: background 0.3s ease, box-shadow 0.3s ease;
  cursor: pointer;
}
.btn:hover, .btn:focus {
  background: linear-gradient(180deg, var(--purple-dark), var(--purple-dark));
  text-decoration: none;
}
.btn .icon { width: 1.1em; height: 1.1em; }

/* ----------------------------------------------------------------- header */

.site-header { position: relative; z-index: 50; }

.header-middle { background: #fff; box-shadow: 0 3px 5px -1px rgba(0,0,0,0.1); }
.header-middle-h {
  display: flex; align-items: center; justify-content: space-between;
  gap: 2rem; min-height: 120px; padding: 0.75rem var(--padding-inline);
}
.header-brand { display: flex; align-items: center; gap: 1.5rem; }
.header-logo img { width: 255px; height: auto; display: block; }
.header-badge { width: 150px; height: auto; display: block; }

.header-contact { display: flex; gap: 1rem; }
.contact-card {
  display: flex; align-items: center; gap: 1rem;
  padding: 0.9rem 1.4rem;
  background: var(--bg-alt); border-radius: var(--radius);
  color: var(--text); text-decoration: none;
}
.contact-card:hover { color: var(--text); text-decoration: none; background: #ececec; }
.contact-card-icon { color: var(--purple-dark); font-size: 1.6rem; display: flex; }
.contact-card-text { display: flex; flex-direction: column; line-height: 1.25; }
.contact-card-label { font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.02em; }
.contact-card-value { font-size: 0.95rem; font-weight: 700; color: var(--purple-dark); }

.header-bottom { background: var(--purple-dark); color: #fff; }

/* Sticky nav: site.js adds .is-stuck once the strip reaches the top of the
   viewport, and sets --nav-height on the spacer so the page does not jump. */
.header-bottom.is-stuck {
  position: fixed; top: 0; left: 0; right: 0; z-index: 60;
  box-shadow: 0 3px 5px -1px rgba(0, 0, 0, 0.2);
}
.header-bottom-spacer { height: 0; }
.header-bottom.is-stuck + .header-bottom-spacer { height: var(--nav-height, 80px); }

.header-bottom-h {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1.5rem; padding: 0 var(--padding-inline);
}

.site-nav { flex: 1 1 auto; }
.nav-list { display: flex; align-items: stretch; gap: 0; margin: 0; padding: 0; list-style: none; }
.nav-item { margin: 0; }
.nav-item > a {
  display: flex; align-items: center; height: 80px;
  padding: 0 0.9rem;
  color: #fff; font-size: 19px; font-weight: 700; text-decoration: none;
  transition: background 0.2s ease, color 0.2s ease;
}
.nav-item > a:hover, .nav-item > a:focus {
  background: var(--green); color: var(--purple-dark);
  text-decoration: underline;
  text-underline-offset: 0.25em;
  text-decoration-thickness: 2px;
}
.nav-item.is-current > a { background: var(--green); color: var(--purple-dark); }

.header-socials { display: flex; align-items: center; gap: 1.1rem; }
.header-socials a { color: #fff; font-size: 1.5rem; display: flex; }
.header-socials a:hover { color: #fff; opacity: 0.75; }

.nav-toggle {
  display: none; align-items: center; gap: 0.6rem;
  background: none; border: 0; padding: 0.5rem;
  color: var(--heading); font: inherit; cursor: pointer;
}
.nav-toggle-bars { display: inline-flex; flex-direction: column; gap: 5px; width: 28px; }
.nav-toggle-bars span { display: block; height: 3px; background: currentColor; border-radius: 2px; }
.nav-close { display: none; }

/* ------------------------------------------------------------- page hero */

.page-hero { position: relative; padding: clamp(3rem, 6vmax, 7rem) var(--padding-inline); overflow: hidden; }
.page-hero-img {
  position: absolute; inset: 0;
  background-position: center center; background-size: cover; background-repeat: no-repeat;
}
.page-hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(90deg, #ffffff, rgba(255,255,255,0));
}
.page-hero-h { position: relative; }
.page-hero h1 { color: var(--purple-dark); margin: 0; font-weight: 700; }

.breadcrumbs {
  display: flex; align-items: center; gap: 0.5rem;
  margin-bottom: 0.75rem; color: var(--purple-dark); font-size: 1rem;
}
.breadcrumbs a { color: var(--purple-dark); }
.breadcrumbs a:hover { color: var(--link-hover); }
.breadcrumbs-sep { display: flex; font-size: 0.8em; }

/* --------------------------------------------------------------- home page */

.home-hero { position: relative; padding: var(--section-pad) var(--padding-inline); overflow: hidden; }
.home-hero-img {
  position: absolute; inset: 0;
  background: url('images/newslider2.jpg') top center / cover no-repeat;
}
.home-hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(90deg, #ffffff 35%, rgba(255,255,255,0) 100%);
}
.home-hero-h { position: relative; max-width: 620px; }
.home-hero .eyebrow {
  margin: 0 0 0.4rem; color: var(--purple-dark);
  font-weight: 700; text-transform: uppercase; letter-spacing: 0.02em; font-size: 1rem;
}
.home-hero h1 { color: var(--purple); font-weight: 700; margin-bottom: 1.5rem; }

.callout-green {
  background: var(--green); color: var(--link-hover);
  padding: 1.5rem; border-radius: var(--radius);
}
.callout-green :where(h1,h2,h3,h4) { color: inherit; }
.callout-blue { background: var(--blue-soft); color: var(--text); padding: 1.5rem; }

.home-flyers { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; margin-top: 2.5rem; }
.home-flyers video { width: 100%; height: auto; aspect-ratio: 16 / 9; display: block; border-radius: var(--radius); background: #000; }

/* Partner logo carousel */
.partners { position: relative; margin-top: 2rem; }
.partners-track {
  display: flex; align-items: center; gap: 2.5rem;
  overflow-x: auto; scroll-behavior: smooth;
  scroll-snap-type: x mandatory;
  padding: 1rem 0; margin: 0 3rem;
  scrollbar-width: none;
}
.partners-track::-webkit-scrollbar { display: none; }
.partners-track img {
  flex: 0 0 auto; max-height: 90px; width: auto; scroll-snap-align: start;
}
.partners-btn {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 2.5rem; height: 2.5rem;
  display: flex; align-items: center; justify-content: center;
  background: none; border: 0; cursor: pointer;
  color: var(--text); font-size: 1.5rem; line-height: 1;
}
.partners-btn:hover { color: var(--purple); }
.partners-prev { left: 0; }
.partners-next { right: 0; }

/* ------------------------------------------------------------- about page */

.motto { text-align: center; margin: 2.5rem 0; }
.motto-title { color: var(--purple); font-weight: 700; font-size: 2rem; margin-bottom: 0.3rem; }
.motto-text {
  color: var(--purple); font-size: 2.5rem; line-height: 1.3;
  margin: 0; font-family: var(--font);
}

.director-card { padding: 2rem; text-align: center; }
.director-card.is-green  { background: var(--green);       color: var(--link-hover); }
.director-card.is-purple { background: var(--purple-dark); color: #fff; }
.director-card img {
  width: 180px; height: 180px; border-radius: 50%; object-fit: cover;
  display: block; margin: 0 auto 1.5rem;
}
.director-card .director-name { font-weight: 700; margin-bottom: 0.5rem; }

.report-links { display: grid; grid-template-columns: auto repeat(3, 1fr); gap: 2rem; align-items: center; }
.report-links img { width: 100px; }
.report-link { text-align: center; }
.report-link p { font-size: 1.4rem; margin-bottom: 1rem; }

/* --------------------------------------------------------- meet the team */

.volunteers {
  position: relative;
  padding: 6rem var(--padding-inline);
  background: url('images/volunteers-background.jpg') center center / cover no-repeat;
}
.volunteers-box { max-width: 640px; text-align: center; }

.team-member {
  display: grid; grid-template-columns: 320px 1fr; gap: 2.5rem;
  padding: 3rem 0; border-top: 1px solid var(--border);
}
.team-member:first-of-type { border-top: 0; }
.team-photo { text-align: center; }
.team-photo img {
  width: 260px; height: 260px; border-radius: 50%; object-fit: cover;
  display: block; margin: 0 auto 1rem;
}
.team-contact { font-size: 1rem; line-height: 1.7; }
.team-contact a { display: block; color: var(--link); }
.team-contact .icon { margin-right: 0.4em; }
.team-body h3 { margin-bottom: 0.3em; }
.team-role { font-weight: 700; margin-bottom: 0.8rem; }
.team-fun { font-weight: 700; margin-bottom: 0.5rem; }

/* ---------------------------------------------------------------- gallery */

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 12px;
}
.gallery-grid a { display: block; }
.gallery-grid img {
  width: 100%; height: 100%; aspect-ratio: 1 / 1; object-fit: cover;
  display: block; border-radius: 6px;
}

.lightbox {
  position: fixed; inset: 0; z-index: 200;
  display: none; align-items: center; justify-content: center;
  background: rgba(0, 0, 0, 0.9);
}
.lightbox.is-open { display: flex; }
.lightbox img { max-width: 92vw; max-height: 88vh; border-radius: 4px; }
.lightbox button {
  position: absolute; background: none; border: 0; color: #fff;
  font-size: 2.5rem; line-height: 1; cursor: pointer; padding: 1rem;
}
.lightbox-close { top: 0.5rem; right: 1rem; }
.lightbox-prev  { left: 0.5rem; top: 50%; transform: translateY(-50%); }
.lightbox-next  { right: 0.5rem; top: 50%; transform: translateY(-50%); }

/* --------------------------------------------------------------- reviews */

.reviews-list { display: grid; gap: 1.5rem; margin-top: 2.5rem; }
.review-card {
  padding: 2rem;
  border: 2px solid var(--border);
  border-radius: var(--radius);
  transition: border-color 0.3s ease;
}
.review-card:hover { border-color: var(--purple); }
.review-stars { display: flex; gap: 0.2rem; margin: 0 0 0.75rem; color: var(--purple); }
.review-star svg { width: 1.1em; height: 1.1em; display: block; }
.review-quote > p:last-child { margin-bottom: 0; }
.review-by { margin: 1rem 0 0; line-height: 1.5; }
.review-author { display: block; font-weight: 700; }
.review-role { display: block; color: var(--faded); font-size: 0.9rem; }

/* -------------------------------------------------------------- services */

.service-block { display: grid; grid-template-columns: 2fr 1fr; gap: 2.5rem; align-items: start; }
.service-images { display: grid; gap: 1rem; }
.service-images img { width: 100%; border-radius: var(--radius); display: block; }
.service-lists { display: grid; grid-template-columns: 1fr 1fr; gap: 0 2.5rem; }

.iconbox { display: grid; grid-template-columns: 140px 1fr; gap: 1.5rem; align-items: start; }
.iconbox img { width: 140px; border-radius: var(--radius); }
.iconbox h3 { margin-bottom: 0.5rem; }

/* ------------------------------------------------------------------ forms */

.form { max-width: 100%; }
.field { margin-bottom: 1.5rem; }
.field > label,
.field-label { display: block; margin-bottom: 0.4rem; }

input[type="text"], input[type="email"], input[type="tel"],
input[type="file"], select, textarea {
  width: 100%;
  height: 2.8rem;
  padding: 0.8rem;
  border: 0; border-radius: 0;
  background: var(--bg-alt);
  box-shadow: 0 1px 0 0 rgba(0, 0, 0, 0.08) inset;
  color: var(--text);
  font-family: inherit; font-size: 1rem;
}
textarea { height: auto; min-height: 10rem; resize: vertical; }
select { appearance: auto; }
input:focus, select:focus, textarea:focus {
  outline: 0; box-shadow: 0 0 0 2px var(--purple);
}

.checkbox-list { display: grid; gap: 0.5rem; padding: 0; margin: 0 0 1.5rem; list-style: none; }
.checkbox-list label { display: flex; align-items: center; gap: 0.75rem; cursor: pointer; }
.checkbox-list input[type="checkbox"] { width: 1.5em; height: 1.5em; flex: 0 0 auto; }

/* Honeypot — hidden from people, visible to naive bots. */
.hp-field {
  position: absolute !important; left: -9999px !important;
  width: 1px; height: 1px; overflow: hidden;
}

.notice { padding: 1rem 1.25rem; border-radius: var(--radius); margin-bottom: 2rem; }
.notice-ok    { background: #e8f4d9; border-left: 5px solid var(--green); color: #2d4a06; }
.notice-error { background: #fdecf3; border-left: 5px solid var(--link);  color: #7a1240; }

.field-error { color: #b30045; font-size: 0.9rem; margin-top: 0.3rem; }
.field-hint  { color: var(--faded); font-size: 0.9rem; margin-top: 0.3rem; }

.contact-details .iconbox { grid-template-columns: 90px 1fr; align-items: center; }
.contact-icon {
  width: 90px; height: 90px; border-radius: 50%;
  background: var(--purple); color: #fff;
  display: flex; align-items: center; justify-content: center; font-size: 2.25rem;
}
.contact-buttons { display: grid; gap: 0.8rem; margin: 2rem 0; }
.contact-buttons .btn { justify-content: center; }

/* ----------------------------------------------------------------- footer */

.site-footer { background: var(--purple-dark); color: #fff; }
.footer-main { padding: var(--section-pad) var(--padding-inline); }
.footer-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 2.5rem; text-align: center; }
.footer-heading { color: #fff; font-size: max(1.2rem, 1.2vw); margin-bottom: 1rem; }
.footer-nav { list-style: none; margin: 0; padding: 0; }
.footer-nav li { margin-bottom: 0.5rem; }
.footer-nav a, .footer-details a { color: #fff; }
.footer-nav a:hover, .footer-details a:hover { color: #fff; text-decoration: underline; }
.footer-logo { width: 200px; margin: 0 auto 1rem; display: block; }
.footer-details { line-height: 1.6; }
.footer-socials { display: flex; justify-content: center; gap: 1.1rem; margin-top: 1.25rem; }
.footer-socials a { color: #2b7bd4; font-size: 1.25rem; display: flex; }
.footer-socials a:hover { opacity: 0.8; }

.footer-bottom {
  background: var(--purple-darker); color: #fff;
  padding: 1rem var(--padding-inline); text-align: center; font-size: 12px;
}
.footer-bottom p { margin: 0; }
.footer-bottom a { color: #fff; text-decoration: underline; }

/* ------------------------------------------------------------------- 404 */

.error-page { padding: 6rem var(--padding-inline); text-align: center; }
.error-page h1 { color: var(--purple); }

/* ------------------------------------------------------------ responsive */

@media (max-width: 1250px) {
  .header-logo img { width: 200px; }
  .header-badge { width: 120px; }
  .nav-item > a { padding: 0 0.6rem; font-size: 17px; }
  .header-socials { gap: 0.8rem; }
  .header-socials a { font-size: 1.25rem; }
}

@media (max-width: 1023px) {
  :root { --section-pad: 2.5rem; --padding-inline: 1.5rem; }

  .nav-toggle { display: flex; }
  .header-contact { display: none; }
  .header-middle-h { min-height: auto; }
  .header-logo img { width: 160px; }
  .header-badge { width: 90px; }

  /* The purple nav strip collapses; the nav itself becomes a fixed overlay,
     so it must NOT be display:none'd via its parent. */
  .header-bottom, .header-bottom.is-stuck {
    position: static; background: none; box-shadow: none;
  }
  .header-bottom-spacer, .header-bottom.is-stuck + .header-bottom-spacer { height: 0; }
  .header-bottom-h { padding: 0; display: block; }
  .header-socials { display: none; }

  /* Mobile menu: full-screen purple overlay */
  .site-nav {
    position: fixed; inset: 0; z-index: 100;
    display: none; flex-direction: column; justify-content: center;
    background: var(--purple-dark);
    padding: 2rem 1.5rem;
    overflow-y: auto;
  }
  .site-nav.is-open { display: flex; }
  .nav-close {
    display: block; position: absolute; top: 1rem; right: 1.25rem;
    width: 2.75rem; height: 2.75rem; padding: 0;
    background: none; border: 0; color: #3a2b3d; cursor: pointer;
  }
  .nav-close svg { width: 100%; height: 100%; }
  .nav-list { flex-direction: column; gap: 0.25rem; }
  .nav-item > a {
    height: auto; justify-content: center; padding: 0.9rem 1rem;
    font-size: 1.35rem; font-weight: 400; border-bottom: 0;
  }
  .nav-item.is-current > a,
  .nav-item > a:hover, .nav-item > a:focus { background: var(--green); color: var(--purple-dark); }

  body.nav-open { overflow: hidden; }

  .cols-2, .cols-2-wide, .cols-2-narrow, .cols-3,
  .service-block, .home-flyers, .footer-cols { grid-template-columns: 1fr; }
  .iconbox { grid-template-columns: 110px 1fr; }
  .iconbox img { width: 110px; }
  .report-links { grid-template-columns: 1fr; text-align: center; }
  .report-links img { margin: 0 auto; }
  .team-member { grid-template-columns: 1fr; }
  .home-hero-overlay { background: linear-gradient(180deg, rgba(255,255,255,0.92), rgba(255,255,255,0.9)); }
  .page-hero-overlay { background: linear-gradient(90deg, #ffffff, rgba(255,255,255,0.25)); }
}

@media (max-width: 767px) {
  :root { --font-size: 16px; --line-height: 25px; --section-pad: 1.5rem; }
  h1 { font-size: max(2.5rem, 2.5vw); }
  .motto-text { font-size: 1.8rem; }
  .service-lists { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
  .team-photo img { width: 200px; height: 200px; }
  .partners-track { margin: 0 2rem; }
}

@media print {
  .site-header, .site-footer, .nav-toggle { display: none; }
}
