:root {
  --primary-color: #0C1F29;
  --primary-dark: #081419;
  --primary-light: #1a3a4a;
  --accent-blue: #5a9fc7;
  --accent-blue-dim: #3a7fa7;
  --background-dark: #0a0e12;
  --background-light: #0f1519;
  --surface: #12181c;
  --surface-hover: #1a2228;
  --text-primary: #ffffff;
  --text-secondary: #a0aec0;
  --text-muted: #6b7280;
  --border-color: #1f2937;
  --success: #10b981;
  --error: #ef4444;
  --warning: #f59e0b;
  --info: #3b82f6;
}


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

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background-color: var(--background-dark);
  color: var(--text-primary);
  line-height: 1.6;
  font-size: 16px;
}

.navbar {
  background: var(--surface);
  border-bottom: 1px solid var(--border-color);
  padding: 1rem 0;
  position: sticky;
  top: 0;
  z-index: 1000;
}

.nav-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 2rem;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 2rem;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 1.35rem;
  font-weight: 600;
  color: #5a9fc7;
  justify-self: start;
}

.nav-logo i {
  font-size: 1.5rem;
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 2rem;
  justify-self: center;
}

.nav-link {
  color: var(--text-secondary);
  text-decoration: none;
  font-weight: 400;
  transition: color 0.2s;
  padding: 0.5rem 1rem;
  border-radius: 6px;
}

.nav-link:hover,
.nav-link.active {
  color: #5a9fc7;
}

.nav-auth {
  display: flex;
  align-items: center;
  justify-self: end;
}

.btn-login {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: #5a9fc7;
  color: white;
  border: none;
  padding: 0.625rem 1.25rem;
  border-radius: 6px;
  font-size: 0.95rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-login:hover {
  background: #4a8fb7;
}

.user-info {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  background: var(--surface-hover);
  padding: 0.5rem 0.875rem;
  border-radius: 6px;
}

.user-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 2px solid #5a9fc7;
}

.btn-logout {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  font-size: 1.1rem;
  padding: 0.5rem;
  border-radius: 4px;
  transition: color 0.2s;
}

.btn-logout:hover {
  color: var(--error);
}

.hero {
  position: relative;
  min-height: 500px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--background-dark);
  overflow: hidden;
}

.hero-overlay {
  display: none;
}

.hero-content {
  position: relative;
  text-align: center;
  z-index: 1;
  padding: 2rem;
}

.hero-icon {
  font-size: 5rem;
  color: #5a9fc7;
  margin-bottom: 1.5rem;
  opacity: 0.9;
}

.hero-title {
  font-size: 3.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.hero-subtitle {
  font-size: 1.2rem;
  color: var(--text-secondary);
  margin-bottom: 2rem;
  font-weight: 400;
}

.hero-buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.875rem 1.75rem;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 500;
  font-size: 1rem;
  transition: background 0.2s, opacity 0.2s;
  border: none;
  cursor: pointer;
}

.btn-primary {
  background: #5a9fc7;
  color: white;
}

.btn-primary:hover {
  background: #4a8fb7;
  opacity: 0.95;
}

.btn-secondary {
  background: var(--surface);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  cursor: pointer;
  border-radius: 6px;
  transition: all 0.2s;
}

.btn-secondary:hover {
  background: var(--surface-hover);
  border-color: #5a9fc7;
}

.btn-discord {
  background: #5865F2;
  color: white;
}

.btn-discord:hover {
  background: #4752C4;
  opacity: 0.95;
}

.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 2rem;
}

.section-title {
  font-size: 2rem;
  text-align: center;
  margin-bottom: 2.5rem;
  color: var(--text-primary);
  font-weight: 600;
}

.about-section {
  padding: 4rem 0;
  background: var(--background-light);
}

.about-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
}

.about-card {
  background: var(--surface);
  padding: 2rem;
  border-radius: 8px;
  border: 1px solid var(--border-color);
  transition: border-color 0.2s;
}

.about-card:hover {
  border-color: #5a9fc7;
}

.card-icon {
  font-size: 2.5rem;
  color: #5a9fc7;
  margin-bottom: 1rem;
  opacity: 0.9;
}

.about-card h3 {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
  color: var(--text-primary);
  font-weight: 600;
}

.about-card p {
  color: var(--text-secondary);
  line-height: 1.6;
  font-size: 0.95rem;
}

.stats-section {
  padding: 3rem 0;
  background: var(--surface);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
}

.stat-item {
  text-align: center;
  padding: 2rem;
}

.stat-number {
  font-size: 2.5rem;
  font-weight: 600;
  color: #5a9fc7;
  margin-bottom: 0.5rem;
}

.stat-label {
  font-size: 0.95rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 500;
}

.gallery-section {
  padding: 4rem 0;
  background: var(--background-dark);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}

.gallery-item {
  aspect-ratio: 16/9;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--border-color);
  transition: border-color 0.2s;
}

.gallery-item:hover {
  border-color: #5a9fc7;
}

.gallery-placeholder {
  width: 100%;
  height: 100%;
  background: var(--surface);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}

.gallery-placeholder i {
  font-size: 3rem;
  color: #5a9fc7;
}

.gallery-placeholder p {
  color: var(--text-secondary);
  font-weight: 600;
}

.join-section {
  padding: 4rem 0;
  background: var(--surface);
}

.join-content {
  text-align: center;
}

.join-content h2 {
  font-size: 2rem;
  margin-bottom: 1rem;
  color: var(--text-primary);
  font-weight: 600;
}

.join-content p {
  font-size: 1.1rem;
  margin-bottom: 2rem;
  color: var(--text-secondary);
}

.join-buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

.footer {
  background: var(--background-dark);
  padding: 2.5rem 0 1rem;
  border-top: 1px solid var(--border-color);
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-section h3,
.footer-section h4 {
  color: var(--text-primary);
  margin-bottom: 0.875rem;
  font-weight: 600;
  font-size: 1rem;
}

.footer-section ul {
  list-style: none;
}

.footer-section ul li {
  margin-bottom: 0.5rem;
  color: var(--text-secondary);
}

.footer-section a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.3s;
}

.footer-section a:hover {
  color: #5a9fc7;
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid var(--border-color);
  color: var(--text-muted);
}

.dashboard {
  display: flex;
  min-height: calc(100vh - 80px);
}

.sidebar {
  width: 280px;
  background: var(--surface);
  border-right: 1px solid var(--border-color);
  padding: 2rem 0;
}

.sidebar-header {
  padding: 1.5rem 1.5rem 1.5rem;
  border-bottom: 1px solid var(--border-color);
}

.sidebar-header h2 {
  color: var(--text-primary);
  font-size: 1.25rem;
  font-weight: 600;
}

.sidebar-nav {
  padding: 1rem 0;
}

.sidebar-link {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.875rem 1.5rem;
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.2s, background 0.2s;
  border-left: 2px solid transparent;
}

.sidebar-link:hover,
.sidebar-link.active {
  background: var(--surface-hover);
  color: #5a9fc7;
  border-left-color: #5a9fc7;
}

.sidebar-link i {
  font-size: 1.3rem;
  width: 24px;
}

.main-content {
  flex: 1;
  padding: 2rem;
  background: var(--background-light);
  overflow-y: auto;
}

.content-section {
  display: none;
  margin-bottom: 2rem;
}

.content-section.active {
  display: block;
}

.content-header {
  margin-bottom: 2.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border-color);
}

.content-header h1 {
  font-size: 2rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.content-header h1 i {
  color: #5a9fc7;
}

.content-subtitle {
  color: var(--text-secondary);
  font-size: 0.95rem;
  margin: 0;
}

.section-header h2 {
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.section-header h2 i {
  color: #5a9fc7;
  font-size: 1.2rem;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.header-actions {
  display: flex;
  gap: 0.75rem;
  align-items: center;
}

.info-banner {
  background: var(--surface);
  border: 1px solid var(--border-color);
  border-left: 3px solid #5a9fc7;
  padding: 1rem 1.25rem;
  border-radius: 6px;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 2rem;
  color: var(--text-secondary);
  font-size: 0.95rem;
}

.info-banner i {
  color: #5a9fc7;
  font-size: 1.2rem;
  flex-shrink: 0;
}

.member-info {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
}

.member-info span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.table-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid var(--border-color);
}

.data-table td.notes-preview {
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-style: italic;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 0;
}

.data-table td.actions {
  text-align: center;
  white-space: nowrap;
  vertical-align: middle;
}

.btn-icon {
  background: none;
  border: none;
  color: var(--accent);
  cursor: pointer;
  font-size: 0.95rem;
  padding: 4px 8px;
  border-radius: 4px;
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.btn-icon:hover {
  background: rgba(90, 159, 199, 0.1);
  color: var(--primary);
}

.rank-badge {
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: capitalize;
}

.rank-leader {
  background: rgba(255, 215, 0, 0.2);
  color: #ffd700;
}

.rank-mitglied {
  background: rgba(90, 159, 199, 0.2);
  color: #5a9fc7;
}

.sync-status {
  text-align: center;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.section-header h1 {
  font-size: 1.75rem;
  color: var(--text-primary);
  font-weight: 600;
}

.search-bar {
  position: relative;
  margin-bottom: 2rem;
}

.search-bar input {
  width: 100%;
  padding: 0.75rem 2.5rem 0.75rem 1rem;
  background: var(--surface);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  color: var(--text-primary);
  font-size: 0.95rem;
  transition: border-color 0.2s;
}

.search-bar input:focus {
  outline: none;
  border-color: #5a9fc7;
}

.search-bar i {
  position: absolute;
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
}

.table-container {
  background: var(--surface);
  border-radius: 8px;
  overflow-x: auto;
  border: 1px solid var(--border-color);
}

.table-container::-webkit-scrollbar {
  height: 8px;
}

.table-container::-webkit-scrollbar-track {
  background: var(--background-dark);
  border-radius: 4px;
}

.table-container::-webkit-scrollbar-thumb {
  background: var(--border-color);
  border-radius: 4px;
}

.table-container::-webkit-scrollbar-thumb:hover {
  background: #5a9fc7;
}

.data-table {
  width: 100%;
  min-width: 1000px;
  border-collapse: collapse;
}

.data-table thead {
  background: var(--surface-hover);
}

.data-table th {
  padding: 0.875rem 1rem;
  text-align: left;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  font-size: 0.8rem;
  letter-spacing: 0.5px;
}


.data-table td {
  padding: 0.875rem 1rem;
  border-top: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-size: 0.95rem;
}

.data-table tbody tr {
  transition: background 0.15s;
}

.data-table tbody tr:hover {
  background: var(--background-light);
}

.data-table .loading,
.data-table .empty {
  text-align: center;
  padding: 3rem;
  color: var(--text-muted);
}

.actions {
  display: flex;
  gap: 0.5rem;
}

.btn-icon {
  background: transparent;
  border: none;
  padding: 0.5rem;
  border-radius: 4px;
  cursor: pointer;
  color: var(--text-secondary);
  transition: color 0.2s;
  font-size: 1rem;
}

.btn-icon:hover {
  color: var(--text-primary);
}

.btn-edit:hover {
  color: var(--info);
}

.btn-delete:hover {
  color: var(--error);
}

.finance-summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.summary-card {
  background: var(--surface);
  padding: 1.5rem;
  border-radius: 8px;
  border: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  gap: 1rem;
}

.summary-icon {
  width: 50px;
  height: 50px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
}

.summary-card.income .summary-icon {
  background: rgba(16, 185, 129, 0.2);
  color: var(--success);
}

.summary-card.expense .summary-icon {
  background: rgba(239, 68, 68, 0.2);
  color: var(--error);
}

.summary-card.balance .summary-icon {
  background: rgba(12, 31, 41, 0.3);
  color: #2a5570;
}

.summary-info {
  flex: 1;
}

.summary-label {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-bottom: 0.25rem;
  font-weight: 500;
}

.summary-value {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--text-primary);
}

.status-badge {
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: capitalize;
}

.status-active {
  background: rgba(16, 185, 129, 0.2);
  color: var(--success);
}

.status-inactive {
  background: rgba(107, 114, 128, 0.2);
  color: var(--text-muted);
}

.status-suspended {
  background: rgba(239, 68, 68, 0.2);
  color: var(--error);
}

.type-badge {
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 600;
}

.type-income {
  background: rgba(16, 185, 129, 0.2);
  color: var(--success);
}

.type-expense {
  background: rgba(239, 68, 68, 0.2);
  color: var(--error);
}

.money-badge {
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 600;
}

.green-money-badge {
  background: rgba(16, 185, 129, 0.2);
  color: #10b981;
}

.black-money-badge {
  background: rgba(107, 114, 128, 0.3);
  color: #9ca3af;
}

.modal .modal-header h2 i {
  margin-right: 0.5rem;
}

#confirmModal .modal-body p {
  font-size: 1rem;
  color: var(--text-primary);
  margin-bottom: 2rem;
  text-align: center;
}

#confirmModal .fas.fa-exclamation-triangle {
  color: #f59e0b;
}

.amount.positive {
  color: var(--success);
  font-weight: 600;
}

.amount.negative {
  color: var(--error);
  font-weight: 600;
}

.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  padding: 2rem;
}

.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  z-index: 10000;
  align-items: center;
  justify-content: center;
}

.modal.active {
  display: flex;
}

.modal-content {
  background: var(--surface);
  border-radius: 8px;
  border: 1px solid var(--border-color);
  max-width: 500px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
}

.modal-header {
  padding: 1.5rem;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-header h2 {
  color: var(--text-primary);
  font-size: 1.25rem;
  font-weight: 600;
}

.modal-close {
  background: transparent;
  border: none;
  font-size: 1.5rem;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0.25rem;
  line-height: 1;
  transition: color 0.2s;
}

.modal-close:hover {
  color: var(--text-primary);
}

.modal-body {
  padding: 1.5rem;
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  color: var(--text-secondary);
  font-weight: 500;
  font-size: 0.9rem;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 0.625rem;
  background: var(--background-dark);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  color: var(--text-primary);
  font-size: 0.95rem;
  font-family: inherit;
  transition: border-color 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #5a9fc7;
}

.form-group input[list] {
  cursor: text;
}

.form-group input[list]::-webkit-calendar-picker-indicator {
  cursor: pointer;
  opacity: 0.6;
  transition: opacity 0.2s;
}

.form-group input[list]::-webkit-calendar-picker-indicator:hover {
  opacity: 1;
}

.modal-actions {
  display: flex;
  gap: 1rem;
  justify-content: flex-end;
  margin-top: 2rem;
}

.modal-actions .btn {
  min-width: 100px;
  font-size: 0.875rem;
  padding: 0.5rem 1rem;
}

.notification {
  position: fixed;
  top: 20px;
  right: 20px;
  background: var(--surface);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  padding: 0.875rem 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
  z-index: 3000;
  transform: translateX(400px);
  transition: transform 0.2s;
}

.notification.show {
  transform: translateX(0);
}

.notification-success {
  border-left: 4px solid var(--success);
}

.notification-error {
  border-left: 4px solid var(--error);
}

.notification-info {
  border-left: 4px solid var(--info);
}

.notification i {
  font-size: 1.5rem;
}

.notification-success i {
  color: var(--success);
}

.notification-error i {
  color: var(--error);
}

.notification-info i {
  color: var(--info);
}

@media (max-width: 768px) {
  .nav-container {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  
  .nav-logo {
    justify-self: center;
  }
  
  .nav-menu {
    display: none;
  }
  
  .nav-auth {
    justify-self: center;
  }
  
  .hero-title {
    font-size: 2.5rem;
  }
  
  .hero-subtitle {
    font-size: 1.2rem;
  }
  
  .dashboard {
    flex-direction: column;
  }
  
  .sidebar {
    width: 100%;
    border-right: none;
    border-bottom: 1px solid var(--border-color);
  }
  
  .sidebar-nav {
    display: flex;
    overflow-x: auto;
  }
  
  .sidebar-link {
    white-space: nowrap;
    border-left: none;
    border-bottom: 3px solid transparent;
  }
  
  .sidebar-link:hover,
  .sidebar-link.active {
    border-left: none;
    border-bottom-color: #5a9fc7;
  }
  
  .section-header {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .data-table {
    font-size: 0.9rem;
  }
  
  .data-table th,
  .data-table td {
    padding: 0.75rem 0.5rem;
  }
}
