/**
 * Main Stylesheet for TypingExam.in
 * Extracted from inline styles for better performance and caching
 */

/* CSS Variables */
:root {
  --primary-color: #1976d2;
  --secondary-color: #424242;
  --accent-color: #ff6f00;
  --success-color: #388e3c;
}

/* Base Styles */
body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: #f8f9fa;
}

/* Hero Section */
.hero-section {
  background: linear-gradient(135deg, var(--primary-color), #1565c0);
  color: white;
  padding: 60px 0 50px;
  margin-bottom: 40px;
  position: relative;
  overflow: hidden;
}

.hero-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(800px circle at 20% 10%, rgba(255, 255, 255, 0.20), transparent 60%),
    radial-gradient(700px circle at 80% 20%, rgba(255, 255, 255, 0.15), transparent 55%),
    radial-gradient(900px circle at 40% 110%, rgba(0, 0, 0, 0.18), transparent 55%);
  opacity: 0.9;
  pointer-events: none;
}

.hero-section .container {
  position: relative;
  z-index: 1;
}

.hero-title {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 15px;
}

.hero-subtitle {
  font-size: 1.2rem;
  opacity: 0.9;
  margin-bottom: 0;
}

/* Typing Effect Styles */
.typing-effect {
  display: inline;
  background: linear-gradient(90deg, #fff, rgba(255, 255, 255, 0.95));
  -webkit-background-clip: text;
  background-clip: text;
}

.typing-cursor {
  display: inline-block;
  color: rgba(255, 255, 255, 0.9);
  font-weight: 400;
  animation: blink 0.6s ease-in-out infinite;
  margin-left: 2px;
  transition: opacity 0.5s ease-out;
}

.typing-cursor.typing-done {
  animation: none;
  opacity: 0;
  visibility: hidden;
}

@keyframes blink {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0;
  }
}

.hero-actions {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
}

.hero-kpis {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.hero-kpi {
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 12px;
  padding: 12px 16px;
  min-width: 160px;
}

.hero-kpi-value {
  font-size: 1.25rem;
  font-weight: 800;
  line-height: 1.1;
}

.hero-kpi-label {
  font-size: 0.9rem;
  opacity: 0.9;
}

/* Category Section Styles */
.category-section {
  margin-bottom: 30px;
}

.category-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
  padding-bottom: 10px;
  border-bottom: 2px solid #e0e0e0;
}

.category-header-icon {
  color: var(--primary-color);
  font-size: 1.5rem;
}

.category-header-name {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--secondary-color);
  margin: 0;
}

.category-header-badge {
  background: var(--primary-color);
  color: white;
  padding: 4px 12px;
  border-radius: 6px;
  font-size: 0.85rem;
  font-weight: 600;
}

.category-header-action {
  margin-left: auto;
  color: var(--primary-color);
  text-decoration: none;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 5px;
  transition: color 0.2s;
}

.category-header-action:hover {
  color: #1565c0;
}

/* Exam Card Styles */
.exam-card {
  border: 1px solid #e0e0e0;
  border-radius: 12px;
  transition: all 0.3s ease;
  overflow: hidden;
  background: white;
  height: 100%;
}

.exam-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
  border-color: var(--primary-color);
}

.exam-card .card-body {
  padding: 20px;
}

.exam-badge {
  font-size: 0.75rem;
  padding: 4px 10px;
  border-radius: 20px;
}

.btn-start {
  background: var(--primary-color);
  color: white;
  border-radius: 25px;
  padding: 10px 25px;
  font-weight: 500;
  transition: all 0.3s ease;
}

.btn-start:hover {
  background: #1565c0;
  color: white;
  transform: scale(1.05);
}

.category-badge {
  background: var(--primary-color);
  color: white;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
}

.section-title {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--secondary-color);
  margin-bottom: 10px;
}

.section-subtitle {
  color: #666;
  margin-bottom: 30px;
}

.exam-card-header {
  background: var(--primary-color);
  color: white;
  padding: 15px 20px;
  font-weight: 600;
  font-size: 1.05rem;
}

.exam-card-body {
  padding: 25px;
}

.exam-meta {
  display: flex;
  gap: 15px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.exam-meta-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
  color: #666;
}

.exam-meta-item i {
  color: var(--primary-color);
}

.btn-practice {
  background: var(--primary-color);
  border: none;
  padding: 10px 25px;
  border-radius: 6px;
  font-weight: 600;
  transition: all 0.3s ease;
  color: white;
}

.btn-practice:hover {
  background: #1565c0;
  box-shadow: 0 4px 12px rgba(25, 118, 210, 0.3);
  color: white;
}

.features-section {
  background: white;
  padding: 50px 24px;
  margin: 40px 0;
  border-radius: 16px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
  border: 1px solid #eee;
  overflow: hidden;
}

.feature-item {
  text-align: center;
  padding: 20px;
}

.feature-icon {
  width: 70px;
  height: 70px;
  background: linear-gradient(135deg, var(--primary-color), #1565c0);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  color: white;
  margin: 0 auto 15px;
}

.footer {
  background: var(--secondary-color);
  color: white;
  padding: 40px 0 20px;
  margin-top: 60px;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  transition: color 0.3s;
}

.footer-links a:hover {
  color: white;
}

.empty-state {
  text-align: center;
  padding: 60px 20px;
  background: white;
  border-radius: 16px;
}

.empty-state i {
  font-size: 4rem;
  color: #ddd;
  margin-bottom: 20px;
}

.faq-card {
  background: white;
  border-radius: 16px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
  border: 1px solid #eee;
  overflow: hidden;
}

/* Category Chips Section */
.exam-chips-section {
  border-radius: 16px;
  margin-bottom: 40px;
  overflow: hidden;
}

.exam-chip-container {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  overflow-y: hidden;
  padding: 10px 0;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  scrollbar-color: var(--primary-color) #f0f0f0;
}

.exam-chip-container::-webkit-scrollbar {
  height: 8px;
}

.exam-chip-container::-webkit-scrollbar-track {
  background: #f0f0f0;
  border-radius: 10px;
}

.exam-chip-container::-webkit-scrollbar-thumb {
  background: var(--primary-color);
  border-radius: 10px;
}

.exam-chip-container::-webkit-scrollbar-thumb:hover {
  background: #1565c0;
}

.exam-chip {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 20px 8px 8px;
  background: linear-gradient(135deg, #f8f9fa, #ffffff);
  border: 2px solid #e0e0e0;
  border-radius: 30px;
  transition: all 0.3s ease;
  text-decoration: none;
  color: var(--secondary-color);
  font-weight: 500;
  font-size: 0.95rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  white-space: nowrap;
  flex-shrink: 0;
}

.exam-chip:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(25, 118, 210, 0.2);
  border-color: var(--primary-color);
  background: linear-gradient(135deg, #e3f2fd, #ffffff);
  color: var(--primary-color);
}

.exam-chip-logo {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: contain;
  background: white;
  padding: 5px;
  border: 1px solid #e0e0e0;
}

.exam-chip-badge {
  background: var(--primary-color);
  color: white;
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 600;
  margin-left: 5px;
}

/* Responsive Styles */
@media (max-width: 576px) {
  .hero-title {
    font-size: 1.9rem;
  }

  .hero-subtitle {
    font-size: 1rem;
  }

  .hero-section {
    padding: 50px 0 40px;
  }
}

/* Overview Card Section */
.overview-card {
  background: white;
  padding: 30px;
  border-radius: 16px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
  border: 1px solid #eee;
}

.overview-card p {
  line-height: 1.7;
  color: #555;
}

.overview-card .table {
  font-size: 0.9rem;
}

.overview-card .table th {
  font-weight: 600;
  white-space: nowrap;
}