body {
  font-family: 'Inter', sans-serif;
  background: #f9fafb;
  color: #111827;
  margin: 0;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

header {
  text-align: center;
  padding: 2rem 1rem;
  background: white;
  border-bottom: 1px solid #e5e7eb;
}
header h1 {
  font-size: 2rem;
  font-weight: 600;
  color: #4f46e5;
}
header p {
  color: #6b7280;
  margin-top: 0.5rem;
}

main {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 2rem;
}

.card {
  background: white;
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.05);
  width: 100%;
  max-width: 600px;
}

.step { margin-bottom: 1.5rem; }
.step h2 { color: #374151; font-size: 1.2rem; margin-bottom: 0.5rem; }

label { font-weight: 600; display: block; margin-bottom: 0.5rem; }

input[type="text"], input[type="number"] {
  width: 100%;
  padding: 0.7rem;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  font-size: 0.95rem;
  transition: border 0.2s;
}
input:focus { border-color: #4f46e5; outline: none; }

.field {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}
.field input[type="text"] { flex: 2; }
.field input[type="number"] { width: 80px; }

button {
  border: none;
  border-radius: 8px;
  padding: 0.7rem 1.2rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s, transform 0.2s;
}
button:hover { transform: translateY(-2px); }

.add-btn {
  background: #eef2ff;
  color: #4338ca;
}
.calc-btn {
  background: #4f46e5;
  color: white;
}
.reset-btn {
  background: #ef4444;
  color: white;
}
.actions { display: flex; gap: 1rem; }

#result {
  margin-top: 1.5rem;
  padding: 1rem;
  border-radius: 8px;
  font-size: 1.1rem;
  text-align: center;
  display: none;
}
.result-yes { background: #dcfce7; color: #166534; }
.result-no { background: #fee2e2; color: #991b1b; }
.result-balanced { background: #fef9c3; color: #854d0e; }

footer {
  text-align: center;
  padding: 1rem;
  font-size: 0.9rem;
  color: #6b7280;
  border-top: 1px solid #e5e7eb;
}

/* Popup */
.popup {
  position: fixed; top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0,0,0,0.5);
  display: flex; justify-content: center; align-items: center;
  z-index: 1000;
}
.popup-content {
  background: white;
  padding: 2rem;
  border-radius: 12px;
  max-width: 400px;
  text-align: center;
  box-shadow: 0 6px 20px rgba(0,0,0,0.2);
}
.popup-content h2 { margin-bottom: 1rem; }
.popup-content button {
  margin-top: 1rem;
  background: #4f46e5;
  color: white;
}