/* ===============================================================
   FC Melbourne Palestine
   Palette and stripe motif taken from the club crest and the
   club's own information booklet.
   =============================================================== */

:root {
  /* Colour, sampled directly from the crest artwork */
  --ink: #000000;
  --ink-soft: #14161a;
  --bone: #f4f4f1;
  --bone-dim: #e6e6e1;
  --green: #196c25;
  --green-lift: #1f8a2f;
  --red: #d31618;
  --red-lift: #e8272a;
  --white: #ffffff;

  --text-on-dark: rgba(255, 255, 255, 0.86);
  --text-on-dark-quiet: rgba(255, 255, 255, 0.6);
  --text-on-light: #16181b;
  --text-on-light-quiet: #4b5157;
  --rule-dark: rgba(255, 255, 255, 0.16);
  --rule-light: rgba(0, 0, 0, 0.12);

  /* Type */
  --display: 'Archivo', 'Helvetica Neue', Arial, sans-serif;
  --body: 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI',
    Roboto, sans-serif;

  /* Scale */
  --step--1: clamp(0.83rem, 0.8rem + 0.15vw, 0.92rem);
  --step-0: clamp(1rem, 0.96rem + 0.2vw, 1.12rem);
  --step-1: clamp(1.2rem, 1.12rem + 0.4vw, 1.45rem);
  --step-2: clamp(1.5rem, 1.34rem + 0.8vw, 2rem);
  --step-3: clamp(1.95rem, 1.6rem + 1.7vw, 3rem);
  --step-4: clamp(2.5rem, 1.9rem + 3vw, 4.5rem);
  --step-5: clamp(3rem, 2rem + 5vw, 6.5rem);

  /* Layout */
  --measure: 68ch;
  --gutter: clamp(1.25rem, 5vw, 4rem);
  --shell: 1180px;
  --section-y: clamp(4rem, 9vw, 8rem);
}

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

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

body {
  margin: 0;
  background: var(--ink);
  color: var(--text-on-dark);
  font-family: var(--body);
  font-size: var(--step-0);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

h1,
h2,
h3,
h4 {
  font-family: var(--display);
  font-weight: 800;
  line-height: 1.02;
  letter-spacing: -0.02em;
  margin: 0 0 0.5em;
  text-wrap: balance;
}

h1 {
  font-size: var(--step-4);
}
h2 {
  font-size: var(--step-3);
}
h3 {
  font-size: var(--step-1);
  letter-spacing: -0.01em;
}

p {
  margin: 0 0 1.1em;
  max-width: var(--measure);
}

a {
  color: inherit;
}

:focus-visible {
  outline: 3px solid var(--green-lift);
  outline-offset: 3px;
  border-radius: 2px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--white);
  color: var(--ink);
  padding: 0.85rem 1.25rem;
  z-index: 200;
  font-weight: 700;
}
.skip-link:focus {
  left: 0;
}

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

/* --------------------------------------------------------------
   Shell
---------------------------------------------------------------- */
.shell {
  width: min(100% - (var(--gutter) * 2), var(--shell));
  margin-inline: auto;
}

.section {
  padding-block: var(--section-y);
}

.section--light {
  background: var(--bone);
  color: var(--text-on-light);
  /* Paper texture, echoing the printed booklet */
  background-image: radial-gradient(
    rgba(0, 0, 0, 0.035) 1px,
    transparent 1px
  );
  background-size: 4px 4px;
}

.section--light p {
  color: var(--text-on-light-quiet);
}

.section--light h2,
.section--light h3 {
  color: var(--text-on-light);
}

/* --------------------------------------------------------------
   The stripe motif.
   Three diagonals in black, red and green. Lifted from the corner
   accents used throughout the club's booklet, reused here as a
   structural divider rather than decoration.
---------------------------------------------------------------- */
.stripes {
  height: 10px;
  border: 0;
  margin: 0;
  background: repeating-linear-gradient(
    -60deg,
    var(--ink) 0 14px,
    var(--red) 14px 28px,
    var(--green) 28px 42px,
    transparent 42px 90px
  );
}

.stripes--onDark {
  background: repeating-linear-gradient(
    -60deg,
    var(--white) 0 14px,
    var(--red) 14px 28px,
    var(--green) 28px 42px,
    transparent 42px 90px
  );
}

.rule {
  border: 0;
  border-top: 1px solid var(--rule-dark);
  margin: 0;
}
.section--light .rule {
  border-top-color: var(--rule-light);
}

/* --------------------------------------------------------------
   Header
---------------------------------------------------------------- */
.masthead {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(0, 0, 0, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--rule-dark);
}

.masthead__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding-block: 0;
}

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

.brand img {
  width: 88px;
  height: 88px;
  transition: width 0.22s ease, height 0.22s ease;
}

.brand__name {
  font-family: var(--display);
  font-weight: 800;
  font-size: 1.02rem;
  line-height: 1.08;
  letter-spacing: -0.01em;
  max-width: 12ch;
  transition: font-size 0.22s ease;
}

/* Compact state, switched on by main.js once the page is scrolled.
   The scroll threshold in the script is deliberately larger than the
   height lost here, so the header cannot flip back and forth between
   the two states. */
.masthead[data-compact='true'] .brand img {
  width: 56px;
  height: 56px;
}

.masthead[data-compact='true'] .brand__name {
  font-size: 0.92rem;
}

.nav {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  flex-wrap: wrap;
}

.nav a {
  text-decoration: none;
  color: var(--text-on-dark-quiet);
  font-size: 0.92rem;
  font-weight: 500;
  padding: 0.45rem 0.7rem;
  border-radius: 2px;
  transition: color 0.15s ease, background-color 0.15s ease;
}

.nav a:hover {
  color: var(--white);
  background: rgba(255, 255, 255, 0.07);
}

.nav a[aria-current='page'] {
  color: var(--white);
  box-shadow: inset 0 -2px 0 var(--green-lift);
}

.nav__cta {
  background: var(--green);
  color: var(--white) !important;
  font-weight: 700;
  padding: 0.55rem 1.1rem !important;
}
.nav__cta:hover {
  background: var(--green-lift) !important;
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--rule-dark);
  color: var(--white);
  font: inherit;
  font-size: 0.85rem;
  padding: 0.5rem 0.85rem;
  cursor: pointer;
  border-radius: 2px;
}

/* --------------------------------------------------------------
   Buttons
---------------------------------------------------------------- */
.btn {
  display: inline-block;
  font-family: var(--display);
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: 0.01em;
  text-decoration: none;
  padding: 0.95rem 1.9rem;
  border: 2px solid transparent;
  border-radius: 2px;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease,
    color 0.15s ease;
}

.btn--primary {
  background: var(--green);
  color: var(--white);
}
.btn--primary:hover {
  background: var(--green-lift);
}

.btn--ghost {
  background: transparent;
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.4);
}
.btn--ghost:hover {
  border-color: var(--white);
  background: rgba(255, 255, 255, 0.08);
}

.section--light .btn--ghost {
  color: var(--text-on-light);
  border-color: rgba(0, 0, 0, 0.3);
}
.section--light .btn--ghost:hover {
  border-color: var(--ink);
  background: rgba(0, 0, 0, 0.05);
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-top: 1.75rem;
}

/* --------------------------------------------------------------
   Hero
---------------------------------------------------------------- */
.hero {
  position: relative;
  overflow: hidden;
  background: var(--ink);
  padding-block: clamp(3.5rem, 8vw, 7rem);
}

.hero__bg {
  position: absolute;
  inset: 0;
  background-image: var(--hero-image, none);
  background-size: cover;
  background-position: center 65%;
  opacity: 0.3;
}

.hero__bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.75) 0%,
    rgba(0, 0, 0, 0.55) 45%,
    rgba(0, 0, 0, 0.95) 100%
  );
}

.hero__inner {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
}

.hero__crest {
  width: min(100%, 320px);
  justify-self: center;
  filter: drop-shadow(0 18px 40px rgba(0, 0, 0, 0.7));
}

.hero h1 {
  font-size: clamp(1.5rem, 1.15rem + 1.15vw, 2.25rem);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--white);
  max-width: 30ch;
  margin-bottom: 0;
}

/* --------------------------------------------------------------
   Fundraising meter
   The number is small on purpose. The invitation is the message,
   not the total.
---------------------------------------------------------------- */
.meter {
  background: var(--ink-soft);
  border-top: 1px solid var(--rule-dark);
  border-bottom: 1px solid var(--rule-dark);
  padding-block: clamp(2rem, 4vw, 3rem);
}

.meter__inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: end;
}

.meter__figures {
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
  flex-wrap: wrap;
  margin-bottom: 0.9rem;
}

.meter__raised {
  font-family: var(--display);
  font-weight: 800;
  font-size: var(--step-3);
  color: var(--white);
  letter-spacing: -0.03em;
  line-height: 1;
}

.meter__goal {
  font-size: var(--step--1);
  color: var(--text-on-dark-quiet);
}

.meter__track {
  height: 8px;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 100px;
  overflow: hidden;
}

.meter__fill {
  height: 100%;
  background: linear-gradient(90deg, var(--green), var(--green-lift));
  border-radius: 100px;
  width: 0;
  transition: width 1.1s cubic-bezier(0.22, 1, 0.36, 1);
  min-width: 4px;
}

.meter__note {
  margin: 0.9rem 0 0;
  font-size: var(--step--1);
  color: var(--text-on-dark-quiet);
  max-width: 46ch;
}

/* --------------------------------------------------------------
   Generic content pieces
---------------------------------------------------------------- */
.page-head {
  padding-block: clamp(3rem, 7vw, 5.5rem) clamp(2rem, 4vw, 3rem);
  border-bottom: 1px solid var(--rule-dark);
}

.page-head h1 {
  max-width: 18ch;
  color: var(--white);
}

.page-head p {
  font-size: var(--step-1);
  color: var(--text-on-dark-quiet);
  max-width: 52ch;
  margin-bottom: 0;
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: clamp(2rem, 6vw, 5rem);
  align-items: start;
}

.split--even {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.stack > * + * {
  margin-top: 1.5rem;
}

.lede {
  font-size: var(--step-1);
  line-height: 1.5;
}

.section--light .lede {
  color: var(--text-on-light);
}

/* Values / benefit lists with a crest-green marker */
.ticks {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.75rem;
}

.ticks li {
  position: relative;
  padding-left: 1.9rem;
  max-width: var(--measure);
}

.ticks li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 11px;
  height: 11px;
  background: var(--green);
  transform: rotate(45deg);
}

.section--light .ticks li {
  color: var(--text-on-light-quiet);
}

/* --------------------------------------------------------------
   Roadmap
   Numbered because the content genuinely is a sequence.
---------------------------------------------------------------- */
.phases {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1px;
  background: var(--rule-light);
  border: 1px solid var(--rule-light);
}

.phase {
  background: var(--bone);
  padding: clamp(1.5rem, 3vw, 2.25rem);
}

.phase__num {
  font-family: var(--display);
  font-weight: 800;
  font-size: var(--step-3);
  line-height: 1;
  color: var(--green);
  display: block;
  margin-bottom: 0.4rem;
}

.phase__window {
  font-size: var(--step--1);
  color: var(--text-on-light-quiet);
  margin-bottom: 1.25rem;
}

.phase h3 {
  margin-bottom: 0.9rem;
}

.phase ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.6rem;
  font-size: var(--step--1);
  color: var(--text-on-light-quiet);
}

.phase li {
  padding-left: 1.1rem;
  position: relative;
}

.phase li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 6px;
  height: 2px;
  background: var(--red);
}

/* --------------------------------------------------------------
   Sponsorship tiers
---------------------------------------------------------------- */
.tier {
  border: 1px solid var(--rule-light);
  background: var(--white);
  margin-bottom: 1.5rem;
  overflow: hidden;
}

.tier__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.4rem clamp(1.25rem, 3vw, 2rem);
  border-bottom: 1px solid var(--rule-light);
}

.tier__name {
  font-family: var(--display);
  font-weight: 800;
  font-size: var(--step-2);
  letter-spacing: -0.02em;
  margin: 0;
  color: var(--text-on-light);
}

.tier__price {
  font-family: var(--display);
  font-weight: 800;
  font-size: var(--step-2);
  color: var(--green);
  letter-spacing: -0.02em;
}

.tier__placement {
  width: 100%;
  font-size: var(--step--1);
  color: var(--text-on-light-quiet);
  margin: 0;
}

.tier__body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(1.5rem, 3vw, 2.5rem);
  padding: clamp(1.5rem, 3vw, 2rem);
  align-items: center;
}

.tier__image {
  background: var(--bone);
  padding: 0.75rem;
  border: 1px solid var(--rule-light);
}

.tier__includes {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.6rem;
  font-size: var(--step--1);
  color: var(--text-on-light-quiet);
}

.tier__includes li {
  position: relative;
  padding-left: 1.5rem;
}

.tier__includes li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.5em;
  width: 9px;
  height: 9px;
  background: var(--green);
  transform: rotate(45deg);
}

/* Tier accent bars, one per tier, echoing the booklet's banners */
.tier--platinum .tier__head {
  border-top: 5px solid #b9bcc0;
}
.tier--gold .tier__head {
  border-top: 5px solid #c8a137;
}
.tier--silver .tier__head {
  border-top: 5px solid #9aa0a6;
}
.tier--bronze .tier__head {
  border-top: 5px solid #a2703f;
}
.tier--ground-signage .tier__head {
  border-top: 5px solid var(--green);
}

/* --------------------------------------------------------------
   Founder
---------------------------------------------------------------- */
.founder {
  display: grid;
  grid-template-columns: minmax(0, 240px) minmax(0, 1fr);
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: start;
}

.founder__photo {
  border: 1px solid var(--rule-light);
  background: var(--bone-dim);
}

.backer {
  border-left: 3px solid var(--green);
  padding-left: 1.25rem;
}

.backer h3 {
  margin-bottom: 0.35rem;
}

/* --------------------------------------------------------------
   FAQ
---------------------------------------------------------------- */
.faq {
  border-top: 1px solid var(--rule-light);
  max-width: 78ch;
}

.faq details {
  border-bottom: 1px solid var(--rule-light);
}

.faq summary {
  cursor: pointer;
  padding: 1.35rem 2.5rem 1.35rem 0;
  font-family: var(--display);
  font-weight: 700;
  font-size: var(--step-1);
  letter-spacing: -0.01em;
  color: var(--text-on-light);
  position: relative;
  list-style: none;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  content: '';
  position: absolute;
  right: 0.4rem;
  top: 50%;
  width: 13px;
  height: 2px;
  background: var(--green);
  transform: translateY(-50%);
}

.faq summary::before {
  content: '';
  position: absolute;
  right: 0.4rem;
  top: 50%;
  width: 13px;
  height: 2px;
  background: var(--green);
  transform: translateY(-50%) rotate(90deg);
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.faq details[open] summary::before {
  transform: translateY(-50%) rotate(0deg);
  opacity: 0;
}

.faq details p {
  margin: 0 0 1.4rem;
  color: var(--text-on-light-quiet);
  max-width: 66ch;
}

/* --------------------------------------------------------------
   Embeds
---------------------------------------------------------------- */
.embed {
  background: var(--white);
  border: 1px solid var(--rule-light);
  padding: 0.5rem;
}

.embed iframe {
  display: block;
  width: 100%;
  min-height: 900px;
  border: 0;
}

/* --------------------------------------------------------------
   Callout / detail blocks
---------------------------------------------------------------- */
.callout {
  background: var(--white);
  border: 1px solid var(--rule-light);
  border-left: 4px solid var(--green);
  padding: clamp(1.25rem, 3vw, 1.85rem);
}

.callout--onDark {
  background: var(--ink-soft);
  border-color: var(--rule-dark);
  border-left-color: var(--green);
}

.detail-list {
  display: grid;
  gap: 0.5rem;
  margin: 0;
  font-size: var(--step-0);
}

.detail-list div {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.detail-list dt {
  font-weight: 600;
  min-width: 8ch;
  color: var(--text-on-light);
}

.detail-list dd {
  margin: 0;
  color: var(--text-on-light-quiet);
}

.contact-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 1.1rem;
}

.contact-list a {
  color: var(--white);
  text-decoration: none;
  border-bottom: 1px solid var(--green-lift);
  padding-bottom: 1px;
}

.contact-list a:hover {
  color: var(--green-lift);
}

/* --------------------------------------------------------------
   Footer
---------------------------------------------------------------- */
.foot {
  background: var(--ink);
  border-top: 1px solid var(--rule-dark);
  padding-block: clamp(3rem, 6vw, 4.5rem) 2rem;
}

.foot__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) repeat(2, minmax(0, 1fr));
  gap: clamp(2rem, 5vw, 4rem);
  margin-bottom: 3rem;
}

.foot h4 {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 1rem;
  letter-spacing: 0.02em;
}

.foot ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.6rem;
}

.foot a {
  color: var(--text-on-dark-quiet);
  text-decoration: none;
  font-size: 0.93rem;
}

.foot a:hover {
  color: var(--white);
}

.foot__brand img {
  width: 64px;
  margin-bottom: 1rem;
}

.foot__brand p {
  font-size: 0.93rem;
  color: var(--text-on-dark-quiet);
  max-width: 34ch;
}

.foot__base {
  border-top: 1px solid var(--rule-dark);
  padding-top: 1.75rem;
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.45);
}

/* --------------------------------------------------------------
   Responsive
---------------------------------------------------------------- */
@media (max-width: 900px) {
  .hero__inner,
  .split,
  .split--even,
  .tier__body,
  .founder,
  .meter__inner {
    grid-template-columns: minmax(0, 1fr);
  }

  .hero__crest {
    width: min(60%, 240px);
    order: -1;
    justify-self: center;
  }

  .foot__grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .meter__inner {
    align-items: start;
  }
}

@media (max-width: 780px) {
  .nav-toggle {
    display: block;
  }

  .nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--ink);
    border-bottom: 1px solid var(--rule-dark);
    flex-direction: column;
    align-items: stretch;
    padding: 0.75rem var(--gutter) 1.5rem;
    gap: 0.15rem;
  }

  .nav[data-open='true'] {
    display: flex;
  }

  .nav a {
    padding: 0.8rem 0.5rem;
    font-size: 1rem;
  }

  .nav__cta {
    margin-top: 0.6rem;
    text-align: center;
  }

  .masthead {
    position: relative;
  }

  /* The header scrolls away on small screens rather than sticking,
     so there is nothing to compact. Hold one size throughout. */
  .brand img,
  .masthead[data-compact='true'] .brand img {
    width: 64px;
    height: 64px;
  }

  .brand__name,
  .masthead[data-compact='true'] .brand__name {
    max-width: none;
    font-size: 1rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
}

@media print {
  .masthead,
  .foot,
  .btn-row {
    display: none;
  }
  body {
    background: #fff;
    color: #000;
  }
}
