/**
 * CONSOLIDATED STYLES SHEET
 * Barning Live - All pages use this single stylesheet
 * Merged from: navbar.css, login.css, home.css, users.css, modern-ui.css, 
 *              events.css, devices.css, admin.css, acties.css
 */

/* ============================================================
   CSS VARIABLES & COLOR PALETTE
   ============================================================ */
:root {
  /* Colors */
  --primary-color: #2c3e50;
  --secondary-color: #3498db;
  --success-color: #27ae60;
  --warning-color: #f39c12;
  --danger-color: #e74c3c;
  --light-color: #ecf0f1;
  --dark-color: #34495e;
  --navy: #063e6f;
  
  /* Modern UI Dark Theme */
  --mui-bg: #0f1724;
  --mui-surface: #0b1220;
  --mui-card: #0e1624;
  --mui-text: #e6eef8;
  --mui-muted: #7a8ba8;
  --mui-accent: #4f9cf9;
  --mui-accent-600: #2b80f6;
  --mui-success: #2ecc71;
  --mui-danger: #ff6b6b;
  
  /* Borders & Shadows */
  --radius: 10px;
  --radius-sm: 6px;
  --glass: rgba(255, 255, 255, 0.03);
  --glass-2: rgba(255, 255, 255, 0.02);
  --shadow: 0 6px 18px rgba(2, 6, 23, 0.6);
  --box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --mono: ui-monospace, SFMono-Regular, Menlo, Monaco, 'Roboto Mono', 'Courier New', monospace;
  
  /* Event-specific gradients */
  --event-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  --maps-gradient: linear-gradient(135deg, #28a745 0%, #20c997 100%);
  --btn-primary-gradient: linear-gradient(180deg, var(--mui-accent), var(--mui-accent-600));
}

/* ============================================================
   RESET & BASE STYLES
   ============================================================ */
* {
  box-sizing: border-box;
}

html, body {
  height: 100%;
  margin: 0;
  padding: 0;
}

body {
  padding-top: 56px;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, Arial, sans-serif;
  background: #f9f9f9;
  color: #333;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.5;
}

h1, h2, h3, h4, h5, h6 {
  margin-top: 0;
  color: #333;
}

a {
  color: var(--navy);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* ============================================================
   NAVBAR STYLES (Fixed/Sticky Navigation)
   ============================================================ */

nav.navbar {
  background: var(--navy);
  color: #fff;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 1050;
  margin: 0;
  padding: 0.75rem 0;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.15);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.navbar-modern {
  padding: 0.75rem 0;
  font-weight: 500;
  letter-spacing: 0.3px;
}

.navbar-container {
  max-width: none;
  width: 100%;
  padding: 0;
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
}

.navbar-brand {
  padding: 10px;
  margin-right: 10px;
  transition: var(--transition);
  flex-shrink: 0;
}

.navbar-brand:hover {
  opacity: 0.85;
  transform: translateY(-1px);
}

.navbar-logo {
  height: 24px;
  width: auto;
  display: block;
  transition: var(--transition);
}

.navbar-collapse {
  flex-grow: 1;
  align-items: center;
  justify-content: space-between;
}

.navbar-links {
  display: flex;
  gap: 0.5rem;
  margin: 0;
  flex: 0 0 auto;
  flex-wrap: nowrap;
}

.navbar-auth {
  display: flex;
  gap: 1rem;
  align-items: center;
  margin: 0;
  flex-shrink: 0;
}

/* Navigation Links */
.navbar-modern .nav-link {
  color: rgba(255, 255, 255, 0.85) !important;
  font-size: 0.95rem;
  padding: 0.5rem 0.85rem !important;
  margin: 0 0.25rem;
  border-radius: 6px;
  transition: var(--transition);
  position: relative;
  text-decoration: none;
}

.navbar-modern .nav-link:hover {
  color: white !important;
  background-color: rgba(79, 156, 249, 0.15);
  transform: translateY(-1px);
}

.navbar-modern .nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 2px;
  background: var(--mui-accent);
  border-radius: 1px;
  transform: translateX(-50%);
  transition: width var(--transition);
}

.navbar-modern .nav-link:hover::after {
  width: 80%;
}

/* User Display */
.navbar-user {
  color: rgba(180, 180, 180, 0.75) !important;
  padding: 0.5rem 0.85rem !important;
  font-size: 0.9rem;
  pointer-events: none;
}

/* Login/Logout Links */
/* Use .nav-link.nav-login (3-class specificity 0,3,0) to beat .navbar-modern .nav-link (0,2,0) */
.navbar-modern .nav-link.nav-login {
  color: rgba(120, 185, 120, 0.9) !important;
  padding: 0.5rem 0.85rem !important;
}

.navbar-modern .nav-link.nav-login:hover {
  color: rgb(140, 210, 140) !important;
  background-color: rgba(79, 156, 249, 0.15);
  transform: translateY(-1px);
}

.navbar-modern .nav-link.nav-login::after {
  background: rgb(120, 185, 120) !important;
}

.navbar-modern .nav-link.nav-login:hover::after {
  width: 80%;
}

.navbar-modern .nav-link.nav-logout {
  color: rgba(210, 90, 90, 0.85) !important;
  padding: 0.5rem 0.85rem !important;
}

.navbar-modern .nav-link.nav-logout:hover {
  color: rgba(225, 100, 100, 1) !important;
  background-color: rgba(210, 90, 90, 0.12);
  transform: translateY(-1px);
}

.navbar-modern .nav-link.nav-logout::after {
  background: rgba(210, 90, 90, 0.85) !important;
}

.navbar-modern .nav-link.nav-logout:hover::after {
  width: 80%;
}

/* ---- Mobile: < 1000px ---- */
@media (max-width: 999.98px) {
  /* Toggler: always visible, pushed to the far right */
  .navbar-modern .navbar-toggler {
    display: block !important;
    margin-left: auto;
    order: 2;
  }

  /* Brand stays left */
  .navbar-modern .navbar-brand {
    order: 1;
  }

  /* Collapse: full-width row below brand + toggler */
  .navbar-modern .navbar-collapse {
    order: 3;
    flex-basis: 100%;
    width: 100%;
  }

  /* When open, use column flex so we can right-align groups */
  .navbar-modern .navbar-collapse.show,
  .navbar-modern .navbar-collapse.collapsing {
    display: flex !important;
    flex-direction: column;
    align-items: flex-end;  /* groups stick to the right */
    padding: 0.25rem 0 0.5rem;
  }

  /* Each group: fit-content = as wide as its widest link.
     All links inside then share that same width column. */
  .navbar-modern .navbar-links,
  .navbar-modern .navbar-auth {
    display: flex;
    flex-direction: column;
    align-items: stretch;  /* links fill the group width */
    width: fit-content;
    gap: 0;
    margin: 0;
  }

  .navbar-modern .navbar-links .nav-link,
  .navbar-modern .navbar-auth .nav-link,
  .navbar-modern .navbar-auth .navbar-user {
    width: 100%;
    text-align: right;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 0;
    margin: 0;
    padding: 0.65rem 1rem !important;
    transform: none !important;  /* disable hover lift on mobile */
  }

  .navbar-modern .navbar-links .nav-link:last-child,
  .navbar-modern .navbar-auth .nav-link:last-child {
    border-bottom: none;
  }

  /* Hide underline indicator on mobile */
  .navbar-modern .nav-link::after {
    display: none;
  }
}

/* ---- Desktop: >= 1000px ---- */
@media (min-width: 1000px) {
  .navbar-modern .navbar-toggler {
    display: none !important;
  }
  .navbar-modern .navbar-collapse {
    display: flex !important;
    flex-basis: auto;
  }
}

/* Active/current page link */
.navbar-modern .nav-link-active {
  color: white !important;
  background-color: rgba(79, 156, 249, 0.15);
  transform: translateY(-1px);
}

.navbar-modern .nav-link-active::after {
  width: 80%;
}

.navbar-toggler {
  border: none;
  padding: 0;
  transition: var(--transition);
  color: white;
}

.navbar-toggler:focus {
  box-shadow: none;
  outline: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 4px;
}

.navbar-toggler-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 0.85%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2.5' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important;
  width: 1.5rem;
  height: 1.5rem;
}

.navbar-modern .nav-link {
  color: rgba(255, 255, 255, 0.85) !important;
}

/* ============================================================
   FORM & INPUT STYLES
   ============================================================ */
label {
  display: block;
  margin-bottom: 5px;
  color: #555;
  font-weight: 500;
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="date"],
select,
textarea {
  width: 100%;
  padding: 10px 12px;
  margin-bottom: 15px;
  box-sizing: border-box;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 14px;
  background: transparent;
  color: #333;
  transition: all 0.14s ease;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
input[type="number"]:focus,
input[type="date"]:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--navy);
  box-shadow: 0 0 0 3px rgba(6, 62, 111, 0.1);
}

/* Modern UI input styling */
.mui-input {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.06);
  padding: 10px 12px;
  border-radius: 8px;
  color: var(--mui-text);
  transition: all 0.14s ease;
}

.mui-input:focus {
  outline: none;
  box-shadow: 0 6px 20px rgba(47, 156, 249, 0.08);
  border-color: rgba(79, 156, 249, 0.2);
  background: rgba(255, 255, 255, 0.01);
}

/* Checkbox styling */
input[type="checkbox"] {
  cursor: pointer;
  accent-color: var(--mui-accent);
  appearance: none;
  -webkit-appearance: none;
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255, 255, 255, 0.35);
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.08);
  cursor: pointer;
  transition: all 0.12s ease;
  position: relative;
}

input[type="checkbox"]:hover {
  border-color: rgba(255, 255, 255, 0.45);
  background: rgba(255, 255, 255, 0.12);
}

input[type="checkbox"]:checked {
  background: var(--btn-primary-gradient);
  border-color: var(--mui-accent);
  box-shadow: 0 2px 6px rgba(79, 156, 249, 0.3);
}

input[type="checkbox"]:checked::after {
  content: '✓';
  position: absolute;
  top: -2px;
  left: 2px;
  color: white;
  font-weight: bold;
  font-size: 14px;
}

/* Simple input styles for edit fields */
input.edit,
input.locperiod {
  min-width: 50px;
  box-sizing: border-box;
}

/* ============================================================
   BUTTON STYLES
   ============================================================ */
button {
  width: 100%;
  padding: 12px;
  background: var(--navy);
  color: #fff;
  border: none;
  border-radius: 4px;
  font-size: 16px;
  cursor: pointer;
  transition: background 0.2s;
}

button:hover {
  background: #0056b3;
}

.mui-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 8px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--mui-text);
  cursor: pointer;
  transition: all 0.14s ease;
  font-weight: 600;
}

.mui-btn:active {
  transform: translateY(1px);
}

.mui-btn--primary {
  background: var(--btn-primary-gradient);
  color: white;
  box-shadow: 0 6px 18px rgba(47, 84, 173, 0.18);
}

.mui-btn--ghost {
  background: transparent;
  border-color: rgba(255, 255, 255, 0.06);
  color: var(--mui-text);
}

.mui-btn--outline {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.mui-btn--danger {
  background: linear-gradient(180deg, var(--mui-danger), #ff4b4b);
  color: white;
}

.mui-btn--sm {
  padding: 6px 10px;
  font-size: 0.85rem;
  border-radius: 6px;
}

.btn-custom {
  border-radius: 8px;
  padding: 8px 16px;
  font-weight: 500;
  transition: var(--transition);
  border: none;
  margin: 0 2px;
}

.delete-btn {
  background: #c00;
  color: #fff;
  border: none;
  padding: 6px 12px;
  border-radius: 4px;
  margin-top: 15px;
  cursor: pointer;
}

.restart-btn {
  background: #c00;
  color: #fff;
  padding: 0.5em 1em;
  border: none;
  border-radius: 4px;
}

.btn {
  display: inline-block;
  padding: 10px 20px;
  background: var(--navy);
  color: #fff;
  text-decoration: none;
  border-radius: 4px;
}

/* ============================================================
   TABLE STYLES
   ============================================================ */
table {
  border-collapse: collapse;
  width: 100%;
  table-layout: auto;
  margin-top: 1em;
}

th, td {
  border: 1px solid #ccc;
  padding: 6px;
  text-align: left;
}

th {
  background: #f5f5f5;
  font-weight: bold;
}

#userTbl th,
#userTbl td {
  border: 1px solid #ccc;
}

.control-table {
  width: 100%;
  table-layout: fixed;
  margin-bottom: 0;
}

#controlTable {
  margin-bottom: 0;
  border-collapse: collapse;
}

.mui-table {
  width: 100%;
  border-collapse: collapse;
  background: transparent;
  border-radius: 8px;
  overflow: hidden;
}

.mui-table th,
.mui-table td {
  padding: 12px 14px;
  text-align: left;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.03);
}

.mui-table thead th {
  font-size: 0.9rem;
  color: var(--mui-muted);
  background: rgba(255, 255, 255, 0.02);
}

.mui-table tbody tr:hover td {
  background: rgba(255, 255, 255, 0.01);
}

/* ============================================================
   MODAL & OVERLAY STYLES
   ============================================================ */
.modal-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.5);
  z-index: 1000;
}

.modal-overlay.show {
  display: flex;
  justify-content: center;
  align-items: center;
}

.modal-content {
  background: #fff;
  max-width: 400px;
  margin: 5% auto;
  padding: 20px;
  border-radius: 8px;
  position: relative;
  box-shadow: var(--box-shadow);
}

.modal-close {
  position: absolute;
  top: 10px;
  right: 15px;
  cursor: pointer;
  font-size: 20px;
  background: none;
  border: none;
  padding: 0;
  width: auto;
}

.modal-form label {
  display: block;
  margin-bottom: 10px;
}

.modal-form input,
.modal-form select {
  width: 100%;
  padding: 5px;
  margin-top: 5px;
}

.modal-form button {
  padding: 6px 12px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  width: 100%;
}

.modal-form button[type="submit"] {
  background: var(--navy);
  color: #fff;
}

.delete-modal-content {
  max-width: 350px;
  margin: 10% auto;
}

.qr-modal-content {
  max-width: 400px;
  margin: 10% auto;
}

.create-modal-content {
  max-width: 400px;
  margin: 5% auto;
}

/* Channel mapping modal */
#channelMappingModal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 10000;
  justify-content: center;
  align-items: center;
}

#channelMappingContent {
  background: white;
  padding: 2em;
  border-radius: 8px;
  max-width: 600px;
  max-height: 80vh;
  overflow-y: auto;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.channel-row {
  display: flex;
  align-items: center;
  margin-bottom: 10px;
}

.channel-row label {
  width: 100px;
  font-weight: bold;
}

.channel-row select {
  flex: 1;
  padding: 5px;
}

/* Loading overlay */
#loadingOverlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

#loadingMessage {
  background: white;
  padding: 2em;
  border-radius: 8px;
  text-align: center;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* Modern UI modal */
.mui-modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease;
}

.mui-modal.show {
  opacity: 1;
  pointer-events: auto;
}

.mui-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 6, 23, 0.65);
  backdrop-filter: blur(3px);
}

.mui-modal__panel {
  position: relative;
  background: var(--mui-surface);
  color: var(--mui-text);
  border-radius: 12px;
  padding: 18px;
  max-width: 720px;
  width: 92%;
  box-shadow: 0 20px 50px rgba(2, 6, 23, 0.6);
  transform: translateY(8px);
  transition: transform 0.18s ease;
}

.mui-modal.show .mui-modal__panel {
  transform: translateY(0);
}

.mui-modal__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.mui-modal__title {
  font-weight: 700;
}

.mui-modal__close {
  background: transparent;
  border: 0;
  color: var(--mui-muted);
  cursor: pointer;
  padding: 8px;
  border-radius: 8px;
  font-size: 1.1rem;
  width: auto;
}

.mui-modal__close:hover {
  color: var(--mui-text);
  background: rgba(255, 255, 255, 0.02);
}

.mui-modal__body {
  color: var(--mui-text);
}

/* ============================================================
   CARD & CONTAINER STYLES
   ============================================================ */
.container {
  width: clamp(320px, 95vw, 3840px);
  margin: 28px auto;
  padding: 18px;
}

@media (max-width: 420px) {
  .container {
    padding: 12px;
    margin: 18px auto;
  }
}

.content {
  max-width: 600px;
  margin: 2em auto;
  text-align: center;
  background: #fff;
  padding: 20px;
  border: 1px solid #ddd;
  border-radius: 6px;
}

/* ============================================================
   HOME PAGE
   ============================================================ */

.home-main {
  min-height: calc(100vh - 56px);
  background: #f2f5f9;
}

/* Hero */
.home-hero {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 5rem 1.5rem 4rem;
  text-align: center;
}

.home-hero-inner {
  max-width: 640px;
}

/* Dark-navy pill behind the logo */
.home-logo-wrap {
  display: inline-block;
  background: var(--light-color);
  border-radius: 18px;
  padding: 1.25rem 2.25rem;
  margin-bottom: 1.75rem;
  box-shadow: 0 6px 24px rgba(6, 62, 111, 0.22);
}

.home-logo {
  height: 72px;
  width: auto;
  display: block;
}

.home-title {
  color: #162032;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 700;
  margin-bottom: 0.75rem;
  letter-spacing: -0.02em;
}

.home-subtitle {
  color: #5a6a7e;
  font-size: 1.1rem;
  margin-bottom: 2rem;
}

.home-cta {
  display: inline-block;
  background: var(--navy);
  color: #fff !important;
  padding: 0.75rem 2.25rem;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none !important;
  transition: var(--transition);
  box-shadow: 0 4px 16px rgba(6, 62, 111, 0.25);
}

.home-cta:hover {
  background: #084f8e;
  transform: translateY(-2px);
  box-shadow: 0 6px 22px rgba(6, 62, 111, 0.38);
}

.home-logged-in {
  color: #5a6a7e;
  margin-bottom: 0;
  font-size: 0.95rem;
}

.home-logged-in strong {
  color: #162032;
}

/* Social section */
.home-socials {
  padding: 1rem 1.5rem 5rem;
}

.home-section-title {
  text-align: center;
  color: #8a9db5;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 2rem;
}

.social-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
  gap: 1.25rem;
  max-width: 960px;
  margin: 0 auto;
}

/* Base card - light mode */
.social-card {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  background: #fff;
  border: 1px solid #dde4ee;
  border-radius: 14px;
  padding: 1.5rem;
  text-decoration: none !important;
  color: #162032;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.social-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 14px;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.social-card:hover {
  transform: translateY(-4px);
  border-color: #c4d0e0;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.1);
  color: #162032;
}

.social-card:hover::before {
  opacity: 1;
}

/* Facebook */
.social-card--facebook::before {
  background: linear-gradient(135deg, rgba(24, 119, 242, 0.08), transparent 60%);
}
.social-card--facebook .social-card__icon {
  background: #1877f2;
}
.social-card--facebook .social-card__cta {
  color: #4d9ef7;
}

/* Instagram */
.social-card--instagram::before {
  background: linear-gradient(135deg, rgba(225, 48, 108, 0.08), rgba(253, 180, 60, 0.05) 60%);
}
.social-card--instagram .social-card__icon {
  background: linear-gradient(45deg, #fd5949, #d6249f, #285aeb);
}
.social-card--instagram .social-card__cta {
  color: #e05d9a;
}

/* LinkedIn */
.social-card--linkedin::before {
  background: linear-gradient(135deg, rgba(10, 102, 194, 0.08), transparent 60%);
}
.social-card--linkedin .social-card__icon {
  background: #0a66c2;
}
.social-card--linkedin .social-card__cta {
  color: #4d9ef7;
}

/* Card parts */
.social-card__header {
  display: flex;
  align-items: center;
  gap: 0.9rem;
}

.social-card__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 10px;
  flex-shrink: 0;
  color: #fff;
}

.social-card__icon svg {
  width: 22px;
  height: 22px;
}

.social-card__meta {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}

.social-card__platform {
  font-size: 0.75rem;
  color: #8a9db5;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
}

.social-card__handle {
  font-size: 1rem;
  font-weight: 700;
  color: #162032;
}

.social-card__desc {
  font-size: 0.9rem;
  color: #5a6a7e;
  line-height: 1.55;
  margin: 0;
}

.social-card__cta {
  font-size: 0.85rem;
  font-weight: 600;
  margin-top: auto;
}

.section {
  background: linear-gradient(180deg, var(--glass), transparent);
  padding: 18px;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin-bottom: 18px;
}

.login-container {
  max-width: 350px;
  margin: 100px auto;
  padding: 30px;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.form-section {
  background: #f8f9fa;
  padding: 1.5rem;
  border-radius: var(--radius);
  margin-bottom: 2rem;
}

.main-card {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(20px);
  border-radius: var(--radius);
  box-shadow: var(--box-shadow);
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: var(--transition);
  overflow: hidden;
}

.mui-card {
  background: var(--mui-card);
  padding: 16px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.03);
  box-shadow: 0 10px 30px rgba(2, 6, 23, 0.5);
  margin-top: 8px;
  margin-bottom: 8px;
}

.mui-card-title {
  font-weight: 700;
}

.mui-card-sub {
  font-size: 0.9rem;
  color: var(--mui-muted);
}

.event-card {
  border: 1px solid #dee2e6;
  border-radius: var(--radius);
  margin-bottom: 1rem;
  transition: var(--transition);
  background: white;
}

.event-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.event-header {
  padding: 1rem;
  border-bottom: 1px solid #eee;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* ============================================================
   HEADER & SECTION STYLES
   ============================================================ */
.header-section {
  background: var(--event-gradient);
  color: white;
  padding: 2rem;
  margin: -1rem -1rem 2rem -1rem;
  position: relative;
  overflow: hidden;
}

.section-header {
  border-bottom: 3px solid #667eea;
  margin-bottom: 1.5rem;
  padding-bottom: 0.5rem;
}

.no-events {
  text-align: center;
  padding: 3rem 2rem;
  color: #6c757d;
}

/* ============================================================
   NAVBAR MODERN UI STYLES
   ============================================================ */
.mui-navbar {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px 18px;
  background: linear-gradient(180deg, var(--glass), var(--glass-2));
  backdrop-filter: blur(6px);
  border-radius: 12px;
}

.mui-brand {
  font-weight: 700;
  color: var(--mui-text);
  letter-spacing: 0.2px;
}

.mui-nav {
  display: flex;
  gap: 10px;
  align-items: center;
}

.mui-nav a,
.mui-nav--mobile a {
  color: var(--mui-muted);
  text-decoration: none;
  padding: 8px;
  border-radius: 8px;
  display: block;
}

.mui-nav a:hover,
.mui-nav--mobile a:hover {
  color: var(--mui-text);
  background: rgba(255, 255, 255, 0.02);
}

.mui-nav .active {
  color: var(--mui-accent);
}

.mui-toggle {
  display: none;
  background: transparent;
  border: 0;
  color: var(--mui-text);
}

@media (max-width: 720px) {
  .mui-nav {
    display: none;
  }

  .mui-toggle {
    display: inline-flex;
  }

  .mui-nav--mobile {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-top: 8px;
  }

  .mui-nav--mobile.show {
    display: flex;
  }
}

/* ============================================================
   BADGE & STATUS STYLES
   ============================================================ */
.status-bubble {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  margin-right: 8px;
  vertical-align: middle;
}

.status-bubble.online {
  background-color: #4caf50;
}

.status-bubble.offline {
  background-color: #f44336;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
  border-radius: 25px;
  font-size: 0.9rem;
  border: 1px solid rgba(255, 255, 255, 0.3);
}

.event-status-active {
  background: var(--success-color);
  color: white;
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 500;
}

.event-status-inactive {
  background: var(--danger-color);
  color: white;
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 500;
}

.active-event {
  border-left: 4px solid #28a745;
}

.inactive-event {
  border-left: 4px solid #6c757d;
  opacity: 0.8;
}

.mui-badge {
  display: inline-block;
  padding: 6px 8px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.8rem;
}

.mui-badge--success {
  background: rgba(46, 204, 113, 0.12);
  color: var(--mui-success);
}

.mui-badge--danger {
  background: rgba(255, 107, 107, 0.08);
  color: var(--mui-danger);
}

.mui-badge--sm {
  padding: 4px 6px;
  font-size: 0.75rem;
}

/* ============================================================
   TAB & NAVIGATION STYLES
   ============================================================ */
.nav-tabs-custom {
  border-bottom: 2px solid #dee2e6;
  margin-bottom: 2rem;
}

.nav-tabs-custom .nav-link {
  color: #6c757d;
  border: none;
  border-bottom: 3px solid transparent;
  padding: 1rem 1.5rem;
  font-weight: 500;
  transition: var(--transition);
}

.nav-tabs-custom .nav-link:hover {
  color: var(--secondary-color);
  border-bottom-color: var(--secondary-color);
}

.nav-tabs-custom .nav-link.active {
  color: var(--secondary-color);
  border-bottom-color: var(--secondary-color);
  background: none;
}

.mui-tabs {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
  margin-bottom: 8px;
}

.mui-tabs__nav {
  display: flex;
  gap: 8px;
}

.mui-tabs__btn {
  padding: 8px 12px;
  border-radius: 8px;
  background: transparent;
  border: 1px solid transparent;
  color: var(--mui-muted);
  cursor: pointer;
}

.mui-tabs__btn.active {
  background: rgba(255, 255, 255, 0.02);
  color: var(--mui-text);
  border-color: rgba(255, 255, 255, 0.03);
}

.mui-tabs__panel {
  padding: 12px;
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.01), transparent);
  border: 1px solid rgba(255, 255, 255, 0.02);
}

/* ============================================================
   UPLOAD ZONE & FILE STYLES
   ============================================================ */
.upload-zone {
  border: 2px dashed #dee2e6;
  border-radius: var(--radius);
  padding: 2rem;
  text-align: center;
  background: #f8f9fa;
  transition: var(--transition);
}

.upload-zone:hover {
  border-color: var(--secondary-color);
  background: #e9ecef;
}

.mui-file {
  display: flex;
  align-items: center;
  gap: 8px;
}

.mui-file input[type="file"] {
  display: none;
}

.mui-file__btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 8px;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.06);
  cursor: pointer;
}

.mui-file__name {
  font-size: 0.9rem;
  color: var(--mui-muted);
}

/* ============================================================
   ANIMATION & LOADING STYLES
   ============================================================ */
.spinner {
  border: 4px solid #f3f3f3;
  border-top: 4px solid #3498db;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  animation: spin 1s linear infinite;
  margin: 0 auto 1em auto;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

.connection-status {
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% {
    opacity: 1;
  }
  50% {
    opacity: 0.7;
  }
  100% {
    opacity: 1;
  }
}

.mui-spinner {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 4px solid rgba(255, 255, 255, 0.06);
  border-top-color: var(--mui-accent);
  animation: mui-spin 0.8s linear infinite;
}

@keyframes mui-spin {
  to {
    transform: rotate(360deg);
  }
}

/* ============================================================
   FORM & CONTROL STYLES
   ============================================================ */
.mui-form {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.mui-label {
  font-size: 0.9rem;
  color: var(--mui-muted);
}

.mui-textbox {
  position: relative;
}

.mui-textbox input,
.mui-textbox textarea {
  width: 100%;
  padding: 14px 12px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: transparent;
  color: var(--mui-text);
  resize: vertical;
}

.mui-textbox label {
  position: absolute;
  left: 12px;
  top: 12px;
  color: var(--mui-muted);
  pointer-events: none;
  transition: all 0.12s ease;
  transform-origin: left top;
  z-index: 2;
  background: transparent;
  padding: 0 4px;
}

.mui-textbox input:focus + label,
.mui-textbox input:not(:placeholder-shown) + label,
.mui-textbox textarea:focus + label,
.mui-textbox textarea:not(:placeholder-shown) + label,
.mui-textbox.has-value label {
  transform: translateY(-18px) scale(0.82);
  opacity: 0.98;
  color: var(--mui-accent);
  font-size: 0.85rem;
  background: var(--mui-surface);
  padding: 0 6px;
}

/* ============================================================
   ALERT & MESSAGE STYLES
   ============================================================ */
.error {
  color: #dc3545;
  margin-bottom: 15px;
  padding: 10px;
  background: #f8d7da;
  border: 1px solid #f5c6cb;
  border-radius: 4px;
  font-size: 14px;
}

.msg {
  color: green;
}

.err {
  color: red;
}

.error-text {
  color: red;
}

.warning {
  color: red;
  font-weight: bold;
}

.debug {
  color: #555;
  font-size: 12px;
  margin-top: 20px;
  background: #f3f3f3;
  padding: 10px;
  border-radius: 4px;
  word-break: break-all;
}

.mui-alert {
  padding: 12px 14px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.03);
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.mui-alert .title {
  font-weight: 700;
}

.mui-alert--info {
  background: linear-gradient(180deg, rgba(79, 156, 249, 0.08), rgba(79, 156, 249, 0.03));
  color: var(--mui-accent);
}

.mui-alert--success {
  background: linear-gradient(180deg, rgba(46, 204, 113, 0.06), rgba(46, 204, 113, 0.03));
  color: var(--mui-success);
}

.mui-alert--danger {
  background: linear-gradient(180deg, rgba(255, 107, 107, 0.04), rgba(255, 107, 107, 0.02));
  color: var(--mui-danger);
}

.mui-alert--warn {
  background: linear-gradient(180deg, rgba(255, 195, 0, 0.04), rgba(255, 195, 0, 0.02));
  color: #ffbf00;
}

/* ============================================================
   GROUP & COLLAPSIBLE STYLES
   ============================================================ */
.groupbox {
  margin: 2px;
}

.group-header {
  background: #4a90e2;
  color: white;
  font-weight: bold;
  text-align: left;
}

.group-header td {
  padding: 8px;
  font-size: 14px;
  border: 1px solid #ccc;
}

.group-header input[type="checkbox"] {
  margin-right: 10px;
  cursor: pointer;
}

.group-toggle-header {
  background: #e8f4f8;
}

.group-toggle-header:hover {
  background: #d0e8f0;
}

.user-group-header {
  background-color: #4a90e2;
  cursor: pointer;
}

.group-select-all {
  transform: scale(1.1);
}

.group-select-all:indeterminate {
  opacity: 0.7;
}

.group-color-card {
  border-left: 4px solid #6c757d;
}

.color-button {
  width: 28px;
  height: 28px;
  padding: 0;
  border: 1px solid #dee2e6;
  border-radius: 4px;
  margin: 2px;
  cursor: pointer;
  display: inline-block;
}

.color-button.active {
  border: 2px solid #000;
}

/* Card header for collapsible groups */
.card-header[data-bs-toggle="collapse"] {
  transition: background-color 0.3s ease;
}

.card-header[data-bs-toggle="collapse"]:hover {
  background-color: #3d7fc7 !important;
}

.card-header .fa-chevron-down {
  transition: transform 0.3s ease;
}

.card-header[aria-expanded="false"] .fa-chevron-down {
  transform: rotate(-90deg);
}

/* ============================================================
   ONLINE LIST & STATUS STYLES
   ============================================================ */
#onlineList {
  margin-top: 1em;
  padding: 1em;
  background: #eef;
  border: 1px solid #99f;
}

/* ============================================================
   LOG & SCROLLABLE CONTAINERS
   ============================================================ */
.log {
  background: #f4f4f4;
  padding: 1em;
  height: 300px;
  overflow-y: scroll;
  border: 1px solid #ccc;
}

.scrollable-container {
  max-height: 300px;
  overflow-y: auto;
}

/* ============================================================
   CODE & PRE-FORMATTED TEXT
   ============================================================ */
pre {
  background: #222;
  color: #0f0;
  padding: 1em;
  border-radius: 5px;
  overflow-x: auto;
}

textarea {
  width: 100%;
  height: 120px;
}

.command-input {
  width: 80%;
}

/* ============================================================
   BACK LINK STYLES
   ============================================================ */
.back-link {
  text-align: center;
  margin-top: 15px;
}

.back-link a {
  color: var(--navy);
  text-decoration: none;
  font-size: 14px;
}

.back-link a:hover {
  text-decoration: underline;
}

/* ============================================================
   QR CODE STYLES
   ============================================================ */
.qr {
  margin: 10px 0;
}

.qr-code {
  margin: 10px 0;
}

.qr-code img {
  max-width: 200px;
  height: auto;
}

/* ============================================================
   FIELDSET & LEGEND
   ============================================================ */
fieldset {
  border: 1px solid #ccc;
  padding: 10px;
  margin: 10px 0;
}

legend {
  font-weight: bold;
}

/* ============================================================
   UTILITY CLASSES
   ============================================================ */
/* Text alignment */
.text-align-center {
  text-align: center;
}

/* Colors & backgrounds */
.background-green {
  background: #4caf50;
}

.color-white {
  color: white;
}

.changed {
  background: #ffd4d4 !important;
}

/* Sizing */
.full-width {
  width: 100%;
}

.width-100-percent {
  width: 100%;
}

.half-width {
  width: calc(50% - 20px);
}

.half-width-margin {
  width: calc(50% - 20px);
  margin-right: 4px;
}

.col-12-5 {
  width: 12.5%;
}

/* Display & Box sizing */
.box-sizing-border-box {
  box-sizing: border-box;
}

.hidden-input {
  display: none;
}

.inline-block-form {
  display: inline-block;
}

.inline-flex-label {
  display: inline-flex;
  align-items: center;
  width: calc(50% - 2px);
  margin-right: 4px;
}

/* Spacing */
.margin-left-1em {
  margin-left: 1em;
}

.margin-1em-vertical {
  margin: 1em 0;
}

.margin-right-6px {
  margin-right: 6px;
}

.margin-top-2em {
  margin-top: 2em;
}

.padding-6px {
  padding: 6px;
}

/* Pointer & cursor */
.cursor-pointer {
  cursor: pointer;
}

.cursor-default {
  cursor: default;
}

/* Selection & opacity */
.user-select-none {
  user-select: none;
}

.opacity-1 {
  opacity: 1;
}

/* Vertical alignment */
.vertical-align-middle {
  vertical-align: middle;
}

/* Control cell styling */
.control-cell {
  padding: 10px;
  background: #f5f5f5;
  border: 1px solid #ccc;
  vertical-align: top;
}

/* ============================================================
   MODERN UI COMPONENTS (Additional)
   ============================================================ */
.h1 {
  font-size: 1.25rem;
  margin: 0 0 8px 0;
}

.h2 {
  font-size: 1rem;
  margin: 0 0 8px 0;
  color: var(--mui-muted);
}

.row {
  display: flex;
  gap: 12px;
  align-items: center;
}

.col {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.mr-auto {
  margin-right: auto;
}

.center {
  display: flex;
  align-items: center;
  justify-content: center;
}

.small {
  font-size: 0.85rem;
  color: var(--mui-muted);
}

/* Switch/Toggle */
.mui-switch {
  display: inline-flex;
  align-items: center;
  gap: 24px;
  padding: 8px 0;
  margin-top: 6px;
  margin-bottom: 8px;
}

.mui-switch > .small {
  margin-left: 28px;
  align-self: center;
  line-height: 1;
  transform: translateY(2px);
}

.mui-switch__track {
  width: 44px;
  height: 26px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 999px;
  padding: 3px;
  cursor: pointer;
  position: relative;
  transition: background 0.12s ease;
}

.mui-switch__thumb {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--mui-text);
  box-shadow: 0 2px 6px rgba(2, 6, 23, 0.4);
  transform: translateX(0);
  transition: transform 0.12s ease;
}

.mui-switch.on .mui-switch__track {
  background: var(--btn-primary-gradient);
}

.mui-switch.on .mui-switch__thumb {
  transform: translateX(18px);
  background: white;
}

/* Progress bar */
.mui-progress {
  background: rgba(255, 255, 255, 0.04);
  height: 12px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.02);
  margin-top: 8px;
  margin-bottom: 8px;
}

.mui-progress__fill {
  height: 100%;
  background: var(--btn-primary-gradient);
  width: 0%;
  transition: width 0.22s ease;
}

.mui-progress__meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  color: var(--mui-muted);
  margin-top: 8px;
}

/* Accordion */
.mui-accordion {
  border-radius: 8px;
  overflow: hidden;
  margin-top: 8px;
  margin-bottom: 8px;
}

.mui-accordion__item + .mui-accordion__item {
  border-top: 1px solid rgba(255, 255, 255, 0.03);
}

.mui-accordion__header {
  padding: 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  background: transparent;
  border: none;
  width: 100%;
}

.mui-accordion__body {
  padding: 12px;
  border-top: 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.01), transparent);
  display: none;
}

.mui-accordion__item.open .mui-accordion__body {
  display: block;
}

/* Range slider */
.mui-range {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.mui-range input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  height: 10px;
  background: transparent;
  border-radius: 999px;
  outline: none;
}

.mui-range input[type="range"]::-webkit-slider-runnable-track {
  height: 10px;
  background: rgba(255, 255, 255, 0.04);
  border-radius: 999px;
}

.mui-range input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  margin-top: -4px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--mui-text);
  box-shadow: 0 4px 12px rgba(11, 18, 36, 0.55);
  cursor: pointer;
  border: 2px solid rgba(255, 255, 255, 0.06);
}

.mui-range input[type="range"]::-moz-range-track {
  height: 10px;
  background: rgba(255, 255, 255, 0.04);
  border-radius: 999px;
}

.mui-range input[type="range"]::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--mui-text);
  box-shadow: 0 4px 12px rgba(11, 18, 36, 0.55);
  border: 2px solid rgba(255, 255, 255, 0.06);
}

.mui-range input[type="range"]:focus::-webkit-slider-runnable-track {
  box-shadow: 0 0 0 6px rgba(79, 156, 249, 0.06);
}

.mui-range input[type="range"]:focus::-moz-range-track {
  box-shadow: 0 0 0 6px rgba(79, 156, 249, 0.06);
}

.mui-range .range-value {
  font-size: 0.85rem;
  color: var(--mui-muted);
}

/* Tooltip */
.mui-tooltip {
  position: relative;
  display: inline-block;
}

.mui-tooltip[data-tip]:hover::after {
  content: attr(data-tip);
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  bottom: calc(100% + 8px);
  background: var(--mui-surface);
  color: var(--mui-text);
  padding: 6px 8px;
  border-radius: 6px;
  font-size: 0.85rem;
  white-space: nowrap;
  box-shadow: 0 6px 18px rgba(2, 6, 23, 0.6);
}

/* Toast notifications */
.mui-toast-container {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 1100;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.mui-toast {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(255, 255, 255, 0.01));
  padding: 10px 14px;
  border-radius: 8px;
  color: var(--mui-text);
  box-shadow: 0 6px 18px rgba(2, 6, 23, 0.6);
  opacity: 0;
  transform: translateY(6px);
  transition: all 0.18s ease;
}

.mui-toast.show {
  opacity: 1;
  transform: translateY(0);
}

/* Ghost surface */
.mui-ghost-surface {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(255, 255, 255, 0.00));
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.02);
  padding: 12px;
}

/* Preview grid */
.preview-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

@media (max-width: 900px) {
  .preview-grid {
    grid-template-columns: 1fr;
  }
}

.preview-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.preview-cards .mui-card {
  padding: 16px;
}

/* Menu/Dropdown */
.mui-menu {
  position: relative;
}

.mui-menu__list {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 180px;
  background: var(--mui-surface);
  border-radius: 8px;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.03);
  box-shadow: 0 10px 30px rgba(2, 6, 23, 0.6);
  display: none;
}

.mui-menu__list.show {
  display: block;
}

.mui-menu__item {
  padding: 10px;
  border-radius: 6px;
  color: var(--mui-text);
  cursor: pointer;
}

.mui-menu__item:hover {
  background: rgba(255, 255, 255, 0.02);
}

/* Breadcrumbs */
.mui-breadcrumbs {
  display: flex;
  gap: 8px;
  align-items: center;
  font-size: 0.9rem;
  color: var(--mui-muted);
}

.mui-breadcrumbs a {
  color: var(--mui-muted);
  text-decoration: none;
}

.mui-breadcrumbs .sep {
  color: rgba(255, 255, 255, 0.06);
}

/* Pagination */
.mui-pagination {
  display: flex;
  gap: 6px;
  align-items: center;
}

.mui-pagination .page {
  padding: 6px 10px;
  border-radius: 6px;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.03);
  cursor: pointer;
  color: var(--mui-muted);
}

.mui-pagination .page.active {
  background: rgba(255, 255, 255, 0.02);
  color: var(--mui-text);
  border-color: rgba(255, 255, 255, 0.04);
}

/* Search bar */
.mui-search {
  display: flex;
  align-items: center;
  gap: 8px;
  border-radius: 10px;
  padding: 6px;
  border: 1px solid rgba(255, 255, 255, 0.04);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.01), rgba(255, 255, 255, 0.00));
}

.mui-search input {
  background: transparent;
  border: 0;
  color: var(--mui-text);
  outline: none;
  padding: 8px 10px;
  flex: 1;
  min-width: 0;
  font-size: 0.95rem;
}

.mui-search input::placeholder {
  color: var(--mui-muted);
}

.mui-search .mui-btn {
  padding: 8px 12px;
  height: 36px;
  border-radius: 8px;
}

.mui-search .mui-btn:active {
  transform: none;
}

/* Hamburger menu */
.mui-hamburger {
  width: 36px;
  height: 28px;
  display: inline-flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 6px;
  cursor: pointer;
  background: transparent;
  border: none;
}

.mui-hamburger span {
  display: block;
  height: 3px;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 3px;
}

/* Checkbox variants */
.mui-checkbox {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.checkbox-simple {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.checkbox-simple .inp-cbx {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.checkbox-simple .cbx {
  user-select: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
  border-radius: 6px;
}

.checkbox-simple .box {
  width: 18px;
  height: 18px;
  border-radius: 3px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  transition: background 0.12s linear, border-color 0.12s linear;
}

.checkbox-simple .box svg {
  opacity: 0;
  transform: scale(0.9);
  transition: opacity 0.08s linear, transform 0.12s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.checkbox-simple .label {
  line-height: 18px;
  color: var(--mui-text);
}

.checkbox-simple .inp-cbx:checked + .cbx .box {
  background: var(--btn-primary-gradient);
  border-color: transparent;
}

.checkbox-simple .inp-cbx:checked + .cbx .box svg {
  opacity: 1;
  transform: scale(1);
}

/* ============================================================
   DEVICE & RESPONSIVE SPECIFIC STYLES
   ============================================================ */
select,
button {
  margin: 0.5em 0;
}

th.select,
td.select {
  width: 40px;
  text-align: center;
}

.group-row {
  display: none;
}

/* Event network badges */
.event-network {
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
  border-radius: 25px;
  font-size: 0.9rem;
  border: 1px solid rgba(255, 255, 255, 0.3);
}

/* ============================================================
   ACCESSIBILITY
   ============================================================ */
:focus {
  outline: none;
}

:focus-visible {
  outline: 2px solid rgba(79, 156, 249, 0.35);
  outline-offset: 2px;
}

/* ============================================================
   RESPONSIVE DESIGN
   ============================================================ */
@media (max-width: 768px) {
  .event-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }

  .nav-tabs-custom .nav-link {
    padding: 0.75rem 1rem;
    font-size: 0.9rem;
  }

  .header-section {
    padding: 1.5rem;
    margin: -1rem -1rem 1.5rem -1rem;
  }

  body {
    margin: 1em;
  }
}

@media (max-width: 600px) {
  .login-container {
    max-width: 90%;
    margin: 50px auto;
    padding: 20px;
  }

  .container {
    padding: 12px;
    margin: 10px auto;
  }
}

/* ============================================================
   CONNECTION TESTER STYLES
   ============================================================ */

.connection-container {
  max-width: 100%;
  margin: 0;
  padding: 20px;
  min-height: calc(100vh - 76px);
}

.connection-flex-layout {
  display: flex;
  gap: 20px;
  width: 100%;
  min-height: calc(100vh - 200px);
}

.connection-left-panel {
  flex: 0 0 400px;
  max-width: 400px;
}

.connection-right-panel {
  flex: 1;
  min-width: 0;
}

@media (max-width: 1024px) {
  .connection-flex-layout {
    flex-direction: column;
  }
  
  .connection-left-panel {
    flex: 1;
    max-width: 100%;
  }
}

.page-header {
  background: white;
  padding: 20px;
  border-radius: 6px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  margin-bottom: 20px;
}

.page-header h1 {
  margin: 0;
  color: #063e6f;
  font-size: 24px;
  font-weight: 600;
  letter-spacing: 0.5px;
}

.page-header p {
  margin: 8px 0 0 0;
  color: #666;
  font-size: 14px;
}

.test-panel {
  background: white;
  padding: 20px;
  border-radius: 6px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  margin-bottom: 20px;
}

.test-panel .form-group {
  margin-bottom: 16px;
}

.test-panel .form-group:last-child {
  margin-bottom: 0;
}

.test-panel label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: #333;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.test-panel input[type="text"],
.test-panel input[type="number"] {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #d0d0d0;
  border-radius: 6px;
  font-size: 14px;
  font-family: inherit;
  transition: all 0.2s ease;
  box-sizing: border-box;
}

.test-panel input[type="text"]:focus,
.test-panel input[type="number"]:focus {
  outline: none;
  border-color: #063e6f;
  box-shadow: 0 0 0 3px rgba(6, 62, 111, 0.1);
}

.test-panel input[type="text"]:hover,
.test-panel input[type="number"]:hover {
  border-color: #999;
}

.help-text {
  font-size: 12px;
  color: #666;
  margin-top: 6px;
}

.row-inputs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.test-panel button {
  background: #063e6f;
  color: white;
  border: none;
  padding: 12px 24px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  width: 100%;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.test-panel button:hover:not(:disabled) {
  background: #0a5a9e;
  transform: translateY(-1px);
}

.test-panel button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.test-panel button[type="button"] {
  background: #27ae60;
  padding: 12px 16px;
  white-space: nowrap;
}

.test-panel button[type="button"]:hover {
  background: #229954;
}

.loading {
  display: none;
  text-align: center;
  padding: 20px;
  transition: opacity 0.3s ease;
}

.loading.show {
  display: block;
  opacity: 1;
}

.spinner {
  border: 4px solid #f3f3f3;
  border-top: 4px solid #063e6f;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  animation: spin 1s linear infinite;
  margin: 0 auto 10px;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.results {
  opacity: 0;
  transition: opacity 0.4s ease-in-out;
}

.results.show {
  opacity: 1;
}

.results > div {
  animation: fadeInUp 0.5s ease-out;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.error-message {
  background: #f8d7da;
  color: #721c24;
  padding: 12px;
  border-radius: 6px;
  margin-bottom: 20px;
  display: none;
  border: 1px solid #f5c6cb;
}

.error-message.show {
  display: block;
}

.result-card {
  background: white;
  border-left: 4px solid #063e6f;
  padding: 16px;
  margin-bottom: 16px;
  border-radius: 6px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.result-title {
  font-weight: 600;
  color: #063e6f;
  margin-bottom: 12px;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.result-icon {
  font-size: 18px;
}

.result-content {
  font-size: 14px;
  color: #555;
}

.result-line {
  margin-bottom: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.result-line:last-child {
  margin-bottom: 0;
}

.result-label {
  font-weight: 500;
  color: #666;
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 0.5px;
}

.result-value {
  color: #333;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, 'Courier New', monospace;
  font-size: 13px;
}

.status-badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 4px;
  font-weight: 600;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.status-success {
  background: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
}

.status-failed {
  background: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
}

.overall-status {
  background: #063e6f;
  color: white;
  padding: 16px;
  border-radius: 6px;
  margin-bottom: 20px;
  text-align: center;
  font-weight: 600;
  font-size: 16px;
  letter-spacing: 0.5px;
}

.overall-status.success {
  background: #27ae60;
}

.overall-status.failed {
  background: #e74c3c;
}

.timestamp {
  font-size: 12px;
  color: #999;
  margin-top: 16px;
  text-align: center;
}

@media (max-width: 600px) {
  .row-inputs {
    grid-template-columns: 1fr;
  }
}
