/* General */

body {
  margin: 0;
  font-family: Arial, sans-serif;
  background: #f9f9f9;
  color: #222;
  transition: background 0.3s, color 0.3s;
}

.dark-mode {
  background: #121212;
  color: #f1f1f1;
}

/* Sidebar */

.sidebar {
  height: 100%;
  width: 260px;
  position: fixed;
  top: 0;
  left: 0;
  background-color: #fff;
  box-shadow: 3px 0 10px rgba(0,0,0,0.2);
  overflow-x: hidden;
  transform: translateX(-260px);
  transition: transform 0.2s ease, opacity 0.2s ease;
  padding-top: 60px;
  z-index: 1000;
  opacity: 0;
}

.sidebar.open {
  transform: translateX(0);
  opacity: 1;
}

.sidebar a {
  padding: 12px 24px;
  text-decoration: none;
  font-size: 16px;
  color: #111;
  display: block;
  transition: background 0.2s, padding-left 0.2s;
}

.sidebar a:hover {
  background: #007BFF;
  color: #fff;
  padding-left: 30px;
}

.dark-mode .sidebar {
  background-color: #1e1e1e;
}

.dark-mode .sidebar a {
  color: #f1f1f1;
}

.dark-mode .sidebar a:hover {
  background: #555;
}

/* Close Button */

.closebtn {
  position: absolute;
  top: 10px;
  right: 20px;
  font-size: 36px;
  color: #333;
  cursor: pointer;
}

/* Top Bar */

.topbar {
  background: #444444;
  color: #fff;
  padding: 12px 20px;
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: background 0.3s;
}

.dark-mode .topbar {
  background: #444;
}

.menu-btn {
  font-size: 24px;
  cursor: pointer;
}

#modeToggle {
  background: none;
  border: none;
  color: inherit;
  font-size: 20px;
  cursor: pointer;
}

/* Content */

.content {
  padding: 20px;
}

/* Card (Email Reset Section) */

.card {
  background: #fff;
  border-radius: 8px;
  padding: 20px;
  margin: 15px 0;
  box-shadow: 0 4px 10px rgba(0,0,0,0.15);
  transition: background 0.3s, color 0.3s;
}

.dark-mode .card {
  background: #1e1e1e;
  color: #f1f1f1;
  box-shadow: 0 4px 12px rgba(255,255,255,0.05);
}

/* Copy Button */

.copy-btn {
  display: inline-block;
  margin-top: 12px;
  padding: 8px 16px;
  background: #007BFF;
  color: #fff;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.3s;
  width: 100%;
}

.copy-btn:hover {
  background: #0056b3;
}

.fancy-btn {
  background-color: #007BFF;
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 8px 16px;
  font-size: 16px;
  cursor: pointer;
  box-shadow: 0 4px 6px rgba(0,0,0,0.2);
  transition: all 0.3s ease;
}

.fancy-btn:hover {
  background-color: #0056b3;
  box-shadow: 0 6px 10px rgba(0,0,0,0.3);
  transform: translateY(-2px);
}

body.dark-mode .fancy-btn {
  background-color: #555;
  color: #fff;
}

body.dark-mode .fancy-btn:hover {
  background-color: #777;
  box-shadow: 0 6px 10px rgba(255,255,255,0.1);
}

#emailBody {
  background-color: #ebebeb;
  padding: 10px;
  border-radius: 6px;
  white-space: pre-wrap;
  color: black;
}

.dark-mode #emailBody {
  background-color: #404040;
  padding: 10px;
  border-radius: 6px;
  white-space: pre-wrap;
  color: #ffffff;
}

#groupEmailBody {
  background-color: #ebebeb;
  padding: 10px;
  border-radius: 6px;
  white-space: pre-wrap;
  color: black;
}

.dark-mode #groupEmailBody {
  background-color: #404040;
  padding: 10px;
  border-radius: 6px;
  white-space: pre-wrap;
  color: #ffffff;
}

#whatsappDcsBody {
  background-color: #ebebeb;
  padding: 10px;
  border-radius: 6px;
  white-space: pre-wrap;
  color: black;
}

.dark-mode #whatsappDcsBody {
  background-color: #404040;
  padding: 10px;
  border-radius: 6px;
  white-space: pre-wrap;
  color: #ffffff;
}

#bandwidthUpgradationBody {
  background-color: #ebebeb;
  padding: 10px;
  border-radius: 6px;
  white-space: pre-wrap;
  color: black;
}

.dark-mode #bandwidthUpgradationBody {
  background-color: #404040;
  padding: 10px;
  border-radius: 6px;
  white-space: pre-wrap;
  color: #ffffff;
}

#crmMessageFormatBody {
  background-color: #ebebeb;
  padding: 10px;
  border-radius: 6px;
  white-space: pre-wrap;
  color: black;
}

.dark-mode #crmMessageFormatBody {
  background-color: #404040;
  padding: 10px;
  border-radius: 6px;
  white-space: pre-wrap;
  color: #ffffff;
}

/* Home Text */

.home-wrap {
  text-align: center;
  margin-top: 150px;
  font-family: inherit;
}

.home-h4 {
  font-weight: 700;
  font-size: 30px;
  margin: 0 0 10px 0;
}

.home-h1 {
  font-weight: 600;
  font-size: 90px;
  color: #E50088;
  margin: 0;
  letter-spacing: 0.5px;
}

.home-h2 {
  font-weight: 700;
  font-size: 40px;
  letter-spacing: 8px;
  margin: 0;
}

.home-h5 {
  margin-top: 50px;
  font-size: 15px;
  font-weight: 400;
  opacity: 0.9;
}

.card h3 {
  color: #E50088;
  font-weight: bold;
}

/* Push About section to the bottom with a gap */

.sidebar-bottom {
  margin-top: 40px;
  border-top: 1px solid #ccc;
  /*padding-top: 10px;*/
}

/* Warning */

.p1 {
  background: yellow;
  color: black;
  font-weight: bold;
  font-size: 14px;
  display: inline-block;
  padding: 2px 6px;
  border-radius: 4px;
  margin-bottom: 20px;
}

/* Contacts */

/* Contacts table design */

/* Contacts Table Styles */

table {
  width: 100%;
  border-collapse: collapse;
  /*margin: 15px 0;*/
  font-size: 14px;
}

thead th {
  padding: 12px 10px;
  text-align: left;
  font-weight: bold;
}

tbody td {
  padding: 10px;
  border-bottom: 1px solid #e0e0e0;
}

/* Light mode table styles */

table {
  background-color: #ffffff;
  color: #222222;
}

thead tr {
  background-color: #f1f1f1 !important;
}

thead th {
  color: #222222;
  border-bottom: 2px solid #ddd;
}

tbody tr:nth-child(odd) {
  background-color: #fafafa;
}

tbody tr:nth-child(even) {
  background-color: #f0f0f0;
}

/* Dark mode table styles */

.dark-mode table {
  background-color: #1e1e1e;
  color: #f1f1f1;
}

.dark-mode thead tr {
  background-color: #2d2d2d !important;
}

.dark-mode thead th {
  color: #f1f1f1;
  border-bottom: 2px solid #444;
}

.dark-mode tbody tr:nth-child(odd) {
  background-color: #252525;
}

.dark-mode tbody tr:nth-child(even) {
  background-color: #2a2a2a;
}

.dark-mode tbody td {
  border-bottom: 1px solid #333;
}

/* Contact copy elements */

.contact-copy {
  cursor: pointer;
  text-decoration: underline;
  color: #007BFF;
  transition: color 0.2s;
}

.dark-mode .contact-copy {
  color: #4da6ff;
}

.contact-copy:hover {
  color: #0056b3;
}

.dark-mode .contact-copy:hover {
  color: #80c1ff;
}

.contact-copy.copied {
  color: green;
  font-weight: bold;
}

.dark-mode .contact-copy.copied {
  color: #00cc00;
}

/* Responsive table container */

.table-container {
  max-height: 400px;
  overflow-y: auto;
  border-radius: 8px;
  border: 1px solid #ddd;
}

.dark-mode .table-container {
  border: 1px solid #444;
}

/* Search Container Styles */

.search-container {
  position: relative;
  margin-bottom: 20px;
}

.search-input {
  width: 100%;
  padding: 12px 15px 12px 40px;
  border: 1px solid #ddd;
  border-radius: 6px;
  font-size: 16px;
  transition: all 0.3s;
  background-color: #fff;
  color: #222;
}

.dark-mode .search-input {
  background-color: #2d2d2d;
  color: #f1f1f1;
  border-color: #444;
}

.search-input:focus {
  outline: none;
  border-color: #007BFF;
  box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.25);
}

.dark-mode .search-input:focus {
  border-color: #4da6ff;
  box-shadow: 0 0 0 2px rgba(77, 166, 255, 0.25);
}

.search-icon {
  position: absolute;
  left: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: #888;
}

.dark-mode .search-icon {
  color: #aaa;
}

/* Result Count Styles */

.result-count {
  margin-top: 15px;
  font-size: 14px;
  color: #666;
}

.dark-mode .result-count {
  color: #aaa;
}

/* Dropdown menu styles */

.dropdown {
  position: relative;
}

.dropdown-btn {
  width: 100%;
  text-align: left;
  padding: 12px 24px;
  text-decoration: none;
  font-size: 16px;
  color: #111;
  display: block;
  background: none;
  border: none;
  cursor: pointer;
  transition: background 0.2s, padding-left 0.2s;
}

.dropdown-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease-out;
  background-color: #f9f9f9;
}

.dropdown.open .dropdown-content {
  max-height: 500px;
}

.dropdown.open .dropdown-btn .dropdown-arrow {
  transform: rotate(90deg);
}

.dropdown-arrow {
  float: right;
  transition: transform 0.3s ease;
  margin-right: 5px;
}

.dropdown-content a {
  padding: 12px 24px 12px 40px;
  text-decoration: none;
  font-size: 14px;
  color: #111;
  display: block;
  transition: background 0.2s, padding-left 0.2s;
}

.dark-mode .dropdown-btn {
  color: #f1f1f1;
}

.dark-mode .dropdown-content {
  background-color: #2d2d2d;
}

.dark-mode .dropdown-content a {
  color: #f1f1f1;
}

.dropdown-btn:hover, .dropdown-content a:hover {
  background: #007BFF;
  color: #fff;
  padding-left: 30px;
}

.dark-mode .dropdown-btn:hover, .dark-mode .dropdown-content a:hover {
  background: #555;
}

/* Hidden helper for copying */

#copy-helper {
  position: absolute;
  left: -9999px;
  opacity: 0;
  pointer-events: none;
  background: white !important;
  color: black !important;
}

/* Light mode table for copying */

.copy-table {
  border-collapse: collapse;
  font-family: Arial, sans-serif;
  font-size: 13px;
  text-align: center;
  border: 1px solid black;
  width: 100%;
  background: white !important;
  color: black !important;
}

.copy-table th, .copy-table td {
  border: 1px solid black;
  padding: 5px;
  background: white !important;
  color: black !important;
}

.copy-table thead tr {
  background-color: #f1f1f1 !important;
}

.copy-table thead th {
  background-color: #f1f1f1 !important;
}

/* Responsive container for mobile zooming */

.responsive-table-container {
  width: 100%;
  overflow-x: visible;
  margin: 15px 0;
}

@media (max-width: 768px) {
  .responsive-table-container {
    zoom: 0.8;
    -moz-transform: scale(0.8);
    -moz-transform-origin: 0 0;
    -o-transform: scale(0.8);
    -o-transform-origin: 0 0;
    -webkit-transform: scale(0.8);
    -webkit-transform-origin: 0 0;
  }
}

/* Ensure the original table styling is maintained for display */

#createEmailBody table {
  border-collapse: collapse;
  font-family: Arial, sans-serif;
  font-size: 13px;
  text-align: center;
  border: 1px solid black;
  width: 100%;
}

#createEmailBody th, #createEmailBody td {
  border: 1px solid black;
  padding: 5px;
}

#renameEmailBody table {
  border-collapse: collapse;
  font-family: Arial, sans-serif;
  font-size: 13px;
  text-align: center;
  border: 1px solid black;
  width: 100%;
}

#renameEmailBody th, #renameEmailBody td {
  border: 1px solid black;
  padding: 5px;
}

#complainEmailBody td {
  border: 1px solid black;
  padding: 8px;
}

/* Additional styling for leave backup table */

/* Leave backup table specific styles */

.leave-backup-table {
  width: auto;
  border-collapse: collapse;
  table-layout: auto;
  margin: 0;
  max-width: 400px;
}

.leave-backup-table th, .leave-backup-table td {
  border: 1px solid black;
  padding: 8px;
  word-wrap: break-word;
}

.leave-backup-table th {
  background-color: #f1f1f1;
  text-align: center;
  white-space: nowrap;
  color: #222;
}

.leave-backup-table td {
  text-align: left;
  vertical-align: top;
}

/* Dark mode styles for leave backup table */

.dark-mode .leave-backup-table th {
  background-color: #2d2d2d !important;
  color: #f1f1f1 !important;
  border-color: #444 !important;
}

.dark-mode .leave-backup-table td {
  background-color: #1e1e1e !important;
  color: #f1f1f1 !important;
  border-color: #444 !important;
}

/* For copy functionality - fixed width */

.copy-table.leave-backup-table {
  border-collapse: collapse;
  font-family: Arial, sans-serif;
  font-size: 13px;
  border: 1px solid black;
  width: 400px !important;
  background: white !important;
  color: black !important;
  table-layout: fixed;
  margin: 0;
}

.copy-table.leave-backup-table th, .copy-table.leave-backup-table td {
  border: 1px solid black !important;
  padding: 8px !important;
  background: white !important;
  color: black !important;
}

.copy-table.leave-backup-table th {
  background-color: #f1f1f1 !important;
  text-align: center !important;
  white-space: nowrap !important;
}

.copy-table.leave-backup-table td {
  text-align: left !important;
  vertical-align: top !important;
}

#createEmailBody {
  overflow-x: auto;
}

#renameEmailBody {
  overflow-x: auto;
}

/* Zonal Reports specific styles */

.report-link {
  color: #007BFF;
  text-decoration: none;
  transition: color 0.2s;
}

.report-link:hover {
  color: #0056b3;
  text-decoration: underline;
}

.dark-mode .report-link {
  color: #4da6ff;
}

.dark-mode .report-link:hover {
  color: #80c1ff;
}

/* Copy button styling for reports - fixed size */

.report-copy {
  padding: 6px 12px;
  background: #007BFF;
  color: white;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.3s ease;
  width: 70px;
  text-align: center;
  font-size: 13px;
  font-weight: 500;
  display: inline-block;
  box-sizing: border-box;
}

.report-copy:hover {
  background: #0056b3;
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.report-copy.copied {
  background: green;
  transform: none;
  box-shadow: none;
}

.dark-mode .report-copy {
  background: #555;
}

.dark-mode .report-copy:hover {
  background: #777;
}

.dark-mode .report-copy.copied {
  background: #00a300;
}

/* Media queries for responsive button sizing */

@media (max-width: 768px) {
  .report-copy {
    width: 70px;
    padding: 5px 10px;
    font-size: 12px;
  }
}

@media (max-width: 480px) {
  .report-copy {
    width: 70px;
    padding: 4px 8px;
    font-size: 11px;
  }
}

