/* ==========================================================================
   NovaPlayer - Portal Web & IPTV Landing Page Stylesheet
   Design minimalista dark emerald do NovaPlayer
   ========================================================================== */

:root {
  --em: #00DF82;
  --em2: #05D374;
  --em-glow: rgba(0, 223, 130, 0.32);
  --em-subtle: rgba(0, 223, 130, 0.12);
  --bg: #020805;
  --bg-card: rgba(8, 22, 16, 0.78);
  --bg-card-hover: rgba(13, 34, 25, 0.92);
  --bg-card-solid: #06150e;
  --border: rgba(255, 255, 255, 0.08);
  --border-active: rgba(0, 223, 130, 0.38);
  --txt: #f8fafc;
  --muted: #86A597;
  --muted-light: #cbd5e1;
  --warn: #f59e0b;
  --danger: #ef4444;
  --radius-lg: 20px;
  --radius-md: 14px;
  --radius-sm: 8px;
  --font-main: 'Outfit', 'Segoe UI', system-ui, -apple-system, Roboto, sans-serif;
  --font-logo: 'Outfit', 'Arial Black', sans-serif;
}

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

html, body {
  background: var(--bg);
  color: var(--txt);
  font-family: var(--font-main);
  -webkit-font-smoothing: antialiased;
  line-height: 1.55;
  scroll-behavior: smooth;
  min-height: 100vh;
  width: 100%;
  overflow-x: hidden;
  position: relative;
}

/* Background com Gradientes Radiais Esmeralda */
.bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  background: var(--bg);
  background-image:
    radial-gradient(ellipse 70% 55% at 50% 18%, rgba(0, 223, 130, 0.14) 0%, rgba(2, 8, 5, 0.6) 55%, #020805 100%),
    radial-gradient(ellipse 90% 70% at 50% 0%, rgba(0, 223, 130, 0.08) 0%, rgba(2, 8, 5, 0) 65%),
    radial-gradient(circle 800px at 80% 90%, rgba(5, 211, 116, 0.06) 0%, rgba(2, 8, 5, 0) 70%);
  pointer-events: none;
}

.wrap {
  position: relative;
  z-index: 1;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Tipografia & Logos */
.logo {
  font-family: var(--font-logo);
  font-weight: 900;
  letter-spacing: 0.8px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: var(--txt);
}
.logo .o {
  color: var(--em);
}
.logo-badge {
  font-size: 10px;
  text-transform: uppercase;
  background: var(--em);
  color: #041f17;
  padding: 2px 8px;
  border-radius: 999px;
  font-weight: 800;
  letter-spacing: 1px;
}

/* ==========================================================================
   Header Fixo com Vidro Fosco (Glassmorphism)
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(7, 11, 9, 0.78);
  -webkit-backdrop-filter: blur(14px) saturate(160%);
  backdrop-filter: blur(14px) saturate(160%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  transition: background 0.2s;
}

.hdr-in {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.hdr-in .logo {
  font-size: 23px;
  flex: 0 0 auto;
}

.hdr-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

.hdr-nav a {
  color: var(--muted);
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  padding: 7px 14px;
  border-radius: 999px;
  white-space: nowrap;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.hdr-nav a:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
}

.hdr-nav a.active {
  color: var(--em);
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.25);
}

.hdr-nav a.is-cta {
  color: #04231a;
  background: var(--em);
  font-weight: 700;
  margin-left: 8px;
}

.hdr-nav a.is-cta:hover {
  background: var(--em);
  filter: brightness(1.12);
  box-shadow: 0 0 16px var(--em-glow);
}

.hdr-acts {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
}

/* Ícones SVG Universais e Botões */
.btn-ic {
  width: 16px;
  height: 16px;
  stroke-width: 2.2;
  display: inline-block;
  vertical-align: -2.5px;
  margin-right: 6px;
  flex-shrink: 0;
}
.btn-ic-lg {
  width: 26px;
  height: 26px;
  stroke-width: 2;
  display: inline-block;
  vertical-align: middle;
  flex-shrink: 0;
}
.btn-ic-spin {
  animation: icSpin 0.85s linear infinite;
}
@keyframes icSpin {
  100% { transform: rotate(360deg); }
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
  margin-right: 6px;
  vertical-align: middle;
}
.status-dot.active { background: #10b981; box-shadow: 0 0 8px #10b981; }
.status-dot.trial { background: #f59e0b; box-shadow: 0 0 8px #f59e0b; }
.status-dot.expired { background: #ef4444; box-shadow: 0 0 8px #ef4444; }
.status-dot.blocked { background: #6b7280; }

.lang-btn {
  background: transparent;
  border: 1.5px solid rgba(255, 255, 255, 0.2);
  color: var(--muted);
  border-radius: 999px;
  padding: 7px 14px;
  font-size: 13.5px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  font-family: inherit;
}

.lang-btn:hover {
  border-color: var(--em);
  color: var(--em);
  background: rgba(16, 185, 129, 0.08);
}

.hdr-nav .ic {
  display: none;
  width: 18px;
  height: 18px;
}

/* Mobile-First Navigation Toggle, Backdrop & Drawer */
.mobile-nav-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 99;
}

.mobile-nav-backdrop.active {
  display: block;
}

.mobile-nav-toggle {
  display: none;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #fff;
  border-radius: 10px;
  width: 38px;
  height: 38px;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.mobile-nav-toggle:hover,
.mobile-nav-toggle.open {
  background: rgba(0, 223, 130, 0.18);
  border-color: var(--em);
  color: var(--em);
  box-shadow: 0 0 12px rgba(0, 223, 130, 0.3);
}

@media (max-width: 820px) {
  .hdr-in {
    padding: 0 14px;
    height: 62px;
    gap: 8px;
  }
  .hdr-in .logo {
    font-size: 19px;
  }
  .hdr-in .logo img {
    height: 28px !important;
    width: 28px !important;
  }
  .hdr-acts {
    gap: 6px;
  }
  #btnAuthOpen {
    padding: 6px 12px !important;
    font-size: 12.5px !important;
  }
  .lang-btn {
    padding: 6px 9px !important;
    font-size: 12px !important;
  }
  .mobile-nav-toggle {
    display: inline-flex;
  }
  .hdr-nav {
    display: none !important;
    position: fixed;
    top: 62px;
    left: 0;
    right: 0;
    background: rgba(3, 10, 6, 0.98);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border-bottom: 1.5px solid rgba(0, 223, 130, 0.35);
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.95), 0 0 40px rgba(0, 223, 130, 0.08);
    padding: 18px 16px 24px;
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
    z-index: 102;
  }
  .hdr-nav.open {
    display: flex !important;
    animation: mobileNavSlide 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  }
  .hdr-nav a {
    padding: 13px 16px;
    font-size: 15px;
    font-weight: 700;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: #f1f5f9;
    justify-content: flex-start;
  }
  .hdr-nav a:hover, .hdr-nav a.active {
    background: rgba(0, 223, 130, 0.14);
    border-color: rgba(0, 223, 130, 0.4);
    color: var(--em);
  }
}

@keyframes mobileNavSlide {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ==========================================================================
   Botões e Componentes Globais
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--em);
  color: #041811;
  font-weight: 700;
  text-decoration: none;
  padding: 13px 26px;
  border-radius: 12px;
  font-size: 15px;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
}

.btn:hover {
  filter: brightness(1.1);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px var(--em-glow);
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.04);
  color: var(--txt);
  border: 1.5px solid rgba(255, 255, 255, 0.16);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--em);
  color: var(--em);
  box-shadow: none;
}

.btn-sm {
  padding: 8px 14px;
  font-size: 13px;
  border-radius: 8px;
}

.btn-danger {
  background: rgba(239, 68, 68, 0.18);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.35);
}

.btn-danger:hover {
  background: #ef4444;
  color: #fff;
  box-shadow: 0 4px 14px rgba(239, 68, 68, 0.35);
}

.btn-whatsapp {
  background: #25d366;
  color: #032b12;
  font-weight: 800;
}

.btn-whatsapp:hover {
  background: #22bf5b;
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.35);
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero {
  text-align: center;
  padding: 68px 0 48px;
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.3);
  padding: 6px 16px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  color: var(--em);
  letter-spacing: 0.5px;
  margin-bottom: 20px;
}

.hero-pill .dot {
  width: 8px;
  height: 8px;
  background: var(--em);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--em);
  animation: pulseDot 2s infinite ease-in-out;
}

@keyframes pulseDot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.85); }
}

.hero .logo-big {
  font-size: clamp(52px, 10vw, 108px);
  color: var(--txt);
  line-height: 1;
  font-family: var(--font-logo);
  letter-spacing: 1.5px;
  margin-bottom: 8px;
}

.hero h1 {
  font-size: clamp(24px, 3.8vw, 42px);
  font-weight: 800;
  margin: 12px 0 16px;
  letter-spacing: -0.5px;
  color: #fff;
}

.hero p {
  color: var(--muted);
  font-size: clamp(15px, 2vw, 18px);
  max-width: 680px;
  margin: 0 auto 32px;
  line-height: 1.65;
}

.hero .cta {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  max-width: 960px;
  margin: 0 auto;
}

@media (max-width: 640px) {
  .hero {
    padding: 28px 0 20px;
  }
  .hero-pill {
    font-size: 11px;
    padding: 4px 12px;
    margin-bottom: 14px;
    letter-spacing: 0.3px;
  }
  .hero .logo-big {
    font-size: clamp(34px, 10.5vw, 46px);
    letter-spacing: 0.5px;
    white-space: nowrap;
    margin-bottom: 4px;
  }
  .hero h1 {
    font-size: clamp(17px, 5vw, 21px);
    margin: 6px 0 10px;
    line-height: 1.35;
  }
  .hero p {
    font-size: 13.5px;
    margin-bottom: 20px;
    line-height: 1.55;
    padding: 0 4px;
  }
  .hero .cta {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    width: 100%;
    gap: 8px;
    padding: 0 2px;
  }
  /* Os 4 botões de ação principal ocupam largura total */
  .hero .cta > a:nth-child(1),
  .hero .cta > a:nth-child(2),
  .hero .cta > a:nth-child(3),
  .hero .cta > button:nth-child(4) {
    grid-column: span 2;
    width: 100%;
    min-height: 48px;
    font-size: 14.5px;
    padding: 12px 16px;
    border-radius: 12px;
    justify-content: center;
  }
  /* Os 4 botões complementares formam um grid 2x2 elegante */
  .hero .cta > button:nth-child(5),
  .hero .cta > a:nth-child(6),
  .hero .cta > a:nth-child(7),
  .hero .cta > a:nth-child(8) {
    grid-column: span 1;
    width: 100%;
    min-height: 44px;
    font-size: 12px;
    padding: 10px 8px;
    border-radius: 10px;
    justify-content: center;
    text-align: center;
    white-space: normal;
    line-height: 1.25;
  }
  .mac-portal-card {
    padding: 22px 14px !important;
    margin: 0 -4px !important;
    border-radius: 16px !important;
  }
  .portal-nav-tabs {
    flex-direction: column;
    gap: 6px;
  }
  .mac-input-wrapper input {
    font-size: 16px !important;
    padding: 14px 12px !important;
    letter-spacing: 1px !important;
  }
}

/* ==========================================================================
   Área de Gestão / Configuração Remota por MAC (NovaPlayer Style)
   ========================================================================== */
.mac-portal-section {
  padding: 24px 0 60px;
}

.mac-portal-card {
  max-width: 760px;
  margin: 0 auto;
  background: var(--bg-card);
  border: 1.5px solid var(--border-active);
  border-radius: var(--radius-lg);
  padding: 36px 32px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.55), 0 0 40px rgba(0, 223, 130, 0.08);
  position: relative;
  overflow: hidden;
}

.mac-portal-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--em), transparent);
}

.portal-nav-tabs {
  display: flex;
  gap: 8px;
  background: rgba(0, 0, 0, 0.45);
  padding: 5px;
  border-radius: 12px;
  margin-bottom: 28px;
  border: 1px solid var(--border);
}

.portal-tab-btn {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--muted);
  padding: 10px 14px;
  border-radius: 9px;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: inherit;
}

.portal-tab-btn:hover {
  color: var(--txt);
  background: rgba(255, 255, 255, 0.05);
}

.portal-tab-btn.active {
  background: var(--em);
  color: #041f17;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.mac-input-group {
  margin-bottom: 24px;
}

.mac-input-label {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 14px;
  color: var(--muted-light);
  margin-bottom: 8px;
  font-weight: 600;
}

.mac-input-label small {
  color: var(--em);
  font-weight: normal;
}

.mac-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.mac-input-wrapper input {
  width: 100%;
  background: #090e0b;
  border: 2px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
  padding: 16px 20px;
  color: #fff;
  font-size: 20px;
  letter-spacing: 2px;
  text-align: center;
  font-family: monospace, var(--font-main);
  transition: all 0.2s;
}

.mac-input-wrapper input:focus {
  outline: none;
  border-color: var(--em);
  box-shadow: 0 0 16px var(--em-glow);
  background: #0c1410;
}

.mac-input-wrapper input::placeholder {
  color: #4b5853;
  letter-spacing: 1px;
  font-size: 16px;
}

/* Informações do Aparelho Localizado */
.device-box {
  background: rgba(12, 17, 14, 0.95);
  border: 1px solid rgba(16, 185, 129, 0.25);
  border-radius: 16px;
  padding: 22px;
  margin: 24px 0;
  text-align: left;
}

.device-box-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border);
  padding-bottom: 14px;
  margin-bottom: 16px;
  flex-wrap: wrap;
  gap: 10px;
}

.device-box-title {
  display: flex;
  align-items: center;
  gap: 10px;
}

.device-box-title h3 {
  font-size: 18px;
  color: #fff;
}

.device-box-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px;
  font-size: 14px;
}

.device-prop {
  background: rgba(255, 255, 255, 0.03);
  padding: 10px 14px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.device-prop span {
  display: block;
  font-size: 12px;
  color: var(--muted);
  text-transform: uppercase;
  margin-bottom: 3px;
}

.device-prop strong {
  font-size: 14.5px;
  color: var(--txt);
}

/* Status Badges */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.badge-active {
  background: rgba(16, 185, 129, 0.18);
  color: #6ee7b7;
  border: 1px solid rgba(16, 185, 129, 0.35);
}

.badge-trial {
  background: rgba(245, 158, 11, 0.18);
  color: #fcd34d;
  border: 1px solid rgba(245, 158, 11, 0.35);
}

.badge-expired {
  background: rgba(239, 68, 68, 0.18);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.35);
}

.badge-blocked {
  background: rgba(107, 114, 128, 0.2);
  color: #d1d5db;
  border: 1px solid rgba(107, 114, 128, 0.35);
}

/* Gerenciamento de Playlists do Aparelho */
.playlists-container {
  margin-top: 24px;
}

.playlists-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.playlists-header h4 {
  font-size: 16px;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 8px;
}

.playlist-card {
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  transition: all 0.2s;
}

.playlist-card:hover {
  border-color: rgba(16, 185, 129, 0.3);
  background: rgba(255, 255, 255, 0.05);
}

.playlist-info {
  flex: 1;
  min-width: 0;
}

.playlist-info h5 {
  font-size: 15px;
  color: #fff;
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.playlist-info p {
  color: var(--muted);
  font-size: 13px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.playlist-type-tag {
  font-size: 10.5px;
  font-weight: 800;
  text-transform: uppercase;
  padding: 2px 7px;
  border-radius: 5px;
  background: rgba(16, 185, 129, 0.16);
  color: var(--em);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

/* Formulário de Injeção de Playlist Remota */
.playlist-form-box {
  background: rgba(10, 15, 12, 0.95);
  border: 1px dashed rgba(16, 185, 129, 0.35);
  border-radius: 16px;
  padding: 24px;
  margin-top: 20px;
}

.playlist-form-box h4 {
  font-size: 16px;
  color: #fff;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.form-toggle {
  display: flex;
  gap: 10px;
  margin-bottom: 18px;
}

.form-toggle-btn {
  flex: 1;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  color: var(--muted);
  padding: 10px;
  border-radius: 10px;
  font-weight: 700;
  font-size: 13.5px;
  cursor: pointer;
  transition: all 0.2s;
  font-family: inherit;
}

.form-toggle-btn.active {
  background: rgba(16, 185, 129, 0.15);
  border-color: var(--em);
  color: var(--em);
}

.form-row {
  margin-bottom: 14px;
  text-align: left;
}

.form-row label {
  display: block;
  font-size: 13px;
  color: var(--muted-light);
  margin-bottom: 6px;
  font-weight: 600;
}

.form-row input {
  width: 100%;
  background: #070b09;
  border: 1.5px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  padding: 12px 14px;
  color: #fff;
  font-size: 14.5px;
  transition: border-color 0.2s;
  font-family: inherit;
}

.form-row input:focus {
  outline: none;
  border-color: var(--em);
  background: #0c1410;
}

.form-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

@media (max-width: 600px) {
  .form-grid-2 {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   Seção de Renovação / Planos de Ativação
   ========================================================================== */
.plans-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 16px;
  margin: 24px 0;
}

.plan-card {
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 16px;
  padding: 22px 18px;
  text-align: center;
  transition: all 0.25s;
  cursor: pointer;
  position: relative;
  display: flex;
  flex-direction: column;
}

.plan-card:hover {
  transform: translateY(-3px);
  border-color: var(--em);
  background: rgba(16, 185, 129, 0.06);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.plan-card.highlight {
  border: 2px solid var(--em);
  background: rgba(16, 185, 129, 0.09);
}

.plan-ribbon {
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--em);
  color: #04231a;
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  padding: 3px 12px;
  border-radius: 999px;
  letter-spacing: 0.5px;
}

.plan-card h4 {
  font-size: 18px;
  color: #fff;
  margin-bottom: 6px;
}

.plan-price {
  font-size: 26px;
  font-weight: 900;
  color: var(--em);
  margin: 8px 0;
}

.plan-price small {
  font-size: 13px;
  color: var(--muted);
  font-weight: normal;
}

.plan-card p {
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 16px;
  flex: 1;
}

/* ==========================================================================
   Seções da Landing Page (Como Funciona, Formatos, Dispositivos)
   ========================================================================== */
section {
  padding: 54px 0;
}

.sec-title {
  text-align: center;
  font-size: clamp(22px, 3vw, 32px);
  font-weight: 800;
  margin-bottom: 8px;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sec-title .bar {
  display: inline-block;
  width: 44px;
  height: 4px;
  background: var(--em);
  border-radius: 3px;
  vertical-align: middle;
  margin-right: 14px;
}

.sec-sub {
  text-align: center;
  color: var(--muted);
  margin-bottom: 38px;
  font-size: 15.5px;
  max-width: 620px;
  margin-left: auto;
  margin-right: auto;
}

.grid {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.card {
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 28px 24px;
  transition: all 0.2s;
}

.card:hover {
  border-color: rgba(16, 185, 129, 0.3);
  background: rgba(255, 255, 255, 0.05);
  transform: translateY(-2px);
}

.card .step-n {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: rgba(16, 185, 129, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  color: var(--em);
  font-weight: 900;
  font-size: 22px;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.card .ic {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: rgba(16, 185, 129, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  color: var(--em);
}

.card .ic svg {
  width: 26px;
  height: 26px;
  stroke: var(--em);
  fill: none;
  stroke-width: 2;
}

.card h3 {
  font-size: 19px;
  margin-bottom: 8px;
  color: #fff;
}

.card p {
  color: var(--muted);
  font-size: 14.5px;
  line-height: 1.6;
}

/* Grade de Formatos Compatíveis */
.fmt-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 18px;
}

.fmt-box {
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 24px;
}

.fmt-box h3 {
  font-size: 15px;
  font-weight: 800;
  color: var(--em);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 14px;
}

.fmt-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.fmt-tags span {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--txt);
}

/* ==========================================================================
   Grade de Dispositivos (Estilo NovaPlayer)
   ========================================================================== */
.dv-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 14px;
  max-width: 1040px;
  margin: 0 auto;
}

@media (max-width: 960px) {
  .dv-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

@media (max-width: 600px) {
  .dv-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 9px;
  }
}

.dv {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 22px 10px 16px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.09);
  color: var(--txt);
  text-decoration: none;
  text-align: center;
  transition: all 0.2s;
  cursor: pointer;
}

.dv:hover {
  border-color: var(--em);
  background: rgba(16, 185, 129, 0.1);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

.dv-logo {
  height: 44px;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #f5f5f1;
}

.dv-logo svg {
  display: block;
  fill: currentColor;
}

.dv-logo svg.dv-ic {
  height: 38px;
  width: 38px;
}

.dv-logo svg.dv-wm {
  width: 110px;
  max-width: 88%;
  height: auto;
}

.dv-logo svg.dv-wm2 {
  height: 34px;
  width: auto;
  max-width: 88%;
}

.dv-name {
  font-size: 14.5px;
  font-weight: 700;
  line-height: 1.25;
  margin-top: 2px;
}

.dv-name small {
  display: block;
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
}

.dv-st {
  font-size: 12px;
  font-weight: 700;
  color: var(--em);
}

.dv-wide {
  grid-column: span 3;
}

@media (max-width: 960px) {
  .dv-wide {
    grid-column: span 2;
  }
}

@media (max-width: 600px) {
  .dv-wide {
    grid-column: span 3;
  }
}

/* ==========================================================================
   Aviso Legal e DMCA (Compliance & Transparência)
   ========================================================================== */
.notice {
  background: rgba(16, 185, 129, 0.06);
  border: 1px solid rgba(16, 185, 129, 0.28);
  border-radius: 18px;
  padding: 34px 30px;
  margin: 30px 0;
}

.notice h2 {
  font-size: 22px;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: #fff;
}

.notice h2 svg {
  width: 24px;
  height: 24px;
  stroke: var(--em);
  fill: none;
  stroke-width: 2;
}

.notice ul {
  list-style: none;
  display: grid;
  gap: 12px;
}

.notice li {
  color: #d9e2dd;
  font-size: 15px;
  padding-left: 24px;
  position: relative;
  line-height: 1.6;
}

.notice li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 9px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--em);
}

.notice strong {
  color: #fff;
}

/* ==========================================================================
   Modais Interativos
   ========================================================================== */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(0, 0, 0, 0.82);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.modal-overlay.open {
  display: flex;
  opacity: 1;
}

.modal-box {
  position: relative;
  max-width: 480px;
  width: 100%;
  background: #0f1612;
  border: 1px solid rgba(16, 185, 129, 0.4);
  border-radius: 20px;
  padding: 32px 28px;
  text-align: center;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.7);
  animation: modalPop 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modalPop {
  0% { transform: scale(0.92); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

.modal-x {
  position: absolute;
  top: 14px;
  right: 18px;
  background: transparent;
  border: none;
  color: #9aa6a0;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  transition: color 0.15s;
}

.modal-x:hover {
  color: #fff;
}

.modal-ic {
  font-size: 42px;
  margin-bottom: 12px;
}

.modal-box h3 {
  font-size: 22px;
  margin-bottom: 12px;
  color: #fff;
}

.modal-box p {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
  margin-bottom: 18px;
}

.modal-box p b, .modal-box p strong {
  color: #fff;
}

.code-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: 14px 0 20px;
}

.code-badge span {
  font-size: 26px;
  font-weight: 900;
  letter-spacing: 3px;
  color: var(--em);
  font-family: monospace;
  background: rgba(16, 185, 129, 0.12);
  border: 1px dashed rgba(16, 185, 129, 0.5);
  border-radius: 12px;
  padding: 10px 20px;
}

/* ==========================================================================
   Toast Notifications
   ========================================================================== */
#toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}

.toast {
  pointer-events: auto;
  min-width: 280px;
  max-width: 420px;
  padding: 14px 20px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 600;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
  animation: slideToast 0.3s ease;
  backdrop-filter: blur(10px);
}

@keyframes slideToast {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

.toast-success {
  background: rgba(16, 185, 129, 0.95);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.toast-error {
  background: rgba(239, 68, 68, 0.95);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.toast-info {
  background: rgba(59, 130, 246, 0.95);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

/* ==========================================================================
   Rodapé
   ========================================================================== */
footer {
  text-align: center;
  padding: 50px 0 70px;
  color: var(--muted);
  font-size: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  margin-top: 40px;
}

footer .logo {
  color: var(--muted);
  font-size: 20px;
  margin-bottom: 12px;
}

footer a {
  color: var(--em);
  text-decoration: none;
  transition: color 0.15s;
}

footer a:hover {
  text-decoration: underline;
}

footer .footer-links {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin: 14px 0;
  flex-wrap: wrap;
}

/* ==========================================================================
   Autenticação de Usuário (E-mail & Senha) e Dashboard do Cliente
   ========================================================================== */
.auth-modal-box {
  max-width: 440px;
  background: #0d1410;
  border: 1.5px solid var(--border-active);
  border-radius: 20px;
  padding: 32px 28px;
  text-align: center;
  position: relative;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.75), 0 0 30px rgba(16, 185, 129, 0.12);
}

.auth-tabs {
  display: flex;
  background: rgba(0, 0, 0, 0.4);
  padding: 4px;
  border-radius: 12px;
  margin-bottom: 22px;
  border: 1px solid var(--border);
}

.auth-tab-btn {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--muted);
  padding: 10px;
  border-radius: 9px;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
  font-family: inherit;
}

.auth-tab-btn.active {
  background: var(--em);
  color: #04231a;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.3);
}

.auth-input-group {
  margin-bottom: 14px;
  text-align: left;
}

.auth-input-group label {
  display: block;
  font-size: 13px;
  color: var(--muted-light);
  margin-bottom: 6px;
  font-weight: 600;
}

.auth-input-group input {
  width: 100%;
  background: #080c09;
  border: 1.5px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  padding: 12px 14px;
  color: #fff;
  font-size: 14.5px;
  transition: border-color 0.2s;
  font-family: inherit;
}

.auth-input-group input:focus {
  outline: none;
  border-color: var(--em);
  background: #0b120e;
}

.password-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
}

.password-wrapper input {
  width: 100%;
  padding-right: 44px !important;
}

.btn-toggle-pass {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  color: var(--muted, #94a3b8);
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.2s;
  z-index: 2;
  border-radius: 6px;
}

.btn-toggle-pass:hover {
  color: var(--em, #10b981);
}

.user-profile-header {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.25);
  border-radius: 14px;
  padding: 16px 20px;
  margin-bottom: 24px;
  text-align: left;
}

.user-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--em);
  color: #04231a;
  font-weight: 900;
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.user-devices-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 14px;
  margin: 18px 0;
}

.user-device-card {
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 18px;
  text-align: left;
  transition: all 0.2s;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.user-device-card:hover {
  border-color: rgba(16, 185, 129, 0.35);
  background: rgba(255, 255, 255, 0.05);
}

/* ==========================================================================
   Parcerias Empresariais & Provedores de IPTV (B2B)
   ========================================================================== */
.b2b-section {
  padding: 64px 0 80px;
  position: relative;
}

.b2b-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.4);
  color: var(--em);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 5px 14px;
  border-radius: 999px;
  margin-bottom: 12px;
}

.b2b-hero-card {
  background: linear-gradient(145deg, rgba(16, 185, 129, 0.10) 0%, rgba(7, 11, 9, 0.95) 70%);
  border: 1.5px solid rgba(16, 185, 129, 0.35);
  border-radius: var(--radius-lg);
  padding: 42px 34px;
  margin-bottom: 40px;
  text-align: center;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.b2b-hero-card h2 {
  font-size: clamp(24px, 3.4vw, 38px);
  color: #fff;
  font-weight: 900;
  margin-bottom: 14px;
}

.b2b-hero-card p {
  color: var(--muted-light);
  font-size: clamp(15px, 1.8vw, 17px);
  max-width: 760px;
  margin: 0 auto 28px;
  line-height: 1.65;
}

.b2b-features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin: 32px 0 48px;
}

.b2b-feat-card {
  background: rgba(20, 26, 22, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 18px;
  padding: 30px 24px;
  text-align: left;
  transition: all 0.25s;
}

.b2b-feat-card:hover {
  transform: translateY(-3px);
  border-color: var(--em);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4);
}

.b2b-feat-card .b2b-ic {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  margin-bottom: 18px;
}

.b2b-feat-card h4 {
  font-size: 19px;
  color: #fff;
  margin-bottom: 8px;
}

.b2b-feat-card p {
  color: var(--muted);
  font-size: 14.5px;
  line-height: 1.6;
}

/* Formulário B2B para Provedores */
.b2b-form-card {
  max-width: 720px;
  margin: 0 auto;
  background: rgba(15, 22, 18, 0.92);
  border: 1.5px solid rgba(16, 185, 129, 0.35);
  border-radius: var(--radius-lg);
  padding: 38px 32px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
}

.b2b-form-card select {
  width: 100%;
  background: #080c09;
  border: 1.5px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  padding: 12px 14px;
  color: #fff;
  font-size: 14.5px;
  font-family: inherit;
  cursor: pointer;
}

.b2b-form-card select:focus {
  outline: none;
  border-color: var(--em);
}

.b2b-form-card textarea {
  width: 100%;
  background: #080c09;
  border: 1.5px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  padding: 12px 14px;
  color: #fff;
  font-size: 14.5px;
  font-family: inherit;
  resize: vertical;
  min-height: 90px;
}

.b2b-form-card textarea:focus {
  outline: none;
  border-color: var(--em);
}

/* ==========================================================================
   Suporte a Idioma Bilíngue (PT / EN) NovaPlayer
   ========================================================================== */
html:not(.lang-pt) [data-l="pt"] {
  display: none !important;
}

html.lang-pt [data-l="en"] {
  display: none !important;
}

/* ==========================================================================
   Painel do Cliente Autenticado (Client Dashboard - Visão Separada)
   ========================================================================== */
.portal-view {
  animation: fadeInView 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes fadeInView {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Prevenção de flash para usuário autenticado */
html.has-user-session #viewGuest { display: none !important; }
html.has-user-session #viewUser { display: block !important; }
html.has-user-session #hdrNavGuest { display: none !important; }
html.has-user-session #hdrActsGuest { display: none !important; }
html.has-user-session #hdrActsUser { display: flex !important; }

/* Barra Flutuante de Retorno ao Painel */
.return-dash-banner {
  background: linear-gradient(90deg, #064e3b 0%, #047857 100%);
  color: #fff;
  padding: 10px 20px;
  font-size: 13.5px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 68px;
  z-index: 99;
  box-shadow: 0 4px 16px rgba(0,0,0,0.4);
}

.return-dash-banner a {
  color: #fff;
  font-weight: 700;
  text-decoration: underline;
  cursor: pointer;
}

/* Welcome Hero do Cliente */
.client-hero-card {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.16) 0%, rgba(13, 20, 16, 0.95) 60%),
              radial-gradient(circle at 85% 30%, rgba(16, 185, 129, 0.22) 0%, transparent 60%);
  border: 1.5px solid rgba(16, 185, 129, 0.4);
  border-radius: var(--radius-lg);
  padding: 32px 36px;
  margin: 32px 0 36px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.55), 0 0 40px rgba(16, 185, 129, 0.12);
  flex-wrap: wrap;
}

.client-hero-left {
  display: flex;
  align-items: center;
  gap: 20px;
  flex: 1;
  min-width: 0;
}

.client-avatar-big {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: linear-gradient(135deg, #10b981 0%, #047857 100%);
  color: #041f17;
  font-size: 26px;
  font-weight: 900;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 20px rgba(16, 185, 129, 0.4);
  flex-shrink: 0;
}

.client-hero-meta {
  flex: 1;
  min-width: 0;
}

.client-hero-meta h2 {
  font-size: clamp(20px, 2.5vw, 28px);
  color: #fff;
  font-weight: 800;
  margin-bottom: 4px;
  word-break: break-word;
}

.client-hero-meta p {
  color: var(--muted);
  font-size: 14.5px;
  margin-bottom: 8px;
}

.client-badges-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.client-badge-pill {
  font-size: 12px;
  font-weight: 700;
  padding: 3px 12px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  max-width: 100%;
}

.client-badge-pill span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.client-badge-pill.status-pro {
  background: rgba(16, 185, 129, 0.2);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.45);
}
.client-badge-pill.status-info {
  background: rgba(255, 255, 255, 0.08);
  color: var(--muted-light);
  border: 1px solid var(--border);
}

/* Botão Chamativo de Acesso ao Web Player */
.dash-quick-player-btn {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: #032017 !important;
  font-weight: 900;
  font-size: 16px;
  padding: 16px 30px;
  border-radius: 14px;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  box-shadow: 0 10px 30px rgba(16, 185, 129, 0.45);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  text-decoration: none;
  text-align: center;
}

.dash-quick-player-btn:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 14px 40px rgba(16, 185, 129, 0.65);
  background: linear-gradient(135deg, #34d399 0%, #10b981 100%);
}

.dash-quick-player-btn small {
  display: block;
  font-size: 11px;
  font-weight: 600;
  opacity: 0.85;
}

/* Grid Principal de Conteúdo do Dashboard */
.dash-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 24px;
  margin-bottom: 40px;
}

@media (max-width: 900px) {
  .dash-grid {
    grid-template-columns: 1fr;
  }
}

.dash-card {
  background: rgba(18, 24, 20, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-md);
  padding: 24px;
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.4);
}

.dash-card:hover {
  border-color: rgba(16, 185, 129, 0.3);
}

.dash-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  padding-bottom: 14px;
}

.dash-card-title {
  color: #fff;
  font-size: 18px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 10px;
}

.dash-card-title span.ic {
  font-size: 20px;
}

.dash-badge {
  font-size: 11px;
  background: rgba(16, 185, 129, 0.15);
  color: var(--em);
  padding: 2px 8px;
  border-radius: 999px;
  font-weight: 700;
}

/* User Header Pill */
.hdr-user-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  padding: 5px 12px;
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  max-width: 220px;
}
.hdr-user-pill span#hdrUserEmail {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.hdr-user-pill .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 8px #10b981;
  flex-shrink: 0;
}

/* App Install Chips */
.dash-install-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
  margin-top: 14px;
}

.dash-install-box {
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px;
  transition: all 0.2s;
}

.dash-install-box:hover {
  border-color: rgba(16, 185, 129, 0.4);
  background: rgba(16, 185, 129, 0.05);
}

.dash-install-box h6 {
  color: #fff;
  font-size: 14px;
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.dash-install-box p {
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 8px;
}

.dash-install-code {
  font-family: monospace;
  font-size: 13px;
  color: #34d399;
  background: rgba(16, 185, 129, 0.12);
  padding: 3px 8px;
  border-radius: 6px;
  display: inline-block;
  font-weight: 700;
}

/* ==========================================================================
   CLIENT DASHBOARD V2 — METRICAS, ABAS E CARDS RICOS
   ========================================================================== */

/* Grid de Métricas / KPI Cards */
.dash-kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin-bottom: 28px;
}

.dash-kpi-card {
  background: linear-gradient(145deg, rgba(18, 26, 21, 0.9) 0%, rgba(10, 15, 12, 0.95) 100%);
  border: 1px solid rgba(16, 185, 129, 0.22);
  border-radius: var(--radius-md);
  padding: 18px 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
  transition: all 0.25s ease;
  position: relative;
  overflow: hidden;
}

.dash-kpi-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(16, 185, 129, 0.6), transparent);
  opacity: 0;
  transition: opacity 0.3s;
}

.dash-kpi-card:hover {
  transform: translateY(-3px);
  border-color: rgba(16, 185, 129, 0.5);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.5), 0 0 24px rgba(16, 185, 129, 0.15);
}

.dash-kpi-card:hover::before {
  opacity: 1;
}

.dash-kpi-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 22px;
}
.dash-kpi-icon.kpi-emerald {
  background: rgba(16, 185, 129, 0.15);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.3);
}
.dash-kpi-icon.kpi-amber {
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.3);
}
.dash-kpi-icon.kpi-blue {
  background: rgba(59, 130, 246, 0.15);
  color: #60a5fa;
  border: 1px solid rgba(59, 130, 246, 0.3);
}
.dash-kpi-icon.kpi-purple {
  background: rgba(168, 85, 247, 0.15);
  color: #c084fc;
  border: 1px solid rgba(168, 85, 247, 0.3);
}

.dash-kpi-meta {
  flex: 1;
  min-width: 0;
}

.dash-kpi-label {
  font-size: 11.5px;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 3px;
}

.dash-kpi-value {
  font-size: 20px;
  font-weight: 800;
  color: #fff;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-kpi-sub {
  font-size: 12px;
  color: var(--muted-light);
  margin-top: 4px;
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Barra de Abas do Painel */
.dash-nav-bar {
  background: rgba(11, 16, 13, 0.95);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 6px;
  display: flex;
  gap: 6px;
  margin-bottom: 26px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  -ms-overflow-style: none;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.dash-nav-bar::-webkit-scrollbar {
  display: none;
}

.dash-tab-btn {
  background: transparent;
  border: none;
  border-radius: 10px;
  padding: 10px 18px;
  color: var(--muted);
  font-weight: 700;
  font-size: 13.5px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.dash-tab-btn:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.06);
}

.dash-tab-btn.active {
  color: #032017 !important;
  background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
  font-weight: 800;
  box-shadow: 0 4px 16px rgba(16, 185, 129, 0.38);
}

.dash-tab-btn .tab-badge {
  font-size: 11px;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.25);
  color: inherit;
}

/* Painéis de Conteúdo das Abas */
.dash-tab-panel {
  display: none;
  animation: dashFadeIn 0.28s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.dash-tab-panel.active {
  display: block;
}

@keyframes dashFadeIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Cards Ricos de Dispositivos */
.user-device-card-rich {
  background: linear-gradient(145deg, rgba(18, 25, 20, 0.95) 0%, rgba(10, 14, 11, 0.98) 100%);
  border: 1px solid rgba(16, 185, 129, 0.25);
  border-radius: 16px;
  padding: 22px;
  margin-bottom: 18px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
  transition: all 0.22s ease;
}

.user-device-card-rich:hover {
  border-color: rgba(16, 185, 129, 0.5);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.55), 0 0 20px rgba(16, 185, 129, 0.12);
}

.device-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  flex-wrap: wrap;
}

.device-card-title-group {
  display: flex;
  align-items: center;
  gap: 14px;
}

.device-avatar-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: rgba(16, 185, 129, 0.15);
  color: #10b981;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(16, 185, 129, 0.3);
  flex-shrink: 0;
}

.device-name-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.device-name-row h4 {
  color: #fff;
  font-size: 17px;
  font-weight: 800;
  margin: 0;
}

.device-rename-btn {
  background: transparent;
  border: none;
  color: var(--muted);
  cursor: pointer;
  padding: 3px 6px;
  border-radius: 4px;
  display: inline-flex;
  align-items: center;
  transition: all 0.2s;
}

.device-rename-btn:hover {
  color: var(--em);
  background: rgba(255, 255, 255, 0.05);
}

.device-details-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  margin-bottom: 16px;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  padding: 14px 16px;
}

.device-info-cell {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.device-info-cell small {
  font-size: 11px;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 700;
  letter-spacing: 0.5px;
}

.device-info-cell .val-row {
  display: flex;
  align-items: center;
  gap: 6px;
}

.device-info-cell strong {
  font-family: monospace;
  font-size: 14px;
  color: #fff;
}

.dash-copy-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 6px;
  color: var(--muted-light);
  cursor: pointer;
  padding: 3px 8px;
  font-size: 11.5px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: all 0.15s;
}

.dash-copy-btn:hover {
  color: #fff;
  background: rgba(16, 185, 129, 0.2);
  border-color: rgba(16, 185, 129, 0.4);
}

.dash-copy-btn.copied {
  background: #10b981 !important;
  color: #042017 !important;
  border-color: #10b981 !important;
  font-weight: 700;
}

/* Barra de Expiração */
.device-expiry-track {
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  overflow: hidden;
  margin-top: 6px;
}

.device-expiry-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #10b981, #34d399);
}

.device-actions-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
}

/* Planos no Dashboard do Cliente */
.dash-plans-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  margin-top: 14px;
}

.dash-plan-card {
  background: rgba(18, 25, 21, 0.95);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 26px 22px;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: all 0.25s ease;
}

.dash-plan-card:hover {
  border-color: rgba(16, 185, 129, 0.5);
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5), 0 0 25px rgba(16, 185, 129, 0.15);
}

.dash-plan-card.featured {
  border: 2px solid var(--em);
  background: linear-gradient(145deg, rgba(16, 185, 129, 0.12) 0%, rgba(13, 20, 16, 0.98) 100%);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.55), 0 0 30px rgba(16, 185, 129, 0.2);
}

.dash-plan-card .plan-badge-top {
  position: absolute;
  top: -12px;
  right: 20px;
  background: linear-gradient(135deg, #10b981, #059669);
  color: #032017;
  font-size: 11px;
  font-weight: 800;
  padding: 3px 12px;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
}

.dash-plan-price {
  font-size: 30px;
  font-weight: 900;
  color: #fff;
  margin: 12px 0 16px;
}

.dash-plan-price small {
  font-size: 14px;
  color: var(--muted);
  font-weight: 500;
}

.dash-plan-features {
  list-style: none;
  padding: 0;
  margin: 0 0 22px 0;
  flex: 1;
}

.dash-plan-features li {
  font-size: 13.5px;
  color: var(--muted-light);
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.dash-plan-features li svg {
  color: #10b981;
  flex-shrink: 0;
}

/* FAQ Accordion */
.dash-faq-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 14px;
}

.dash-faq-item {
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  transition: border-color 0.2s;
}

.dash-faq-item:hover {
  border-color: rgba(16, 185, 129, 0.35);
}

.dash-faq-header {
  padding: 16px 20px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 700;
  color: #fff;
  font-size: 15px;
}

.dash-faq-header svg {
  transition: transform 0.25s ease;
  color: var(--muted);
}

.dash-faq-item.open .dash-faq-header svg {
  transform: rotate(180deg);
  color: var(--em);
}

.dash-faq-body {
  display: none;
  padding: 0 20px 18px 20px;
  font-size: 14px;
  color: var(--muted-light);
  line-height: 1.6;
  border-top: 1px solid rgba(255, 255, 255, 0.04);
}

.dash-faq-item.open .dash-faq-body {
  display: block;
}

/* ==========================================================================
   Mobile-First & Ultra-Responsive Breakpoints (Client Portal / #viewUser)
   ========================================================================== */
@media (max-width: 900px) {
  .client-hero-card {
    flex-direction: column;
    align-items: stretch;
    padding: 22px 18px;
    margin: 20px 0 24px;
    gap: 18px;
  }

  .client-hero-left {
    min-width: 0;
    width: 100%;
    gap: 14px;
  }

  .client-avatar-big {
    width: 52px;
    height: 52px;
    font-size: 22px;
  }

  .client-hero-meta {
    flex: 1;
    min-width: 0;
  }

  .client-hero-meta h2 {
    font-size: 20px;
    word-break: break-word;
  }

  .dash-quick-player-btn {
    width: 100%;
    min-height: 52px;
    padding: 14px 20px;
    font-size: 15px;
    justify-content: center;
  }

  .dash-kpi-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-bottom: 20px;
  }

  .dash-kpi-card {
    padding: 12px 10px;
    gap: 10px;
  }

  .dash-kpi-icon {
    width: 38px;
    height: 38px;
    font-size: 17px;
    border-radius: 10px;
  }

  .dash-kpi-value {
    font-size: 16px;
  }

  .dash-kpi-label {
    font-size: 10px;
  }

  .dash-kpi-sub {
    font-size: 11px;
  }

  .dash-nav-bar {
    padding: 4px;
    gap: 4px;
    margin-bottom: 18px;
    border-radius: 12px;
  }

  .dash-tab-btn {
    padding: 8px 12px;
    font-size: 12.5px;
    min-height: 42px;
  }
}

@media (max-width: 640px) {
  #viewUser.wrap {
    padding: 0 12px 60px;
  }

  .client-hero-card {
    padding: 18px 14px;
    margin: 14px 0 18px;
    border-radius: 14px;
    gap: 16px;
  }

  .client-hero-left {
    flex-direction: row;
    align-items: center;
    gap: 12px;
  }

  .client-avatar-big {
    width: 46px;
    height: 46px;
    font-size: 20px;
  }

  .client-hero-meta h2 {
    font-size: 17px;
    line-height: 1.3;
  }

  .client-hero-meta p {
    font-size: 12.5px;
    line-height: 1.45;
    margin-bottom: 8px;
  }

  .client-badges-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
    width: 100%;
  }

  .client-badge-pill {
    max-width: 100%;
    font-size: 11px;
    padding: 3px 10px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .client-badge-pill #dashUserEmail {
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    display: inline-block;
    vertical-align: middle;
  }

  .dash-quick-player-btn {
    padding: 12px 14px;
    font-size: 14px;
    border-radius: 12px;
  }

  .dash-quick-player-btn small {
    font-size: 10px;
  }

  .dash-kpi-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }

  .dash-kpi-card {
    padding: 10px 8px;
    gap: 8px;
    border-radius: 10px;
  }

  .dash-kpi-icon {
    width: 32px;
    height: 32px;
    font-size: 15px;
    border-radius: 8px;
  }

  .dash-kpi-value {
    font-size: 14.5px;
  }

  .dash-kpi-label {
    font-size: 9.5px;
  }

  .dash-kpi-sub {
    font-size: 10.5px;
  }

  .user-device-card-rich {
    padding: 16px 12px;
    border-radius: 14px;
  }

  .device-card-top {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .device-details-grid {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    padding: 10px;
  }

  .device-info-cell small {
    font-size: 10px;
  }

  .device-info-cell strong {
    font-size: 12px;
  }

  .device-actions-row {
    flex-direction: column;
    width: 100%;
    gap: 8px;
  }

  .device-actions-row .btn {
    width: 100%;
    min-height: 44px;
    justify-content: center;
  }

  .dash-plans-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .dash-card {
    padding: 18px 14px;
    border-radius: 14px;
  }

  .dash-card-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .hdr-user-pill {
    max-width: 110px;
    padding: 4px 8px;
    font-size: 11.5px;
  }

  #hdrActsUser {
    gap: 4px;
  }

  #hdrActsUser .btn {
    padding: 6px 10px !important;
    font-size: 11.5px !important;
  }
}

