/* ═══════════════════════════════════════════════════════════
   DESIGN SYSTEM — ReWeave360
   Aesthetic: Organic Luxury × Earth-Intelligence
   main.css — Global styles, typography, layout, utilities
   ═══════════════════════════════════════════════════════════ */

/* ── Design Tokens ── */
:root {
  --moss: #2D4A2D;
  --forest: #1A3320;
  --sage: #7A9E7E;
  --mint: #B8D4B8;
  --linen: #F2EDE4;
  --sand: #E8DDD0;
  --clay: #C4956A;
  --warm: #8B6355;
  --cream: #FAF7F2;
  --charcoal: #1C1C1A;
  --stone: #6B6B65;
  --gold: #C9A84C;
  --sky: #4A8FA8;

  --font-display: 'Fraunces', Georgia, serif;
  --font-body: 'DM Sans', system-ui, sans-serif;

  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 28px;
  --radius-xl: 48px;

  --shadow-soft: 0 4px 32px rgba(29, 67, 29, 0.08);
  --shadow-card: 0 2px 16px rgba(29, 67, 29, 0.06), 0 0 1px rgba(29, 67, 29, 0.1);
  --shadow-lift: 0 16px 48px rgba(29, 67, 29, 0.14);

  --transition: 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

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

html {
  scroll-behavior: smooth;
  font-size: 15px;
}

body {
  font-family: var(--font-body);
  background: var(--cream);
  color: var(--charcoal);
  line-height: 1.6;
  overflow-x: hidden;
}

/* ── Typography ── */
.display-xl {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 4.5vw, 3.8rem);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.03em;
  color: var(--forest);
}

.display-lg {
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 3.2vw, 2.6rem);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.025em;
  color: var(--forest);
}

.display-md {
  font-family: var(--font-display);
  font-size: clamp(1.3rem, 2.2vw, 1.9rem);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--forest);
}

.section-label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--sage);
  display: flex;
  align-items: center;
  gap: 8px;
}

.section-label::before {
  content: '';
  width: 24px;
  height: 2px;
  background: var(--sage);
  border-radius: 2px;
}

.lead {
  font-size: 1rem;
  color: var(--stone);
  line-height: 1.7;
  max-width: 560px;
}

/* ── Layout ── */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
}

.container-wide {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 32px;
}

.pt-nav {
  padding-top: 60px;
}

section {
  padding: 64px 0;
}

/* ── Grid ── */
.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

/* ── Divider ── */
.divider {
  height: 1px;
  background: var(--sand);
  margin: 32px 0;
}

/* ── Metric / Stat ── */
.stat-value {
  font-family: var(--font-display);
  font-size: 2.2rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1;
}

.stat-unit {
  font-size: 1rem;
  font-weight: 400;
  opacity: 0.7;
}

.stat-label {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--stone);
  margin-top: 4px;
}

/* ── Progress Bar ── */
.progress-track {
  width: 100%;
  height: 8px;
  background: var(--sand);
  border-radius: 4px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  border-radius: 4px;
  background: linear-gradient(90deg, var(--sage), var(--moss));
  transition: width 1.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* ── Utilities ── */
.text-center { text-align: center; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.flex-start { display: flex; align-items: flex-start; gap: 16px; }

.gap-4  { gap: 4px; }
.gap-8  { gap: 8px; }
.gap-12 { gap: 12px; }
.gap-16 { gap: 16px; }
.gap-20 { gap: 20px; }
.gap-24 { gap: 24px; }
.gap-32 { gap: 32px; }

.mb-8  { margin-bottom: 8px; }
.mb-12 { margin-bottom: 12px; }
.mb-16 { margin-bottom: 16px; }
.mb-20 { margin-bottom: 20px; }
.mb-24 { margin-bottom: 24px; }
.mb-32 { margin-bottom: 32px; }
.mb-40 { margin-bottom: 40px; }
.mb-48 { margin-bottom: 48px; }

.mt-auto { margin-top: auto; }
.w-full  { width: 100%; }
.rounded-full { border-radius: 9999px; }
.hidden  { display: none; }

.section-header { margin-bottom: 44px; }

.col-gap {
  display: flex;
  flex-direction: column;
}

.chip {
  display: inline-block;
  padding: 3px 10px;
  background: var(--sand);
  border-radius: 20px;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--stone);
}

/* ── Scrollbar ── */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: var(--sand); }
::-webkit-scrollbar-thumb { background: var(--sage); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--moss); }

/* ── About Page Specific ── */
.about-hero {
  background: var(--linen);
  padding: 120px 0 80px;
  border-bottom: 1px solid var(--sand);
}

.value-item {
  background: white;
  border-radius: var(--radius-md);
  padding: 24px;
  border: 1px solid var(--sand);
}

.team-card {
  background: white;
  border-radius: var(--radius-lg);
  padding: 28px;
  text-align: center;
  border: 1px solid var(--sand);
  transition: var(--transition);
}

.team-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lift);
}

.team-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.2rem;
  color: white;
  margin: 0 auto 14px;
}

/* ── Partner Page ── */
.register-card {
  background: white;
  border-radius: var(--radius-xl);
  padding: 48px;
  box-shadow: var(--shadow-lift);
  border: 1px solid var(--sand);
}

.benefit-card {
  background: white;
  border-radius: var(--radius-lg);
  padding: 28px;
  border: 1px solid var(--sand);
  transition: var(--transition);
}

.benefit-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lift);
}

/* ── How It Works Page ── */
.how-section {
  background: var(--linen);
  padding: 80px 0;
}

.hiw-step {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
  padding: 80px 0;
  border-bottom: 1px dashed var(--sand);
}

.hiw-step:last-child {
  border-bottom: none;
}

.hiw-step.reverse {
  direction: rtl;
}

.hiw-step.reverse > * {
  direction: ltr;
}

.hiw-step-number {
  font-family: var(--font-display);
  font-size: 6rem;
  font-weight: 800;
  color: rgba(255, 255, 255, 0.15);
  line-height: 1;
  position: absolute;
  top: 20px;
  left: 20px;
}

.hiw-step-visual {
  border-radius: var(--radius-xl);
  padding: 60px 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 280px;
  position: relative;
  overflow: hidden;
}

/* ── Impact / Blog section specific ── */
.blog-card {
  background: white;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--sand);
  transition: var(--transition);
}

.blog-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lift);
}

.blog-featured {
  grid-column: span 3;
  display: grid;
  grid-template-columns: 1fr 1.5fr;
}

.blog-image {
  height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  position: relative;
  overflow: hidden;
}

.blog-body { padding: 24px; }
.blog-meta { font-size: 0.75rem; color: var(--stone); margin-bottom: 10px; }

.blog-title {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--forest);
  line-height: 1.3;
  margin-bottom: 10px;
  letter-spacing: -0.01em;
}

.blog-excerpt {
  font-size: 0.82rem;
  color: var(--stone);
  line-height: 1.6;
}

/* ── Testimonials ── */
.testimonial-card {
  background: white;
  border-radius: var(--radius-xl);
  padding: 48px;
  border: 1px solid var(--sand);
}

.testimonial-quote {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 300;
  font-style: italic;
  line-height: 1.6;
  color: var(--forest);
  margin-bottom: 28px;
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: 16px;
}

.testimonial-avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--sage), var(--moss));
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 700;
  font-size: 1.1rem;
}

/* ── Partner Strip ── */
.partner-strip {
  background: var(--sand);
  padding: 40px 0;
  overflow: hidden;
}

.partner-scroll {
  display: flex;
  gap: 60px;
  animation: scrollLeft 25s linear infinite;
  width: max-content;
}

.partner-strip:hover .partner-scroll {
  animation-play-state: paused;
}

.partner-logo {
  height: 32px;
  opacity: 1;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.1rem;
  color: var(--forest);
  white-space: nowrap;
  display: flex;
  align-items: center;
}

.partner-logo svg { width: auto; height: 100%; }

/* ── Footer ── */
footer {
  background: var(--forest);
  color: white;
  padding: 80px 0 40px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 60px;
}

.footer-logo-text {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--mint);
  margin-bottom: 14px;
}

.footer-desc {
  font-size: 0.87rem;
  color: rgba(184, 212, 184, 0.5);
  line-height: 1.7;
}

.footer-heading {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(184, 212, 184, 0.4);
  margin-bottom: 16px;
}

.footer-links { list-style: none; }
.footer-links li { margin-bottom: 10px; }

.footer-links a {
  font-size: 0.87rem;
  color: rgba(184, 212, 184, 0.6);
  text-decoration: none;
  transition: var(--transition);
}

.footer-links a:hover { color: var(--mint); }

.footer-bottom {
  border-top: 1px solid rgba(122, 158, 126, 0.15);
  padding-top: 32px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-bottom-text {
  font-size: 0.8rem;
  color: rgba(184, 212, 184, 0.35);
}

/* ══════════════════════════════════════════════════
   RESPONSIVE
   ══════════════════════════════════════════════════ */
@media (max-width: 1024px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .display-xl { font-size: clamp(2rem, 4vw, 3rem); }
  .display-lg { font-size: clamp(1.5rem, 3vw, 2.2rem); }
  .display-md { font-size: clamp(1.2rem, 2vw, 1.7rem); }
  .hero-stats { grid-template-columns: repeat(2, 1fr); gap: 1px; }
  .hiw-step { grid-template-columns: 1fr !important; gap: 32px; }
}

@media (max-width: 768px) {
  .blog-featured {
    grid-column: span 1;
    display: flex;
    flex-direction: column;
  }

  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }

  section { padding: 44px 0; }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .testimonial-card,
  .register-card,
  .card {
    padding: 20px;
  }

  .container, .container-wide { padding: 0 16px; }
}

@media (max-width: 480px) {
  .display-xl, .display-lg { font-size: 1.8rem; }
  .display-md { font-size: 1.3rem; }
  .stat-value { font-size: 1.8rem; }
}
