/* ============================================
   Retailer App — Layout (PORTDA structure)
   Page header + sticky module nav + screens grid
   ============================================ */

:root {
  --primary: #BE8848;
  --primary-light: #F5ECE2;
  --primary-dark: #8A6234;
  --accent: #1A1410;
  --accent-light: #FFEDD5;
  --success: #16A34A;
  --success-light: #DCFCE7;
  --text: #1A1410;
  --text-2: #786458;
  --text-3: #A89580;
  --line: #E5D8C5;
  --line-soft: #F1E8DA;
  --bg: #FBF6EE;
  --card: #FFFCF5;
}

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

/* Invisible scrollbars — scrolling works, scrollbar UI hidden */
* {
  scrollbar-width: none;
  -ms-overflow-style: none;
}
*::-webkit-scrollbar {
  display: none;
  width: 0;
  height: 0;
}
body {
  font-family: 'Poppins', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* ============================================
   Page header
   ============================================ */
.page-header {
  max-width: 1400px;
  margin: 0 auto;
  padding: 32px 32px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}
.logo {
  display: flex;
  align-items: center;
  gap: 16px;
}
.logo-mark {
  width: 56px; height: 56px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: white;
  border-radius: 16px;
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 24px;
  letter-spacing: -0.5px;
  box-shadow: 0 8px 22px rgba(25, 86, 227, 0.28);
  position: relative;
}
.logo-mark::after {
  content: '';
  position: absolute;
  top: 8px; right: 8px;
  width: 10px; height: 10px;
  background: var(--success);
  border-radius: 50% 0;
  transform: rotate(45deg);
  box-shadow: 0 2px 4px rgba(22,163,74,0.30);
}
.page-header h1 {
  font-size: 22px;
  font-weight: 700;
  margin: 0;
  letter-spacing: -0.3px;
}
.page-header p {
  font-size: 13px;
  color: var(--text-2);
  margin: 2px 0 0;
}
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  background: white;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-family: 'Poppins', sans-serif;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  text-decoration: none;
  transition: all 0.15s ease;
}
.back-link:hover {
  background: var(--primary-light);
  color: var(--primary);
  border-color: rgba(25,86,227,0.20);
}

/* ============================================
   Module nav (sticky pill bar)
   ============================================ */
.module-nav-wrap {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(247, 249, 252, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--line);
}
.module-nav {
  max-width: 1400px;
  margin: 0 auto;
  padding: 14px 32px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.module-nav a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 16px;
  background: white;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-family: 'Poppins', sans-serif;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--text-2);
  text-decoration: none;
  transition: all 0.15s ease;
  white-space: nowrap;
}
.module-nav a:hover {
  background: var(--primary-light);
  color: var(--primary);
  border-color: rgba(25,86,227,0.20);
}
.module-nav a.active {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
  box-shadow: 0 4px 12px rgba(25,86,227,0.28);
  font-weight: 600;
}

/* ============================================
   Screens grid
   ============================================ */
.screens-grid {
  max-width: 1400px;
  margin: 0 auto;
  padding: 40px 32px 64px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
  gap: 36px 24px;
  justify-items: center;
}

.screen-wrap {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  width: 100%;
  max-width: 310px;
}
.screen-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 14px;
  padding: 0 4px;
}
.screen-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-2);
  letter-spacing: 0.2px;
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.dl-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--primary);
  color: white;
  border: none;
  padding: 6px 12px;
  border-radius: 999px;
  font-family: 'Poppins', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.4px;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(25, 86, 227, 0.28);
  transition: all 0.15s ease;
  flex-shrink: 0;
}
.dl-btn i { font-size: 11px; }
.dl-btn:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(25, 86, 227, 0.35);
}
.dl-btn:active { transform: translateY(0); }
.dl-btn:disabled {
  background: var(--text-3);
  cursor: wait;
  transform: none;
  box-shadow: none;
}
.phone-link {
  display: block;
  text-decoration: none;
  color: inherit;
}
.screen-label .num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: white;
  color: var(--primary);
  font-weight: 700;
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 6px;
  border: 1px solid var(--line);
}

/* Phone mockup */
.phone {
  width: 290px;
  height: 627px;
  border-radius: 36px;
  overflow: hidden;
  position: relative;
  background: #1a1a1a;
  box-shadow:
    0 0 0 8px #1a1a1a,
    0 0 0 9px #2a2a2a,
    0 30px 60px rgba(15,23,41,0.18);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.phone:hover {
  transform: translateY(-4px);
  box-shadow:
    0 0 0 8px #1a1a1a,
    0 0 0 9px #2a2a2a,
    0 36px 72px rgba(15,23,41,0.24);
}
.phone-inner {
  width: 390px;
  height: 844px;
  transform: scale(0.7435);
  transform-origin: top left;
}
.phone-inner iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;}

/* ============================================
   Landing — Premium hero + module showcase
   ============================================ */
.landing-bg {
  background:
    radial-gradient(ellipse 800px 600px at 20% 0%, rgba(25,86,227,0.12), transparent),
    radial-gradient(ellipse 600px 400px at 100% 30%, rgba(124,58,237,0.08), transparent),
    linear-gradient(180deg, #FFFFFF 0%, #F7F9FC 100%);
  position: relative;
  overflow: hidden;
}
.landing-bg::before {
  content: '';
  position: absolute;
  top: -100px; right: -150px;
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(22,163,74,0.10), transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

/* Hero */
.hero-wrap {
  max-width: 1400px;
  margin: 0 auto;
  padding: 40px 32px 60px;
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 60px;
  align-items: center;
  min-height: 580px;
}

.hero-left .hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: white;
  border: 1px solid var(--line);
  padding: 8px 16px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 24px;
  box-shadow: 0 4px 12px rgba(25,86,227,0.06);
}
.hero-badge .pulse {
  width: 8px; height: 8px;
  background: var(--success);
  border-radius: 50%;
  box-shadow: 0 0 0 4px rgba(22,163,74,0.15);
}

.hero-left h1 {
  font-size: 64px;
  font-weight: 800;
  letter-spacing: -2.2px;
  line-height: 0.98;
  margin: 0 0 20px;
}
.hero-left h1 .accent {
  background: linear-gradient(135deg, var(--primary), #4079FF, #7C3AED);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  display: block;
}
.hero-left h1 .small-line {
  display: block;
  font-size: 22px;
  font-weight: 500;
  color: var(--text-2);
  letter-spacing: -0.3px;
  margin-top: 12px;
  line-height: 1.3;
}
.hero-left .lead {
  font-size: 16px;
  color: var(--text-2);
  line-height: 1.65;
  max-width: 480px;
  margin: 0 0 28px;
}
.hero-ctas {
  display: flex;
  gap: 12px;
  margin-bottom: 32px;
  flex-wrap: wrap;
}
.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 24px;
  border-radius: 14px;
  font-family: 'Poppins', sans-serif;
  font-weight: 700;
  font-size: 14px;
  text-decoration: none;
  transition: all 0.2s ease;
  cursor: pointer;
  border: none;
}
.hero-cta.primary {
  background: var(--primary);
  color: white;
  box-shadow: 0 12px 28px rgba(25,86,227,0.28);
}
.hero-cta.primary:hover { background: var(--primary-dark); transform: translateY(-2px); box-shadow: 0 16px 32px rgba(25,86,227,0.32); }
.hero-cta.ghost {
  background: white;
  color: var(--text);
  border: 1px solid var(--line);
}
.hero-cta.ghost:hover { border-color: var(--primary); color: var(--primary); }

.hero-stats-row {
  display: flex;
  gap: 32px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}
.hero-stats-row .stat-num {
  font-size: 32px;
  font-weight: 800;
  letter-spacing: -1px;
  background: linear-gradient(135deg, var(--primary), #4079FF);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
}
.hero-stats-row .stat-lbl {
  font-size: 12px;
  color: var(--text-2);
  margin-top: 6px;
}

/* Hero right - floating phone mockups */
.hero-right {
  position: relative;
  height: 580px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.hero-blob {
  position: absolute;
  inset: 10% 8%;
  background: radial-gradient(circle, rgba(25,86,227,0.18), transparent 70%);
  border-radius: 50%;
  filter: blur(20px);
}
.hero-phone {
  position: absolute;
  width: 240px;
  height: 520px;
  border-radius: 32px;
  overflow: hidden;
  background: #1a1a1a;
  box-shadow:
    0 0 0 7px #1a1a1a,
    0 0 0 8px #2a2a2a,
    0 40px 80px rgba(15,23,41,0.20);
  transition: transform 0.4s ease;
}
.hero-phone-inner {
  width: 390px;
  height: 844px;
  transform: scale(0.6155);
  transform-origin: top left;
}
.hero-phone-inner iframe {
  width: 100%; height: 100%;
  border: 0;
  pointer-events: none;
}

.hero-phone.p1 {
  z-index: 3;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}
.hero-phone.p2 {
  z-index: 2;
  top: 50%;
  left: 22%;
  transform: translate(-50%, -50%) rotate(-8deg) scale(0.88);
  opacity: 0.92;
}
.hero-phone.p3 {
  z-index: 2;
  top: 50%;
  right: 8%;
  transform: translate(0, -50%) rotate(8deg) scale(0.88);
  opacity: 0.92;
}

/* Feature strip */
.feature-strip {
  max-width: 1400px;
  margin: 0 auto;
  padding: 40px 32px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  border-top: 1px solid var(--line);
  position: relative;
  z-index: 2;
}
.feature {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}
.feature-icon {
  width: 44px; height: 44px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 18px;
  flex-shrink: 0;
}
.feature h4 {
  font-size: 14px;
  font-weight: 700;
  margin: 0 0 4px;
  letter-spacing: -0.2px;
}
.feature p {
  font-size: 12px;
  color: var(--text-2);
  margin: 0;
  line-height: 1.5;
}

/* Section title */
.section-block-head {
  max-width: 1400px;
  margin: 0 auto;
  padding: 64px 32px 24px;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  flex-wrap: wrap;
}
.section-block-head .left {
  flex: 1;
  min-width: 280px;
}
.section-block-head .eyebrow {
  font-size: 12px;
  font-weight: 700;
  color: var(--primary);
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 8px;
}
.section-block-head h2 {
  font-size: 36px;
  font-weight: 800;
  margin: 0 0 8px;
  letter-spacing: -1px;
  line-height: 1.1;
}
.section-block-head p {
  font-size: 15px;
  color: var(--text-2);
  margin: 0;
  max-width: 540px;
  line-height: 1.6;
}

/* Module cards — bento grid with real screen previews */
.modules-grid {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 32px 80px;
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 20px;
}

/* Bento sizing */
.module-card { grid-column: span 3; }
.module-card.feature { grid-column: span 6; }
.module-card.wide { grid-column: span 6; }

@media (max-width: 1100px) {
  .module-card { grid-column: span 4; }
  .module-card.feature, .module-card.wide { grid-column: span 6; }
}
@media (max-width: 760px) {
  .module-card,
  .module-card.feature,
  .module-card.wide { grid-column: span 12; }
}

.module-card {
  background: white;
  border: 1px solid var(--line);
  border-radius: 22px;
  text-decoration: none;
  color: inherit;
  transition: all 0.3s ease;
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 280px;
}
.module-card:hover {
  border-color: transparent;
  transform: translateY(-6px);
  box-shadow: 0 24px 48px rgba(15,23,41,0.10);
}

/* Top label band — gradient color per module */
.mc-band {
  height: 6px;
  background: var(--gradient, linear-gradient(135deg, var(--primary), #4079FF));
}

/* Header inside card */
.mc-head {
  padding: 18px 22px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.mc-num {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1px;
  color: var(--text-2);
}
.mc-num .dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--gradient, var(--primary));
}
.mc-count {
  background: var(--bg);
  color: var(--text);
  font-size: 11px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid var(--line);
}

/* Body */
.mc-body {
  padding: 12px 22px 18px;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.mc-body h3 {
  font-size: 22px;
  font-weight: 800;
  margin: 0 0 6px;
  letter-spacing: -0.5px;
  line-height: 1.15;
}
.mc-body p {
  font-size: 13px;
  color: var(--text-2);
  margin: 0;
  line-height: 1.55;
}

/* Feature card body — bigger */
.module-card.feature .mc-body h3 { font-size: 30px; letter-spacing: -0.8px; }
.module-card.feature .mc-body p { font-size: 14px; max-width: 90%; }
.module-card.feature .mc-head { padding-top: 22px; }
.module-card.feature { min-height: 360px; }

/* Phone preview area */
.mc-preview {
  flex: 1;
  position: relative;
  margin-top: 16px;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  background: linear-gradient(180deg, transparent, rgba(0,0,0,0.02));
}
.mc-mini {
  width: 150px;
  height: 240px;
  border-radius: 22px;
  overflow: hidden;
  background: #1a1a1a;
  box-shadow:
    0 0 0 5px #1a1a1a,
    0 0 0 6px #2a2a2a,
    0 20px 40px rgba(15,23,41,0.18);
  transition: transform 0.35s ease;
  margin-bottom: -120px;
}
.mc-mini-inner {
  width: 390px;
  height: 844px;
  transform: scale(0.3589);
  transform-origin: top left;
}
.mc-mini-inner iframe {
  width: 100%; height: 100%;
  border: 0;
  pointer-events: none;
}
.module-card:hover .mc-mini { transform: translateY(-12px); }

/* Feature card preview — show 3 phones */
.module-card.feature .mc-preview {
  margin-top: 18px;
  height: 220px;
  align-items: flex-end;
  gap: 16px;
}
.module-card.feature .mc-mini {
  width: 160px; height: 260px;
  margin-bottom: -100px;
}
.module-card.feature .mc-mini-inner { transform: scale(0.4103); }
.module-card.feature .mc-mini.side {
  opacity: 0.85;
  transform: scale(0.86);
}
.module-card.feature .mc-mini.side.left { transform: scale(0.86) rotate(-6deg); }
.module-card.feature .mc-mini.side.right { transform: scale(0.86) rotate(6deg); }
.module-card.feature:hover .mc-mini.center { transform: translateY(-14px); }

/* Footer */
.mc-foot {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 22px 18px;
  border-top: 1px solid var(--line-soft);
  font-size: 12px;
  color: var(--text-2);
  font-weight: 500;
}
.mc-foot .tags {
  flex: 1;
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.mc-foot .tag {
  background: var(--bg);
  color: var(--text-2);
  font-size: 10px;
  font-weight: 600;
  padding: 4px 8px;
  border-radius: 6px;
  border: 1px solid var(--line-soft);
  letter-spacing: 0.2px;
}
.mc-foot .arrow {
  color: var(--primary);
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: transform 0.2s ease;
  white-space: nowrap;
}
.module-card:hover .mc-foot .arrow { transform: translateX(4px); }

/* Responsive overrides */
@media (max-width: 980px) {
  .hero-wrap { grid-template-columns: 1fr; gap: 40px; padding: 24px 32px 40px; }
  .hero-left h1 { font-size: 44px; }
  .hero-right { height: 460px; }
  .feature-strip { grid-template-columns: repeat(2, 1fr); }
  .section-block-head h2 { font-size: 28px; }
}
@media (max-width: 600px) {
  .hero-left h1 { font-size: 36px; letter-spacing: -1.4px; }
  .hero-left h1 .small-line { font-size: 18px; }
  .hero-stats-row { gap: 20px; }
  .hero-stats-row .stat-num { font-size: 24px; }
  .feature-strip { grid-template-columns: 1fr; padding: 28px 20px; }
  .hero-right { height: 380px; }
  .hero-phone { width: 200px; height: 432px; }
  .hero-phone-inner { transform: scale(0.5128); }
  .hero-phone.p2 { left: 18%; }
  .hero-phone.p3 { right: 4%; }
}

/* ============================================
   Footer
   ============================================ */
.footer {
  text-align: center;
  padding: 40px 32px 60px;
  color: var(--text-3);
  font-size: 12px;
}

/* ============================================
   Responsive
   ============================================ */
@media (max-width: 700px) {
  .page-header { padding: 24px 20px 12px; }
  .page-header h1 { font-size: 18px; }
  .module-nav { padding: 12px 20px; gap: 6px; }
  .module-nav a { padding: 8px 12px; font-size: 11.5px; }
  .screens-grid { padding: 28px 20px 48px; gap: 28px 16px; }
  .landing-hero { padding: 40px 20px 28px; }
  .landing-hero h1 { font-size: 30px; }
  .modules-grid { padding: 12px 20px 60px; }
}

a.screen-label { text-decoration: none; cursor: pointer; transition: color 0.15s ease; }
a.screen-label:hover { color: var(--primary, #BE8848); }
a.screen-label:hover .fa-arrow-up-right-from-square { opacity: 1 !important; }