* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: Arial, sans-serif;
}

body {
  background-color: #f5f5f5; /* Light mode background */
  color: #333333; /* Light mode text color */
  line-height: 1.6;
  transition: background-color 0.3s, color 0.3s;
}

body.dark-theme {
  background-color: #1a1a1a;
  color: #d0d0d0;
}

/* Sidebar Styles */
.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  width: 200px;
  height: 100%;
  background-color: #ffffff; /* Light mode sidebar background */
  border-right: 1px solid #cccccc; /* Light mode border */
  z-index: 1000;
}

body.dark-theme .sidebar {
  background-color: #1e1e1e;
  border-right: 1px solid #444;
}

.sidebar-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px;
  background-color: #3b82f6;
  color: #ffffff;
  border-radius: 0; /* Ensure no rounded corners */
}

body.dark-theme .sidebar-header {
  background-color: #2563eb;
}

.sidebar-header h2 {
  font-size: 20px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.sidebar-header h2 i {
  color: #ffffff;
}

body.dark-theme .sidebar-header h2 i {
  color: #ffffff;
}

.sidebar-content {
  padding: 10px;
}

.sidebar-user-actions {
  margin-bottom: 10px; /* Reduced margin */
}

.sidebar-user-actions > * {
  display: block;
  margin-bottom: 8px;
}

#sidebar-account-info {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sidebar-nav-item {
  padding: 8px 12px;
  background-color: #e5e7eb;
  border: none;
  border-radius: 0; /* Ensure no rounded corners */
  cursor: pointer;
  font-size: 16px;
  text-align: left;
  color: #333333;
  transition: background-color 0.3s;
}

.sidebar-nav-item:hover {
  background-color: #d1d5db;
}

.sidebar-nav-item.active {
  background-color: #3b82f6;
  color: #ffffff;
}

body.dark-theme .sidebar-nav-item {
  background-color: #2a2a2a;
  color: #d0d0d0;
}

body.dark-theme .sidebar-nav-item:hover {
  background-color: #3a3a3a;
}

body.dark-theme .sidebar-nav-item.active {
  background-color: #3b82f6;
}

/* Main Content Styles */
.main-content {
  margin-left: 200px;
}

/* Responsive Design */
@media (max-width: 768px) {
  .sidebar {
    position: relative;
    width: 100%;
    height: auto;
    border-right: none;
    border-bottom: 1px solid #cccccc;
  }

  body.dark-theme .sidebar {
    border-bottom: 1px solid #444;
  }

  .main-content {
    margin-left: 0;
  }
}

.container {
  margin: 0;
  padding: 5px; /* Further reduced padding */
}

/* Button Styles */
.btn {
  padding: 6px 12px;
  border: none;
  border-radius: 0; /* Ensure no rounded corners */
  cursor: pointer;
  font-size: 14px;
  transition: background-color 0.3s;
}

.btn-flat {
  background-color: #3b82f6;
  color: #ffffff;
}

.btn-flat:hover {
  background-color: #2563eb;
}

body.dark-theme .btn-flat {
  background-color: #3b82f6;
}

body.dark-theme .btn-flat:hover {
  background-color: #2563eb;
}

.btn-info {
  background-color: #3b82f6;
  color: #ffffff;
}

.btn-info:hover {
  background-color: #2563eb;
}

body.dark-theme .btn-info {
  background-color: #3b82f6;
}

body.dark-theme .btn-info:hover {
  background-color: #2563eb;
}

.btn-success {
  background-color: #22c55e;
  color: #ffffff;
}

.btn-success:hover {
  background-color: #16a34a;
}

body.dark-theme .btn-success {
  background-color: #22c55e;
}

body.dark-theme .btn-success:hover {
  background-color: #16a34a;
}

.btn-danger {
  background-color: #ef4444;
  color: #ffffff;
}

.btn-danger:hover {
  background-color: #dc2626;
}

body.dark-theme .btn-danger {
  background-color: #ef4444;
}

body.dark-theme .btn-danger:hover {
  background-color: #dc2626;
}

.btn-warning {
  background-color: #facc15;
  color: #1a1a1a;
}

.btn-warning:hover {
  background-color: #eab308;
}

body.dark-theme .btn-warning {
  background-color: #facc15;
}

body.dark-theme .btn-warning:hover {
  background-color: #eab308;
}

.button-group {
  display: flex;
  gap: 5px; /* Reduced gap */
  margin-top: 5px; /* Reduced margin */
}

.tab-content {
  display: none;
  background-color: #ffffff;
  padding: 5px; /* Further reduced padding */
  border: 1px solid #cccccc;
  border-radius: 0; /* Ensure no rounded corners */
}

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

body.dark-theme .tab-content {
  background-color: #2a2a2a;
  border-color: #444;
}

.location-input {
  display: flex;
  flex-wrap: wrap;
  gap: 5px; /* Reduced gap */
  margin-bottom: 5px; /* Reduced margin */
  align-items: center;
}

.location-input label {
  font-weight: bold;
}

.location-input input,
.location-input select {
  padding: 6px;
  border: 1px solid #cccccc;
  border-radius: 0; /* Ensure no rounded corners */
  font-size: 14px;
  background-color: #ffffff;
  color: #333333;
}

body.dark-theme .location-input input,
body.dark-theme .location-input select {
  background-color: #3a3a3a;
  border-color: #555;
  color: #d0d0d0;
}

h2, h3 {
  margin-bottom: 5px; /* Reduced margin */
  color: #2563eb;
}

body.dark-theme h2,
body.dark-theme h3 {
  color: #3b82f6;
}

.conditions-stack,
.card-stack {
  display: flex;
  flex-direction: column;
  gap: 5px; /* Reduced gap */
  margin-bottom: 5px; /* Reduced margin */
}

.condition-item,
.card {
  background-color: #f5f5f5;
  padding: 5px; /* Reduced padding */
  border-radius: 0; /* Ensure no rounded corners */
  border: 1px solid #cccccc;
}

body.dark-theme .condition-item,
body.dark-theme .card {
  background-color: #3a3a3a;
  border-color: #555;
}

.condition-label {
  font-weight: bold;
  margin-right: 5px;
}

.alert {
  padding: 5px; /* Reduced padding */
  border-radius: 0; /* Ensure no rounded corners */
  margin-bottom: 5px; /* Reduced margin */
  border: 1px solid;
}

.alert-success {
  background-color: #d1fae5;
  color: #065f46;
  border-color: #10b981;
}

.alert-danger {
  background-color: #fee2e2;
  color: #991b1b;
  border-color: #ef4444;
}

body.dark-theme .alert-success {
  background-color: #166534;
  color: #86efac;
  border-color: #22c55e;
}

body.dark-theme .alert-danger {
  background-color: #7f1d1d;
  color: #f87171;
  border-color: #ef4444;
}

.fa-spinner {
  margin-right: 5px;
}

.radar-iframe {
  width: 100%;
  height: 500px;
  margin: 5px 0; /* Reduced margin */
  border: none;
  border-radius: 0; /* Ensure no rounded corners */
}

/* Modal Styles */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  overflow: auto;
  border-radius: 0; /* Ensure no rounded corners */
}

.modal-content {
  background-color: #ffffff;
  margin: 10% auto;
  padding: 10px; /* Reduced padding */
  border: 1px solid #cccccc;
  width: 90%;
  max-width: 400px;
  border-radius: 0; /* Ensure no rounded corners */
  text-align: center;
}

body.dark-theme .modal-content {
  background-color: #2a2a2a;
  border-color: #444;
}

.share-option {
  display: flex;
  align-items: center;
  gap: 5px; /* Reduced gap */
  margin-bottom: 5px; /* Reduced margin */
}

.share-option input[type="checkbox"] {
  width: auto;
}

.share-option label {
  margin: 0;
}

.close {
  color: #333333;
  float: right;
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
}

body.dark-theme .close {
  color: #d0d0d0;
}

.close:hover,
.close:focus {
  color: #000000;
  text-decoration: none;
}

body.dark-theme .close:hover,
body.dark-theme .close:focus {
  color: #ffffff;
}

.form-group {
  margin-bottom: 5px; /* Reduced margin */
}

.form-group label {
  display: block;
  margin-bottom: 3px; /* Reduced margin */
  font-weight: bold;
}

.form-group input,
.form-group select {
  width: 100%;
  padding: 6px;
  border: 1px solid #cccccc;
  border-radius: 0; /* Ensure no rounded corners */
  font-size: 14px;
  background-color: #ffffff;
  color: #333333;
}

body.dark-theme .form-group input,
body.dark-theme .form-group select {
  background-color: #3a3a3a;
  border-color: #555;
  color: #d0d0d0;
}

.footer {
  text-align: center;
  padding: 5px; /* Reduced padding */
  background-color: #ffffff;
  color: #333333;
  border-radius: 0; /* Ensure no rounded corners */
  margin-top: 5px; /* Reduced margin */
  border: 1px solid #cccccc;
}

.footer a {
  color: #2563eb;
  text-decoration: none;
}

.footer a:hover {
  text-decoration: underline;
}

body.dark-theme .footer {
  background-color: #2a2a2a;
  color: #d0d0d0;
  border-color: #444;
}

body.dark-theme .footer a {
  color: #3b82f6;
}

.welcome-message {
  font-style: italic;
  color: #666666;
  margin-bottom: 5px; /* Reduced margin */
}

body.dark-theme .welcome-message {
  color: #888;
}

.btn-secondary {
  background-color: #6b7280;
  color: #ffffff;
}

.btn-secondary:hover {
  background-color: #4b5563;
}

body.dark-theme .btn-secondary {
  background-color: #6b7280;
}

body.dark-theme .btn-secondary:hover {
  background-color: #4b5563;
}

#login-form .btn, #profile-section .btn {
  margin: 3px; /* Reduced margin */
  width: 120px;
}

.severe-weather-section {
  background-color: #f5f5f5;
  padding: 5px; /* Reduced padding */
  border-radius: 0; /* Ensure no rounded corners */
  border: 1px solid #cccccc;
  margin-bottom: 5px; /* Reduced margin */
}

body.dark-theme .severe-weather-section {
  background-color: #3a3a3a;
  border-color: #555;
}

.alert-warning {
  background-color: #fef9c3;
  color: #854d0e;
  border-color: #facc15;
}

body.dark-theme .alert-warning {
  background-color: #713f12;
  color: #fde68a;
  border-color: #facc15;
}

.collapsible-header {
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 5px;
}

.collapsible-header .fa-chevron-down {
  transition: transform 0.3s;
}

.collapsible-header.active .fa-chevron-down {
  transform: rotate(180deg);
}

.collapsible-content {
  margin-top: 5px; /* Reduced margin */
}

.radar-modal-content {
  max-width: 850px;
  border-radius: 0; /* Ensure no rounded corners */
}

.achievement-card {
  display: flex;
  align-items: center;
  gap: 5px; /* Reduced gap */
}

.achievement-icon {
  font-size: 24px;
  color: #10b981;
}

body.dark-theme .achievement-icon {
  color: #22c55e;
}

.modal-toggle {
  display: flex;
  justify-content: center;
  margin-bottom: 5px; /* Reduced margin */
}

.toggle-button {
  padding: 6px 18px;
  border: none;
  background-color: #e5e7eb;
  cursor: pointer;
  font-size: 16px;
  color: #333333;
  transition: background-color 0.3s;
  border-radius: 0; /* Ensure no rounded corners */
}

.toggle-button.active {
  background-color: #3b82f6;
  color: #ffffff;
}

body.dark-theme .toggle-button {
  background-color: #3a3a3a;
  color: #d0d0d0;
}

body.dark-theme .toggle-button.active {
  background-color: #3b82f6;
}

.auth-form {
  text-align: center;
}