/* Common page layout styles */
.payment-page,
.expense-page {
  max-width: 1200px;
  margin: 0 auto;
  padding: 24px;
  background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
  min-height: calc(100vh - 100px);
}

/* Common header styles */
.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  padding: 0 4px;
}

.header .left h2 {
  margin: 0;
  font-size: 28px;
  font-weight: 700;
  color: #1e293b;
  letter-spacing: -0.5px;
}

.header .right {
  display: flex;
  gap: 12px;
  align-items: center;
}

/* Common control styles */
.page-size {
  padding: 10px 14px;
  border: 2px solid #e2e8f0;
  border-radius: 12px;
  background: #fff;
  font-size: 14px;
  font-weight: 500;
  color: #475569;
  cursor: pointer;
  transition: all 0.2s ease;
}

.page-size:hover {
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.page-size:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* Common button styles */
.new-btn {
  background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
  color: #fff;
  border: none;
  padding: 12px 20px;
  border-radius: 12px;
  cursor: pointer;
  font-weight: 600;
  font-size: 14px;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
  transition: all 0.2s ease;
}

.new-btn:hover {
  box-shadow: 0 6px 20px rgba(59, 130, 246, 0.4);
}

.new-btn:active {
  transform: translateY(0);
}

/* Export dropdown styling */
.export-dropdown {
  padding: 10px 14px;
  border: 2px solid #e2e8f0;
  border-radius: 12px;
  background: #fff;
  font-size: 14px;
  font-weight: 500;
  color: #475569;
  cursor: pointer;
  transition: all 0.2s ease;
  min-width: 120px;
}

.export-dropdown:hover {
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.export-value {
  display: flex;
  align-items: center;
}

.export-option {
  display: flex;
  align-items: center;
  padding: 8px 0;
}

/* Search section styling */
.search-section {
  margin-bottom: 20px;
}

.search-row {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.search-item {
  flex: 1;
  min-width: 200px;
}

.search-input {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid #e2e8f0;
  border-radius: 12px;
  background: #fff;
  font-size: 14px;
  color: #374151;
  transition: all 0.2s ease;
}

.search-input:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.search-input::placeholder {
  color: #9ca3af;
}

/* Common table wrapper */
.table-wrap {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 24px rgba(51, 65, 85, 0.08);
}

/* Common table styles */
.payment-table,
.expense-table {
  width: 100%;
  border-collapse: collapse;
}

.payment-table thead,
.expense-table thead {
  background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
}

.payment-table th,
.expense-table th {
  padding: 16px 20px;
  text-align: left;
  color: #374151;
  font-weight: 600;
  font-size: 14px;
  border-bottom: 2px solid #e5e7eb;
  letter-spacing: 0.5px;
}

.payment-table td,
.expense-table td {
  padding: 16px 20px;
  border-bottom: 1px solid #f3f4f6;
  font-size: 14px;
  color: #4b5563;
  transition: all 0.2s ease;
}

.payment-table tbody tr,
.expense-table tbody tr {
  transition: all 0.2s ease;
}

.payment-table tbody tr:hover,
.expense-table tbody tr:hover {
  background: linear-gradient(135deg, #fafbff 0%, #f0f4ff 100%);
}

.payment-table tbody tr:last-child td,
.expense-table tbody tr:last-child td {
  border-bottom: none;
}

/* Common pagination styles */
.pagination {
  display: flex;
  gap: 12px;
  justify-content: center;
  align-items: center;
  padding: 24px 0;
}

.pagination button {
  border: 2px solid #e5e7eb;
  background: #fff;
  border-radius: 10px;
  padding: 8px 14px;
  cursor: pointer;
  font-weight: 500;
  color: #374151;
  transition: all 0.2s ease;
}

.pagination button:hover:not(:disabled) {
  border-color: #3b82f6;
  background: #3b82f6;
  color: #fff;
}

.pagination button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.pagination span {
  font-weight: 600;
  color: #4b5563;
  padding: 0 8px;
}

/* Loading container */
.loading-container {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 64px;
  color: #6b7280;
}

/* Action Buttons */
.action-buttons {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: center;
}

.action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: 2px solid;
  border-radius: 8px;
  background: #fff;
  cursor: pointer;
  font-size: 14px;
  transition: all 0.2s ease;
  padding: 0;
}

.delete-btn {
  border-color: #ef4444;
  color: #ef4444;
}

.delete-btn:hover:not(:disabled) {
  background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
  color: #fff;
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

.delete-btn:disabled {
  border-color: #d1d5db;
  color: #9ca3af;
  cursor: not-allowed;
  opacity: 0.5;
}

/* Common dialog styles */
.payment-dialog .p-dialog-header,
.expense-dialog .p-dialog-header {
  background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
  border-bottom: 1px solid #e2e8f0;
}

.payment-dialog .p-dialog-content,
.expense-dialog .p-dialog-content {
  padding: 24px;
}

.payment-dialog .p-dialog-footer,
.expense-dialog .p-dialog-footer {
  background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
  border-top: 1px solid #e2e8f0;
  padding: 16px 24px;
  gap: 12px;
}

.dialog-title {
  font-size: 20px;
  font-weight: 700;
  color: #1e293b;
}

.dialog-body {
  display: grid;
  gap: 20px;
  padding: 4px 0;
}

.form-row {
  display: grid;
  gap: 8px;
}

.form-row label {
  font-size: 14px;
  font-weight: 600;
  color: #374151;
}

.full {
  width: 100%;
}

/* Text center styling for empty states */
.text-center {
  text-align: center;
  color: #9ca3af;
  font-style: italic;
}

/* Common input styling */
.payment-dialog input[type="number"],
.payment-dialog input[type="text"],
.payment-dialog textarea,
.expense-dialog input[type="number"],
.expense-dialog input[type="text"],
.expense-dialog textarea {
  border: 2px solid #e2e8f0;
  border-radius: 8px;
  padding: 10px 14px;
  transition: all 0.2s ease;
  font-size: 14px;
  color: #374151;
}

.payment-dialog input[type="number"]:focus,
.payment-dialog input[type="text"]:focus,
.payment-dialog textarea:focus,
.expense-dialog input[type="number"]:focus,
.expense-dialog input[type="text"]:focus,
.expense-dialog textarea:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* Common button enhancements */
.payment-dialog .p-button,
.expense-dialog .p-button {
  border-radius: 8px;
  font-weight: 600;
  padding: 10px 20px;
  transition: all 0.2s ease;
}

.payment-dialog .p-button:not(.p-button-text),
.expense-dialog .p-button:not(.p-button-text) {
  background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
  border: none;
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.2);
}

.payment-dialog .p-button:not(.p-button-text):hover,
.expense-dialog .p-button:not(.p-button-text):hover {
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.payment-dialog .p-button.p-button-text,
.expense-dialog .p-button.p-button-text {
  color: #6b7280;
  border: 2px solid #e2e8f0;
  background: #fff;
}

.payment-dialog .p-button.p-button-text:hover,
.expense-dialog .p-button.p-button-text:hover {
  background: #f8fafc;
  border-color: #d1d5db;
}

/* Global PrimeVue Button Override - Remove all transform effects */
.p-button {
  transform: none !important;
}

.p-button:hover {
  transform: none !important;
}

.p-button:focus {
  transform: none !important;
}

.p-button:active {
  transform: none !important;
}

.p-button:not(.p-disabled):hover {
  transform: none !important;
}

/* Additional overrides for PrimeVue component variations */
.p-button-primary,
.p-button-secondary,
.p-button-success,
.p-button-info,
.p-button-warning,
.p-button-danger,
.p-button-help,
.p-button-text,
.p-button-outlined {
  transform: none !important;
}

.p-button-primary:hover,
.p-button-secondary:hover,
.p-button-success:hover,
.p-button-info:hover,
.p-button-warning:hover,
.p-button-danger:hover,
.p-button-help:hover,
.p-button-text:hover,
.p-button-outlined:hover {
  transform: none !important;
}

/* Ensure no transform effects on any interactive elements */
* {
  -webkit-transform: none !important;
  -moz-transform: none !important;
  -ms-transform: none !important;
  -o-transform: none !important;
}

*:hover,
*:focus,
*:active {
  -webkit-transform: none !important;
  -moz-transform: none !important;
  -ms-transform: none !important;
  -o-transform: none !important;
}

/* PrimeVue dropdown overrides */
.p-dropdown {
  border: 2px solid #e2e8f0 !important;
  border-radius: 12px !important;
}

.p-dropdown:hover {
  border-color: #3b82f6 !important;
}

.p-dropdown:focus-within {
  border-color: #3b82f6 !important;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1) !important;
}
