﻿/* ============================================================
   HOW IT WORKS — 5-step DSP animation
   ============================================================ */

.hiw {
  background: rgba(245, 244, 248, 0.90);
  padding: 64px 0 72px;
  overflow: hidden;
}

/* ── Header ── */
.hiw__eyebrow {
  font-family: "Montserrat", sans-serif;
  font-size: 11px;
  letter-spacing: 0.22em;
  color: #9414FA;
  margin-bottom: 18px;
}
.hiw__title-row {
  margin-bottom: 32px;
}
@media (max-width: 780px) { .hiw__title-row { flex-direction: column; } }
.hiw__title {
  font-family: "Montserrat", sans-serif;
  font-weight: 800;
  font-size: clamp(28px, 4vw, 52px);
  line-height: 1.08;
  letter-spacing: -0.03em;
  color: #121212;
  margin: 0;
}
.hiw__title em {
  font-style: italic;
  background: linear-gradient(135deg, #9414FA 0%, #B33AF0 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hiw__subtitle {
  font-size: clamp(15px, 1.1vw, 17px);
  color: #3e3e3e;
  opacity: 0.78;
  max-width: 640px;
  line-height: 1.5;
  margin: 12px 0 0;
  font-weight: 400;
}

/* ── Loop pill ── */
.hiw__step--loop {
  background: linear-gradient(135deg, #9414FA, #4CCBFF);
  border-color: transparent;
  color: #fff;
}
.hiw__step--loop:hover { opacity: 0.88; border-color: transparent; color: #fff; }
.hiw__step--loop.active {
  background: linear-gradient(135deg, #7a08d4, #2bb8f5);
  box-shadow: 0 6px 20px -4px rgba(76,203,255,0.40);
}
.hiw__step-loop-icon { font-size: 15px; line-height: 1; }

/* ── Two-column body layout ── */
.hiw__body {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 40px;
  align-items: start;
}
@media (max-width: 860px) {
  .hiw__body { grid-template-columns: 1fr; }

  /* Stage becomes inline block inside the active sidenav-item */
  .hiw__stage {
    position: relative;
    height: auto;
    min-height: 0;
    margin-top: 16px;
    width: 100%;
  }
  .hiw__panel {
    position: relative;
    inset: unset;
    height: auto;
    transition: opacity 300ms ease;
  }
  .hiw__panel:not(.active) {
    display: none;
  }
  .hiw__panel.active {
    display: block;
    opacity: 1;
    pointer-events: auto;
  }
  .hiw__panel-inner {
    height: auto;
  }
  /* Give cards a fixed height for the animation to render properly */
  .hiw__card {
    min-height: 360px;
  }
}

/* ── Vertical sidenav ── */
.hiw__sidenav {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-top: 0;
}
.hiw__sidenav-item {
  display: flex;
  flex-direction: column;
}

/* ── Step pills ── */
.hiw__step {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 999px;
  border: 1.5px solid #e0dde8;
  background: #fff;
  font-family: "Montserrat", sans-serif;
  font-size: 13px;
  font-weight: 600;
  color: #8b8b8b;
  cursor: pointer;
  transition: all 220ms cubic-bezier(0.2, 0.8, 0.2, 1);
  width: fit-content;
  min-width: 188px;
}
.hiw__step:hover { border-color: #9414FA; color: #9414FA; }
.hiw__step.active {
  background: #9414FA;
  border-color: #9414FA;
  color: #fff;
  box-shadow: 0 6px 20px -4px rgba(148,20,250,0.40);
}
.hiw__step-num {
  font-family: "Montserrat", sans-serif;
  font-size: 10px;
  letter-spacing: 0.12em;
  opacity: 0.7;
}
.hiw__step.active .hiw__step-num { opacity: 1; }

/* ── Step inline description ── */
.hiw__step-desc {
  display: none;
  padding: 12px 18px 12px;
  max-width: 240px;
}
.hiw__step-desc.active {
  display: block;
}
.hiw__step-desc p {
  font-size: 13px;
  line-height: 1.6;
  color: #6f6f6f;
  margin: 0 0 10px;
}
.hiw__step-desc .hiw__tags span {
  font-size: 10px;
  padding: 4px 10px;
}

/* ── Stage ── */
.hiw__stage {
  background: transparent;
  border-radius: 0;
  border: none;
  overflow: visible;
  box-shadow: none;
  position: relative;
  height: 500px;
}
/* Clip only the non-loop panels, not the orbit labels */
.hiw__panel:not(.hiw__panel--loop) {
  overflow: hidden;
  border-radius: 24px;
}
.hiw__progress-wrap {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  z-index: 10;
}
.hiw__progress {
  height: 100%;
  background: #f0edf8;
}
.hiw__progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #9414FA, #B33AF0);
  width: 0%;
  transition: width 0.1s linear;
}

/* ── Panels — all absolute, z-index toggle fixes stacking bugs ── */
.hiw__panel {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 500ms ease;
  padding: 0;
  display: flex;
  align-items: center;
  z-index: 1;
}
.hiw__panel.active {
  opacity: 1;
  pointer-events: auto;
  z-index: 2;
}
.hiw__panel-inner {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  width: 100%;
  height: 100%;
}
.hiw__panel-inner > .hiw__card {
  width: 100%;
  max-width: 100%;
}

/* ── Dark card shell ── */
.hiw__card {
  background: #121212;
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 12px 48px -12px rgba(0,0,0,0.60), 0 0 0 1px rgba(148,20,250,0.08);
  display: flex;
  flex-direction: column;
  position: relative;
}
.hiw__card-chrome {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  background: #1a1a1a;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.hiw__dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.hiw__dot--red    { background: #ff5f57; }
.hiw__dot--yellow { background: #febc2e; }
.hiw__dot--green  { background: #28c840; }
.hiw__card-title {
  font-family: "Montserrat", sans-serif;
  font-size: 10px;
  letter-spacing: 0.10em;
  color: rgba(255,255,255,0.75);
}

/* ── Panel copy ── */
.hiw__panel-copy h3 {
  font-family: "Montserrat", sans-serif;
  font-weight: 800;
  font-size: clamp(22px, 2.5vw, 32px);
  letter-spacing: -0.025em;
  color: #121212;
  margin: 0 0 14px;
}
.hiw__panel-copy p {
  font-size: 15px;
  line-height: 1.65;
  color: #6f6f6f;
  margin: 0 0 20px;
}
.hiw__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.hiw__tags span {
  font-family: "Montserrat", sans-serif;
  font-size: 10px;
  letter-spacing: 0.10em;
  padding: 5px 12px;
  border-radius: 999px;
  background: #f0edf8;
  color: #9414FA;
  border: 1px solid rgba(148,20,250,0.15);
}

/* ============================================================
   STEP 0 — AI Chat / Understand (light mode)
   ============================================================ */
.hiw__card--light {
  background: #fff;
  border: 1px solid #e4e4e4;
  box-shadow: 0 4px 24px -8px rgba(0,0,0,0.10);
  display: flex;
  flex-direction: column;
  height: 440px;
}
.hiw__card-chrome--light {
  background: #f5f5f5;
  border-bottom: 1px solid #e8e8e8;
}
.hiw__card-title--light { color: #222; }

.hiw__chat-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.hiw__chat-messages {
  flex: 1;
  padding: 12px 14px 8px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 9px;
  overflow: hidden;
}
.hiw__bubble {
  max-width: 86%;
  padding: 8px 12px;
  border-radius: 14px;
  font-family: "Montserrat", sans-serif;
  font-size: 11.5px;
  line-height: 1.5;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 350ms ease, transform 350ms ease;
}
.hiw__bubble.show { opacity: 1; transform: translateY(0); }
.hiw__bubble--user {
  background: #7c3aed;
  color: #fff;
  align-self: flex-end;
  border-bottom-right-radius: 4px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.hiw__bubble-attachment {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(255,255,255,0.15);
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: 6px;
  padding: 5px 10px;
  font-size: 11px;
  font-family: "Montserrat", sans-serif;
  font-weight: 600;
  color: #fff;
  letter-spacing: 0.02em;
}
.hiw__bubble-attachment svg {
  flex-shrink: 0;
  opacity: 0.85;
}
.hiw__bubble--ai {
  background: transparent;
  color: #222;
  border: none;
  align-self: flex-start;
  border-bottom-left-radius: 4px;
  padding: 0;
  max-width: 100%;
}
.hiw__bubble--typing {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 8px 12px;
  background: #f0f0f0;
  border-radius: 12px;
  align-self: flex-start;
}
.hiw__bubble--typing span {
  display: block;
  width: 5px; height: 5px;
  border-radius: 50%;
  background: #bbb;
  animation: typingDot 1.2s infinite ease-in-out;
}
.hiw__bubble--typing span:nth-child(2) { animation-delay: 0.2s; }
.hiw__bubble--typing span:nth-child(3) { animation-delay: 0.4s; }
@keyframes typingDot {
  0%,60%,100% { transform: translateY(0); opacity: 0.5; }
  30% { transform: translateY(-4px); opacity: 1; }
}

/* ── Bar chart response card ── */
.hiw__rchart {
  background: #fafafa;
  border: 0.5px solid #e8e8e8;
  border-radius: 10px;
  padding: 10px 12px;
  width: 100%;
}
.hiw__rchart-title { font-size: 10.5px; font-weight: 700; color: #1a1a1a; margin-bottom: 2px; font-family: "Montserrat", sans-serif; }
.hiw__rchart-meta  { font-size: 9.5px; color: #aaa; margin-bottom: 10px; font-family: "Montserrat", sans-serif; }
.hiw__rchart-row   { display: flex; align-items: center; gap: 7px; margin-bottom: 5px; }
.hiw__rchart-label { font-size: 10px; color: #555; width: 120px; flex-shrink: 0; text-align: right; font-family: "Montserrat", sans-serif; }
.hiw__rchart-track { flex: 1; background: #f0eeff; border-radius: 3px; height: 11px; overflow: hidden; }
.hiw__rchart-fill  { height: 100%; background: #7c3aed; border-radius: 3px; width: 0%; transition: width 700ms ease; }
.hiw__rchart-pct   { font-size: 10px; color: #666; width: 32px; text-align: right; flex-shrink: 0; font-family: "Montserrat", sans-serif; }
.hiw__rchart-src   { font-size: 9px; color: #bbb; margin-top: 8px; padding-top: 6px; border-top: 0.5px solid #eee; display: flex; justify-content: space-between; font-family: "Montserrat", sans-serif; }

/* ── Question card (Understand step) ── */
.hiw__rquestion { width: 100%; }
.hiw__rquestion-text { font-size: 11px; font-weight: 700; color: #1a1a1a; margin-bottom: 3px; line-height: 1.4; font-family: "Montserrat", sans-serif; }
.hiw__rquestion-meta { font-size: 9px; color: #aaa; margin-bottom: 9px; font-family: "Montserrat", sans-serif; }
.hiw__rquestion-chips { display: flex; flex-wrap: wrap; gap: 5px; }
.hiw__rquestion-chip {
  font-size: 9.5px;
  color: #7c3aed;
  border: 1px solid #c4b5fd;
  border-radius: 20px;
  padding: 4px 10px;
  cursor: default;
  font-family: "Montserrat", sans-serif;
  transition: background .25s, border-color .25s, color .25s;
  white-space: nowrap;
}
.hiw__rquestion-chip--selected {
  background: #7c3aed;
  border-color: #7c3aed;
  color: #fff;
}

/* ── Insights card ── */
.hiw__rinsights {
  background: #f5f3ff;
  border: 0.5px solid #ddd6fe;
  border-radius: 10px;
  padding: 10px 12px;
  width: 100%;
}
.hiw__rinsights--pink {
  background: #fce7f3;
  border-color: #f9a8d4;
}
.hiw__rinsights-head { font-size: 9.5px; font-weight: 700; color: #1a1a1a; letter-spacing: .07em; text-transform: uppercase; display: flex; align-items: center; gap: 5px; margin-bottom: 7px; font-family: "Montserrat", sans-serif; }
.hiw__rinsights-row  { display: flex; gap: 6px; margin-bottom: 4px; font-size: 10px; color: #333; line-height: 1.4; font-family: "Montserrat", sans-serif; }
.hiw__rinsights-arr  { color: #7c3aed; font-weight: 700; flex-shrink: 0; font-size: 8px; margin-top: 2px; }

/* ── Go deeper card ── */
.hiw__rdeeper {
  background: #fff;
  border: 0.5px solid #e8e8e8;
  border-radius: 10px;
  overflow: hidden;
  width: 100%;
}
.hiw__rdeeper-lbl  { font-size: 9.5px; color: #aaa; padding: 7px 11px 4px; font-family: "Montserrat", sans-serif; letter-spacing: .05em; }
.hiw__rdeeper-row  { display: flex; align-items: center; gap: 7px; padding: 6px 11px; border-top: 0.5px solid #f2f2f2; }
.hiw__rdeeper-arr  { color: #7c3aed; font-size: 11px; flex-shrink: 0; }
.hiw__rdeeper-text { font-size: 10px; color: #444; font-family: "Montserrat", sans-serif; }

/* ── Go deeper chips variant ── */
.hiw__rdeeper--chips { overflow: visible; }
.hiw__rdeeper--chips .hiw__rdeeper-lbl { padding: 0 0 7px; border-bottom: none; }
.hiw__rdeeper-chips-row { display: flex; flex-wrap: wrap; gap: 5px; padding: 0; }
.hiw__rdeeper-chip {
  font-size: 9.5px;
  color: #7c3aed;
  border: 1px solid #c4b5fd;
  border-radius: 20px;
  padding: 4px 10px;
  font-family: "Montserrat", sans-serif;
  white-space: nowrap;
}

/* ── Input row (light) ── */
.hiw__chat-input-row--light {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px 10px;
  border-top: 1px solid #eee;
  background: #fff;
  flex-shrink: 0;
}
.hiw__chat-input-wrap--light {
  flex: 1;
  background: #f7f7f7;
  border: 1px solid #ddd;
  border-radius: 20px;
  padding: 7px 12px;
  font-family: "Montserrat", sans-serif;
  font-size: 11.5px;
  color: #222;
  min-height: 34px;
  display: flex;
  align-items: center;
}
.hiw__cursor--light {
  display: inline-block;
  width: 1.5px;
  height: 12px;
  background: #7c3aed;
  margin-left: 1px;
  vertical-align: middle;
  animation: blink 0.9s step-end infinite;
}
@keyframes blink { 0%,100%{opacity:1} 50%{opacity:0} }
.hiw__chat-send--light {
  width: 34px; height: 34px;
  border-radius: 50%;
  background: #7c3aed;
  border: none;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  opacity: 1;
  transition: transform 150ms, box-shadow 150ms;
}
.hiw__chat-send--light:hover { transform: scale(1.08); box-shadow: 0 4px 14px -4px rgba(124,58,237,0.5); }

/* ============================================================
   STEP 1 — Planner / Plan
   ============================================================ */
.hiw__planner-body { padding: 20px 24px; display: flex; flex-direction: column; gap: 14px; }
.hiw__planner-row { display: flex; align-items: center; gap: 12px; }
.hiw__planner-lbl {
  font-family: "Montserrat", sans-serif;
  font-size: 10px;
  letter-spacing: 0.10em;
  color: rgba(255,255,255,0.40);
  min-width: 76px;
}
.hiw__bar-track {
  flex: 1;
  height: 8px;
  background: rgba(255,255,255,0.07);
  border-radius: 999px;
  overflow: hidden;
  display: flex;
}
.hiw__bar-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #9414FA, #B33AF0);
  border-radius: 999px;
  transition: width 900ms cubic-bezier(0.2,0.8,0.2,1);
}
.hiw__bar-fill--accent { background: linear-gradient(90deg, #B33AF0, #DB1EFA); }

/* Gender buttons */
.hiw__gender-btns {
  flex: 1;
  display: flex;
  gap: 6px;
}
.hiw__gender-btn {
  flex: 1;
  padding: 5px 0;
  border-radius: 6px;
  border: 1.5px solid rgba(255,255,255,0.10);
  background: rgba(255,255,255,0.04);
  color: rgba(255,255,255,0.35);
  font-family: "Montserrat", sans-serif;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  transition: all 220ms;
}
.hiw__gender-btn.active {
  background: rgba(148,20,250,0.20);
  border-color: #9414FA;
  color: #c97bff;
  box-shadow: 0 0 10px rgba(148,20,250,0.25);
}
.hiw__planner-val {
  font-family: "Montserrat", sans-serif;
  font-size: 11px;
  color: rgba(255,255,255,0.60);
  min-width: 44px;
  text-align: right;
}
.hiw__val--highlight { color: #c97bff; font-weight: 700; }
.hiw__planner-forecast {
  display: flex;
  gap: 10px;
  padding-top: 8px;
  border-top: 1px solid rgba(255,255,255,0.06);
}
.hiw__forecast-chip {
  background: #9414FA;
  border: none;
  border-radius: 8px;
  padding: 8px 14px;
  font-size: 12px;
  color: #fff;
  font-family: "Montserrat", sans-serif;
  flex: 1;
  text-align: center;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 400ms, transform 400ms;
}
.hiw__forecast-chip strong { display: block; font-size: 16px; color: #fff; font-weight: 800; margin-top: 2px; }
.hiw__forecast-chip.visible { opacity: 1; transform: translateY(0); }

/* Est. Reach highlight row */
.hiw__planner-row--reach {
  background: rgba(148,20,250,0.08);
  border: 1px solid rgba(148,20,250,0.20);
  border-radius: 8px;
  padding: 6px 8px;
  margin: 2px -4px;
}
.hiw__planner-lbl--reach { color: #c97bff !important; font-weight: 700; }
.hiw__bar-track--reach { height: 12px !important; }
.hiw__bar-fill--reach {
  height: 100%;
  background: linear-gradient(90deg, #4CCBFF, #9414FA, #B33AF0) !important;
  box-shadow: 0 0 10px rgba(148,20,250,0.50);
}

/* Planner fake cursor */
.hiw__planner-cursor {
  position: absolute;
  top: 0; left: 0;
  pointer-events: none;
  z-index: 10;
  opacity: 0;
  transition: opacity 200ms;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.6));
}
.hiw__planner-cursor.visible { opacity: 1; }

/* ============================================================
   STEP 2 — Spotlight / Create
   ============================================================ */
.hiw__card--spotlight {
  display: flex;
  flex-direction: column;
}
.hiw__spotlight-body {
  flex: 1;
  display: flex;
  align-items: stretch;  /* children fill full height → aspect-ratio calculates width */
  justify-content: center;
  gap: 8px;
  padding: 20px;
  background: #fff;
  overflow: hidden;
}

/* Width is derived from height via 9:16 — never crops */
.hiw__spot-vid-wrap {
  flex: none;
  width: auto;
  aspect-ratio: 9 / 16;
  border-radius: 10px;
  overflow: hidden;
  position: relative;
  opacity: 0;
  transform: scale(0.96);
  transition: opacity 500ms ease, transform 600ms cubic-bezier(0.34, 1.2, 0.64, 1);
}
.hiw__spot-vid-wrap.lit {
  opacity: 1;
  transform: scale(1);
}
.hiw__spot-vid-wrap video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Progress dots for the mobile single-video carousel (hidden on desktop) */
.hiw__spot-dots {
  display: none;
  position: absolute;
  left: 50%;
  bottom: 10px;
  transform: translateX(-50%);
  gap: 6px;
  z-index: 2;
}
.hiw__spot-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.15);
  transition: background 250ms, transform 250ms;
}
.hiw__spot-dot.active {
  background: #9414FA;
  transform: scale(1.3);
}

/* Keep old studio classes hidden (used by old step) */
.hiw__studio-body {
  display: flex;
  flex: 1;
  gap: 0;
  overflow: hidden;
}

/* Left panel: thumbnail list — fills full card height */
.hiw__studio-list {
  width: 185px;
  flex-shrink: 0;
  border-right: 1px solid #ebebeb;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  align-self: stretch;
}
.hiw__studio-thumb {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 12px;
  border-bottom: 1px solid #f0f0f0;
  border-left: 3px solid transparent;
  background: transparent;
  cursor: pointer;
  transition: all 180ms ease;
  min-height: 0;
}
.hiw__studio-thumb:last-child { border-bottom: none; }
.hiw__studio-thumb:hover { background: #faf8ff; }
.hiw__studio-thumb.active {
  border-left-color: #9414FA;
  background: #f7f2ff;
}
.hiw__studio-thumb-img {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  overflow: hidden;
  flex-shrink: 0;
  background: #eee;
  box-shadow: 0 2px 8px rgba(0,0,0,0.12);
}
.hiw__studio-thumb-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hiw__studio-thumb-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}
.hiw__studio-thumb-name {
  font-family: "Montserrat", sans-serif;
  font-size: 11px;
  font-weight: 700;
  color: #1a1a1a;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.hiw__studio-thumb-type {
  font-family: "Montserrat", sans-serif;
  font-size: 9px;
  color: #aaa;
  white-space: nowrap;
}
.hiw__studio-thumb.active .hiw__studio-thumb-name { color: #7a08d4; }
.hiw__studio-thumb.active .hiw__studio-thumb-type { color: #b370f5; }

/* Right panel: phone + metrics side by side */
.hiw__studio-preview {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  padding: 16px 18px;
}
.hiw__studio-phone-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.hiw__studio-phone {
  position: relative;
  width: 100px;
  background: #1a1a1a;
  border-radius: 18px;
  padding: 9px 5px 9px;
  box-shadow: 0 8px 32px -8px rgba(0,0,0,0.40), 0 0 0 1px rgba(0,0,0,0.08);
  display: flex;
  flex-direction: column;
  align-items: center;
}
.hiw__studio-phone-notch {
  width: 28px;
  height: 4px;
  background: #333;
  border-radius: 999px;
  margin-bottom: 7px;
}
.hiw__studio-phone-screen {
  width: 100%;
  aspect-ratio: 9 / 16;
  border-radius: 7px;
  overflow: hidden;
  background: #000;
}
.hiw__studio-phone-screen img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: opacity 350ms ease;
}
.hiw__studio-phone-screen img.switching { opacity: 0; }

/* Label below phone */
.hiw__studio-label {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
}
.hiw__studio-label-type {
  font-family: "Montserrat", sans-serif;
  font-size: 8px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #9414FA;
  font-weight: 700;
  transition: opacity 250ms ease;
}
.hiw__studio-label-name {
  font-family: "Montserrat", sans-serif;
  font-size: 11px;
  font-weight: 700;
  color: #1a1a1a;
  transition: opacity 250ms ease;
}

/* Metrics panel */
.hiw__studio-metrics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  align-content: center;
}
.hiw__studio-metric {
  background: #f7f5fc;
  border: 1px solid #ede8f8;
  border-radius: 10px;
  padding: 9px 11px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 72px;
}
.hiw__studio-metric--accent {
  background: linear-gradient(135deg, #9414FA08, #B33AF010);
  border-color: rgba(148,20,250,0.18);
}
.hiw__studio-metric-val {
  font-family: "Montserrat", sans-serif;
  font-size: 16px;
  font-weight: 800;
  color: #1a1a1a;
  letter-spacing: -0.03em;
  line-height: 1;
  transition: opacity 300ms ease;
}
.hiw__studio-metric--accent .hiw__studio-metric-val { color: #9414FA; }
.hiw__studio-metric-lbl {
  font-family: "Montserrat", sans-serif;
  font-size: 8.5px;
  color: #aaa;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-weight: 600;
  transition: opacity 300ms ease;
}

/* Cursor dark variant for light card */
.hiw__fake-cursor--dark svg path { fill: #333; stroke: #fff; }

/* Builder (old) hidden */
.hiw__builder-body { display: none; }
.hiw__builder-assets {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 80px;
}
.hiw__asset {
  background: #fff;
  border: none;
  border-radius: 10px;
  padding: 10px 8px;
  text-align: center;
  font-size: 22px;
  cursor: grab;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  transition: border-color 200ms, box-shadow 200ms, transform 200ms, opacity 300ms;
  user-select: none;
}
.hiw__asset span { font-family: "Montserrat", sans-serif; font-size: 9px; color: #9414FA; }
.hiw__asset.dragging {
  transform: scale(1.08);
  border-color: #9414FA;
  box-shadow: 0 8px 24px -6px rgba(148,20,250,0.50);
  opacity: 0.5;
}
.hiw__asset.placed { opacity: 0.25; }

.hiw__builder-canvas {
  flex: 1;
  background: #1a1a1a;
  border: 2px dashed rgba(148,20,250,0.30);
  border-radius: 12px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 180px;
  transition: border-color 300ms;
}
.hiw__builder-canvas.drag-over { border-color: #9414FA; }
.hiw__canvas-label {
  font-family: "Montserrat", sans-serif;
  font-size: 11px;
  color: rgba(255,255,255,0.18);
  letter-spacing: 0.10em;
  pointer-events: none;
  transition: opacity 300ms;
}
.hiw__canvas-label.hidden { opacity: 0; }

/* Fake cursor */
.hiw__fake-cursor {
  position: absolute;
  top: 0; left: 0;
  pointer-events: none;
  z-index: 20;
  opacity: 0;
  transition: opacity 200ms, transform 260ms cubic-bezier(0.25, 0.8, 0.25, 1);
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.6));
}
.hiw__fake-cursor.visible { opacity: 1; }

/* Ghost element dragged by cursor */
.hiw__ghost {
  position: absolute;
  top: 0; left: 0;
  pointer-events: none;
  z-index: 19;
  background: #2a1a40;
  border: 1.5px solid rgba(148,20,250,0.60);
  border-radius: 10px;
  padding: 6px 8px;
  font-size: 18px;
  text-align: center;
  opacity: 0;
  transition: opacity 150ms;
  display: flex;
  align-items: center;
  gap: 4px;
  font-family: "Montserrat", sans-serif;
  font-size: 10px;
  color: rgba(255,255,255,0.7);
  box-shadow: 0 8px 24px -4px rgba(148,20,250,0.40);
  white-space: nowrap;
}
.hiw__ghost.visible { opacity: 1; }

/* Canvas build — items appear individually as dropped */
.hiw__canvas-build {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 10px;
  transition: background 600ms ease;
  pointer-events: none;
}
.hiw__builder-canvas.complete .hiw__canvas-build {
  background: linear-gradient(135deg, #9414FA 0%, #B33AF0 60%, #DB1EFA 100%);
  box-shadow: 0 12px 40px -10px rgba(148,20,250,0.60);
}
.hiw__canvas-emoji {
  font-size: 38px;
  filter: drop-shadow(0 4px 8px rgba(0,0,0,0.3));
  opacity: 0;
  transform: scale(0.5) translateY(10px);
  transition: opacity 400ms cubic-bezier(0.2,0.8,0.2,1), transform 400ms cubic-bezier(0.2,0.8,0.2,1);
}
.hiw__canvas-logo-badge {
  background: rgba(255,255,255,0.18);
  border: 1px solid rgba(255,255,255,0.28);
  border-radius: 6px;
  padding: 4px 12px;
  font-family: "Montserrat", sans-serif;
  font-weight: 800;
  font-size: 13px;
  color: rgba(255,255,255,0.9);
  letter-spacing: 0.05em;
  opacity: 0;
  transform: scale(0.5) translateY(6px);
  transition: opacity 400ms cubic-bezier(0.2,0.8,0.2,1), transform 400ms cubic-bezier(0.2,0.8,0.2,1);
}
.hiw__canvas-cta-btn {
  background: #fff;
  color: #9414FA;
  border-radius: 999px;
  padding: 6px 18px;
  font-family: "Montserrat", sans-serif;
  font-weight: 700;
  font-size: 12px;
  opacity: 0;
  transform: scale(0.5) translateY(6px);
  transition: opacity 400ms cubic-bezier(0.2,0.8,0.2,1), transform 400ms cubic-bezier(0.2,0.8,0.2,1);
}
.hiw__canvas-emoji.placed,
.hiw__canvas-logo-badge.placed,
.hiw__canvas-cta-btn.placed {
  opacity: 1;
  transform: scale(1) translateY(0);
}

/* ============================================================
   STEP 3 — Deliver & Optimize (Campaign Manager)
   ============================================================ */
.hiw__card--deliver { display: flex; flex-direction: column; }

/* 3 stat cards */
.hiw__dlv-stats {
  display: flex;
  gap: 8px;
  padding: 12px 16px 10px;
  border-bottom: 1px solid #f0edf8;
}
.hiw__dlv-stat {
  flex: 1;
  background: #faf9ff;
  border: 1px solid #ede9f8;
  border-radius: 10px;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.hiw__dlv-stat-icon { color: #9414FA; margin-bottom: 2px; }
.hiw__dlv-stat-val {
  font-family: "Montserrat", sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: #1a0a2e;
  letter-spacing: -0.02em;
}
.hiw__dlv-stat-lbl {
  font-size: 10px;
  color: #555;
  font-family: "Montserrat", sans-serif;
  letter-spacing: 0.02em;
}

/* Campaign body */
.hiw__dlv-body { padding: 12px 16px; display: flex; flex-direction: column; gap: 10px; }
.hiw__dlv-campaign-row {
  display: flex;
  align-items: center;
  gap: 10px;
}
.hiw__dlv-cname {
  font-family: "Montserrat", sans-serif;
  font-size: 13px;
  font-weight: 700;
  color: #1a0a2e;
}
.hiw__dlv-chip {
  font-family: "Montserrat", sans-serif;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.08em;
  padding: 3px 8px;
  border-radius: 999px;
  transition: background 500ms ease, color 500ms ease;
}
.hiw__dlv-chip--active  { background: #e6f9ee; color: #1a8a44; }
.hiw__dlv-chip--ahead   { background: #e8f0ff; color: #2756cc; }
.hiw__dlv-chip--onpace  { background: #e6f9ee; color: #1a8a44; }
.hiw__dlv-chip--behind  { background: #fff3e0; color: #b85c00; }

/* Budget bar */
.hiw__dlv-budget-row {
  display: flex;
  align-items: center;
  gap: 8px;
}
.hiw__dlv-budget-lbl {
  font-family: "Montserrat", sans-serif;
  font-size: 9px;
  letter-spacing: 0.10em;
  color: #666;
  white-space: nowrap;
}
.hiw__dlv-budget-track {
  flex: 1;
  height: 6px;
  background: #f0edf8;
  border-radius: 999px;
  overflow: hidden;
}
.hiw__dlv-budget-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #9414FA, #B33AF0);
  border-radius: 999px;
  transition: width 1.4s cubic-bezier(0.2,0.8,0.2,1);
}
.hiw__dlv-budget-meta {
  font-size: 10px;
  color: #555;
  white-space: nowrap;
}
.hiw__dlv-accent { color: #9414FA; }

/* Line items table */
.hiw__dlv-table { display: flex; flex-direction: column; gap: 2px; }
.hiw__dlv-thead {
  display: grid;
  grid-template-columns: 2fr 70px 70px 60px 70px;
  gap: 4px;
  padding: 4px 8px;
  font-family: "Montserrat", sans-serif;
  font-size: 8px;
  letter-spacing: 0.10em;
  color: #666;
}
.hiw__dlv-row {
  display: grid;
  grid-template-columns: 2fr 70px 70px 60px 70px;
  gap: 4px;
  align-items: center;
  padding: 7px 8px;
  border-radius: 8px;
  background: #faf9ff;
  font-size: 11px;
  color: #333;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 300ms ease, transform 300ms ease;
}
.hiw__dlv-row.visible { opacity: 1; transform: translateY(0); }
.hiw__dlv-row-name {
  display: flex;
  flex-direction: column;
  font-family: "Montserrat", sans-serif;
  font-size: 10px;
  font-weight: 600;
  color: #1a0a2e;
}
.hiw__dlv-row-name small { font-weight: 400; color: #666; font-size: 9px; }

/* "+N more" note shown only on mobile once the list is trimmed */
.hiw__dlv-more {
  display: none;
  text-align: center;
  font-family: "Montserrat", sans-serif;
  font-size: 9.5px;
  color: #999;
  padding: 6px 0 2px;
}

/* Keep old inventory CSS */
.hiw__inventory-body { padding: 16px 20px; }
.hiw__inventory-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
  font-size: 12px;
  color: rgba(255,255,255,0.35);
  font-family: "Montserrat", sans-serif;
}
.hiw__inv-count { color: #c97bff; font-weight: 700; }
.hiw__inventory-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 16px;
}
.hiw__inv-item {
  background: #1e1e1e;
  border: 1.5px solid rgba(255,255,255,0.08);
  border-radius: 12px;
  padding: 12px 8px;
  text-align: center;
  font-size: 22px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  transition: all 300ms cubic-bezier(0.2,0.8,0.2,1);
  filter: grayscale(1) brightness(0.5);
  opacity: 0.5;
}
.hiw__inv-item span {
  font-family: "Montserrat", sans-serif;
  font-size: 9px;
  letter-spacing: 0.06em;
  color: rgba(255,255,255,0.30);
}
.hiw__inv-item.active {
  filter: grayscale(0) brightness(1);
  opacity: 1;
  background: #fff;
  border-color: transparent;
  box-shadow: none;
  transform: scale(1.04);
}
.hiw__inv-item.active span { color: #9414FA; }
.hiw__inv-smartbid {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-top: 10px;
  border-top: 1px solid rgba(255,255,255,0.06);
}
.hiw__inv-bid-lbl {
  font-family: "Montserrat", sans-serif;
  font-size: 10px;
  letter-spacing: 0.10em;
  color: #c97bff;
  white-space: nowrap;
}
.hiw__inv-bid-bar {
  flex: 1;
  height: 6px;
  background: rgba(255,255,255,0.07);
  border-radius: 999px;
  overflow: hidden;
}
.hiw__inv-bid-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #4CCBFF, #9414FA, #B33AF0);
  border-radius: 999px;
  transition: width 1.2s cubic-bezier(0.2,0.8,0.2,1);
}
.hiw__inv-bid-val {
  font-family: "Montserrat", sans-serif;
  font-size: 10px;
  color: #c97bff;
  white-space: nowrap;
}

/* ============================================================
   STEP 4 — Measure (light, redesigned)
   ============================================================ */

/* ── Campaign banner ── */
.hiw__msr-banner {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px;
  background: linear-gradient(135deg, #6B00C8 0%, #9414FA 100%);
  flex-shrink: 0;
}
.hiw__msr-bleft { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.hiw__msr-row1 { display: flex; align-items: center; gap: 8px; }
.hiw__msr-inflight {
  font-family: "Montserrat", sans-serif; font-size: 8px; font-weight: 700;
  letter-spacing: 0.1em; background: rgba(255,255,255,0.2);
  color: #fff; padding: 2px 7px; border-radius: 99px;
}
.hiw__msr-btype { font-family: "Montserrat", sans-serif; font-size: 8px; letter-spacing: 0.12em; color: rgba(255,255,255,0.65); }
.hiw__msr-pctrow { display: flex; align-items: baseline; gap: 7px; }
.hiw__msr-pct { font-size: 20px; font-weight: 800; color: #fff; line-height: 1; font-family: var(--font-display); }
.hiw__msr-budget { font-family: "Montserrat", sans-serif; font-size: 8px; color: rgba(255,255,255,0.65); }
.hiw__msr-bstats {
  display: flex; gap: 8px; font-family: "Montserrat", sans-serif;
  font-size: 7.5px; color: rgba(255,255,255,0.5); letter-spacing: 0.04em;
}
.hiw__msr-bright {
  display: flex; flex-direction: column; align-items: center; gap: 1px;
  background: rgba(255,255,255,0.15); border: 1px solid rgba(255,255,255,0.3);
  border-radius: 10px; padding: 7px 12px; flex-shrink: 0;
}
.hiw__msr-clbl { font-family: "Montserrat", sans-serif; font-size: 7px; letter-spacing: 0.14em; color: rgba(255,255,255,0.65); display: block; }
.hiw__msr-conf { font-size: 22px; font-weight: 800; color: #fff; line-height: 1; font-family: var(--font-display); display: block; }

/* ── Charts 2×2 grid ── */
.hiw__msr-charts {
  flex: 1; display: grid;
  grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr;
  gap: 7px; padding: 9px 12px; min-height: 0;
}
.hiw__msrc {
  background: #f8f7fc; border: 1px solid #eceaf5; border-radius: 10px;
  padding: 8px 9px 7px; display: flex; flex-direction: column; gap: 5px;
  overflow: hidden; min-height: 0;
}
.hiw__msrc-head { display: flex; justify-content: space-between; align-items: baseline; flex-shrink: 0; }
.hiw__msrc-head b { font-family: "Montserrat", sans-serif; font-size: 8.5px; font-weight: 700; color: #1a1a1a; letter-spacing: -0.01em; }
.hiw__msrc-head span { font-family: "Montserrat", sans-serif; font-size: 7.5px; color: #777; }

/* Chart 1: Inventory pie */
.hiw__msrc-inv { flex: 1; display: flex; align-items: center; gap: 8px; min-height: 0; }
.hiw__msrc-pie { width: 56px; height: 56px; flex-shrink: 0; }
.hiw__msrc-inv-legend { display: flex; flex-direction: column; gap: 5px; }
.hiw__msrc-inv-legend > div { display: flex; align-items: center; gap: 5px; font-family: "Montserrat", sans-serif; font-size: 8px; color: #444; }
.hiw__msrc-inv-legend b { color: #1a1a1a; }
.hiw__msrc-inv-legend em { color: #8B00E8; font-style: normal; font-weight: 600; }
.hiw__msrc-dot { width: 8px; height: 8px; border-radius: 2px; display: inline-block; flex-shrink: 0; }

/* Chart 2: Age bars */
.hiw__msrc-age { flex: 1; display: flex; align-items: flex-end; gap: 4px; min-height: 0; padding-top: 4px; }
.hiw__msrc-agecol { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px; height: 100%; }
.hiw__msrc-agepct { font-family: "Montserrat", sans-serif; font-size: 7px; color: #666; flex-shrink: 0; }
.hiw__msrc-barwrap { flex: 1; width: 100%; display: flex; align-items: flex-end; min-height: 0; }
.hiw__msrc-bar { width: 100%; height: 100%; border-radius: 3px 3px 0 0; transform-origin: bottom center; }
.hiw__msrc-agelbl { font-family: "Montserrat", sans-serif; font-size: 7px; color: #777; flex-shrink: 0; }

/* Chart 3: Reach summary */
.hiw__msrc-reach { flex: 1; display: flex; flex-direction: column; gap: 5px; min-height: 0; }
.hiw__msrc-reachhero { background: #f0e8ff; border: 1px solid #ddd0ff; border-radius: 8px; padding: 5px 9px; flex-shrink: 0; }
.hiw__msrc-reachbig { font-size: 18px; font-weight: 800; color: #8B00E8; line-height: 1; display: block; font-family: var(--font-display); }
.hiw__msrc-reachlbl { font-family: "Montserrat", sans-serif; font-size: 6.5px; letter-spacing: 0.1em; color: #9414FA; display: block; margin-top: 1px; }
.hiw__msrc-reachgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 3px; }
.hiw__msrc-rstat { display: flex; flex-direction: column; }
.hiw__msrc-rstat strong { font-family: "Montserrat", sans-serif; font-size: 9px; font-weight: 700; color: #1a1a1a; }
.hiw__msrc-rstat span { font-family: "Montserrat", sans-serif; font-size: 6px; letter-spacing: 0.08em; color: #666; }

/* Chart 4: Frequency curve */
.hiw__msrc-freqsvg { flex: 1; width: 100%; min-height: 0; overflow: visible; }
.hiw__msrc-freqx { display: flex; justify-content: space-between; flex-shrink: 0; }
.hiw__msrc-freqx span { font-family: "Montserrat", sans-serif; font-size: 7px; color: #888; }

/* ── (old dark-mode measure styles kept for reference) ── */
.hiw__measure-body { padding: 20px 24px; display: flex; flex-direction: column; gap: 20px; }
.hiw__measure-kpis {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
.hiw__kpi {
  background: #fff;
  border: none;
  border-radius: 12px;
  padding: 14px 12px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.hiw__kpi--accent {
  background: #fff;
}
.hiw__kpi-val {
  font-family: "Montserrat", sans-serif;
  font-weight: 800;
  font-size: clamp(20px, 2.5vw, 28px);
  letter-spacing: -0.03em;
  color: #9414FA;
  line-height: 1;
}
.hiw__kpi-unit { font-size: 12px; color: #9414FA; font-weight: 600; margin-bottom: 4px; }
.hiw__kpi-lbl { font-family: "Montserrat", sans-serif; font-size: 9px; letter-spacing: 0.12em; color: #222; text-transform: uppercase; }
/* ── 3-chart row ── */
.hiw__charts-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 10px;
}
.hiw__measure-chart {
  background: #1a1a1a;
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 12px;
  padding: 10px 12px 8px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.hiw__chart-lbl-top {
  font-family: "Montserrat", sans-serif;
  font-size: 9px;
  letter-spacing: 0.10em;
  color: rgba(255,255,255,0.30);
  text-transform: uppercase;
}
.hiw__chart-bars {
  display: flex;
  align-items: flex-end;
  gap: 5px;
  height: 64px;
}
.hiw__chart-bar {
  flex: 1;
  height: 0%;
  background: #9414FA;
  border-radius: 4px 4px 0 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding-bottom: 3px;
  transition: height 800ms cubic-bezier(0.2,0.8,0.2,1);
}
.hiw__chart-bar span { font-family: "Montserrat", sans-serif; font-size: 8px; color: rgba(255,255,255,0.45); }

/* Donut chart */
.hiw__measure-chart--donut { align-items: center; }
.hiw__donut-svg { width: 64px; height: 64px; flex-shrink: 0; }
.hiw__donut-legend {
  display: flex;
  gap: 8px;
  align-items: center;
  font-family: "Montserrat", sans-serif;
  font-size: 8px;
  color: rgba(255,255,255,0.40);
  flex-wrap: wrap;
  justify-content: center;
}
.hiw__donut-dot {
  display: inline-block;
  width: 6px; height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
}

/* Sparkline / area chart */
.hiw__spark-svg {
  width: 100%;
  height: 60px;
  overflow: visible;
}
.hiw__spark-labels {
  display: flex;
  justify-content: space-between;
  font-family: "Montserrat", sans-serif;
  font-size: 8px;
  color: rgba(255,255,255,0.30);
}

/* ============================================================
   The Loop — home panel
   ============================================================ */
.hiw__loop-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border-radius: 24px;
  pointer-events: none;
  opacity: 0.35;
  z-index: 0;
}
.hiw__loop-inner { position: relative; z-index: 1; }
.hiw__panel--loop {
  background: #121212;
  border-radius: 24px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.hiw__loop-inner {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 32px;
  padding: 32px 48px;
  text-align: left;
  width: 100%;
}
.hiw__loop-left {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.hiw__loop-label {
  font-family: "Montserrat", sans-serif;
  font-weight: 800;
  font-size: clamp(22px, 2.4vw, 34px);
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #DB1EFA 0%, #FF6FDF 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  line-height: 1.1;
}
.hiw__loop-caption {
  font-size: 13px;
  color: #fff;
  max-width: 320px;
  line-height: 1.6;
  font-family: "Montserrat", sans-serif;
}

/* Dynamic step preview in left column */
.hiw__loop-dynamic {
  margin-top: 8px;
  padding-top: 20px;
  border-top: 1px solid rgba(148,20,250,0.25);
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.hiw__loop-dynamic-title {
  font-family: "Montserrat", sans-serif;
  font-weight: 800;
  font-size: clamp(22px, 2.8vw, 34px);
  letter-spacing: -0.02em;
  color: #fff;
  line-height: 1.1;
  /* fixed min-height so caption below never shifts the title position */
  min-height: 1.2em;
  transition: opacity 0.22s ease;
}
.hiw__loop-dynamic-desc {
  font-size: 13px;
  color: rgba(255,255,255,0.80);
  line-height: 1.65;
  font-family: "Montserrat", sans-serif;
  max-width: 300px;
  transition: opacity 0.22s ease;
}
.hiw__loop-see-more {
  display: inline-flex;
  align-items: center;
  margin-top: 4px;
  padding: 10px 20px;
  border-radius: 999px;
  border: 0;
  background: #9F44FB;
  color: #fff;
  font-family: "Montserrat", sans-serif;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.04em;
  cursor: pointer;
  width: fit-content;
  transition: transform .2s, box-shadow .25s;
  box-shadow: 0 10px 40px -12px rgba(159,68,251,0.6), inset 0 0 0 1px rgba(255,255,255,0.1);
}
.hiw__loop-see-more:hover {
  box-shadow: 0 18px 56px -10px rgba(219,30,250,0.9);
  transform: translateY(-1px);
}

/* Orbit */
.hiw__loop-orbit {
  position: relative;
  width: 460px;
  height: 460px;
  flex-shrink: 0;
  overflow: visible;
}
.hiw__loop-logo {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 90px;
  height: auto;
  filter: invert(1) brightness(2);
  pointer-events: none;
  z-index: 3;
}
.hiw__loop-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.hiw__loop-pulse {
  animation: loopPulse 2.5s linear infinite;
  transform-origin: 120px 120px;
}
@keyframes loopPulse {
  from { stroke-dashoffset: 0; }
  to   { stroke-dashoffset: -440; }
}

/* Nodes */
.hiw__loop-node {
  position: absolute;
  top: 50%;
  left: 50%;
  transform:
    translate(-50%, -50%)
    rotate(var(--angle))
    translateY(-205px)
    rotate(calc(-1 * var(--angle)));
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  font-family: "Montserrat", sans-serif;
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  white-space: nowrap;
  cursor: pointer;
  transition: color 0.3s;
  animation: loopNodePop 0.4s cubic-bezier(0.2,0.8,0.2,1) both;
}
.hiw__loop-node:nth-child(2) { animation-delay: 0.05s; }
.hiw__loop-node:nth-child(3) { animation-delay: 0.10s; }
.hiw__loop-node:nth-child(4) { animation-delay: 0.15s; }
.hiw__loop-node:nth-child(5) { animation-delay: 0.20s; }
.hiw__loop-node:nth-child(6) { animation-delay: 0.25s; }
@keyframes loopNodePop {
  from { opacity: 0; transform:
    translate(-50%,-50%)
    rotate(var(--angle))
    translateY(-192px)
    rotate(calc(-1 * var(--angle))); }
  to { opacity: 1; transform:
    translate(-50%,-50%)
    rotate(var(--angle))
    translateY(-205px)
    rotate(calc(-1 * var(--angle))); }
}

/* Active node pill */
.hiw__loop-node--active {
  color: #fff;
}
.hiw__loop-node--active span:last-child {
  background: #fff;
  color: #C020F0;
  padding: 5px 14px;
  border-radius: 100px;
  box-shadow: 0 0 18px rgba(219,30,250,0.40);
  font-size: 15px;
  transition: all 0.35s cubic-bezier(0.2,0.8,0.2,1);
}
.hiw__loop-node--active .hiw__loop-node-num {
  color: #fff;
}

.hiw__loop-node-num {
  display: block;
  font-family: "Montserrat", sans-serif;
  font-size: 10px;
  letter-spacing: 0.12em;
  color: #c97bff;
  margin-bottom: 1px;
}
.hiw__loop-node-dot {
  width: 22px; height: 22px;
  border-radius: 50%;
  background: rgba(148,20,250,0.18);
  border: 1.5px solid rgba(148,20,250,0.50);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 3px;
  font-size: 11px;
}

/* ── Plan chat: AI text bubble & confirm card ── */
.hiw__bubble--ai-text {
  background: #f5f5f5;
  color: #222;
  font-size: 10.5px;
  font-family: "Montserrat", sans-serif;
  line-height: 1.5;
  padding: 9px 13px;
  border-radius: 12px 12px 12px 4px;
  max-width: 85%;
}
.hiw__plan-confirm {
  background: #fff;
  border: 1px solid #e8e8e8;
  border-radius: 10px;
  overflow: hidden;
  min-width: 200px;
  font-family: "Montserrat", sans-serif;
}
.hiw__plan-confirm-head {
  background: #7c3aed;
  color: #fff;
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  padding: 7px 12px;
}
.hiw__plan-confirm-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 5px 12px;
  border-bottom: 0.5px solid #f2f2f2;
  font-size: 10px;
  color: #555;
}
.hiw__plan-confirm-row strong { color: #111; font-weight: 600; }
.hiw__plan-confirm-btn {
  display: block;
  width: 100%;
  padding: 8px 12px;
  background: #7c3aed;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  font-family: "Montserrat", sans-serif;
  border: none;
  cursor: pointer;
  letter-spacing: .04em;
}
.hiw__plan-confirm-btn:hover { background: #6d28d9; }

/* ── Plan card two-column layout ── */
.hiw__card--plan {
  height: 440px;
}
.hiw__plan-body {
  flex: 1;
  display: flex;
  overflow: hidden;
}
.hiw__card--plan .hiw__chat-body {
  flex: 1;
  border-right: 1px solid #efefef;
  min-width: 0;
}

/* ── Data so far panel ── */
.hiw__plan-data {
  width: 168px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  padding: 12px 10px 10px;
  gap: 6px;
  overflow: hidden;
}
.hiw__plan-data-title {
  font-size: 8.5px;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: #7c3aed;
  font-family: "Montserrat", sans-serif;
  margin-bottom: 4px;
}
.hiw__plan-item {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  background: #f8f7ff;
  border: 1px solid #ebe8f8;
  border-radius: 8px;
  padding: 6px 8px;
  transition: border-color .3s;
}
.hiw__plan-item.filled {
  border-color: #c4b5fd;
}
.hiw__plan-item-check {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 1.5px solid #ccc;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 1px;
  transition: background .3s, border-color .3s;
}
.hiw__plan-item-check.checked {
  background: #7c3aed;
  border-color: #7c3aed;
}
.hiw__plan-item-content {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}
.hiw__plan-item-label {
  font-size: 8px;
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: #999;
  font-family: "Montserrat", sans-serif;
}
.hiw__plan-item-value {
  font-size: 9.5px;
  font-weight: 600;
  color: #1a1a1a;
  font-family: "Montserrat", sans-serif;
  line-height: 1.3;
}
.hiw__plan-cta {
  margin-top: auto;
  width: 100%;
  padding: 8px;
  border-radius: 8px;
  border: none;
  font-size: 9.5px;
  font-weight: 700;
  font-family: "Montserrat", sans-serif;
  letter-spacing: .04em;
  background: #d4d4d4;
  color: #fff;
  cursor: default;
  transition: background .4s, cursor .4s;
}
.hiw__plan-cta.enabled {
  background: #7c3aed;
  cursor: pointer;
}
.hiw__plan-cta.enabled:hover { background: #6d28d9; }

/* ── Plan results dashboard ── */
.hiw__results-pages {
  display: flex;
  flex-direction: column;
  width: 100%;
  transition: transform .65s cubic-bezier(.4,0,.2,1);
}
.hiw__results-pages.scrolled { transform: translateY(-50%); }
.hiw__results-page {
  width: 100%;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.hiw__results {
  width: 100%;
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow: hidden;
}
.hiw__results-header {
  background: #6d28d9;
  padding: 10px 14px;
  flex-shrink: 0;
}
.hiw__results-reach-big {
  font-size: 22px;
  font-weight: 800;
  color: #fff;
  font-family: "Montserrat", sans-serif;
  line-height: 1;
  margin-bottom: 6px;
}
.hiw__results-reach-big span {
  font-size: 10px;
  font-weight: 500;
  opacity: .8;
  margin-left: 4px;
}
.hiw__results-stats {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}
.hiw__results-stat {
  display: flex;
  flex-direction: column;
  gap: 1px;
}
.hiw__results-stat strong {
  font-size: 10px;
  font-weight: 700;
  color: #fff;
  font-family: "Montserrat", sans-serif;
}
.hiw__results-stat span {
  font-size: 8px;
  color: rgba(255,255,255,.65);
  font-family: "Montserrat", sans-serif;
}
.hiw__results-stat--pill {
  background: rgba(255,255,255,.15);
  border-radius: 20px;
  padding: 3px 8px;
  font-size: 8.5px;
  color: #fff;
  font-family: "Montserrat", sans-serif;
  font-weight: 600;
  flex-direction: row;
  align-items: center;
}
.hiw__results-body {
  display: flex;
  flex: 1;
  gap: 0;
  overflow: hidden;
}
.hiw__results-chart-title {
  font-size: 9px;
  font-weight: 700;
  color: #444;
  font-family: "Montserrat", sans-serif;
  letter-spacing: .05em;
  text-transform: uppercase;
  margin-bottom: 4px;
}
.hiw__results-chart-wrap {
  flex: 1;
  padding: 10px 10px 6px 10px;
  border-right: 1px solid #f0f0f0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.hiw__results-svg {
  flex: 1;
  width: 100%;
  display: block;
}
.hiw__results-line {
  stroke-dasharray: 400;
  stroke-dashoffset: 400;
  transition: stroke-dashoffset 1.2s ease;
}
.hiw__results-line.draw { stroke-dashoffset: 0; }
.hiw__results-legend {
  display: flex;
  gap: 10px;
  margin-top: 4px;
}
.hiw__results-legend span {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 8px;
  color: #666;
  font-family: "Montserrat", sans-serif;
}
.hiw__results-legend em {
  width: 8px; height: 8px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}
.hiw__results-xaxis {
  display: flex;
  justify-content: space-between;
  padding: 0 2px;
  font-size: 7.5px;
  color: #bbb;
  font-family: "Montserrat", sans-serif;
  margin-top: 2px;
}
.hiw__results-xlabel {
  text-align: center;
  font-size: 7.5px;
  color: #bbb;
  font-family: "Montserrat", sans-serif;
  margin-top: 1px;
}
.hiw__results-table-wrap {
  width: 180px;
  flex-shrink: 0;
  padding: 10px 10px 6px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.hiw__results-table {
  width: 100%;
  border-collapse: collapse;
  font-family: "Montserrat", sans-serif;
}
.hiw__results-table thead th {
  font-size: 7.5px;
  color: #aaa;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  padding: 0 0 5px;
  text-align: left;
  border-bottom: 1px solid #eee;
}
.hiw__results-row {
  opacity: 0;
  transform: translateY(4px);
  transition: opacity .3s ease var(--delay, 0s), transform .3s ease var(--delay, 0s);
}
.hiw__results-row.visible {
  opacity: 1;
  transform: translateY(0);
}
.hiw__results-table td {
  font-size: 8.5px;
  color: #333;
  padding: 5px 0;
  border-bottom: 0.5px solid #f5f5f5;
}
.hiw__results-table td.pct { color: #7c3aed; font-weight: 700; }
.hiw__results-row--total td { font-weight: 700; color: #7c3aed; }
.hiw__results-row--total td.pct { font-size: 10px; }

/* ── Fake cursor for Plan ── */
.hiw__fake-cursor {
  position: absolute;
  z-index: 99;
  pointer-events: none;
  opacity: 0;
  transition: opacity .2s;
  filter: drop-shadow(0 1px 3px rgba(0,0,0,.3));
}

/* ── Plan results: page 2 — Campaign strategy + Top placements ── */
.hiw__strategy {
  padding: 10px 14px 6px;
  flex-shrink: 0;
  border-bottom: 1px solid #f0f0f0;
}
.hiw__strategy-title { font-size: 9.5px; font-weight: 800; color: #111; font-family: "Montserrat", sans-serif; margin-bottom: 2px; }
.hiw__strategy-sub   { font-size: 8px; color: #888; font-family: "Montserrat", sans-serif; margin-bottom: 8px; }
.hiw__strategy-slider-wrap { position: relative; margin-bottom: 4px; }
.hiw__strategy-track {
  height: 6px; border-radius: 3px;
  background: linear-gradient(to right, #f59e0b, #84cc16, #22d3ee, #6366f1, #7c3aed);
  position: relative;
}
.hiw__strategy-thumb {
  width: 14px; height: 14px; border-radius: 50%;
  background: #fff; border: 2px solid #333;
  position: absolute; top: 50%; right: 0;
  transform: translate(50%, -50%);
  box-shadow: 0 1px 4px rgba(0,0,0,.2);
}
.hiw__strategy-labels {
  display: flex; justify-content: space-between;
  font-size: 7.5px; color: #bbb;
  font-family: "Montserrat", sans-serif; margin-top: 3px;
}
.hiw__strategy-labels span:last-child { font-weight: 700; color: #333; background: #fff; border: 1px solid #ddd; border-radius: 20px; padding: 1px 7px; }
.hiw__strategy-extremes {
  display: flex; justify-content: space-between;
  font-size: 7px; color: #ccc;
  font-family: "Montserrat", sans-serif; margin-top: 2px; letter-spacing: .06em; text-transform: uppercase;
}
.hiw__strategy-name {
  font-size: 18px; font-weight: 800; color: #3b82f6;
  font-family: "Montserrat", sans-serif; margin-bottom: 2px;
}

/* Keyword boxes */
.hiw__kw-boxes { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 6px; padding: 6px 14px 4px; }
.hiw__kw-box { background: #fafafa; border: 1px solid #e8e3f8; border-radius: 8px; padding: 7px 8px 6px; display: flex; flex-direction: column; gap: 5px; }
.hiw__kw-box-head { display: flex; align-items: center; justify-content: space-between; }
.hiw__kw-box-title { font-size: 8.5px; font-weight: 800; color: #111; font-family: "Montserrat", sans-serif; }
.hiw__kw-box-count { font-size: 8px; font-weight: 700; color: #7c3aed; background: #ede9fe; border-radius: 20px; padding: 1px 6px; }
.hiw__kw-box-count--zero { color: #aaa; background: #f0f0f0; }
.hiw__kw-tags { display: flex; flex-wrap: wrap; gap: 4px; min-height: 34px; }
.hiw__kw-tags--empty { align-items: flex-start; }
.hiw__kw-tag { display: inline-flex; align-items: center; gap: 3px; background: #fff; border: 1px solid #d8d0f5; border-radius: 20px; padding: 2px 7px; font-size: 7.5px; color: #5b21b6; font-family: "Montserrat", sans-serif; white-space: nowrap; }
.hiw__kw-x { font-size: 8px; color: #9c7ae0; cursor: default; }
.hiw__kw-empty-hint { font-size: 7.5px; color: #bbb; font-family: "Montserrat", sans-serif; font-style: italic; line-height: 1.4; }
.hiw__kw-input-row { display: flex; gap: 4px; }
.hiw__kw-input { flex: 1; border: 1px solid #e0d9f5; border-radius: 20px; padding: 3px 8px; font-size: 7.5px; color: #888; font-family: "Montserrat", sans-serif; outline: none; background: #fff; min-width: 0; }
.hiw__kw-add { background: none; border: none; font-size: 7.5px; font-weight: 700; color: #7c3aed; font-family: "Montserrat", sans-serif; cursor: default; padding: 0 4px; }

.hiw__placements { flex: 1; padding: 8px 14px 6px; overflow: hidden; }
.hiw__placements-head {
  display: flex; align-items: center; justify-content: space-between; margin-bottom: 7px;
}
.hiw__placements-title { font-size: 9.5px; font-weight: 800; color: #111; font-family: "Montserrat", sans-serif; }
.hiw__placements-meta  { font-size: 7.5px; color: #999; font-family: "Montserrat", sans-serif; }
.hiw__placements-cols  { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.hiw__placements-group-title {
  font-size: 8px; font-weight: 800; color: #7c3aed;
  font-family: "Montserrat", sans-serif; letter-spacing: .05em;
  margin-bottom: 5px;
}
.hiw__placements-count { font-size: 7.5px; color: #aaa; float: right; font-weight: 400; }
.hiw__placements-row   { display: flex; gap: 5px; overflow: hidden; }
.hiw__placement-card   {
  flex: 1; min-width: 0;
  display: flex; flex-direction: column; align-items: center;
  text-align: center; font-family: "Montserrat", sans-serif;
}
.hiw__placement-icon {
  width: 28px; height: 28px; border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; margin-bottom: 3px;
  border: 1px solid #eee;
  background: #f8f8f8;
  overflow: hidden;
}
.hiw__placement-icon img {
  width: 100%; height: 100%;
  object-fit: cover;
  border-radius: 7px;
}
.hiw__placement-name  { font-size: 7px; color: #222; font-weight: 600; line-height: 1.2; }
.hiw__placement-match { font-size: 6.5px; color: #aaa; margin-top: 1px; }

/* ============================================================
   MOBILE — Plan / Create / Deliver panel overrides
   (kept at end of file so they win the cascade over the
   unconditional component rules defined above)
   ============================================================ */
@media (max-width: 860px) {

  /* ── STEP 1: Plan — stack chat over a compact 2-col "Data so far" grid ── */
  .hiw__card--plan {
    height: 480px;
  }
  /* Results dashboard (reach chart + inventory table, stacked) needs more room */
  .hiw__card--plan.hiw__card--plan-results {
    height: 680px;
  }
  .hiw__plan-body {
    flex-direction: column;
  }
  .hiw__card--plan .hiw__chat-body {
    border-right: none;
    border-bottom: 1px solid #efefef;
  }
  .hiw__plan-data {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    overflow: visible;
    padding: 10px 12px;
    gap: 6px;
  }
  .hiw__plan-data-title {
    grid-column: 1 / -1;
    margin-bottom: 0;
  }
  .hiw__plan-item {
    padding: 5px 9px;
    gap: 5px;
  }
  .hiw__plan-item-check {
    width: 13px;
    height: 13px;
    margin-top: 0;
  }
  .hiw__plan-item-content {
    flex-direction: row;
    align-items: baseline;
    gap: 4px;
  }
  .hiw__plan-cta {
    grid-column: 1 / -1;
    margin-top: 6px;
  }

  /* ── STEP 2: Plan results — stack chart above the inventory table ── */
  .hiw__results-body {
    flex-direction: column;
  }
  .hiw__results-chart-wrap {
    border-right: none;
    border-bottom: 1px solid #f0f0f0;
    flex: 0 0 auto;
    height: 200px;
  }
  .hiw__results-table-wrap {
    width: 100%;
    flex: 0 0 auto;
  }

  /* ── STEP 2: Create — one video at a time, crossfade carousel ── */
  .hiw__spotlight-body {
    position: relative;
    padding: 24px;
  }
  .hiw__spot-vid-wrap {
    position: absolute;
    top: 50%;
    left: 50%;
    height: calc(100% - 48px);
    width: auto;
    transform: translate(-50%, -50%) scale(0.96);
  }
  .hiw__spot-vid-wrap.lit {
    transform: translate(-50%, -50%) scale(1);
  }
  .hiw__spot-dots {
    display: flex;
  }

  /* ── STEP 3: Deliver & Optimize — 2 stacked line-item cards, gray fill ── */
  /* 3 stat cards: wrap to 2 columns and tighten so labels don't clip */
  .hiw__dlv-stats {
    flex-wrap: wrap;
    padding: 10px 12px 8px;
    gap: 6px;
  }
  .hiw__dlv-stat {
    flex: 1 1 40%;
    padding: 8px 9px;
  }
  .hiw__dlv-stat-val {
    font-size: 14px;
  }
  .hiw__dlv-stat-lbl {
    font-size: 8.5px;
  }
  .hiw__card--deliver {
    height: 560px;
  }
  .hiw__dlv-budget-row {
    flex-wrap: wrap;
  }
  .hiw__dlv-budget-meta {
    white-space: normal;
    flex: 1 0 100%;
    margin-top: 2px;
    font-size: 9.5px;
  }
  .hiw__dlv-thead {
    display: none;
  }
  .hiw__dlv-row {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto auto auto;
    gap: 4px 8px;
    padding: 10px 12px;
    background: #f0f0f2;
  }
  .hiw__dlv-row-name {
    grid-column: 1 / -1;
  }
  .hiw__dlv-row > span:nth-child(2) { grid-column: 1; grid-row: 2; justify-self: start; }
  .hiw__dlv-row > span:nth-child(3) { grid-column: 2; grid-row: 2; justify-self: start; }
  .hiw__dlv-row > span:nth-child(4),
  .hiw__dlv-row > span:nth-child(5) {
    font-size: 11px;
    color: #666;
  }
  .hiw__dlv-row > span:nth-child(4) { grid-column: 1; grid-row: 3; }
  .hiw__dlv-row > span:nth-child(5) { grid-column: 2; grid-row: 3; }
  .hiw__dlv-row > span:nth-child(4)::before { content: "Gastado "; color: #999; font-weight: 600; font-size: 9px; }
  .hiw__dlv-row > span:nth-child(5)::before { content: "Entregado "; color: #999; font-weight: 600; font-size: 9px; }
  #dlvRow2, #dlvRow3, #dlvRow4 {
    display: none;
  }
  .hiw__dlv-more {
    display: block;
  }
}
