/* General styles and variables */
:root {
  --primary-color: #3442db;
  --secondary-color: #2ecc71;
  --accent-color: #e74c3c;
  --text-color: #34495e;
  --background-color: #ecf0f1;
}


body {
  font-family: "Lato", sans-serif;
  font-weight: 400;
  font-style: normal;
  text-align: center;
  margin: 0.5;
  padding: 2px;
}

/* Container styles */
.container {
  width: auto;
  text-align: center;
  max-width: 444px;
  margin: auto;
  padding: 2px;
}

/* Form elements */
input[type="number"],
input[type="text"], 
input[type="password"],
select {
  text-align: center;
  padding: 2px;
  border: 1px solid #ddd;
  border-radius: 4px;
}

label {
  font-size: 15px;
  color: #777;
}

/* Fieldset styles */
fieldset {
  width: auto;
  margin: .5px;
  border: 1px solid silver;
  padding: 4px;
  border-radius: 16px;
}

legend {
  padding: 2px;
}

.dashboard-table th {
  background-color: rgb(58, 78, 90);
  color: white;
  font-size: 13px;
}

.dashboard-table td {
  color: black;
  font-size: 16px;
}

.dashboard-table .savings-gift {
  background-color: #aecd00;
  color: white;
}

.dashboard-table .cashback {
  background-color: #4a90e2;
  color: white;
}

/* Special table styles */
.dashboard-table.items-table tbody tr td:first-child {
  text-decoration: underline;
  color: #3e696c;
  cursor: pointer;
}

.dashboard-table#dashboardtable tbody tr td:nth-child(2) {
  text-decoration: underline;
  color: #6f5e92;
  cursor: pointer;
  text-align: center;
  font-size: 12px;
}

/* Dashboard container and blocks */
.dashboard-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  width: 70%;
  margin: 0 auto;
  padding: 10px;
}

.dashboard-block {
  background-color: #f5f5f5;
  border: 2px solid #ddd;
  border-radius: 5px;
  padding: 15px;
  margin: 5px;
  text-align: center;
  width: 45%;
  box-sizing: border-box;
}

.dashboard-block h3 {
  margin-bottom: 10px;
}

.dashboard-block p {
  font-size: 10px;
  font-weight: bold;  
}

.dashboard-block.pay { background-color: #ffc107; }
.dashboard-block.users { background-color: #c02942; }
.dashboard-block.sales { background-color: #428bca; }
.dashboard-block.rewards { background-color: #3cba54; }

/* Section styles */
.section-header {
  background-color: #f0f0f0;
  padding: 10px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-radius: 5px;
  margin-bottom: 5px;
}

.section-header h2 {
  margin: 0px;
}

.section-content {
  display: none;
  padding: 0px;
  border: 1px solid #efe7e7;
  border-radius: 0 0 5px 5px;
}

.arrow {
  transition: transform 0.3s ease;
}

.arrow.open {
  transform: rotate(180deg);
}

/* Section header colors */
#summary-header { background-color: #e6f2ff; color: #0066cc; }
#shop-header { background-color: #e6a8e2; color: #660036; }
#commit-header { background-color: #49b9e6; color: #100532; }
#pay-header { background-color: #d2d1da; color: #2443be; }
#uncommit-header { background-color: #ffe6e6; color: #cc0000; }
#gift-header { background-color: #f2e6ff; color: #6600cc; }

/* Bill summary styles */
.bill-amnt, .bill-value {
  font-size: 1.3em;
  float: center;
  color: gray;
}

.bill-amnt.highlight, .bill-value.highlight {
  color: green;
}

.total-payable {
  color: gray;
  font-size: 1.2em;
}

.total-payable.highlight {
  color: #65925e;
}

/* Payment table styles */
.payment-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-family: Arial, sans-serif;
  background-color: #f8f9fa;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 0 10px rgba(0,0,0,0.1);
}

.payment-table td {
  padding: 2px 4px;
  border-bottom: .5px solid #e9ecef;
}

.payment-table p {
  margin: 1px 0;
}

.payment-table img {
  max-width: 100%;
  height: auto;
  margin-bottom: 1px;
}

.step-number {
  display: inline-block;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  color: white;
  text-align: center;
  line-height: 24px;
  font-weight: bold;
  margin-right: 50px;
}

/* Tooltip styles */
.tooltip {
  position: relative;
  display: inline-block;
  cursor: help;
}

.tooltip .tooltiptext {
  visibility: hidden;
  width: 120px;
  background-color: black;
  color: white;
  text-align: center;
  border-radius: 6px;
  padding: 5px 0;
  position: absolute;
  z-index: 1;
  bottom: 125%;
  left: 50%;
  margin-left: -60px;
  opacity: 0;
  transition: opacity 0.3s;
}

.tooltip:hover .tooltiptext {
  visibility: visible;
  opacity: 1;
}

.info-tooltip {
  position: fixed;
  background-color: #f9f9f9;
  border: 1px solid #ccc;
  padding: 5px;
  border-radius: 4px;
  font-size: 14px;
  z-index: 1000;
  max-width: 200px; /* Adjust as needed */
  word-wrap: break-word;
}

.info-tooltip::after {
  content: '';
  position: absolute;
  left: 50%;
  margin-left: -5px;
  border-width: 5px;
  border-style: dashed;
  opacity: 1;
}

.info-tooltip:not(.below)::after {
  top: 100%;
  border-color: #333 transparent transparent transparent;
}

.info-tooltip.below::after {
  bottom: 50%;
  border-color: transparent transparent #333 transparent;
}

/* Dashboard table styles */
#summary-content .dashboard-table {
  margin-bottom: 0px;
  width: 100%;
}

#summary-content .dashboard-table:last-child {
  margin-bottom: 0;
}

/* Cashback table styles */
#cashbackTable {
  border-collapse: collapse;
}

#cashbackTable th, #cashbackTable td {
  border: 1px solid #ddd;
  padding: 8px;
  text-align: center;
}

#cashbackTable .blue-bg th {
  background-color: #2196F3;
  color: white;
}

/* Savings and Gift table styles */
#savingsGiftTable {
  border-collapse: collapse;
  margin-bottom: 20px;
}

#savingsGiftTable th, #savingsGiftTable td {
  border: 1px solid #ddd;
  padding: 8px;
  text-align: center;
}

#savingsGiftTable th {
  background-color: #4CAF50;
  color: white;
}

/* Input styles */
input[type="text"], input[type="password"] {
  width: 100%;
  max-width: 100px;
  font-size: 14px;
}

/* Dashboard table styles (updated) */
.dashboard-table {
  width: 100%;
  font-size: 12px;
}

.dashboard-table th, .dashboard-table td {
  padding: 5px;
}

/* Payment table styles (updated) */
.payment-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0 10px;
}

.payment-table td {
  padding: 1px;
  vertical-align: middle;
}

.input-cell {
  text-align: left;
}

.payment-table input[type="text"] {
  width: calc(100% - 20px);
  padding: 0px;
  border: 1px solid #ccc;
  border-radius: 4px;
}

/* Reset and base styles */
body, html {
  margin: 0;
  padding: 4px;
  height: auto;
  font-family: Arial, sans-serif;
  font-size: 13px;   
}

.container {
  width: auto;
  text-align: center;
  max-width: 350px;
  margin: 0 auto;
  padding: 11px;
}

p {
  font-family: "Montserrat", sans-serif;
  font-optical-sizing: auto;
  font-weight: 250;
  font-style: normal;
  font-size: .9em;
  color: #666;
  line-height: .9;
  margin: 0.5em 0;
}

/* Tile styles */
.tile {
  padding: 5px;
  border-radius: 10px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  min-height: 60px;
  transition: all 0.3s ease;
}

.tile:hover {
  transform: translateY(-5px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.tile h2 {
  font-size: 1em;
  margin: 0 0 1px 0;
}

.tile p {
  font-size: 1em;
  margin: 1px;
}

.button {
  background-color: #4CAF50;
  color: white;
  padding: 8px 16px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 13px;
  width: AUTO;
  margin-top: 5px;
}

.button:hover {
  background-color: #1f4e22;
}

/* Form elements */
input[type="text"], input[type="password"], input[type="number"], select {
  width: 100px;
  max-width: 110px;
  font-size: 14px;
  padding: 4px;
  border: 2px solid #ddd;
  border-radius: 4px;
  text-align: center;
}

/* Table styles */
.dashboard-table {
  width: 100%;
  font-size: 16px;
  border-collapse: collapse;
}

.dashboard-table th, .dashboard-table td {
  padding: 5px;
  border: 1px solid #ddd;
  text-align: center;
}

/* Leaderboard styles */
.leaderboard {
  grid-column: 1 / -1;
  padding: 0px;
  border-radius: 1px;
  box-shadow: 0 1px 2px rgba(0,0,0,0.1);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin: 0px 0;
}

.leaderboard p {
  margin-bottom: 0px;
  font-size: 1.3em;
  font-weight: bold;
  color: blue;
  animation: blink 4s linear infinite;
  text-align: center;
}

.leaderboard table {
  width: auto;
  max-width: 400px;
  border-collapse: collapse;
  font-size: 0.8em;
  margin: 0px auto;
}

.leaderboard th, .leaderboard td {
  border: 1px solid #ddd;
  padding: 7px;
  text-align: center;
}

/* Custom alert styles */
.custom-alert {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(1, 0, 0, 1);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

.alert-content {
  background-color: #fffaaa;
  padding: 30px;
  border-radius: 10px;
  text-align: center;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  max-width: 80%;
  width: 400px;
}

.alert-content h2 {
  margin-top: 0;
  color: #333;
  font-size: 24px;
}

.alert-content p {
  color: #666;
  font-size: 16px;
  line-height: 1.5;
}

.alert-content button {
  margin-top: 20px;
  padding: 10px 20px;
  cursor: pointer;
  background-color: #4CAF50;
  color: white;
  border: none;
  border-radius: 5px;
  font-size: 16px;
  transition: background-color 0.3s;
}

.alert-content button:hover {
  background-color: #45a049;
}

/* Animations */
@keyframes blink {
  0% { opacity: .1; }
  25% { opacity: 0.25; }
  50% { opacity: 0.50; }
  75% { opacity: 0.75; }
  100% { opacity: 1; }
}

/* Media queries */
@media (max-width: 768px) {
  .inner-container {
      grid-template-columns: 1fr;
  }

  .tile {
      transform: none !important;
  }
}


.no-boarder-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0 1px;
  border-radius: 16px;
}

.no-boarder-table,
.no-boarder-table th,
.no-boarder-table td {
  border: none;
  border-radius: 4px;
  padding: 5px;
}

.no-boarder-table tr:nth-child(odd) {
  background-color: #f0e6ff;
}

.no-boarder-table tr:nth-child(even) {
  background-color: #e6e6fa;
}

.no-boarder-table input,
.no-boarder-table button {
  width: 90%;
  box-sizing: border-box;
  padding: 10px;
  border: 1px solid #d1c1e0;
  border-radius: 4px;
}

.no-boarder-table input {
  background-color: white;
}

.no-boarder-table button {
  background-color: #463dec;
  color: white;
  border: none;
  cursor: pointer;
  transition: background-color 0.3s;
}

button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.no-boarder-table button:hover {
  background-color: #45a049;
}


.no-boarder-table td[colspan="2"] {
  text-align: center;
}

input[type="checkbox"]:focus {
  outline: 2px solid #4CAF50;
  outline-offset: 2px;
}

.no-border-table {
  border-collapse: separate;
  border-spacing: 0 1px;
  border-radius: 16px;
}

.no-border-table td {
  border: none;
  border-radius: 4px;
  padding: 2px;
}

.no-border-table tr:nth-child(odd) {
  background-color: #f0e6ff;
}

.no-border-table tr:nth-child(even) {
  background-color: #e6e6fa;
}

.no-border-table input,
.no-border-table button {
  width: 100%;
  box-sizing: border-box;
  padding: 10px;
  border: 1px solid #d1c1e0;
  border-radius: 4px;
}

.no-border-table input {
  background-color: white;
}

.no-border-table button {
  background-color: #706ae8;
  color: white;
  border: none;
  cursor: pointer;
  transition: background-color 0.3s;
}

.no-border-table button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.no-border-table button:hover:not(:disabled) {
  background-color: #463dec;
}
