/* === UNIPE - Personalizaciones osTicket === */

/* Layout */
.main-content { width: 100% !important; }
.sidebar.pull-right .content { display: none !important; }

/* Temas de ayuda */
.field--type-info,
.field-info {
  margin-bottom: 0 !important;
}
.form-header b {
  font-size: 18px !important;
}

/* Contenedor principal */
#container {
    width: 960px !important;
}

/* Nav: distribuir items equitativamente */
#nav {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    height: auto !important;
    min-height: 24px !important;
    padding: 2px 10px !important;
    box-sizing: border-box !important;
    margin: 0 20px !important;
}
#nav li {
    display: flex !important;
    margin: 0 !important;
}
#nav li a {
    margin-left: 0 !important;
}

/* Boton Buscar institucional */
button.green.button {
    background-color: #064365 !important;
    background-image: linear-gradient(135deg, #064365, #042c44) !important;
    color: #ffffff !important;
    border: none !important;
    border-radius: 5px !important;
    padding: 6px 16px !important;
    font-size: 13px !important;
    cursor: pointer !important;
    box-shadow: none !important;
    text-shadow: none !important;
}
button.green.button:hover {
    background-color: #19b8d7 !important;
    background-image: none !important;
}

/* Buscador: ancho contenido y alineado con la card */
.search-form {
    display: none;
    /*display: flex !important;*/
    align-items: center !important;
    gap: 8px !important;
    margin: 0 !important;
    padding: 0 !important;
    width: 65% !important;
}
.search-form .search {
    flex: 1 !important;
    width: auto !important;
    box-sizing: border-box !important;
}

/* ===== Nav superior: estetica moderna con iconos SVG ===== */
#nav {
    background-color: #ffffff !important;
    box-shadow: 0 1px 3px rgba(0,0,0,0.04) !important;
    gap: 4px !important;
    background: none !important;
    border-top: none !important;
}

#nav li a {
    display: flex !important;
    align-items: center !important;
    padding: 8px 16px 8px 34px !important;
    border-radius: 8px !important;
    color: #064365 !important;
    font-weight: 600 !important;
    font-size: 13px !important;
    text-decoration: none !important;
    transition: background-color 0.15s ease, color 0.15s ease !important;
    white-space: nowrap !important;
    position: relative !important;
    background-image: none !important;
}

#nav li a::before {
    content: "" !important;
    position: absolute !important;
    left: 12px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    width: 16px !important;
    height: 16px !important;
    background-color: currentColor !important;
    -webkit-mask-repeat: no-repeat !important;
    mask-repeat: no-repeat !important;
    -webkit-mask-position: center !important;
    mask-position: center !important;
    -webkit-mask-size: contain !important;
    mask-size: contain !important;
}

#nav li a.home::before {
    -webkit-mask-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M3 11l9-8 9 8'/><path d='M5 10v10a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1V10'/><path d='M9 21v-6h6v6'/></svg>") !important;
    mask-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M3 11l9-8 9 8'/><path d='M5 10v10a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1V10'/><path d='M9 21v-6h6v6'/></svg>") !important;
}

#nav li a.new::before {
    -webkit-mask-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M12 20h9'/><path d='M16.5 3.5a2.121 2.121 0 0 1 3 3L7 19l-4 1 1-4L16.5 3.5z'/></svg>") !important;
    mask-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M12 20h9'/><path d='M16.5 3.5a2.121 2.121 0 0 1 3 3L7 19l-4 1 1-4L16.5 3.5z'/></svg>") !important;
}

#nav li a.status::before {
    -webkit-mask-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><circle cx='11' cy='11' r='7'/><line x1='21' y1='21' x2='16' y2='16'/></svg>") !important;
    mask-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><circle cx='11' cy='11' r='7'/><line x1='21' y1='21' x2='16' y2='16'/></svg>") !important;
}

#nav li a.tickets::before {
    -webkit-mask-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M15 5H8a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h8a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2z'/><path d='M9 9h6'/><path d='M9 13h6'/><path d='M9 17h4'/></svg>") !important;
    mask-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M15 5H8a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h8a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2z'/><path d='M9 9h6'/><path d='M9 13h6'/><path d='M9 17h4'/></svg>") !important;
}

#nav li a.kb::before {
    -webkit-mask-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M4 19.5A2.5 2.5 0 0 1 6.5 17H20'/><path d='M6.5 2H20v20H6.5A2.5 2.5 0 0 1 4 19.5v-15A2.5 2.5 0 0 1 6.5 2z'/></svg>") !important;
    mask-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M4 19.5A2.5 2.5 0 0 1 6.5 17H20'/><path d='M6.5 2H20v20H6.5A2.5 2.5 0 0 1 4 19.5v-15A2.5 2.5 0 0 1 6.5 2z'/></svg>") !important;
}

#nav li a:hover {
    background-color: #f0f8fc !important;
    color: #19b8d7 !important;
}

#nav li a.active {
    background-color: #064365 !important;
    color: #ffffff !important;
}

#nav li a.active:hover {
    background-color: #19b8d7 !important;
    color: #ffffff !important;
}

/* ===== Footer ===== */
#footer #poweredBy {
    display: none;
}

/* ============================================================
   KNOWLEDGE BASE carpeta en CSS puro (reemplaza PNG)
   ============================================================ */

#kb > li > i {
    display: block;
    width: 36px;
    height: 28px;
    float: left;
    margin-right: 8px;
    margin-top: 2px;
    background: none !important; /* anula el PNG del theme */
    position: relative;
}

/* Cuerpo de la carpeta */
#kb > li > i::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 36px;
    height: 22px;
    background-color: #19b8d7;
    border-radius: 0 3px 3px 3px;
}

/* Lengüeta superior */
#kb > li > i::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 16px;
    height: 8px;
    background-color: #19b8d7;
    border-radius: 3px 3px 0 0;
    opacity: 0.75;
}

/* ============================================================
   KNOWLEDGE BASE Ocultar sidebar span4, span8 a full ancho
   ============================================================ */

#kb .span4,
.searchbar,
div.sidebar {
    display: none !important;
}

#kb .span8,
div.span8 {
    width: 100% !important;
    margin-left: 0 !important;
}

/* ============================================================
   TICKETS Tabla #ticketTable
   ============================================================ */
table#ticketTable {
    width: 100%;
}

table#ticketTable thead tr,
table#ticketTable thead tr th {
    background: linear-gradient(135deg, #064365 0%, #0a5a8a 100%) !important;
    background-color: #064365 !important;
    color: #ffffff !important;
    border: none !important;
}

table#ticketTable thead th {
    padding: 10px 12px !important;
    font-weight: 600 !important;
    white-space: nowrap !important;
}

table#ticketTable thead th a,
table#ticketTable thead th a:visited {
    color: #ffffff !important;
    text-decoration: none !important;
}

table#ticketTable thead th a:hover {
    color: #19b8d7 !important;
}

/* Caption */
table#ticketTable caption {
    background-color: transparent !important;
    background: none !important;
    text-align: left !important;
    font-size: 12px !important;
    color: #888 !important;
    padding: 6px 2px !important;
}

#ticketTable td a.Icon {
    background-image: none !important;
    padding-left: 20px !important;
    position: relative !important;
}

#ticketTable td a.Icon::before {
    content: "" !important;
    position: absolute !important;
    left: 0 !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    width: 14px !important;
    height: 14px !important;
    background-color: #19b8d7 !important;
    -webkit-mask-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M15 5H8a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h8a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2z'/><path d='M9 9h6'/><path d='M9 13h6'/><path d='M9 17h4'/></svg>") !important;
    mask-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M15 5H8a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h8a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2z'/><path d='M9 9h6'/><path d='M9 13h6'/><path d='M9 17h4'/></svg>") !important;
    -webkit-mask-repeat: no-repeat !important;
    mask-repeat: no-repeat !important;
    -webkit-mask-size: contain !important;
    mask-size: contain !important;
}


/* TICKETS — Div paginación: quitar padding-top forzado */
#content > div > div:has(> ol),
table#ticketTable + div {
    padding-top: inherit !important;
}

/* TICKETS — Caption estilizado */
table#ticketTable caption {
    background: linear-gradient(135deg, #064365 0%, #0a5a8a 100%) !important;
    color: #ffffff !important;
    text-align: left !important;
    font-size: 12px !important;
    font-weight: 500 !important;
    padding: 7px 12px !important;
    caption-side: top !important;
    border-radius: 6px 6px 0 0 !important;
}
