/* FleetPager marketing page — iOS-faithful mock + feature sections */

body.app-product {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}

/* ── Hero ── */
.app-hero {
  flex: 0 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(500px, 1.35fr);
  grid-template-rows: auto;
  gap: 2.5rem;
  align-items: center;
  padding: 2.5rem 0 3rem;
  max-width: 1200px;
  margin: 0 auto;
  width: min(100% - 2rem, 1200px);
}

/* Safari: grid + flex:1 can stretch hero phones tall — keep column content-sized */
.app-hero > .phone-wrap {
  align-self: center;
  justify-self: center;
  height: auto;
  min-height: 0;
}

.app-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--emerald);
  letter-spacing: 0.02em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.app-badge img {
  width: 28px;
  height: 28px;
  border-radius: 7px;
}

.app-hero h1 {
  font-size: clamp(2rem, 4.5vw, 3rem);
  line-height: 1.08;
  letter-spacing: -0.04em;
  margin: 0 0 0.85rem;
}

.app-hero .sub {
  color: var(--muted);
  font-size: 1.1rem;
  max-width: 30rem;
  margin: 0 0 1.5rem;
  line-height: 1.55;
}

.store-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.store-row .btn-lg { min-width: 11rem; }

.app-bullets {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.55rem;
}

.app-bullets li {
  display: flex;
  gap: 0.55rem;
  align-items: flex-start;
  color: var(--muted);
  font-size: 0.95rem;
}

.app-bullets code {
  font-family: var(--mono);
  font-size: 0.88em;
  background: rgba(255, 255, 255, 0.06);
  padding: 0.1em 0.3em;
  border-radius: 4px;
}

.app-bullets li::before {
  content: "";
  width: 8px;
  height: 8px;
  margin-top: 0.45rem;
  border-radius: 50%;
  background: var(--emerald);
  flex-shrink: 0;
}

.price-line {
  margin-top: 1.25rem;
  font-size: 0.9rem;
  color: var(--dim);
}

.price-line strong { color: var(--text); }

/* ── iPhone frame + iOS Messages mock ── */
.phone-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  perspective: 1200px;
  min-width: 0;
  min-height: 0;
  overflow: visible;
  flex-shrink: 0;
}

.phones-duo {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  gap: 2.25rem;
  align-items: flex-start;
  justify-content: center;
  width: 100%;
  padding: 0 0.5rem;
  min-height: 0;
}

.phone-unit {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  flex: 0 0 auto;
  align-self: flex-start;
  min-height: 0;
}

.phone-unit-label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--emerald);
}

.phone-frame {
  width: min(100%, 272px);
  background: linear-gradient(145deg, #1a1a1e, #0d0d0f);
  border: 1px solid #2a2a30;
  border-radius: 44px;
  padding: 10px;
  box-shadow:
    0 50px 100px rgba(0, 0, 0, 0.55),
    0 0 0 1px rgba(52, 211, 153, 0.06),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
  overflow: hidden;
  line-height: 0;
  flex-shrink: 0;
  height: auto;
  max-height: none;
}

/* Duo hero: fixed-width shells — no inline-block (Safari flex stretch bug) */
.phones-duo .phone-unit .phone-frame {
  width: 242px;
  max-width: 242px;
  flex-shrink: 0;
  display: block;
  box-sizing: border-box;
}

.phones-duo .phone-unit--inbox .phone-frame {
  transform: rotateY(-3deg) rotateX(1deg);
}

.phones-duo .phone-unit--chat .phone-frame {
  transform: rotateY(3deg) rotateX(1deg);
}

/*
 * iPhone 390×844 aspect box.
 * padding-bottom hack — Safari ignores aspect-ratio in some flex/grid ancestors.
 */
.phone-screen {
  position: relative;
  width: 100%;
  height: 0;
  padding-bottom: 216.410256%; /* 844 / 390 */
  overflow: hidden;
  border-radius: 34px;
  background: #000;
}

.phone-screen > .phone-screenshot {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: top center;
  border-radius: 0;
  display: block;
}

.phones-duo .ios-screen,
.phones-duo .ios-screen--chat {
  min-height: 540px;
}

.phones-duo .ios-brand {
  padding: 4px 16px 10px;
}

.phones-duo .ios-brand-top .name {
  font-size: 26px;
}

.phones-duo .ios-search {
  margin: 10px 16px 14px;
  padding: 10px 14px;
}

.phones-duo .ios-thread {
  padding: 14px 16px;
  gap: 14px;
}

.phones-duo .ios-avatar {
  width: 48px;
  height: 48px;
}

.phones-duo .ios-thread-head .title {
  font-size: 16px;
}

.phones-duo .ios-thread-preview {
  margin-top: 5px;
}

.phones-duo .ios-thread-preview .text {
  -webkit-line-clamp: 1;
  font-size: 15px;
  line-height: 1.35;
}

.phones-duo .ios-threads-panel {
  flex: 1;
}

.phones-duo .ios-chat-msgs {
  padding: 20px 16px 28px;
  gap: 16px;
}

.phones-duo .ios-bubble {
  padding: 11px 15px;
  font-size: 16px;
  line-height: 1.45;
  max-width: 76%;
}

.phones-duo .ios-compose {
  padding: 10px 12px 18px;
}

.phones-duo .ios-compose-field {
  padding: 10px 16px;
  font-size: 16px;
}

.phone-dynamic-island {
  width: 96px;
  height: 28px;
  background: #000;
  border-radius: 20px;
  margin: 6px auto 8px;
}

.phone-screenshot {
  display: block;
  width: 100%;
  max-width: 100%;
  border-radius: 34px;
  background: #000;
  flex-shrink: 0;
  -webkit-user-drag: none;
}

.phones-duo .phone-frame {
  padding: 8px;
  background: #000;
}

/* Safari: drop 3D tilt — it skews the aspect box */
@supports (-webkit-touch-callout: none) {
  .phones-duo .phone-unit--inbox .phone-frame,
  .phones-duo .phone-unit--chat .phone-frame {
    transform: none;
  }
}

.ios-screen {
  /* iOS dark mode — matches FleetPager on iPhone */
  --ios-bg: #000000;
  --ios-label: #ffffff;
  --ios-secondary: #8e8e93;
  --ios-separator: rgba(84, 84, 88, 0.65);
  --ios-blue: #0a84ff;
  --ios-search-bg: #1c1c1e;
  --ios-bubble-recv: #3a3a3c;
  background: var(--ios-bg);
  border-radius: 34px;
  overflow: hidden;
  min-height: 580px;
  display: flex;
  flex-direction: column;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Helvetica Neue", sans-serif;
  color: var(--ios-label);
}

.ios-status {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 22px 2px;
  font-size: 14px;
  font-weight: 600;
}

.ios-status .icons {
  display: flex;
  gap: 5px;
  align-items: center;
  font-size: 12px;
}

.ios-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 4px 14px 8px;
  font-size: 17px;
}

.ios-nav button {
  background: none;
  border: none;
  color: var(--ios-blue);
  font-size: 20px;
  padding: 4px;
  line-height: 1;
}

.ios-brand {
  padding: 2px 16px 6px;
}

.ios-brand-top {
  display: flex;
  align-items: center;
  gap: 10px;
}

.ios-brand-top img {
  width: 28px;
  height: 28px;
  border-radius: 6px;
}

.ios-brand-top .name {
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.ios-brand .panel {
  margin-top: 2px;
  margin-left: 38px;
  font-size: 12px;
  font-weight: 500;
  color: var(--ios-secondary);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.ios-search {
  margin: 6px 16px 10px;
  padding: 8px 12px;
  background: var(--ios-search-bg);
  border-radius: 10px;
  font-size: 17px;
  color: var(--ios-secondary);
}

.ios-threads {
  flex: 1;
  border-top: 0.5px solid var(--ios-separator);
}

.ios-thread {
  display: flex;
  gap: 14px;
  padding: 10px 16px;
  border-bottom: 0.5px solid var(--ios-separator);
  align-items: flex-start;
}

.ios-avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 17px;
  font-weight: 600;
  color: #fff;
}

.ios-avatar.g1 { background: linear-gradient(135deg, #5a8cf2, #40c0f2); }
.ios-avatar.g2 { background: linear-gradient(135deg, #8c5ae6, #d966bf); }
.ios-avatar.g3 { background: linear-gradient(135deg, #f27359, #f2a640); }
.ios-avatar.g4 { background: linear-gradient(135deg, #4dbf8c, #33d9b2); }

.ios-thread-body { flex: 1; min-width: 0; }

.ios-thread-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
}

.ios-thread-head .title {
  font-size: 17px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ios-thread-head .time {
  font-size: 15px;
  color: var(--ios-secondary);
  flex-shrink: 0;
}

.ios-thread-preview {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 3px;
}

.ios-thread-preview .text {
  font-size: 15px;
  color: var(--ios-label);
  font-weight: 500;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.ios-thread-preview .text.muted { color: var(--ios-secondary); font-weight: 400; }

.ios-unread {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--ios-blue);
  flex-shrink: 0;
}

.ios-tabbar {
  display: flex;
  justify-content: center;
  padding: 10px 0 18px;
  border-top: 0.5px solid var(--ios-separator);
}

.ios-tabbar span {
  width: 134px;
  height: 5px;
  background: #fff;
  border-radius: 100px;
  opacity: 0.28;
}

.ios-threads-panel {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.ios-screen--chat {
  min-height: 580px;
}

.ios-screen--chat .ios-chat {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: var(--ios-bg);
}

.ios-chat-header {
  text-align: center;
  padding: 6px 12px 10px;
  border-bottom: 0.5px solid var(--ios-separator);
  font-size: 13px;
  font-weight: 600;
}

.ios-chat-header .back {
  float: left;
  color: var(--ios-blue);
  font-size: 22px;
  line-height: 1;
}

.ios-chat-msgs {
  flex: 1;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  overflow: hidden;
}

.ios-bubble {
  max-width: 82%;
  padding: 8px 12px;
  border-radius: 18px;
  font-size: 15px;
  line-height: 1.35;
}

.ios-bubble.recv {
  align-self: flex-start;
  background: var(--ios-bubble-recv);
  color: var(--ios-label);
  border-bottom-left-radius: 4px;
}

.ios-bubble.sent {
  align-self: flex-end;
  background: var(--ios-blue);
  color: #fff;
  border-bottom-right-radius: 4px;
}

.ios-bubble .who {
  display: block;
  font-size: 11px;
  font-weight: 600;
  opacity: 0.65;
  margin-bottom: 2px;
}

.ios-compose {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  padding: 8px 10px 14px;
  border-top: 0.5px solid var(--ios-separator);
}

.ios-compose-field {
  flex: 1;
  background: var(--ios-search-bg);
  border-radius: 20px;
  padding: 8px 14px;
  font-size: 15px;
  color: var(--ios-secondary);
}

/* ── Feature sections ── */
.mkt-section {
  border-top: 1px solid var(--border-soft);
  padding: 3.5rem 0;
}

.mkt-section .inner {
  width: min(100% - 2rem, 1080px);
  margin: 0 auto;
}

.mkt-section h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  letter-spacing: -0.03em;
  margin: 0 0 0.5rem;
  text-align: center;
}

.mkt-section .lead-center {
  text-align: center;
  color: var(--muted);
  max-width: 36rem;
  margin: 0 auto 2.5rem;
  font-size: 1.05rem;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

.feature-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1.25rem 1.2rem;
  transition: border-color 0.2s, transform 0.2s;
}

.feature-card:hover {
  border-color: rgba(52, 211, 153, 0.35);
  transform: translateY(-2px);
}

.feature-card .icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  margin-bottom: 0.85rem;
  background: rgba(52, 211, 153, 0.1);
  border: 1px solid rgba(52, 211, 153, 0.2);
}

.feature-card h3 {
  margin: 0 0 0.4rem;
  font-size: 0.98rem;
  letter-spacing: -0.02em;
}

.feature-card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.5;
}

.feature-card code,
.step-card code,
.security-band code {
  font-family: var(--mono);
  font-size: 0.82em;
  background: rgba(255, 255, 255, 0.06);
  padding: 0.1em 0.35em;
  border-radius: 4px;
}

.feature-card .tag {
  display: inline-block;
  margin-top: 0.65rem;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--emerald);
  background: rgba(52, 211, 153, 0.1);
  padding: 0.2rem 0.45rem;
  border-radius: 4px;
}

/* ── How it works ── */
.steps-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
  counter-reset: step;
}

.step-card {
  position: relative;
  padding: 1.5rem 1.25rem 1.25rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
}

.step-card::before {
  counter-increment: step;
  content: counter(step);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--emerald);
  color: #042f1a;
  font-size: 0.82rem;
  font-weight: 800;
  margin-bottom: 0.85rem;
}

.step-card h3 {
  margin: 0 0 0.45rem;
  font-size: 1rem;
}

.step-card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.5;
}

.step-card a {
  color: var(--emerald);
  font-weight: 600;
  font-size: 0.85rem;
}

/* ── Security band ── */
.security-band {
  background: linear-gradient(180deg, rgba(52, 211, 153, 0.06), transparent);
  border: 1px solid rgba(52, 211, 153, 0.15);
  border-radius: 20px;
  padding: 2rem 2rem 1.75rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: center;
}

.security-band ul {
  list-style: none;
  padding: 0;
  margin: 1rem 0 0;
  display: grid;
  gap: 0.55rem;
}

.security-band li {
  color: var(--muted);
  font-size: 0.92rem;
  padding-left: 1.25rem;
  position: relative;
}

.security-band li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--emerald);
  font-weight: 700;
}

.security-band .cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-top: 1.25rem;
}

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

.security-visual .phone-frame--solo {
  width: min(100%, 260px);
}

.platforms-heading {
  margin-top: 2.5rem;
  font-size: clamp(1.25rem, 2.5vw, 1.6rem);
  text-align: center;
  letter-spacing: -0.03em;
}

/* ── Platforms strip ── */
.platform-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.platform-card {
  text-align: center;
  padding: 1.5rem 1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
}

.platform-card .emoji {
  font-size: 2rem;
  margin-bottom: 0.65rem;
}

.platform-card h3 {
  margin: 0 0 0.35rem;
  font-size: 1rem;
}

.platform-card p {
  margin: 0 0 1rem;
  color: var(--muted);
  font-size: 0.85rem;
}

/* ── Footer ── */
.mini-foot {
  border-top: 1px solid var(--border-soft);
  padding: 1rem 0 1.4rem;
  color: var(--dim);
  font-size: 0.8rem;
  margin-top: auto;
}

.mini-foot .row {
  width: min(100% - 2rem, 1080px);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  justify-content: space-between;
  align-items: center;
}

.mini-foot a { color: var(--muted); }
.mini-foot a:hover { color: var(--text); }

.nav-links-inline {
  display: flex;
  gap: 1.25rem;
  color: var(--muted);
  font-size: 0.88rem;
}

.nav-links-inline a:hover { color: var(--text); }

/* ── Screenshot gallery ── */
.shot-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

.shot-card {
  margin: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  transition: border-color 0.2s, transform 0.2s;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1rem 0.75rem 0;
}

.shot-card:hover {
  border-color: rgba(52, 211, 153, 0.35);
  transform: translateY(-2px);
}

.shot-card .phone-frame--gallery {
  width: 100%;
  max-width: 220px;
}

.shot-card figcaption {
  padding: 0.75rem 1rem;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--muted);
  text-align: center;
  width: 100%;
}

/* ── Region / language picker ── */
.locale-picker {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}

.locale-picker-label {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.locale-picker select {
  appearance: none;
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.4rem 1.75rem 0.4rem 0.65rem;
  font-size: 0.84rem;
  line-height: 1.2;
  cursor: pointer;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--muted) 50%),
    linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position:
    calc(100% - 14px) calc(50% - 2px),
    calc(100% - 9px) calc(50% - 2px);
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
}

.locale-picker select:hover,
.locale-picker select:focus {
  border-color: rgba(52, 211, 153, 0.45);
  outline: none;
}

.locale-picker--foot .locale-picker-label {
  display: none;
}

.nav-cta {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

@media (max-width: 960px) {
  .shot-grid { grid-template-columns: repeat(2, 1fr); }
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  .steps-row { grid-template-columns: repeat(2, 1fr); }
  .security-band { grid-template-columns: 1fr; }
}

@media (max-width: 820px) {
  .app-hero {
    grid-template-columns: 1fr;
    padding-top: 1.5rem;
    text-align: center;
  }

  .app-hero .sub { margin-inline: auto; }
  .store-row { justify-content: center; }
  .app-bullets { text-align: left; max-width: 22rem; margin-inline: auto; }
  .price-line { text-align: center; }
  .phones-duo .phone-unit .phone-frame {
    width: min(42vw, 242px);
    max-width: 242px;
    transform: none;
  }
  .feature-grid,
  .steps-row,
  .platform-strip,
  .shot-grid { grid-template-columns: 1fr; }
  .nav-links-inline { display: none; }
  .locale-picker--nav { display: none; }
}

@media (max-width: 520px) {
  .phones-duo {
    flex-direction: column;
    align-items: center;
  }

  .phones-duo .phone-frame {
    width: min(100%, 272px);
  }
}