/* Root & Body */
:root{
  --brand-primary:#0d6efd;
  --brand-dark:#0a58ca;
  --brand-text:#0b1b2b;
}

html, body {
  height: 100%;
  margin: 0;
}

body{
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif;
  color: var(--brand-text);
  background:
    radial-gradient(1200px 600px at 10% 0%, rgba(13,110,253,.08), transparent 60%),
    radial-gradient(1000px 500px at 90% 10%, rgba(13,110,253,.05), transparent 60%),
    linear-gradient(180deg, #ffffff 0%, #f7fbff 100%);
  background-repeat: no-repeat;
  background-attachment: fixed;
  background-size: cover;
  display: flex;
  flex-direction: column;

}
.comment-background{ background:
    radial-gradient(1200px 600px at 10% 0%, rgba(13,110,253,.08), transparent 60%),
    radial-gradient(1000px 500px at 90% 10%, rgba(13,110,253,.05), transparent 60%),
    linear-gradient(180deg, #ffffff 0%, #f7fbff 100%);}

/* Sidebar & Navbar */
.sidebar {
  min-height: 100vh;
  background:
    radial-gradient(1200px 600px at 10% 0%, rgba(13,110,253,.08), transparent 60%),
    radial-gradient(1000px 500px at 90% 10%, rgba(13,110,253,.05), transparent 60%),
    linear-gradient(180deg, #ffffff 0%, #f7fbff 100%);
  border-right: 1px solid #dee2e6;
    transition: width 0.3s;

}
.sidebar.collapsed {
  width: 100px; /* collapsed width */
}

.sidebar .menu-text {
  display: inline-block;
  transition: opacity 0.3s;
}

.sidebar.collapsed .menu-text {
  display: none;
}

.sidebar .nav-link.active { background: #0095da; color: #fff; border-radius: 0.375rem; }

.sidebar .nav-link {
  white-space: nowrap;
  overflow: hidden;
    color: #333;
}
/* center icons when collapsed */
.sidebar.collapsed .nav-link i {
  margin-right: 0;
  text-align: center;
  width: 100%;
}
/* Sidebar — nicer active styling */
#sidebar { transition: all .18s ease; }

/* nav link base */
#sidebar .nav-link {
  color: #263238;
  border-radius: 8px;
  padding: .45rem .7rem;
  transition: background .15s, color .15s, transform .12s;
}

/* hover */
#sidebar .nav-link:hover {
  background: rgba(0,0,0,0.03);
  text-decoration: none;
}

/* active item */
#sidebar .nav-link.active {
  background: linear-gradient(90deg, rgba(0,149,218,0.12), rgba(0,149,218,0.04));
  color: #013444;
  font-weight: 600;
  border-left: 4px solid #0095da;
  box-shadow: 0 6px 14px rgba(3,47,78,0.06);
}

/* make icon + label match color when active */
#sidebar .nav-link.active .bi,
#sidebar .nav-link.active .menu-text {
  color: #013444 !important;
}

/* parent collapse header, when a child inside is active */
.collapse-toggle.active-parent {
  background: rgba(0,0,0,0.03);
  border-radius: 8px;
  padding: .4rem .55rem;
  margin-right: .25rem;
}

/* caret rotation for open collapse */
.collapse-toggle .bi-caret-down-fill {
  transition: transform .18s ease;
}
.collapse-toggle[aria-expanded="true"] .bi-caret-down-fill {
  transform: rotate(-180deg);
}

/* smaller visual tweaks */
.sidebar-divider { opacity: .08; margin: .75rem 0; }
#sidebar .nav .nav-item + .nav-item { margin-top: .25rem; }
.lang-option {
  font-family: "Segoe UI Emoji", "Apple Color Emoji", "Noto Color Emoji", sans-serif;
}

.navbar {
      background-color: #0095da;
    }
.navbar .nav-link, .navbar .navbar-brand {
      color: #fff;
    }
.navbar > .container-fluid {
    flex-direction: row !important;
    align-items: center;
}
.sidebar .nav-item.dashboard-link > a {
    background: linear-gradient(135deg, #0095da, #00c4ff);
    border-radius: 6px;
    padding: 0.6rem 1rem;
    font-weight: bold;
    color: white !important;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: background 0.3s ease;
}

.sidebar .nav-item.dashboard-link > a:hover {
    background: linear-gradient(135deg, #007bb5, #00a2cc);
}

.chart-container { position: relative; height: 300px; }    
.dropdown-menu { font-size: 0.9rem; }

/* Content */
.container-fluid { flex: 1 1 auto; display: flex; flex-direction: column;   padding-top: 0.3rem;
    padding-bottom: 0.3rem;}


/* Cards */
.card-shell, .card-registration, .card-reset, .card-forgot, .card-login, .card-form {
  background:
    radial-gradient(1200px 600px at 10% 0%, rgba(13,110,253,0.08), transparent 60%),
    radial-gradient(1000px 500px at 90% 10%, rgba(13,110,253,0.05), transparent 60%),
    linear-gradient(180deg, #ffffff 0%, #f7fbff 100%);
  border-radius: 10px;
  border: 5px solid #0095da;
  border-top-width: 60px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.1);
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 30px;
}

.card-shell { min-height: calc(100vh - 30px); }
.card-registration { width: 100%; max-width: 1200px; margin: 2rem auto; }
.card-reset, .card-forgot, .card-login { max-width: 400px; margin: 4.5rem auto; }

.card-shell .card-title, 
.card-registration h4.card-title,
.card-reset h4.card-title,
.card-forgot h4.card-title,
.card-login h4.card-title {
  position: absolute;
  top: -45px;
  left: 0;
  width: 100%;
  text-align: center;
  color: white;
  background-color: #0095da;
  padding: 10px 0;
  border-top-left-radius: 5px;
  border-top-right-radius: 5px;
  font-weight: 700;
}

/* Tables */
.table-responsive { flex: 1 1 auto; overflow-y: auto; margin-top: 10px; }
.table-striped tbody tr:nth-of-type(odd),
.attach-list .list-group-item:nth-child(odd),
.usage-entry table tbody tr:nth-child(even),
.audit-entry table tbody tr:nth-child(even) {
  background-color: rgba(13,110,253,.05);
}

/* Buttons */
.status-tabs .btn { flex: 1; }
.status-tabs .btn.active { background-color: #0d6efd; color: #fff; }
.action-btn { width: 100%; }
.clear-btn, .clearable-input .btn-clear { position: absolute; right: 10px; z-index: 2; }

/* Forms */
.form-label { font-weight: 700; }
.readonly-field[readonly], .form-select:disabled { background-color: #f8fafc; }
.form-floating>.form-control { height: calc(3rem + 2px); }
.required:after { content:" *"; color:red; }

/* Modal */
.modal-header {
  background-color: #0095da;
  color: #fff;
  border-bottom: 3px solid #0078b5;
}
.modal-header .modal-title { font-weight: 700; margin: 0; }
.modal-header .btn-close { filter: invert(1); }

/* Hero Section */
.hero{
  position: relative;
  padding: clamp(3rem, 6vw, 6rem) 0;
}
.hero .badge{
  background: rgba(13,110,253,.12);
  color: var(--brand-primary);
  border: 1px solid rgba(13,110,253,.25);
}
.hero h1{
  font-weight: 800;
  letter-spacing: -.02em;
  line-height: 1.1;
}
.hero p.lead{ color: #334155; }
.stat{
  background: #fff;
  border: 1px solid rgba(13,110,253,.1);
  border-radius: 1rem;
  padding: 1rem 1.25rem;
  box-shadow: 0 10px 30px rgba(13,110,253,.06);
  margin-top: 20px;
}
.stat h3{ margin:0; font-size:1.5rem; font-weight:800; }
.stat small{ color:#475569; }
.features-list { list-style:none; padding-left:0; }
.features-list li { margin-bottom: 20px; font-size: 16px; }
.features-list li strong { font-size: 18px; color: #004080; }

/* Stepper & Progress */
.stepper { display:flex; justify-content:space-between; margin-bottom:20px; }
.stepper .step { flex:1; text-align:center; padding:10px; border-bottom:3px solid #ccc; cursor:pointer; }
.stepper .step.active { font-weight:bold; border-color:#0095da; color:#0095da; }
.card-header { background-color: #0095da; color: #fff; }
.progress-container { display:flex; justify-content:space-between; position:relative; margin-bottom:30px; }
.progress-step { width:25%; text-align:center; font-weight:500; position:relative; }
.progress-step::before {
  content: '';
  position: absolute; top:15px; left:50%; transform: translateX(-50%);
  height:10px; width:10px; border-radius:50%; background-color:#ccc; z-index:1;
}
.progress-step.active::before { background-color:#0095da; }
.progress { height:5px; position:absolute; top:19px; left:0; width:100%; background-color:#e9ecef; z-index:0; }
.progress-bar { background-color:#0095da; }

/* Preview images */
.preview-img, .preview-img-small, .preview-img-wide { display:block; margin-top:5px; object-fit:contain; border:1px solid #ddd; }
.preview-img-small { width:150px; height:150px; }
.preview-img-wide { width:100%; height:50px; }

/* Feature cards */
.feature-card { border:1px solid #e0e0e0; border-radius:12px; transition: transform 0.3s; }
.feature-card:hover { transform: translateY(-5px); }

/* Footer */
.footer{ margin-top:auto; background:#ffffffaa; border-top:1px solid rgba(13,110,253,.12); }

/* Utilities */
.d-flex-center {
    display: flex;
    justify-content: center; /* horizontal centering */
    align-items: center;     /* vertical centering */
    height: 100%;            /* make sure parent/container has height */
}
.remove-btn { cursor:pointer; color:red; }
.forgot-link, .register-link { font-size:0.9rem; display:block; margin-top:10px; text-align:center; cursor:pointer; }
/* Collapsible section headers */
    .collapse-toggle {
      cursor: pointer;
      padding: 8px 0;
      font-weight: 600;
      color: #333;
      display: flex;
      justify-content: space-between;
      align-items: center;
    }
    .collapse-toggle:hover {
      color: #0095da;
    }
/* Responsive */
@media(max-width:991px){ .hero { display:none; } }
/* put this in your css */
.hs-wrapper {
  position: relative; /* container for dropdown */
}

.hs-wrapper .autocomplete-suggestions {
  position: absolute;
  top: 100%;              /* show just below the input */
  left: 0;
  width: max-content;     /* allow wider than input if needed */
  min-width: 100%;        /* but at least as wide as input */
  max-height: 250px;
  overflow-y: auto;
  z-index: 1050;          /* appear above table */
   background:
    radial-gradient(1200px 600px at 10% 0%, rgba(13,110,253,.08), transparent 60%),
    radial-gradient(1000px 500px at 90% 10%, rgba(13,110,253,.05), transparent 60%),
    linear-gradient(180deg, #ffffff 0%, #f7fbff 100%);
  border: 1px solid #ccc;
  border-radius: 0 0 4px 4px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.15);
}

.autocomplete-suggestions .list-group-item {
    cursor: pointer;
}
.autocomplete-suggestions .list-group-item:hover {
    background-color: #f0f0f0;
}
  /* Smaller inputs */
    .producer-fieldset input.form-control {
        height: 36px;           /* default is ~38-40px */
        font-size: 0.85rem;     /* smaller text */
        padding: 0.25rem 0.5rem;
    }

    /* Smaller legend */
    .producer-fieldset legend {
        font-size: 0.9rem;
        padding: 0 0.5rem;
    }
    /* Let dropdown menus escape DataTables scroll/overflow */
table.dataTable td {
  overflow: visible !important;
}

.dataTables_wrapper .dropdown-menu {
  position: absolute !important;
  z-index: 1055 !important; /* higher than modal backdrops */
}
.spinner {
  border: 6px solid #f3f3f3;
  border-top: 6px solid #3498db;
  border-radius: 50%;
  width: 50px;
  height: 50px;
  animation: spin 1s linear infinite;
}
@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}
@media print {
    .row { display: flex; flex-wrap: wrap; }
    .col-md-4 { flex: 0 0 33.3333%; max-width: 33.3333%; }
}
 #alertModalContent {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
  }
  #alertModalContent.show {
    transform: scale(1.05);
    box-shadow: 0 0 25px rgba(0,0,0,0.3);
  }
/* Force modal body to scroll on small screens */
.modal-dialog-scrollable .modal-body {
    overflow-y: auto !important;
    max-height: calc(100vh - 150px) !important; /* Adjust spacing */
}

/* Allow modal-content to shrink instead of blocking scroll */
.modal-dialog-scrollable .modal-content {
    max-height: 100vh;
}
