/* ============================================================
   QR INVEST – Estilos principais
   Autor: Quatro Rios | Versão: 1.3
   Base: Argon Dashboard (HSN)
   ============================================================ */

/* ======= GLOBAL ======= */
:root {
  --primary: #0046ad;
  --secondary: #002f6c;
  --accent: #ffcc00;
  --light-bg: #f5f6fa;
  --text-color: #1a1a1a;
}

body {
  font-family: 'Inter', sans-serif !important;
  background: var(--light-bg);
  color: var(--text-color);
  margin: 0;
  padding: 0;
  line-height: 1.6;
}

/* ======= DASHBOARD WRAPPER ======= */
.qr-dashboard {
  display: flex;
  min-height: 100vh;
  width: 100%;
  overflow-x: hidden;
}

/* ======= SIDEBAR ======= */
.qr-sidebar {
  width: 240px;
  background: var(--secondary);
  color: #fff;
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  z-index: 999;
  transition: transform 0.3s ease-in-out;
}

.qr-sidebar .logo {
  padding: 20px;
  text-align: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.qr-sidebar .logo img {
  max-width: 120px;
  height: auto;
}

.qr-sidebar nav ul {
  list-style: none;
  margin: 0;
  padding: 20px 0;
}
.qr-sidebar nav ul li {
  margin: 4px 0;
}
.qr-sidebar nav ul li a {
  display: block;
  padding: 12px 20px;
  text-decoration: none;
  color: #fff;
  font-size: 15px;
  border-left: 3px solid transparent;
  transition: all 0.2s ease-in-out;
}
.qr-sidebar nav ul li a:hover,
.qr-sidebar nav ul li.active a {
  background: rgba(255, 255, 255, 0.1);
  border-left-color: var(--accent);
  padding-left: 24px;
}

/* ======= BOTÃO MOBILE ======= */
.qr-sidebar-toggle {
  display: none;
  position: fixed;
  top: 15px;
  left: 15px;
  background: var(--primary);
  border: none;
  color: #fff;
  padding: 10px 12px;
  border-radius: 4px;
  z-index: 1001;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

/* ======= HEADER ======= */
.qr-header {
  margin-left: 240px;
  background: var(--primary);
  color: #fff;
  padding: 15px 30px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: sticky;
  top: 0;
  z-index: 998;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

.qr-header .saldo {
  font-size: 18px;
  font-weight: 600;
}
.qr-header .saldo small {
  display: block;
  font-size: 14px;
  opacity: 0.85;
}
.qr-header .actions {
  display: flex;
  align-items: center;
  gap: 20px;
}
.qr-header .actions button {
  background: transparent;
  border: none;
  color: #fff;
  cursor: pointer;
  font-size: 18px;
  transition: opacity 0.2s;
}
.qr-header .actions button:hover {
  opacity: 0.8;
}
.qr-header .user {
  font-size: 14px;
  font-weight: 500;
}

/* ======= CONTEÚDO ======= */
.qr-content {
  flex: 1;
  margin-left: 240px;
  padding: 25px;
}

.qr-card {
  background: #fff;
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  margin-bottom: 20px;
  transition: transform 0.2s ease-in-out;
}
.qr-card:hover {
  transform: translateY(-3px);
}

.qr-card h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 12px;
  color: var(--primary);
}

/* ======= WALLET ======= */
.qr-wallet table {
  width: 100%;
  border-collapse: collapse;
  border-radius: 8px;
  overflow: hidden;
}
.qr-wallet th, .qr-wallet td {
  padding: 12px;
  font-size: 14px;
}
.qr-wallet th {
  background: var(--primary);
  color: #fff;
  text-align: left;
}
.qr-wallet tr:nth-child(even) {
  background: #f9f9f9;
}

/* ======= RESPONSIVIDADE ======= */
@media (max-width: 991px) {
  .qr-sidebar {
    transform: translateX(-100%);
  }
  .qr-sidebar.open {
    transform: translateX(0);
  }
  .qr-header,
  .qr-content {
    margin-left: 0;
  }
  .qr-sidebar-toggle {
    display: block;
  }
}

@media (max-width: 600px) {
  .qr-header .saldo {
    font-size: 16px;
  }
  .qr-card {
    padding: 15px;
  }
  .qr-wallet th,
  .qr-wallet td {
    font-size: 12px;
    padding: 8px;
  }
}

/* ======= DARK MODE (opcional futuro) ======= */
body.dark-mode {
  background: #111827;
  color: #e5e7eb;
}
body.dark-mode .qr-card {
  background: #1f2937;
  color: #f3f4f6;
}
body.dark-mode .qr-sidebar {
  background: #0f172a;
}
body.dark-mode .qr-header {
  background: #1d4ed8;
}

/* ===============================================
   Ajuste de Contraste – Paleta Quatro Rios Invest
   =============================================== */

/* Cards e fundo */
.qr-card {
  background: #ffffff;
  border: 1px solid #e5e7eb;
  box-shadow: 0 2px 8px rgba(0, 47, 108, 0.08);
}
.qr-card h3,
.qr-card h5 {
  color: #002f6c;
}

/* Botões primários */
.btn-primary,
.qr-marketplace .qr-form button,
.qr-form button {
  background-color: #0046ad !important;
  border-color: #0046ad !important;
  color: #fff !important;
  font-weight: 600;
  border-radius: 6px;
  transition: background 0.2s ease-in-out;
}
.btn-primary:hover,
.qr-marketplace .qr-form button:hover {
  background-color: #002f6c !important;
  border-color: #002f6c !important;
}

/* Alertas e feedback */
.alert-success,
.notice-success {
  background-color: #1ab394;
  border-left: 5px solid #148f77;
  color: #fff;
  font-weight: 500;
  border-radius: 6px;
}
.alert-warning {
  background-color: #f39c12;
  color: #fff;
  border-radius: 6px;
}

/* Header (saldo) */
.qr-header {
  background: linear-gradient(90deg, #002f6c 0%, #0046ad 100%);
  color: #fff;
}
.qr-header .saldo span {
  background: #0046ad;
  padding: 6px 12px;
  border-radius: 6px;
  color: #fff;
  font-weight: 700;
}

/* Links e destaques */
a {
  color: #0046ad;
  text-decoration: none;
}
a:hover {
  color: #002f6c;
  text-decoration: underline;
}

/* Tabelas */
.table-primary th,
.qr-wallet th {
  background-color: #0046ad !important;
  color: #fff !important;
}
.table-striped tbody tr:nth-child(even) {
  background-color: #f9fbff;
}
