/* ==========================================================================
   Natolead — Hero section (modern redesign)
   Load AFTER styles.css and homepage.css. Uses the brand tokens defined in
   homepage.css (--brand-*, --text, --muted, --line). All selectors are
   prefixed .hx so nothing else on the site is affected.

   If your site header is position:fixed (not in normal flow), raise --hx-top.
   ========================================================================== */

.hx {
  --hx-top: clamp(36px, 5vw, 72px);
  --hx-bottom: clamp(56px, 8vw, 112px);
  --hx-gutter: clamp(18px, 4vw, 40px);
  position: relative;
  isolation: isolate;
  overflow: clip;
  padding: var(--hx-top) 0 var(--hx-bottom);
}

/* ---------- Background layers ---------- */
.hx-bg { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.hx-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(#8bc63f14 1px, transparent 1px),
    linear-gradient(90deg, #8bc63f14 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(ellipse 70% 65% at 68% 38%, #000 15%, transparent 75%);
  mask-image: radial-gradient(ellipse 70% 65% at 68% 38%, #000 15%, transparent 75%);
}
.hx-glow { position: absolute; border-radius: 50%; filter: blur(90px); }
.hx-glow-a { width: min(600px, 75vw); aspect-ratio: 1; right: -10%; top: -10%; background: #32833f55; }
.hx-glow-b { width: min(420px, 60vw); aspect-ratio: 1; left: -12%; bottom: -8%; background: #8bc63f22; }

/* ---------- Layout ---------- */
.hx-inner {
  width: min(1240px, 100% - 2 * var(--hx-gutter));
  margin-inline: auto;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
  align-items: center;
  gap: clamp(32px, 5vw, 72px);
}
.hx-copy { min-width: 0; }

/* ---------- Copy ---------- */
.hx-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 clamp(18px, 2.4vw, 28px);
  padding: 8px 14px;
  border: 1px solid #a7cf4135;
  border-radius: 999px;
  background: #8bc63f10;
  color: #c3de9a;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .14em;
  line-height: 1.35;
  text-transform: uppercase;
}
.hx-dot {
  flex: none;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--brand-lime);
  box-shadow: 0 0 0 4px #8bc63f26;
}

.hx h1 {
  margin: 0;
  color: var(--text);
  font-size: clamp(2.45rem, 1.4rem + 4.6vw, 5rem);
  font-weight: 600;
  line-height: 1.03;
  letter-spacing: -.035em;
  text-wrap: balance;
}
.hx-line { display: block; }
.hx-accent {
  background: linear-gradient(100deg, #d6f0a0, var(--brand-lime) 55%, var(--brand-green));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}
.hx-arrow {
  display: inline-grid;
  place-items: center;
  width: .6em;
  height: .6em;
  margin-left: .2em;
  vertical-align: .08em;
  border-radius: 50%;
  background: var(--brand-gradient);
  color: var(--brand-ink);
  box-shadow: 0 6px 24px #8bc63f40;
}
.hx-arrow svg { width: 55%; height: 55%; }

.hx-lede {
  max-width: 52ch;
  margin: clamp(18px, 2.4vw, 28px) 0 0;
  color: var(--muted);
  font-size: clamp(1rem, .94rem + .3vw, 1.175rem);
  line-height: 1.7;
}

/* ---------- Actions ---------- */
.hx-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 22px;
  margin-top: clamp(24px, 3vw, 36px);
}
.hx-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  min-height: 54px;
  padding: 0 9px 0 24px;
  border: 1px solid #a7cf4166;
  border-radius: 14px;
  background: var(--brand-gradient);
  color: var(--brand-ink);
  font: inherit;
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;
  box-shadow: 0 10px 30px #8bc63f26, inset 0 1px 0 #ffffff55;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}
.hx-btn:hover {
  background: linear-gradient(115deg, #bedf73, var(--brand-lime));
  box-shadow: 0 14px 38px #8bc63f3d, inset 0 1px 0 #ffffff66;
  transform: translateY(-2px);
}
.hx-btn-icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: #1020101f;
}
.hx-link {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-height: 54px;
  color: var(--text);
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  transition: color .2s ease;
}
.hx-link:hover { color: var(--brand-light); }
.hx-play {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid #718766;
  border-radius: 50%;
  background: #ffffff08;
  transition: border-color .2s ease, background .2s ease;
}
.hx-play svg { width: 12px; height: 12px; margin-left: 2px; fill: currentColor; }
.hx-link:hover .hx-play { border-color: var(--brand-lime); background: #8bc63f1a; }
.hx-btn:focus-visible, .hx-link:focus-visible {
  outline: 3px solid var(--brand-light);
  outline-offset: 3px;
}

/* ---------- Trust row ---------- */
.hx-trust {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 26px;
  margin: clamp(28px, 4vw, 44px) 0 0;
  padding: 22px 0 0;
  border-top: 1px solid var(--line);
  list-style: none;
  color: #c9d6c4;
  font-size: 14px;
  font-weight: 500;
}
.hx-trust li { display: inline-flex; align-items: center; gap: 8px; }
.hx-trust svg { flex: none; width: 18px; height: 18px; color: var(--brand-lime); }

/* ---------- Visual ---------- */
.hx-visual {
  position: relative;
  display: grid;
  place-items: center;
  min-width: 0;
  padding: clamp(40px, 5vw, 56px) 0 clamp(72px, 7vw, 88px);
}
.hx-ring {
  position: absolute;
  inset: 2% -4%;
  border: 1px solid #8bc63f26;
  border-radius: 50%;
  pointer-events: none;
}
.hx-ring::after {
  content: '';
  position: absolute;
  inset: 9%;
  border: 1px dashed #a7cf4122;
  border-radius: 50%;
}

.hx-card {
  position: relative;
  width: min(100%, 460px);
  padding: clamp(18px, 2.4vw, 28px);
  border: 1px solid #7ca45b55;
  border-radius: 28px;
  background: linear-gradient(150deg, #263d2af2, #101c14f5 70%);
  box-shadow: 0 40px 90px #00000066, 0 0 70px #8bc63f14, inset 0 1px 0 #ffffff14;
  transform: rotate(2deg);
}
.hx-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
}
.hx-brand { display: inline-flex; align-items: center; gap: 10px; min-width: 0; }
.hx-brand img {
  flex: none;
  width: 38px;
  height: 28px;
  padding: 2px 4px;
  border-radius: 8px;
  background: var(--brand-paper);
  object-fit: contain;
}
.hx-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  flex: none;
  padding: 5px 11px;
  border: 1px solid #8bc63f40;
  border-radius: 999px;
  background: #8bc63f12;
  color: #bbcbb1;
  font-size: 11px;
  font-weight: 600;
}
.hx-badge i { width: 6px; height: 6px; border-radius: 50%; background: var(--brand-lime); }

.hx-card-title {
  margin: clamp(18px, 2.4vw, 28px) 0 0;
  color: var(--text);
  font-size: clamp(1.4rem, 1.1rem + 1vw, 1.9rem);
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: -.02em;
}
.hx-card-title strong { display: block; color: var(--brand-light); font-weight: 600; }

.hx-chart-wrap { position: relative; margin-top: clamp(18px, 2.4vw, 26px); }
.hx-chart {
  display: flex;
  align-items: flex-end;
  gap: clamp(6px, 1vw, 10px);
  height: clamp(150px, 19vw, 220px);
  border-bottom: 1px solid var(--line);
  background: repeating-linear-gradient(
    to top, transparent 0 calc(25% - 1px), #ffffff0f calc(25% - 1px) 25%);
}
.hx-chart i {
  flex: 1;
  height: var(--h);
  border-radius: 8px 8px 3px 3px;
  background: linear-gradient(to top, var(--brand-deep), var(--brand-light));
  transform-origin: bottom;
}
.hx-chart i:nth-child(even) { background: linear-gradient(to top, #245b2d, var(--brand-green)); }
.hx-chart i:last-child { box-shadow: 0 0 26px #8bc63f55; }
.hx-trend {
  position: absolute;
  top: -6px;
  right: 2px;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: #8bc63f1c;
  border: 1px solid #8bc63f4d;
  color: var(--brand-light);
}
.hx-trend svg { width: 18px; height: 18px; }
.hx-axis {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 10px;
  color: #bbcbb1;
  font-size: 11px;
  font-weight: 500;
}

.hx-card-foot {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: clamp(16px, 2vw, 22px);
  padding-top: clamp(14px, 2vw, 20px);
  border-top: 1px solid var(--line);
  color: #bbcbb1;
  font-size: 12px;
  line-height: 1.4;
}
.hx-card-foot strong { display: block; color: var(--text); font-weight: 600; }
.hx-stack { display: flex; flex: none; }
.hx-stack b {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  margin-left: -8px;
  border: 2px solid #142218;
  border-radius: 50%;
  background: #344e2b;
  color: var(--brand-paper);
  font-size: 10px;
}
.hx-stack b:first-child { margin-left: 0; }
.hx-stack b:nth-child(2) { background: #42663b; }
.hx-stack b:nth-child(3) { background: #58733a; }
.hx-foot-arrow { margin-left: auto; color: var(--brand-light); }

/* ---------- Floating cards ---------- */
.hx-float {
  position: absolute;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 16px;
  border-radius: 16px;
  box-shadow: 0 22px 50px #00000055;
  color: var(--brand-ink);
}
.hx-float small {
  display: block;
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  line-height: 1.4;
}
.hx-float strong { display: block; font-size: 14px; font-weight: 700; line-height: 1.3; }
.hx-float span.hx-sub { display: block; font-size: 11.5px; line-height: 1.4; }
.hx-float svg { width: 18px; height: 18px; }

.hx-notice {
  top: 21%;
  right: -5%;
  background: var(--brand-paper);
  border: 1px solid #e1ecd4;
}
.hx-notice small, .hx-notice .hx-sub { color: var(--brand-muted-ink); }
.hx-ico {
  display: grid;
  place-items: center;
  flex: none;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: var(--brand-pale);
  color: #245b2d;
}
.hx-appt {
  bottom: 6px;
  left: -4%;
  background: var(--brand-gradient);
  border: 1px solid #ffffff33;
}
.hx-appt small { color: #314823; }
.hx-appt .hx-ico { background: #1020101a; color: var(--brand-ink); }

.hx-note {
  position: absolute;
  bottom: 10px;
  right: 4px;
  color: var(--muted);
  font-size: 11px;
  letter-spacing: .06em;
  white-space: nowrap;
}

/* ---------- Motion (only when the visitor allows it) ---------- */
@media (prefers-reduced-motion: no-preference) {
  .hx-dot { animation: hx-pulse 2.4s ease-in-out infinite; }
  .hx-copy > * { animation: hx-rise .7s cubic-bezier(.2, .7, .2, 1) both; }
  .hx-copy > :nth-child(2) { animation-delay: .08s; }
  .hx-copy > :nth-child(3) { animation-delay: .16s; }
  .hx-copy > :nth-child(4) { animation-delay: .24s; }
  .hx-copy > :nth-child(5) { animation-delay: .32s; }
  .hx-card { animation: hx-card-in .9s cubic-bezier(.2, .7, .2, 1) .15s both; }
  .hx-chart i { animation: hx-grow .9s cubic-bezier(.2, .8, .2, 1) both; animation-delay: calc(var(--i) * 70ms + 450ms); }
  .hx-notice { animation: hx-float 6s ease-in-out infinite alternate; }
  .hx-appt { animation: hx-float 7s ease-in-out -2s infinite alternate; }
  .hx-ring { animation: hx-spin 80s linear infinite; }
}
@keyframes hx-pulse { 50% { box-shadow: 0 0 0 8px #8bc63f08; } }
@keyframes hx-rise { from { opacity: 0; transform: translateY(18px); } }
@keyframes hx-card-in { from { opacity: 0; transform: translateY(26px) rotate(4deg); } }
@keyframes hx-grow { from { transform: scaleY(.04); opacity: .4; } }
@keyframes hx-float { to { transform: translateY(-9px); } }
@keyframes hx-spin { to { transform: rotate(360deg); } }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .hx-inner { gap: 28px; }
  .hx-notice { right: -1%; }
  .hx-appt { left: -2%; }
}

@media (max-width: 900px) {
  .hx-inner { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .hx-visual { max-width: 540px; width: 100%; margin-inline: auto; }
  .hx-lede { max-width: 60ch; }
}

@media (max-width: 560px) {
  .hx-eyebrow { font-size: 10px; letter-spacing: .1em; }
  .hx-actions { flex-direction: column; align-items: stretch; gap: 6px; }
  .hx-btn { justify-content: space-between; }
  .hx-link { justify-content: center; }
  .hx-trust { flex-direction: column; gap: 10px; }
  .hx-visual { padding: 78px 0 82px; }
  .hx-card { width: calc(100% - 8px); transform: rotate(1deg); border-radius: 22px; }
  .hx-notice { top: 0; right: 0; padding: 10px 12px; }
  .hx-appt { bottom: 4px; left: 0; padding: 10px 12px; }
  .hx-float strong { font-size: 13px; }
  .hx-ico { width: 32px; height: 32px; }
  .hx-note { display: none; }
}

@media (max-width: 380px) {
  .hx-badge { display: none; }
  .hx-float .hx-sub { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .hx-btn, .hx-link, .hx-play { transition: none; }
  .hx-btn:hover { transform: none; }
}

.hx-cta-note {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: .875rem;
}

.hx-team-note {
  max-width: 52ch;
  margin-top: 22px;
  padding-left: 14px;
  border-left: 2px solid var(--lime);
  font-size: .875rem;
  line-height: 1.55;
}

.hx-team-note p {
  margin: 4px 0 0;
  color: var(--muted);
}
