/* General Reset */
* {
  margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

/* Body Styling */
  body {
  background: linear-gradient(135deg, #2c3e50, #4ca1af);
    color: #eee;
    line-height: 1.8;
    padding: 40px;
}

/* Container */
  .container {
  max-width: 1200px;
    margin: 0 auto;
    padding: 40px;
    background: linear-gradient(135deg, #1e3c72, #2a5298);
    border-radius: 16px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.5);
    overflow: hidden;
    text-align: center;
}

/* Header */
  .header {
  text-align: center;
    margin-bottom: 40px;
}

.header .business-logo {
  max-width: 150px;
    margin-bottom: 10px;
}

.header h1 {
  font-size: 2.5rem;
    color: #ffcc29;
}

/* Invoice Form */
  form {
  display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 30px;
    text-align: left;
}

form label {
  display: block;
    margin-bottom: 8px;
    color: #ccc;
    font-size: 1.1rem;
}

form input, form select, textarea {
  width: 100%;
    padding: 12px;
    border: 1.5px solid #666;
    border-radius: 8px;
    background: #2c3e50;
    color: #fff;
    font-size: 1rem;
    transition: 0.3s ease;
}

form input:focus, form select:focus, textarea:focus {
  border-color: #ffcc29;
    background: #3b5998;
    outline: none;
}

/* Items Table */
  table {
  width: 100%;
    border-collapse: collapse;
    margin-bottom: 30px;
    background: #34495e;
    color: #fff;
}

thead th {
  background: #ffcc29;
    color: #222;
    text-align: left;
    padding: 12px;
    font-size: 1.1rem;
}

tbody td {
  padding: 12px;
    border: 1px solid #666;
}

tbody tr:nth-child(even) {
  background: #3b5998;
}

/* Totals Section */
  #totals {
  margin: 30px 0;
    background: linear-gradient(135deg, #23395d, #406e8e);
    padding: 25px;
    border-radius: 10px;
    box-shadow: inset 0 5px 10px rgba(0, 0, 0, 0.5);
}

#totals p {
  margin-bottom: 15px;
    display: flex;
    justify-content: space-between;
    font-size: 1.1rem;
}

#totals span {
  font-weight: bold;
    color: #ffcc29;
}

/* Buttons */
  button {
  background: #ffcc29;
    color: #222;
    padding: 15px 20px;
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s ease;
}

button:hover {
  background: #e6b800;
}

button.secondary {
  background: #666;
    color: #ddd;
}

button.secondary:hover {
  background: #777;
    color: #fff;
}

/* Invoice Preview */
  #invoicePreview {
  padding: 30px;
    background: linear-gradient(135deg, #1e3c72, #2a5298);
    color: #fff;
    border-radius: 16px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.5);
    text-align: center;
}

#invoicePreview h2 {
  color: #ffcc29;
    margin-bottom: 30px;
}

/* Responsive Design */
  @media (max-width: 768px) {
  form {
      grid-template-columns: 1fr;
}

button {
  width: 100%;
      margin: 10px 0;
}

}
  
  .payment-section {
  text-align: center;
      margin-top: 20px;
      padding: 15px;
      border: 1px solid #ccc;
      border-radius: 10px;
      background-color: #222; /* Darker background for better contrast */
      color: #fff; /* Light text for readability */
      box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.2);
}

.payment-section h3 {
  margin-bottom: 10px;
      color: #f8f9fa; /* Light gray text */
      font-size: 24px; /* Larger size for the heading */
      font-weight: bold; /* Bold for emphasis */
}

.payment-link {
  margin-bottom: 15px;
      word-wrap: break-word;
}

.payment-link a {
  display: inline-block; /* Make sure it behaves like a button */
      color: #007bff; /* Bright blue color for the link */
      font-weight: bold;
      text-decoration: none;
      font-size: 16px;
      padding: 10px 20px; /* Add padding for a clickable feel */
      border-radius: 5px;
      background-color: #e7f5ff; /* Light background color */
      border: 1px solid #007bff; /* Blue border for a button-like appearance */
      transition: all 0.3s ease-in-out; /* Smooth transition for hover effects */
      margin-bottom: 10px; /* Add margin below for spacing */
}

.payment-link a:hover {
  text-decoration: none; /* Remove underline on hover */
      background-color: #007bff; /* Change background to blue on hover */
      color: #fff; /* Change text color to white */
      box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.1); /* Add subtle shadow */
}

.payment-link a:focus {
  outline: none; /* Remove the default focus outline */
      box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.6); /* Add custom focus outline */
}

.payment-button-wrapper {
  margin: 15px 0;
}

.payment-button {
  display: inline-block;
      padding: 12px 25px;
      background-color: #00bfff;
      color: #222; /* Dark text for contrast */
      text-decoration: none;
      border-radius: 5px;
      font-size: 16px;
      font-weight: bold;
      transition: 0.3s;
}

.payment-button:hover {
  background-color: #ffcc00;
      color: #000;
}

.qr-code-wrapper {
  margin-top: 15px;
}

.qr-code {
  width: 150px;
      height: 150px;
      display: block;
      margin: 0 auto;
      border-radius: 10px;
      background-color: #fff; /* Ensure QR code stands out */
      padding: 5px;
      border: 2px solid #007bff; /* Add border around the QR code */
}

.payment-button, .payment-link a {
  padding: 12px 18px;
}


  
  /* Icon Support for Buttons */
  .payment-button i {
  margin-right: 8px;
}

.payment-link a i {
  margin-right: 8px;
}

/* Main Container */
  .invoice-container {
  max-width: 1200px;
    margin: 0 auto;
    background-color: #ffffff6b;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

/* Header Styling */
  h1 {
  text-align: center;
    font-size: 2.5em;
    color: #2c3e50;
    margin-bottom: 20px;
}

/* Form Section Styling */
  .form-section,
  .business-info-section,
  .address-section,
  .items-section,
  .tax-discount-section,
  .totals-section,
  .notes-section,
  .actions-section {
  margin-bottom: 20px;
}

label {
  font-weight: bold;
    margin-bottom: 5px;
    display: block;
    color: #34495e;
}

input[type="text"],
  input[type="date"],
  input[type="number"],
  input[type="url"],
  select,
  textarea {
  width: 100%;
    padding: 10px;
    margin: 5px 0 15px 0;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 1em;
    transition: border-color 0.3s ease;
}

input[type="text"]:focus,
  input[type="date"]:focus,
  input[type="number"]:focus,
  input[type="url"]:focus,
  select:focus,
  textarea:focus {
  border-color: #3498db;
    outline: none;
}

textarea {
  height: 100px;
    resize: vertical;
}

.modal {
  display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
  background-color: #34495e;
    color: #fff;
    padding: 80px;
    margin: 10% auto;
    width: 60%;
    height: 80%; /* Set a fixed height */
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    overflow-y: auto; /* Enable vertical scrolling */
}

.close {
  float: right;
    font-size: 24px;
    cursor: pointer;
}

/* Target only the invoice benefits modal */
  #invoiceBenefitsModal {
  display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    animation: fadeIn 0.3s ease-in-out;
    overflow: auto; /* Enable scrolling when content is too long */
}

/* Modal Content for invoice benefits */
  #invoiceBenefitsModal .modal-content {
  background: #ffffff;
    color: #2c3e50;
    padding: 40px;
    margin: 5% auto; /* Adjusted margin for better centering */
    width: 80%; /* Increased width */
    max-width: 900px; /* Bigger modal */
    max-height: 85vh; /* Constrain height */
    overflow-y: auto; /* Scrollable if content is too long */
    border-radius: 15px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
    text-align: center;
    font-size: 22px; /* Larger text */
    line-height: 1.6; /* Better spacing */
    animation: slideIn 0.3s ease-in-out;
}

/* Close button */
  #invoiceBenefitsModal .close {
  float: right;
    font-size: 30px; /* Bigger close button */
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
}

#invoiceBenefitsModal .close:hover {
  color: red;
}

/* List Styling */
  #invoiceBenefitsModal ul {
  list-style: none;
    padding: 0;
    max-height: 60vh; /* Prevent overflow */
    overflow-y: auto; /* Make the list scrollable */
}

#invoiceBenefitsModal ul li {
  display: flex;
    align-items: center;
    font-size: 22px; /* Larger text */
    padding: 15px;
    border-bottom: 1px solid #ddd;
    transition: background 0.3s ease-in-out;
}

#invoiceBenefitsModal ul li:hover {
  background: #f8f9fa;
}

/* Icons */
  #invoiceBenefitsModal ul li i {
  font-size: 28px; /* Bigger icons */
    margin-right: 20px;
    color: #007bff;
    transition: transform 0.3s ease-in-out;
}

#invoiceBenefitsModal ul li:hover i {
  transform: scale(1.2);
}

#invoiceBenefitsModal ul li i {
  font-size: 24px;
}


  
  #invoice-alert-banner {
  position: fixed;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #007BFF, #00D4FF);
    color: white;
    padding: 12px 16px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 700px;
    box-shadow: 0px 5px 12px rgba(0, 0, 0, 0.15);
    font-weight: 1000;
    transition: all 0.3s ease-in-out;
}

#invoice-alert-banner:hover {
  box-shadow: 0px 6px 16px rgba(0, 0, 0, 0.2);
}

#invoice-alert-banner button {
  background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    font-size: 16px;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 50%;
    transition: background 0.3s ease-in-out;
}

#invoice-alert-banner button:hover {
  background: rgba(255, 255, 255, 0.4);
}

#close-alert-btn {
  background: none;
    border: none;
    color: white;
    font-size: 16px;
    cursor: pointer;
    padding: 5px;
}

.email-btn {
  display: inline-block;
      padding: 8px 16px;
      background-color: #4CAF50;
      color: white;
      text-align: center;
      border-radius: 4px;
      font-size: 14px;
      text-decoration: none;
      transition: background-color 0.3s ease;
}

.email-btn:hover {
  background-color: #45a049;
}

.email-btn:active {
  background-color: #388e3c;
}

.email-btn:focus {
  outline: none;
      box-shadow: 0 0 4px 2px rgba(0, 0, 0, 0.1);
}

/* Tooltip Container */
  .tooltip {
  position: relative;
    display: inline-block;
    cursor: pointer;
    font-weight: bold;
    font-size: 1.3rem;
    color: #ff5733; /* Vivid orange for better visibility */
    padding: 4px 8px;
    border-radius: 50%;
    background: linear-gradient(135deg, #ff5733, #ff8c00); /* Orange gradient */
    box-shadow: 0px 4px 10px rgba(255, 87, 51, 0.5);
    transition: transform 0.2s ease-in-out;
}

/* Tooltip Hover Effect */
  .tooltip:hover {
  transform: scale(1.1);
}

/* Tooltip Styling */
  .tooltip::after {
  content: attr(data-tooltip);
    visibility: hidden;
    background: linear-gradient(135deg, #6a11cb, #2575fc); /* Blue/Purple gradient */
    color: #fff;
    text-align: center;
    padding: 10px 14px;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 500;
    white-space: nowrap;
    position: absolute;
    z-index: 10;
    bottom: 140%;
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    opacity: 0;
    transition: opacity 0.3s ease-in-out, transform 0.3s ease-in-out;
    box-shadow: 0px 4px 15px rgba(106, 17, 203, 0.4); /* Glowing effect */
    pointer-events: none;
}

/* Tooltip Arrow */
  .tooltip::before {
  content: "";
    position: absolute;
    top: -8px;
    left: 50%;
    transform: translateX(-50%);
    border-width: 8px;
    border-style: solid;
    border-color: #6a11cb transparent transparent transparent; /* Match gradient */
    visibility: hidden;
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

/* Tooltip Appears on Hover */
  .tooltip:hover::after,
  .tooltip:hover::before {
  visibility: visible;
    opacity: 1;
    transform: translateX(-50%) translateY(-5px);
}

/* Scoped styling for the signature section */
          .signature-container {
  background: white;
              padding: 20px;
              border-radius: 10px;
              box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.1);
              max-width: 500px;
              margin: auto;
              text-align: center;
}

.signature-container h3 {
  font-size: 18px;
              margin-bottom: 10px;
              color: #333;
}

.signature-box {
  border: 2px solid #007bff;
              border-radius: 5px;
              background: #fff;
              width: 100%;
              height: 200px;
              cursor: crosshair;
}

.signature-buttons {
  margin-top: 15px;
}

.signature-buttons button {
  padding: 8px 12px;
              font-size: 14px;
              border: none;
              border-radius: 5px;
              cursor: pointer;
              transition: 0.3s;
              margin: 5px;
}

.signature-clear {
  background: #dc3545; color: white;
}

.signature-save {
  background: #28a745; color: white;
}

.signature-undo {
  background: #ffc107; color: black;
}

.signature-download {
  background: #007bff; color: white;
}

.signature-options {
  margin-top: 10px;
}

.signature-options label {
  font-size: 14px;
              margin-right: 5px;
}

.signature-options select, .signature-options input {
  padding: 5px;
              font-size: 14px;
              border-radius: 5px;
              border: 1px solid #ccc;
}

.signature-image {
  display: none;
              border: 1px solid #007bff;
              border-radius: 5px;
              margin-top: 15px;
              width: 100%;
}

/* Chart Modal Styling */
  .chart-modal {
  display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7); /* Darkened overlay */
    z-index: 1000;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 0.3s ease-in-out;
}

.chart-modal.show {
  display: flex;
    opacity: 1;
}

.chart-modal-content {
  background: white;
    margin: 0 15px;
    padding: 30px;
    border-radius: 12px; /* Rounded corners for a modern look */
    width: 80%;
    max-width: 700px; /* Increased max-width for larger screens */
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1); /* Soft shadow for depth */
    animation: modal-fade-in 0.5s ease-out;
}

@keyframes modal-fade-in {
  0% {
        transform: scale(0.95);
        opacity: 0;
}

100% {
  transform: scale(1);
        opacity: 1;
}

}
  
  .chart-modal .close {
  position: absolute;
    top: 15px;
    right: 20px;
    font-size: 24px;
    font-weight: bold;
    color: #333;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 50%;
    padding: 5px 10px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.chart-modal .close:hover {
  background: #ff6347; /* Color change on hover */
    color: white;
}

/* Ensuring chart canvas is contained */
  .chart-container {
  display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: center;
    padding: 10px;
    min-height: 250px;
    justify-content: center; /* Center content vertically */
}

.chart-container canvas {
  width: 100%;
    height: 300px; /* Fixed height for consistency */
    max-width: 100%; /* Ensure canvas is responsive */
    border-radius: 8px;
    background: #f4f4f4;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); /* Shadow for canvas */
}

/* Loading Spinner */
  #loadingSpinner {
  position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 2em;
    color: #ff6347;
    z-index: 1000;
    display: none; /* Hidden by default */
    animation: rotate-spinner 1s linear infinite;
}

@keyframes rotate-spinner {
  0% {
        transform: translate(-50%, -50%) rotate(0deg);
}

}
  
  /* Mobile responsiveness */
  @media (max-width: 768px) {
  .chart-modal-content {
        width: 90%; /* Reduce width on smaller screens */
        padding: 20px;
}

.chart-modal .close {
  top: 10px;
        right: 10px;
        font-size: 18px; /* Adjust close button size */
}

#loadingSpinner {
  font-size: 1.2em; /* Smaller spinner for mobile */
}

}
  
  /* General styling for the tax summary container */
  .tax-summary {
  background: linear-gradient(135deg, #34b7f1, #16a085); /* Gradient background */
      border-radius: 10px;
      padding: 20px 30px;
      margin-top: 20px;
      border: none;
      box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15); /* Larger shadow for depth */
      font-family: 'Poppins', sans-serif; /* Smooth modern font */
      color: #ffffff; /* White text color */
      animation: fadeIn 1s ease-out; /* Fade-in effect on load */
}

/* Animation for fade-in effect */
  @keyframes fadeIn {
  from {
          opacity: 0;
          transform: translateY(20px);
}

to {
  opacity: 1;
          transform: translateY(0);
}

}
  
  /* Styling for the summary paragraphs */
  .tax-summary p {
  font-size: 1.2em;
      margin: 15px 0;
      line-height: 1.6;
      letter-spacing: 0.5px;
      transition: transform 0.3s ease, color 0.3s ease; /* Smooth transition on hover */
}

/* Hover effect for paragraphs */
  .tax-summary p:hover {
  transform: scale(1.05); /* Slightly zooms in on hover */
      color: #f39c12; /* Change text color on hover */
}

/* Styling for the strong tags */
  .tax-summary strong {
  font-size: 1.1em;
      color: #f39c12; /* Bright color for strong labels */
      letter-spacing: 1px;
}

/* Styling for the values (span) */
  .tax-summary span {
  font-weight: bold;
      font-size: 1.3em;
      color: #f1c40f; /* Gold color for emphasis */
      background: #2c3e50; /* Dark background for the span */
      padding: 5px 10px;
      border-radius: 5px;
      transition: background-color 0.3s ease; /* Smooth background color transition */
}

/* Hover effect for the values (span) */
  .tax-summary span:hover {
  background-color: #e67e22; /* Change background on hover */
}

/* Adding a border on the bottom of each paragraph */
  .tax-summary p:not(:last-child) {
  border-bottom: 2px solid #f39c12;
      padding-bottom: 10px;
}

/* Extra styling for responsiveness */
  @media (max-width: 768px) {
  .tax-summary {
          padding: 15px;
}

.tax-summary p {
  font-size: 1em;
}

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

body {
  font-family: 'Roboto', sans-serif;
      background-color: #f4f7fc;
      color: #333;
      padding: 30px;
      line-height: 1.5;
}

/* Table Styles */
  .tax-report {
  width: 100%;
      margin: 20px 0;
      border-radius: 8px;
      overflow: hidden;
      border: 1px solid #ddd;
      box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
      background-color: white;
      transition: transform 0.3s ease-in-out, box-shadow 0.3s ease;
}

.tax-report th, .tax-report td {
  padding: 15px 20px;
      text-align: center;
      font-size: 1.05em;
      border-bottom: 1px solid #ddd;
}

.tax-report th {
  background-color: #2c3e50;
      color: white;
      text-transform: uppercase;
      letter-spacing: 1px;
      font-weight: 600;
}

.tax-report td {
  background-color: #ecf0f1;
      color: #34495e;
      font-size: 1em;
      transition: background-color 0.3s ease;
}

/* Hover Effect for Table Rows */
  .tax-report tr:hover {
  background-color: #f1f1f1;
      transform: scale(1.02); /* Slight zoom effect */
      box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

/* Button Styling */
  .delete-btn {
  padding: 10px 20px;
      font-size: 1.1em;
      background-color: #e74c3c;
      color: white;
      border: none;
      border-radius: 5px;
      cursor: pointer;
      transition: background-color 0.3s ease, transform 0.3s ease;
      box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.delete-btn:hover {
  background-color: #c0392b;
      transform: scale(1.05); /* Slight grow effect */
}

.delete-btn:active {
  background-color: #d35400;
      transform: scale(1.02); /* Button compression effect on click */
}

.delete-btn:focus {
  outline: none;
}

/* Table Footer Styling (Summary Section) */
  .tax-summary {
  background-color: #2c3e50;
      color: white;
      padding: 20px;
      margin-top: 20px;
      border-radius: 8px;
      box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.tax-summary p strong {
  color: #f39c12;
}

/* Responsive Styles */
  @media (max-width: 768px) {
  .tax-report th, .tax-report td {
          font-size: 0.9em;
          padding: 12px;
}

.delete-btn {
  font-size: 1em;
          padding: 8px 16px;
}

.tax-summary {
  font-size: 1em;
          padding: 15px;
}

}
  
  /* Smooth Scroll for Actions */
  html {
  scroll-behavior: smooth;
}

/* General Totals Section Styles */
  .totals-section {
  background-color: #2c3e50; /* Darker background for contrast */
      color: white; /* White text color for readability */
      padding: 30px;
      border-radius: 10px;
      box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
      margin: 20px 0;
      font-family: 'Roboto', sans-serif;
      font-size: 1.2em;
      max-width: 600px;
      margin-left: auto;
      margin-right: auto;
}

/* Style for each paragraph */
  .totals-section p {
  margin-bottom: 15px;
      padding: 8px 0;
      font-weight: 500;
      text-align: left;
      letter-spacing: 1px;
      position: relative;
}

/* Accent Styles for the Span Elements */
  .totals-section span {
  font-weight: bold;
      font-size: 1.4em; /* Larger font size for values */
      color: #f39c12; /* Gold accent color for values */
      display: inline-block;
      margin-left: 10px;
}

/* Style for each key value (for each span) */
  #subtotal {
  color: #27ae60; /* Green for Subtotal */
}

#taxAmount {
  color: #3498db; /* Blue for Tax */
}

#discountAmount {
  color: #e74c3c; /* Red for Discount */
}

#grandTotal {
  color: #9b59b6; /* Purple for Total */
}

#amountPaid {
  color: #2ecc71; /* Lighter green for Paid */
}

#amountOwed {
  color: #e67e22; /* Orange for Amount Owed */
}

/* Hover Effect on Paragraphs */
  .totals-section p:hover {
  background-color: rgba(255, 255, 255, 0.1); /* Light background change on hover */
      cursor: pointer; /* Show pointer cursor to indicate interactivity */
      transform: scale(1.02); /* Slight zoom effect */
      transition: transform 0.2s ease-in-out, background-color 0.3s ease-in-out;
}

/* Bold Title for Totals Section */
  .totals-section h3 {
  font-size: 1.8em;
      font-weight: bold;
      margin-bottom: 20px;
      text-align: center;
      color: #ecf0f1;
      letter-spacing: 2px;
}

/* Responsive Design (for smaller screens) */
  @media (max-width: 768px) {
  .totals-section {
          padding: 20px;
          font-size: 1em;
}

.totals-section span {
  font-size: 1.2em; /* Adjust span size for smaller screens */
}

.totals-section p {
  font-size: 1em;
}

}

  /* General styling for the receipt section */
#receiptSection {
  background: linear-gradient(135deg, #34b7f1, #16a085); /* Gradient background */
  border-radius: 10px;
  padding: 20px 30px;
  margin-top: 20px;
  border: none;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15); /* Larger shadow for depth */
  font-family: 'Poppins', sans-serif; /* Smooth modern font */
  color: #ffffff; /* White text color */
  animation: fadeIn 1s ease-out; /* Fade-in effect on load */
}

/* Animation for fade-in effect */
@keyframes fadeIn {
  from {
      opacity: 0;
      transform: translateY(20px);
}

}

/* Styling for the receipt table */
.receipt-table {
  width: 100%;
  margin-top: 20px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid #ddd;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  background-color: white;
  transition: transform 0.3s ease-in-out, box-shadow 0.3s ease;
}

/* Table headers */
.receipt-table th {
  padding: 15px 20px;
  text-align: center;
  background-color: #2c3e50;
  color: white;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 600;
}

/* Table data */
.receipt-table td {
  padding: 15px 20px;
  text-align: center;
  background-color: #ecf0f1;
  color: #34495e;
  font-size: 1em;
  transition: background-color 0.3s ease;
}

/* Hover Effect for Table Rows */
.receipt-table tr:hover {
  background-color: #f1f1f1;
  transform: scale(1.02); /* Slight zoom effect */
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

/* Styling for the action buttons */
.receipt-actions {
  display: flex;
  justify-content: center;
  gap: 10px;
}

.receipt-actions button {
  padding: 10px 20px;
  font-size: 1.1em;
  background-color: #e74c3c;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  transition: background-color 0.3s ease, transform 0.3s ease;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.receipt-actions button:hover {
  background-color: #c0392b;
  transform: scale(1.05); /* Slight grow effect */
}

.receipt-actions button:active {
  background-color: #d35400;
  transform: scale(1.02); /* Button compression effect on click */
}

.receipt-actions button:focus {
  outline: none;
}

/* Extra styling for responsiveness */
@media (max-width: 768px) {
  #receiptSection {
      padding: 15px;
}

.receipt-table th, .receipt-table td {
  font-size: 0.9em;
      padding: 12px;
}

}

/* Smooth Scroll for Actions */
html {
  scroll-behavior: smooth;
}

/* Email Receipt Button Styles */
.email-receipt-btn {
  display: inline-block;
  background-color: #007bff; /* Blue color */
  color: white;
  padding: 8px 12px;
  border-radius: 5px;
  text-decoration: none;
  font-size: 14px;
  font-weight: bold;
  transition: background-color 0.3s ease;
}

.email-receipt-btn:hover {
  background-color: #0056b3; /* Darker blue on hover */
}

/* Button: How to Generate Payment Links */
#openGuide {
  background-color: #3498db; /* Blue */
  color: white;
}

/* Root Variables for Easy Customization */
:root {
  --primary-color: #007bff;
  --secondary-color: #28a745;
  --danger-color: #dc3545;
  --warning-color: #ffcc00;
  --bg-light: rgba(180, 155, 165, 0.9);
  --bg-dark: rgba(20, 20, 20, 0.952);
  --text-dark: #333;
  --text-light: #fff;
  --shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Main Container */
#recurringInvoiceContainer {
  font-family: 'Poppins', sans-serif;
  max-width: 100%;
  margin: auto;
  padding: 20px;
  background: var(--bg-light);
  border-radius: 12px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(8px);
  transition: 0.3s ease-in-out;
}

/* Summary Container */
.summary-container {
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  color: var(--text-light);
  padding: 20px;
  border-radius: 12px;
  box-shadow: var(--shadow);
  margin-bottom: 20px;
  text-align: center;
}

.summary-container h3 {
  font-size: 22px;
  font-weight: 600;
  margin-bottom: 10px;
}

.summary-box {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-around;
  gap: 15px;
}

.summary-box p {
  background: rgba(255, 255, 255, 0.2);
  padding: 12px;
  border-radius: 8px;
  font-size: 16px;
  font-weight: bold;
  text-align: center;
  transition: 0.3s ease;
}

.summary-box p:hover {
  background: rgba(255, 255, 255, 0.4);
  transform: scale(1.05);
}

/* Table Styling */
.invoice-history {
  width: 100%;
  border-collapse: collapse;
  background: var(--bg-light);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.invoice-history thead {
  background: var(--primary-color);
  color: var(--text-light);
}

.invoice-history thead th {
  padding: 14px;
  text-align: left;
  font-weight: 600;
}

.invoice-history tbody tr {
  transition: 0.3s ease-in-out;
}

.invoice-history tbody tr:nth-child(even) {
  background: #337dc7;
}

.invoice-history tbody tr:hover {
  background: rgba(0, 123, 255, 0.1);
  transform: scale(1.01);
}

.invoice-history td {
  padding: 12px;
  border-bottom: 1px solid #4a76b9;
}

/* Status Styling */
.invoice-history td[id^="status-"] {
  font-weight: bold;
  padding: 8px;
  border-radius: 6px;
  text-align: center;
}

.invoice-history td[id^="status-"]:contains("Paid") {
  color: var(--secondary-color);
}

.invoice-history td[id^="status-"]:contains("Partially Paid") {
  color: var(--warning-color);
}

.invoice-history td[id^="status-"]:contains("Unpaid") {
  color: var(--danger-color);
}

/* Buttons Styling */
.invoice-history button {
  background: var(--secondary-color);
  color: var(--text-light);
  border: none;
  padding: 8px 12px;
  margin: 3px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
  font-weight: bold;
  transition: 0.3s ease-in-out;
  box-shadow: 2px 2px 6px rgba(0, 0, 0, 0.2);
}

.invoice-history button:hover {
  background: #218838;
  transform: scale(1.05);
}

.invoice-history button:nth-child(2) {
  background: var(--danger-color);
}

.invoice-history button:nth-child(2):hover {
  background: #c82333;
}

.invoice-history button:nth-child(3) {
  background: var(--primary-color);
}

.invoice-history button:nth-child(3):hover {
  background: #0056b3;
}

/* Input Fields */
.invoice-history input {
  padding: 8px;
  border: 1px solid #3aaaad;
  border-radius: 6px;
  width: 90px;
  font-size: 14px;
}

/* Responsive Design */
@media screen and (max-width: 768px) {
  .summary-box {
      flex-direction: column;
      align-items: center;
}

.invoice-history td::before {
  content: attr(data-label);
      float: left;
      font-weight: bold;
      color: var(--text-dark);
}

.invoice-history button {
  width: 100%;
      margin-top: 6px;
}

}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
  #recurringInvoiceContainer {
      background: var(--bg-dark);
      color: var(--text-light);
}

.invoice-history {
  background: var(--bg-dark);
      color: var(--text-light);
}

}

.analyticsModal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(5px); /* Adds a slight blur effect to the background */
  overflow: auto;
}

.analyticsModal-content {
  background: #fff;
  margin: 5% auto;
  padding: 20px;
  border-radius: 12px;
  width: 80%;
  max-width: 1000px;
  text-align: center;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}

.close:hover {
  color: #ff0000;
}

.chart-container {
  width: 100%;
  max-width: 900px;
  margin: 20px auto;
}

canvas {
  width: 100% !important;
  height: auto !important;
  max-height: 500px;
  image-rendering: crisp-edges; /* Helps with reducing blurriness */
}

/* ==== Final Top Navbar Styles ==== */
.top-navbar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  background-color: var(--primary-color);
  color: var(--white);
  padding: 1rem 1.5rem;
  border-radius: 10px;
  margin-bottom: 1.5rem;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.top-navbar h1 {
  font-size: 1.5rem;
  color: var(--white);
  margin: 0;
}

.nav-left {
  display: flex;
  align-items: center;
  gap: 2rem;
  flex-wrap: wrap;
}

.top-navbar nav ul {
  list-style: none;
  display: flex;
  gap: 1rem;
  margin: 0;
  padding: 0;
}

.top-navbar nav a {
  text-decoration: none;
  color: var(--white);
  font-weight: 600;
  transition: color 0.3s ease;
}

.top-navbar nav a:hover {
  color: #e0e0e0;
}

.nav-buttons {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-top: 10px;
}

.nav-buttons button {
  background-color: var(--accent-color);
  color: var(--white);
  padding: 0.5rem 1rem;
  border: none;
  border-radius: 6px;
  font-weight: bold;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.nav-buttons button:hover {
  background-color: var(--secondary-color);
}

@media (max-width: 768px) {
  .top-navbar {
    flex-direction: column;
    align-items: stretch;
    padding: 1rem;
}

}

.tab-navigation {
  display: flex;
  justify-content: center;
  margin: 20px 0;
  gap: 10px;
  flex-wrap: wrap;
}

.tab-navigation button {
  padding: 10px 20px;
  background: #007bff;
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-weight: bold;
  transition: background 0.3s ease;
}

.tab-navigation button:hover {
  background: #0056b3;
}

.tab-view {
  display: none;
  padding: 20px;
}

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

.wizard-step {
  display: none;
}
.active-step {
  display: block;
}

.wizard-navigation {
  display: flex;
  justify-content: space-between;
  margin-top: 20px;
}

#wizard-navigation button {
  padding: 10px 20px;
  font-size: 1rem;
}
