:root {
  --primary-color: #4F46E5;
  --primary-hover: #4338CA;
  --bg-color: #0F172A;
  --panel-bg: rgba(30, 41, 59, 0.7);
  --text-primary: #F8FAFC;
  --text-secondary: #94A3B8;
  --border-color: rgba(255, 255, 255, 0.1);
  --danger-color: #EF4444;
  --danger-hover: #DC2626;
}

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

body {
  font-family: 'Inter', sans-serif;
  background-color: var(--bg-color);
  color: var(--text-primary);
  min-height: 100vh;
  background-image: radial-gradient(circle at top right, #1E1B4B, transparent 40%),
                    radial-gradient(circle at bottom left, #064E3B, transparent 40%);
  background-attachment: fixed;
}

.container {
  max-width: 1000px;
  margin: 0 auto;
  padding: 2rem;
}

header {
  text-align: center;
  margin-bottom: 3rem;
}

h1 {
  font-size: 2.5rem;
  font-weight: 700;
  background: linear-gradient(to right, #60A5FA, #A78BFA);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 0.5rem;
}

.subtitle {
  color: var(--text-secondary);
  font-size: 1.1rem;
}

.glass-panel {
  background: var(--panel-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 2rem;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}

.add-sale-section {
  margin-bottom: 2rem;
}

.add-sale-section h2, .sales-list-section h2 {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  color: #E2E8F0;
}

#sale-form {
  display: grid;
  grid-template-columns: 1fr 1fr 2fr auto;
  gap: 1rem;
  align-items: end;
}

.form-group {
  display: flex;
  flex-direction: column;
}

label {
  font-size: 0.875rem;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
}

input, select {
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  padding: 0.75rem 1rem;
  border-radius: 8px;
  font-family: inherit;
  font-size: 1rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}

input:focus, select:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 2px rgba(79, 70, 229, 0.2);
}

.primary-btn {
  background-color: var(--primary-color);
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: background-color 0.2s, transform 0.1s;
  height: 45px;
}

.primary-btn:hover {
  background-color: var(--primary-hover);
  transform: translateY(-1px);
}

.primary-btn:active {
  transform: translateY(0);
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
}

.total-sales {
  font-size: 1.25rem;
  font-weight: 600;
  color: #10B981;
  background: rgba(16, 185, 129, 0.1);
  padding: 0.5rem 1rem;
  border-radius: 20px;
  border: 1px solid rgba(16, 185, 129, 0.2);
}

.table-container {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th {
  text-align: left;
  padding: 1rem;
  color: var(--text-secondary);
  font-weight: 500;
  border-bottom: 1px solid var(--border-color);
}

td {
  padding: 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

tr:hover td {
  background: rgba(255, 255, 255, 0.02);
}

.type-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 12px;
  font-size: 0.85rem;
  font-weight: 500;
}

.type-gallery {
  background: rgba(167, 139, 250, 0.15);
  color: #C4B5FD;
  border: 1px solid rgba(167, 139, 250, 0.3);
}

.type-xerox {
  background: rgba(96, 165, 250, 0.15);
  color: #93C5FD;
  border: 1px solid rgba(96, 165, 250, 0.3);
}

.amount-col {
  font-family: monospace;
  font-size: 1.1rem;
  font-weight: 600;
}

.delete-btn {
  background: transparent;
  color: var(--danger-color);
  border: 1px solid var(--danger-color);
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s;
  font-size: 0.875rem;
}

.delete-btn:hover {
  background: var(--danger-color);
  color: white;
}

@media (max-width: 768px) {
  #sale-form {
    grid-template-columns: 1fr;
  }
}
