.corner-button {
  font-family: 'Lato', sans-serif;
  letter-spacing: .02rem;
  cursor: pointer;
  background: transparent;
  border: 0.5rem solid currentColor;
  padding: 1.5rem 2rem;
  font-size: 1.2rem;
  color: rgb(86, 140, 29);
  position: relative;
  -webkit-transition: color 0.3s;
  transition: color 0.3s;
}
.corner-button:hover {
  color: rgb(201, 251, 74);
}
.corner-button:hover::before {
  width: 0;
}
.corner-button:hover::after {
  height: 0;
}
.corner-button:active {
  border-width: 0.25rem;
}
.corner-button span {
  position: relative;
  z-index: 2;
}
.corner-button::before, .corner-button::after {
  content: '';
  position: absolute;
  background: white;
  /* color: rgb(86, 140, 29); */
  color: black;
  /* background: transparent; */
  z-index: 1;
  -webkit-transition: all 0.3s;
  transition: all 0.3s;
}
.corner-button::before {
  width: calc(100% - 3rem);
  height: calc(101% + 1rem);
  top: -0.5rem;
  left: 50%;
  -webkit-transform: translateX(-50%);
          transform: translateX(-50%);
}
.corner-button::after {
  height: calc(100% - 3rem);
  width: calc(101% + 1rem);
  left: -0.5rem;
  top: 50%;
  -webkit-transform: translateY(-50%);
          transform: translateY(-50%);
}
#pdfContainer {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

#firma-wrapper {
    position: absolute;
    top: 200px;
    left: 200px;
    z-index: 20;
    display: none;
    transform-origin: top left;
    cursor: move;
}

/* ============================================================
   📱 MENÚ HAMBURGUESA MÓVIL - CUENTA FÁCIL
   ============================================================ */

/* Botón hamburguesa - solo visible en móvil */
#btnMenuMobile {
    display: none;
    background: linear-gradient(145deg, #ffffff, #f1f3f6);
    border: none;
    border-radius: 50%;
    width: 42px;
    height: 42px;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    transition: all 0.2s ease-in-out;
    flex-shrink: 0;
}

#btnMenuMobile:hover {
    transform: scale(1.1);
    background: linear-gradient(145deg, #f7fafc, #e9eef5);
}

#btnMenuMobile i {
    font-size: 20px;
    color: #198754;
    transition: all 0.3s ease;
}

/* Overlay oscuro semitransparente */
#mobileMenuOverlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.45);
    z-index: 10000;
    backdrop-filter: blur(2px);
    animation: overlayFadeIn 0.3s ease;
}

@keyframes overlayFadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

/* Panel lateral (Drawer) */
#mobileMenuDrawer {
    position: fixed;
    top: 0;
    right: -300px;
    width: 280px;
    height: 100%;
    background: linear-gradient(180deg, #ffffff 0%, #f8fffe 100%);
    z-index: 10001;
    box-shadow: -4px 0 24px rgba(0, 0, 0, 0.18);
    transition: right 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

#mobileMenuDrawer.open {
    right: 0;
}

/* Cabecera del drawer */
.drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 20px;
    border-bottom: 1px solid rgba(25, 135, 84, 0.15);
    background: linear-gradient(135deg, #198754 0%, #28a745 100%);
}

.drawer-header-title {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #ffffff;
    font-weight: 700;
    font-size: 1rem;
    letter-spacing: 0.5px;
}

.drawer-header-title i {
    font-size: 18px;
}

/* Botón cerrar del drawer */
#btnCloseDrawer {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s ease;
    color: #ffffff;
}

#btnCloseDrawer:hover {
    background: rgba(255, 255, 255, 0.35);
}

#btnCloseDrawer i {
    font-size: 16px;
}

/* Lista de ítems del menú dentro del drawer */
.drawer-menu-list {
    list-style: none;
    padding: 12px 0;
    margin: 0;
    flex: 1;
}

.drawer-menu-item {
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.drawer-menu-link {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 15px 22px;
    text-decoration: none;
    color: #333;
    font-size: 0.95rem;
    font-weight: 500;
    transition: all 0.2s ease;
    cursor: pointer;
}

.drawer-menu-link:hover {
    background: linear-gradient(90deg, rgba(25, 135, 84, 0.08) 0%, transparent 100%);
    color: #198754;
    padding-left: 28px;
    text-decoration: none;
}

.drawer-menu-link img {
    width: 28px;
    height: 28px;
    object-fit: contain;
    flex-shrink: 0;
}

.drawer-menu-link span {
    flex: 1;
}

/* Pie del drawer */
.drawer-footer {
    padding: 16px 20px;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
    background: #f8f9fa;
}

.drawer-footer-user {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #555;
    font-size: 0.88rem;
}

/* ============================================================
   📱 MEDIA QUERIES - Responsive
   ============================================================ */

@media (max-width: 767px) {
    /* Mostrar botón hamburguesa */
    #btnMenuMobile {
        display: flex;
    }


    /* En móvil, comprimir el bloque izquierdo del navbar */
    .tab-bar .nombre-usuario-label {
        display: none !important;
    }
}

@media (min-width: 768px) {
    /* Ocultar botón hamburguesa en desktop */
    #btnMenuMobile {
        display: none !important;
    }

}

/* ============================================================
   📱 UTILIDADES RESPONSIVE
   ============================================================ */

/* Ocultar elementos del navbar en móvil */
@media (max-width: 767px) {
    .ocultar-en-movil {
        display: none !important;
    }
}

/* Badges dentro del drawer */
.drawer-badge {
    position: absolute;
    top: -6px;
    right: -8px;
    background-color: #dc3545;
    color: white;
    font-size: 10px;
    font-weight: 700;
    padding: 2px 5px;
    border-radius: 50%;
    min-width: 18px;
    text-align: center;
    line-height: 1.4;
    box-shadow: 0 1px 4px rgba(0,0,0,0.2);
}

.drawer-badge-pend {
    position: absolute;
    top: -6px;
    right: -24px;
    background-color: #f59e0b;
    color: white;
    font-size: 10px;
    font-weight: 700;
    padding: 2px 5px;
    border-radius: 50%;
    min-width: 18px;
    text-align: center;
    line-height: 1.4;
    box-shadow: 0 1px 4px rgba(0,0,0,0.2);
}

/* Ítem de cerrar sesión con color peligro */
.drawer-link-danger {
    color: #dc3545 !important;
}

.drawer-link-danger:hover {
    background: linear-gradient(90deg, rgba(220, 53, 69, 0.08) 0%, transparent 100%) !important;
    color: #b02a37 !important;
    padding-left: 28px;
}