/* ==========================================================================
   MACHINE GLOBAL — DESIGN SYSTEM & ESTILOS
   Software White Label de Mobilidade & Entrega
   ========================================================================== */

:root {
  --machine-blue: #2b7aff;
  --machine-blue-hover: #1a5fd4;
  --machine-blue-soft: rgba(43, 122, 255, 0.08);
  --machine-blue-glow: rgba(43, 122, 255, 0.35);
  --machine-dark: #262626;
  --machine-text-muted: #666666;
  --machine-bg-light: #fafafa;
  --machine-border: #e5e5e5;
  --machine-border-subtle: rgba(217, 217, 217, 0.6);
  --machine-green: #10b981;
  --machine-yellow: #f59e0b;
  --machine-red: #ef4444;
}

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

body {
  font-family: 'Source Sans 3', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--machine-dark);
  background-color: #ffffff;
  line-height: 1.5;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Floating pill navbar */
.floating-nav {
  position: fixed;
  top: 14px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1000;
  width: calc(100% - 32px);
  max-width: 1240px;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--machine-border-subtle);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06);
  transition: all 0.3s ease;
  padding: 10px 24px;
}

.floating-nav.scrolled {
  top: 8px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.09);
}

/* Brand Button Styles */
.glow-btn {
  background: linear-gradient(135deg, #2b7aff 0%, #1a5fd4 100%);
  color: #ffffff;
  font-weight: 600;
  border-radius: 9999px;
  box-shadow: 0 4px 20px var(--machine-blue-glow);
  transition: all 0.25s ease;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
}

.glow-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(43, 122, 255, 0.5);
}

.glow-btn:active {
  transform: translateY(0);
}

.neon-border-btn {
  border-radius: 9999px;
  border: 1px solid rgba(43, 122, 255, 0.35);
  background: rgba(43, 122, 255, 0.04);
  color: var(--machine-blue);
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.neon-border-btn:hover {
  background: rgba(43, 122, 255, 0.12);
  color: var(--machine-blue-hover);
  border-color: var(--machine-blue);
}

/* 4 Modules Pill Selector Tabs (Exact Match to User Uploaded Screenshot) */
.module-pill-tabs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin: 36px auto;
}

.module-pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  height: 48px;
  padding: 0 24px;
  border-radius: 9999px;
  font-size: 15px;
  font-weight: 600;
  color: #333333;
  background-color: #f1f3f5;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  outline: none;
  user-select: none;
}

.module-pill-btn svg {
  width: 19px;
  height: 19px;
  flex-shrink: 0;
  transition: transform 0.2s ease;
}

.module-pill-btn:hover {
  background-color: #e5e9ec;
  color: #111111;
  transform: translateY(-1px);
}

.module-pill-btn.active {
  background: #2b7aff !important;
  color: #ffffff !important;
  box-shadow: 0 6px 20px rgba(43, 122, 255, 0.38);
  border-color: transparent;
}

.module-pill-btn.active svg {
  color: #ffffff !important;
}

/* Smartphone Mockup Frame */
.phone-frame {
  width: 330px;
  height: 660px;
  background: #111827;
  border-radius: 46px;
  padding: 12px;
  box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.3), 0 0 0 1px rgba(255, 255, 255, 0.1);
  position: relative;
  margin: 0 auto;
  flex-shrink: 0;
}

.phone-screen {
  width: 100%;
  height: 100%;
  background: #ffffff;
  border-radius: 36px;
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
}

.phone-dynamic-island {
  position: absolute;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  width: 96px;
  height: 22px;
  background: #000000;
  border-radius: 20px;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding: 0 8px;
}

.phone-dynamic-island .camera {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #1e293b;
}

.phone-status-bar {
  height: 38px;
  padding: 10px 18px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11px;
  font-weight: 600;
  color: #1f2937;
  z-index: 40;
  position: relative;
}

/* Map Containers */
.leaflet-container {
  font-family: inherit;
}

.radar-ping {
  position: relative;
  display: inline-flex;
}

.radar-ping::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: var(--machine-blue);
  animation: radar-wave 2s infinite ease-out;
  opacity: 0.8;
  pointer-events: none;
}

@keyframes radar-wave {
  0% {
    width: 100%;
    height: 100%;
    opacity: 0.8;
  }
  100% {
    width: 320%;
    height: 320%;
    opacity: 0;
  }
}

/* Badge Pulse */
.pulse-dot {
  width: 8px;
  height: 8px;
  background-color: var(--machine-blue);
  border-radius: 50%;
  display: inline-block;
  animation: pulse-animation 1.5s infinite;
}

@keyframes pulse-animation {
  0% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(43, 122, 255, 0.7);
  }
  70% {
    transform: scale(1);
    box-shadow: 0 0 0 8px rgba(43, 122, 255, 0);
  }
  100% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(43, 122, 255, 0);
  }
}

/* Feature Cards */
.feature-card {
  background: #ffffff;
  border: 1px solid var(--machine-border);
  border-radius: 20px;
  padding: 28px;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.feature-card:hover {
  border-color: rgba(43, 122, 255, 0.5);
  box-shadow: 0 16px 40px -15px rgba(43, 122, 255, 0.15);
  transform: translateY(-3px);
}

/* Client Logo Marquee */
.marquee-wrapper {
  overflow: hidden;
  user-select: none;
  display: flex;
  gap: 2rem;
}

.marquee-track {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  justify-content: space-around;
  gap: 2rem;
  min-width: 100%;
  animation: marquee-scroll 32s linear infinite;
}

.marquee-track:hover {
  animation-play-state: paused;
}

@keyframes marquee-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(calc(-100% - 2rem)); }
}

/* Modern Tabs Content Transitions */
.tab-content {
  display: none;
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.tab-content.active {
  display: block;
  opacity: 1;
  transform: translateY(0);
}

/* Dispatch modal popup for driver app */
.dispatch-alert-modal {
  position: absolute;
  inset: 0;
  background: rgba(17, 24, 39, 0.88);
  backdrop-filter: blur(8px);
  z-index: 60;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 16px;
  animation: slide-up 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slide-up {
  from { transform: translateY(100%); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

/* Audio chime notification wave */
.audio-chime-ring {
  animation: ring 0.5s ease-in-out infinite alternate;
}

@keyframes ring {
  0% { transform: rotate(-10deg); }
  100% { transform: rotate(10deg); }
}
