html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

/* Client Primary Color Variables */
:root {
  --akura-primary: #00529B;
  --akura-primary-light: #1a6bb3;
  --akura-primary-dark: #003f7a;
  --akura-primary-hover: #004085;
  --akura-secondary: #f8f9fa;
  --akura-accent: #e3f2fd;
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem var(--akura-primary);
}

/* Footer styling */
.footer {
    background-color: white;
    color: var(--akura-primary-dark);
    border-top-color: rgb(222, 226, 230);
    border-top-style: solid;
    border-top-width: 0.8px
}

@media (max-width: 767px) {
  .footer {
    font-size: 14px;
  }
}

/* Dual Logo Branding */
.navbar-brand {
  transition: all 0.3s ease;
}

.navbar-brand:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}

.client-logo img {
  transition: all 0.3s ease;
  border-radius: 4px;
}

.system-logo img {
  transition: all 0.3s ease;
  border-radius: 6px;
  box-shadow: 0 2px 4px rgba(0, 82, 155, 0.1);
}

.system-branding {
  position: relative;
}

.system-branding::before {
  content: '';
  position: absolute;
  left: -8px;
  top: 50%;
  transform: translateY(-50%);
  width: 2px;
  height: 30px;
  background: linear-gradient(to bottom, transparent, var(--akura-primary), transparent);
  opacity: 0.3;
}

/* Home Page Hero Section Logos */
.hero-content {
  transition: all 0.3s ease;
}

.cta-content {
  transition: all 0.3s ease;
}

.cta-logo {
  transition: all 0.3s ease;
}

/* Responsive branding adjustments */
@media (max-width: 767px) {
  .client-logo img {
    width: 60px !important;
  }
  
  .system-logo img {
    width: 28px !important;
    height: 28px !important;
  }
  
  .system-branding::before {
    display: none;
  }

  /* Hero section mobile adjustments */
  .hero-content {
    flex-direction: column !important;
    text-align: center !important;
  }
  
  .hero-logo {
    margin-right: 0 !important;
    margin-bottom: 20px !important;
    width: 60px !important;
    height: 60px !important;
  }
  
  .hero-text {
    text-align: center !important;
  }
  
  .cta-content {
    flex-direction: column !important;
  }
  
  .cta-logo {
    margin-right: 0 !important;
    margin-bottom: 10px !important;
  }
}

@media (min-width: 992px) {
  .client-logo img {
    width: 90px !important;
  }
  
  .system-logo img {
    width: 40px !important;
    height: 40px !important;
  }
}

/* Akura Brand Colors */
.btn-primary {
  background-color: var(--akura-primary);
  border-color: var(--akura-primary);
}

.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active {
  background-color: var(--akura-primary-hover);
  border-color: var(--akura-primary-dark);
}

.btn-outline-primary {
  color: var(--akura-primary);
  border-color: var(--akura-primary);
}

.btn-outline-primary:hover,
.btn-outline-primary:focus,
.btn-outline-primary:active {
  background-color: var(--akura-primary);
  border-color: var(--akura-primary);
}

.text-primary {
  color: var(--akura-primary) !important;
}

.bg-primary {
  background-color: var(--akura-primary) !important;
}

.table-dark {
  background-color: var(--akura-primary);
  border-color: var(--akura-primary-dark);
}

.table-dark th,
.table-dark td {
  border-color: var(--akura-primary-dark);
}

/* Navigation Styling */
.navbar {
  background-color: white !important;
  border-bottom: 3px solid var(--akura-primary);
}

.navbar-brand:hover {
  opacity: 0.8;
}

.nav-link:hover {
  color: var(--akura-primary) !important;
}

.nav-link.active {
  color: var(--akura-primary) !important;
  font-weight: 600;
}

.version-pill {
  display: inline-flex;
  align-items: center;
  background-color: #58c2e8;
  color: #001b2f;
  border-radius: 14px;
  padding: 8px 14px;
  font-weight: 700;
  font-size: 0.95rem;
  line-height: 1;
}

.user-avatar-toggle {
  padding: 0 !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.user-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background-color: #2f7fc1;
  color: #fff;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 0 2px rgba(0, 82, 155, 0.15);
}

.user-avatar-toggle::after {
  display: none !important;
}

.user-menu-dropdown {
  min-width: auto;
  width: max-content;
  max-width: min(90vw, 420px);
}

.user-menu-dropdown .dropdown-item-text {
  white-space: nowrap;
}

.idea-lit-icon {
  position: relative;
}

.idea-lit-icon::after {
  content: "✨";
  font-family: "Segoe UI Emoji", "Apple Color Emoji", sans-serif;
  position: absolute;
  font-size: 0.55em;
  top: -0.45em;
  right: -0.35em;
  line-height: 1;
}

/* Card Headers */
.card-header {
  background-color: var(--akura-accent);
  border-bottom: 2px solid var(--akura-primary);
  color: var(--akura-primary-dark);
  font-weight: 600;
}

/* Form Controls */
.form-control:focus {
  border-color: var(--akura-primary);
  box-shadow: 0 0 0 0.2rem rgba(0, 82, 155, 0.25);
}

.searchbutton-padding 
{
    padding-bottom: 1.5rem !important;
}

.searchbutton-padding button {
    font-size: 1rem !important;
}

/* Alerts */
.alert-danger {
  background-color: #f8d7da;
  border-color: #f5c6cb;
  color: #721c24;
}

.alert-info {
  background-color: var(--akura-accent);
  border-color: var(--akura-primary-light);
  color: var(--akura-primary-dark);
}

/* Status Badges */
.badge.bg-success {
  background-color: #28a745 !important;
}

.badge.bg-primary {
  background-color: var(--akura-primary) !important;
}

/* Links */
a {
  color: var(--akura-primary);
}

a:hover {
  color: var(--akura-primary-hover);
}

/* Display Headers */
.display-4 {
  color: var(--akura-primary-dark);
  font-weight: 600;
}

.lead {
  color: #6c757d;
}

/* Mobile-friendly improvements */
.container {
  padding-left: 15px;
  padding-right: 15px;
}

/* Ensure main content has proper bottom spacing */
main {
  min-height: 400px; /* Ensure minimum height for content */
  padding-bottom: 20px;
}

@media (max-width: 767px) {
  main {
    padding-bottom: 120px; /* More space on mobile for floating button */
  }
}

/* Mobile-friendly navigation */
.navbar-brand img {
  max-width: 80px;
  height: auto;
  transition: all 0.3s ease;
}

@media (min-width: 768px) {
  .navbar-brand img {
    max-width: 100px;
  }
}

/* Mobile-friendly tables */
.table-responsive {
  border: none;
}

.table-responsive table {
  font-size: 14px;
}

@media (max-width: 767px) {
  .table-responsive table {
    font-size: 12px;
  }
  
  .table-responsive th,
  .table-responsive td {
    padding: 6px 4px;
    white-space: nowrap;
  }
  
  /* Stack table columns on very small screens */
  .table-responsive .btn {
    padding: 4px 8px;
    font-size: 12px;
  }
}

/* Mobile-friendly forms */
.form-control {
  font-size: 16px; /* Prevents zoom on iOS */
}

@media (max-width: 767px) {
  .search-form {
    flex-direction: column !important;
    gap: 10px !important;
  }
  
  .search-form input:not([type="checkbox"]):not([type="radio"]) {
    width: 100% !important;
  }
  
  .search-form button {
    width: 100%;
  }
}

.search-form input[type="checkbox"],
.search-form input[type="radio"] {
  width: 1em !important;
  height: 1em !important;
}

/* Mobile-friendly detail cards */
@media (max-width: 767px) {
  .detail-table {
    font-size: 14px;
  }
  
  .detail-table td:first-child {
    font-weight: bold;
    width: 40%;
  }
  
  .detail-table td {
    padding: 8px 4px;
    border-bottom: 1px solid #eee;
  }
}

/* Mobile-friendly buttons */
@media (max-width: 767px) {
  .btn {
    padding: 8px 12px;
    margin-bottom: 5px;
  }
  
  .btn-lg {
    padding: 12px 20px;
    width: 100%;
  }
}

/* Responsive spacing */
@media (max-width: 767px) {
  .mb-3 {
    margin-bottom: 1rem !important;
  }
  
  h1, h2, h3 {
    font-size: calc(1.2rem + 0.5vw);
  }
}

/* Feature Cards */
.card {
  border: 1px solid rgba(0, 82, 155, 0.125);
  transition: all 0.3s ease;
}

.card:hover {
  border-color: var(--akura-primary);
  box-shadow: 0 4px 8px rgba(0, 82, 155, 0.15);
}

.card-title {
  color: var(--akura-primary-dark);
}

/* Table Improvements */
.table-striped > tbody > tr:nth-of-type(odd) > td,
.table-striped > tbody > tr:nth-of-type(odd) > th {
  background-color: rgba(0, 82, 155, 0.05);
}

.table-hover > tbody > tr:hover > td,
.table-hover > tbody > tr:hover > th {
  background-color: rgba(0, 82, 155, 0.1);
}

/* Search Form Enhancements */
.search-form {
  background-color: var(--akura-accent);
  padding: 20px;
  border-radius: 8px;
  margin-bottom: 20px;
  border-left: 4px solid var(--akura-primary);
}

/* Loading States */
.loading {
  color: var(--akura-primary);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
  background: var(--akura-primary);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--akura-primary-hover);
}

/* Loading Modal Overlay */
.loading-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  z-index: 9999;
  align-items: center;
  justify-content: center;
}

.loading-overlay.show {
  display: flex;
}

.loading-spinner-container {
  background-color: white;
  padding: 30px 40px;
  border-radius: 12px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
  text-align: center;
  max-width: 300px;
}

.loading-spinner {
  width: 60px;
  height: 60px;
  border: 6px solid var(--akura-accent);
  border-top: 6px solid var(--akura-primary);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 20px;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.loading-text {
  color: var(--akura-primary-dark);
  font-size: 16px;
  font-weight: 600;
  margin: 0;
}

.loading-subtext {
  color: #6c757d;
  font-size: 14px;
  margin-top: 8px;
}

