.card-box {
    background: #fff;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    margin-bottom: 2rem;
  }
  .situation-nav {
    padding: 0.25rem 0.6rem;
    font-size: 0.8rem;
    background: #f1f5f9;
    color: #1e293b;
    border-radius: 50px;
    border: none;
    cursor: pointer;
    transition: background 0.3s, transform 0.2s;
  }
  .situation-nav:hover {
    background: #e2e8f0;
    transform: translateY(-1px);
  }
body {
  font-family: 'Titillium Web', sans-serif;
  background: linear-gradient(to bottom right, #f0f4ff, #ffffff);
  margin: 0;
  padding: 2rem;
  color: #111;
}

h1 {
  font-family: 'Anton', sans-serif;
}

.container {
  max-width: 800px;
  margin: auto;
  background: white;
  padding: 2.5rem;
  border-radius: 16px;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.05);
  backdrop-filter: blur(5px);
  border: 1px solid rgba(255, 255, 255, 0.3);
}

h2, h3 {
  color: #1e3a8a;
  margin-top: 0;
}

.field {
  margin-bottom: 1.5rem;
}

label {
  font-weight: 600;
  display: block;
  margin-bottom: .5rem;
  color: #1e293b;
}

input, textarea, select {
  width: 100%;
  padding: .75rem;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-size: 1rem;
  background-color: #f8fafc;
  transition: border-color 0.3s;
  box-sizing: border-box;
}

input:focus, textarea:focus, select:focus {
  border-color: #2563eb;
  outline: none;
  background-color: #fff;
}

textarea {
  resize: vertical;
  font-family: inherit;
}

.btn {
  padding: 0.45rem 1.2rem;
  background: linear-gradient(135deg, #3b82f6, #2563eb);
  color: #ffffff;
  font-weight: 600;
  border: none;
  border-radius: 50px;
  cursor: pointer;
  font-size: 0.95rem;
  letter-spacing: 0.3px;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.btn:hover {
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(37, 99, 235, 0.4);
}

.btn:active {
  transform: translateY(0);
  box-shadow: 0 3px 8px rgba(37, 99, 235, 0.3);
}

.badge {
  font-weight: 500;
  padding: .4rem .8rem;
  border-radius: 999px;
  background: #e0e7ff;
  color: #3730a3;
  display: inline-block;
  margin-bottom: 1rem;
  font-size: 0.875rem;
}

.bar {
  height: 14px;
  background: #e5e7eb;
  border-radius: 999px;
  overflow: hidden;
}

.bar span {
  display: block;
  height: 100%;
  background: linear-gradient(to right, #4f46e5, #6366f1);
  transition: width 0.5s ease;
}

.val {
  font-weight: 500;
  font-size: 14px;
  margin-top: .3rem;
  color: #334155;
}

.error {
  color: #b91c1c;
  font-weight: 600;
  background: #fee2e2;
  padding: .75rem;
  border-radius: 6px;
  margin: 1rem 0;
  border-left: 4px solid #dc2626;
}

.success {
  color: #065f46;
  font-weight: 600;
  background: #d1fae5;
  padding: .75rem;
  border-radius: 6px;
  margin: 1rem 0;
  border-left: 4px solid #059669;
}

hr {
  border: none;
  border-top: 2px solid #e5e7eb;
  margin: 2rem 0;
}

details {
  margin-top: 1rem;
  padding: 0.5rem;
  background: #f8fafc;
  border-radius: 6px;
}

summary {
  cursor: pointer;
  color: #2563eb;
  font-weight: 500;
  padding: 0.5rem;
  user-select: none;
}

summary:hover {
  color: #1d4ed8;
}

pre {
  white-space: pre-wrap;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  padding: 1rem;
  border-radius: 6px;
  font-size: 13px;
  overflow-x: auto;
  max-height: 400px;
  overflow-y: auto;
}

.char-counter {
  margin-top: 6px;
  font-size: 13px;
  color: #64748b;
}

.char-counter.warning {
  color: #dc2626;
  font-weight: 600;
}

.evaluation-overlay {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(15, 23, 42, 0.35);
  backdrop-filter: blur(6px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
  z-index: 9999;
}

.evaluation-overlay.visible {
  opacity: 1;
  pointer-events: auto;
}

.evaluation-dialog {
  background: #ffffff;
  padding: 1.75rem 2.25rem;
  border-radius: 18px;
  box-shadow: 0 20px 45px rgba(15, 23, 42, 0.2);
  text-align: center;
  animation: float 1.8s ease-in-out infinite alternate;
}

.evaluation-spinner {
  width: 56px;
  height: 56px;
  margin: 0 auto 1rem auto;
  border-radius: 50%;
  border: 5px solid rgba(37, 99, 235, 0.15);
  border-top-color: #2563eb;
  animation: spin 0.9s linear infinite;
}

.evaluation-title {
  margin: 0;
  font-size: 1.2rem;
  font-weight: 700;
  color: #1e3a8a;
  letter-spacing: 0.5px;
}

.evaluation-subtitle {
  margin: 0.35rem 0 0;
  font-size: 0.95rem;
  color: #475569;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  animation: pulse 1.2s ease-in-out infinite;
}

.situation-box {
  background: #f8fafc;
  padding: 1rem;
  border-radius: 8px;
  border-left: 4px solid #3b82f6;
  margin-bottom: 1.5rem;
  white-space: pre-line;
}


.progress-indicator {
  text-align: center;
  color: #64748b;
  font-size: 0.875rem;
  margin-bottom: 1rem;
}

a.more-link {
  color: #475569;
  font-weight: 600;
  text-decoration: none;
  transition: color 0.3s;
}

a.more-link:hover {
  color: #1e3a8a;
  text-decoration: underline;
}

@media (max-width: 768px) {
  body {
    padding: 1rem;
  }
  
  .container {
    padding: 1.5rem;
  }
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

@keyframes pulse {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 1; }
}

@keyframes float {
  0% { transform: translateY(0px); }
  100% { transform: translateY(-6px); }
}


/* Summary section styles */
.summary {
  margin-top: 2rem;
}

.summary-bars .field {
  margin-bottom: 0.8rem;
}

.table-wrapper {
  overflow-x: auto;
  margin-top: 1rem;
}

.summary-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  background: white;
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.summary-table th {
  background: #f1f5f9;
  color: #334155;
  padding: 10px;
  text-align: left;
}

.summary-table td {
  border-top: 1px solid #e2e8f0;
  padding: 8px 10px;
  vertical-align: top;
}

.answer-cell, .explanation-cell {
  max-height: 100px;
  overflow-y: auto;
  padding: 4px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 4px;
}
