/* RESET & BASE */
body {
  font-family: 'Segoe UI', sans-serif;
  background: #d1d4d6; /* replace your existing light background */
  margin: 0;
  padding: 1em;
}

h1 {
  font-size: 1.4em;
  margin: 0;
}
h2 {
  font-size: 1.4em;
  margin: 0;
  color: #000000;
}
header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1em;
}

#reminderCard h3 {
  margin: 0 0 0.5em;
  color: #222;
  font-size: 1.2em;
}

#reminderList {
  list-style: none;
  padding: 0;
  margin: 0;
}

#reminderList li {
  background: #fff;
  padding: 0.6em 1em;
  margin: 0.4em 0;
  border-radius: 8px;
  font-size: 0.95em;
  color: #333;
  box-shadow: 0 2px 4px rgba(0,0,0,0.08);
}


.button {
  background: #007bff;
  color: white;
  padding: 0.5em 1em;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  display: inline-block;
}

.full {
  width: 100%;
  margin-top: 1em;
}

/* FORM */
form {
  display: flex;
  flex-direction: column;
  gap: 1em;
}

.form-group {
  display: flex;
  flex-direction: column;
}

.form-group input,
.form-group select,
.form-group textarea {
  padding: 0.5em;
  border: 1px solid #ccc;
  border-radius: 6px;
}

/* CARDS */
#poList .card {
  background: #fff;
  padding: 1em;
  border-radius: 10px;
  margin-bottom: 0.7em;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 15px;
  font-weight: bold;
  padding: 6px 8px;
  border-bottom: 1px solid #ccc;
  cursor: pointer;
}

.client-name {
  font-size: 1em;
  font-weight: bold;
}

.card-details {
  padding-top: 6px;
  margin-top: 6px;
}

.card-details.hidden {
  display: none;
}

.card-section {
  margin: 4px 0;
  word-wrap: break-word;
  white-space: pre-wrap;
  overflow-wrap: break-word;
}

.card-section span.label {
  font-weight: bold;
  display: inline-block;
  width: 140px;
}

.status {
  font-weight: bold;
  color: white;
  padding: 0.2em 0.5em;
  border-radius: 6px;
  font-size: 15px;
}

.status.paid {
  background-color: #28a745;
}

.status.unpaid {
  background-color: #dc3545;
}

.card .delete-btn {
  background: #dc3545;
  color: white;
  border: none;
  padding: 0.3em 0.6em;
  font-size: 0.8em;
  border-radius: 6px;
  float: right;
  cursor: pointer;
}

.card-actions {
  margin-top: 0.5em;
}

/* SUMMARY */
#summary {
  background: #fff;
  padding: 1em;
  border-radius: 10px;
  margin-bottom: 1em;
  box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

#summary div {
  margin: 0.3em 0;
  font-size: 1em;
}

/* TOAST */
.toast {
  position: fixed;
  bottom: 1rem;
  left: 50%;
  transform: translateX(-50%);
  background: #333;
  color: white;
  padding: 0.75em 1.5em;
  border-radius: 8px;
  font-size: 0.95em;
  opacity: 0.95;
  z-index: 9999;
  transition: opacity 0.4s ease, transform 0.4s ease;
}
.toast.hidden {
  display: none;
}

/* MODAL */
.modal {
  position: fixed;
  top: 0; left: 0;
  width: 100vw; height: 100vh;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}
.modal.hidden {
  display: none;
}
.modal-content {
  background: white;
  padding: 2rem;
  border-radius: 10px;
  text-align: center;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}
#closeModalBtn {
  margin-top: 1rem;
  padding: 0.5rem 1rem;
  background-color: #0a7;
  border: none;
  color: white;
  font-weight: bold;
  border-radius: 5px;
  cursor: pointer;
}

/* NOTES */
.notes-content {
  white-space: pre-wrap;
  word-wrap: break-word;
  overflow-wrap: break-word;
  margin-top: 4px;
}

/* INVOICE LIST (COMPACT, CLEAN) */
.invoice-list {
  list-style: none;
  padding: 0;
  margin: -3.0em 0;
}

.invoice-list li {
  margin: -20px 0;
  padding: 1px 10px;
  background: #d9dbdc;
  border: 4px solid #04884b;
  border-radius: 9px;
  font-size: 17px;
  line-height: .4;
  color: #060606;
}

.invoice-list li div {
  font-weight: bold;
  margin-bottom: 2px;
}

.invoice-list li small {
  display: block;
  font-size: 12px;
  color: #131313;
  font-weight: bold;
  margin-left: 10px;
  line-height: .8;
}

.invoice-list .badge {
  margin-left: 6px;
  font-size: 14px;
  padding: 2px 6px;
  border-radius: 4px;
}

.badge.paid {
  background: #d4edda;
  color: #155724;
}

.badge.warning {
  background: #fff3cd;
  color: #856404;
}











.invoice-group {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
  gap: 0.5em;
  margin-bottom: 0.6em;
  background: #f0f2f5;
  padding: 0.6em;
  border-radius: 5px;
  border: 1px solid #ccc;
  font-size: 1.3em;
  align-items: center;
}

.invoice-group input,
.invoice-group select {
  font-size: 0.85em;
  padding: 0.3em 0.5em;
  border-radius: 4px;
  border: 1px solid #bbb;
  height: 28px;
  width: 100%;
  box-sizing: border-box;
}

.invoice-group label {
  display: flex;
  flex-direction: column;
  font-size: 0.75em;
  font-weight: 600;
  margin: 0;

}

/* 📱 Mobile: stack cleanly */
@media (max-width: 600px) {
  .invoice-group {
    grid-template-columns: 1fr;
    gap: 0.4em;
  }
}


.user-email {
  margin-left: 1rem;
  font-weight: bold;
  color: #333;
}

.logout-btn {
  margin-left: 1rem;
  background: #f44336;
  color: white;
  border: none;
  padding: 0.5em 1em;
  border-radius: 6px;
  cursor: pointer;
  font-weight: bold;
}

.logout-btn:hover {
  background: #d32f2f;
}


/*====================INDEX.HTML=========================*/
.main-header {
  background: white;
  padding: 1em;
  border-radius: 12px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
  margin-bottom: 1.5em;
}

.logo-section {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 1em;
  flex-wrap: wrap;
}

.logo {
  width: 50px;
  height: auto;
  border-radius: 6px;
}

.title-text h1 {
  margin: 0;
  font-size: 1.3em;
}

.app-desc {
  margin: 0;
  font-size: 0.9em;
  color: #666;
}

.button-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5em;
  margin-top: 1em;
}

.user-bar {
  margin-top: 1em;
  font-size: 0.95em;
  color: #444;
  font-weight: bold;
}

/* 📱 Mobile optimization */
@media (max-width: 600px) {
  .logo-section {
    flex-direction: column;
    align-items: flex-start;
  }

  .button-group {
    flex-direction: column;
    align-items: stretch;
  }

  .button-group a,
  .button-group button {
    width: 100%;
    text-align: center;
  }

  .user-bar {
    text-align: center;
  }
}

/* Header Card Styling */
.header-card {
  background: white;
  padding: 1em;
  margin-bottom: 1em;
  border-radius: 12px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.08);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 1em;
  border: 1px solid #ddd;
}


/* Logo + title */
#appHeaderCard {
  flex-direction: column;
}

.header-logo {
  width: 60px;
  height: auto;
  border-radius: 8px;
}

.header-title h1 {
  margin: 0.2em 0 0 0;
  font-size: 1.4em;
}

.header-title p {
  margin: 0.3em 0 0 0;
  font-size: 0.95em;
  color: #555;
}

/* Button group */
#buttonCard {
  flex-direction: row;
  flex-wrap: wrap;
  gap: 0.75em;
}

#buttonCard .button {
  min-width: 120px;
  text-align: center;
}

.logout-btn {
  background-color: #dc3545;
}

/* Logged-in user */
#userCard {
  font-size: 0.95em;
  color: #000000;
  font-weight: bold;
  justify-content: center;
}

.header-title h1 {
  color: #222;
}

.header-title p {
  color: #444;
}


/*=========================buttons on index======================*/
/* Core button styling */
/* Button container: row layout with wrap on small screens */
#buttonCard {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  padding: 1em;
  background-color: #f9f4f4;
  border-radius: 8px;
}

/* Shared button styling */
.button,
.button:visited {
  padding: 10px 16px;
  font-size: 1rem;
  font-weight: 600;
  color: white;
  background-color: #007bff;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: background-color 0.2s ease;
  white-space: nowrap;
}

/* Button hover effect */
.button:hover {
  background-color: #0056b3;
}

/* Variants */
.button.dark {
  background-color: #e97d01;
}
.button.dark:hover {
  background-color: #f0f2f4;
}

.button.logout-btn {
  background-color: #dc3545;
}
.button.logout-btn:hover {
  background-color: #a71d2a;
}

.button.help-btn {
  background-color: #6c757d;
}
.button.help-btn:hover {
  background-color: #495057;
}

.header-card {
  background-color: #e6e6e8;
  padding: 1rem;
  margin: 1rem auto;
  border-radius: 10px;
  max-width: 960px;
  color: #fff;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

/* Force horizontal alignment for the unique button row */
/* Shared row container */
.button-row-wrap {
  display: flex !important;
  flex-wrap: wrap !important;
  justify-content: center !important;
  gap: 10px !important;
  padding: 10px !important;
}
.button {
  text-align: center !important;
  vertical-align: middle !important;
  line-height: normal !important;
  display: inline-block !important;
}
/* Individual button override */
.btn-new,
.btn-help,
.btn-admin,
.btn-export,
.btn-logout {
  flex: 1 1 auto !important;
  min-width: 120px !important;
  max-width: 150px !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  padding: 8px 10px !important;
  font-size: 14px !important;
  text-align: center !important;
}

/* Uniform button width */
.btn-new,
.btn-help,
.btn-admin,
.btn-export,
.btn-logout {
  flex: 1 1 150px !important;
  max-width: 150px !important;
  min-width: 150px !important;
  text-align: center !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  padding: 8px 10px !important;
  font-size: 14px !important;
}

/* 3D Button Base Style */
.button-row-wrap .button {
  background: linear-gradient(to bottom, #0074d9, #005fa3) !important;
  color: white !important;
  border: none !important;
  border-radius: 8px !important;
  box-shadow: 0 4px 0 #003d73 !important;
  transition: all 0.15s ease-in-out !important;
  cursor: pointer !important;
  font-weight: 600 !important;
}

/* Hover effect */
.button-row-wrap .button:hover {
  background: linear-gradient(to bottom, #339cff, #0074d9) !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 5px 0 #003d73 !important;
}

/* Active (click) effect */
.button-row-wrap .button:active {
  transform: translateY(2px) !important;
  box-shadow: 0 2px 0 #002f5a !important;
}


@media (max-width: 600px) {
  .btn-new,
  .btn-help,
  .btn-admin,
  .btn-export,
  .btn-logout {
    flex: 1 1 100% !important;
    max-width: 100% !important;
    min-width: unset !important;
  }
}
.button-row-wrap * {
  box-sizing: border-box !important;
}


/*---------------------------------search filters------------------*/

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: space-between;
}

.filter-bar input,
.filter-bar select {
  flex: 1 1 45%;
  min-width: 140px;
  padding: 10px;
  border-radius: 8px;
  border: none;
  font-size: 1rem;
}

.status-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  justify-content: flex-start;
  max-width: 100%;
}

.badge.warning {
  background: #814705;
  color: white;
  padding: 2px 6px;
  font-size: 0.75rem;
  border-radius: 4px;
  font-weight: bold;
  white-space: nowrap;
  flex-shrink: 0;
}
@media (max-width: 600px) {
  .card-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
  }

  .card-header > .status-row {
    margin-top: 6px;
    align-self: stretch;
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
  }

  .card-header .status,
  .card-header .badge {
    margin-left: 0;
    width: fit-content;
  }
}










@media (max-width: 600px) {
  .button-row-wrap .button {
    flex: 1 1 100% !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    margin: 0 !important;
  }
}

.button span {
  width: 100%;
  display: inline-block;
  text-align: center;
}
@media (max-width: 600px) {
  .button-row-wrap {
    flex-direction: column !important;
    gap: 10px !important;
    align-items: stretch !important;
  }
}

/*-----------------Notes by user styling-------------------*/
.admin-notes-input {
  width: 98%;
  padding: 6px;
  border: 1px solid #ccc;
  border-radius: 4px;
  resize: vertical;
}
.admin-notes-input {
  width: 100%;
  box-sizing: border-box;
  min-height: 80px;
  resize: vertical;
  font-size: 1em;
}

@media screen and (max-width: 768px) {
  .admin-notes-input {
    font-size: 1em;
    padding: 0.5em;
  }

  .card-section {
    padding: 0.5em 0;
  }

  .label {
    font-size: 1em;
    display: block;
    margin-bottom: 0.25em;
  }
}
@media (max-width: 600px) {
  .admin-notes-input {
    display: block !important;
    width: 100% !important;
    min-height: 80px !important;
    font-size: 1rem !important;
    padding: 0.5em !important;
    border: 1px solid #ccc !important;
    border-radius: 6px !important;
    box-sizing: border-box !important;
    background: #fff !important;
    color: #000 !important;
  }

  .card-section {
    display: block !important;
    width: 100% !important;
    padding: 8px 0 !important;
  }
}


.card-details {
  padding: 10px;
  background: #f9f9f9;
  font-size: 1rem;
}

@media (max-width: 600px) {
  .card {
    font-size: 0.95rem;
  }

}
.admin-notes-input {
  background: #fff;
  color: #000;
}

/*--------------------------splashscreen-----------------------------*/
#splash-screen {
  position: fixed;
  top: 0; left: 0;
  width: 100vw; height: 100vh;
  background: #ffffff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity 0.5s ease;
  padding: 1rem;
  box-sizing: border-box;
  text-align: center;
  overflow: hidden;
}



.splash-image {
  width: 100%;
  max-width: 180px;
  height: auto;
  object-fit: contain;
  opacity: 0;
  animation: fadeSlideUp 1s ease forwards;
  display: block;
}



.splash-text {
  margin-top: 1rem;
  font-size: 1em;
  font-weight: bold;
  color: #333;
  overflow: hidden;
  white-space: nowrap;
  border-right: 2px solid #333;
  width: 0;
  max-width: 90vw;
  animation:
    typing 2.2s steps(36, end) forwards 1.1s,
    blink 0.6s step-end infinite alternate 3.4s;
}

/* Animations */
@keyframes fadeSlideUp {
  0% { opacity: 0; transform: translateY(40px); }
  100% { opacity: 1; transform: translateY(0); }
}

@keyframes typing {
  from { width: 0 }
  to { width: 100% }
}

@keyframes blink {
  50% { border-color: transparent }
}

@media (max-width: 600px) {
  .splash-image {
    max-width: 140px;
  }

  .splash-text {
    font-size: 1em;
    padding: 0 1rem;
  }

  #splash-screen {
    padding: 1.5rem 0.5rem;
  }
}



.clear-filter-btn {
  background-color: #eee;
  border: 1px solid #ccc;
  padding: 6px 12px;
  border-radius: 6px;
  cursor: pointer;
  font-weight: bold;
}
.clear-filter-btn:hover {
  background-color: #ddd;
}


.button.clear-filter {
  background: linear-gradient(to bottom, #6c757d, #5a6268) !important;
  color: white !important;
  border: none !important;
  border-radius: 8px !important;
  box-shadow: 0 4px 0 #343a40 !important;
  transition: all 0.15s ease-in-out !important;
  cursor: pointer !important;
  font-weight: 600 !important;
}

.button.clear-filter:hover {
  background: linear-gradient(to bottom, #868e96, #6c757d) !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 5px 0 #343a40 !important;
  border: 3px solid #15f837 !important;
}

.button.clear-filter:active {
  transform: translateY(2px) !important;
  box-shadow: 0 2px 0 #2e3338 !important;
}

#reminderCard {
  position: relative;
  z-index: 10;
}

#reminderCard button {
  pointer-events: auto;
  z-index: 11;
  position: relative;
}
.reminder-btn {
  pointer-events: auto;
  position: relative;
  z-index: 2;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}











/* ------------------------------------------------------------------- VENDOR CARD FIXES --------------------------------------------------- */
.list-container {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1rem;
  max-width: 1100px;
  margin: auto;
}

.card {
  background: #ffffff;
  padding: 1rem;
  border-radius: 12px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.08);
  margin: 0 auto;
  max-width: 800px;
}

.card-header {
  cursor: pointer;
  text-align: left;
  border-bottom: 1px solid #eee;
  padding-bottom: 6px;
}

.card-header h3 {
  margin: 0;
  color: #003366;
  font-size: 1.2rem;
}

.card-header p {
  margin: 0;
  font-size: 0.95rem;
  color: #666;
}

.card-details {
  font-size: 0.95rem;
  line-height: 1.5;
  padding-top: 10px;
  text-align: left;
}

.card-details.hidden {
  display: none;
}

.invoice-section {
  border: 4px solid #ccc;
  border-radius: 10px;
  background-color: #fdfdfd;
  margin-top: 20px;
  padding: 15px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.invoice-heading {
  margin-top: 0;
  margin-bottom: 10px;
  font-size: 1.1em;
  border-bottom: 1px solid #ddd;
  padding-bottom: 5px;
}

.invoice-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 10px;
  font-size: 0.9em;
}

.invoice-table th,
.invoice-table td {
  padding: 8px 10px;
  border: 1px solid #ddd;
  text-align: left;
}

.invoice-table th {
  background-color: #f2f2f2;
}

.invoice-total-row {
  margin-top: 10px;
  font-weight: bold;
}

.no-invoice-text {
  font-style: italic;
  color: #777;
  margin: 10px 0;
}

.vendor-page .invoice-row {
  margin: 4px 0;
  font-size: 0.85rem;
}

.invoice-card {
  background: #f7faff;
  border: 4px solid #ccddee;
  border-radius: 8px;
  padding: 10px;
  margin-bottom: 10px;
  box-shadow: 1px 1px 5px rgba(0,0,0,0.05);
}

.invoice-top {
  display: flex;
  justify-content: space-between;
  font-size: 0.95rem;
  font-weight: 500;
  margin-bottom: 6px;
  color: #003366;
}

.invoice-actions {
  display: flex;
  gap: 0.5rem;
}
/* Responsive Enhancements */
@media (max-width: 600px) {
  .tabs {
    flex-direction: column;
    align-items: center;
  }

 


  .vendor-header img {
    width: 64px;
    height: 64px;
  }

  .vendor-header h1 {
    font-size: 1.4rem;
  }

  .vendor-header p {
    font-size: 0.9rem;
  }
}

.vendor-page .button {
  font-size: 0.85rem;
  padding: 0.4rem 0.9rem;
  border-radius: 6px;
  width: 80px;
}

.vendor-page .button.btn-small {
  font-size: 0.75rem;
  padding: 0.3rem 0.6rem;
}

.vendor-page .add-invoice-btn {
  background-color: #056805;
  color: #fff;
  font-size: 0.85rem;
  padding: 0.4rem 1rem;
  margin-top: 8px;
  border-radius: 6px;
  width: 120px;
}

.vendor-page .add-invoice-btn:hover {
  background-color: #0c5fa3;
}

.vendor-page .save-vendor-btn,
.vendor-page .cancel-vendor-btn {
  font-size: 0.7rem;
  padding: 0.5rem 1.2rem;
  border-radius: 6px;
  width: 130px;
  height: 34px;
  text-align: center;
}

/* Save-specific colors */
.vendor-page .save-vendor-btn {
  background-color: #2a6d1c;
  color: #fff;
}

.vendor-page .save-vendor-btn:hover {
  background-color: #378c25;
}

/* Cancel-specific colors */
.vendor-page .cancel-vendor-btn {
  background-color: #fcb4b4;
  color: white;
}

.vendor-page .cancel-vendor-btn:hover {
  background-color: #c94444;
}

/* Invoice Buttons Styled to Match Other UI */
.vendor-page .btn-edit-invoice,
.vendor-page .btn-delete-invoice {
  font-size: 0.75rem;
  padding: 0.3rem 0.6rem;
  border-radius: 6px;
  width: 80px;
  text-align: center;
  color: white;
}

/* Green Edit Button */
.vendor-page .btn-edit-invoice {
  background-color: #2a6d1c;
}

.vendor-page .btn-edit-invoice:hover {
  background-color: #378c25;
}

/* Red Delete Button */
.vendor-page .btn-delete-invoice {
  background-color: #c94444;
}

.vendor-page .btn-delete-invoice:hover {
  background-color: #9e2e2e;
}
.po-meta {
  font-size: 0.85em;
  color: #555;
  margin-top: 2px;
}
.po-meta {
  font-size: 0.85em;
  color: #555;
  margin-top: 2px;
}




/*---------------------settigns page user request styling---------------------*/

.modal {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0, 0, 0, 0.6);
  display: flex; align-items: center; justify-content: center;
  z-index: 999;
}
.modal-content {
  background: white;
  padding: 20px;
  border-radius: 8px;
  width: 90%;
  max-width: 400px;
  position: relative;
}
/*----------------------------------------------settjngs button styling----------------------------*/
/* Settings button that preserves 3D look */
.button-row-wrap .btn-settings {
  background: linear-gradient(to bottom, #d8bd0b, #e35007) !important;
  box-shadow: 0 4px 0 #f04106 !important;
  color: white !important;
}

.button-row-wrap .btn-settings:hover {
  background: linear-gradient(to bottom, #f60804, #ffa463) !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 5px 0 #f12e07 !important;
}

.button-row-wrap .btn-settings:active {
  transform: translateY(2px) !important;
  box-shadow: 0 2px 0 #1d1a77 !important;
}

.btn-settings {
  flex: 1 1 150px !important;
  max-width: 150px !important;
  min-width: 150px !important;
  text-align: center !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  padding: 8px 10px !important;
  font-size: 14px !important;
}



/*-------------------------------------new settigns chat and messagign servcie stylign-----------------------*/
/*----------------------chat window total----------------*/
.chat-panel {
  position: fixed;
  top: 0;
  right: 0;
  width: 350px;
  height: 100%;
  background: #fff;
  border-left: 2px solid #ccc;
  display: flex;
  flex-direction: column;
  z-index: 999;
  box-shadow: -2px 0 5px rgba(0,0,0,0.1);
  transition: transform 0.3s ease;
}
.chat-panel.hidden {
  transform: translateX(100%);
}


/*----------------------length of chat window total----------------*/
.chat-messages {
  flex: 1;
  padding: 1em;
  overflow-y: auto;
}


/*----------------------chat window input box for text----------------*/
.chat-input textarea {
  width: 100%;
  height: 60px;
  resize: none;
  border-radius: 10px;
}
.chat-input input[type="file"] {
  margin-top: 0.5em;
  margin-bottom: 0.5em;
  border-radius: 10px;
}


.chat-message {
  margin: 0.5em;
  max-width: 90%;
}
.chat-message.user {
  align-self: flex-end;
  text-align: left;
}
.chat-message.dev {
  align-self: flex-start;
  text-align: left;
}
.bubble {
  padding: 0.75em;
  border-radius: 12px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

/* === Chat bubble meta + file display === */
/* === Chat Meta user email color=== */
.bubble-meta {
  font-size: 8.75px;
  color: #13f603;
  margin-bottom: 0.25em;
}
.bubble-file {
  font-size: 0.8em;
  color: #0074d9;
  margin-top: 0.5em;
}

/* === Default Theme === */
#chatPanel[data-theme="default"] {
  background: #f9f9f9;
  color: #222;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 14px;
}
#chatPanel[data-theme="default"] .bubble {
  background: #e0e0e0;
  color: #000;
}
#chatPanel[data-theme="default"] .chat-header {
  background: #0074d9;
  border-bottom: 6px solid #0541bb;
  color: #fff;
}
#chatPanel[data-theme="default"] .chat-input {
  background: #0074d9;
  border-top: 6px solid #0541bb;
}

/* === Dark Theme === */
#chatPanel[data-theme="dark"] {
  background: #222;
  color: #ccc;
  font-family: 'Fira Code', monospace;
  font-size: 14px;
}
#chatPanel[data-theme="dark"] .bubble {
  background: #333;
  color: #eee;
}
#chatPanel[data-theme="dark"] .chat-header {
  background: #111;
  border-bottom: 6px solid #666;
  color: #eee;
}
#chatPanel[data-theme="dark"] .chat-input {
  background: #111;
  border-top: 6px solid #666;
}

/* === Terminal Theme === */
#chatPanel[data-theme="terminal"] {
  background: #000;
  color: #00ff00;
  font-family: 'Source Code Pro', monospace;
  font-size: 14px;
}
#chatPanel[data-theme="terminal"] .bubble {
  background: #111;
  color: #00ff00;
}
#chatPanel[data-theme="terminal"] .chat-header {
  background: #000;
  border-bottom: 6px solid #0f0;
  color: #0f0;
}
#chatPanel[data-theme="terminal"] .chat-input {
  background: #000;
  border-top: 6px solid #0f0;
}

/* === Blush Theme === */
#chatPanel[data-theme="blush"] {
  background: #ffd1dc;
  color: #000;
  font-family: 'Comic Sans MS', cursive;
  font-size: 13px;
}
#chatPanel[data-theme="blush"] .bubble {
  background: #fff0f5;
  color: #111;
}
#chatPanel[data-theme="blush"] .chat-header {
  background: #ff69b4;
  border-bottom: 6px solid #ff1493;
  color: #fff;
}
#chatPanel[data-theme="blush"] .chat-input {
  background: #ff69b4;
  border-top: 6px solid #ff1493;
}

/* === Retro Theme === */
#chatPanel[data-theme="retro"] {
  background: #ebc27c;
  color: #333;
  font-family: 'Comic Sans MS';
  font-size: 14px;
}
#chatPanel[data-theme="retro"] .bubble {
  background: #ec7f02;
  color: #222;
}
#chatPanel[data-theme="retro"] .chat-header {
  background: #ec7f02;
  border-bottom: 6px solid #e30f04;
  color: #fff;
}
#chatPanel[data-theme="retro"] .chat-input {
  background: #ec7f02;
  border-top: 6px solid #e30f04;
}

/* === Lavender Theme === */
#chatPanel[data-theme="lavender"] {
  background: #e6e6fa;
  color: #4b0082;
  font-family: 'Georgia', serif;
  font-size: 14px;
}
#chatPanel[data-theme="lavender"] .bubble {
  background: #d8bfd8;
  color: #4b0082;
}
#chatPanel[data-theme="lavender"] .chat-header {
  background: #b19cd9;
  border-bottom: 6px solid #9370db;
  color: #fff;
}
#chatPanel[data-theme="lavender"] .chat-input {
  background: #b19cd9;
  border-top: 6px solid #9370db;
}

/* === Mint Theme === */
#chatPanel[data-theme="mint"] {
  background: #e8fff1;
  color: #1a4d2e;
  font-family: 'Arial', sans-serif;
  font-size: 14px;
}
#chatPanel[data-theme="mint"] .bubble {
  background: #c1f1d8;
  color: #1a4d2e;
}
#chatPanel[data-theme="mint"] .chat-header {
  background: #57cc99;
  border-bottom: 6px solid #38a169;
  color: #fff;
}
#chatPanel[data-theme="mint"] .chat-input {
  background: #57cc99;
  border-top: 6px solid #38a169;
}

/* === Sky Theme === */
#chatPanel[data-theme="sky"] {
  background: #e0f7ff;
  color: #004e7c;
  font-family: 'Verdana', sans-serif;
  font-size: 14px;
}
#chatPanel[data-theme="sky"] .bubble {
  background: #cceeff;
  color: #004e7c;
}
#chatPanel[data-theme="sky"] .chat-header {
  background: #00aaff;
  border-bottom: 6px solid #0077cc;
  color: #fff;
}
#chatPanel[data-theme="sky"] .chat-input {
  background: #00aaff;
  border-top: 6px solid #0077cc;
}

/* === Ocean Theme === */
#chatPanel[data-theme="ocean"] {
  background: #e0f0f8;
  color: #00334d;
  font-family: 'Tahoma', sans-serif;
  font-size: 14px;
}
#chatPanel[data-theme="ocean"] .bubble {
  background: #b3d9ff;
  color: #00334d;
}
#chatPanel[data-theme="ocean"] .chat-header {
  background: #005f99;
  border-bottom: 6px solid #003f66;
  color: #fff;
}
#chatPanel[data-theme="ocean"] .chat-input {
  background: #005f99;
  border-top: 6px solid #003f66;
}

/* === Cotton Candy Theme === */
#chatPanel[data-theme="cottoncandy"] {
  background: #fff0fb;
  color: #cc2a7f;
  font-family: 'Comic Sans MS', cursive;
  font-size: 14px;
}
#chatPanel[data-theme="cottoncandy"] .bubble {
  background: #ffc9ec;
  color: #8e1754;
}
#chatPanel[data-theme="cottoncandy"] .chat-header {
  background: #ff82c0;
  border-bottom: 6px solid #d63384;
  color: #fff;
}
#chatPanel[data-theme="cottoncandy"] .chat-input {
  background: #ff82c0;
  border-top: 6px solid #d63384;
}

/* === Bubble borders by sender === */
/*.chat-message.user .bubble { border-left: 5px solid #0074d9; }*/
/*.chat-message.dev .bubble  { border-right: 5px solid #ff4136; }*/

/* === Developer Bubble === */
.chat-message.developer .bubble {

  border: 2px solid #a03426 !important;
  border-radius: 20px 20px 0px 20px !important;
  font-family: 'Source Code Pro', monospace;
  font-size: 12px;

  box-shadow: 0 2px 8px rgba(255, 153, 0, 0.3) !important;
  margin-right: auto !important;
}

/* === Current User Bubble === */
.chat-message.user .bubble {
 
  border: 2px solid #26669e !important;
  border-radius: 20px 0 20px 20px !important;
  font-family: 'Source Code Pro', monospace;
  font-size: 12px;

  box-shadow: 0 2px 8px rgba(0, 116, 217, 0.3) !important;
  margin-left: auto !important;
}

/* === Recipient Bubble (not developer, not current user) === */
.chat-message.recipient .bubble {

  border: 3px solid #26669e !important;
  border-radius: 0px 20px 20px 20px !important;
  font-family: 'Source Code Pro', monospace ;
  font-size: 12px;

  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1) !important;
  margin-right: auto !important;
}

/* === Common Layout for All Chat Bubbles === */
.chat-message {
  display: flex !important;
  margin: 0.4rem 0 !important;
  max-width: 90% !important;
}

.chat-message.user {
  justify-content: flex-end !important;
}
.chat-message.developer,
.chat-message.recipient {
  justify-content: flex-start !important;
}
/*-----------------------------------------------------------------------------------------------------------*/
.chat-message.developer .bubble-meta {
  color: #093dc1;
  font-weight: bold;
}

.chat-message.developer .bubble-file {
  color: #111111;
}
/* Developer Bubble Style */
.developer-bubble .bubble {
  background: linear-gradient(to right, #7e57c2, #9575cd);
  border-radius: 20px 20px 0 20px;
  /*border-left: 5px solid #3206f6;*/
  animation: fadeSlideIn 0.5s ease-out;
}

/* Developer Name Styling */
.dev-name {
  color: #f92707;
  font-size: 14px;
}

/* Entry Animation */
@keyframes fadeSlideIn {
  0% {
    opacity: 0;
    transform: translateX(-20px) scale(0.95);
  }
  100% {
    opacity: 1;
    transform: translateX(0) scale(1);
  }
}





/*-------------------------testing------------------------------------*/

.chat-input {
  padding: 1em;
  border-top: 6px solid #b806ee;
  background: #0074d9;
}

.chat-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1em;
  background: #0074d9;
  border-bottom: 6px solid #b806ee;
  color: white;
}

.bubble {
  position: relative;
  padding: 0.75em;
  margin: 2px;
  border-radius: 12px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

/* DELETE BUTTON STYLE */
.delete-btn {
  position: absolute;
  top: 6px;
  right: 8px;
  background: transparent;
  border: none;
  font-size: 12px;
  color: #888;
  cursor: pointer;
  padding: 0;
  opacity: 0.6;
  transition: opacity 0.2s ease;
}
.delete-btn:hover {
  opacity: 1;
  color: red;
}

/* EDIT BUTTON STYLE */
.bubble .edit-btn {
  position: absolute;
  bottom: 6px;
  right: 8px;
  background: transparent;
  border: none;
  font-size: 12px;
  color: #888;
  cursor: pointer;
  padding: 0;
  opacity: 0.6;
  transition: opacity 0.2s ease;
}

.bubble .edit-btn:hover {
  opacity: 1;
  color: #0074d9;
}

.vendor-card.collapsed .chat-details {
  display: none;
}

/*---------------------------------privat chat styling---------------------------*/

.chat-summary {
  cursor: pointer;
  padding: 0.5rem;
  background: #f4f4f4;
  border-bottom: 1px solid #ddd;

}
.chat-summary h4 {
  margin: 0;
  font-size: 1rem;
}
.chat-details {
  padding: 0.5rem;
}




.section-title {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 15px;
  color: #333;
}


.vendor-card {
  background: white;
  border-radius: 12px;
  box-shadow: 0 0 4px rgba(0,0,0,0.05);
  padding: 12px 16px;
  cursor: pointer;
  transition: all 0.3s ease;
  border: 1px solid #ddd;
}

.vendor-card.collapsed {
  padding: 12px 16px;
}

.vendor-card:hover {
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.chat-summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.chat-summary h4 {
  margin: 0;
  font-size: 1.1rem;
}

.chat-details {
  margin-top: 10px;
  transition: max-height 0.3s ease;
}

#floatingChatIcon {
  position: fixed;
  bottom: 20px;
  right: 20px;
  font-size: 26px;
  background: #007bff;
  color: white;
  border-radius: 50%;
  padding: 10px 12px;
  cursor: pointer;
  z-index: 9999;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}
/*------------------user / recepent sides on chat app----------------------*/
.chat-message {
  display: flex !important;
  margin: 0.4rem 0 !important;
  max-width: 90% !important;
}



/* Bubble box, no color change */
.chat-message .bubble {
  padding: 0.6rem 1rem !important;
  border-radius: 16px !important;
  max-width: 100% !important;
  position: relative !important;
}

/* Your message: border on the RIGHT */
.chat-message.user .bubble {
  border-right: 4px solid #0074d9 !important; /* Adjust to match your theme */
  margin-left: auto !important;
}

/* Recipient message: border on the LEFT */
.chat-message.dev .bubble {
  border-left: 4px solid #f60505 !important; /* Adjust to match your theme */
  margin-right: auto !important;
}



/*----------------------------------------press and hold sub menu-------------------------------*/

.bubble-options-menu {
  position: absolute;
  background: white;
  border: 1px solid #ccc;
  border-radius: 10px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  z-index: 9999;
  padding: 8px;
  display: flex;
  gap: 6px;
}
.bubble-options-menu button {
  background: #f5f5f5;
  border: none;
  padding: 5px 8px;
  border-radius: 6px;
  cursor: pointer;
}
.bubble-options-menu button:hover {
  background: #ddd;
}


.reaction-picker .emoji {
  font-size: 20px;
  cursor: pointer;
  transition: transform 0.2s;
}
.reaction-picker .emoji:hover {
  transform: scale(1.3);
}

.reaction-fly {
  position: absolute;
  font-size: 24px;
  transition: all 0.8s ease-out;
  pointer-events: none;
  z-index: 9999;
}

.reaction-display {
  position: absolute;
  bottom: 4px;
  font-size: 18px;
}

.reaction-display.left {
  left: 8px;
}

.reaction-fly {
  position: absolute;
  will-change: transform, opacity;
  transition: transform 1.2s ease-out, opacity 1.2s ease-out;
  user-select: none;
}

.reaction-sparkle {
  position: absolute;
  color: gold;
  opacity: 0.8;
  user-select: none;
  will-change: transform, opacity;
}


.reaction-picker {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 8px 10px;
  font-size: 1.5rem;
  background: white;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  justify-content: center;
  max-width: 260px;
}

.reaction-picker .emoji {
  cursor: pointer;
  transition: transform 0.2s ease;
}

.reaction-picker .emoji:hover {
  transform: scale(1.3);
}

.font-size-box input {
  font-size: 0.9rem;
}
.font-size-box button {
  font-size: 0.85rem;
  padding: 2px 6px;
  cursor: pointer;
}
