/* form_create.css - Final Version */
:root {
  /* Color Scheme */
  --primary: #4361ee;
  --primary-dark: #3a0ca3;
  --primary-light: #4895ef;
  --secondary: #f72585;
  --accent: #4cc9f0;
  --dark: #121212;
  --darker: #0d0d0d;
  --darkest: #080808;
  --light: #f8f9fa;
  --success: #4bb543;
  --error: #ff3333;
  --warning: #ffcc00;
  
  /* UI Elements */
  --glass: rgba(30, 30, 40, 0.85);
  --glass-border: rgba(255, 255, 255, 0.1);
  --glass-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  --text-primary: rgba(255, 255, 255, 0.95);
  --text-secondary: rgba(255, 255, 255, 0.7);
  --question-card: rgba(40, 40, 60, 0.8);
  --question-card-hover: rgba(50, 50, 80, 0.9);
  --select-bg: rgba(25, 25, 40, 0.95);
}

/* Base Styles */
body {
  background: linear-gradient(135deg, var(--dark), var(--darker));
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  min-height: 100vh;
  color: var(--text-primary);
  line-height: 1.6;
  margin: 0;
  padding: 0;
  background-attachment: fixed;
}

/* Main Container */
.container {
  max-width: 900px;
  padding: 2rem;
  margin: 0 auto;
}

/* Typography */
h2 {
  font-size: 2rem;
  margin-bottom: 2rem;
  position: relative;
  color: white;
}

h2::after {
  content: "";
  position: absolute;
  bottom: -10px;
  left: 0;
  width: 60px;
  height: 3px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
}

/* Form Styling */
form {
  background: var(--glass);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 12px;
  padding: 2rem;
  border: 1px solid var(--glass-border);
  box-shadow: var(--glass-shadow);
  margin-bottom: 2rem;
}

.form-group {
  margin-bottom: 1.5rem;
}

label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: var(--accent);
}

/* Input Fields */
.form-control {
  background: var(--select-bg);
  border: 1px solid var(--glass-border);
  border-radius: 6px;
  padding: 0.75rem 1rem;
  color: white;
  width: 100%;
  transition: all 0.3s ease;
}

.form-control:focus {
  outline: none;
  border-color: var(--primary-light);
  box-shadow: 0 0 0 3px rgba(67, 97, 238, 0.25);
}

/* Select Dropdowns */
select.form-control {
  appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='white'%3e%3cpath d='M7 10l5 5 5-5z'/%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  background-size: 12px;
  padding-right: 2.5rem;
}

select.form-control option {
  background: var(--darker);
  color: white;
}

/* Question Cards */
#questions-container {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 1rem;
}

.question-card {
  background: var(--question-card);
  border-radius: 8px;
  padding: 1.25rem;
  border: 1px solid var(--glass-border);
  transition: all 0.3s ease;
}

.question-card:hover {
  background: var(--question-card-hover);
  transform: translateY(-2px);
}

.question-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.question-number {
  font-weight: 600;
  color: var(--primary-light);
}

.remove-question {
  background: none;
  border: none;
  color: var(--error);
  cursor: pointer;
  font-size: 1.25rem;
  line-height: 1;
}

/* Question Type Select */
.question-type-select {
  margin-top: 0.5rem;
  width: 100%;
}

/* Options Container */
.options-container {
  margin-top: 1rem;
  display: none;
  background: var(--darkest);
  padding: 1rem;
  border-radius: 6px;
}

.options-container.active {
  display: block;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.options-label {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
}

/* Buttons */
.btn {
  border: none;
  border-radius: 6px;
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-primary {
  background: linear-gradient(to right, var(--primary), var(--primary-dark));
  color: white;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(67, 97, 238, 0.3);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.1);
  color: white;
  border: 1px solid var(--glass-border);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.2);
}

#add-question-btn {
  margin-top: 0.5rem;
  background: rgba(76, 201, 240, 0.1);
  border: 1px solid var(--accent);
  color: var(--accent);
}

/* Alerts */
.alert {
  padding: 1rem;
  border-radius: 6px;
  margin-bottom: 1.5rem;
  border-left: 4px solid transparent;
}

.alert-success {
  background: rgba(75, 181, 67, 0.1);
  border-left-color: var(--success);
}

.alert-danger {
  background: rgba(255, 51, 51, 0.1);
  border-left-color: var(--error);
}

/* Date Input */
input[type="date"] {
  position: relative;
}

input[type="date"]::-webkit-calendar-picker-indicator {
  filter: invert(1);
  opacity: 0.7;
  cursor: pointer;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
  .container {
    padding: 1.5rem;
  }
  
  form {
    padding: 1.5rem;
  }
}