/* Base layout */
body {
  margin: 0;
  font-family: 'Inter', sans-serif;
  background: linear-gradient(135deg, #0a0a2a, #1a0033);
  color: #e0e0e0;
  overflow: hidden;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Background animated mesh */
.bg {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 20% 20%, #4a00e0, transparent 50%),
              radial-gradient(circle at 80% 80%, #00c6ff, transparent 50%);
  background-size: 200% 200%;
  animation: bgMove 15s linear infinite;
  filter: blur(80px) contrast(150%);
  opacity: 0.6;
}
@keyframes bgMove {
  0% { background-position: 0% 0%; }
  50% { background-position: 100% 100%; }
  100% { background-position: 0% 0%; }
}

/* Glassmorphism card */
.card {
  position: relative;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  backdrop-filter: blur(12px) saturate(180%);
  border: 1px solid rgba(255,255,255,0.2);
  padding: 2rem 1.5rem;
  max-width: 460px;
  width: 90%;
  box-shadow: 0 8px 32px rgba(0,0,0,0.2);
  transform-style: preserve-3d;
  transition: transform 0.3s ease;
  opacity: 0;
  transform: scale(0.9);
}
.card.fade-in { opacity: 1; transform: scale(1); }

/* Card hover tilt */
.card:hover {
  transform: perspective(800px) rotateX(3deg) rotateY(3deg);
}

h1 {
  font-size: 2rem;
  text-align: center;
  margin-bottom: 1rem;
  background: linear-gradient(45deg, #00c6ff, #4a00e0);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  font-weight: 700;
}

/* Progress bar */
.progress {
  width: 100%;
  height: 6px;
  background: rgba(255,255,255,0.1);
  border-radius: 3px;
  margin-bottom: 1.5rem;
  overflow: hidden;
}
.progress-bar {
  height: 100%;
  width: 33%;
  background: linear-gradient(90deg, #00c6ff, #4a00e0);
  transition: width 0.4s ease;
}

/* Form fields with floating labels */
.field {
  position: relative;
  margin-top: 1rem;
}
.field input,
.field select {
  width: 100%;
  padding: 1rem 0.5rem 0.25rem;
  background: transparent;
  border: none;
  border-bottom: 2px solid rgba(255,255,255,0.3);
  color: #e0e0e0;
  font-size: 1rem;
  outline: none;
  transition: border-color 0.3s;
}
.field input:focus,
.field select:focus {
  border-bottom-color: #00c6ff;
}
.field label {
  position: absolute;
  left: 0.5rem;
  top: 1rem;
  color: rgba(255,255,255,0.6);
  font-size: 1rem;
  pointer-events: none;
  transition: all 0.3s;
}
.field input:focus + label,
.field input:not(:placeholder-shown) + label,
.field select:focus + label,
.field select:not(:invalid) + label {
  top: -0.5rem;
  font-size: 0.85rem;
  color: #00c6ff;
}

/* Buttons */
.glow-btn {
  position: relative;
  display: inline-block;
  padding: 0.75rem 1.5rem;
  margin-top: 1rem;
  background: transparent;
  color: #e0e0e0;
  border: 2px solid #00c6ff;
  border-radius: 6px;
  cursor: pointer;
  overflow: hidden;
  transition: color 0.3s;
}
.glow-btn::before {
  content: '';
  position: absolute;
  inset: -2px;
  background: linear-gradient(45deg, #00c6ff, #4a00e0, #00c6ff);
  z-index: -1;
  filter: blur(8px);
  opacity: 0.7;
  animation: glow 2s linear infinite;
}
@keyframes glow {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}
.glow-btn:hover {
  color: #fff;
}

/* Result pop‑up */
#result {
  margin-top: 1rem;
  font-weight: bold;
  text-align: center;
  opacity: 0;
  transform: scale(0.8);
}
#result.pop-up {
  animation: popScale 0.4s forwards;
}
@keyframes popScale {
  to { opacity: 1; transform: scale(1); }
}

/* Appointments table */
#appointmentsContainer {
  margin-top: 2rem;
  background: rgba(255,255,255,0.05);
  border-radius: 8px;
  padding: 1rem;
}
#appointmentsTable {
  width: 100%;
  border-collapse: collapse;
  color: #e0e0e0;
}
#appointmentsTable th,
#appointmentsTable td {
  padding: 0.5rem;
  border: 1px solid rgba(255,255,255,0.1);
  text-align: left;
  font-size: 0.85rem;
}
#appointmentsTable th {
  background: rgba(255,255,255,0.1);
}

/* Global smooth transitions */
* {
  box-sizing: border-box;
  transition: all 0.2s ease;
}

@media (max-width: 480px) {
  .card { padding: 1.5rem 1rem; }
  h1 { font-size: 1.5rem; }
}
