/* ==========================================================================
         GONAU ADMIN - GLASSMORPHISM & HIGH-DENSITY OPERATIONS
========================================================================== */
:root {
  --g-bg: #070707;
  --g-sidebar: rgba(14, 14, 14, 0.94);
  --g-glass: rgba(255, 255, 255, 0.03);
  --g-glass-header: rgba(255, 255, 255, 0.055);
  --g-border: rgba(255, 255, 255, 0.09);
  --g-border-hover: rgba(255, 255, 255, 0.28);
  --g-text: #f4f4f5;
  --g-muted: #8e8e93;
}

body {
  background: radial-gradient(circle at top right, #161616 0%, #070707 60%)
    fixed !important;
  color: var(--g-text) !important;
  font-family:
    "Inter",
    -apple-system,
    BlinkMacSystemFont,
    sans-serif !important;
  overflow-x: hidden;
}

/* --- TOPBAR MÓVIL --- */
.gonau-mobile-topbar {
  background: rgba(12, 12, 12, 0.94);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--g-border);
  z-index: 1030;
}

/* --- SIDEBAR DESKTOP (>= 768px) & OFFCANVAS MÓVIL (< 768px) --- */
@media (min-width: 768px) {
  .gonau-sidebar {
    position: fixed !important;
    top: 0;
    left: 0;
    width: 250px !important;
    height: 100vh !important;
    background: var(--g-sidebar) !important;
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border-right: 1px solid var(--g-border) !important;
    z-index: 1040 !important;
    overflow-y: auto;
    overflow-x: hidden;
  }

  .gonau-main-content {
    margin-left: 250px !important;
    width: calc(100% - 250px) !important;
    padding: 1.75rem 2.25rem !important;
    min-height: 100vh;
  }
}

@media (max-width: 767.98px) {
  .gonau-sidebar.offcanvas-md {
    width: 275px !important;
    background: #0e0e0e !important;
    border-right: 1px solid var(--g-border-hover) !important;
    overflow-y: auto;
  }

  .gonau-main-content {
    margin-left: 0 !important;
    width: 100% !important;
    padding: 1rem !important;
    min-height: calc(100vh - 52px);
  }
}

.gonau-sidebar::-webkit-scrollbar {
  width: 4px;
}
.gonau-sidebar::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.15);
  border-radius: 4px;
}

.gonau-brand-header {
  letter-spacing: 4px;
  font-weight: 700;
  font-size: 1.05rem;
  color: #ffffff;
  padding: 0.75rem 0.5rem;
  border-bottom: 1px solid var(--g-border);
}

.gonau-sidebar .nav-link {
  color: var(--g-muted) !important;
  font-size: 0.84rem;
  font-weight: 500;
  padding: 0.58rem 0.75rem !important;
  border-radius: 10px;
  margin-bottom: 3px;
  display: flex;
  align-items: center;
  width: 100%;
  transition:
    background-color 0.18s ease,
    color 0.18s ease;
}

.gonau-sidebar .nav-link:hover,
.gonau-sidebar .nav-link[aria-expanded="true"] {
  background: rgba(255, 255, 255, 0.08) !important;
  color: #ffffff !important;
}

.gonau-sidebar .nav-link i:first-child {
  font-size: 1rem !important;
  width: 22px;
  text-align: center;
  flex-shrink: 0;
}

/* Submenú vertical sin salto horizontal durante animación */
.gonau-submenu {
  display: block;
  width: 100%;
  padding-left: 0.5rem;
  margin-bottom: 4px;
}

.gonau-submenu li {
  display: block;
  width: 100%;
}

.gonau-submenu .nav-link {
  display: block !important;
  font-size: 0.8rem;
  padding: 0.45rem 0.75rem 0.45rem 2.1rem !important;
  color: #a1a1aa !important;
  white-space: normal;
}

.gonau-submenu .nav-link:hover {
  color: #ffffff !important;
  background: rgba(255, 255, 255, 0.05) !important;
}

/* --- TARJETAS GLASSMORPHISM ESTILO GONAU --- */
.card,
.table-card {
  background: var(--g-glass) !important;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--g-border) !important;
  border-radius: 16px !important;
  color: var(--g-text) !important;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.55) !important;
}

.card-header {
  background: var(--g-glass-header) !important;
  border-bottom: 1px solid var(--g-border) !important;
  padding: 1.1rem 1.4rem !important;
  color: #ffffff !important;
}

.card-header h5,
.card-header h4 {
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin: 0;
}

/* --- TABLAS LIMPIAS DE ALTA DENSIDAD --- */
.table {
  --bs-table-bg: transparent !important;
  --bs-table-color: var(--g-text) !important;
  --bs-table-border-color: var(--g-border) !important;
  --bs-table-striped-bg: rgba(255, 255, 255, 0.018) !important;
  --bs-table-striped-color: var(--g-text) !important;
  --bs-table-hover-bg: rgba(255, 255, 255, 0.05) !important;
  --bs-table-hover-color: #ffffff !important;
  font-size: 0.86rem;
  margin-bottom: 0;
}

.table thead,
.table thead.bg-body,
.table thead.table-dark {
  background: rgba(255, 255, 255, 0.04) !important;
}

.table thead th {
  background: transparent !important;
  color: var(--g-muted) !important;
  font-size: 0.7rem !important;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  padding: 0.95rem 0.85rem !important;
  border-bottom: 1px solid var(--g-border-hover) !important;
  white-space: nowrap;
}

.table tbody td {
  padding: 0.85rem 0.85rem !important;
  vertical-align: middle;
  border-bottom: 1px solid var(--g-border) !important;
}

.table tbody img {
  border-radius: 10px;
  border: 1px solid var(--g-border-hover);
  object-fit: cover;
  background: #000;
}

/* --- INPUTS Y BUSCADORES ESTILO GONAU --- */
.form-control,
.form-select,
.input-group-text {
  background: rgba(255, 255, 255, 0.04) !important;
  border: 1px solid rgba(255, 255, 255, 0.16) !important;
  color: #ffffff !important;
  font-size: 0.85rem;
  border-radius: 10px;
}

.form-control:focus,
.form-select:focus {
  background: rgba(255, 255, 255, 0.07) !important;
  border-color: #ffffff !important;
  box-shadow: 0 0 14px rgba(255, 255, 255, 0.15) !important;
}

.form-select option {
  background-color: #141414;
  color: #ffffff;
}

.input-group > .input-group-text {
  border-top-right-radius: 0 !important;
  border-bottom-right-radius: 0 !important;
  color: var(--g-muted) !important;
}

.input-group > .form-control:not(:last-child) {
  border-radius: 0 !important;
}

.input-group > .btn:last-child {
  border-top-left-radius: 0 !important;
  border-bottom-left-radius: 0 !important;
}

/* --- BOTONES CÁPSULA & MONOCROMÁTICOS GONAU --- */
.btn {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  border-radius: 50px;
  padding: 0.5rem 1.15rem;
  transition: all 0.2s ease;
}

.btn-success,
.btn-primary,
.btn-info {
  background: #ffffff !important;
  border: 1px solid #ffffff !important;
  color: #000000 !important;
}

.btn-success:hover,
.btn-primary:hover,
.btn-info:hover {
  background: #e4e4e7 !important;
  border-color: #e4e4e7 !important;
  color: #000000 !important;
  box-shadow: 0 0 16px rgba(255, 255, 255, 0.35);
}

.btn-outline-success,
.btn-outline-info,
.btn-outline-primary,
.btn-outline-light,
.btn-light {
  background: rgba(255, 255, 255, 0.05) !important;
  border: 1px solid rgba(255, 255, 255, 0.22) !important;
  color: #ffffff !important;
}

.btn-outline-success:hover,
.btn-outline-info:hover,
.btn-outline-primary:hover,
.btn-outline-light:hover,
.btn-light:hover {
  background: #ffffff !important;
  border-color: #ffffff !important;
  color: #000000 !important;
  box-shadow: 0 0 16px rgba(255, 255, 255, 0.35);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.08) !important;
  border: 1px solid rgba(255, 255, 255, 0.15) !important;
  color: #ffffff !important;
}

/* --- DROPDOWNS, MODALS & OFFCANVAS GLASS --- */
.dropdown-menu {
  background: rgba(18, 18, 18, 0.96) !important;
  backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.18) !important;
  border-radius: 12px !important;
  padding: 0.45rem !important;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.85) !important;
}

.dropdown-item {
  color: #e4e4e7 !important;
  font-size: 0.8rem;
  border-radius: 8px;
  padding: 0.5rem 0.85rem;
}

.dropdown-item:hover {
  background: rgba(255, 255, 255, 0.1) !important;
  color: #ffffff !important;
}

.modal-content,
.offcanvas {
  background: rgba(15, 15, 15, 0.96) !important;
  backdrop-filter: blur(18px);
  border: 1px solid rgba(255, 255, 255, 0.16) !important;
  color: #ffffff !important;
}

.modal-header,
.offcanvas-header {
  border-bottom: 1px solid var(--g-border) !important;
}

.modal-footer {
  border-top: 1px solid var(--g-border) !important;
}

.btn-close {
  filter: invert(1) grayscale(100%) brightness(200%);
}

/* --- PAGINACIÓN ESTILO GONAU --- */
.pagination {
  gap: 4px;
}

.pagination .page-link {
  background: rgba(255, 255, 255, 0.04) !important;
  border: 1px solid rgba(255, 255, 255, 0.16) !important;
  color: #ffffff !important;
  border-radius: 8px !important;
  font-size: 0.8rem;
  padding: 0.45rem 0.85rem;
}

.pagination .page-item.active .page-link {
  background: #ffffff !important;
  border-color: #ffffff !important;
  color: #000000 !important;
  font-weight: 700;
}

.pagination .page-link:hover {
  background: rgba(255, 255, 255, 0.15) !important;
}

.text-muted {
  color: var(--g-muted) !important;
}

.bg-light,
.bg-body {
  background: rgba(255, 255, 255, 0.04) !important;
  color: #ffffff !important;
}
