@import url('https://fonts.googleapis.com/css2?family=Roboto+Condensed:ital,wght@0,100..900;1,100..900&display=swap');

:root {
    --primary-color: #033C73;
    --secondary-color: #007BFF;
    --success-color: #1B9B17;
    --danger-color: #DC3545;
    --warning-color: #FFC107;
    --light-color: #F8F9FA;
    --dark-color: #212529;
}

body {
    font-family: 'Roboto Condensed', sans-serif !important;
    background-color: #ffffff;
    color: var(--dark-color);
}

.bg-primary {
    background-color: var(--primary-color) !important;
}

.text-primary {
    color: var(--primary-color) !important;
}

.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-primary:hover {
    background-color: #022a52; 
    border-color: #022a52;
}

.bg-secondary {
    background-color: var(--secondary-color) !important;
}

/* Navbar Overrides */
.navbar {
    background: linear-gradient(90deg, #033C73 0%, #054a8a 100%);
}

.navbar-brand {
    font-size: 1.5rem;
    letter-spacing: -0.5px;
}

/* Accordion Overrides for Menu */
.accordion-button:not(.collapsed) {
    color: var(--primary-color);
    background-color: #e7f1ff;
    box-shadow: inset 0 -1px 0 rgba(0,0,0,.125);
}

.accordion-button:focus {
    box-shadow: none;
    border-color: rgba(0,0,0,.125);
}

/* Footer / Social Bar */
.footer-link {
    color: #cbd5e1;
    text-decoration: none;
    transition: color 0.2s;
}

/* Responsive Width Utility for Navbar Top Bar */
.responsive-w-100 {
    width: 100%;
}
@media (min-width: 992px) { /* lg breakpoint */
    .responsive-w-100 {
        width: auto !important;
    }
}

/* Sidebar UX/UI Refinements */
.sidebar-link {
    font-size: 0.9rem;
    color: var(--dark-color);
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    transition: all 0.2s ease-in-out;
    display: block;
    text-decoration: none;
    background-color: #f8f9fa; /* Default light background */
}

.sidebar-link:hover {
    color: #ffffff !important;
    background-color: var(--primary-color) !important; 
    transform: translateX(3px);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.sidebar-link:hover i {
    color: #ffffff !important;
    opacity: 1 !important;
}


/* TomSelect Customization */
/* TomSelect Default (Global / Forms) */
.ts-wrapper {
    width: 100% !important;
    display: block !important;
}

.ts-control {
    border-radius: 0.375rem !important; /* Standard Bootstrap Radius */
    padding: 0.375rem 0.75rem !important;
    box-shadow: none !important;
    position: relative !important;
    width: 100% !important;
    display: flex !important;
    align-items: center !important;
    min-height: auto !important;
    background-color: #fff; /* Default white for forms */
    border: 1px solid #ced4da; /* Default border */
    color: #333;
}

/* NAVBAR SPECIFIC STYLE (Pill / Dark) */
.ts-navbar-style .ts-control {
    background-color: rgba(255, 255, 255, 0.1) !important;
    border: 1px solid rgba(255, 255, 255, 0.15) !important;
    color: #fff !important;
    border-radius: 50rem !important;
    padding-left: 1rem !important;
    padding-right: 2.5rem !important;
    min-height: 38px !important;
    text-overflow: ellipsis;
    white-space: nowrap;
    overflow: hidden;
}

/* Navbar Chevron Scope */
.ts-navbar-style .ts-control::after {
    content: '\f0d7'; /* fa-caret-down */
    font-family: "Font Awesome 6 Free", "FontAwesome";
    font-weight: 900;
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: rgba(255, 255, 255, 0.8);
    pointer-events: none !important;
    font-size: 0.85rem;
}

/* Common Item Styles */
.ts-control .item {
    font-size: 0.9rem;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
    max-width: 100% !important;
    display: block !important;
}

/* Navbar Specific Item Color */
.ts-navbar-style .ts-control .item {
    color: #fff !important;
}

.ts-control .item {
    color: #fff !important;
    font-size: 0.9rem;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
    max-width: 100% !important;
    display: block !important;
}

/* Hide input in control if using dropdown_input, or style it minimally */
.ts-control input {
    color: #fff !important;
}

/* Ensure Dropdown is on top */
.ts-dropdown {
    z-index: 2000 !important;
    border-radius: 0.5rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    border: none;
    padding-top: 0;
    overflow: hidden;
}

/* Header Search Input (Plugin: dropdown_input) */
.ts-dropdown .dropdown-input-container {
    padding: 0.5rem;
    background: #f8f9fa;
    border-bottom: 1px solid #dee2e6;
}

.ts-dropdown .dropdown-input {
    border: 1px solid #ced4da;
    border-radius: 0.25rem;
    padding: 0.375rem 0.75rem;
    font-size: 0.85rem; /* Smaller font for search */
    width: 100%;
}

.ts-dropdown .option {
    font-size: 0.9rem; /* Smaller font for items */
    padding: 0.5rem 1rem;
}

.ts-dropdown .active {
    background-color: var(--primary-color) !important;
    color: #fff !important;
}

@media (min-width: 992px) {
    .ts-dropdown {
        width: 400px !important;
    }
}

.offcanvas-body .accordion-button {
    font-size: 0.95rem; /* Reduced from default */
    padding: 0.75rem 1rem;
}

.offcanvas-body .accordion-body {
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
}

.submenu-context h6 {
    font-size: 0.85rem;
    letter-spacing: 0.05em;
    color: #6c757d !important; /* Muted uppercase header */
}

/* Selector Container */
.selector-container {
    width: 100%;
}
@media (min-width: 992px) {
    .selector-container {
        width: 320px; /* Fixed width on Desktop */
    }
}

/* Navbar Item Layout (Icon Top, Text Bottom) */
.navbar-nav .nav-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    font-weight: 700 !important; /* Bold */
    font-size: 0.8rem !important; /* Smaller */
    color: #fff !important;
    padding: 0.5rem 1rem !important;
    transition: color 0.2s;
}

.navbar-nav .nav-link i {
    font-size: 1.2rem;
    margin-bottom: 2px;
    margin-right: 0 !important;
}

.navbar-nav .nav-link:hover, .navbar-nav .nav-link.active {
    color: #beefff !important; /* Lighter Blue */
}


/* Colocar cualquier imagen En escalas de grises Para producir efecto Pasa una escala de grises a colores al hacer Hover */
.imgescalasgrises {
    -webkit-filter: grayscale(100%);
    -moz-filter: grayscale(100%);
    -ms-filter: grayscale(100%);
    -o-filter: grayscale(100%);
    filter: grayscale(100%);
}

/* Pasa una escala de grises a colores al hacer Hover */
.imgescalasgrises:hover {
    -webkit-filter: grayscale(0%);
    -moz-filter: grayscale(0%);
    -ms-filter: grayscale(0%);
    -o-filter: grayscale(0%);
    filter: grayscale(0%);
}

/* =============================================
   ELEMENTOS SOCIALES Y BOTONES FLOTANTES
   ============================================= */

.barra-social {
  position: fixed;
  right: 0;
  top: 40%;
  font-size: 1.4rem;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  z-index: 500;
}

.iconossociales {
  color: white;
  text-decoration: none;
  padding: .7rem;
  display: flex;
  transition: all 0.8s ease; /* 800ms */
  text-decoration: none;
  width: 2.5rem;
  margin-bottom: 0 !important; /* Force no gap */
}

/* Dynamic Colors Support */
.iconossociales-dynamic {
    background-color: var(--bg-color, #333);
}

.iconossociales-dynamic:hover {
    background-color: var(--hover-color, #000);
    padding-right: 4rem !important; /* Force expansion */
    width: auto !important; /* Allow expansion */
    border-radius: .3rem 0 0 .4rem !important; /* Override position-based radius */
    box-shadow: 0 0 .5rem rgba(0, 0, 0, 0.42);
    text-decoration: none;
    color: #ffffff;
}

/* Wrapper-based selectors for radius */
.social-wrapper:first-child .iconossociales {
  border-radius: .4rem 0 0 0;
}

.social-wrapper:last-child .iconossociales {
  border-radius: 0 0 0 .4rem;
}

/* Ensure wrapper doesn't add space and aligns content */
.social-wrapper {
    margin: 0;
    padding: 0;
    line-height: 0;
    display: flex; /* Robust alignment */
    justify-content: flex-end; /* Align right */
    width: auto; /* Corregido: width: 100% causaba desbordamiento horizontal */
}

/* WhatsApp Floating Button (Left) */
.btn-whatsapp-float {
    position: fixed;
    bottom: 30px;
    left: 30px;
    width: 60px;
    height: 60px;
    color: #fff;
    border-radius: 50%;
    text-align: center;
    font-size: 30px;
    z-index: 1000;
    transition: all 0.3s ease;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0px 4px 10px rgba(0,0,0,0.3);
}

.btn-whatsapp-float:hover {
    color: #fff;
    transform: scale(1.1);
    box-shadow: 0 6px 15px rgba(37, 211, 102, 0.5);
}