/* =====================================================================
   Young Hearts Australia — stylesheet
   Palette: Soft Peach (main), Dusty Sky Blue, Golden Ochre
   ===================================================================== */

:root {
  /* Main + accent colours */
  --peach:       #EAA68A;   /* main colour */
  --sky-blue:    #74A7CB; 

  /* Soft tints for backgrounds */
  --peach-soft:  #FBEDE6;
  --blush:       #FDF6F1;
  --sky-soft:    #EAF2F8;


  /* Base Colors */
  --charcoal:    #4A413B;
  --white:       #FFFFFF;

  /* Legacy accent (minimal use) */
  --accent:      var(--sky-blue);
  --accent-dark: #4F87B2;

  /* Backgrounds */
  --bg:          var(--white);
  --bg-muted:    var(--peach-soft);
  --ink:         var(--charcoal);
  --ink-soft:    #7A6F66;
--warm-cream:    #F7F3EE;

  --maxw: 1120px;
  --radius: 16px;
  --shadow-sm: 0 4px 14px rgba(74, 65, 59, 0.08);
  --shadow-md: 0 12px 34px rgba(74, 65, 59, 0.12);
  --ease: cubic-bezier(0.16, 1, 0.3, 1);

  --font-head: "Playfair Display", Georgia, serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
}

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

html { scroll-behavior: smooth; scroll-padding-top: 84px; }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.7;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

a { color: var(--sky-blue); text-decoration: none; transition: color .2s var(--ease); }
a:hover { color: var(--accent-dark); }

h1, h2, h3 { font-family: var(--font-head); font-weight: 600; line-height: 1.2; color: var(--charcoal); margin: 0; }

.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: 24px;
}
.container--narrow { max-width: 760px; }

/* Accessibility helpers */
.skip-link {
  position: absolute;
  left: 12px; top: -60px;
  background: var(--charcoal);
  color: #fff;
  padding: 10px 16px;
  border-radius: 8px;
  z-index: 1000;
  transition: top .25s var(--ease);
}
.skip-link:focus { top: 12px; color: #fff; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}

:focus-visible {
  outline: 3px solid var(--sky-blue);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ----------------------------- Buttons ----------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 30px;
  border-radius: 999px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1rem;
  letter-spacing: .01em;
  cursor: pointer;
  border: 2px solid transparent;
  transition: transform .25s var(--ease), background .25s var(--ease), color .25s var(--ease), box-shadow .25s var(--ease);
}
.btn:hover { transform: translateY(-2px); }

.btn--coral { background: var(--accent-dark); color: #fff; box-shadow: var(--shadow-sm); }
.btn--coral:hover { background: var(--accent); color: #fff; box-shadow: var(--shadow-md); }

.btn--light { background: #fff; color: var(--charcoal); box-shadow: var(--shadow-sm); }
.btn--light:hover { color: var(--charcoal); box-shadow: var(--shadow-md); }

.btn--outline-light { background: transparent; color: var(--charcoal); border-color: rgba(87,95,94,.4); }
.btn--outline-light:hover { background: rgba(87,95,94,.08); color: var(--charcoal); }

/* ----------------------------- Navigation ----------------------------- */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  transition: background .3s var(--ease), box-shadow .3s var(--ease), padding .3s var(--ease);
  padding: 10px 0;
}
.site-header.is-scrolled {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  box-shadow: 0 1px 0 rgba(87,95,94,.08), var(--shadow-sm);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav__brand { display: flex; align-items: center; gap: 12px; }
.nav__logo { width: 80px; height: 57px; object-fit: cover; }
/* Hide logo in header by default, show when scrolled */
.nav__logo {
  opacity: 0;
  transform: scale(0.9);
  transition: opacity 0.3s var(--ease), transform 0.3s var(--ease);
}

.site-header.is-scrolled .nav__logo {
  opacity: 1;
  transform: scale(1);
}
.nav__brand-text {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--charcoal);
  line-height: 1;
  opacity: 0;
  transition: opacity .3s var(--ease);
}
.nav__brand-text span { color: var(--sky-blue); }
.site-header.is-scrolled .nav__brand-text { opacity: 0; }

/* On the transparent hero nav, brand text is visible */
.nav__brand-text { opacity: 0; color: var(--charcoal); }
.nav__brand-text span { color: var(--charcoal); }
.site-header.is-scrolled .nav__brand-text { color: var(--charcoal); }
.site-header.is-scrolled .nav__brand-text span { color: var(--sky-blue); }

.nav__menu {
  display: flex;
  align-items: center;
  gap: 30px;
  list-style: none;
  margin: 0; padding: 0;
}
.nav__menu a {
  color: var(--charcoal);
  font-weight: 500;
  font-size: .98rem;
  position: relative;
}
.nav__menu a::after {
  content: "";
  position: absolute;
  left: 0; bottom: -6px;
  width: 0; height: 2px;
  background: var(--sky-blue);
  transition: width .25s var(--ease);
}
.nav__menu a:hover::after { width: 100%; }

.site-header.is-scrolled .nav__menu a { color: var(--charcoal); }
.site-header.is-scrolled .nav__menu a:hover { color: var(--sky-blue); }

.nav__cta {
  padding: 9px 20px;
  border: 2px solid rgba(87,95,94,.3);
  border-radius: 999px;
}
.nav__cta::after { display: none; }
.nav__cta:hover { background: rgba(87,95,94,.08); }
.site-header.is-scrolled .nav__cta {
  border-color: var(--sky-blue);
  color: var(--sky-blue) !important;
}
.site-header.is-scrolled .nav__cta:hover { background: var(--sky-blue); color: #fff !important; }

/* Hamburger */
.nav__toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: 0;
  cursor: pointer;
  padding: 8px;
}
.nav__toggle span {
  width: 26px; height: 2px;
  background: var(--charcoal);
  border-radius: 2px;
  transition: transform .3s var(--ease), opacity .3s var(--ease), background .3s var(--ease);
}
/* Close button in mobile menu */
.nav__close-wrap {
  display: none;
}

@media (max-width: 768px) {
  .nav__close-wrap {
    display: block;
    width: 100%;
    text-align: right;
    padding-top: 10px;
    /* margin-bottom: 20px;*/
  }
  
  .nav__close {
    background: none;
    border: none;
    color: #fff;  /* Changed from var(--charcoal) to white */
    cursor: pointer;
    padding: 8px;
  }
}
.site-header.is-scrolled .nav__toggle span { background: var(--charcoal); }

/* ----------------------------- Hero ----------------------------- */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: var(--white);
  color: var(--charcoal);
  overflow: hidden;
  padding: 120px 0 90px;
}
/* soft decorative accents */

.hero::after {
  content: "";
  position: absolute;
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(255,255,255,.5) 0%, transparent 62%);
  bottom: -160px; left: -120px;
  filter: blur(40px);
}
.hero__inner { position: relative; z-index: 2; }

.hero__logo-wrap {
  /* width: 180px; height: 180px; */
  margin: 0 auto 30px;
  /* background: #fff;
  border-radius: 50%; */
  display: grid;
  place-items: center;
  /* box-shadow: 0 20px 50px rgba(0,0,0,.28); */
}
.hero__logo { width: 34%; /* height: 84%;*/ object-fit: contain; /* border-radius: 50%;*/ }
@media (max-width: 720px) {
  .hero__logo { width: 44%; }
}
@media (max-width: 480px) {
  .hero__logo { width: 54%; }
}

.hero__title {
  color: var(--charcoal);
  font-size: clamp(2rem, 5vw, 3.4rem);
  max-width: 25ch;
  margin: 0 auto 22px;
}
.hero__sub {
  color: var(--charcoal);
  font-size: clamp(1.02rem, 2vw, 1.2rem);
  max-width: 52ch;
  margin: 0 auto 38px;
  opacity: 0.85;
}
.hero__cta { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }

.hero__scroll {
  position: absolute;
  left: 50%; bottom: 26px;
  transform: translateX(-50%);
  width: 26px; height: 42px;
  border: 2px solid rgba(87,95,94,.3);
  border-radius: 999px;
  z-index: 2;
}
.hero__scroll span {
  position: absolute;
  left: 50%; top: 8px;
  width: 4px; height: 8px;
  margin-left: -2px;
  background: var(--charcoal);
  border-radius: 2px;
  animation: scrollDot 1.8s infinite;
}
@keyframes scrollDot {
  0% { opacity: 0; transform: translateY(0); }
  40% { opacity: 1; }
  80% { opacity: 0; transform: translateY(14px); }
  100% { opacity: 0; }
}

/* ----------------------------- Sections ----------------------------- */
.section { padding: clamp(64px, 10vw, 120px) 0; }
.section--muted { background: var(--bg-muted); }

.story { background: var(--peach-soft); }
.support { background: var(--peach-soft); }
.contact { background: var(--white); }

.eyebrow {
  text-transform: uppercase;
  letter-spacing: .18em;
  font-size: .8rem;
  font-weight: 600;
  color: var(--sky-blue);
  margin: 0 0 14px;
}
.eyebrow--light { color: var(--charcoal); opacity: 0.7; }

.section__title {
  font-size: clamp(1.7rem, 3.6vw, 2.6rem);
  /* max-width: 20ch; */
  margin: 0 0 36px;
}
.section__title--light { color: #fff; }

/* Prose blocks */
.prose p { color: var(--ink-soft); font-size: 1.08rem; margin: 0 0 22px; }
.prose--light p { color: rgba(255,255,255,.95); }

.story__pull, .support__pull {
  font-family: var(--font-head);
  font-size: clamp(1.4rem, 3vw, 1.9rem);
  color: var(--sky-blue);
  font-style: italic;
  margin: 34px 0 !important;
}
.support__pull { color: var(--charcoal); }

/* ----------------------------- Cards ----------------------------- */
.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
  margin-top: 10px;
}
.card {
  background: #fff;
  border-radius: var(--radius);
  padding: 38px 30px;
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(140,191,217,.18);
  transition: transform .35s var(--ease), box-shadow .35s var(--ease);
  display: flex;
  flex-direction: column;
  align-items: center;
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }
.card__icon {
  width: 62px; height: 62px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  background: rgba(140,191,217,.18);
  color: var(--sky-blue);
  margin-bottom: 22px;
}
.card__icon svg { width: 30px; height: 30px; }
.card__title { font-size: 1.32rem; margin-bottom: 10px; }
.card__text { color: var(--ink-soft); margin: 0; text-align: center; }

/* ----------------------------- Support ----------------------------- */
.help {
  background: linear-gradient(325deg, #C8DFF0 0%, #74A7CB 100%);
  color: var(--charcoal);
  text-align: center;
}
.help .prose { margin-inline: auto; }
.help .prose p { color: rgba(255, 255, 255, 0.95); }
.help__cta { margin-top: 30px; }

/* ----------------------------- Contact form ----------------------------- */
.contact__lead { color: var(--ink-soft); font-size: 1.08rem; margin: 0 0 40px; }

.form { text-align: left; }
.form__row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
.form__group { margin-bottom: 22px; }
.form__group label {
  display: block;
  font-weight: 600;
  font-size: .92rem;
  color: var(--charcoal);
  margin-bottom: 8px;
}
.form input,
.form textarea {
  width: 100%;
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--ink);
  background: #fff;
  border: 1.5px solid rgba(87,95,94,.2);
  border-radius: 12px;
  padding: 13px 16px;
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease);
}
.form input:focus,
.form textarea:focus {
  outline: none;
  border-color: var(--sky-blue);
  box-shadow: 0 0 0 4px rgba(140,191,217,.22);
}
.form textarea { resize: vertical; }

.cf-turnstile { margin: 6px 0 24px; }

.form__submit { width: 100%; margin-top: 4px; }

.form__status { margin: 16px 0 0; font-weight: 500; min-height: 1.2em; }
.form__status.is-success { color: #2e7d5b; }
.form__status.is-error { color: #C75555; }

.contact__direct { text-align: center; margin-top: 34px; color: var(--ink-soft); }

/* ----------------------------- Footer ----------------------------- */
.footer {
  background: var(--charcoal);
  color: rgba(255,255,255,.85);
  padding: 56px 0 40px;
}
.footer__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 16px;
}
.footer__brand { display: flex; flex-direction: column; align-items: center; gap: 14px; }
.footer__logo { width: 99px; }
.footer__tagline {
  font-family: var(--font-head);
  font-style: italic;
  color: rgba(255,255,255,.9);
  max-width: 40ch;
  margin: 0;
}
.footer__social { display: flex; gap: 14px; list-style: none; padding: 0; margin: 6px 0; }
.footer__social a {
  width: 42px; height: 42px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: rgba(255,255,255,.1);
  color: #fff;
  transition: background .25s var(--ease);
}
.footer__social a:hover { background: var(--sky-blue); }
.footer__copy { font-size: .88rem; color: rgba(255,255,255,.6); margin: 8px 0 0; }

/* ----------------------------- Reveal animations ----------------------------- */
/*
  Scroll-reveal is progressively enhanced: content is fully visible by
  default and only hidden once the inline <script> in <head> sets the
  "js" class on <html>. This keeps every word readable and indexable by
  crawlers and no-JS browsers while preserving the animation for users.
*/
.reveal {
  opacity: 1;
  transform: none;
  transition: opacity .7s var(--ease), transform .7s var(--ease);
}
.js .reveal {
  opacity: 0;
  transform: translateY(28px);
}
.js .reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .hero__scroll span { animation: none; }
  .btn:hover, .card:hover { transform: none; }
}

/* ----------------------------- Responsive ----------------------------- */
@media (max-width: 860px) {
  .cards { grid-template-columns: 1fr; max-width: 460px; margin-inline: auto; }
}

@media (max-width: 720px) {
  .nav__toggle { display: flex; }
  .nav__menu {
    position: fixed;
    inset: 0 0 auto 0;
    top: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    background: var(--charcoal);
    padding: 0px 28px 32px;
    transform: translateY(-100%);
    transition: transform .35s var(--ease);
    box-shadow: var(--shadow-md);
  }
  .nav__menu.is-open { transform: translateY(0); }
  .nav__menu a { color: #fff !important; font-size: 1.1rem;  width: 100%; }
  .nav__menu a::after { display: none; }
  .nav__cta { border-color: rgba(255,255,255,.5); display: inline-block; margin-top: 8px; }
  .site-header.is-scrolled .nav__cta { color: #fff !important; }

  .form__row { grid-template-columns: 1fr; gap: 0; }
}
