/* ==========================================================================
   The Collective — Join page styles
   ========================================================================== */

:root {
  /* Official brand colours */
  --teal: #6BB7B0;       /* primary teal — button fills, decorative accents */
  --bg-warm: #F7F5F0;    /* warm off-white — page background */
  --mustard: #D9A441;    /* secondary accent — small decorative details only */
  --text-dark: #1E3A38;  /* charcoal — body text, headings, button text */
  --text-muted: #5C7A78;
  --white: #FFFFFF;
  --error: #B3261E;

  /* --teal-deep is the same hue as --teal (≈175°), darkened only where flat
     #6BB7B0 fails WCAG contrast as text or as a UI-component boundary
     (measured ~2.1:1 against this off-white — links, focus rings, and the
     checkbox need at least 3:1, body text needs 4.5:1). Used for: link
     text, focus indicators, and input focus borders. Not the previous
     dark teal (#0F6E6A) — recalculated from the new brand teal. */
  --teal-deep: #326762;

  --radius-lg: 16px;
  --radius-md: 10px;
  --shadow-soft: 0 4px 16px rgba(30, 58, 56, 0.08);
  --focus-ring: 3px solid var(--teal-deep);
}

* {
  box-sizing: border-box;
}

html {
  /* Respect the user's browser text-size setting; never shrink below it. */
  font-size: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg-warm);
  color: var(--text-dark);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 1rem;
  line-height: 1.6;
}

.page {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 24px 16px 64px;
}

.card {
  width: 100%;
  max-width: 560px;
  background: var(--white);
  border-radius: var(--radius-lg);
  border-top: 5px solid var(--mustard);
  box-shadow: var(--shadow-soft);
  padding: 24px 24px 32px;
  margin-top: 24px;
}

@media (min-width: 640px) {
  .card {
    padding: 32px 56px 48px;
    margin-top: 48px;
  }
}

.brand-header {
  text-align: center;
  margin-bottom: 16px;
}

/* The supplied logo file is a 1080x1080 transparent PNG with a lot of
   built-in vertical padding around the mark itself. .logo-wrap crops that
   padding visually (overflow:hidden) without touching the source file:
   the image is scaled up and shifted inside a fixed-ratio window sized to
   the mark's own bounding box, so only transparent space is hidden and no
   visible pixel of the logo or wordmark is cut off. */
.logo-wrap {
  position: relative;
  overflow: hidden;
  width: 100%;
  max-width: 284px;
  aspect-ratio: 781 / 336;
  margin: 0 auto;
}

.logo-wrap .logo {
  position: absolute;
  top: 0;
  left: 0;
  width: 138.28%;
  max-width: none;
  height: auto;
  transform: translate(-13.43%, -40.56%);
}

h1 {
  color: var(--teal-deep);
  font-size: 1.75rem;
  line-height: 1.25;
  margin: 0 0 16px;
  text-align: center;
}

@media (min-width: 640px) {
  h1 {
    font-size: 2.1rem;
  }
}

.intro {
  color: var(--text-dark);
  font-size: 1.0625rem;
  text-align: center;
  margin: 0 0 32px;
}

.field {
  margin-bottom: 20px;
}

.field label {
  display: block;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text-dark);
}

.field input[type="text"],
.field input[type="email"] {
  width: 100%;
  font-size: 1.0625rem;
  padding: 14px 16px;
  border: 2px solid #C9DAD8;
  border-radius: var(--radius-md);
  background: var(--white);
  color: var(--text-dark);
  min-height: 52px;
}

.field input[type="text"]:focus,
.field input[type="email"]:focus {
  outline: var(--focus-ring);
  outline-offset: 2px;
  border-color: var(--teal-deep);
}

.field input[aria-invalid="true"] {
  border-color: var(--error);
}

.checkbox-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.field-checkbox .field-error {
  margin-left: 36px;
}

.field-checkbox input[type="checkbox"] {
  width: 24px;
  height: 24px;
  min-width: 24px;
  margin-top: 2px;
  accent-color: var(--teal-deep);
}

.field-checkbox input[type="checkbox"]:focus-visible {
  outline: var(--focus-ring);
  outline-offset: 2px;
}

.field-checkbox label {
  font-weight: 400;
  font-size: 1rem;
  margin-bottom: 0;
}

.field-error {
  color: var(--error);
  font-size: 0.9375rem;
  margin: 8px 0 0;
  font-weight: 600;
}

.form-status {
  background: #FDECEA;
  color: var(--error);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  font-size: 1rem;
  margin-bottom: 20px;
}

button[type="submit"] {
  width: 100%;
  background: var(--teal);
  color: var(--text-dark);
  font-size: 1.125rem;
  font-weight: 700;
  border: 2px solid transparent;
  border-radius: var(--radius-md);
  padding: 16px 24px;
  min-height: 56px;
  cursor: pointer;
}

button[type="submit"]:hover {
  border-color: var(--teal-deep);
}

button[type="submit"]:focus-visible {
  outline: var(--focus-ring);
  outline-offset: 3px;
}

button[type="submit"]:disabled {
  opacity: 0.75;
  cursor: not-allowed;
}

/* Honeypot: hidden from everyone but automated bots that scan the DOM. */
.honeypot {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

#confirmation-view h1 {
  outline: none;
}

#confirmation-message p {
  font-size: 1.0625rem;
  margin: 0 0 16px;
}

.contact-line {
  text-align: center;
  font-size: 1rem;
  color: var(--text-muted);
  margin-top: 24px;
}

a,
a:link,
a:visited {
  color: var(--teal-deep);
}

a:hover,
a:active {
  color: var(--teal-deep);
  text-decoration-thickness: 2px;
}

a:focus-visible {
  outline: var(--focus-ring);
  outline-offset: 2px;
}

/* Respect users who ask for reduced motion; the page has no animation
   by design, but this guards against anything added later. */
@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
    animation: none !important;
  }
}
