/* ==========================================================================
   Nuform Green - components
   ========================================================================== */

/* ---------- Buttons ---------- */
.btn-brand, .btn-ghost {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 26px; border-radius: 999px; font-weight: 600; font-size: 0.95rem;
  text-decoration: none; cursor: pointer; transition: var(--transition); border: 1px solid transparent;
}
.btn-brand {
  background: var(--brand); color: #fff;
  box-shadow: 0 6px 20px rgba(var(--brand-rgb), 0.35);
}
.btn-brand:hover, .btn-brand:focus-visible {
  background: var(--brand-dark); color: #fff; transform: translateY(-2px);
  box-shadow: 0 10px 28px rgba(var(--brand-rgb), 0.5);
}
.btn-brand:disabled { opacity: 0.7; transform: none; cursor: wait; }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--surface-border); }
.btn-ghost:hover { background: var(--surface-card); border-color: var(--gold); color: var(--text); }

/* ---------- Header ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 1030;
  background: var(--header-bg); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--surface-border);
  transition: box-shadow 0.3s ease, background-color 0.3s ease;
}
.site-header.is-scrolled { box-shadow: var(--shadow); }
.site-header .navbar { min-height: var(--header-h); padding: 0; }
.brand-link { display: block; width: 150px; color: var(--text); }
.brand-link svg { display: block; width: 100%; height: auto; }

.site-header .nav-link {
  color: var(--text-muted); font-size: 0.95rem; font-weight: 500;
  position: relative; transition: var(--transition);
}
.site-header .nav-link::after {
  content: ''; position: absolute; left: 0.5rem; right: 0.5rem; bottom: 2px; height: 2px;
  background: var(--gold); transform: scaleX(0); transform-origin: left; transition: transform 0.3s var(--ease);
}
.site-header .nav-link:hover, .site-header .nav-link.active { color: var(--accent); }
.site-header .nav-link:hover::after, .site-header .nav-link.active::after { transform: scaleX(1); }

.navbar-toggler { border: 1px solid var(--surface-border); color: var(--text); padding: 6px 10px; }
.navbar-toggler:focus { box-shadow: none; }
.navbar-toggler .bi { font-size: 1.5rem; line-height: 1; }

.theme-toggle {
  width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center;
  background: var(--surface-card); border: 1px solid var(--surface-border); color: var(--text);
  cursor: pointer; transition: var(--transition);
}
.theme-toggle:hover { border-color: var(--gold); transform: rotate(15deg); }
.theme-toggle .bi { font-size: 1.1rem; }
:root[data-theme="dark"] .theme-toggle .bi-moon-stars-fill,
:root:not([data-theme]) .theme-toggle .bi-moon-stars-fill { display: none; }
:root[data-theme="light"] .theme-toggle .bi-sun-fill { display: none; }

@media (max-width: 991.98px) {
  .site-header .navbar-collapse {
    background: var(--surface); border: 1px solid var(--surface-border); border-radius: var(--radius);
    padding: 12px 16px 16px; margin-bottom: 12px;
  }
  .site-header .navbar-collapse .btn-brand { width: 100%; margin-top: 8px; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative; text-align: center; overflow: hidden;
  min-height: max(100vh, 640px); display: flex; align-items: center;
  padding: calc(var(--header-h) + 48px) 0 clamp(200px, 26vw, 340px);
}
.hero::before { /* ambient glow */
  content: ''; position: absolute; top: -140px; left: 50%; width: 700px; height: 560px;
  transform: translateX(-50%); border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle, var(--glow) 0%, transparent 70%); filter: blur(70px);
}
.hero-bg {
  position: absolute; inset: 0; pointer-events: none;
  background: url('../img/hero-bg.svg') center bottom / cover no-repeat;
  -webkit-mask-image: linear-gradient(to bottom, #000 78%, transparent 100%);
          mask-image: linear-gradient(to bottom, #000 78%, transparent 100%);
}
.hero .container { position: relative; z-index: 1; width: 100%; }

.badge-pill {
  display: inline-flex; align-items: center; gap: 8px; padding: 6px 16px; margin-bottom: 28px;
  border-radius: 999px; background: var(--surface-card); border: 1px solid var(--surface-border);
  color: var(--accent); font-size: 0.85rem; font-weight: 600; text-align: left;
}
.badge-dot {
  flex: none; width: 8px; height: 8px; background: var(--gold); border-radius: 50%;
  animation: pulse 2s infinite;
}
@keyframes pulse {
  0%   { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(var(--gold-rgb), 0.7); }
  70%  { transform: scale(1);    box-shadow: 0 0 0 10px rgba(var(--gold-rgb), 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(var(--gold-rgb), 0); }
}

.hero h1 {
  font-size: clamp(2.2rem, 5.5vw, 4.4rem); line-height: 1.1; font-weight: 700;
  max-width: 900px; margin: 0 auto 24px;
}
.hero h1 span {
  background: var(--heading-grad); -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.hero p.lead-text {
  font-size: clamp(1rem, 1.8vw, 1.25rem); color: var(--text-muted);
  max-width: 680px; margin: 0 auto 40px;
}
.hero-actions { display: flex; justify-content: center; gap: 16px; flex-wrap: wrap; }

/* Keep the scene proportional on narrow screens instead of zooming into the plant */
@media (max-width: 767.98px) {
  .hero-bg { background-size: 1000px auto; background-position: 58% bottom; }
}

/* ---------- Metrics ---------- */
.metrics-bar {
  position: relative; z-index: 2; margin-top: clamp(-150px, -12vw, -70px); margin-bottom: 100px;
}
.metric-card {
  height: 100%; background: var(--surface); border: 1px solid var(--surface-border);
  padding: 28px 24px; border-radius: var(--radius); position: relative; overflow: hidden;
  transition: var(--transition);
}
.metric-card::before {
  content: ''; position: absolute; inset: 0 0 auto 0; height: 3px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent); opacity: 0; transition: var(--transition);
}
.metric-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.metric-card:hover::before { opacity: 1; }
.metric-num { font-family: var(--font-head); font-size: 2.25rem; font-weight: 700; line-height: 1.2; margin-bottom: 4px; }
.metric-num span { color: var(--accent); font-size: 1.5rem; }
.metric-label { color: var(--text-muted); font-size: 0.9rem; font-weight: 500; }

/* ---------- Sections ---------- */
.section { padding: 0 0 110px; }
.section-title { text-align: center; margin-bottom: 56px; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px; margin-bottom: 14px;
  color: var(--accent); font-size: 0.8rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase;
}
.eyebrow::before { content: ''; width: 28px; height: 3px; border-radius: 2px; background: var(--gold); }
.section-title h2 { font-size: clamp(1.8rem, 3.5vw, 2.75rem); margin-bottom: 16px; }
.section-title p { color: var(--text-muted); max-width: 600px; margin: 0 auto; }

/* Feature cards */
.feature-card {
  height: 100%; background: var(--surface); border: 1px solid var(--surface-border);
  border-radius: var(--radius); padding: 36px 30px; transition: var(--transition);
}
.feature-card:hover { transform: translateY(-5px); border-color: var(--brand); box-shadow: var(--shadow); }
.feature-icon {
  width: 52px; height: 52px; border-radius: 12px; display: grid; place-items: center; margin-bottom: 24px;
  background: rgba(var(--brand-rgb), 0.14); border: 1px solid var(--surface-border);
  color: var(--accent); font-size: 1.5rem; transition: var(--transition);
}
.feature-card:hover .feature-icon { background: var(--brand); color: #fff; }
.feature-card h3 { font-size: 1.35rem; margin-bottom: 12px; }
.feature-card p { color: var(--text-muted); font-size: 0.95rem; line-height: 1.7; margin: 0; }

/* Process steps */
.steps { counter-reset: step; position: relative; }
.step {
  height: 100%; position: relative; padding: 32px 26px 28px; border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--surface-border); transition: var(--transition);
}
.step:hover { transform: translateY(-4px); border-color: var(--gold); box-shadow: var(--shadow); }
.step-num {
  width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; margin-bottom: 20px;
  background: var(--gold); color: #1c1700; font-family: var(--font-head); font-weight: 700; font-size: 1.1rem;
}
.step h3 { font-size: 1.15rem; margin-bottom: 8px; }
.step p { color: var(--text-muted); font-size: 0.92rem; margin: 0; }
@media (min-width: 992px) {
  .steps .col-lg-3:not(:last-child) .step::after { /* connector */
    content: ''; position: absolute; top: 55px; left: calc(100% - 4px); width: calc(var(--bs-gutter-x) + 8px);
    border-top: 2px dashed var(--gold); opacity: 0.7;
  }
}

/* FAQ accordion */
.faq .accordion-item {
  background: var(--surface); border: 1px solid var(--surface-border) !important; border-radius: var(--radius) !important;
  margin-bottom: 14px; overflow: hidden; transition: border-color 0.25s ease;
}
.faq .accordion-item:has(.show) { border-color: var(--brand) !important; }
.faq .accordion-button {
  background: transparent; color: var(--text); font-weight: 600; padding: 20px 24px; box-shadow: none;
}
.faq .accordion-button:not(.collapsed) { color: var(--accent); background: transparent; }
.faq .accordion-button:focus-visible { outline: 3px solid var(--gold); outline-offset: -3px; }
.faq .accordion-body { color: var(--text-muted); padding: 0 24px 22px; }
.faq .accordion-button::after { filter: none; }
:root[data-theme="dark"] .faq .accordion-button::after { filter: invert(1) brightness(1.4); }

/* ---------- Form ---------- */
.form-section {
  background: var(--surface); border: 1px solid var(--surface-border); border-radius: 24px;
  padding: clamp(28px, 6vw, 60px) clamp(20px, 5vw, 48px); max-width: 800px; margin: 0 auto;
  position: relative; overflow: hidden;
}
.form-section::before {
  content: ''; position: absolute; inset: 0 0 auto 0; height: 4px;
  background: linear-gradient(90deg, var(--brand), var(--gold));
}
.form-section h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); }
.form-section .form-label { font-size: 0.85rem; color: var(--text-muted); font-weight: 500; margin-bottom: 6px; }
.form-control, .form-select {
  background-color: var(--surface-card); border: 1px solid var(--surface-border); color: var(--text);
  padding: 13px 16px; border-radius: 10px; font-size: 0.95rem; transition: var(--transition);
}
.form-control::placeholder { color: var(--text-dim); }
.form-control:focus, .form-select:focus {
  background-color: var(--surface-card); color: var(--text); border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(var(--gold-rgb), 0.35);
}
.form-control.is-invalid, .form-select.is-invalid { border-color: #dc3545; background-image: none; }
.invalid-feedback { font-size: 0.8rem; }
.hp-field { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-alert { border-radius: 12px; font-size: 0.92rem; margin-top: 20px; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--footer-bg); border-top: 1px solid var(--surface-border);
  padding: 80px 0 32px; color: var(--text-muted); font-size: 0.92rem;
}
.footer-logo { display: block; width: 170px; color: var(--text); margin-bottom: 18px; }
.footer-logo svg { display: block; width: 100%; height: auto; }
.site-footer h4 { color: var(--text); font-size: 1.05rem; margin-bottom: 12px; }
.site-footer h5 {
  color: var(--text); font-size: 0.85rem; margin-bottom: 18px; text-transform: uppercase; letter-spacing: 0.08em;
}
.site-footer ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.site-footer a { color: var(--text-muted); text-decoration: none; transition: var(--transition); }
.site-footer a:hover { color: var(--accent); }
.footer-contact li { display: flex; gap: 10px; align-items: flex-start; }
.footer-contact .bi { color: var(--gold); margin-top: 3px; }
.social { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.social a {
  width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center;
  background: var(--surface); border: 1px solid var(--surface-border); color: var(--text); font-size: 1.05rem;
}
.social a:hover { background: var(--brand); border-color: var(--brand); color: #fff; transform: translateY(-3px); }
.copyright {
  margin-top: 56px; padding-top: 28px; border-top: 1px solid var(--surface-border);
  text-align: center; color: var(--text-dim); font-size: 0.85rem;
}

/* Back to top */
.to-top {
  position: fixed; right: 20px; bottom: 20px; z-index: 1020; width: 46px; height: 46px; border-radius: 50%;
  display: grid; place-items: center; border: 0; background: var(--gold); color: #1c1700; font-size: 1.2rem;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.3); opacity: 0; visibility: hidden; transform: translateY(12px);
  transition: var(--transition); cursor: pointer;
}
.to-top.show { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { transform: translateY(-3px); }

/* ---------- Small screens ---------- */
@media (max-width: 575.98px) {
  .section { padding-bottom: 80px; }
  .hero { padding-top: calc(var(--header-h) + 48px); }
  .hero-actions .btn-brand, .hero-actions .btn-ghost { width: 100%; }
  .brand-link { width: 128px; }
}