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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background-color: var(--bg-color);
  color: var(--text-color);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.header {
  background: rgba(255,255,255,0.05);
  padding: 16px 0;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}

.header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  height: 40px;
}

.site-name {
  font-size: 1.25rem;
  font-weight: 600;
}

.btn-logout {
  color: var(--text-color);
  opacity: 0.7;
  text-decoration: none;
}

.main {
  flex: 1;
  padding: 40px 20px;
}

.footer {
  padding: 20px;
  text-align: center;
  opacity: 0.6;
  font-size: 0.875rem;
}

/* Auth */
.auth-container {
  max-width: 400px;
  margin: 0 auto;
  text-align: center;
}

.login-form {
  margin-top: 30px;
}

.form-group {
  margin-bottom: 20px;
  text-align: left;
}

.form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 500;
}

.form-group input {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 8px;
  background: rgba(255,255,255,0.05);
  color: var(--text-color);
  font-size: 1rem;
}

.or-divider {
  margin: 20px 0;
  opacity: 0.5;
}

.btn-primary {
  display: inline-block;
  padding: 12px 24px;
  background: var(--primary-color);
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  cursor: pointer;
  text-decoration: none;
  transition: opacity 0.2s;
}

.btn-primary:hover {
  opacity: 0.9;
}

.error {
  background: rgba(239, 68, 68, 0.2);
  border: 1px solid rgb(239, 68, 68);
  padding: 12px;
  border-radius: 8px;
  margin-bottom: 20px;
}

.register-link {
  margin-top: 24px;
  opacity: 0.8;
}

.register-link a {
  color: var(--primary-color);
  text-decoration: none;
}

.register-link a:hover {
  text-decoration: underline;
}

.hint {
  display: block;
  margin-top: 6px;
  font-size: 0.75rem;
  opacity: 0.6;
}

/* Course */
.course-container {
  max-width: 800px;
  margin: 0 auto;
}

.course-description {
  opacity: 0.8;
  margin-bottom: 40px;
}

.section {
  margin-bottom: 40px;
}

.section-title {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
}

.section-number {
  background: var(--primary-color);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.875rem;
}

.section-description {
  opacity: 0.7;
  margin-bottom: 16px;
  margin-left: 44px;
}

.lessons {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-left: 44px;
}

.lesson-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  background: rgba(255,255,255,0.05);
  border-radius: 8px;
  text-decoration: none;
  color: var(--text-color);
  transition: background 0.2s;
}

.lesson-card:hover {
  background: rgba(255,255,255,0.1);
}

.lesson-title {
  flex: 1;
}

.lesson-duration {
  opacity: 0.6;
  font-size: 0.875rem;
}

.badge-free {
  background: var(--secondary-color);
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 0.75rem;
}

/* Lesson */
.lesson-container {
  max-width: 900px;
  margin: 0 auto;
}

.back-link {
  color: var(--text-color);
  opacity: 0.7;
  text-decoration: none;
  margin-bottom: 20px;
  display: inline-block;
}

.video-container {
  margin: 20px 0;
  border-radius: 12px;
  overflow: hidden;
}

.lesson-content {
  margin: 30px 0;
  line-height: 1.8;
}

.quiz-cta {
  margin-top: 30px;
  text-align: center;
}

/* Quiz */
.quiz-container {
  max-width: 700px;
  margin: 0 auto;
}

.question {
  margin-bottom: 30px;
  padding: 20px;
  background: rgba(255,255,255,0.05);
  border-radius: 12px;
}

.question-text {
  font-weight: 500;
  margin-bottom: 16px;
}

.question-number {
  color: var(--primary-color);
}

.answers {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.answer {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: rgba(255,255,255,0.05);
  border-radius: 8px;
  cursor: pointer;
}

.answer:hover {
  background: rgba(255,255,255,0.1);
}

.quiz-result {
  text-align: center;
  padding: 40px;
  border-radius: 12px;
}

.quiz-result.passed {
  background: rgba(34, 197, 94, 0.2);
}

.quiz-result.failed {
  background: rgba(239, 68, 68, 0.2);
}

.score {
  font-size: 2rem;
  font-weight: 600;
  margin: 20px 0;
}
