:root {
  --bg-primary: #0a0e23;
  --bg-secondary: #141a31;
  --accent: #7b68ee;
  --accent-color: #7b68ee; /* Added for consistency */
  --accent-hover: #9378ff;
  --text-primary: #ffffff;
  --text-secondary: #b8c2e0;
  --card-bg: #1a2038;
  --success: #4ade80;
  --error: #f87171;
  --warning: #fbbf24;
  --border-radius: 12px;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --border-color: rgba(123, 104, 238, 0.2); /* Added for consistency */
}

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

body {
  font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
  background: linear-gradient(135deg, var(--bg-primary) 0%, #1a1a2e 100%);
  margin: 0;
  min-height: 100vh;
  color: var(--text-primary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 
    radial-gradient(circle at 10% 20%, rgba(123, 104, 238, 0.15) 0%, transparent 20%),
    radial-gradient(circle at 90% 80%, rgba(123, 104, 238, 0.15) 0%, transparent 20%),
    radial-gradient(circle at 50% 50%, rgba(0, 0, 0, 0) 0%, var(--bg-primary) 100%);
  pointer-events: none;
  z-index: -1;
}

#app {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  position: relative;
  z-index: 1;
}

.quiz-card {
  background: rgba(26, 32, 56, 0.6);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(123, 104, 238, 0.1);
  border-radius: var(--border-radius);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  padding: 2.5rem 2rem;
  max-width: 500px;
  width: 90%;
  max-width: 500px;
  margin: 2rem auto;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
  animation: cardEntrance 0.6s ease-out forwards;
}

@keyframes cardEntrance {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.quiz-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--accent), #9378ff);
  transition: var(--transition);
}

.quiz-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3);
  border-color: rgba(123, 104, 238, 0.3);
}

.quiz-card:active {
  transform: translateY(-2px);
}

.logo {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 2rem;
  text-align: center;
}

.logo img {
  width: 80px;
  height: auto;
  margin-bottom: 1rem;
  filter: drop-shadow(0 0 10px rgba(123, 104, 238, 0.5));
  transition: var(--transition);
}

.logo h1 {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0.5rem 0 0;
  background: linear-gradient(90deg, #fff, #b8c2e0);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  letter-spacing: 0.5px;
}

.input-group {
  margin-bottom: 1.5rem;
}

.input-label {
  font-size: 0.95rem;
  font-weight: 500;
  margin-bottom: 0.5rem;
  display: block;
  color: var(--text-secondary);
  transition: var(--transition);
}

input[type="text"] {
  width: 100%;
  padding: 0.9rem 1.2rem;
  border: 2px solid rgba(123, 104, 238, 0.1);
  border-radius: var(--border-radius);
  font-size: 1rem;
  font-family: 'Poppins', sans-serif;
  outline: none;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  background: rgba(26, 32, 56, 0.6);
  color: var(--text-primary);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

input[type="text"]:hover {
  border-color: rgba(123, 104, 238, 0.3);
  background: rgba(26, 32, 56, 0.8);
}

input[type="text"]:focus {
  border-color: var(--accent);
  background: rgba(26, 32, 56, 0.9);
  box-shadow: 0 0 0 3px rgba(123, 104, 238, 0.2), 0 4px 16px rgba(123, 104, 238, 0.1);
  transform: translateY(-1px);
}

input[type="text"]::placeholder {
  color: rgba(184, 194, 224, 0.5);
  font-weight: 400;
  transition: opacity 0.2s ease;
}

input[type="text"]:focus::placeholder {
  opacity: 0.7;
}

.confidence-slider {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin: 1.5rem 0;
}

.slider-container {
  display: flex;
  align-items: center;
  gap: 1rem;
  width: 100%;
}

input[type="range"] {
  flex: 1;
  height: 6px;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  background: rgba(184, 194, 224, 0.1);
  border-radius: 10px;
  outline: none;
  transition: var(--transition);
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--accent);
  cursor: pointer;
  transition: var(--transition);
  box-shadow: 0 0 0 2px var(--bg-secondary), 0 2px 10px rgba(0, 0, 0, 0.2);
}

input[type="range"]:hover::-webkit-slider-thumb {
  transform: scale(1.1);
  background: var(--accent-hover);
}

.slider-value {
  min-width: 2.5rem;
  text-align: center;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--accent);
  background: rgba(123, 104, 238, 0.1);
  padding: 0.3rem 0.6rem;
  border-radius: 20px;
  transition: var(--transition);
}

.slider-tooltip {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-top: 0.5rem;
  font-style: italic;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.slider-tooltip::before {
  content: '💡';
  font-style: normal;
}

/* Error Message Styling */
.error-message {
  color: var(--error);
  font-size: 0.9rem;
  margin-top: 1rem;
  text-align: center;
  font-weight: 500;
  opacity: 0;
  transition: opacity 0.3s ease;
  padding: 0.75rem 1rem;
  background: rgba(248, 113, 113, 0.1);
  border-radius: var(--border-radius);
  border-left: 3px solid var(--error);
  animation: fadeIn 0.3s ease forwards;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-5px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Focus styles for better accessibility */
*:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}

/* Disabled state for buttons */
button:disabled {
  cursor: not-allowed;
  opacity: 0.7;
  transform: none !important;
  box-shadow: none !important;
}

.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  border: none;
  border-radius: 8px;
  padding: 12px 24px;
  font-size: 16px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  margin: 20px 0 0;
  display: inline-block;
  min-width: 160px;
  text-align: center;
}

.start-btn:hover, .submit-btn:hover {
  background: var(--accent-hover);
}

.start-btn:active, .submit-btn:active {
  transform: scale(0.98);
}

.start-btn:disabled, .submit-btn:disabled {
  background: #4a4e69;
  cursor: not-allowed;
  opacity: 0.7;
  transform: none;
}

.start-btn.loading::after {
  content: '';
  position: absolute;
  width: 20px;
  height: 20px;
  border: 3px solid rgba(255, 255, 255, 0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes buttonPulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.02); }
  100% { transform: scale(1); }
}

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

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(15px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.progress-circle {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 1.5rem;
  position: relative;
}

.timer-num {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  font-size: 1.2rem;
  font-weight: 700;
  color: #506eff;
}

.question-number {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
  text-align: center;
  font-weight: 500;
  letter-spacing: 0.3px;
}

.question-text {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 1.1rem;
  text-align: center;
}

.quiz-actions {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  margin-top: 0.7rem;
}

.hint-btn {
  background: none;
  border: 2px dashed #506eff;
  color: #506eff;
  border-radius: 0.75rem;
  padding: 0.7rem;
  cursor: pointer;
  font-size: 1rem;
  font-weight: 600;
  transition: background 0.2s, color 0.2s;
}

.hint-btn:active {
  background: #f0f6ff;
}

.quiz-feedback {
  margin-top: 0.6rem;
  min-height: 1.2em;
}

.tf-toggle {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
}

/* Animations */
.animate-fadein {
  animation: fadein 0.5s;
}
.animate-fadeout {
  animation: fadeout 0.4s;
  opacity: 0 !important;
}
.animate-slidein {
  animation: slidein 0.5s;
}
@keyframes fadein {
  from { opacity: 0; transform: scale(0.97); }
  to { opacity: 1; transform: scale(1); }
}
@keyframes fadeout {
  from { opacity: 1; }
  to { opacity: 0; }
}
@keyframes slidein {
  from { opacity: 0; transform: translateY(40px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Results Page */
.quiz-card {
  max-width: 800px;
  padding: 2rem;
}

/* Score Display */
.score-display {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
  margin: 1.5rem 0;
}

.score-circle {
  width: 160px;
  height: 160px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-color), #7a5fff);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  color: white;
  box-shadow: 0 10px 25px rgba(80, 110, 255, 0.3);
  margin: 0 auto;
}

.score-percent {
  font-size: 2.5rem;
  font-weight: 700;
  line-height: 1;
  margin-bottom: 0.25rem;
}

.score-label {
  font-size: 1rem;
  opacity: 0.9;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 500;
}

.score-details {
  display: flex;
  gap: 2rem;
  text-align: center;
  margin-top: 1rem;
}

.score-detail {
  display: flex;
  flex-direction: column;
}

.detail-value {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
}

.detail-label {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-top: 0.25rem;
}

/* Results Actions */
.results-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  margin-top: 2rem;
  flex-wrap: wrap;
}

.btn-primary, .btn-secondary {
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  border: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-primary {
  background: var(--accent-color);
  color: white;
  box-shadow: 0 4px 15px rgba(80, 110, 255, 0.3);
}

.btn-primary:hover {
  background: #3a5eff;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(80, 110, 255, 0.4);
}

.btn-secondary {
  background: var(--card-bg);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  background: var(--bg-color);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Results List & Items */
.results-list {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  margin-top: 1rem;
}

.results-list h3 {
  font-size: 1.2rem;
  margin-bottom: 1rem;
  color: var(--text-primary);
  font-weight: 600;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--border-color);
}

.result-item {
  background: var(--card-bg);
  border-radius: 12px;
  padding: 1.25rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  border-left: 4px solid transparent;
  color: var(--text-primary);
}

.result-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.result-item.correct {
  border-left-color: #20c997;
  background: rgba(32, 201, 151, 0.05);
}

.result-item.incorrect {
  border-left-color: #ff5a5f;
  background: rgba(255, 90, 95, 0.05);
}

.result-question {
  font-weight: 500;
  margin-bottom: 0.75rem;
  line-height: 1.5;
  color: var(--text-primary);
}

.result-number {
  display: inline-block;
  width: 1.75rem;
  height: 1.75rem;
  background: var(--accent-color);
  color: white;
  border-radius: 50%;
  text-align: center;
  line-height: 1.75rem;
  font-size: 0.9rem;
  margin-right: 0.5rem;
  font-weight: 600;
}

.result-answer, .result-correct {
  margin: 0.5rem 0;
  font-size: 0.95rem;
  line-height: 1.5;
  padding-left: 1.75rem;
}

.result-label {
  color: var(--text-secondary);
  font-weight: 500;
}

.result-value {
  color: var(--text-primary);
  font-weight: 500;
}

.result-item.incorrect .result-value {
  color: #ff5a5f;
  text-decoration: line-through;
}

.result-item.correct .result-value {
  color: #20c997;
}

.result-correct .result-value {
  color: #20c997;
  font-weight: 600;
}

/* Ensure correct answer is green in review mistakes */
.result-item.incorrect .result-correct .result-value {
  color: #20c997;
  text-decoration: none;
  font-weight: 500;
}

.result-explanation {
  margin-top: 0.75rem;
  padding: 0.75rem;
  background: rgba(0, 0, 0, 0.03);
  border-radius: 8px;
  font-size: 0.9rem;
  line-height: 1.5;
  color: var(--text-secondary);
  border-right: 3px solid var(--accent-color);
}

.empty-state {
  text-align: center;
  padding: 2rem 1rem;
  color: var(--text-secondary);
  font-size: 1rem;
}

/* Performance Comparison */
.performance-comparison {
  padding: 0.5rem;
}

.performance-comparison h3 {
  font-size: 1.2rem;
  margin-bottom: 1.5rem;
  color: var(--text-primary);
  text-align: center;
}

.comparison-chart {
  background: var(--card-bg);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.performance-tips {
  background: var(--card-bg);
  border-radius: 12px;
  padding: 1.5rem;
  margin-top: 1.5rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.performance-tips h4 {
  font-size: 1.1rem;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.performance-tips ul {
  padding-left: 1.25rem;
  margin: 0;
}

.performance-tips li {
  margin-bottom: 0.5rem;
  line-height: 1.5;
  color: var(--text-secondary);
}

.performance-tips li:last-child {
  margin-bottom: 0;
}

/* Performance Metrics */
.performance-metrics {
  display: flex;
  justify-content: center;
  gap: 3rem;
  margin: 2rem 0;
  text-align: center;
}

.metric {
  background: var(--card-bg);
  border-radius: 12px;
  padding: 1.5rem;
  min-width: 160px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  border: 1px solid var(--border-color);
}

.metric-value {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--accent-color);
  line-height: 1;
  margin-bottom: 0.5rem;
}

.metric-label {
  font-size: 0.9rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Bars */
.bars-container {
  background: var(--card-bg);
  border-radius: 12px;
  padding: 1.5rem;
  margin: 2rem 0;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  border: 1px solid var(--border-color);
}

.bar-label {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
  display: block;
}

.bar {
  height: 36px;
  background: rgba(0, 0, 0, 0.1);
  border-radius: 18px;
  overflow: hidden;
  position: relative;
  margin-bottom: 1.5rem;
  border: 1px solid var(--border-color);
  background: rgba(0, 0, 0, 0.1);
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.2);
}

.bar-fill {
  height: 100%;
  border-radius: 18px;
  position: relative;
  transition: width 0.8s ease;
  min-width: 2%;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding-right: 15px;
  box-sizing: border-box;
  color: white;
  font-weight: 600;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.bar-text {
  position: absolute;
  top: 50%;
  right: 15px;
  transform: translateY(-50%);
  color: white;
  font-weight: 600;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

/* Insight Box */
.insight-box {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  background: rgba(80, 110, 255, 0.1);
  border-left: 4px solid var(--accent-color);
  padding: 1rem 1.25rem;
  border-radius: 8px;
  margin: 1.5rem 0;
}

.insight-icon {
  font-size: 1.5rem;
  line-height: 1;
  margin-top: 0.2rem;
}

.insight-text {
  flex: 1;
  color: var(--text-primary);
  line-height: 1.5;
}

/* Share Container */
.share-container {
  text-align: center;
  padding: 1.5rem 0;
}

.share-container h3 {
  color: var(--text-primary);
  margin-bottom: 1rem;
}

.share-container p {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  line-height: 1.6;
}

.share-buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  margin: 1.5rem 0;
}

.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 1.2rem;
  border-radius: 8px;
  border: none;
  font-size: 0.95rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  background: var(--card-bg);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}

.share-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.share-btn i {
  font-size: 1.1rem;
}

.share-btn.twitter {
  background: #1da1f2;
  color: white;
  border-color: #1da1f2;
}

.share-btn.linkedin {
  background: #0077b5;
  color: white;
  border-color: #0077b5;
}

.download-options {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-color);
}

.download-options p {
  margin-bottom: 1rem;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
  .performance-metrics {
    flex-direction: column;
    gap: 1rem;
  }
  
  .metric {
    width: 100%;
  }
  
  .share-buttons {
    flex-direction: column;
  }
  
  .share-btn {
    width: 100%;
    justify-content: center;
  }
}

/* Results & Tabs */
.tabs {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 0.5rem;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.tabs::-webkit-scrollbar {
  display: none;
}

.tab-btn {
  background: none;
  border: none;
  padding: 0.5rem 1rem;
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
  border-radius: 6px;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.tab-btn:hover {
  color: var(--accent-color);
  background: rgba(80, 110, 255, 0.1);
}

.tab-btn.active {
  color: var(--accent-color);
  font-weight: 600;
  position: relative;
}

.tab-btn.active::after {
  content: '';
  position: absolute;
  bottom: -0.5rem;
  left: 50%;
  transform: translateX(-50%);
  width: 24px;
  height: 3px;
  background: var(--accent-color);
  border-radius: 3px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .score-circle {
    width: 140px;
    height: 140px;
  }
  
  .score-percent {
    font-size: 2rem;
  }
  
  .results-actions {
    flex-direction: column;
    align-items: stretch;
  }
  
  .btn-primary, .btn-secondary {
    width: 100%;
    justify-content: center;
  }
}

/* Results & Tabs */
.tabs {
  display: flex;
  gap: 0.5rem;
  margin: 1.2rem 0 0.7rem 0;
  justify-content: center;
}
.tab-btn {
  background: #f8fafc;
  border: 1.5px solid #e0e5ef;
  color: #506eff;
  padding: 0.6rem 1.1rem;
  border-radius: 0.8rem 0.8rem 0 0;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.tab-btn.active, .tab-btn:focus {
  background: #506eff;
  color: #fff;
  outline: none;
}
.tab-content {
  background: linear-gradient(145deg, #0a1128, #1a1f3a);
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  border-radius: 0 0 1.2rem 1.2rem;
  padding: 1.1rem 0.7rem;
  min-height: 120px;
}
.result-card {
  border-radius: 0.7rem;
  box-shadow: 0 1px 6px rgba(80,110,255,0.07);
  margin-bottom: 1rem;
  padding: 0.7rem 0.9rem;
  background: #fff;
  font-size: 1rem;
}
.result-card.correct {
  border-left: 6px solid #20c997;
}
.result-card.incorrect {
  border-left: 6px solid #ff5a5f;
}
.confetti {
  margin-bottom: 0.7rem;
  text-align: center;
}
.confidence-bar {
  width: 100%;
  height: 18px;
  background: #e0e5ef;
  border-radius: 9px;
  overflow: hidden;
  margin-top: 0.5rem;
  position: relative;
}

.confidence-bar-inner {
  height: 100%;
  display: inline-block;
  text-align: center;
  color: #fff;
  font-size: 0.85rem;
  font-weight: 600;
  line-height: 18px;
  border-radius: 1rem;
  position: absolute;
  left: 0;
  top: 0;
  z-index: 1;
  opacity: 0.92;
}

@media (max-width: 600px) {
  .quiz-card {
    padding: 1.25rem 0.5rem;
    max-width: 98vw;
  }
  .tab-content {
    padding: 0.5rem 0.2rem;
  }
}

/* Print styles for PDF */
@media print {
  body, #app, .quiz-card {
    background: #fff !important;
    color: #23272f !important;
    box-shadow: none !important;
  }
  .start-btn, .hint-btn, .tabs, .confetti {
    display: none !important;
  }
  .tab-content, .result-card {
    background: #fff !important;
    color: #23272f !important;
    box-shadow: none !important;
  }
}

/* Enhanced Submit Button */
.quiz-actions {
  margin: 2.5rem auto 0;
  width: 100%;
  max-width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0 1rem;
}

#quiz-form {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
}

.submit-btn {
  background: linear-gradient(135deg, var(--accent) 0%, #6a5acd 100%);
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  border-radius: 50px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: var(--transition);
  box-shadow: 0 4px 12px rgba(123, 104, 238, 0.4);
  width: 100%;
  max-width: 220px;
  position: relative;
  overflow: hidden;
  z-index: 1;
}

.submit-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 0;
  height: 100%;
  background: linear-gradient(135deg, var(--accent-hover) 0%, #7b68ee 100%);
  transition: all 0.4s ease;
  z-index: -1;
  opacity: 0;
}

.submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(123, 104, 238, 0.6);
}

.submit-btn:hover::before {
  width: 100%;
  opacity: 1;
}

.submit-btn:active {
  transform: translateY(0);
  box-shadow: 0 2px 10px rgba(123, 104, 238, 0.6);
}

.submit-btn:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(123, 104, 238, 0.4), 0 4px 15px rgba(123, 104, 238, 0.4);
}

.submit-arrow {
  transition: transform 0.3s ease;
}

.submit-btn:hover .submit-arrow {
  transform: translateX(4px);
}

/* Quiz Footer */
.quiz-footer {
  margin-top: 2.5rem;
  text-align: center;
  width: 100%;
  padding: 1rem 0 0;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.quiz-footer p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin: 0;
  opacity: 0.8;
  transition: var(--transition);
}

.quiz-footer p:hover {
  opacity: 1;
  color: var(--accent);
}

.quiz-footer a {
  color: var(--accent);
  text-decoration: none;
  transition: var(--transition);
}

.quiz-footer a:hover {
  text-decoration: underline;
}

/* Update timer display */
.timer-num {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-primary);
}

/* Footer Styles */
.site-footer {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  padding: 12px 20px;
  text-align: center;
  font-size: 0.9rem;
  color: var(--text-secondary);
  background: rgba(10, 14, 35, 0.9);
  backdrop-filter: blur(8px);
  z-index: 1000;
  border-top: 1px solid rgba(123, 104, 238, 0.2);
  transition: all 0.3s ease;
}

.site-footer:hover {
  color: var(--accent);
  background: rgba(10, 14, 35, 0.95);
}

/* Add padding to the bottom of the app to prevent content from being hidden behind the fixed footer */
body {
  padding-bottom: 50px;
}

/* Responsive adjustments */
@media (max-width: 480px) {
  .submit-btn {
    padding: 0.875rem 1.5rem;
    font-size: 1rem;
  }
}
