/* ============================================================
   KAIREN ECOSOLUTION — STORYBOOK LANDING PAGE
   Aesthetic: Editorial magazine / refined industrial
   Fonts: Instrument Serif (display) + Libre Franklin (body)
   ============================================================ */

/* --- DESIGN TOKENS --- */
:root {
  --green: #2E7D32;
  --green-deep: #1B5E20;
  --green-light: #4CAF50;
  --green-pale: #E8F5E9;
  --green-accent: #0A3D0A;
  --orange: #E65100;
  --orange-warm: #F57C00;
  --blue: #1565C0;
  --ink: #1a1a1a;
  --ink-light: #4a4a4a;
  --ink-muted: #888888;
  --paper: #FAFAF7;
  --paper-warm: #F0EDE6;
  --paper-green: #E8EFE5;
  --dark: #141414;
  --dark-soft: #1E1E1E;
  --white: #FFFFFF;
  --rule: #d8d4cc;
  --section-pad: clamp(4rem, 8vw, 7rem);
  --container: min(72rem, 90vw);
}

/* --- RESET & BASE --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }
body {
  font-family: 'Libre Franklin', sans-serif;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.7;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }

/* --- LAYOUT --- */
.container { width: var(--container); margin: 0 auto; }
.section-pad { padding: var(--section-pad) 0; }

/* --- TYPOGRAPHY --- */
.kicker {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-bottom: 0.8rem;
  color: var(--green);
}
.headline { font-family: 'Instrument Serif', serif; line-height: 1.12; }
.headline--hero { font-size: clamp(2.2rem, 4.5vw, 3.5rem); }
.headline--section { font-size: clamp(1.6rem, 3vw, 2.5rem); }
.headline--sub { font-size: clamp(1.1rem, 2vw, 1.5rem); font-family: 'Instrument Serif', serif; }
.body-large { font-size: clamp(0.95rem, 1.1vw, 1.1rem); line-height: 1.75; color: var(--ink-light); }
.source-cite { font-size: 0.75rem; color: var(--ink-muted); font-style: italic; margin-top: 0.4rem; }

/* --- NAVIGATION --- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  padding: 1.2rem 0;
  background: #FFFFFF;
  transition: all 0.4s ease;
}
.nav.scrolled {
  background: #FFFFFF;
  padding: 0.7rem 0;
  box-shadow: 0 1px 0 rgba(0,0,0,0.06);
}
.nav-inner { display: flex; justify-content: space-between; align-items: center; }
.nav-logo img { height: 56px; width: auto; transition: height 0.3s ease, opacity 0.3s; }
.nav-logo img:hover { opacity: 0.8; }
.nav.scrolled .nav-logo img { height: 40px; }
.nav-links { display: flex; gap: 2rem; list-style: none; }
.nav-links a {
  font-size: 0.8rem; font-weight: 500; color: rgba(0,0,0,0.7);
  letter-spacing: 0.03em; transition: color 0.3s;
}
.nav-links a:hover { color: var(--white); }
.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 0.5rem; }
.nav-toggle span { display: block; width: 20px; height: 2px; background: rgba(255,255,255,0.8); margin: 4px 0; transition: all 0.3s; }

@media (max-width: 768px) {
  .nav-toggle { display: block; }
  .nav-links {
    display: none; position: absolute; top: 100%; left: 0; right: 0;
    background: rgba(20,20,20,0.96); backdrop-filter: blur(16px);
    flex-direction: column; padding: 1.5rem 2rem; gap: 1rem;
  }
  .nav-links.active { display: flex; }
}

/* --- CHAPTER PROGRESS --- */
.progress-bar {
  position: fixed; top: 0; left: 0; height: 3px; z-index: 1001;
  background: var(--green); width: 0%; transition: width 0.1s linear;
}

/* --- HERO --- */
.hero {
  position: relative; min-height: 100vh; display: flex; align-items: center;
  overflow: hidden; background: var(--dark);
}
.hero-bg {
  position: absolute; inset: 0;
  background: url('hero-palm.jpg') center/cover no-repeat;
  opacity: 0.45;
}
.hero-bg::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(14,14,14,0.85) 0%, rgba(14,14,14,0.35) 50%, rgba(27,94,32,0.15) 100%);
}
.hero-content { position: relative; z-index: 2; padding: 8rem 0 4rem; max-width: 780px; }
.hero-content .headline { color: var(--white); }
.hero-content .headline em { font-style: normal; color: var(--green-light); }
.hero-eyebrow {
  font-size: 0.75rem; font-weight: 600; letter-spacing: 0.15em;
  color: var(--green-light); text-transform: uppercase; margin-bottom: 2rem;
}
.hero-title { color: var(--white); margin-bottom: 1.5rem; }
.hero-title em { font-style: normal; color: var(--green-light); }
.hero-lede { font-size: 1.1rem; line-height: 1.7; color: rgba(255,255,255,0.6); max-width: 600px; }
.hero-badge {
  display: inline-flex; align-items: center; gap: 0.6rem;
  margin-top: 2rem; padding: 0.6rem 1.2rem;
  background: rgba(46, 125, 50, 0.15); border: 1px solid rgba(46, 125, 50, 0.3);
  border-radius: 2px; font-size: 0.8rem; color: var(--green-light); font-weight: 500;
}
.hero-badge-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--green-light); animation: pulse 2s infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.4; } }

/* --- BELIEF (pull quote) --- */
.belief { padding: var(--section-pad) 0; background: var(--white); }
.belief-quote {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(1.3rem, 2.2vw, 1.8rem);
  line-height: 1.5; max-width: 780px; color: var(--ink);
}
.belief-quote em { font-style: italic; color: var(--green-deep); }
.belief-attr { font-size: 0.8rem; color: var(--ink-muted); margin-top: 1.5rem; }
.rule { border: none; border-top: 1px solid var(--rule); }
.rule--thick { border-top-width: 3px; border-color: var(--ink); }

/* --- WHY (urgency) --- */
.why { padding: var(--section-pad) 0; background: var(--paper-warm); position: relative; overflow: hidden; }
.why-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: start; }
.why-image {
  position: relative; border-radius: 2px; overflow: hidden;
  aspect-ratio: 4/3;
}
.why-image img { width: 100%; height: 100%; object-fit: cover; }
.why-image-overlay {
  position: absolute; bottom: 0; left: 0; right: 0; padding: 1.5rem;
  background: linear-gradient(transparent, rgba(0,0,0,0.7));
  color: var(--white); font-size: 0.75rem; font-weight: 600;
  letter-spacing: 0.1em; text-transform: uppercase;
}

@media (max-width: 1024px) { .why-grid { grid-template-columns: 1fr; gap: 2.5rem; } }

/* --- CONTEXT (dark, numbers) --- */
.context { padding: var(--section-pad) 0; background: var(--dark); color: var(--white); }
.context .kicker { color: var(--green-light); }
.context .headline--section { color: var(--white); }
.context .body-large { color: rgba(255,255,255,0.6); }
.context-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: start; margin-bottom: 3rem; }
.context-numbers { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem; margin-top: 2rem; }
.context-num { padding: 1.5rem; background: var(--dark-soft); border-left: 3px solid var(--green); }
.context-num-value {
  font-family: 'Instrument Serif', serif; font-size: 2.2rem; color: var(--green-light);
}
.context-num-label { font-size: 0.8rem; color: rgba(255,255,255,0.5); margin-top: 0.3rem; line-height: 1.4; }
.context-market {
  margin-top: 2rem; padding: 1.5rem; background: var(--dark-soft);
  border-left: 3px solid var(--orange);
}
.context-market p { font-size: 0.85rem; color: rgba(255,255,255,0.55); line-height: 1.6; }
.context-market strong { color: var(--orange-warm); }

@media (max-width: 1024px) {
  .context-grid { grid-template-columns: 1fr; }
  .context-numbers { grid-template-columns: 1fr 1fr; }
}

/* --- VALUE LADDER --- */
.ladder { padding: var(--section-pad) 0; background: var(--white); }
.ladder-intro { max-width: 680px; margin-bottom: 3rem; }
.ladder-steps { display: flex; flex-direction: column; gap: 0; position: relative; padding-left: 3rem; }
.ladder-steps::before {
  content: ''; position: absolute; left: 11px; top: 0; bottom: 0;
  width: 2px; background: var(--rule);
}
.ladder-step { display: grid; grid-template-columns: auto 1fr; gap: 2rem; padding: 2rem 0; position: relative; }
.ladder-step + .ladder-step { border-top: 1px solid var(--rule); }
.ladder-step-marker { position: absolute; left: -3rem; top: 2.3rem; }
.ladder-step-dot {
  width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--green);
  background: var(--white); position: relative; z-index: 1;
}
.ladder-step:nth-child(1) .ladder-step-dot { background: var(--green-light); border-color: var(--green-light); }
.ladder-step:nth-child(2) .ladder-step-dot { background: var(--green); border-color: var(--green); }
.ladder-step:nth-child(3) .ladder-step-dot { background: var(--orange); border-color: var(--orange); }
.ladder-step-phase {
  font-size: 0.65rem; font-weight: 700; letter-spacing: 0.15em;
  text-transform: uppercase; color: var(--green); margin-bottom: 0.3rem;
}
.ladder-step:nth-child(3) .ladder-step-phase { color: var(--orange); }
.ladder-step-title { font-family: 'Instrument Serif', serif; font-size: 1.4rem; color: var(--ink); margin-bottom: 0.8rem; }
.ladder-step-desc { font-size: 0.9rem; color: var(--ink-light); line-height: 1.7; margin-bottom: 1rem; }
.ladder-tags { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.ladder-tag {
  font-size: 0.65rem; font-weight: 600; padding: 0.2rem 0.6rem;
  background: var(--green-pale); color: var(--green-deep); letter-spacing: 0.02em;
}

/* --- COMPARISON TABLE (Drop-in) --- */
.comparison { padding: var(--section-pad) 0; background: var(--paper-green); }
.comparison-table {
  width: 100%; border-collapse: collapse; margin-top: 2rem;
  font-size: 0.85rem; background: var(--white);
  box-shadow: 0 2px 20px rgba(0,0,0,0.06);
}
.comparison-table thead th {
  padding: 1rem 1.2rem; text-align: left; font-weight: 700;
  font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase;
  border-bottom: 2px solid var(--ink);
}
.comparison-table thead th:nth-child(2) { background: var(--green-deep); color: var(--white); }
.comparison-table tbody td {
  padding: 0.8rem 1.2rem; border-bottom: 1px solid var(--rule);
  vertical-align: middle;
}
.comparison-table tbody td:first-child { font-weight: 600; color: var(--ink); }
.comparison-table tbody td:nth-child(2) { background: var(--green-pale); font-weight: 600; color: var(--green-deep); }
.comparison-table tbody tr:last-child td { border-bottom: none; }
.comp-check { color: var(--green); font-weight: 700; }
.comp-cross { color: #c62828; font-weight: 700; }
.comp-partial { color: var(--orange); font-weight: 600; }

@media (max-width: 768px) {
  .comparison-table { font-size: 0.75rem; }
  .comparison-table thead th, .comparison-table tbody td { padding: 0.6rem 0.8rem; }
}

/* --- TECHNOLOGY (minimal, green-tinted) --- */
.tech { padding: var(--section-pad) 0; background: var(--paper); }
.tech-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: start; margin-top: 2rem; }
.tech-badge {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.5rem 1rem; margin-top: 1.5rem;
  background: var(--green-deep); color: var(--white);
  font-size: 0.75rem; font-weight: 700; letter-spacing: 0.06em;
}
.tech-badge svg { width: 16px; height: 16px; }
.tech-changes { background: var(--white); padding: 2rem; box-shadow: 0 2px 20px rgba(0,0,0,0.05); }
.tech-changes-title {
  font-size: 0.65rem; font-weight: 700; letter-spacing: 0.15em;
  text-transform: uppercase; color: var(--ink-muted); margin-bottom: 1.5rem;
}
.tech-change { display: flex; align-items: flex-start; gap: 0.8rem; margin-bottom: 1rem; }
.tech-change:last-child { margin-bottom: 0; }
.tech-change-bar { width: 3px; min-height: 2rem; background: var(--green); flex-shrink: 0; margin-top: 0.2rem; }
.tech-change strong { display: block; font-size: 0.85rem; color: var(--ink); }
.tech-change span { font-size: 0.8rem; color: var(--ink-muted); }

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

/* --- PRODUCT SPECS --- */
.product { padding: var(--section-pad) 0; background: var(--white); }
.product-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: start; margin-top: 2rem; }
.spec-table { width: 100%; border-collapse: collapse; }
.spec-table tr td { padding: 0.7rem 0; border-bottom: 1px solid var(--rule); }
.spec-table tr:last-child td { border-bottom: none; }
.spec-table td:first-child { font-size: 0.9rem; color: var(--ink-light); }
.spec-table td:last-child {
  font-family: 'Instrument Serif', serif; font-size: 1rem;
  color: var(--green-deep); text-align: right;
}
.product-features { list-style: none; }
.product-features li {
  padding: 0.5rem 0; padding-left: 1.2rem; position: relative;
  font-size: 0.9rem; color: var(--ink-light); border-bottom: 1px solid var(--rule);
}
.product-features li:last-child { border-bottom: none; }
.product-features li::before {
  content: ''; position: absolute; left: 0; top: 0.85rem;
  width: 6px; height: 6px; background: var(--green); border-radius: 50%;
}

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

/* --- WHY KAIREN (dark, authentic) --- */
.cred { padding: var(--section-pad) 0; background: var(--dark); color: var(--white); }
.cred .kicker { color: var(--green-light); }
.cred .headline--section { color: var(--white); }
.cred-text { max-width: 680px; margin-bottom: 3rem; }
.cred-text .body-large { color: rgba(255,255,255,0.6); }
.cred-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.cred-card {
  padding: 2rem; background: var(--dark-soft);
  border-top: 3px solid var(--green);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.cred-card:hover { transform: translateY(-4px); box-shadow: 0 8px 30px rgba(0,0,0,0.3); }
.cred-card h4 {
  font-family: 'Instrument Serif', serif; font-size: 1.15rem;
  color: var(--white); margin-bottom: 0.8rem;
}
.cred-card p { font-size: 0.85rem; color: rgba(255,255,255,0.5); line-height: 1.65; }
.cred-card-num { font-family: 'Instrument Serif', serif; font-size: 2rem; color: var(--green-light); margin-bottom: 0.5rem; }

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

/* --- CTA / CLOSING --- */
.closing { padding: var(--section-pad) 0; background: var(--paper); }
.closing-inner { max-width: 780px; }
.closing-title {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(1.5rem, 2.5vw, 2.2rem);
  line-height: 1.2; margin-bottom: 1.5rem;
}
.closing-title em { font-style: italic; color: var(--green-deep); }
.cta-split { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; margin-top: 2.5rem; }
.cta-card {
  padding: 2rem; background: var(--white);
  border: 1px solid var(--rule); transition: all 0.3s ease;
  display: flex; flex-direction: column; gap: 0.8rem;
}
.cta-card:hover { border-color: var(--green); box-shadow: 0 4px 20px rgba(46,125,50,0.1); }
.cta-card-label { font-size: 0.65rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-muted); }
.cta-card-title { font-family: 'Instrument Serif', serif; font-size: 1.2rem; color: var(--ink); }
.cta-card-link {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-size: 0.85rem; font-weight: 600; color: var(--green);
  margin-top: auto; transition: gap 0.3s;
}
.cta-card:hover .cta-card-link { gap: 0.8rem; }
.cta-card-link svg { width: 14px; height: 14px; }

@media (max-width: 768px) { .cta-split { grid-template-columns: 1fr; } }

/* --- FOOTER --- */
.footer { padding: 3rem 0 2rem; background: var(--dark); color: rgba(255,255,255,0.5); }
.footer-inner { display: grid; grid-template-columns: 1fr auto auto; gap: 4rem; align-items: start; }
.footer-logo img { height: 36px; margin-bottom: 1rem; }
.footer-tagline { font-size: 0.8rem; color: rgba(255,255,255,0.4); }
.footer-legal { font-size: 0.75rem; color: rgba(255,255,255,0.3); margin-top: 0.5rem; }
.footer-col h5 { font-size: 0.7rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: rgba(255,255,255,0.6); margin-bottom: 0.8rem; }
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 0.4rem; }
.footer-col a { font-size: 0.8rem; color: rgba(255,255,255,0.4); transition: color 0.3s; }
.footer-col a:hover { color: var(--green-light); }
.footer-bottom {
  margin-top: 2rem; padding-top: 1.5rem;
  border-top: 1px solid rgba(255,255,255,0.08);
  display: flex; justify-content: space-between; font-size: 0.7rem;
}

@media (max-width: 768px) {
  .footer-inner { grid-template-columns: 1fr; gap: 2rem; }
}

/* --- REVEAL ANIMATIONS --- */
.reveal {
  opacity: 0; transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.visible { opacity: 1; transform: translateY(0); }
.reveal--delay-1 { transition-delay: 0.15s; }
.reveal--delay-2 { transition-delay: 0.3s; }
.reveal--delay-3 { transition-delay: 0.45s; }

/* --- COUNTER ANIMATION --- */
.counter-value { font-variant-numeric: tabular-nums; }

/* --- PHOTO CREDIT --- */
.photo-credit {
  font-size: 0.6rem; color: rgba(255,255,255,0.3);
  position: absolute; bottom: 0.5rem; right: 0.5rem;
}
