style.css
/* Import Google Fonts - Inter & JetBrains Mono */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500;600&display=swap');

:root {
  --primary: #6366f1;
  --primary-dark: #4f46e5;
  --secondary: #ec4899;
  --accent: #06b6d4;
  --success: #10b981;
  --error: #ef4444;
  --warning: #f59e0b;
  --background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  --surface: rgba(255, 255, 255, 0.95);
  --surface-hover: rgba(255, 255, 255, 1);
  --text-primary: #1f2937;
  --text-secondary: #6b7280;
  --border: rgba(255, 255, 255, 0.2);
  --shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  --shadow-hover: 0 35px 60px -12px rgba(0, 0, 0, 0.35);
}

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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--background);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  position: relative;
  overflow-x: hidden;
}

/* Animated background particles */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background:
          radial-gradient(circle at 25% 25%, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
          radial-gradient(circle at 75% 75%, rgba(255, 255, 255, 0.05) 0%, transparent 50%);
  animation: float 20s ease-in-out infinite;
  pointer-events: none;
  z-index: -1;
}

@keyframes float {
  0%, 100% { transform: translateY(0px) rotate(0deg); }
  33% { transform: translateY(-20px) rotate(1deg); }
  66% { transform: translateY(10px) rotate(-1deg); }
}

::selection {
  background: var(--primary);
  color: white;
}

.wrapper {
  width: min(900px, 100%);
  background: var(--surface);
  backdrop-filter: blur(20px);
  border-radius: 24px;
  padding: 40px;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.wrapper::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--primary), var(--secondary), var(--accent));
  border-radius: 24px 24px 0 0;
}

.wrapper:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
  background: var(--surface-hover);
}

.wrapper .input-field {
  opacity: 0;
  position: absolute;
  z-index: -999;
}

.content-box {
  background: rgba(255, 255, 255, 0.6);
  border-radius: 16px;
  padding: 24px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
}

.content-box:hover {
  background: rgba(255, 255, 255, 0.8);
  border-color: rgba(255, 255, 255, 0.5);
}

.typing-text {
  max-height: 300px;
  overflow-y: auto;
  scroll-behavior: smooth;
}

.typing-text::-webkit-scrollbar {
  width: 6px;
}

.typing-text::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.05);
  border-radius: 10px;
}

.typing-text::-webkit-scrollbar-thumb {
  background: var(--primary);
  border-radius: 10px;
  transition: background 0.3s ease;
}

.typing-text::-webkit-scrollbar-thumb:hover {
  background: var(--primary-dark);
}

.typing-text p {
  font-family: 'JetBrains Mono', 'Monaco', 'Consolas', monospace;
  font-size: 22px;
  line-height: 1.8;
  text-align: justify;
  letter-spacing: 0.5px;
  word-break: break-word;
  color: var(--text-primary);
  font-weight: 500;
}

.typing-text p span {
  position: relative;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  border-radius: 4px;
  padding: 2px 1px;
}

.typing-text p span.correct {
  color: var(--success);
  background: rgba(16, 185, 129, 0.1);
  transform: scale(1.02);
}

.typing-text p span.incorrect {
  color: var(--error);
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.3);
  animation: shake 0.5s ease-in-out;
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-2px); }
  75% { transform: translateX(2px); }
}

.typing-text p span.active {
  color: var(--primary);
  background: rgba(99, 102, 241, 0.1);
  font-weight: 600;
  transform: scale(1.05);
}

.typing-text p span.active::before {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  border-radius: 2px;
  animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scaleX(1); }
  50% { opacity: 0.7; transform: scaleX(0.95); }
}

.content {
  margin-top: 24px;
  padding: 24px 0 0;
  border-top: 1px solid rgba(0, 0, 0, 0.1);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.content button {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: white;
  border: none;
  padding: 14px 28px;
  font-size: 16px;
  font-weight: 600;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3);
  position: relative;
  overflow: hidden;
  min-width: 120px;
}

.content button::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s ease;
}

.content button:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(99, 102, 241, 0.4);
  background: linear-gradient(135deg, var(--primary-dark), var(--primary));
}

.content button:hover::before {
  left: 100%;
}

.content button:active {
  transform: translateY(0);
  box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3);
}

.result-details {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  align-items: center;
  flex: 1;
}

.result-details li {
  display: flex;
  align-items: center;
  list-style: none;
  background: rgba(255, 255, 255, 0.7);
  padding: 12px 16px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
  min-width: 120px;
}

.result-details li:hover {
  background: rgba(255, 255, 255, 0.9);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.result-details li p {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.result-details li span {
  font-size: 24px;
  font-weight: 800;
  color: var(--text-primary);
  margin-left: 8px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Responsive Design */
@media (max-width: 768px) {
  body {
    padding: 10px;
  }

  .wrapper {
    padding: 24px;
    border-radius: 20px;
  }

  .content-box {
    padding: 20px;
  }

  .typing-text p {
    font-size: 18px;
    text-align: left;
  }

  .content {
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
  }

  .content button {
    width: 100%;
    padding: 16px;
    font-size: 18px;
  }

  .result-details {
    justify-content: space-between;
    width: 100%;
  }

  .result-details li {
    flex: 1;
    min-width: auto;
    justify-content: center;
    flex-direction: column;
    text-align: center;
    padding: 16px 12px;
  }

  .result-details li span {
    margin-left: 0;
    margin-top: 4px;
    font-size: 20px;
  }
}

@media (max-width: 480px) {
  .wrapper {
    padding: 16px;
  }

  .content-box {
    padding: 16px;
  }

  .typing-text p {
    font-size: 16px;
  }

  .result-details {
    flex-direction: column;
    gap: 12px;
  }

  .result-details li {
    width: 100%;
    flex-direction: row;
    justify-content: space-between;
  }

  .result-details li span {
    margin-left: 8px;
    margin-top: 0;
  }
}

/* Special animations for better UX */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.wrapper {
  animation: fadeInUp 0.6s ease-out;
}

.result-details li {
  animation: fadeInUp 0.6s ease-out;
}

.result-details li:nth-child(2) {
  animation-delay: 0.1s;
}

.result-details li:nth-child(3) {
  animation-delay: 0.2s;
}

.result-details li:nth-child(4) {
  animation-delay: 0.3s;
}