/* ===================================
   Lightfield Farm - MVP Site Styles
   =================================== */

/* --- Self-hosted Fonts --- */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/inter-400.ttf') format('truetype');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('fonts/inter-500.ttf') format('truetype');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('fonts/inter-600.ttf') format('truetype');
}
@font-face {
  font-family: 'Source Serif 4';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/sourceserif4-400.ttf') format('truetype');
}
@font-face {
  font-family: 'Source Serif 4';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('fonts/sourceserif4-600.ttf') format('truetype');
}
@font-face {
  font-family: 'Source Serif 4';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/sourceserif4-400i.ttf') format('truetype');
}

/* --- Reset & Base --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  /* Colors */
  --golden-hour: #D4A04A;
  --golden-hour-light: #E8C477;
  --warm-cream: #F5EFE0;
  --deep-soil: #3B2A1A;
  --field-green: #5A7247;
  --sky-wash: #C5D5E4;
  --milk-white: #FDFCF8;
  --straw: #E8D5A3;
  --clay: #9B7653;
  --dusk: #6B5B4E;
  --iron: #4A4A48;

  /* Typography */
  --font-serif: "Source Serif 4", Georgia, serif;
  --font-sans: "Inter", "Helvetica Neue", sans-serif;

  /* Layout */
  --content-width: 42rem;
  --wide-width: 64rem;
  --section-padding: 5rem 1.5rem;
  --section-padding-mobile: 3rem 1.25rem;
}

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-serif);
  color: var(--deep-soil);
  background-color: var(--warm-cream);
  line-height: 1.7;
  font-size: 1.0625rem;
}

/* Subtle linen texture */
body::before {
  content: "";
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.03;
  background-image: url("data:image/svg+xml,%3Csvg width='6' height='6' viewBox='0 0 6 6' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%233B2A1A' fill-opacity='1'%3E%3Cpath d='M5 0h1L0 5V4zM6 5v1H5z'/%3E%3C/g%3E%3C/svg%3E");
}

::selection {
  background-color: var(--straw);
  color: var(--deep-soil);
}

/* --- Typography --- */
h1, h2, h3, h4 {
  font-family: var(--font-serif);
  line-height: 1.2;
  font-weight: 600;
  color: var(--deep-soil);
}

h1 { font-size: clamp(2rem, 5vw, 3.25rem); }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.25rem); margin-bottom: 1.5rem; }
h3 { font-size: clamp(1.15rem, 2.5vw, 1.5rem); margin-bottom: 0.75rem; }
h4 { font-size: clamp(1rem, 2vw, 1.2rem); margin-bottom: 0.5rem; font-weight: 600; }

p {
  max-width: var(--content-width);
  margin-bottom: 1.25rem;
  color: var(--dusk);
}

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

blockquote {
  border-left: 2px solid var(--golden-hour);
  padding-left: 1.5rem;
  margin: 2rem 0;
  font-style: italic;
  color: var(--dusk);
}

/* --- Links --- */
a {
  color: var(--deep-soil);
  text-decoration-color: var(--golden-hour);
  text-underline-offset: 3px;
  transition: color 0.2s ease;
}
a:hover { color: var(--golden-hour); }

:focus-visible {
  outline: 2px solid var(--golden-hour);
  outline-offset: 2px;
  border-radius: 2px;
}

/* --- Navigation --- */
.site-nav {
  font-family: var(--font-sans);
  padding: 1.25rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: var(--wide-width);
  margin: 0 auto;
}

.site-nav .logo {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  font-weight: 600;
  text-decoration: none;
  color: var(--deep-soil);
  letter-spacing: -0.01em;
}
.site-nav .logo:hover { color: var(--golden-hour); }

.nav-links {
  display: flex;
  gap: 2rem;
  list-style: none;
  align-items: center;
}

.nav-links a {
  font-size: 0.875rem;
  font-weight: 500;
  text-decoration: none;
  color: var(--dusk);
  letter-spacing: 0.01em;
  transition: color 0.2s ease;
}
.nav-links a:hover { color: var(--deep-soil); }
.nav-links a.active { color: var(--deep-soil); }

/* Mobile nav toggle */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  color: var(--deep-soil);
}

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

  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    background: var(--warm-cream);
    flex-direction: column;
    padding: 1.5rem;
    gap: 1.25rem;
    border-bottom: 1px solid var(--straw);
    z-index: 50;
  }
  .nav-links.open { display: flex; }

  .site-nav { position: relative; }
}

/* --- Sections --- */
.section {
  padding: var(--section-padding);
}
@media (max-width: 768px) {
  .section { padding: var(--section-padding-mobile); }
}

.section-inner {
  max-width: var(--wide-width);
  margin: 0 auto;
}

.section-narrow .section-inner {
  max-width: var(--content-width);
}

.bg-milk { background-color: var(--milk-white); }
.bg-cream { background-color: var(--warm-cream); }
.bg-soil { background-color: var(--deep-soil); }
.bg-soil h2, .bg-soil h3 { color: var(--warm-cream); }
.bg-soil p { color: var(--straw); }
.bg-soil a { color: var(--golden-hour-light); }

/* --- Hero --- */
.hero {
  padding: 6rem 1.5rem 5rem;
  text-align: center;
}
@media (max-width: 768px) {
  .hero { padding: 4rem 1.25rem 3rem; }
}

.hero h1 {
  margin-bottom: 1rem;
}

.hero .subline {
  font-size: clamp(1.05rem, 1.5vw, 1.2rem);
  color: var(--dusk);
  max-width: 36rem;
  margin: 0 auto;
  line-height: 1.6;
}

/* Page hero (subpages) */
.page-hero {
  padding: 4rem 1.5rem 3rem;
  text-align: center;
  background-color: var(--milk-white);
}
@media (max-width: 768px) {
  .page-hero { padding: 3rem 1.25rem 2rem; }
}

.page-hero h1 { margin-bottom: 0.75rem; }
.page-hero .subline {
  font-size: 1.1rem;
  color: var(--dusk);
  max-width: 32rem;
  margin: 0 auto;
}

/* --- Cards --- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin: 2rem 0;
}

.card {
  background: var(--milk-white);
  border: 1px solid rgba(232, 213, 163, 0.4);
  border-radius: 4px;
  padding: 2rem;
}

.card h3 { color: var(--deep-soil); }
.card p { color: var(--dusk); font-size: 0.95rem; }

/* --- Apprenticeship Feature --- */
.apprentice-feature {
  max-width: var(--content-width);
  margin: 0 auto;
  text-align: center;
  padding: 2.5rem 2rem;
  border: 2px solid var(--golden-hour);
  border-radius: 4px;
  background: var(--milk-white);
}
.apprentice-feature h2 {
  margin-bottom: 1.25rem;
}
.apprentice-feature p {
  margin-left: auto;
  margin-right: auto;
  text-align: left;
}
.apprentice-feature .btn {
  margin-top: 1rem;
}

/* --- Buttons / CTAs --- */
.btn {
  display: inline-block;
  font-family: var(--font-sans);
  font-size: 0.875rem;
  font-weight: 500;
  padding: 0.75rem 2rem;
  border-radius: 3px;
  text-decoration: none;
  transition: background-color 0.2s ease, color 0.2s ease;
  cursor: pointer;
  border: none;
}

.btn-primary {
  background-color: var(--golden-hour);
  color: var(--deep-soil);
}
.btn-primary:hover {
  background-color: var(--golden-hour-light);
  color: var(--deep-soil);
}

.btn-outline {
  background: transparent;
  border: 1px solid var(--golden-hour);
  color: var(--deep-soil);
}
.btn-outline:hover {
  background-color: var(--golden-hour);
  color: var(--deep-soil);
}

/* Link arrow */
.link-arrow {
  font-family: var(--font-sans);
  font-size: 0.9rem;
  font-weight: 500;
  text-decoration: none;
  color: var(--deep-soil);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: gap 0.2s ease, color 0.2s ease;
}
.link-arrow:hover {
  color: var(--golden-hour);
  gap: 0.75rem;
}
.link-arrow::after {
  content: "\2192";
}

/* --- Steps --- */
.steps {
  list-style: none;
  counter-reset: step-counter;
}

.step {
  counter-increment: step-counter;
  display: flex;
  gap: 1.25rem;
  margin-bottom: 2rem;
  align-items: flex-start;
}

.step-number {
  flex-shrink: 0;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  background-color: rgba(212, 160, 74, 0.15);
  color: var(--golden-hour);
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.step-content {
  flex: 1;
}

.step-content h3 { margin-bottom: 0.5rem; }

/* --- Two-column layout --- */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  margin: 2rem 0;
}
@media (max-width: 768px) {
  .two-col { grid-template-columns: 1fr; }
}

/* --- Chain visual (Soil > Grass > Herd > Family) --- */
.chain {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  margin: 2.5rem 0;
  flex-wrap: wrap;
}

.chain-item {
  display: flex;
  align-items: center;
  gap: 0;
}

.chain-node {
  width: 5rem;
  height: 5rem;
  border-radius: 50%;
  background: var(--warm-cream);
  border: 2px solid rgba(212, 160, 74, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-serif);
  font-size: 1rem;
  font-weight: 600;
  color: var(--deep-soil);
}

.chain-arrow {
  width: 2rem;
  text-align: center;
  color: rgba(212, 160, 74, 0.5);
  font-size: 1.25rem;
}

@media (max-width: 480px) {
  .chain { flex-direction: column; gap: 0.25rem; }
  .chain-arrow { transform: rotate(90deg); }
}

/* --- Divider --- */
.divider {
  height: 1px;
  background: linear-gradient(to right, transparent, rgba(212, 160, 74, 0.3), transparent);
  margin: 3rem 0;
  border: none;
}

/* --- Contact Form --- */
.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--deep-soil);
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 0.75rem 1rem;
  font-family: var(--font-serif);
  font-size: 1rem;
  color: var(--deep-soil);
  background: var(--milk-white);
  border: 1px solid var(--straw);
  border-radius: 3px;
  transition: border-color 0.2s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--golden-hour);
}

.form-group textarea {
  min-height: 8rem;
  resize: vertical;
}

/* --- Form Messages --- */
.form-message {
  padding: 1.25rem 1.5rem;
  border-radius: 4px;
  margin-bottom: 1.5rem;
}
.form-message p { margin: 0; font-size: 0.95rem; }
.form-message-success {
  background: rgba(90, 114, 71, 0.1);
  border: 1px solid rgba(90, 114, 71, 0.3);
  color: var(--deep-soil);
}
.form-message-error {
  background: rgba(180, 80, 60, 0.1);
  border: 1px solid rgba(180, 80, 60, 0.3);
  color: var(--deep-soil);
}

/* --- Footer --- */
.site-footer {
  background-color: var(--deep-soil);
  color: var(--straw);
  padding: 3rem 1.5rem 2rem;
}

.footer-inner {
  max-width: var(--wide-width);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.footer-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 2rem;
}

.footer-brand {
  font-family: var(--font-serif);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--warm-cream);
}

.footer-nav {
  display: flex;
  gap: 1.5rem;
  list-style: none;
  flex-wrap: wrap;
}

.footer-nav a {
  font-family: var(--font-sans);
  font-size: 0.8rem;
  color: var(--clay);
  text-decoration: none;
  transition: color 0.2s ease;
}
.footer-nav a:hover { color: var(--warm-cream); }

.footer-contact {
  font-family: var(--font-sans);
  font-size: 0.85rem;
  color: var(--clay);
}
.footer-contact a {
  color: var(--golden-hour-light);
  text-decoration: none;
}
.footer-contact a:hover { color: var(--warm-cream); }

.footer-disclaimer {
  font-family: var(--font-sans);
  font-size: 0.8rem;
  color: var(--clay);
  line-height: 1.5;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(155, 118, 83, 0.2);
}

.footer-bottom {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  color: rgba(155, 118, 83, 0.6);
}

/* --- Utility --- */
.text-center { text-align: center; }
.mx-auto { margin-left: auto; margin-right: auto; }
.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }

/* List with check marks */
.check-list {
  list-style: none;
  padding: 0;
}
.check-list li {
  padding: 0.4rem 0;
  padding-left: 1.75rem;
  position: relative;
  color: var(--dusk);
  font-size: 0.95rem;
}
.check-list li::before {
  content: "\2713";
  position: absolute;
  left: 0;
  color: var(--field-green);
  font-weight: 600;
}

/* Scrollbar */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--warm-cream); }
::-webkit-scrollbar-thumb { background: var(--clay); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--dusk); }
