/* ============================================================
   Trezz — design tokens
   ============================================================ */
:root {
  --paper: #FAF8F4;
  --paper-raised: #FFFFFF;
  --ink: #14171A;
  --ink-soft: #4A5056;
  --ink-faint: #8B9197;
  --green: #0E5E47;
  --green-deep: #0A4534;
  --green-tint: #E7F0EC;
  --amber: #C98A2D;
  --line: rgba(20, 23, 26, 0.10);
  --line-soft: rgba(20, 23, 26, 0.06);

  --font-display: "Fraunces", Georgia, serif;
  --font-body: "Instrument Sans", -apple-system, "Helvetica Neue", sans-serif;

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in: cubic-bezier(0.4, 0, 1, 1);
  --ease-micro: cubic-bezier(0.2, 0, 0, 1);

  --container: 1120px;
  --radius: 14px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--paper);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 28px;
}

/* ============================================================
   Typography
   ============================================================ */
h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 500;
  line-height: 1.08;
  letter-spacing: -0.01em;
}

h1 {
  font-size: clamp(2.6rem, 5.5vw, 4.1rem);
}

h1 em {
  font-style: italic;
  color: var(--green);
}

h2 {
  font-size: clamp(1.9rem, 3.6vw, 2.7rem);
}

h3 {
  font-size: 1.2rem;
  font-weight: 600;
  letter-spacing: 0;
  font-family: var(--font-body);
}

.eyebrow {
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--green);
  margin-bottom: 16px;
}

.eyebrow-light { color: #8FCBB7; }

.lede {
  font-size: 1.13rem;
  color: var(--ink-soft);
  max-width: 32em;
  margin-top: 22px;
}

/* ============================================================
   Reveal-on-scroll
   ============================================================ */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
}
.reveal[data-delay="1"] { transition-delay: 0.08s; }
.reveal[data-delay="2"] { transition-delay: 0.16s; }
.reveal[data-delay="3"] { transition-delay: 0.24s; }
.reveal[data-delay="4"] { transition-delay: 0.32s; }

.reveal.in {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
  * { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; }
}

/* ============================================================
   Buttons & links
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 13px 24px;
  border-radius: 99px;
  text-decoration: none;
  transition: background 0.15s var(--ease-micro), transform 0.15s var(--ease-micro), box-shadow 0.15s var(--ease-micro);
}

.btn-primary {
  background: var(--green);
  color: #FAF8F4;
  box-shadow: 0 1px 2px rgba(14, 94, 71, 0.25);
}

.btn-primary:hover {
  background: var(--green-deep);
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(14, 94, 71, 0.28);
}

.btn-primary:active {
  transform: translateY(0);
  box-shadow: 0 1px 2px rgba(14, 94, 71, 0.25);
}

.btn-sm { padding: 9px 18px; font-size: 0.88rem; }
.btn-lg { padding: 16px 30px; font-size: 1.02rem; }

.btn-arrow {
  display: inline-block;
  transition: transform 0.15s var(--ease-micro);
}
.btn:hover .btn-arrow { transform: translateX(3px); }

.link-quiet {
  color: var(--ink-soft);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  transition: color 0.15s var(--ease-micro);
}
.link-quiet:hover { color: var(--ink); }

.link-underline {
  position: relative;
}
.link-underline::after {
  content: "";
  position: absolute;
  left: 0; bottom: -3px;
  width: 100%; height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.3s var(--ease-out);
}
.link-underline:hover::after {
  transform: scaleX(1);
  transform-origin: left;
}

/* ============================================================
   Nav
   ============================================================ */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(250, 248, 244, 0.85);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s var(--ease-out);
}

.nav.scrolled { border-bottom-color: var(--line-soft); }

.nav-inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 16px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.25rem;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: -0.01em;
}

.logo svg { transition: transform 0.4s var(--ease-out); }
.logo:hover svg { transform: rotate(-8deg); }

.nav-links {
  display: flex;
  gap: 28px;
}

.nav-links a {
  color: var(--ink-soft);
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 500;
  transition: color 0.15s var(--ease-micro);
}
.nav-links a:hover { color: var(--ink); }

.nav-actions {
  display: flex;
  align-items: center;
  gap: 20px;
}

/* ============================================================
   Hero
   ============================================================ */
.hero {
  padding: 88px 0 64px;
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 56px;
  align-items: center;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 26px;
  margin-top: 34px;
}

/* --- hero visual: layered cards --- */
.hero-visual { position: relative; }

.card-stack {
  position: relative;
  max-width: 420px;
  margin-left: auto;
}

.dash-card {
  position: relative;
  z-index: 2;
  background: var(--paper-raised);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 26px 26px 20px;
  box-shadow:
    0 1px 2px rgba(20, 23, 26, 0.04),
    0 12px 40px rgba(20, 23, 26, 0.08);
}

.dash-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.dash-title {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--ink-faint);
}

.dash-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--green);
  background: var(--green-tint);
  padding: 4px 10px;
  border-radius: 99px;
}

.pulse-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--green);
  animation: pulse 2s var(--ease-out) infinite;
}

@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 rgba(14, 94, 71, 0.35); }
  70%  { box-shadow: 0 0 0 6px rgba(14, 94, 71, 0); }
  100% { box-shadow: 0 0 0 0 rgba(14, 94, 71, 0); }
}

.dash-amount {
  margin-top: 12px;
  font-family: var(--font-display);
  font-size: 2.3rem;
  font-weight: 500;
  letter-spacing: -0.01em;
  font-variant-numeric: tabular-nums;
}

.currency { color: var(--ink-faint); margin-right: 2px; }

.dash-delta {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--green);
  margin-top: 2px;
}

.dash-chart {
  width: 100%;
  height: 72px;
  margin-top: 16px;
}

.chart-line {
  stroke-dasharray: 600;
  stroke-dashoffset: 600;
}
.in .chart-line, .hero-visual.in .chart-line {
  animation: drawline 1.6s var(--ease-out) 0.5s forwards;
}
@keyframes drawline {
  to { stroke-dashoffset: 0; }
}

.chart-area {
  opacity: 0;
  transition: opacity 0.8s var(--ease-out) 1.2s;
}
.in .chart-area { opacity: 1; }

.dash-transactions {
  margin-top: 16px;
  border-top: 1px solid var(--line-soft);
  padding-top: 6px;
}

.txn {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  font-size: 0.88rem;
  border-bottom: 1px solid var(--line-soft);
}
.txn:last-child { border-bottom: none; }

.txn-icon {
  width: 26px; height: 26px;
  border-radius: 50%;
  background: var(--green-tint);
  color: var(--green);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  flex-shrink: 0;
}

.txn-icon-out {
  background: rgba(20, 23, 26, 0.05);
  color: var(--ink-soft);
}

.txn-name { flex: 1; color: var(--ink-soft); }

.txn-amt {
  font-weight: 600;
  color: var(--green);
  font-variant-numeric: tabular-nums;
}
.txn-amt-out { color: var(--ink-soft); }

/* floating mini cards */
.mini-card {
  position: absolute;
  background: var(--paper-raised);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px 18px;
  box-shadow: 0 8px 28px rgba(20, 23, 26, 0.10);
  display: flex;
  align-items: center;
  gap: 12px;
}

.mini-card-back {
  z-index: 1;
  top: -34px;
  right: -20px;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  animation: floaty 6s ease-in-out infinite;
}

.mini-card-front {
  z-index: 3;
  bottom: -24px;
  left: -36px;
  animation: floaty 6s ease-in-out 1.2s infinite;
}

@keyframes floaty {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-7px); }
}

.mini-card-row { display: flex; align-items: center; gap: 8px; }

.mini-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--ink);
}

.mini-sub {
  display: block;
  font-size: 0.72rem;
  color: var(--ink-faint);
}

.mini-amount {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}

.dot { width: 7px; height: 7px; border-radius: 50%; }
.dot-amber { background: var(--amber); }

.check-circle {
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--green);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* ============================================================
   Features
   ============================================================ */
.features {
  padding: 110px 0;
  border-top: 1px solid var(--line-soft);
}

.section-head {
  max-width: 560px;
  margin-bottom: 56px;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 22px;
}

.feature {
  background: var(--paper-raised);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  padding: 30px 28px;
  transition: transform 0.3s var(--ease-out), box-shadow 0.3s var(--ease-out), border-color 0.3s var(--ease-out);
}

.feature:hover {
  transform: translateY(-3px);
  border-color: var(--line);
  box-shadow: 0 14px 36px rgba(20, 23, 26, 0.07);
}

.feature-icon {
  width: 44px; height: 44px;
  border-radius: 12px;
  background: var(--green-tint);
  color: var(--green);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  transition: transform 0.3s var(--ease-out);
}

.feature:hover .feature-icon { transform: scale(1.07) rotate(-3deg); }

.feature h3 { margin-bottom: 8px; }

.feature p {
  color: var(--ink-soft);
  font-size: 0.95rem;
}

/* ============================================================
   Card issuing
   ============================================================ */
.issuing {
  padding: 110px 0;
  border-top: 1px solid var(--line-soft);
  overflow: hidden;
}

.issuing-grid {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 72px;
  align-items: center;
}

.issuing-list {
  list-style: none;
  margin-top: 26px;
  display: grid;
  gap: 12px;
}

.issuing-list li {
  position: relative;
  padding-left: 28px;
  font-size: 0.95rem;
  color: var(--ink-soft);
}

.issuing-list li::before {
  content: "";
  position: absolute;
  left: 0; top: 4px;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: var(--green-tint);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none'%3E%3Cpath d='M4.5 8.5l2.5 2.4 4.5-5.4' stroke='%230E5E47' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-size: 11px;
  background-position: center;
  background-repeat: no-repeat;
}

.issuing-actions { margin-top: 32px; }

/* --- the card itself --- */
.issuing-visual { display: flex; justify-content: center; }

.issued-card-wrap {
  position: relative;
  padding: 40px 30px;
}

.issued-card {
  position: relative;
  z-index: 2;
  width: 330px;
  height: 204px;
  border-radius: 18px;
  background:
    radial-gradient(120% 160% at 10% 0%, rgba(250, 248, 244, 0.10) 0%, rgba(250, 248, 244, 0) 55%),
    linear-gradient(135deg, var(--green) 0%, var(--green-deep) 100%);
  color: #FAF8F4;
  padding: 22px 24px;
  display: flex;
  flex-direction: column;
  box-shadow:
    0 2px 4px rgba(10, 69, 52, 0.2),
    0 24px 48px rgba(10, 69, 52, 0.28);
  transform: rotate(-5deg);
  transition: transform 0.5s var(--ease-out), box-shadow 0.5s var(--ease-out);
}

.issued-card:hover {
  transform: rotate(0deg) translateY(-4px);
  box-shadow:
    0 2px 4px rgba(10, 69, 52, 0.2),
    0 32px 64px rgba(10, 69, 52, 0.34);
}

.issued-card-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.issued-card-logo {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.05rem;
  letter-spacing: -0.01em;
}

.issued-card-tag {
  font-size: 0.62rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  padding: 4px 10px;
  border: 1px solid rgba(250, 248, 244, 0.35);
  border-radius: 99px;
  color: rgba(250, 248, 244, 0.85);
}

.issued-card-chip {
  width: 38px;
  height: 28px;
  margin-top: 22px;
  border-radius: 6px;
  background: linear-gradient(135deg, #E6D8B8 0%, #C9B488 100%);
  position: relative;
}

.issued-card-chip::after {
  content: "";
  position: absolute;
  inset: 5px 7px;
  border: 1px solid rgba(10, 69, 52, 0.3);
  border-radius: 3px;
}

.issued-card-number {
  margin-top: 14px;
  font-size: 1.05rem;
  letter-spacing: 0.14em;
  font-variant-numeric: tabular-nums;
  color: rgba(250, 248, 244, 0.92);
}

.issued-card-bottom {
  margin-top: auto;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
}

.issued-card-holder {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: rgba(250, 248, 244, 0.7);
}

.issued-card-network { display: inline-flex; }

.network-circle {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: inline-block;
}

.network-circle-a { background: rgba(250, 248, 244, 0.85); }
.network-circle-b { background: rgba(250, 248, 244, 0.35); margin-left: -10px; }

/* floating chips around the card */
.issuing-chip-a {
  z-index: 3;
  top: 8px;
  right: -16px;
  animation: floaty 6s ease-in-out infinite;
}

.issuing-chip-b {
  z-index: 3;
  bottom: 4px;
  left: -20px;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  animation: floaty 6s ease-in-out 1.4s infinite;
}

.dot-green { background: var(--green); }

/* ============================================================
   How it works
   ============================================================ */
.how { padding: 110px 0; }

.steps {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
}

.step {
  position: relative;
  padding-top: 22px;
  border-top: 2px solid var(--line);
}

.step::before {
  content: "";
  position: absolute;
  top: -2px; left: 0;
  width: 0; height: 2px;
  background: var(--green);
  transition: width 0.9s var(--ease-out) 0.3s;
}
.step.in::before { width: 48px; }

.step-num {
  font-family: var(--font-display);
  font-size: 0.95rem;
  color: var(--green);
  font-weight: 600;
}

.step h3 { margin: 12px 0 8px; }

.step p {
  color: var(--ink-soft);
  font-size: 0.95rem;
}

/* ============================================================
   Security (dark section)
   ============================================================ */
.security {
  background: var(--ink);
  color: var(--paper);
  padding: 110px 0;
}

.security-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 64px;
  align-items: center;
}

.security h2 { color: var(--paper); }

.lede-light {
  font-size: 1.08rem;
  color: rgba(250, 248, 244, 0.65);
  margin-top: 20px;
  max-width: 30em;
}

.security-list {
  list-style: none;
  margin-top: 30px;
  display: grid;
  gap: 13px;
}

.security-list li {
  position: relative;
  padding-left: 30px;
  font-size: 0.95rem;
  color: rgba(250, 248, 244, 0.85);
}

.security-list li::before {
  content: "";
  position: absolute;
  left: 0; top: 4px;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: rgba(143, 203, 183, 0.15);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none'%3E%3Cpath d='M4.5 8.5l2.5 2.4 4.5-5.4' stroke='%238FCBB7' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-size: 12px;
  background-position: center;
  background-repeat: no-repeat;
}

/* vault visual */
.security-visual { display: flex; justify-content: center; }

.vault-card {
  position: relative;
  width: 260px;
  height: 260px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.vault-ring {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(250, 248, 244, 0.14);
}

.vault-ring-outer {
  inset: 0;
  animation: spin 36s linear infinite;
  border-style: dashed;
}

.vault-ring-inner {
  inset: 38px;
  animation: spin 24s linear infinite reverse;
  border-style: dashed;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.vault-core {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  background: var(--green);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow:
    0 0 0 14px rgba(14, 94, 71, 0.18),
    0 0 0 28px rgba(14, 94, 71, 0.07);
}

/* ============================================================
   Pricing
   ============================================================ */
.pricing { padding: 110px 0; }

.pricing .section-head {
  text-align: center;
  margin-left: auto;
  margin-right: auto;
}

.price-card {
  max-width: 720px;
  margin: 0 auto;
  background: var(--paper-raised);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 44px 48px;
  display: grid;
  grid-template-columns: 1.4fr auto;
  gap: 48px;
  align-items: center;
  box-shadow: 0 14px 44px rgba(20, 23, 26, 0.06);
}

.price-copy {
  font-size: 1.08rem;
  color: var(--ink-soft);
  max-width: 26em;
}

.price-side {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  border-left: 1px solid var(--line-soft);
  padding-left: 40px;
}

.price-caption {
  font-size: 0.85rem;
  color: var(--ink-faint);
}

/* ============================================================
   CTA
   ============================================================ */
.cta { padding: 40px 0 130px; }

.cta-inner {
  text-align: center;
  background: var(--green-tint);
  border-radius: 24px;
  padding: 80px 40px;
}

.cta p {
  color: var(--ink-soft);
  margin-top: 14px;
}

.cta-actions {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 28px;
  margin-top: 32px;
}

/* ============================================================
   Footer
   ============================================================ */
.footer {
  border-top: 1px solid var(--line-soft);
  padding: 36px 0;
}

.footer-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.footer-links {
  display: flex;
  gap: 28px;
}

.footer-links a {
  color: var(--ink-soft);
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.15s var(--ease-micro);
}

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

.footer-copy {
  font-size: 0.83rem;
  color: var(--ink-faint);
}

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 920px) {
  .hero-grid { grid-template-columns: 1fr; gap: 72px; }
  .card-stack { margin: 0 auto; }
  .mini-card-back { right: 0; }
  .mini-card-front { left: -8px; }
  .feature-grid { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .issuing-grid { grid-template-columns: 1fr; gap: 56px; }
  .issuing-visual { order: -1; }
  .issuing-chip-a { right: 0; }
  .issuing-chip-b { left: 0; }
  .security-grid { grid-template-columns: 1fr; }
  .security-visual { order: -1; }
  .price-card { grid-template-columns: 1fr; gap: 32px; text-align: center; }
  .price-side { border-left: none; padding-left: 0; align-items: center; }
}

@media (max-width: 640px) {
  .nav-links { display: none; }
  .hero { padding-top: 56px; }
  .hero-actions { flex-direction: column; align-items: flex-start; gap: 18px; }
  .cta-actions { flex-direction: column; gap: 18px; }
  .footer-row { flex-direction: column; gap: 18px; }
}
