
  .modal {
      display: none; /* Hidden by default */
      position: fixed; /* Stay in place */
      z-index: 9999; /* Higher z-index to ensure it's on top */
      left: 0;
      top: 0;
      width: 100%; /* Full width */
      height: 100%; /* Full height */
      overflow: auto; /* Enable scroll if needed */
      background-color: rgba(0,0,0,0.4); /* Black w/ opacity */
  }

  .modal-content {
      background-color: #fff;
      margin: 5% auto; /* 5% from the top and centered */
      padding: 2rem;
      border-radius: 12px;
      width: 90%; /* Could be more or less, depending on screen size */
      max-width: 800px;
      position: relative;
      box-shadow: 0 4px 6px rgba(0,0,0,0.1);
      z-index: 10000; /* Higher than modal background */
  }

  .close-btn {
      position: absolute;
      top: 15px;
      right: 20px;
      font-size: 28px;
      font-weight: bold;
      cursor: pointer;
      z-index: 10001; /* Highest z-index for interaction */
  }

  .form-group {
      display: flex;
      flex-wrap: wrap;
      gap: 1rem;
      margin: 1rem 0;
  }

  .input-group {
      flex: 1 1 45%;
      min-width: 250px;
  }

  .input-group label {
      display: block;
      margin-bottom: 0.5rem;
      font-weight: 500;
  }

  .input-group input,
  .input-group select {
      width: 100%;
      padding: 0.8rem;
      border: 1px solid #ccc;
      border-radius: 6px;
      font-size: 1rem;
  }

  .form-actions {
      display: flex;
      justify-content: flex-end;
      gap: 1rem;
      margin-top: 1.5rem;
  }

  .cancel-btn,
  .submit-btn {
      padding: 0.7rem 1.5rem;
      border: none;
      border-radius: 6px;
      font-weight: bold;
      cursor: pointer;
      font-size: 1rem;
  }

  .cancel-btn {
      background-color: white;
      border: 1px solid #9c0f3f;
      color: #9c0f3f;
  }

  .submit-btn {
      background-color: #9c0f3f;
      color: white;
  }

  /* Tab styles */
  .tabs {
      display: flex;
      gap: 2px;
      background: #f0f0f0;
      padding: 10px 10px 0;
      border-radius: 8px 8px 0 0;
      margin: -2rem -2rem 2rem;
  }

  .tab {
      padding: 12px 20px;
      background: #fff;
      border: none;
      border-radius: 8px 8px 0 0;
      cursor: pointer;
      font-weight: 500;
      color: #666;
      transition: all 0.3s ease;
  }

  .tab:hover {
      background: #f8f8f8;
  }

  .tab.active {
      background: #9c0f3f;
      color: white;
  }

  .tab-content {
      display: none;
  }

  .tab-content.active {
      display: block;
      animation: fadeIn 0.3s ease;
  }

  .success-message {
      display: none;
      background-color: #4CAF50;
      color: white;
      padding: 1rem;
      border-radius: 6px;
      margin-bottom: 1rem;
      text-align: center;
      font-size: 1.2rem;
  }

  @keyframes fadeIn {
      from { opacity: 0; }
      to { opacity: 1; }
  }
