/* ════════════════════════════════════════════════════════
   iCheck Ecosystem Plugin — ecosystem.css
   ════════════════════════════════════════════════════════ */

/* — Tokens — */
:root {
  --eco-green:        #16a34a;
  --eco-green-mid:    #22c55e;
  --eco-green-light:  #4ade80;
  --eco-green-pale:   #dcfce7;
  --eco-green-bg:     #f0fdf4;
  --eco-white:        #ffffff;
  --eco-text:         #1a2e1a;
  --eco-text-muted:   #4b7a4b;
  --eco-border:       #d1fae5;
  --eco-shadow:       0 8px 40px rgba(22,163,74,.12);
  --eco-radius:       20px;
  --eco-panel-radius: 24px;
  --eco-transition:   cubic-bezier(.4,0,.2,1);
}

/* — Wrapper — */
.icheck-eco {
  padding: 72px 24px 80px;
  background: radial-gradient(ellipse 80% 60% at 50% 0%, #d1fae5 0%, #f0fdf4 55%, #ffffff 100%);
  font-family: 'Be Vietnam Pro', 'SVN-Gilroy', 'Segoe UI', sans-serif;
  -webkit-font-smoothing: antialiased;
}

/* — Heading — */
.icheck-eco__heading {
  text-align: center;
  margin-bottom: 52px;
}
.icheck-eco__heading h2 {
  font-size: clamp(1.6rem, 3.5vw, 2.4rem);
  font-weight: 700;
  color: var(--eco-text);
  line-height: 1.25;
  margin: 0 0 10px;
}
.icheck-eco__heading h2 span {
  color: var(--eco-green);
}
.icheck-eco__heading p {
  font-size: 1rem;
  color: var(--eco-text-muted);
  margin: 0;
}

/* — Layout — */
.icheck-eco__layout {
  display: flex;
  align-items: stretch;
  gap: 32px;
  max-width: 1100px;
  margin: 0 auto;
}

/* ── LEFT STAGES ─────────────────────────────────────────── */
.icheck-eco__stages {
  display: flex;
  flex-direction: column;
  min-width: 180px;
  flex-shrink: 0;
}

.icheck-eco__stage {
  display: flex;
  flex-direction: column;
  align-items: center;
  cursor: pointer;
  outline: none;
}
.icheck-eco__stage:focus-visible .icheck-eco__stage-card {
  box-shadow: 0 0 0 3px var(--eco-green-light);
}

.icheck-eco__stage-card {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 14px 18px;
  border-radius: 16px;
  border: 2px solid var(--eco-border);
  background: var(--eco-white);
  transition: background 0.3s var(--eco-transition),
              border-color 0.3s var(--eco-transition),
              box-shadow 0.3s var(--eco-transition),
              transform 0.3s var(--eco-transition);
  box-shadow: 0 2px 12px rgba(22,163,74,.06);
}
.icheck-eco__stage:hover .icheck-eco__stage-card {
  border-color: var(--eco-green-light);
  box-shadow: 0 4px 20px rgba(22,163,74,.15);
  transform: translateX(4px);
}
.icheck-eco__stage.is-active .icheck-eco__stage-card {
  background: var(--eco-green);
  border-color: var(--eco-green);
  color: var(--eco-white);
  box-shadow: 0 8px 28px rgba(22,163,74,.35);
  transform: translateX(6px);
}

.icheck-eco__stage-icon {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--eco-green);
  transition: color 0.3s var(--eco-transition);
}
.icheck-eco__stage-icon svg {
  width: 100%;
  height: 100%;
}
.icheck-eco__stage.is-active .icheck-eco__stage-icon {
  color: var(--eco-white);
}

.icheck-eco__stage-label {
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  line-height: 1.4;
  color: var(--eco-text-muted);
  transition: color 0.3s var(--eco-transition);
}
.icheck-eco__stage.is-active .icheck-eco__stage-label {
  color: var(--eco-white);
}

/* Connector */
.icheck-eco__stage-connector {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 4px 0;
  flex-shrink: 0;
}
.icheck-eco__stage-line {
  width: 2px;
  height: 22px;
  background: var(--eco-border);
  transition: background 0.4s var(--eco-transition);
}
.icheck-eco__stage-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--eco-border);
  transition: background 0.4s var(--eco-transition), transform 0.4s var(--eco-transition);
}
.icheck-eco__stage.is-active ~ .icheck-eco__stage .icheck-eco__stage-line,
.icheck-eco__stage.is-active .icheck-eco__stage-connector .icheck-eco__stage-line {
  background: var(--eco-green-light);
}
.icheck-eco__stage.is-active .icheck-eco__stage-connector .icheck-eco__stage-dot {
  background: var(--eco-green);
  transform: scale(1.4);
}

/* ── RIGHT PANEL ─────────────────────────────────────────── */
.icheck-eco__panel {
  flex: 1;
  min-width: 0;
  background: var(--eco-white);
  border-radius: var(--eco-panel-radius);
  border: 1.5px solid var(--eco-border);
  box-shadow: var(--eco-shadow);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* Tab list */
.icheck-eco__tabs {
  display: flex;
  align-items: stretch;
  padding: 0 4px;
  border-bottom: 1.5px solid var(--eco-border);
  position: relative;
  gap: 2px;
  background: #fafffe;
}

.icheck-eco__tab {
  flex: 1;
  padding: 14px 10px;
  background: none;
  border: none;
  font-size: .78rem;
  font-weight: 600;
  font-family: inherit;
  color: var(--eco-text-muted);
  cursor: pointer;
  text-align: center;
  line-height: 1.4;
  transition: color 0.25s var(--eco-transition);
  position: relative;
  z-index: 1;
  outline: none;
}
.icheck-eco__tab:focus-visible {
  box-shadow: inset 0 0 0 2px var(--eco-green-light);
}
.icheck-eco__tab:hover {
  color: var(--eco-green);
}
.icheck-eco__tab.is-active {
  color: var(--eco-green);
}

/* Sliding indicator */
.icheck-eco__tab-indicator {
  position: absolute;
  bottom: -1.5px;
  height: 3px;
  border-radius: 2px 2px 0 0;
  background: var(--eco-green);
  transition: left 0.35s var(--eco-transition), width 0.35s var(--eco-transition);
  pointer-events: none;
  z-index: 2;
}

/* Content wrap */
.icheck-eco__content-wrap {
  position: relative;
  flex: 1;
  overflow: hidden;
  min-height: 320px;
}

.icheck-eco__content {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 36px 40px;
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.4s var(--eco-transition), transform 0.4s var(--eco-transition);
  pointer-events: none;
}
.icheck-eco__content.is-active {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
  position: relative;
}

/* Content text */
.icheck-eco__content-text {
  flex: 1;
  min-width: 0;
}
.icheck-eco__content-text h3 {
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--eco-text);
  line-height: 1.3;
  margin: 0 0 16px;
}
.icheck-eco__content-text h3 span {
  color: var(--eco-green);
  display: block;
}
.icheck-eco__content-text p {
  font-size: .9rem;
  line-height: 1.7;
  color: var(--eco-text-muted);
  margin: 0 0 28px;
}

/* CTA buttons */
.icheck-eco__cta {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.icheck-eco__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 26px;
  border-radius: 50px;
  font-size: .88rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.2s var(--eco-transition),
              box-shadow 0.2s var(--eco-transition),
              background 0.2s var(--eco-transition);
  letter-spacing: .02em;
}
.icheck-eco__btn--primary {
  background: var(--eco-green);
  color: #fff;
  box-shadow: 0 4px 18px rgba(22,163,74,.3);
}
.icheck-eco__btn--primary:hover {
  background: #15803d;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(22,163,74,.4);
}
.icheck-eco__btn--outline {
  background: var(--eco-white);
  color: var(--eco-text);
  border: 1.5px solid #d4d4d4;
}
.icheck-eco__btn--outline:hover {
  border-color: var(--eco-green);
  color: var(--eco-green);
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(22,163,74,.15);
}

/* Content visual */
.icheck-eco__content-visual {
  flex-shrink: 0;
  width: 260px;
  max-width: 40%;
  display: flex;
  align-items: center;
  justify-content: center;
}
.icheck-eco-visual {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 12px 32px rgba(22,163,74,.2));
  animation: eco-float 4s ease-in-out infinite;
}
@keyframes eco-float {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(-8px); }
}

/* ── Responsive ──────────────────────────────────────────── */
@media (max-width: 860px) {
  .icheck-eco__layout {
    flex-direction: column;
    gap: 20px;
  }
  .icheck-eco__stages {
    flex-direction: row;
    min-width: unset;
    gap: 0;
    overflow-x: auto;
    padding-bottom: 4px;
  }
  .icheck-eco__stage {
    flex-direction: row;
    flex: 1;
    min-width: 100px;
  }
  .icheck-eco__stage-connector {
    flex-direction: column;
    align-items: center;
    padding: 0 4px;
    transform: rotate(0deg);
  }
  .icheck-eco__stage-line {
    width: 22px;
    height: 2px;
  }
  .icheck-eco__stage-dot {
    width: 6px;
    height: 6px;
  }
  .icheck-eco__stage-card {
    flex-direction: column;
    text-align: center;
    gap: 6px;
    padding: 12px 10px;
  }
  .icheck-eco__stage:hover .icheck-eco__stage-card,
  .icheck-eco__stage.is-active .icheck-eco__stage-card {
    transform: translateY(-3px);
  }
  .icheck-eco__content {
    flex-direction: column;
    padding: 28px 24px;
  }
  .icheck-eco__content-visual {
    max-width: 180px;
    width: 180px;
    order: -1;
  }
  .icheck-eco__tabs {
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
  }
  .icheck-eco__tabs::-webkit-scrollbar { display: none; }
  .icheck-eco__tab {
    flex-shrink: 0;
    white-space: nowrap;
    padding: 12px 14px;
  }
}

@media (max-width: 480px) {
  .icheck-eco {
    padding: 48px 16px 56px;
  }
  .icheck-eco__heading h2 {
    font-size: 1.4rem;
  }
  .icheck-eco__content {
    padding: 24px 18px;
  }
  .icheck-eco__content-text h3 {
    font-size: 1.2rem;
  }
}
