/* 🎨 Paleta institucional */
:root {
  --primary-color: #2e7d32;
  --secondary-color: #002b5c;
  --highlight-color: #8B0000;
  --icon-color: #0f0f0f;
}

/* 🧱 Estructura base del documento */
html, body {
  height: 100%;
  overflow-y: auto;
}

.layout-body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  background-color: #f8f9fa;
}

/* 💻 Área principal de contenido */
.main-content {
  margin-left: 240px;
  margin-top: 56px;
  padding: 2rem 1rem;
  flex-grow: 1;
  background-color: #ffffff;
  overflow-x: hidden;
}

/* 🔝 Navbar institucional */
.navbar-germany {
  background-color: var(--primary-color);
  color: white;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1030;
  width: 100%;
}

.navbar-germany .bi-box-fill,
.navbar-germany .text-dark,
.navbar-germany .btn-outline-dark {
  color: white !important;
  border-color: white;
}

/* 🧾 Branding institucional */
.logo-cde {
  color: var(--highlight-color);
  font-weight: bold;
  font-size: 1.2rem;
  letter-spacing: 0.5px;
  text-shadow: 0 0 2px rgba(0,0,0,0.25);
  -webkit-text-fill-color: var(--highlight-color);
  -webkit-text-stroke: 0.2px rgba(0, 0, 0, 0.2);
}

.logo-hides {
  color: var(--secondary-color);
  font-weight: 500;
}

/* 🖱️ Botones institucionales */
.btn-outline-dark {
  border-color: var(--secondary-color);
  color: var(--secondary-color);
}

.btn-outline-dark:hover {
  background-color: var(--secondary-color);
  color: #ffffff;
}

.btn-cde {
  background-color: var(--secondary-color);
  color: #ffffff;
  border-radius: 0.5rem;
  transition: background-color 0.25s ease-in-out;
}

.btn-cde:hover {
  background-color: var(--primary-color);
  color: var(--icon-color);
}

/* 📑 Formularios y títulos */
h1, h2, h3, h4 {
  color: var(--secondary-color);
}

select, input {
  border-color: var(--secondary-color);
}

.form-control {
  border-radius: 0.5rem;
  border: 1px solid var(--secondary-color);
}

.form-label i {
  margin-right: 6px;
  color: var(--secondary-color);
}

/* 📚 Sidebar institucional */
.sidebar {
  position: fixed;
  top: 56px;
  left: 0;
  bottom: 0;
  width: 240px;
  z-index: 1020;
  overflow-y: auto;
  background-color: var(--secondary-color);
  color: #ffffff;
  padding-top: 1rem;
}

.sidebar .nav-link {
  color: #ffffff;
  font-weight: 500;
  border-radius: 4px;
}

.sidebar .nav-link:hover,
.sidebar .nav-link:focus {
  background-color: rgba(255, 255, 255, 0.1);
}

.sidebar h6,
.sidebar small {
  color: #ffffff;
}

.sidebar .text-white-50 {
  color: #cccccc !important;
}

/* 🔚 Footer institucional */
footer {
  background-color: var(--primary-color);
  color: var(--secondary-color);
  font-size: 0.85rem;
}

/* 🌌 Fondo institucional solo para login */
.login-background {
  position: fixed;
  inset: 0;
  background: url("../../img/fondoinicial.jpg") center center / cover no-repeat;
  opacity: 0.18;
  filter: grayscale(80%) blur(2px);
  z-index: -1;
  pointer-events: none;
}

body {
  position: relative;
  z-index: 1;
}

/* 🧭 Contenedor centrado tipo modal */
.login-wrapper {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 2rem;
}

/* 💠 Modal visualmente elevado */
.login-modal {
  background-color: #ffffffee;
  border-radius: 1rem;
  box-shadow: 0 10px 30px rgba(0,0,0,0.15);
  backdrop-filter: blur(6px);
  padding: 2.5rem 2rem;
  max-width: 400px;
  width: 100%;
  text-align: center;
  z-index: 1;
}

/* 📝 Subtítulo y título del login */
.login-subtitle {
  font-size: 1rem;
  font-weight: 600;
  color: var(--secondary-color);
  margin-bottom: 0.5rem;
}

.login-title {
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  color: var(--icon-color);
}

.login-title span:first-child {
  color: var(--secondary-color);
}

.login-title span:last-child {
  color: var(--primary-color);
}

/* 🔗 Links de ayuda */
.forgot-password,
.change-site {
  display: block;
  font-size: 0.85rem;
  text-decoration: none;
  margin-top: 0.75rem;
}

.forgot-password {
  color: var(--secondary-color);
}

.forgot-password:hover {
  text-decoration: underline;
  color: var(--highlight-color);
}

.change-site {
  color: #6c757d;
}

.change-site:hover {
  text-decoration: underline;
  color: var(--secondary-color);
}

.btn-germany { background-color: #d4af37; }


/*@media (max-width: 768px) {
  #createLabelModal .modal-dialog {
    max-width: 100%;
    margin: 0;
  }

  #createLabelModal .modal-content {
    border-radius: 0;
    height: 100vh;
    max-height: 100vh;
  }

  #createLabelModal .modal-body {
    padding: 1rem;
    overflow-y: auto;
  }

  #createLabelModal .modal-header,
  #createLabelModal .modal-footer {
    padding: 1rem;
  }

  #createLabelModal .form-label {
    font-size: 0.9rem;
  }

  #createLabelModal .form-control,
  #createLabelModal .form-select {
    font-size: 0.9rem;
  }

  #createLabelModal .table-responsive {
    max-height: 200px;
  }

  #createLabelModal .btn {
    font-size: 0.9rem;
    padding: 0.4rem 0.8rem;
  }

  #createLabelModal h5 {
    font-size: 1rem;
  }
}*/

/* 🧾 Modal específico para etiquetas */
.modal-labels .modal-dialog {
  max-width: 90vw;
  max-height: 90vh;
}

.modal-labels .modal-content {
  height: 100%;
  display: flex;
  flex-direction: column;
}

.modal-labels .modal-body {
  overflow-y: auto;
  flex-grow: 1;
  padding: 1.5rem;
}

input[type="hidden"] {
  display: none !important;
}

input.temporarily-visible {
  position: absolute;
  left: -9999px;
}

.card-section {
  background-color: #fff;
  border: 1px solid #dee2e6;
  border-radius: 8px;
  padding: 1rem;
  margin-bottom: 1rem;
}

.form-label.small {
  font-size: 0.85rem;
  font-weight: 500;
}

.form-control-sm,
.form-select-sm {
  font-size: 0.85rem;
  padding: 0.375rem 0.5rem;
}

.section-box {
  border: 1px solid #dee2e6;
  border-radius: 8px;
  padding: 1rem;
  margin-bottom: 1rem;
  background-color: #fff;
}

.section-title {
  font-size: 0.9rem;
  font-weight: 600;
  color: #0d6efd;
  margin-bottom: 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.card-section {
  border: 1px solid #dee2e6;
  border-radius: 8px;
  padding: 1rem;
  margin-bottom: 1rem;
  background-color: #fff;
}

/* Estilo visual para etiquetas que fueron modificadas */
.updated-label {
  background-color: #e6f7ff;
  border-left: 4px solid #0d6efd;
}

.btn-outline-secondary {
  padding: 0 8px;
  font-size: 14px;
}

.preinvoice-wrapper {
  max-width: 1200px;
  margin: auto;
}

td.locked {
  background-color: #f8f9fa;
  color: #6c757d;
  pointer-events: none;
  user-select: none;
  font-style: italic;
}