/* ═══════════════════════════════════════════════
   CAB Lab — form.css
   Application form + Thank You page styles
═══════════════════════════════════════════════ */


/* ───────────────────────────────────────────────
   FORM PAGE BASE
─────────────────────────────────────────────── */
.form-page {
  background: var(--white);
  min-height: 100svh;
}

.form-main {
  padding: calc(var(--nav-h) + 4rem) clamp(1.5rem, 6vw, 6rem) 6rem;
}

.form-wrap {
  max-width: 680px;
  margin: 0 auto;
}


/* ───────────────────────────────────────────────
   FORM HEADER
─────────────────────────────────────────────── */
.form-back {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--sans);
  font-size: 0.75rem;
  font-weight: 400;
  letter-spacing: 0.06em;
  color: #999999;
  text-decoration: none;
  margin-bottom: 2.5rem;
  transition: color 0.2s;
}

.form-back:hover {
  color: var(--black);
}

.form-eyebrow {
  display: block;
  font-family: var(--sans);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 1rem;
}

.form-heading {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(2.5rem, 5vw, 4rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: var(--black);
  margin-bottom: 1.5rem;
}

.form-intro {
  font-family: var(--sans);
  font-size: 0.9375rem;
  font-weight: 300;
  line-height: 1.85;
  color: #666666;
  margin-bottom: 0;
}

.form-rule {
  width: 100%;
  height: 1px;
  background: #e8e8e8;
  margin: 3rem 0;
}


/* ───────────────────────────────────────────────
   FORM FIELDS
─────────────────────────────────────────────── */
.form {
  display: flex;
  flex-direction: column;
  gap: 3rem;
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

/* Label */
.form-label {
  font-family: var(--sans);
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--black);
  line-height: 1.4;
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
}

.form-q-num {
  font-family: var(--sans);
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  color: var(--red);
  flex-shrink: 0;
}

/* Hint */
.form-hint {
  font-family: var(--sans);
  font-size: 0.75rem;
  font-weight: 300;
  color: #aaaaaa;
  letter-spacing: 0.02em;
  margin: 0;
}

/* Text input */
.form-input {
  font-family: var(--sans);
  font-size: 0.9375rem;
  font-weight: 300;
  color: var(--black);
  background: var(--white);
  border: 1px solid #e0e0e0;
  padding: 0.875rem 1rem;
  width: 100%;
  outline: none;
  transition: border-color 0.2s;
  -webkit-appearance: none;
  border-radius: 0;
}

.form-input::placeholder {
  color: #cccccc;
  font-weight: 300;
}

.form-input:focus {
  border-color: var(--black);
}

/* Textarea */
.form-textarea {
  font-family: var(--sans);
  font-size: 0.9375rem;
  font-weight: 300;
  color: var(--black);
  background: var(--white);
  border: 1px solid #e0e0e0;
  padding: 0.875rem 1rem;
  width: 100%;
  resize: vertical;
  min-height: 140px;
  outline: none;
  transition: border-color 0.2s;
  line-height: 1.7;
  -webkit-appearance: none;
  border-radius: 0;
}

.form-textarea::placeholder {
  color: #cccccc;
  font-weight: 300;
}

.form-textarea:focus {
  border-color: var(--black);
}

/* Over-limit state */
.form-textarea.is-over-limit {
  border-color: var(--red);
}

/* Word count */
.form-wordcount {
  font-family: var(--sans);
  font-size: 0.7rem;
  font-weight: 400;
  color: #bbbbbb;
  letter-spacing: 0.04em;
  text-align: right;
  transition: color 0.2s;
}

.form-wordcount.is-near-limit {
  color: #e0a000;
}

.form-wordcount.is-over-limit {
  color: var(--red);
}

.form-wordcount-num {
  font-weight: 500;
}


/* ───────────────────────────────────────────────
   SUBMIT ROW
─────────────────────────────────────────────── */
.form-submit-row {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding-top: 1rem;
  border-top: 1px solid #e8e8e8;
}

.form-submit {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  align-self: flex-start;
  font-family: var(--sans);
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--white);
  background: var(--red);
  padding: 1rem 2.5rem;
  border: 1px solid var(--red);
  cursor: pointer;
  transition: background 0.3s var(--ease), color 0.3s var(--ease), gap 0.3s var(--ease);
}

.form-submit:hover {
  background: var(--black);
  border-color: var(--black);
  gap: 0.9rem;
}

.form-submit:hover svg {
  transform: translateX(3px);
}

.form-submit svg {
  transition: transform 0.3s var(--ease);
  flex-shrink: 0;
}

.form-submit-note {
  font-family: var(--sans);
  font-size: 0.75rem;
  font-weight: 300;
  color: #666666;
  letter-spacing: 0.02em;
  margin: 0;
}

@media (max-width: 560px) {
  .form-submit {
    width: 100%;
    justify-content: center;
  }
}


/* ───────────────────────────────────────────────
   THANK YOU PAGE
─────────────────────────────────────────────── */
.thankyou-main {
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding: calc(var(--nav-h) + 2rem) clamp(1.5rem, 6vw, 6rem) 4rem;
}

.thankyou-wrap {
  max-width: 560px;
  margin: 0 auto;
  animation: heroFadeUp 0.9s var(--ease) both;
}

.thankyou-mark {
  margin-bottom: 2rem;
}

.thankyou-heading {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(3rem, 6vw, 5rem);
  line-height: 1.0;
  letter-spacing: -0.02em;
  color: var(--black);
  margin-bottom: 1.5rem;
}

.thankyou-body {
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(1.2rem, 2.2vw, 1.6rem);
  font-weight: 400;
  line-height: 1.5;
  color: var(--black);
  margin-bottom: 1.5rem;
}

.thankyou-sub {
  font-family: var(--sans);
  font-size: 0.875rem;
  font-weight: 300;
  line-height: 1.8;
  color: #888888;
  margin-bottom: 3rem;
  max-width: 44ch;
}

.thankyou-back {
  display: inline-flex;
  align-items: center;
  font-family: var(--sans);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--black);
  border-bottom: 1px solid #cccccc;
  padding-bottom: 0.2rem;
  transition: color 0.2s, border-color 0.2s;
}

.thankyou-back:hover {
  color: var(--red);
  border-color: var(--red);
}


/* ───────────────────────────────────────────────
   INVESTMENT BLOCK
─────────────────────────────────────────────── */
.investment {
  background: #f5f5f5;
  border: 1px solid #e8e8e8;
  padding: 2.5rem;
  margin-bottom: 3rem;
}

.investment__label {
  display: block;
  font-family: var(--sans);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 1.5rem;
}

.investment__inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

.investment__title {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 1.2rem;
  color: var(--black);
  margin-bottom: 1.25rem;
  line-height: 1.2;
}

.investment__list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.investment__list li {
  font-family: var(--sans);
  font-size: 0.875rem;
  font-weight: 300;
  color: #444444;
  line-height: 1.5;
  padding-left: 1rem;
  position: relative;
}

.investment__list li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 4px;
  height: 1px;
  background: var(--red);
}

.investment__list li strong {
  font-weight: 500;
  color: var(--black);
}

.investment__right {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  justify-content: center;
  padding-left: 2rem;
  border-left: 1px solid #e0e0e0;
}

.investment__note {
  font-family: var(--sans);
  font-size: 0.8rem;
  font-weight: 300;
  line-height: 1.75;
  color: #888888;
  margin: 0;
}

@media (max-width: 560px) {
  .investment__inner {
    grid-template-columns: 1fr;
  }

  .investment__right {
    padding-left: 0;
    border-left: none;
    border-top: 1px solid #e0e0e0;
    padding-top: 1.5rem;
  }
}


/* ───────────────────────────────────────────────
   INLINE CONFIRMATION MESSAGE
─────────────────────────────────────────────── */

/* Ensure hidden attribute always works */
[hidden] { display: none !important; }

.form-confirmation {
  padding: 4rem 0 6rem;
}

.form-confirmation__inner {
  max-width: 560px;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.form-confirmation__heading {
  font-family: var(--serif);
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 300;
  color: var(--black);
  margin: 0;
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.form-confirmation__body {
  font-family: var(--sans);
  font-size: 1rem;
  font-weight: 300;
  line-height: 1.85;
  color: #444444;
  margin: 0;
  max-width: 52ch;
}
