:root {
  --bg-main: #050810;
  --bg-gradient-top: #050810;
  --bg-gradient-bottom: #101520;
  --card-bg: #151b26;
  --card-border: #262f3f;
  --text-main: #e5e7eb;
  --text-muted: #9ca3af;
  --accent: #2aabee;
  --accent-hover: #3bc0ff;
  --divider: #1f2933;
  --overlay-bg: rgba(0, 0, 0, 0.7);
  --radius-lg: 18px;
  --radius-md: 12px;
  --transition-fast: 0.18s ease-out;
}

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

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "SF Pro Text",
  "Segoe UI", sans-serif;
  background: radial-gradient(circle at top, #13192b 0, transparent 55%),
  linear-gradient(to bottom, var(--bg-gradient-top), var(--bg-gradient-bottom));
  color: var(--text-main);
  min-height: 100vh;
  display: flex;
  justify-content: center;
}

.page {
  width: 100%;
  max-width: 560px;
  padding: 20px 16px 32px;
  opacity: 0;
  transform: translateY(4px);
  animation: fadeInUp 0.25s ease-out forwards;
}

.card {
  background: rgba(15, 23, 42, 0.96);
  border-radius: 24px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  box-shadow:
    0 18px 40px rgba(15, 23, 42, 0.7),
    0 0 0 1px rgba(15, 23, 42, 0.7);
  padding: 18px 14px 20px;
  backdrop-filter: blur(22px);
}

@media (min-width: 480px) {
  .page {
    padding: 28px 18px 40px;
  }

  .card {
    padding: 22px 18px 24px;
  }
}

.hero {
  text-align: center;
  padding: 10px 6px 18px;
  border-bottom: 1px solid var(--divider);
  margin-bottom: 18px;
}

.hero-avatar-wrapper {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 10px;
}

.hero-avatar-ring {
  width: 112px;
  height: 112px;
  border-radius: 999px;
  background: conic-gradient(
    from 180deg,
    rgba(42, 171, 238, 0.2),
    rgba(56, 189, 248, 0.6),
    rgba(42, 171, 238, 0.2)
  );
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 3px;
}

.hero-avatar {
  width: 100%;
  height: 100%;
  border-radius: 999px;
  background: radial-gradient(circle at 30% 20%, #1f2937, #020617);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-size: 32px;
  font-weight: 600;
  letter-spacing: 0.05em;
  overflow: hidden;
  position: relative;
}

.hero-avatar img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-title {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 0.02em;
  margin-bottom: 6px;
}

.hero-subtitle {
  font-size: 13px;
  color: var(--text-muted);
  max-width: 320px;
  margin: 0 auto 14px;
  line-height: 1.4;
}

.hero-hint {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(148, 163, 184, 0.4);
}

.hero-hint-text {
  font-size: 11px;
  color: var(--text-muted);
}

.hero-arrow {
  width: 26px;
  height: 26px;
  border-radius: 999px;
  border: none;
  background: var(--accent);
  color: #f9fafb;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background-color var(--transition-fast), transform var(--transition-fast),
  box-shadow var(--transition-fast), opacity var(--transition-fast);
  box-shadow:
    0 0 0 1px rgba(15, 23, 42, 0.7),
    0 4px 12px rgba(37, 99, 235, 0.45);
}

.hero-arrow:hover {
  background: var(--accent-hover);
  transform: translateY(1px);
  box-shadow:
    0 0 0 1px rgba(15, 23, 42, 0.7),
    0 6px 16px rgba(59, 130, 246, 0.6);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 18px;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.02em;
  transition: background-color var(--transition-fast),
  transform var(--transition-fast), box-shadow var(--transition-fast),
  border-color var(--transition-fast), opacity var(--transition-fast);
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background: var(--accent);
  color: #f9fafb;
  box-shadow:
    0 0 0 1px rgba(15, 23, 42, 0.7),
    0 5px 18px rgba(37, 99, 235, 0.55);
}

.btn-primary:hover {
  background: var(--accent-hover);
  transform: translateY(-1px);
  box-shadow:
    0 0 0 1px rgba(15, 23, 42, 0.7),
    0 7px 26px rgba(59, 130, 246, 0.65);
}

.btn-secondary {
  background: transparent;
  color: var(--accent);
  border: 1px solid rgba(148, 163, 184, 0.5);
}

.btn-secondary:hover {
  border-color: var(--accent);
  background: rgba(15, 23, 42, 0.8);
}

.btn-sm {
  padding: 7px 14px;
  font-size: 13px;
}

.btn-full {
  width: 100%;
}

.btn-icon {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.lessons-section {
  padding-top: 4px;
  padding-bottom: 14px;
}

.lessons-group-title {
  font-size: 14px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 8px;
  padding: 0 4px;
}

.lessons-group-subtitle {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 12px;
  padding: 0 4px;
}

.lessons-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 16px;
}

.lesson-card {
  display: flex;
  gap: 10px;
  padding: 9px 9px;
  border-radius: var(--radius-md);
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  align-items: center;
}

.lesson-thumb {
  flex-shrink: 0;
  width: 92px;
  aspect-ratio: 1 / 1;
  border-radius: 12px;
  overflow: hidden;
  background: radial-gradient(circle at 30% 20%, #1f2937, #020617);
  position: relative;
  border: 1px solid rgba(55, 65, 81, 0.7);
}

.lesson-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.lesson-thumb-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom right,
    rgba(15, 23, 42, 0.3),
    rgba(15, 23, 42, 0.9)
  );
  display: flex;
  align-items: center;
  justify-content: center;
}

.lesson-play-icon {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  font-size: 11px;
}

.lesson-content {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.lesson-title {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.3;
}

.lesson-meta {
  font-size: 12px;
  color: var(--text-muted);
}

.lesson-actions {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 2px;
}

.tariffs-section {
  margin-top: 18px;
  border-top: 1px solid var(--divider);
  padding-top: 16px;
}

.tariffs-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.tariff-card {
  border-radius: 14px;
  background: linear-gradient(
    135deg,
    rgba(15, 23, 42, 0.98),
    rgba(15, 23, 42, 0.98)
  );
  border: 1px solid rgba(31, 41, 55, 0.9);
  padding: 10px 10px 11px;
}

.tariff-card-popular {
  position: relative;
  border-color: rgba(42, 171, 238, 0.9);
  box-shadow:
    0 0 0 1px rgba(15, 23, 42, 0.9),
    0 12px 26px rgba(37, 99, 235, 0.4);
  background: radial-gradient(circle at top, rgba(37, 99, 235, 0.25), rgba(15, 23, 42, 0.98));
}

.tariff-popular-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 2px 9px;
  border-radius: 999px;
  border: 1px solid rgba(250, 204, 21, 0.9);
  background: radial-gradient(circle at top, rgba(251, 191, 36, 0.25), rgba(15, 23, 42, 0.98));
  color: #facc15;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-bottom: 7px;
}

.tariff-image {
  width: 100%;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid rgba(55, 65, 81, 0.9);
  background: linear-gradient(
    135deg,
    rgba(31, 41, 55, 0.95),
    rgba(15, 23, 42, 0.98)
  );
  aspect-ratio: 16 / 6;
  margin-bottom: 8px;
}

.tariff-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.tariff-features {
  list-style: none;
  margin: 0 0 10px;
  padding: 0;
  font-size: 12px;
  color: var(--text-muted);
}

.tariff-features li {
  position: relative;
  padding-left: 14px;
  margin-bottom: 4px;
}

.tariff-features li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 7px;
  width: 4px;
  height: 4px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.9);
}

.footer-cta {
  border-top: 1px solid var(--divider);
  padding-top: 14px;
  margin-top: 8px;
}

.footer-cta-title {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 4px;
}

.footer-cta-text {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 10px;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  background: var(--overlay-bg);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 50;
  padding: 16px;
}

.modal-backdrop.active {
  display: flex;
}

.modal {
  width: 100%;
  max-width: 520px;
  background: #020617;
  border-radius: 20px;
  border: 1px solid rgba(148, 163, 184, 0.25);
  box-shadow:
    0 18px 40px rgba(15, 23, 42, 0.9),
    0 0 0 1px rgba(15, 23, 42, 0.9);
  padding: 14px 14px 16px;
}

@media (min-width: 480px) {
  .modal {
    padding: 16px 16px 18px;
  }
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
  gap: 10px;
}

.modal-title {
  font-size: 15px;
  font-weight: 600;
}

.modal-close {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 18px;
  padding: 4px;
  border-radius: 999px;
  line-height: 1;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-close:hover {
  background: rgba(15, 23, 42, 0.9);
  color: #f9fafb;
}

.modal-tabs {
  display: inline-flex;
  background: rgba(15, 23, 42, 0.96);
  border-radius: 999px;
  padding: 3px;
  border: 1px solid rgba(55, 65, 81, 0.9);
  margin-bottom: 10px;
}

.modal-tab {
  border-radius: 999px;
  border: none;
  padding: 5px 12px;
  font-size: 12px;
  font-weight: 500;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: background-color var(--transition-fast), color var(--transition-fast);
  display: flex;
  align-items: center;
  gap: 4px;
}

.modal-tab.active {
  background: var(--accent);
  color: #f9fafb;
}

.modal-video {
  position: relative;
  width: 100%;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid rgba(55, 65, 81, 0.9);
  background: #020617;
  aspect-ratio: 16 / 9;
}

.modal-video iframe {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}

.modal-hint {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 8px;
}

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

