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

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: linear-gradient(135deg, #667eea, #764ba2);
  min-height: 100vh;
  color: #333;
}

.navbar {
  background: #2a2a3a;
  color: #fff;
  padding: 14px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.navbar .brand {
  font-size: 1.2rem;
  font-weight: 600;
}

.nav-links a {
  color: #ccc;
  text-decoration: none;
  margin-left: 18px;
  padding: 6px 10px;
  border-radius: 6px;
  transition: background 0.2s, color 0.2s;
}

.nav-links a:hover {
  color: #fff;
}

.nav-links a.active {
  background: #667eea;
  color: #fff;
}

.container {
  max-width: 720px;
  margin: 32px auto;
  padding: 0 16px;
}

header {
  color: #fff;
  margin-bottom: 24px;
}

header h1 {
  font-size: 1.9rem;
  margin-bottom: 6px;
}

header p {
  opacity: 0.9;
}

.card {
  background: #fff;
  border-radius: 12px;
  padding: 24px;
  margin-bottom: 20px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.card h2 {
  margin-bottom: 16px;
  font-size: 1.2rem;
  color: #2a2a3a;
}

label {
  display: block;
  margin-bottom: 6px;
  font-weight: 500;
}

input[type="text"],
input[type="password"] {
  width: 100%;
  padding: 12px;
  margin-bottom: 14px;
  border: 1px solid #ccc;
  border-radius: 8px;
  font-size: 1rem;
}

button {
  cursor: pointer;
}

.btn {
  padding: 12px 20px;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  transition: transform 0.1s, opacity 0.2s;
}

.btn:active {
  transform: scale(0.98);
}

.btn.primary {
  background: #667eea;
  color: #fff;
}

.btn.primary:hover {
  opacity: 0.9;
}

.btn.secondary {
  background: #e4e4ef;
  color: #333;
}

.btn.secondary:hover {
  background: #d4d4e3;
}

.btn.danger {
  background: #e74c3c;
  color: #fff;
  padding: 6px 12px;
  font-size: 0.85rem;
}

.btn.danger:hover {
  opacity: 0.9;
}

.btn.float-right {
  float: right;
  background: #e4e4ef;
  color: #333;
}

.hidden {
  display: none !important;
}

.options-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.option-card {
  border: 2px solid #e0e0ea;
  border-radius: 10px;
  padding: 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: border-color 0.2s;
}

.option-card:hover {
  border-color: #667eea;
}

.option-text {
  font-size: 1.05rem;
  font-weight: 500;
}

.option-card .btn.vote {
  background: #667eea;
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 10px 18px;
  font-weight: 600;
}

.option-card .btn.vote:hover {
  opacity: 0.9;
}

.result-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 0;
  border-bottom: 1px solid #eee;
}

.result-row:last-child {
  border-bottom: none;
}

.result-info {
  flex: 1;
}

.result-name {
  font-weight: 500;
}

.result-count {
  font-weight: 700;
  color: #667eea;
  margin-left: 12px;
}

.result-bar {
  height: 10px;
  background: #eee;
  border-radius: 6px;
  margin-top: 8px;
  overflow: hidden;
}

.result-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #667eea, #764ba2);
  border-radius: 6px;
  transition: width 0.4s ease;
  width: 0;
}

.muted {
  color: #777;
}

.error {
  color: #e74c3c;
  margin-top: 10px;
  font-weight: 500;
}

.success {
  color: #27ae60;
  margin-top: 10px;
  font-weight: 500;
}

.admin-options-list {
  list-style: none;
}

.admin-options-list li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid #eee;
}

.admin-options-list li:last-child {
  border-bottom: none;
}

.card h3 {
  margin-bottom: 12px;
  font-size: 1rem;
  color: #555;
}

.voter-detail-list {
  list-style: none;
  margin-top: 10px;
}

.voter-detail-list li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid #eee;
}

.voter-detail-list li:last-child {
  border-bottom: none;
}

.voter-detail-name {
  font-weight: 500;
}

.voter-detail-option {
  color: #667eea;
  font-weight: 600;
  max-width: 55%;
  text-align: right;
}

.btn.danger-zone-btn {
  background: #e74c3c;
  color: #fff;
  width: 100%;
  padding: 14px;
  font-size: 1rem;
  border: none;
  border-radius: 8px;
  font-weight: 600;
}

.btn.danger-zone-btn:hover {
  opacity: 0.9;
}

.danger-zone {
  border: 2px solid #e74c3c;
}

.danger-zone h2 {
  color: #e74c3c;
}

@media (max-width: 480px) {
  .navbar {
    flex-direction: column;
    gap: 8px;
  }

  .nav-links a {
    margin: 0 6px;
  }

  .option-card {
    flex-direction: column;
    gap: 12px;
    align-items: stretch;
  }
}
