/* Reset และ Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Sarabun", sans-serif;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.blurred-box {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  border-radius: 20px;
  padding: 40px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  width: 100%;
  max-width: 600px;
}

.user-login-box {
  text-align: center;
}

.user-login-box h4,
.user-login-box h5 {
  color: white;
  margin-bottom: 15px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* แท็บ Styles - แก้ไขให้แสดงผลชัดเจน */
.certificate-type-tabs {
  margin: 30px 0;
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
}

.certificate-type-tabs .nav {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 25px;
  padding: 8px;
  backdrop-filter: blur(10px);
  display: flex !important;
  justify-content: center;
  gap: 10px;
  border: 2px solid rgba(255, 255, 255, 0.3);
}

.certificate-type-tabs .nav-item {
  list-style: none;
}

.certificate-type-tabs .nav-link {
  color: white !important;
  border: none !important;
  border-radius: 20px !important;
  padding: 15px 30px !important;
  margin: 0 !important;
  background: transparent !important;
  transition: all 0.3s ease;
  font-weight: 600 !important;
  font-size: 16px !important;
  text-decoration: none !important;
  display: block !important;
  cursor: pointer !important;
  text-align: center !important;
  min-width: 150px !important;
}

.certificate-type-tabs .nav-link:hover {
  background: rgba(255, 255, 255, 0.3) !important;
  color: white !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(255, 255, 255, 0.2);
}

.certificate-type-tabs .nav-link.active {
  background: #007bff !important;
  color: white !important;
  box-shadow: 0 4px 15px rgba(0, 123, 255, 0.4);
  font-weight: 700 !important;
}

.certificate-type-tabs .nav-link i {
  margin-right: 10px;
  font-size: 18px;
}

/* Form Sections */
.form-section {
  display: none;
  animation: fadeIn 0.5s ease-in-out;
  margin-top: 20px;
}

.form-section.active {
  display: block !important;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Form Controls */
.form-control {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 10px;
  padding: 12px 15px;
  margin: 10px 0;
  font-size: 16px;
  transition: all 0.3s ease;
  width: 100%;
}

.form-control:focus {
  background: white;
  border-color: #007bff;
  box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
  outline: none;
}

/* Labels */
label {
  color: white;
  font-weight: 500;
  margin-bottom: 5px;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  display: block;
  text-align: left;
  margin-left: 5px;
}

/* Info Boxes */
.student-info,
.teacher-info {
  background: rgba(255, 255, 255, 0.15);
  border-radius: 15px;
  padding: 25px;
  margin-top: 20px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(10px);
}

/* Debug Info */
.debug-info {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  padding: 15px;
  margin: 20px 0;
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: white;
  font-size: 14px;
}

/* Responsive */
@media (max-width: 768px) {
  .blurred-box {
    padding: 20px;
    margin: 20px;
  }

  .certificate-type-tabs .nav {
    flex-direction: column;
    gap: 10px;
  }

  .certificate-type-tabs .nav-link {
    margin: 2px 0;
    min-width: auto;
  }
}

/* Loading States */
.loading {
  opacity: 0.6;
  pointer-events: none;
}

/* Success/Error Messages */
.alert {
  border-radius: 10px;
  margin: 15px 0;
  padding: 15px;
}

.alert-success {
  background: rgba(40, 167, 69, 0.2);
  border: 1px solid rgba(40, 167, 69, 0.3);
  color: #d4edda;
}

.alert-danger {
  background: rgba(220, 53, 69, 0.2);
  border: 1px solid rgba(220, 53, 69, 0.3);
  color: #f8d7da;
}
