/*-- -------------------------- -->
<---   Develop By Faith Base    -->
<--- tokens, font, type, forms  -->
<--- ---------------------------*/

@font-face {
  font-family: "Plus Jakarta Sans";
  src: url(/assets/fonts/PlusJakartaSans-Variable.woff2) format("woff2-variations");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}

:root {
  /* Brand scale */
  --navy-900: #14233a;
  --navy-800: #1d314b;
  --navy-700: #2a4266;
  --navy-600: #3b5680;
  --navy-100: #dce2eb;
  --navy-50: #eef1f6;

  --gold-500: #d9a93b;
  --gold-400: #f4c95d;
  --gold-100: #fbeecb;

  --cream-200: #eae6db;
  --cream-100: #f5f3ee;
  --cream-50: #faf9f5;
  --white: #ffffff;

  /* Semantic */
  --bg-page: var(--cream-100);
  --bg-surface: var(--white);
  --bg-dark: var(--navy-800);
  --text-heading: var(--navy-800);
  --text-body: #4b5565;
  --text-muted: #6e7582;
  --text-on-dark: #ffffff;
  --text-on-dark-muted: #c4cddb;
  --accent: var(--gold-400);
  --error: #b3372f;
  --error-bg: #fbedec;
  --success: #2e6b4f;
  --success-bg: #eaf4ef;

  /* Type scale */
  --font-sans: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --fs-display: clamp(2.25rem, 4.5vw, 3.25rem);
  --fs-h1: clamp(1.9375rem, 3.5vw, 2.75rem);
  --fs-h2: clamp(1.625rem, 3vw, 2.25rem);
  --fs-h3: clamp(1.125rem, 1.8vw, 1.375rem);
  --fs-topper: 0.8125rem;
  --fs-body: 1.0625rem;
  --fs-small: 0.875rem;

  /* Spacing / radius / shadow */
  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 1.5rem;
  --space-lg: 2.5rem;
  --space-xl: 4rem;
  --section-padding: clamp(3.75rem, 7.8vw, 6.5rem) 1rem;
  --radius-sm: 0.5rem;
  --radius-md: 0.75rem;
  --radius-lg: 1rem;
  --radius-pill: 999px;
  --shadow-sm: 0 1px 3px rgba(29, 49, 75, 0.08);
  --shadow-md: 0 6px 20px rgba(29, 49, 75, 0.1);
  --shadow-lg: 0 16px 40px rgba(29, 49, 75, 0.16);
  --container: 80rem;

  /* Legacy CodeStitch aliases — keep old rules working during migration */
  --primary: var(--navy-800);
  --primaryLight: var(--gold-100);
  --secondary: var(--gold-400);
  --secondaryLight: var(--gold-500);
  --headerColor: var(--text-heading);
  --bodyTextColor: var(--text-body);
  --bodyTextColorWhite: var(--white);
  --topperFontSize: var(--fs-topper);
  --headerFontSize: var(--fs-h1);
  --bodyFontSize: var(--fs-body);
  --sectionPadding: var(--section-padding);
}

/* ---------- Reset & base ---------- */

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

body {
  margin: 0;
  padding: 0;
  font-family: var(--font-sans);
  font-size: var(--fs-body);
  line-height: 1.65;
  color: var(--text-body);
  background-color: var(--bg-page);
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-sans);
  color: var(--text-heading);
  line-height: 1.15;
  margin: 0;
}

p {
  margin: 0;
}

a {
  color: var(--navy-600);
}

img,
svg {
  max-width: 100%;
  height: auto;
}

:focus-visible {
  outline: 2px solid var(--navy-600);
  outline-offset: 2px;
}

/* ---------- Shared text primitives ---------- */

.cs-topper {
  font-size: var(--fs-topper);
  line-height: 1.2em;
  text-transform: uppercase;
  text-align: inherit;
  letter-spacing: 0.12em;
  font-weight: 700;
  color: var(--gold-500);
  margin-bottom: 0.5rem;
  display: block;
}

.cs-title {
  font-size: var(--fs-h1);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.01em;
  text-align: inherit;
  max-width: 43.75rem;
  margin: 0 0 1rem 0;
  color: var(--text-heading);
  position: relative;
}

.cs-text {
  font-size: var(--fs-body);
  line-height: 1.65;
  text-align: inherit;
  width: 100%;
  max-width: 40.625rem;
  margin: 0;
  color: var(--text-body);
}

/* ---------- Buttons ---------- */

.cs-button-solid {
  font-size: 1rem;
  font-weight: 700;
  font-family: var(--font-sans);
  text-decoration: none;
  text-align: center;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.875rem 2rem;
  background-color: var(--gold-400);
  color: var(--navy-800);
  border: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background-color 0.2s, transform 0.2s, box-shadow 0.2s;
}

.cs-button-solid:hover {
  background-color: var(--gold-500);
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}

.cs-button-outline {
  font-size: 1rem;
  font-weight: 700;
  font-family: var(--font-sans);
  text-decoration: none;
  text-align: center;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.8125rem 2rem;
  background-color: transparent;
  color: var(--navy-800);
  border: 1.5px solid var(--navy-800);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background-color 0.2s, color 0.2s, border-color 0.2s;
}

.cs-button-outline:hover {
  background-color: var(--navy-800);
  color: var(--white);
}

.cs-button-outline.cs-on-dark {
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.6);
}

.cs-button-outline.cs-on-dark:hover {
  background-color: var(--white);
  color: var(--navy-800);
  border-color: var(--white);
}

/* ---------- Form controls ---------- */

.cs-label {
  font-size: var(--fs-small);
  font-weight: 700;
  color: var(--text-heading);
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
  width: 100%;
}

.cs-input {
  font-size: 1rem;
  font-family: inherit;
  width: 100%;
  height: 3rem;
  padding: 0 1rem;
  color: var(--text-heading);
  background-color: var(--white);
  border: 1.5px solid var(--navy-100);
  border-radius: var(--radius-sm);
  transition: border-color 0.2s, box-shadow 0.2s;
}

textarea.cs-input {
  height: auto;
  min-height: 7.5rem;
  padding: 0.75rem 1rem;
  resize: vertical;
}

.cs-input:focus {
  outline: none;
  border-color: var(--navy-600);
  box-shadow: 0 0 0 3px rgba(59, 86, 128, 0.15);
}

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

.cs-error {
  font-size: var(--fs-small);
  font-weight: 500;
  color: var(--error);
}

.form-status {
  font-size: 1rem;
  font-weight: 600;
  margin-top: 1rem;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-sm);
  display: none;
}

.form-status.is-error {
  display: block;
  color: var(--error);
  background-color: var(--error-bg);
}

.form-status.is-success {
  display: block;
  color: var(--success);
  background-color: var(--success-bg);
}

/* ---------- Card primitive ---------- */

.cs-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--cream-200);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}
