/* ==========================================================================
   Emerging Investors Canada
   Brand: black ink on soft pastel gradients. Aileron throughout.
   Colours come from the 2026 brand assets — #EBBAA6 and #E2C696 are the two
   named brand colours; the lighter tints are sampled from the gradient artwork.
   ========================================================================== */

/* --- Aileron, served from jsDelivr ---------------------------------------
   Declared here rather than via four <link> tags so there is one stylesheet
   to fetch and font-display is under our control. To self-host instead, drop
   the .woff2 files in assets/fonts/ and swap the src URLs for local paths. */

@font-face {
  font-family: 'Aileron';
  font-style: normal;
  font-weight: 300;
  font-display: swap;
  src: url(https://cdn.jsdelivr.net/npm/@fontsource/aileron@5.3.0/files/aileron-latin-300-normal.woff2) format('woff2');
}
@font-face {
  font-family: 'Aileron';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(https://cdn.jsdelivr.net/npm/@fontsource/aileron@5.3.0/files/aileron-latin-400-normal.woff2) format('woff2');
}
@font-face {
  font-family: 'Aileron';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(https://cdn.jsdelivr.net/npm/@fontsource/aileron@5.3.0/files/aileron-latin-600-normal.woff2) format('woff2');
}
@font-face {
  font-family: 'Aileron';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(https://cdn.jsdelivr.net/npm/@fontsource/aileron@5.3.0/files/aileron-latin-700-normal.woff2) format('woff2');
}

:root {
  /* named brand colours */
  --peach:  #EBBAA6;
  --sand:   #E2C696;

  /* tints sampled from the gradient artwork */
  --blush:  #FED5D5;
  --sky:    #F3FAFF;
  --haze:   #F0EBF2;
  --warm:   #FFE8C9;

  --ink:    #0B0B0A;
  --body:   #57514E;
  --cream:  #FFF8F1;
  --paper:  #FDFCFB;
  --white:  #FFFFFF;
  --line:   rgba(11, 11, 10, 0.13);

  --measure: 60ch;
  --radius:  16px;
  --gutter:  clamp(1.25rem, 5vw, 3.25rem);

  --font: 'Aileron', 'Helvetica Neue', Helvetica, Arial, system-ui, sans-serif;

  /* the signature wash — reused by the hero, join band and 404 */
  --wash:
    radial-gradient(58% 68% at 80% 84%, rgba(235, 186, 166, 0.92), transparent 64%),
    radial-gradient(52% 58% at 90% 22%, rgba(254, 213, 213, 0.85), transparent 62%),
    radial-gradient(68% 62% at 20% 86%, rgba(226, 198, 150, 0.62), transparent 62%),
    radial-gradient(60% 66% at 10% 14%, rgba(243, 250, 255, 0.96), transparent 60%),
    linear-gradient(135deg, #F7FAFF 0%, #FBF1F1 48%, #FFF2E4 100%);

  /* film grain, matching the texture in the brand artwork */
  --grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23n)' opacity='0.42'/%3E%3C/svg%3E");
}

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

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--paper);
  color: var(--body);
  font-family: var(--font);
  font-size: clamp(1rem, 0.96rem + 0.2vw, 1.0625rem);
  line-height: 1.68;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

/* --- type ---------------------------------------------------------------- */

h1, h2 {
  color: var(--ink);
  font-weight: 300;
  line-height: 1.02;
  letter-spacing: -0.005em;
  margin: 0 0 1.1rem;
  text-wrap: balance;
}

/* All-caps is the display treatment from the brand artwork, where the only
   uppercase element is the org name itself. Reserved for the hero so that
   headings containing mixed-case terms ("VCs") stay readable. */
h1 {
  font-size: clamp(2.4rem, 1.2rem + 5.6vw, 5.25rem);
  text-transform: uppercase;
  line-height: 0.98;
}
h2 { font-size: clamp(1.7rem, 1.05rem + 2.7vw, 2.85rem); }

h3 {
  color: var(--ink);
  font-size: 1.15rem;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.005em;
  margin: 0 0 0.55rem;
}

p { margin: 0 0 1.1em; }
p:last-child { margin-bottom: 0; }

a {
  color: var(--ink);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
a:hover { text-decoration-color: var(--peach); }

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

.wrap {
  width: 100%;
  max-width: 1180px;
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.center { text-align: center; margin-inline: auto; }
.measure { max-width: var(--measure); }

.skip { position: absolute; left: -9999px; }
.skip:focus {
  left: 1rem; top: 1rem; z-index: 100;
  background: var(--ink); color: var(--white);
  padding: 0.7rem 1.1rem; border-radius: 8px;
  text-decoration: none;
}

.eyebrow {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink);
  margin-bottom: 1.1rem;
}

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

.btn {
  display: inline-block;
  background: var(--ink);
  color: var(--white);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 1rem 1.9rem;
  border-radius: 999px;
  text-decoration: none;
  border: 1.5px solid var(--ink);
  transition: background-color 0.16s ease, color 0.16s ease, transform 0.16s ease;
}
.btn:hover {
  background: transparent;
  color: var(--ink);
  transform: translateY(-1px);
}

.btn-sm {
  padding: 0.6rem 1.25rem;
  font-size: 0.7rem;
  letter-spacing: 0.12em;
}

.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: rgba(11, 11, 10, 0.28);
}
.btn-ghost:hover {
  background: var(--ink);
  color: var(--white);
  border-color: var(--ink);
}

@media (prefers-reduced-motion: reduce) {
  .btn, .btn:hover { transform: none; transition: none; }
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  /* Opaque white: the mark PNG has a white background, so a tinted or
     translucent bar would leave a visible box around it. */
  background: var(--white);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1.5rem;
  padding-block: 0.85rem;
}

.brand { display: flex; align-items: center; gap: 0.8rem; text-decoration: none; }
.brand img { width: auto; height: 25px; }
.brand-text {
  display: flex;
  flex-direction: column;
  gap: 0.12em;
  color: var(--ink);
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  line-height: 1.1;
  text-transform: uppercase;
  padding-left: 0.8rem;
  border-left: 1px solid var(--line);
}

.site-nav { display: flex; align-items: center; gap: clamp(1rem, 2.4vw, 2.1rem); }
/* :not(.btn) matters — a bare `.site-nav a` selector outranks `.btn` on
   specificity and would paint the button's label black on black. */
.site-nav a:not(.btn) { color: var(--ink); }
.site-nav a {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
}
.site-nav a:not(.btn):hover {
  text-decoration: underline;
  text-underline-offset: 5px;
  text-decoration-color: var(--peach);
  text-decoration-thickness: 2px;
}

/* --- gradient surfaces --------------------------------------------------- */

/* Any .washed element gets the brand gradient plus the grain overlay. */
.washed { position: relative; isolation: isolate; background: var(--wash); }
.washed::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image: var(--grain);
  background-size: 180px 180px;
  mix-blend-mode: soft-light;
  opacity: 0.55;
  pointer-events: none;
}

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

.hero { padding-top: clamp(3.5rem, 8vw, 6.75rem); overflow: hidden; }
.hero-inner { max-width: 60rem; }
.hero h1 { margin-bottom: 1.5rem; }

.lede {
  font-size: clamp(1.05rem, 1rem + 0.45vw, 1.3rem);
  line-height: 1.62;
  max-width: 50ch;
  color: var(--body);
}

.cta-row { display: flex; flex-wrap: wrap; gap: 0.8rem; margin-top: 2.25rem; }

.hero-photo {
  margin: clamp(3rem, 7vw, 5.25rem) auto 0;
  width: 100%;
  max-width: 1180px;
  padding: 0 var(--gutter) clamp(3rem, 7vw, 5.25rem);
}
.hero-photo img {
  width: 100%;
  aspect-ratio: 16 / 8;
  object-fit: cover;
  object-position: 50% 68%;
  border-radius: var(--radius);
}
.hero-photo figcaption {
  margin-top: 0.9rem;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink);
}
@media (max-width: 640px) {
  .hero-photo img { aspect-ratio: 4 / 3; object-position: 50% 60%; }
}

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

.section { padding-block: clamp(4rem, 9vw, 7.25rem); }
.section-alt { background: var(--cream); }
.section, .join, .hero { scroll-margin-top: 5rem; }

/* --- about split --------------------------------------------------------- */

.split {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: start;
}
@media (max-width: 860px) { .split { grid-template-columns: 1fr; } }

.pull {
  border-left: 3px solid var(--peach);
  padding-left: 1.6rem;
  position: sticky;
  top: 6rem;
}
.pull blockquote {
  margin: 0;
  font-size: clamp(1.15rem, 1rem + 0.7vw, 1.5rem);
  line-height: 1.38;
  font-weight: 400;
  color: var(--ink);
  letter-spacing: -0.01em;
}
.pull-attr {
  margin-top: 1.1rem;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink);
}
@media (max-width: 860px) { .pull { position: static; } }

/* --- eligibility criteria ------------------------------------------------ */

.criteria {
  list-style: none;
  margin: 3.25rem auto 0;
  padding: 0;
  max-width: 64rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr));
  gap: 1.5rem 2.75rem;
}
.criteria li { border-top: 2px solid var(--sand); padding-top: 1.25rem; }
.criteria p { font-size: 0.95rem; margin: 0; }

/* --- join band ----------------------------------------------------------- */

.join { padding-block: clamp(4.25rem, 9vw, 7rem); }
.join-inner { max-width: 46rem; }
.join h2 { color: var(--ink); }
.join .lede { color: var(--body); }
.join .btn { margin-top: 2.25rem; }
.join .fine {
  margin-top: 1.6rem;
  font-size: 0.8rem;
  color: var(--body);
}

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

.site-footer {
  background: var(--white);
  border-top: 1px solid var(--line);
  padding-block: 3.75rem;
}
.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 1.6rem;
}
.footer-logo {
  width: 78px;
  height: auto;
  border-radius: 14px;
}

.footer-nav { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.8rem 1.9rem; }
.footer-nav a {
  color: var(--ink);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
}
.footer-nav a:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-color: var(--peach);
  text-decoration-thickness: 2px;
}

.footer-contact { font-size: 0.925rem; margin: -0.3rem 0 0; }
.footer-contact a { color: var(--ink); font-weight: 600; word-break: break-word; }

.copyright {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--body);
  opacity: 0.8;
}

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

.notfound {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  gap: 0.4rem;
  padding: 3rem var(--gutter);
}
.notfound img {
  width: 96px;
  height: auto;
  border-radius: 16px;
  margin-bottom: 1.75rem;
}
.notfound h1 { font-size: clamp(1.9rem, 1.3rem + 2.4vw, 3rem); }
.notfound .lede { max-width: 34ch; }
.notfound .cta-row { justify-content: center; }

/* --- small screens ------------------------------------------------------- */

@media (max-width: 640px) {
  .header-inner { justify-content: center; }

  .site-nav { width: 100%; justify-content: center; gap: 1.3rem; }
  /* The hero and the join band both carry the CTA, so the header button is
     redundant at this width. */
  .site-nav a { font-size: 0.68rem; letter-spacing: 0.1em; white-space: nowrap; }
  .site-nav .btn { display: none; }

  .brand-text { display: none; }
  .brand img { height: 27px; }

  .cta-row .btn { flex: 1 1 100%; text-align: center; }

  /* balance produces very ragged lines in a narrow column */
  h1, h2 { text-wrap: pretty; }
}
