/* FieldTrade premium phone mockups + in-app UI */
:root {
  --ft-ma-teal: #0d9488;
  --ft-ma-teal-deep: #0a7c72;
  --ft-ma-teal-header: #0f766e;
  --ft-ma-orange: #e85d04;
  --ft-ma-orange-soft: #f97316;
  --ft-ma-bg: #e3e8ec;
  --ft-ma-ink: #1e293b;
  --ft-phone-status-h: 18px;
  --ft-phone-frame: #1c1c1e;
  --ft-phone-radius: 32px;
  --ft-phone-width-showcase: min(196px, 46vw);
  --ft-phone-width-modal: min(220px, 68vw);
  --ft-phone-aspect-demo: 9 / 16.25;
  --ft-phone-width-flow: 162px;
}

/* ── Device chrome (slim Pro-style frame) ── */
.ft-phone-device {
  position: relative;
  margin: 0;
  padding: 6px 5px;
  background: linear-gradient(165deg, #3a3a3c 0%, var(--ft-phone-frame) 55%, #0a0a0b 100%);
  border-radius: var(--ft-phone-radius);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.06) inset,
    0 0 0 1px rgba(0, 0, 0, 0.55),
    0 18px 40px rgba(15, 23, 42, 0.22);
  flex-shrink: 0;
}

.ft-phone-device--sm { width: 182px; --ft-phone-radius: 28px; }
.ft-phone-device--md { width: 218px; }
.ft-phone-device--lg { width: 268px; --ft-phone-radius: 34px; }
.ft-phone-device--hero { width: 196px; }
.ft-phone-device--flow {
  width: var(--ft-phone-width-flow);
  --ft-phone-radius: 26px;
  padding: 5px 4px;
}

.ft-phone-device--demo {
  width: var(--ft-phone-width-modal);
  --ft-phone-radius: 34px;
  padding: 7px 6px;
  margin-inline: auto;
}

.ft-hero-showcase .ft-phone-device--demo,
.ft-phone-device--auth.ft-phone-device--demo {
  width: var(--ft-phone-width-showcase);
  --ft-phone-radius: 28px;
  --ft-phone-status-h: 16px;
  padding: 5px 4px;
}

/* Landing, login, register, Watch Demo — shorter frame (less vertical stretch) */
.ft-phone-device--demo .ft-phone-display {
  aspect-ratio: var(--ft-phone-aspect-demo);
  max-height: min(360px, 52vh);
}

.ft-phone-shell {
  position: relative;
  width: 100%;
  border-radius: calc(var(--ft-phone-radius) - 5px);
  overflow: hidden;
}

.ft-phone-display {
  display: flex;
  flex-direction: column;
  width: 100%;
  border-radius: calc(var(--ft-phone-radius) - 6px);
  overflow: hidden;
  background: #000;
  aspect-ratio: 9 / 19.5;
  position: relative;
  box-sizing: border-box;
}

.ft-phone-screen {
  flex: 1;
  min-height: 0;
  position: relative;
  overflow: hidden;
  background: var(--ft-ma-bg);
}

.ft-phone-home-bar {
  position: absolute;
  left: 50%;
  bottom: 5px;
  transform: translateX(-50%);
  width: 28%;
  height: 3px;
  margin: 0;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.42);
  z-index: 6;
  pointer-events: none;
}

.ft-phone-status {
  flex-shrink: 0;
  height: var(--ft-phone-status-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 10px 0 9px;
  background: #f1f5f9;
  color: #334155;
  font-size: 7px;
  font-weight: 600;
  z-index: 3;
  border-bottom: 1px solid #e2e8f0;
}

.ft-phone-status-time { letter-spacing: 0.02em; }

.ft-phone-status-notch { display: none; }

.ft-phone-status-icons {
  display: flex;
  gap: 4px;
  font-size: 6.5px;
  color: #475569;
}

.ft-phone-shine {
  pointer-events: none;
  position: absolute;
  inset: 0;
  width: 100%;
  background: linear-gradient(125deg, rgba(255, 255, 255, 0.1) 0%, transparent 42%);
  z-index: 5;
}

.ft-phone-device--demo .ft-ma-app { font-size: 6.85px; }

.ft-hero-showcase .ft-phone-device--demo .ft-ma-app,
.ft-phone-device--auth.ft-phone-device--demo .ft-ma-app,
.ft-phone-device--flow .ft-ma-app {
  font-size: 6.65px;
}

.ft-phone-device--demo .ft-phone-status {
  font-size: 6.5px;
  padding: 0 8px 0 7px;
}

.ft-phone-display--carousel {
  isolation: isolate;
}

.ft-phone-display--carousel .ft-ma-slide {
  position: absolute;
  inset: 0;
  width: 100%;
  overflow: hidden;
  opacity: 0;
  transition: opacity 0.5s ease;
  pointer-events: none;
  box-sizing: border-box;
}

.ft-phone-display--carousel .ft-ma-slide.is-active {
  opacity: 1;
  pointer-events: auto;
  z-index: 1;
}

.ft-phone-screen .ft-ma-app,
.ft-phone-display:not(.ft-phone-display--carousel) > .ft-ma-app {
  width: 100%;
  height: 100%;
  min-height: 0;
  box-sizing: border-box;
  padding-bottom: 10px;
}

.ft-demo-scanline { display: none; }

/* ── App shell ── */
.ft-ma-app {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  font-family: 'Inter', 'Segoe UI', system-ui, sans-serif;
  font-size: 8.8px;
  line-height: 1.4;
  color: #fff;
  background: var(--ft-ma-bg);
}

.ft-ma-bar {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  padding: 7px 9px 8px;
  background: linear-gradient(180deg, var(--ft-ma-teal) 0%, var(--ft-ma-teal-header) 100%);
  color: #fff;
  min-height: 32px;
  flex-shrink: 0;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.06);
}

.ft-ma-bar-text strong {
  display: block;
  font-size: 8px;
  font-weight: 600;
  line-height: 1.3;
}

.ft-ma-bar-text span {
  font-size: 7px;
  opacity: 0.92;
  margin-top: 1px;
  display: block;
}

.ft-ma-bar--light {
  background: #fff;
  color: var(--ft-ma-ink);
  box-shadow: 0 1px 0 #e2e8f0;
}

.ft-ma-bar--light .ft-ma-menu {
  color: #334155;
}

.ft-ma-bar--light .ft-ma-bar-text strong {
  color: #0f172a;
  font-size: 7.2px;
}

.ft-ma-bar-kicker {
  font-size: 7.8px !important;
  font-weight: 700 !important;
  opacity: 1 !important;
  color: #0f172a !important;
}

.ft-ma-bar-sub {
  font-size: 6.5px !important;
  opacity: 0.85 !important;
  color: #475569 !important;
  line-height: 1.35;
}

.ft-ma-back,
.ft-ma-menu {
  font-size: 9px;
  margin-top: 2px;
  opacity: 0.95;
  flex-shrink: 0;
}

.ft-ma-body {
  flex: 1;
  min-height: 0;
  overflow: hidden;
}

/* Survey — white sheet + teal card (matches real app) */
.ft-ma-body--survey {
  flex: 1;
  min-height: 0;
  padding: 5px 6px 6px;
  background: #cfd6dd;
}

.ft-ma-sheet {
  height: 100%;
  min-height: 0;
  background: #fff;
  border-radius: 6px;
  padding: 5px;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.08);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
}

/* Teal card hugs content — no stretch to bottom of phone */
.ft-ma-survey-card {
  flex: 0 0 auto;
  width: 100%;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, var(--ft-ma-teal) 0%, var(--ft-ma-teal-header) 100%);
  border-radius: 5px;
  padding: 10px 9px 9px;
}

.ft-ma-survey-spacer {
  display: none;
}

.ft-ma-survey-foot {
  margin-top: 10px;
  flex-shrink: 0;
}

.ft-ma-survey-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 7px;
}

.ft-ma-survey-title h3 {
  margin: 0;
  font-size: 10.5px;
  font-weight: 700;
}

.ft-ma-info {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--ft-ma-orange);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 7px;
}

.ft-ma-survey-q {
  margin: 0 0 2px;
  font-size: 7.5px;
  line-height: 1.5;
}

.ft-ma-survey-input {
  display: flex;
  gap: 5px;
  margin-bottom: 7px;
  align-items: stretch;
}

.ft-ma-survey-input input {
  flex: 1;
  border: 0;
  border-radius: 4px;
  padding: 6px 8px;
  font-size: 9.5px;
  font-weight: 600;
  color: var(--ft-ma-ink);
  min-width: 0;
  background: #fff;
}

.ft-ma-survey-input button {
  border: 0;
  border-radius: 4px;
  background: var(--ft-ma-orange);
  color: #fff;
  font-size: 7.5px;
  font-weight: 700;
  padding: 6px 10px;
  cursor: default;
  white-space: nowrap;
}

.ft-ma-survey-tools {
  display: flex;
  justify-content: space-around;
  padding-top: 8px;
  border-top: 1px solid rgba(255, 255, 255, 0.24);
  font-size: 11px;
}

/* Distance / outlet start */
.ft-ma-app--distance {
  background: #f3f5f7;
  color: var(--ft-ma-ink);
}

.ft-ma-distance-body {
  flex: 1;
  min-height: 0;
  padding: 12px 10px 14px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 8px;
  text-align: center;
}

.ft-ma-distance-label {
  margin: 0 0 4px;
  font-size: 8.5px;
  font-weight: 700;
  color: #0f172a;
}

.ft-ma-distance-intro h3 {
  margin: 0 0 3px;
  font-size: 9px;
  font-weight: 700;
  color: #0f172a;
}

.ft-ma-distance-company {
  font-size: 6.8px;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.ft-ma-distance-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 4px 0;
  padding: 10px 8px;
  border: 2px solid var(--ft-ma-teal);
  border-radius: 4px;
  background: #fff;
  font-size: 8.5px;
  font-weight: 700;
  color: #0f172a;
}

.ft-ma-distance-badge i {
  color: var(--ft-ma-teal-header);
  font-size: 10px;
}

.ft-ma-distance-ok {
  margin: 0;
  font-size: 6.8px;
  font-weight: 600;
  color: var(--ft-ma-teal-deep);
  line-height: 1.4;
}

.ft-ma-distance-ok i {
  color: var(--ft-ma-teal);
  margin-right: 3px;
}

.ft-ma-distance-actions {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: auto;
}

.ft-ma-distance-start {
  border: 1px solid #cbd5e1;
  border-radius: 4px;
  background: #fff;
  color: #0f172a;
  font-size: 8px;
  font-weight: 700;
  padding: 8px 10px;
  cursor: default;
  font-family: inherit;
}

.ft-ma-distance-update {
  border: 0;
  border-radius: 4px;
  background: var(--ft-ma-teal-header);
  color: #fff;
  font-size: 7.5px;
  font-weight: 600;
  padding: 8px 10px;
  cursor: default;
  font-family: inherit;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.ft-phone-device--demo .ft-ma-distance-body {
  padding: 10px 8px 12px;
  gap: 6px;
}

.ft-phone-device--demo .ft-ma-distance-badge {
  padding: 8px 6px;
  font-size: 7.8px;
}

/* Completed */
.ft-ma-tabs {
  display: flex;
  background: #fff;
  color: var(--ft-ma-ink);
  font-size: 6.8px;
  font-weight: 600;
  flex-shrink: 0;
}

.ft-ma-tabs span {
  flex: 1;
  text-align: center;
  padding: 7px 2px;
  border-bottom: 2px solid transparent;
}

.ft-ma-tabs span.is-active {
  color: var(--ft-ma-teal-deep);
  border-bottom-color: var(--ft-ma-orange);
}

.ft-ma-subhead {
  background: #fff;
  color: var(--ft-ma-ink);
  padding: 6px 10px;
  font-size: 6.8px;
  border-bottom: 1px solid #e2e8f0;
  flex-shrink: 0;
}

.ft-ma-subhead strong {
  display: block;
  font-size: 7.5px;
  margin-bottom: 2px;
}

.ft-ma-body--completed {
  padding: 8px;
  background: var(--ft-ma-bg);
}

.ft-ma-outlet-card {
  background: linear-gradient(180deg, var(--ft-ma-teal) 0%, var(--ft-ma-teal-header) 100%);
  border-radius: 6px;
  padding: 10px;
  box-shadow: 0 2px 10px rgba(13, 148, 136, 0.3);
}

.ft-ma-outlet-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 5px;
}

.ft-ma-outlet-top h3 {
  margin: 0;
  font-size: 10.5px;
  font-weight: 700;
}

.ft-ma-check {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--ft-ma-orange);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 9px;
}

.ft-ma-outlet-stats {
  margin: 0 0 3px;
  font-size: 6.8px;
}

.ft-ma-outlet-meta {
  margin: 7px 0 0;
  padding: 7px 0 0;
  list-style: none;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  font-size: 6.2px;
  line-height: 1.5;
  opacity: 0.92;
}

/* Analytics section (mobile app Activity / programs list) */
.ft-ma-app--analytics {
  background: #f3f5f7;
  color: var(--ft-ma-ink);
}

.ft-ma-body--analytics {
  padding: 6px 7px 8px;
  flex: 1;
  min-height: 0;
}

.ft-ma-analytics-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.ft-ma-analytics-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  padding: 8px 9px;
  border-radius: 4px;
  background: rgba(15, 23, 42, 0.08);
  font-size: 7px;
  font-weight: 600;
  color: #0f172a;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.6) inset;
}

.ft-ma-analytics-list li.is-active {
  background: #fff;
  border: 1px solid #cbd5e1;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.08);
}

.ft-ma-analytics-list li.is-done {
  background: #fff;
  color: #334155;
}

.ft-ma-analytics-list li i {
  font-size: 9px;
  color: #64748b;
  flex-shrink: 0;
}

.ft-ma-analytics-list li.is-active i {
  color: var(--ft-ma-teal-header);
}

.ft-ma-analytics-list li.is-done i {
  color: var(--ft-ma-orange-soft);
}

/* Activity */
.ft-ma-body--activity {
  padding: 8px;
  background: var(--ft-ma-bg);
  flex: 1;
  min-height: 0;
}

.ft-ma-activity-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  height: 100%;
}

.ft-ma-activity-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  background: var(--ft-ma-teal-header);
  border-radius: 4px;
  padding: 8px 9px;
  font-size: 6.8px;
  font-weight: 500;
  box-shadow: 0 1px 4px rgba(13, 148, 136, 0.25);
}

.ft-ma-activity-list i {
  color: var(--ft-ma-orange-soft);
  font-size: 10px;
  flex-shrink: 0;
}

/* Hero trio */
.ft-hero-phones {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  gap: 16px;
  position: relative;
  z-index: 1;
  padding: 16px 0 12px;
}

.ft-hero-phones--four {
  gap: 10px;
  flex-wrap: wrap;
  max-width: 100%;
}

.ft-hero-phones--four .ft-phone-device--hero {
  width: min(172px, 22vw);
}

.ft-hero-phones .ft-phone-device--hero:nth-child(2) {
  transform: translateY(-12px) scale(1.04);
  z-index: 2;
}

.ft-hero-phones .ft-phone-device--hero:nth-child(3) {
  transform: translateY(-6px);
  z-index: 1;
}

.ft-hero-phones .ft-phone-device--hero:nth-child(1) {
  transform: rotate(-4deg) translateY(4px);
}

.ft-hero-phones .ft-phone-device--hero:nth-child(4) {
  transform: rotate(4deg) translateY(4px);
}

.ft-mobile-phones-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 18px 20px;
  margin: 24px 0 10px;
}

.ft-mobile-phones-row .ft-phone-device--md {
  width: min(200px, 42vw);
}

.ft-mobile-apart {
  margin-top: 32px;
  padding: 24px;
  background: var(--ft-white, #fff);
  border: 1px solid var(--ft-border, #dde3ea);
  border-radius: 8px;
}

.ft-mobile-apart h3 {
  margin: 0 0 16px;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--ft-ink, #12181c);
}

.ft-mobile-apart ul {
  margin: 0;
  padding-left: 1.1rem;
  color: var(--ft-muted, #64748b);
  font-size: 0.92rem;
  line-height: 1.65;
}

.ft-mobile-apart li { margin-bottom: 10px; }
.ft-mobile-apart li strong { color: var(--ft-ink, #12181c); }

/* Demo modal stage */
.ft-demo-video-wrap {
  padding: 18px 18px 12px;
  background: linear-gradient(165deg, #0f766e 0%, #0d9488 45%, #2dd4bf 100%);
  position: relative;
  overflow: visible;
}

.ft-demo-video-wrap .ft-phone-device {
  filter: drop-shadow(0 16px 32px rgba(0, 0, 0, 0.28));
}

.ft-demo-progress {
  height: 4px;
  background: rgba(255, 255, 255, 0.28);
  margin-top: 18px;
  border-radius: 999px;
  overflow: hidden;
}

.ft-demo-progress span {
  display: block;
  height: 100%;
  width: 0%;
  background: #fff;
  border-radius: inherit;
  transition: width 0.1s linear;
}

.ft-demo-caption {
  padding: 18px 22px 8px;
  background: #fff;
}

.ft-demo-caption h3 {
  margin: 0 0 6px;
  font-size: 1.05rem;
  color: var(--ft-teal-dark, #0f766e);
}

.ft-demo-caption p {
  margin: 0;
  font-size: 0.88rem;
  color: var(--ft-muted, #64748b);
  line-height: 1.55;
}

.ft-demo-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 0 20px 16px;
  background: #fff;
}

.ft-demo-controls button {
  border: 1px solid var(--ft-border, #dde3ea);
  background: #fff;
  border-radius: 999px;
  width: 44px;
  height: 44px;
  cursor: pointer;
  color: var(--ft-teal-dark, #0f766e);
}

.ft-demo-dots--video {
  justify-content: center;
  padding-bottom: 18px;
  background: #fff;
}

.ft-demo-dots--video span.is-active {
  background: var(--ft-teal-dark, #0f766e);
}

@media (max-width: 900px) {
  .ft-hero-phones { flex-wrap: wrap; gap: 18px; }

  .ft-hero-phones .ft-phone-device--hero {
    transform: none !important;
    width: min(172px, 44vw);
  }

  .ft-hero-phones .ft-phone-device--hero:nth-child(2) {
    transform: none !important;
  }

  .ft-mobile-phones-row .ft-phone-device--md {
    width: min(172px, 44vw);
  }

  .ft-phone-btn { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .ft-phone-display--carousel .ft-ma-slide {
    transition: opacity 0.2s ease;
    transform: none;
  }
}
