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

body {
  font-family:
    -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue",
    Arial, sans-serif;
  background: #f8efdf;
  min-height: 100vh;
  padding: 20px;
  color: #343130;
}

.container {
  max-width: 800px;
  margin: 0 auto;
}

header {
  text-align: center;
  margin-bottom: 40px;
}

h1 {
  color: #1f1f1f;
  font-size: 2.5rem;
  margin-bottom: 10px;
  font-weight: 700;
}

.subtitle {
  color: #74716c;
  font-size: 1.1rem;
}

.card {
  background: #fbeede;
  border-radius: 12px;
  box-shadow:
    5px 8px 24px rgba(0, 0, 0, 0.30),
    10px 16px 48px rgba(0, 0, 0, 0.24);
  padding: 30px;
  margin-bottom: 20px;
}

.form-section {
  margin-bottom: 30px;
  padding-bottom: 30px;
  border-bottom: 2px solid #e0e0e0;
}

.form-section:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.section-title {
  color: #e29327;
  font-size: 1.3rem;
  margin-bottom: 20px;
  font-weight: 600;
}

.form-group {
  margin-bottom: 20px;
}

label {
  display: block;
  margin-bottom: 8px;
  color: #343130;
  font-weight: 500;
  font-size: 0.95rem;
}

input[type="text"],
input[type="email"],
input[type="tel"] {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  font-size: 1rem;
  background-color: #ffecd1;
  transition: all 0.3s;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="tel"]:focus {
  outline: none;
  border-color: #ffaf7e;
  background-color: #ffecd1;
  box-shadow: 0 2px 8px rgba(255, 175, 126, 0.15);
}

input[type="text"]:disabled,
input[type="email"]:disabled,
input[type="tel"]:disabled {
  background-color: #ffecd1;
  cursor: not-allowed;
  opacity: 0.7;
}

input[type="text"]:-webkit-autofill,
input[type="email"]:-webkit-autofill,
input[type="tel"]:-webkit-autofill {
  -webkit-box-shadow: 0 0 0 1000px #ffecd1 inset;
  -webkit-text-fill-color: #343130;
  transition: background-color 5000s ease-in-out 0s;
}

input[type="text"]:-webkit-autofill:focus,
input[type="email"]:-webkit-autofill:focus,
input[type="tel"]:-webkit-autofill:focus {
  -webkit-box-shadow: 0 0 0 1000px #ffecd1 inset;
  -webkit-text-fill-color: #343130;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

@media (max-width: 640px) {
  .form-row {
    grid-template-columns: 1fr;
  }
}

.current-registrations {
  background: #f5e6d3;
  border: 2px solid #ffd4b8;
  border-radius: 8px;
  padding: 20px;
  margin-bottom: 25px;
}

.current-registrations h3 {
  color: #e29327;
  margin-bottom: 15px;
  font-size: 1.1rem;
}

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

.registration-table th,
.registration-table td {
  padding: 10px;
  text-align: left;
  border-bottom: 1px solid #ffd4b8;
}

.registration-table th {
  background: #f5e6d3;
  color: #e29327;
  font-weight: 600;
}

.status-badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 12px;
  font-size: 0.85rem;
  font-weight: 600;
}

.status-enrolled {
  background: #f5e6d3;
  color: #e29327;
  border: 2px solid #ffaf7e;
}

.status-waitlisted {
  background: #f5e6d3;
  color: #74716c;
  border: 2px solid #a7a098;
}

.class-option {
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  padding: 16px;
  margin-bottom: 12px;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  background-color: #ffecd1;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
}

.class-option:hover:not(.disabled) {
  border-color: #ffaf7e;
  background-color: #f5e6d3;
  box-shadow: 0 4px 12px rgba(255, 175, 126, 0.2);
  transform: translateY(-1px);
}

.class-option.disabled {
  opacity: 0.6;
  cursor: not-allowed;
  background: #f5e6d3;
}

.class-option input[type="checkbox"] {
  width: 20px;
  height: 20px;
  margin-right: 15px;
  cursor: pointer;
}

.class-option input[type="checkbox"]:disabled {
  cursor: not-allowed;
}

.class-info {
  flex: 1;
}

.class-name {
  font-weight: 600;
  color: #2d3748;
  font-size: 1.05rem;
  margin-bottom: 4px;
}

.class-description {
  color: #718096;
  font-size: 0.9rem;
  margin-bottom: 4px;
}

.class-count {
  color: #74716c;
  font-size: 0.85rem;
  font-weight: 600;
}

.class-count.full {
  color: #e53e3e;
}

.btn {
  padding: 14px 28px;
  border: none;
  border-radius: 8px;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  width: 100%;
}

.btn-primary {
  background: #ffaf7e;
  color: white;
}

.btn-primary:hover:not(:disabled) {
  background: #ff9a5e;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(255, 175, 126, 0.4);
}

.btn-primary:disabled {
  background: #ffd4b8;
  cursor: not-allowed;
}

.alert {
  padding: 16px;
  border-radius: 8px;
  margin-bottom: 20px;
}

.alert-success {
  background: #f5e6d3;
  color: #e29327;
  border: 2px solid #ffaf7e;
}

.alert-error {
  background: #ffcdd2;
  color: #c62828;
  border: 2px solid #e57373;
}

.alert-info {
  background: #949366;
  color: #ffffff;
  border: 3px solid #74716c;
  box-shadow:
    0 4px 12px rgba(148, 147, 102, 0.3),
    0 2px 6px rgba(0, 0, 0, 0.15);
}

.confirmation-card {
  background: linear-gradient(135deg, #ffaf7e, #e29327);
  color: white;
  padding: 30px;
  border-radius: 12px;
  text-align: center;
  margin-bottom: 30px;
}

.confirmation-card h2 {
  font-size: 2rem;
  margin-bottom: 15px;
}

.confirmation-list {
  background: #fbeede;
  color: #343130;
  padding: 20px;
  border-radius: 8px;
  margin-top: 20px;
}

.confirmation-list h3 {
  color: #e29327;
  margin-bottom: 15px;
}

.confirmation-list ul {
  list-style: none;
}

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

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

.footer {
  text-align: center;
  margin-top: 30px;
  color: #74716c;
  font-size: 0.9rem;
}

.loading {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  border-top-color: white;
  animation: spin 0.8s linear infinite;
  margin-left: 10px;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.admin-header {
  background: #fbeede;
  padding: 20px;
  border-radius: 12px;
  margin-bottom: 30px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow:
    5px 8px 24px rgba(0, 0, 0, 0.30),
    10px 16px 48px rgba(0, 0, 0, 0.24);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.stat-card {
  background: #fbeede;
  padding: 20px;
  border-radius: 8px;
  text-align: center;
  box-shadow:
    5px 8px 24px rgba(0, 0, 0, 0.30),
    10px 16px 48px rgba(0, 0, 0, 0.24);
}

.stat-number {
  font-size: 2rem;
  font-weight: 700;
  color: #e29327;
}

.stat-label {
  color: #74716c;
  font-size: 0.9rem;
  margin-top: 5px;
}

.admin-table {
  width: 100%;
  background: #fbeede;
  border-radius: 12px;
  overflow: hidden;
}

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

.admin-table th,
.admin-table td {
  padding: 12px;
  text-align: left;
  border-bottom: 1px solid #ffd4b8;
}

.admin-table th {
  background: #f5e6d3;
  font-weight: 600;
  color: #e29327;
}

.admin-table th.sortable:hover {
  background: #ffd4b8;
  color: #343130;
}

.sort-indicator {
  font-size: 0.8em;
  margin-left: 4px;
}

.admin-table tr:hover {
  background: #f5e6d3;
}

.btn-small {
  padding: 4px 6px;
  font-size: 0.75rem;
  margin-right: 3px;
  margin-bottom: 3px;
  display: inline-block;
  white-space: nowrap;
  width: 80px;
  text-align: center;
}

.btn-danger {
  background: #e53e3e;
  color: white;
}

.btn-danger:hover {
  background: #c53030;
}

.btn-success {
  background: #43a047;
  color: white;
}

.btn-success:hover {
  background: #2e7d32;
}

.btn-secondary {
  background: #9e9e9e;
  color: white;
}

.btn-secondary:hover {
  background: #757575;
}

.btn-warning {
  background: #ffa726;
  color: white;
}

.btn-warning:hover {
  background: #fb8c00;
}

.hidden {
  display: none;
}
