/* ============================================================
   EVOLVE DIGITAL CO. — Landing
   Aesthetic: "Scale Engine" — dark techno-editorial, warm energy
   ============================================================ */

:root {
  /* palette (from logo) */
  --ink:        #0A0A0B;
  --ink-1:      #0D0D0F;
  --ink-2:      #131316;
  --ink-3:      #1B1B1F;
  --line:       #26262B;
  --white:      #FFFFFF;
  --gray:       #B4AEA8;
  --gray-dim:   #75706B;

  --amber:      #FBAE17;
  --orange:     #F26A1B;
  --red:        #E23A19;
  --grad:       linear-gradient(100deg, var(--amber) 0%, var(--orange) 52%, var(--red) 100%);
  --grad-soft:  linear-gradient(100deg, #FFC24D 0%, #F5822F 50%, #E8432099 100%);

  --font-display: 'Archivo', system-ui, sans-serif;
  --font-body:    'Hanken Grotesk', system-ui, sans-serif;
  --font-mono:    'JetBrains Mono', ui-monospace, monospace;

  --maxw: 1200px;
  --ease: cubic-bezier(.2, .7, .2, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }   /* beat .lead-form{display:flex} so JS toggle works */

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font-body);
  background: var(--ink);
  color: var(--white);
  line-height: 1.5;
  overflow-x: hidden;
  min-height: 100vh;
  position: relative;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.mono { font-family: var(--font-mono); font-weight: 500; letter-spacing: .04em; }

/* gradient text helper */
.grad {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  background-size: 200% 100%;
  animation: gradShift 6s ease-in-out infinite;
}
@keyframes gradShift {
  0%, 100% { background-position: 0% 50%; }
  50%      { background-position: 100% 50%; }
}

/* ============================================================
   ATMOSPHERE — fixed background layers
   ============================================================ */
.bg-grid, .bg-glow, .bg-particles, .bg-grain, .bg-vignette {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.bg-grid {
  background-image:
    linear-gradient(to right, rgba(255,255,255,.028) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255,255,255,.028) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 90% 70% at 50% 32%, #000 40%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 90% 70% at 50% 32%, #000 40%, transparent 100%);
}

/* warm glow that tracks the pointer (vars set by JS) */
.bg-glow {
  --mx: 50%; --my: 24%;
  background:
    radial-gradient(680px circle at var(--mx) var(--my), rgba(242,106,27,.16), transparent 62%),
    radial-gradient(1100px circle at 50% -8%, rgba(226,58,25,.16), transparent 60%),
    radial-gradient(760px circle at 82% 8%, rgba(251,174,23,.10), transparent 60%);
  transition: background .18s var(--ease);
}

.bg-particles { z-index: 0; opacity: .9; }

.bg-grain {
  z-index: 2;
  opacity: .05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  mix-blend-mode: overlay;
}

.bg-vignette {
  z-index: 1;
  background: radial-gradient(ellipse 120% 90% at 50% 30%, transparent 55%, rgba(0,0,0,.55) 100%);
}

/* ============================================================
   TOP BAR
   ============================================================ */
.topbar {
  position: relative;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px clamp(18px, 4vw, 48px);
  max-width: var(--maxw);
  margin: 0 auto;
}
.brand { display: inline-flex; align-items: center; gap: 11px; text-decoration: none; }
.brand-mark {
  width: 30px; height: 28px;
  flex: none;
  filter: drop-shadow(0 0 14px rgba(242,106,27,.35));
}
.brand-word {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 21px;
  line-height: .82;
  letter-spacing: -.01em;
  color: var(--white);
}
.brand-word small {
  display: block;
  font-family: var(--font-mono);
  font-weight: 500;
  font-size: 7.5px;
  letter-spacing: .34em;
  color: var(--gray-dim);
  margin-top: 3px;
}
.topbar-cta {
  font-size: 13px;
  color: var(--gray);
  text-decoration: none;
  padding: 9px 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  transition: color .25s, border-color .25s, background .25s;
}
.topbar-cta:hover { color: var(--white); border-color: var(--orange); background: rgba(242,106,27,.08); }

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative;
  z-index: 3;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(48px, 9vh, 110px) clamp(18px, 4vw, 48px) clamp(60px, 10vh, 120px);
  min-height: calc(100vh - 78px);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hud {
  position: absolute;
  font-size: 11px;
  letter-spacing: .18em;
  color: var(--gray-dim);
  z-index: 4;
}
.hud-tl { top: 8px;  left: clamp(18px,4vw,48px); }
.hud-tr { top: 8px;  right: clamp(18px,4vw,48px); }
.hud-bl { bottom: 20px; left: clamp(18px,4vw,48px); }
.hud-br { bottom: 20px; right: clamp(18px,4vw,48px); }
.hud::before {
  content: "";
  display: inline-block;
  width: 22px; height: 1px;
  background: var(--grad);
  vertical-align: middle;
  margin-right: 8px;
  opacity: .8;
}

.hero-inner { max-width: 940px; }

.eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 12.5px;
  color: var(--gray);
  text-transform: uppercase;
  letter-spacing: .16em;
  margin-bottom: clamp(22px, 4vh, 34px);
  max-width: 100%;
}
.eyebrow-txt { overflow-wrap: anywhere; }
.eyebrow-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--grad);
  box-shadow: 0 0 10px 1px rgba(242,106,27,.8);
  animation: pulse 2.2s ease-in-out infinite;
}
@keyframes pulse { 0%,100%{ opacity:1; transform:scale(1);} 50%{ opacity:.5; transform:scale(.75);} }

.headline {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(2.5rem, 7.9vw, 6.1rem);
  line-height: .95;
  letter-spacing: -.03em;
  text-transform: none;
}
.headline .line { display: block; }
.headline .grad { padding-right: .06em; }

.sub {
  margin-top: clamp(24px, 4vh, 34px);
  max-width: 620px;
  font-size: clamp(1.02rem, 1.5vw, 1.28rem);
  color: var(--gray);
  line-height: 1.62;
}
.sub strong { color: var(--white); font-weight: 600; }

.pillars {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: clamp(26px, 4vh, 36px);
}
.pillars li {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  font-weight: 600;
  color: #E9E5E1;
  padding: 9px 16px 9px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255,255,255,.02);
  backdrop-filter: blur(4px);
}
.pillar-idx {
  font-size: 11px;
  color: var(--orange);
  border: 1px solid rgba(242,106,27,.35);
  border-radius: 5px;
  padding: 2px 5px;
  background: rgba(242,106,27,.08);
}

.hero-cta {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
  margin-top: clamp(34px, 5vh, 46px);
}
.cta-note { font-size: 12px; color: var(--gray-dim); text-transform: uppercase; letter-spacing: .12em; }

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 16px;
  text-decoration: none;
  color: #1a0d02;
  padding: 16px 26px;
  border: none;
  border-radius: 999px;
  cursor: pointer;
  background: var(--grad);
  background-size: 160% 100%;
  overflow: hidden;
  isolation: isolate;
  box-shadow: 0 8px 30px -8px rgba(242,106,27,.6), inset 0 1px 0 rgba(255,255,255,.35);
  transition: transform .25s var(--ease), box-shadow .25s, background-position .5s var(--ease);
  animation: btnPulse 3.4s ease-in-out infinite;
}
@keyframes btnPulse {
  0%,100% { box-shadow: 0 8px 30px -8px rgba(242,106,27,.5), inset 0 1px 0 rgba(255,255,255,.35); }
  50%     { box-shadow: 0 8px 42px -6px rgba(242,106,27,.85), inset 0 1px 0 rgba(255,255,255,.35); }
}
.btn::after {  /* shine sweep */
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(110deg, transparent 30%, rgba(255,255,255,.55) 50%, transparent 70%);
  transform: translateX(-120%);
  transition: transform .7s var(--ease);
  z-index: -1;
}
.btn:hover { transform: translateY(-2px); background-position: 100% 50%; }
.btn:hover::after { transform: translateX(120%); }
.btn:active { transform: translateY(0); }
.btn-arrow { transition: transform .25s var(--ease); font-weight: 700; }
.btn:hover .btn-arrow { transform: translateX(5px); }
.btn-block { width: 100%; justify-content: center; margin-top: 8px; padding: 18px; font-size: 17px; }
.btn[disabled] { opacity: .7; cursor: wait; animation: none; }

.scroll-cue {
  position: absolute;
  bottom: 26px; left: 50%;
  transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  font-size: 10px; letter-spacing: .3em; color: var(--gray-dim);
  text-decoration: none;
}
.scroll-line { width: 1px; height: 42px; background: linear-gradient(var(--orange), transparent); animation: scrollLine 2s ease-in-out infinite; transform-origin: top; }
@keyframes scrollLine { 0%,100%{ transform: scaleY(.4); opacity:.4;} 50%{ transform: scaleY(1); opacity:1;} }

/* ============================================================
   APPLY (BLOCK 2)
   ============================================================ */
.apply {
  position: relative;
  z-index: 3;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(70px, 12vh, 140px) clamp(18px, 4vw, 48px) clamp(60px, 8vh, 100px);
  border-top: 1px solid var(--line);
}
.apply-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(32px, 5vw, 80px);
  align-items: start;
}

.apply-head { position: sticky; top: 40px; }
.apply-title {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(2.2rem, 5.4vw, 4.2rem);
  line-height: .98;
  letter-spacing: -.03em;
  margin: 18px 0 20px;
}
.apply-sub { color: var(--gray); font-size: 1.05rem; max-width: 420px; line-height: 1.6; }
.apply-points {
  list-style: none;
  margin-top: 28px;
  display: flex; flex-direction: column; gap: 12px;
  font-size: 13px; color: var(--gray-dim);
}
.apply-points li { letter-spacing: .02em; }

/* card */
.apply-card {
  position: relative;
  background: linear-gradient(180deg, var(--ink-2), var(--ink-1));
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: clamp(24px, 3vw, 38px);
  box-shadow: 0 40px 90px -40px rgba(0,0,0,.9);
}
.apply-card::before {  /* gradient hairline top */
  content: "";
  position: absolute; inset: 0;
  border-radius: 20px;
  padding: 1px;
  background: linear-gradient(160deg, rgba(242,106,27,.55), transparent 40%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

/* form */
.lead-form { display: flex; flex-direction: column; gap: 18px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.field { display: flex; flex-direction: column; gap: 8px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field label, .field .label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--gray-dim);
}

input, select, textarea {
  font-family: var(--font-body);
  font-size: 16px;              /* 16px+ prevents iOS auto-zoom on focus */
  color: var(--white);
  background: var(--ink);
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 13px 14px;
  width: 100%;
  transition: border-color .2s, box-shadow .2s, background .2s;
  outline: none;
}
input::placeholder, textarea::placeholder { color: #57534E; }
input:focus, select:focus, textarea:focus {
  border-color: var(--orange);
  box-shadow: 0 0 0 3px rgba(242,106,27,.16);
  background: #0c0c0e;
}
textarea { resize: vertical; min-height: 78px; line-height: 1.5; }

/* segmented control */
.segmented { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.segmented label {
  position: relative;
  display: block;
  text-align: center;
  cursor: pointer;
}
.segmented input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.segmented span {
  display: block;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  color: var(--gray);
  padding: 12px 8px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: var(--ink);
  transition: all .2s var(--ease);
  text-transform: none;
  letter-spacing: 0;
}
.segmented label:hover span { border-color: #3a3a40; color: var(--white); }
.segmented input:checked + span {
  color: #1a0d02;
  background: var(--grad);
  border-color: transparent;
  box-shadow: 0 6px 18px -8px rgba(242,106,27,.7);
}
.segmented input:focus-visible + span { box-shadow: 0 0 0 3px rgba(242,106,27,.25); }

/* select */
.select-wrap { position: relative; }
select { appearance: none; -webkit-appearance: none; cursor: pointer; padding-right: 40px; }
.select-arrow { position: absolute; right: 14px; top: 50%; transform: translateY(-50%); color: var(--orange); pointer-events: none; font-size: 13px; }

.form-note { font-size: 11px; color: var(--gray-dim); text-align: center; letter-spacing: .04em; }
.form-error {
  font-size: 13px; color: #ff8a6b; text-align: center;
  background: rgba(226,58,25,.1); border: 1px solid rgba(226,58,25,.3);
  border-radius: 10px; padding: 10px;
}

/* success */
.success { text-align: center; padding: 30px 10px; animation: fadeUp .5s var(--ease) both; }
.success-mark {
  width: 78px; height: 78px; margin: 0 auto 22px;
  display: grid; place-items: center;
  color: var(--amber);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(242,106,27,.18), transparent 70%);
  border: 1px solid rgba(242,106,27,.4);
}
.success-mark path { stroke-dasharray: 60; stroke-dashoffset: 60; animation: draw .6s .15s var(--ease) forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
.success h3 { font-family: var(--font-display); font-weight: 800; font-size: 1.7rem; margin-bottom: 10px; }
.success p { color: var(--gray); max-width: 360px; margin: 0 auto; }

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
  position: relative; z-index: 3;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 26px clamp(18px, 4vw, 48px) 40px;
  display: flex; justify-content: space-between; align-items: center;
  border-top: 1px solid var(--line);
  font-size: 12px; color: var(--gray-dim);
}
.footer a { color: var(--gray-dim); text-decoration: none; transition: color .2s; }
.footer a:hover { color: var(--orange); }

/* ============================================================
   REVEAL ANIMATIONS
   ============================================================ */
.reveal { opacity: 0; transform: translateY(22px); animation: fadeUp .8s var(--ease) forwards; animation-delay: calc(var(--d) * 90ms + 120ms); }
@keyframes fadeUp { to { opacity: 1; transform: translateY(0); } }

.apply-head, .apply-card { opacity: 0; transform: translateY(30px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.apply-card { transition-delay: .12s; }
.is-in { opacity: 1 !important; transform: none !important; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 860px) {
  .apply-inner { grid-template-columns: 1fr; }
  .apply-head { position: static; }
  .hud-tr, .hud-br { display: none; }
}
@media (max-width: 560px) {
  .hero { min-height: auto; padding-top: 34px; padding-bottom: 44px; }
  .eyebrow { font-size: 10.5px; letter-spacing: .1em; gap: 8px; margin-bottom: 20px; }

  /* headline flows naturally — the desktop line breaks get bad on narrow screens */
  .headline { font-size: clamp(2.05rem, 8.8vw, 2.9rem); line-height: 1.04; text-wrap: balance; }
  .headline .line { display: inline; }
  .headline .grad { padding-right: 0; }

  .sub { margin-top: 20px; font-size: 1.02rem; }
  .pillars { margin-top: 22px; gap: 10px; }
  .hero-cta { gap: 14px; margin-top: 28px; }
  .btn { width: 100%; justify-content: center; }
  .brand-word { font-size: 19px; }

  .apply { padding-top: 56px; }
  .apply-title { font-size: clamp(1.95rem, 8.8vw, 2.7rem); }
  .apply-sub { font-size: 1rem; }
  .apply-points { margin-top: 22px; }

  .field-row { grid-template-columns: 1fr; }
  .segmented { grid-template-columns: 1fr; }
  .hud { display: none; }
  .footer { flex-direction: column; gap: 10px; text-align: center; }
  .scroll-cue { display: none; }
}

@media (max-width: 360px) {
  .headline { font-size: 1.95rem; }
  .eyebrow { font-size: 9.5px; }
  .topbar { padding: 18px 16px; }
  .hero, .apply { padding-left: 16px; padding-right: 16px; }
}

/* ============================================================
   REDUCED MOTION
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal, .apply-head, .apply-card { opacity: 1 !important; transform: none !important; }
  html { scroll-behavior: auto; }
  .bg-particles { display: none; }
}
