/* =====================================================
   WHATS CLOUD - Premium Theme (Fase 1)
   Reaplica visual do mockup HTML sobre o SB Admin 2
   Incluído DEPOIS de sb-admin-2.min.css para sobrescrever
   ===================================================== */

:root {
  --wc-bg: #020813;
  --wc-bg2: #071324;
  --wc-card: #101827;
  --wc-card2: #111a27;
  --wc-input: #1c222c;
  --wc-border: #1d2738;
  --wc-muted: #9aa3b2;
  --wc-text: #f4f7fb;
  --wc-green: #10b45b;
  --wc-green2: #0a9348;
  --wc-blue: #2563eb;
  --wc-purple: #5a43f3;
  --wc-red: #d92d2d;
  --wc-orange: #f05a24;
  --wc-teal: #0aa58e;
  --wc-shadow: 0 20px 55px rgba(0, 0, 0, 0.5);
  --wc-radius: 22px;
}

/* ----- base ----- */
html, body {
  background:
    radial-gradient(circle at 18% 10%, rgba(17, 185, 84, 0.10), transparent 22%),
    radial-gradient(circle at 85% 8%, rgba(17, 185, 84, 0.08), transparent 18%),
    linear-gradient(180deg, #020711 0%, #030b17 45%, #020813 100%) !important;
  color: var(--wc-text) !important;
  font-family: Inter, system-ui, -apple-system, "Segoe UI", Arial, sans-serif !important;
  min-height: 100vh;
}

body, p, span, label, td, th, li, div {
  color: var(--wc-text);
}

p, .text-muted, .small, .text-gray-600, .text-gray-500, .text-gray-700, .text-gray-800, .text-gray-900 {
  color: var(--wc-muted) !important;
}

a { color: #79aefb; }
a:hover { color: #a8c8ff; }

h1, h2, h3, h4, h5, h6 {
  color: var(--wc-text) !important;
  font-weight: 850;
  letter-spacing: -0.3px;
}

/* ----- sidebar (drawer-like) ----- */
.sidebar,
ul.navbar-nav.sidebar,
ul.navbar-nav.sidebar.sidebar-success {
  background: linear-gradient(180deg, #081222, #080d16) !important;
  border-right: 1px solid #263044 !important;
  box-shadow: 30px 0 80px rgba(0, 0, 0, 0.45);
}

.sidebar .sidebar-brand {
  background: transparent !important;
  color: var(--wc-text) !important;
  padding: 26px 14px 18px;
  height: auto;
}

.sidebar .sidebar-brand-text {
  font-size: 16px;
  font-weight: 900;
  letter-spacing: 0.4px;
}

.sidebar .sidebar-brand-icon i,
.sidebar .navbar-brand-icon i {
  color: var(--wc-green) !important;
}

.sidebar hr.sidebar-divider {
  border-color: rgba(255, 255, 255, 0.06) !important;
  margin: 6px 18px 14px !important;
}

.sidebar .nav-item {
  margin: 6px 12px;
}

.sidebar .nav-item .nav-link {
  border-radius: 14px;
  background: #101724;
  color: #dce2ea !important;
  font-size: 14px;
  font-weight: 600;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.sidebar .nav-item .nav-link i {
  color: #9aa3b2 !important;
  width: 22px;
  text-align: center;
}

.sidebar .nav-item .nav-link .wc-emoji,
.sidebar .nav-item .nav-link .wc-emoji-img {
  display: inline-block;
  width: 26px;
  font-size: 20px;
  line-height: 1;
  text-align: center;
  flex: 0 0 26px;
}

.wc-emoji-h {
  display: inline-block;
  margin-right: 8px;
  font-size: 0.95em;
  vertical-align: -1px;
}

.stat-emoji {
  display: inline-block;
  margin-right: 6px;
  font-size: 16px;
  vertical-align: -1px;
}

.sidebar .nav-item .nav-link:hover {
  background: #182338;
  color: #ffffff !important;
}

.sidebar .nav-item .nav-link.active,
.sidebar .nav-item.active .nav-link {
  background: var(--wc-green) !important;
  color: #062111 !important;
  font-weight: 900;
}

.sidebar .nav-item .nav-link.active i {
  color: #062111 !important;
}

.sidebar-success .sidebar-brand,
.sidebar-success .sidebar-heading {
  color: #ffffff !important;
}

/* ----- topbar ----- */
.navbar.topbar {
  background: rgba(8, 14, 26, 0.85) !important;
  border-bottom: 1px solid var(--wc-border) !important;
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.35) !important;
  min-height: 64px;
  backdrop-filter: blur(8px);
}

.topbar .nav-link,
.topbar .nav-link:focus {
  color: var(--wc-text) !important;
}

.topbar .topbar-divider {
  border-color: rgba(255, 255, 255, 0.08) !important;
}

.topbar .img-profile {
  width: 36px;
  height: 36px;
  border: 2px solid var(--wc-green);
  background: #1c222c;
}

.topbar .navbar-brand-text {
  color: var(--wc-text) !important;
  font-weight: 900;
}

.topbar #sidebarToggleTop {
  color: var(--wc-text) !important;
}

/* ----- content wrapper ----- */
#content-wrapper {
  background: transparent !important;
}

#content {
  background: transparent !important;
}

.container-fluid {
  padding: 24px 28px 96px;
}

/* ----- cards ----- */
.card {
  background: linear-gradient(180deg, rgba(18, 25, 38, 0.95), rgba(12, 18, 28, 0.95)) !important;
  border: 1px solid var(--wc-border) !important;
  border-radius: var(--wc-radius) !important;
  color: var(--wc-text) !important;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.18);
  margin-bottom: 22px;
}

.card-header {
  background: transparent !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
  color: var(--wc-text) !important;
  font-weight: 800;
  padding: 18px 22px;
}

.card-body {
  color: var(--wc-text) !important;
  padding: 20px 22px;
}

.card.glow,
.card.border-left-success {
  border-left: 4px solid var(--wc-green) !important;
  background: linear-gradient(145deg, rgba(14, 35, 33, 0.86), rgba(14, 20, 32, 0.9)) !important;
}

.card.border-left-primary { border-left: 4px solid var(--wc-blue) !important; }
.card.border-left-info    { border-left: 4px solid #0aa58e !important; }
.card.border-left-warning { border-left: 4px solid var(--wc-orange) !important; }
.card.border-left-danger  { border-left: 4px solid var(--wc-red) !important; }

/* ----- alerts ----- */
.alert {
  border-radius: 16px !important;
  border: 1px solid transparent !important;
  font-weight: 600;
}

.alert-info {
  background: rgba(10, 165, 142, 0.12) !important;
  border-color: rgba(10, 165, 142, 0.35) !important;
  color: #b5f0e3 !important;
}

.alert-success {
  background: rgba(16, 180, 91, 0.12) !important;
  border-color: rgba(16, 180, 91, 0.4) !important;
  color: #b6f4cf !important;
}

.alert-warning {
  background: rgba(240, 90, 36, 0.12) !important;
  border-color: rgba(240, 90, 36, 0.4) !important;
  color: #ffd0b8 !important;
}

.alert-danger {
  background: rgba(217, 45, 45, 0.12) !important;
  border-color: rgba(217, 45, 45, 0.4) !important;
  color: #ffc7c7 !important;
}

/* ----- forms ----- */
.form-control,
input.form-control,
textarea.form-control,
select.form-control,
.custom-select {
  background: var(--wc-input) !important;
  border: 1px solid transparent !important;
  border-radius: 14px !important;
  color: var(--wc-text) !important;
  padding: 14px 16px !important;
  height: auto !important;
  transition: 0.18s;
}

.form-control:focus,
.custom-select:focus {
  border-color: #1c69ff !important;
  background: var(--wc-input) !important;
  color: var(--wc-text) !important;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.22), 0 0 22px rgba(37, 99, 235, 0.2) !important;
}

.form-control::placeholder { color: #7f8796 !important; }

textarea.form-control { min-height: 110px; resize: vertical; }

label, .form-group label {
  color: #d8dde7 !important;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 8px;
}

.input-group-text {
  background: var(--wc-input) !important;
  border: 1px solid transparent !important;
  color: var(--wc-text) !important;
  border-radius: 14px !important;
}

.custom-file-label {
  background: var(--wc-input) !important;
  border-radius: 14px !important;
  color: var(--wc-text) !important;
  border-color: transparent !important;
}

/* ----- buttons ----- */
.btn {
  border-radius: 14px !important;
  padding: 12px 18px !important;
  font-weight: 800 !important;
  letter-spacing: 0.2px;
  transition: filter 0.15s, transform 0.15s;
  border: 0 !important;
}

.btn:hover { filter: brightness(1.08); }
.btn:active { transform: scale(0.985); }

.btn-primary, .btn-info {
  background: var(--wc-blue) !important;
  color: #ffffff !important;
}

.btn-success {
  background: var(--wc-green) !important;
  color: #062111 !important;
}

.btn-warning {
  background: var(--wc-orange) !important;
  color: #ffffff !important;
}

.btn-danger {
  background: linear-gradient(135deg, #c71924, #ef4444) !important;
  color: #ffffff !important;
}

.btn-secondary, .btn-light, .btn-default {
  background: #35404d !important;
  color: var(--wc-text) !important;
}

.btn-link {
  color: #79aefb !important;
  font-weight: 700;
}

.btn-purple { background: var(--wc-purple) !important; color: #fff !important; }
.btn-teal   { background: linear-gradient(135deg, #039982, #13b8a5) !important; color: #fff !important; }
.btn-orange { background: var(--wc-orange) !important; color: #fff !important; }

/* ----- tables ----- */
.table, .dataTable {
  color: var(--wc-text) !important;
  background: transparent !important;
}

.table thead th {
  background: rgba(255, 255, 255, 0.03) !important;
  color: #aab2bd !important;
  border-bottom: 1px solid var(--wc-border) !important;
  font-weight: 700;
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 0.6px;
  padding: 14px 12px;
}

.table tbody td {
  border-color: rgba(255, 255, 255, 0.05) !important;
  padding: 14px 12px;
  vertical-align: middle;
}

.table-hover tbody tr:hover {
  background: rgba(255, 255, 255, 0.03) !important;
  color: var(--wc-text) !important;
}

.table tbody tr {
  background: transparent !important;
}

.table-striped tbody tr:nth-of-type(odd) {
  background: rgba(255, 255, 255, 0.015) !important;
}

/* DataTables controls */
.dataTables_wrapper .dataTables_length select,
.dataTables_wrapper .dataTables_filter input {
  background: var(--wc-input) !important;
  border: 1px solid transparent !important;
  border-radius: 10px !important;
  color: var(--wc-text) !important;
  padding: 6px 12px !important;
}

.dataTables_wrapper .dataTables_info,
.dataTables_wrapper .dataTables_length,
.dataTables_wrapper .dataTables_filter,
.dataTables_wrapper .dataTables_paginate {
  color: var(--wc-muted) !important;
  margin: 10px 0;
}

.dataTables_wrapper .paginate_button {
  background: var(--wc-input) !important;
  border: 1px solid var(--wc-border) !important;
  border-radius: 8px !important;
  color: var(--wc-text) !important;
  margin: 0 3px;
}

.dataTables_wrapper .paginate_button.current,
.dataTables_wrapper .paginate_button.current:hover {
  background: var(--wc-green) !important;
  border-color: var(--wc-green) !important;
  color: #062111 !important;
}

/* ----- modals ----- */
.modal-content {
  background: linear-gradient(180deg, #131c2c, #0c1320) !important;
  border: 1px solid var(--wc-border) !important;
  border-radius: 24px !important;
  color: var(--wc-text) !important;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
}

.modal-header {
  border-bottom-color: rgba(255, 255, 255, 0.06) !important;
  padding: 20px 24px;
}

.modal-footer {
  border-top-color: rgba(255, 255, 255, 0.06) !important;
  padding: 16px 24px;
}

.modal-title { color: var(--wc-text) !important; font-weight: 900; }

.close, .modal .close {
  color: var(--wc-text) !important;
  opacity: 0.7;
  text-shadow: none;
}

/* ----- badges & pills ----- */
.badge {
  border-radius: 999px !important;
  padding: 6px 12px !important;
  font-weight: 800 !important;
  font-size: 12px !important;
}

.badge-success { background: var(--wc-green) !important; color: #062111 !important; }
.badge-primary { background: var(--wc-blue) !important; color: #fff !important; }
.badge-danger  { background: var(--wc-red) !important;  color: #fff !important; }
.badge-warning { background: var(--wc-orange) !important; color: #fff !important; }
.badge-info    { background: var(--wc-teal) !important; color: #fff !important; }

/* ----- dropdowns ----- */
.dropdown-menu {
  background: #111a27 !important;
  border: 1px solid var(--wc-border) !important;
  border-radius: 16px !important;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.55) !important;
  padding: 8px;
}

.dropdown-item {
  color: var(--wc-text) !important;
  border-radius: 10px;
  padding: 10px 12px;
}

.dropdown-item:hover, .dropdown-item:focus {
  background: rgba(255, 255, 255, 0.05) !important;
  color: var(--wc-text) !important;
}

.dropdown-divider {
  border-color: rgba(255, 255, 255, 0.06) !important;
}

/* ----- footer ----- */
.sticky-footer,
.sticky-footer.bg-white {
  background: transparent !important;
  color: var(--wc-muted) !important;
  border-top: 1px solid rgba(255, 255, 255, 0.04);
  padding: 18px 0;
}

.sticky-footer .copyright {
  color: var(--wc-muted) !important;
}

/* ----- toastr (notif) ----- */
.toast-success { background-color: var(--wc-green) !important; color: #062111 !important; }
.toast-error   { background-color: var(--wc-red) !important; }
.toast-info    { background-color: var(--wc-teal) !important; }
.toast-warning { background-color: var(--wc-orange) !important; }

/* ----- select2 ----- */
.select2-container--default .select2-selection--single,
.select2-container--default .select2-selection--multiple {
  background: var(--wc-input) !important;
  border: 1px solid transparent !important;
  border-radius: 14px !important;
  min-height: 48px !important;
  color: var(--wc-text) !important;
  padding: 6px 10px !important;
}

.select2-container--default .select2-selection--single .select2-selection__rendered {
  color: var(--wc-text) !important;
  line-height: 36px !important;
}

.select2-dropdown {
  background: #111a27 !important;
  border: 1px solid var(--wc-border) !important;
  color: var(--wc-text) !important;
}

.select2-container--default .select2-results__option--highlighted[aria-selected] {
  background: var(--wc-green) !important;
  color: #062111 !important;
}

/* ----- progress ----- */
.progress {
  background: #182231 !important;
  border-radius: 999px !important;
  height: 10px !important;
}

.progress-bar { background: var(--wc-green) !important; }

/* ----- code blocks ----- */
pre, code {
  background: #121925 !important;
  color: #e9eef8 !important;
  border-radius: 12px;
  padding: 10px 14px;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

/* ----- borda padrão ----- */
hr {
  border-color: rgba(255, 255, 255, 0.06) !important;
}

/* ----- topbar dropdown user name ----- */
.topbar .text-gray-600 {
  color: #d8dde7 !important;
}

/* ----- mobile / sidebar toggle ----- */
@media (max-width: 768px) {
  .container-fluid { padding: 16px 14px 80px; }
  .sidebar.toggled { width: 0 !important; }
}

/* =====================================================
   LOGIN / REGISTER (auth/*.php) - premium look
   ===================================================== */
body.wc-auth {
  min-height: 100vh;
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 30px 18px;
}

.wc-auth-shell {
  width: 100%;
  max-width: 520px;
}

.wc-auth-card {
  background: rgba(13, 20, 28, 0.84);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 36px;
  padding: 46px 32px 36px;
  box-shadow: var(--wc-shadow);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.wc-auth-title {
  text-align: center;
  font-size: clamp(36px, 9vw, 52px);
  font-weight: 950;
  letter-spacing: -1.5px;
  color: var(--wc-text);
  margin: 0 0 8px;
  line-height: 1;
}

.wc-auth-subtitle {
  text-align: center;
  color: var(--wc-muted) !important;
  font-size: 17px;
  margin: 0 0 30px;
  font-weight: 500;
}

.wc-auth-card label {
  display: block;
  color: #d8dde7 !important;
  margin: 18px 0 8px;
  font-size: 16px;
  font-weight: 500;
}

.wc-auth-card input {
  width: 100%;
  background: var(--wc-input) !important;
  border: 1px solid transparent !important;
  border-radius: 16px !important;
  padding: 17px 20px !important;
  color: var(--wc-text) !important;
  font-size: 16px;
  outline: none;
  transition: 0.18s;
  height: auto !important;
}

.wc-auth-card input:focus {
  border-color: #1c69ff !important;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.22), 0 0 22px rgba(37, 99, 235, 0.2) !important;
}

.wc-auth-card .wc-btn-primary {
  display: block;
  width: 100%;
  border: 0;
  border-radius: 18px;
  padding: 18px;
  color: #ffffff !important;
  font-weight: 900;
  font-size: 18px;
  letter-spacing: 0.6px;
  text-align: center;
  text-decoration: none !important;
  background: linear-gradient(180deg, #16c764, #0e9b4d);
  margin-top: 28px;
  cursor: pointer;
  transition: filter 0.15s, transform 0.15s;
  box-shadow: 0 12px 32px rgba(14, 155, 77, 0.35);
  box-sizing: border-box;
}

.wc-auth-card .wc-btn-primary:hover {
  filter: brightness(1.08);
  color: #ffffff !important;
  text-decoration: none !important;
}
.wc-auth-card .wc-btn-primary:active { transform: scale(0.985); }

.wc-auth-footer {
  text-align: center;
  color: #8b93a0 !important;
  margin-top: 26px;
  font-size: 15px;
}

.wc-auth-footer a {
  color: #79aefb;
  font-weight: 700;
  text-decoration: none;
}

.wc-auth-footer a:hover { color: #a8c8ff; }
