:root {
  --sidebar-width: 240px;
  --sidebar-min-width: 60px;
  --sidebar-bg-color: #171717;
}

/* Base styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: Arial, sans-serif;
  background: white;
  height: 100vh;
  font-family: sans-serif;
}

.app-container {
  display: flex;
  height: 100vh;
}

/* Sidebar styles */
.sidebar {
  width: var(--sidebar-width);
  background-color: var(--sidebar-bg-color);
  color: #ffffff;
  display: flex;
  flex-direction: column;
  height: 100%;
  transition: width 0.3s ease;
  overflow: hidden;
}

.sidebar-header {
  padding: 15px;
  background-color:black;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
}

.sidebar-header:hover{
  background-color:rgb(20, 20, 20);
}

.collapse-btn {
  background: none;
  border: none;
  color: #ffffff;
  cursor: pointer;
  font-size: 0.9em;
  padding: 5px;
}

.logo {
  width: 40px;
  height: auto;
  margin-right: 10px;
}

.logo-text{
  display: block;
  margin-right: 25px;
}
.logo-text .row1{
  color: #bb2d2d; 
  font-weight: bold;
  font-size: 0.8em;
}

.logo-text .row2{
  font-size: 1.2em;
  font-weight: bold;
}

.sidebar-menu {
  flex: 1;
  overflow-y: auto;
  padding-top: 15px;
}

.nav-item {
  padding: 10px 20px;
  cursor: pointer;
  border-left: 3px solid transparent;
  transition: background-color 0.2s;
  display: flex;
  align-items: center;
  width: 85%;
  margin-left: 6%;
  border-radius: 22px;
}

.nav-item:hover {
  background-color: #2c3c4f;
}

.nav-item.active {
  background-color: #282828;
}

.nav-icon {
  margin-right: 12px;
  width: 20px;
  text-align: center;
}

.user-section {
  padding: 15px;
  background-color: black;
  display: flex;
  justify-content: space-left;
  align-items: center;
}

.logout-btn {
  background: none;
  border: none;
  color: #ffffff;
  cursor: pointer;
  font-size: 1.2em;
  margin-right: 20px;
}

.user-info {
  font-size: 0.8em;
}

/* Minimized sidebar styles */
.minimized-sidebar {
  width: var(--sidebar-min-width);
  background-color: var(--sidebar-bg-color);
  display: none;
  flex-direction: column;
  height: 100%;
}

.min-sidebar-header {
  padding: 10px;
  background-color: var(--sidebar-bg-color);
  text-align: center;
  cursor: pointer;
}

.min-logo {
  max-width: 100%;
  height: auto;
}

.min-nav-item {
  padding: 15px 0;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
}

.min-nav-item:hover {
  background-color: #2c3c4f;
}

.min-nav-item.active {
  background-color: #39465a;
}

/* Main content area */
.main-view {
  flex: 1;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

#contentFrame {
  width: 100%;
  height: auto;
  border: none;
  flex: 1;
}


#payment-banner-container {
  width: 100%;
  margin-bottom: 20px;
  position: relative;
  z-index: 2;
  background: linear-gradient(102deg, rgba(215, 0, 0, 0.18) 0%, rgba(215, 0, 0, 0.08) 100%);
  border-top: 4px solid var(--main, #d70000);
  border-bottom: 1px solid var(--grey-300, #dee2e6);
  box-shadow: 0 10px 25px rgba(34, 34, 34, 0.12);
}

.payment-banner {
  padding: 22px 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  color: var(--grey-900, #212529);
  font-size: 15px;
}

.payment-banner-hidden {
  display: none;
}


.payment-banner-content {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.payment-banner-text {
  font-weight: 700;
  font-size: 17px;
  line-height: 1.45;
  color: var(--main-dark, #a70000);
}

.payment-banner-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}


.payment-banner-status {
  font-size: 13px;
  color: var(--grey-600, #6c757d);
  font-style: italic;
}

@media (min-width: 768px) {
  .payment-banner {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }

  .payment-banner-content {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    width: 100%;
  }

  .payment-banner-actions {
    justify-content: flex-end;
  }
}

/* Responsive behavior */
@media (max-width: 768px) {
  .sidebar {
    display: none;
  }
  
  .minimized-sidebar {
    display: flex;
  }
}

#nav-bottom-username{
  text-overflow: ellipsis;
  max-width: 160px;
  overflow: hidden;
  white-space: nowrap;
  display: inline-block;
}


/* Server Switcher */
.server-switcher-btn {
  background: none;
  border: 1px solid #333;
  color: #fff;
  padding: 5px 10px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 5px;
  border-radius: 4px;
  margin-left: auto;
}

.server-switcher-btn:hover {
  background: #333;
}

.server-dropdown {
  position: absolute;
  background: var(--sidebar-bg-color);
  border: 1px solid #333;
  width: var(--sidebar-width);
  max-height: 70vh;
  overflow-y: auto;
  z-index: 1000;
}

.server-search {
  width: 100%;
  padding: 10px;
  border: none;
  border-bottom: 1px solid #333;
  background: #222;
  color: #fff;
}

.server-list {
  max-height: calc(70vh - 40px);
  overflow-y: auto;
}

.server-item {
  padding: 10px 15px;
  cursor: pointer;
  color: #fff;
}

.server-item:hover {
  background: #333;
}

/* Sidebar lock overlay */
.sidebar-lock-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(215, 0, 0, 0.35);
  z-index: 100;
  pointer-events: auto;
  display: none;
}

.sidebar-lock-inner {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lock-icon {
  color: var(--error, #e74c3c);
  font-size: 42px;
}

.sidebar.sidebar-locked .nav-item,
.minimized-sidebar.sidebar-locked .min-nav-item {
  pointer-events: none;
  opacity: 0.5;
}

.sidebar.sidebar-locked {
  position: relative;
}
