/*
 * This is a manifest file that'll be compiled into application.css, which will include all the files
 * listed below.
 *
 * Any CSS (and SCSS, if configured) file within this directory, lib/assets/stylesheets, or any plugin's
 * vendor/assets/stylesheets directory can be referenced here using a relative path.
 *
 * You're free to add application-wide styles to this file and they'll appear at the bottom of the
 * compiled file so the styles you add here take precedence over styles defined in any other CSS
 * files in this directory. Styles in this file should be added after the last require_* statement.
 * It is generally better to create a new file per style scope.
 *


 */

 .form-signin {
    max-width: 330px;
    padding: 15px;
    margin: auto;
  }
  .form-signin img {
    margin-bottom: 20px;
  }
  .form-floating {
    margin-bottom: 15px;
  }

/* ==========================================================================
   Tema GG — alineado con el lenguaje visual de las otras apps del grupo
   (wood, gg_creditos, TM-GG): fondo slate, tarjetas blancas, Inter, acentos
   en el azul-verdoso institucional.
   ========================================================================== */

:root {
  --gg-bg: #f8fafc;
  --gg-surface: #ffffff;
  --gg-border: #e2e8f0;
  --gg-border-soft: #f1f5f9;
  --gg-text: #1e293b;
  --gg-text-muted: #64748b;
  --gg-text-faint: #94a3b8;
  --gg-brand: #1f4e5f;
  --gg-brand-dark: #163a47;
  --gg-brand-light: #2f7488;
  --gg-accent: #c8a24a;
  --gg-radius-lg: 0.75rem;
  --gg-radius-md: 0.5rem;
  --gg-sidebar-width: 260px;
  --gg-topbar-height: 56px;
}

html, body {
  height: 100%;
}

body {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background-color: var(--gg-bg);
  color: var(--gg-text);
  font-size: 0.875rem;
}

a {
  color: var(--gg-brand);
}
a:hover {
  color: var(--gg-brand-dark);
}

/* Bootstrap parte de 2.5rem/2rem/1.75rem para h1-h3: en pantallas de
   reporte con muchas tablas quedaba desproporcionado frente al contenido. */
h1, h2, h3, h4, h5, h6 {
  color: var(--gg-text);
  font-weight: 600;
}
h1 { font-size: 1.5rem; }
h2 { font-size: 1.25rem; }
h3 { font-size: 1.1rem; }
h4, h5, h6 { font-size: 1rem; }

/* ---- App shell: sidebar + topbar --------------------------------------- */

.app-shell {
  display: flex;
  min-height: 100vh;
}

.app-sidebar {
  width: var(--gg-sidebar-width);
  background-color: var(--gg-surface);
  border-right: 1px solid var(--gg-border);
  display: flex;
  flex-direction: column;
  align-self: flex-start;
}

@media (min-width: 768px) {
  .app-sidebar {
    position: sticky;
    top: 0;
    height: 100vh;
  }
}

.app-sidebar.offcanvas-md {
  --bs-offcanvas-width: var(--gg-sidebar-width);
}

.app-sidebar-brand {
  padding: 1.1rem 1.25rem;
  border-bottom: 1px solid var(--gg-border-soft);
}
.app-brand-block {
  min-width: 0;
}
.app-brand-logo {
  display: block;
  height: auto;
  width: 140px;
  max-width: 100%;
}
.app-sidebar-brand .title {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gg-brand);
  margin: 0.3rem 0 0;
}

.app-sidebar-nav {
  flex: 1 1 auto;
  overflow-y: auto;
  padding: 0.75rem 0.65rem;
}

.app-nav-group {
  margin-bottom: 0.5rem;
}
.app-nav-group-label {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gg-text-faint);
  padding: 0.5rem 0.6rem 0.35rem;
  margin: 0;
}

.app-nav-link {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.45rem 0.6rem;
  border-radius: var(--gg-radius-md);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--gg-text-muted);
  text-decoration: none;
  white-space: nowrap;
}
.app-nav-link > span:not(.badge) {
  overflow: hidden;
  text-overflow: ellipsis;
}
.app-nav-link .badge {
  flex-shrink: 0;
}
.app-nav-link i {
  font-size: 0.95rem;
  width: 1.1rem;
  text-align: center;
  flex-shrink: 0;
  color: var(--gg-text-faint);
}
.app-nav-link:hover {
  background-color: var(--gg-border-soft);
  color: var(--gg-text);
}
.app-nav-link.active {
  background-color: #eef3f4;
  color: var(--gg-brand);
}
.app-nav-link.active i {
  color: var(--gg-brand);
}

.app-nav-sublist {
  margin: 0.15rem 0 0.35rem 1.75rem;
  padding-left: 0.5rem;
  border-left: 1px solid var(--gg-border-soft);
}
.app-nav-sublist .app-nav-link {
  font-size: 0.8rem;
  padding: 0.3rem 0.5rem;
}

.app-nav-toggle {
  width: 100%;
  background: none;
  border: none;
  cursor: pointer;
}
.app-nav-toggle .bi-chevron-down {
  transition: transform 0.15s ease;
  font-size: 0.7rem !important;
  color: var(--gg-text-faint) !important;
  margin-left: auto;
}
.app-nav-toggle[aria-expanded="false"] .bi-chevron-down {
  transform: rotate(-90deg);
}

.app-sidebar-footer {
  padding: 0.75rem 1rem;
  border-top: 1px solid var(--gg-border-soft);
}
.app-sidebar-footer form {
  margin: 0;
}
.app-sidebar-footer button {
  width: 100%;
  text-align: left;
  padding: 0.4rem 0.5rem !important;
}

.app-main {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.app-topbar {
  height: var(--gg-topbar-height);
  background-color: var(--gg-surface);
  border-bottom: 1px solid var(--gg-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.25rem;
  flex-shrink: 0;
}
.app-topbar .btn-sidebar-toggle {
  border: none;
  background: none;
  font-size: 1.25rem;
  color: var(--gg-text-muted);
  padding: 0.25rem 0.5rem;
}

.app-content {
  flex: 1 1 auto;
  padding: 1.5rem;
  max-width: 100%;
}

@media (min-width: 768px) {
  .app-content {
    padding: 1.75rem 2rem;
  }
}

/* ---- Componentes Bootstrap reskineados ---------------------------------- */

.card {
  border: 1px solid var(--gg-border);
  border-radius: var(--gg-radius-lg);
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}
.card-header {
  border-bottom: 1px solid var(--gg-border-soft);
  background-color: var(--gg-surface);
}
.card-header.bg-primary {
  background-color: var(--gg-brand) !important;
  border-color: var(--gg-brand);
}

.table {
  background-color: var(--gg-surface);
  border: 1px solid var(--gg-border);
  border-radius: var(--gg-radius-lg);
  overflow: hidden;
  border-collapse: separate;
  border-spacing: 0;
}
.table thead th {
  background-color: #f8fafc;
  border-bottom: 1px solid var(--gg-border);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--gg-text-muted);
}
.table td, .table th {
  border-color: var(--gg-border-soft);
  vertical-align: middle;
}
.table tbody tr:hover {
  background-color: #f8fafc;
}
.table thead tr:first-child th:first-child { border-top-left-radius: var(--gg-radius-lg); }
.table thead tr:first-child th:last-child { border-top-right-radius: var(--gg-radius-lg); }
.table tbody tr:last-child td:first-child { border-bottom-left-radius: var(--gg-radius-lg); }
.table tbody tr:last-child td:last-child { border-bottom-right-radius: var(--gg-radius-lg); }

.btn {
  border-radius: var(--gg-radius-md);
  font-weight: 500;
}
.btn-primary {
  background-color: var(--gg-brand);
  border-color: var(--gg-brand);
}
.btn-primary:hover, .btn-primary:focus, .btn-primary:active {
  background-color: var(--gg-brand-dark) !important;
  border-color: var(--gg-brand-dark) !important;
}
.btn-outline-primary {
  color: var(--gg-brand);
  border-color: var(--gg-brand);
}
.btn-outline-primary:hover {
  background-color: var(--gg-brand);
  border-color: var(--gg-brand);
}
.btn-link {
  color: var(--gg-brand);
}

.form-control, .form-select {
  border-radius: var(--gg-radius-md);
  border-color: var(--gg-border);
}
.form-control:focus, .form-select:focus {
  border-color: var(--gg-brand-light);
  box-shadow: 0 0 0 0.2rem rgba(31, 78, 95, 0.12);
}

.badge {
  border-radius: 999px;
  font-weight: 500;
}

.alert {
  border-radius: var(--gg-radius-md);
  border: 1px solid transparent;
}

.nav-tabs .nav-link.active {
  color: var(--gg-brand);
  border-bottom-color: var(--gg-brand);
}

.pagination .page-link {
  color: var(--gg-brand);
}
.pagination .page-item.active .page-link {
  background-color: var(--gg-brand);
  border-color: var(--gg-brand);
}

footer.app-footer {
  background-color: var(--gg-surface);
  border-top: 1px solid var(--gg-border);
  color: var(--gg-text-faint);
  font-size: 0.8rem;
}
