/* Variables */
/* NOTE: index.html loads landing-critical.css + async landing-below-fold.css; other pages use landing.css */
:root {
  --bg-dark: #1f2229;
  --bg-darker: #191c22;
  --bg-code-editor: #2d2d2d;
  --bg-code-tab: #3a3a3a;
  --bg-code-tab-active: #2d2d2d;
  --bg-purple-light: #e8d5f2;
  --bg-secondary: #1f2229;
  --text-white: #ffffff;
  --text-gray: #cccccc;
  --text-black: #000000;
  --accent-orange: #6c7cff;
  --accent-orange-hover: #5468f2;
  --accent-hover: #5468f2;
  --accent-purple: #9d4edd;
  --accent-purple-light: #c77dff;
  --glow-orange: rgba(108, 124, 255, 0.3);
  --glow-purple: rgba(157, 78, 221, 0.3);
  --code-keyword: #ff9800;
  --code-function: #b2bdff;
  --code-string: #ff6b6b;
  --code-builtin: #4ec9b0;
  --code-variable: #9cdcfe;
  --text-primary: #ffffff;
}

/* Reset */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* Remove outline on mouse focus, but keep it for keyboard navigation */
button:focus:not(:focus-visible),
button:active:not(:focus-visible),
a:focus:not(:focus-visible),
a:active:not(:focus-visible),
input:focus:not(:focus-visible),
input:active:not(:focus-visible),
textarea:focus:not(:focus-visible),
textarea:active:not(:focus-visible),
select:focus:not(:focus-visible),
select:active:not(:focus-visible) {
  outline: none;
  -webkit-tap-highlight-color: transparent;
}

/* Show visible focus indicator for keyboard navigation */
button:focus-visible,
a:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: 2px solid var(--accent-orange);
  outline-offset: 2px;
  border-radius: 2px;
}

html {
  scroll-behavior: smooth;
  width: 100%;
  overflow-x: hidden;
}

/* Custom Scrollbar - РІ С†РІРµС‚ СЃР°Р№С‚Р° */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-corner {
  background: var(--bg-purple-light);
  border: none;
  outline: none;
}

::-webkit-scrollbar-track {
  background: var(--bg-purple-light);
  border-radius: 10px;
  border: none;
  outline: none;
}

::-webkit-scrollbar-thumb {
  background: var(--accent-orange);
  border-radius: 10px;
  border: none;
  outline: none;
  transition: background 0.3s ease;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--accent-orange-hover);
}

[data-theme="dark"] ::-webkit-scrollbar-track {
  background: #131416;
}

[data-theme="light"] ::-webkit-scrollbar-track {
  background: #f5f5f5;
}

/* Firefox scrollbar */
* {
  scrollbar-width: thin;
  scrollbar-color: var(--accent-orange) var(--bg-purple-light);
}

[data-theme="dark"] * {
  scrollbar-color: var(--accent-orange) #131416;
}

[data-theme="light"] * {
  scrollbar-color: var(--accent-orange) #f5f5f5;
}

body {
  margin: 0;
  padding: 0;
  background: var(--bg-purple-light);
  color: var(--text-black);
  font-family: "Roboto", -apple-system, BlinkMacSystemFont, "Segoe UI", Oxygen,
    Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  width: 100%;
  max-width: 100%;
  transition: background-color 0.3s ease, color 0.3s ease;
}

[data-theme="dark"] body {
  background: #131416;
  color: var(--text-white);
}

[data-theme="light"] body {
  background: #f5f5f5;
  color: var(--text-black);
}

.container {
  max-width: 1300px;
  margin: 0 auto;
  padding: 0 20px;
  width: 100%;
  box-sizing: border-box;
}

.header .container,
.hero-section-wrapper > .container {
  max-width: 1776px;
}

@media (max-width: 969px) {
  html {
    width: 100%;
    overflow-x: hidden;
  }

  .container {
    max-width: 100%;
    padding: 0 16px;
    width: 100%;
  }

  body {
    overflow-x: hidden;
    width: 100%;
    max-width: 100%;
  }

  * {
    max-width: 100%;
    box-sizing: border-box;
  }
}

@media (max-width: 769px) {
  .container {
    max-width: 100%;
    padding: 0 16px;
  }
}

/* Header */
.header {
  padding: 20px 0;
  background: transparent;
  border-bottom: none;
  position: relative;
  z-index: 1000;
  transition: background-color 0.3s ease;
}

.header-top-indicator {
  position: fixed;
  top: 0;
  left: 50vw;
  width: 24px;
  height: 2px;
  border-radius: 999px;
  background: var(--accent-orange);
  transform: translateX(-50%) scaleX(0);
  transform-origin: center;
  opacity: 0;
  pointer-events: none;
  z-index: 1200;
  display: none;
}

[data-theme="dark"] .header {
  background: transparent;
  border-bottom: none;
}

[data-theme="light"] .header {
  background: transparent;
  border-bottom: none;
}

/* Header with background when scrolled */
.header.scrolled {
  background: rgba(10, 22, 40, 0.95);
  backdrop-filter: blur(10px);
}

[data-theme="light"] .header.scrolled {
  background: rgba(245, 245, 245, 0.95);
  backdrop-filter: blur(10px);
}

.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  gap: 16px;
}

.header-nav {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 24px;
  gap: 24px;
}

.header-menu-wrapper {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-left: auto;
}

.header-menu-wrapper .theme-toggle-btn {
  margin-left: 0;
}

/* Header Navigation */

.header-nav-item {
  position: relative;
}

.header-nav-link {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  position: relative;
  --header-link-accent: var(--accent-orange);
  color: #ffffff;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  border: none;
  background: transparent;
  cursor: pointer;
  transition: color 0.32s cubic-bezier(0.22, 1, 0.36, 1),
    background-color 0.32s cubic-bezier(0.22, 1, 0.36, 1);
  border-radius: 6px;
  font-family: inherit;
  white-space: nowrap;
}

[data-theme="dark"] .header-nav-link {
  color: #ffffff;
}

[data-theme="light"] .header-nav-link {
  color: #333333;
}

.header-nav-link i {
  font-size: 10px;
  transition: transform 0.2s ease;
}

.header-nav-item-dropdown.active .header-nav-link i {
  transform: rotate(180deg);
}

.header-nav-link:hover {
  color: var(--header-link-accent);
}

[data-theme="light"] .header-nav-link:hover {
  background: transparent;
  color: var(--header-link-accent);
}

[data-theme="dark"] .header-nav-link:hover {
  background: transparent;
}

.header-nav-link--vacancies {
  --header-link-accent: #6c7cff;
}

.header-nav-link--trainer {
  --header-link-accent: #35d07f;
}

.header-nav-link--interview {
  --header-link-accent: #f2b230;
}

.header-nav-link--support {
  --header-link-accent: #49b3ff;
}

.header-nav-link:focus {
  outline: 2px solid var(--accent-orange);
  outline-offset: 2px;
}

/* Скрытый пункт меню (до доработки, не удалять) */
.header-nav-link--hidden {
  display: none !important;
  visibility: hidden !important;
}

/* questions.html временно скрыт: flex у .header-nav-link / .mobile-menu-nav a перебивает [hidden] */
.header-nav-link--trainer,
.header-nav a[href*="questions/questions.html"],
.header-menu a[href*="questions/questions.html"],
a.header-nav-link[href*="questions/questions.html"],
.mobile-menu-nav a[href*="questions/questions.html"],
.mobile-menu a[href*="questions/questions.html"] {
  display: none !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

/* SQL «Скоро» в мобильном меню главной */
.mobile-menu-nav__soon {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 16px 32px;
  color: rgba(255, 255, 255, 0.45);
  font-size: 24px;
  font-weight: 600;
  cursor: default;
  pointer-events: none;
  user-select: none;
}

.mobile-menu-nav__soon .header-nav-badge {
  opacity: 0.9;
}

/* BETA badge on nav links - правый край чуть выше, левый на месте */
.header-nav-badge {
  display: inline-flex;
  align-items: center;
  position: relative;
  top: 0;
  margin-left: -0.15em;
  padding: 1px 5px;
  background: var(--accent-orange);
  color: #000;
  font-size: 9px;
  font-weight: 800;
  border-radius: 3px;
  line-height: 1.3;
  letter-spacing: 0.04em;
  vertical-align: baseline;
  transform: rotate(-8deg);
  transform-origin: left center;
}

/* Header Dropdown Menu */
.header-dropdown-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 240px;
  background: #2d2d2d;
  border-radius: 8px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all 0.3s ease;
  z-index: 1000;
  overflow: hidden;
}

[data-theme="light"] .header-dropdown-menu {
  background: #f5f5f5;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
  border: 1px solid rgba(0, 0, 0, 0.1);
}

.header-nav-item-dropdown.active .header-dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.header-dropdown-menu-inner {
  padding: 8px 0;
}

.header-dropdown-item {
  display: block;
  padding: 12px 20px;
  color: var(--text-white);
  font-size: 14px;
  text-decoration: none;
  transition: all 0.2s ease;
  border-left: 3px solid transparent;
}

[data-theme="light"] .header-dropdown-item {
  color: var(--text-black);
}

.header-dropdown-item:hover {
  background: transparent;
  border-left-color: var(--accent-orange);
  color: var(--accent-orange);
}

[data-theme="light"] .header-dropdown-item:hover {
  background: transparent;
}

.header-dropdown-item:focus {
  outline: none;
  background: transparent;
  border-left-color: var(--accent-orange);
}

[data-theme="light"] .header-dropdown-item:focus {
  background: transparent;
}

.header-burger-wrapper {
  position: relative;
  display: none; /* Hidden for future use */
  align-items: center;
}

/* Theme Toggle Button - скрыт: светлая тема пока не доработана */
.theme-toggle-btn {
  width: 40px;
  height: 40px;
  display: none !important;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 2px solid #8ea5ff;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s ease;
  visibility: hidden !important;
  pointer-events: none !important;
}

.theme-toggle-btn i {
  font-size: 18px;
  color: #8ea5ff;
  transition: none;
}

.theme-toggle-btn:hover {
  background: transparent;
  transform: none;
  box-shadow: none;
}

[data-theme="light"] .theme-toggle-btn {
  background: transparent;
  border: 2px solid #8ea5ff;
}

[data-theme="light"] .theme-toggle-btn i {
  color: #8ea5ff;
}

/* Animation Toggle Switch */
.animation-toggle-switch {
  position: relative;
  width: 40px;
  height: 23px;
  background: rgba(108, 124, 255, 0.3);
  border: none;
  border-radius: 12px;
  cursor: pointer;
  padding: 0;
  outline: none;
  -webkit-tap-highlight-color: transparent;
  display: flex;
  align-items: center;
  flex-shrink: 0;
  transition: background-color 0.3s ease;
}

.animation-toggle-switch:hover {
  background: rgba(108, 124, 255, 0.46);
}

.animation-toggle-switch[aria-pressed="true"] {
  background: var(--accent-orange);
}

.animation-toggle-switch[aria-pressed="true"]:hover {
  background: var(--accent-orange-hover);
}

.animation-toggle-track {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: 12px;
  overflow: hidden;
}

.animation-toggle-thumb {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 17px;
  height: 17px;
  background: #ffffff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
  z-index: 2;
}

.animation-toggle-switch[aria-pressed="true"] .animation-toggle-thumb {
  transform: translateX(17px);
}

.animation-toggle-thumb i {
  font-size: 9px;
  color: var(--accent-orange);
  transition: color 0.3s ease, transform 0.3s ease;
  display: block;
  line-height: 1;
}

.animation-toggle-switch[aria-pressed="true"] .animation-toggle-thumb i {
  color: var(--accent-orange);
}

/* РџРѕРєР°Р·С‹РІР°РµРј play РєРѕРіРґР° РІС‹РєР»СЋС‡РµРЅРѕ, pause РєРѕРіРґР° РІРєР»СЋС‡РµРЅРѕ */
.animation-toggle-thumb .fa-pause {
  display: none;
}

.animation-toggle-thumb .fa-play {
  display: block;
  margin-left: 1px;
}

.animation-toggle-switch[aria-pressed="true"]
  .animation-toggle-thumb
  .fa-pause {
  display: block;
}

.animation-toggle-switch[aria-pressed="true"] .animation-toggle-thumb .fa-play {
  display: none;
}

.animation-toggle-switch:focus {
  outline: none;
  box-shadow: none;
}

.animation-toggle-switch:focus-visible {
  outline: none;
  box-shadow: none;
}

/* Header Language Switch */
.header-language-switch {
  position: relative;
  flex-shrink: 0;
}

.header-language-switch__summary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  user-select: none;
  border: none;
  background: transparent;
  padding: 0;
  font: inherit;
}

.header-language-switch__current {
  min-width: 62px;
  height: 40px;
  padding: 0 8px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: none;
  border-radius: 999px;
  background: transparent;
}

.header-language-switch__flag {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.header-language-switch__flag-img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.header-language-switch__label {
  font-size: 14px;
  font-weight: 600;
  color: #f5f7ff;
  letter-spacing: 0.02em;
}

.header-language-switch__toggle {
  width: 24px;
  height: 24px;
  border-radius: 999px;
  border: none;
  background: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #d7dcff;
  font-size: 10px;
  transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1),
    color 0.2s ease !important;
  will-change: transform;
}

.header-language-switch.is-open .header-language-switch__toggle {
  transform: rotate(180deg);
}

.header-language-switch__dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 168px;
  margin: 0;
  padding: 8px;
  list-style: none;
  border-radius: 10px;
  border: none;
  background: #403e4c;
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.35);
  z-index: 1004;
  transform-origin: top right;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-8px) scale(0.98);
  transition: opacity 0.38s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.38s cubic-bezier(0.16, 1, 0.3, 1),
    visibility 0s linear 0.38s !important;
  will-change: opacity, transform;
}

.header-language-switch > .header-language-switch__dropdown {
  display: block;
}

.header-language-switch.is-open > .header-language-switch__dropdown {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0) scale(1);
  transition: opacity 0.38s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.38s cubic-bezier(0.16, 1, 0.3, 1),
    visibility 0s linear 0s !important;
  transition-delay: 0.08s, 0.08s, 0s !important;
}

.header-language-switch:not(.is-open) > .header-language-switch__dropdown {
  transition: opacity 0.28s cubic-bezier(0.4, 0, 1, 1),
    transform 0.28s cubic-bezier(0.4, 0, 1, 1),
    visibility 0s linear 0s !important;
}

.header-language-switch__option {
  width: 100%;
  min-height: 38px;
  border: none;
  background: transparent;
  color: #e7ebff;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  cursor: pointer;
  font-size: 16px;
  font-weight: 500;
  text-align: left;
}

.header-language-switch__option:hover {
  background: rgba(255, 255, 255, 0.08);
}

.header-language-switch__option--active {
  color: #ffffff;
  font-weight: 700;
}

.header-language-switch__option--disabled,
.header-language-switch__option[disabled],
.header-language-switch__option[aria-disabled="true"] {
  color: rgba(231, 235, 255, 0.38);
  cursor: not-allowed;
  opacity: 0.78;
  pointer-events: none;
}

.header-language-switch__option--disabled:hover,
.header-language-switch__option[disabled]:hover,
.header-language-switch__option[aria-disabled="true"]:hover {
  background: transparent;
}

.header-language-switch__option--disabled .header-language-switch__option-label,
.header-language-switch__option[disabled] .header-language-switch__option-label {
  color: rgba(231, 235, 255, 0.42);
}

.header-language-switch__option-badge {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  position: relative;
  top: 0;
  padding: 1px 5px;
  background: var(--accent-orange, #ff8a3d);
  color: #000;
  font-size: 9px;
  font-weight: 800;
  border-radius: 3px;
  line-height: 1.3;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  transform: rotate(-8deg);
  transform-origin: center center;
  flex-shrink: 0;
}

.header-language-switch__option-badge--beta {
  background: var(--accent-orange, #ff8a3d);
  color: #000;
}

.header-language-switch__option-badge--soon {
  background: var(--accent-orange, #ff8a3d);
  color: #000;
}

.header-language-switch__summary:focus-visible,
.header-language-switch__option:focus-visible {
  outline: 2px solid rgba(142, 165, 255, 0.8);
  outline-offset: 2px;
}

[data-theme="light"] .header-language-switch__current {
  border-color: transparent;
  background: transparent;
}

[data-theme="light"] .header-language-switch__label {
  color: #2a315a;
}

[data-theme="light"] .header-language-switch__toggle {
  border-color: transparent;
  background: transparent;
  color: #2a315a;
}

[data-theme="light"] .header-language-switch__dropdown {
  border: none;
  background: #403e4c;
  box-shadow: 0 14px 32px rgba(17, 28, 63, 0.18);
}

[data-theme="light"] .header-language-switch__option {
  color: #2d3562;
}

[data-theme="light"] .header-language-switch__option:hover {
  background: rgba(32, 54, 117, 0.08);
}

/* Global animation disable - when animations are turned off */
.animations-disabled *,
.animations-disabled *::before,
.animations-disabled *::after {
  animation-play-state: paused !important;
  transition: none !important;
}

/* Keep essential transitions for UI elements */
.animations-disabled .header,
.animations-disabled .theme-toggle-btn,
.animations-disabled .animation-toggle-switch,
.animations-disabled .animation-toggle-thumb,
.animations-disabled .mobile-menu,
.animations-disabled .mobile-menu-overlay,
.animations-disabled .faq-answer,
.animations-disabled .header-nav-link,
.animations-disabled .header-donate-btn,
.animations-disabled .header-quick-sale,
.animations-disabled .start-learning-btn,
.animations-disabled .subscribe-btn,
.animations-disabled .course-card,
.animations-disabled .site-sidebar,
.animations-disabled .site-sidebar__inner,
.animations-disabled .site-sidebar__logo,
.animations-disabled .site-sidebar__logo-text,
.animations-disabled .site-sidebar__section,
.animations-disabled .site-sidebar__link,
.animations-disabled .site-sidebar__link-text,
.animations-disabled .site-sidebar__promo,
.animations-disabled .site-sidebar__collapse i,
.animations-disabled body.has-site-sidebar,
.animations-disabled button,
.animations-disabled a {
  transition: background-color 0.2s ease, color 0.2s ease, opacity 0.2s ease,
    transform 0.2s ease !important;
}

.animations-disabled .site-sidebar {
  transition: width 0.75s cubic-bezier(0.4, 0, 0.2, 1), background 0.3s ease !important;
}

.animations-disabled body.has-site-sidebar {
  transition: padding-left 0.75s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

/* Индикатор «онлайн» в поддержке - медленный, не отключаем вместе с декором */
.animations-disabled .site-sidebar__support-pulse::before,
.animations-disabled .site-sidebar__support-pulse::after,
.animations-disabled .site-sidebar__support-pulse-dot {
  animation-play-state: running !important;
}

/* РљРЅРѕРїРєР° В«РЅР°РІРµСЂС…В»: РїСЂРё РѕС‚РєР»СЋС‡С‘РЅРЅС‹С… Р°РЅРёРјР°С†РёСЏС… - РєРѕСЂРѕС‡Рµ, Р±РµР· В«РїСЂСѓР¶РёРЅС‹В» */
.animations-disabled .scroll-to-top {
  transition: opacity 2.4s ease-in-out, transform 2.4s ease-in-out, visibility 0s linear 2.4s !important;
}

.animations-disabled .scroll-to-top.visible {
  transition: opacity 2.4s ease-in-out, transform 2.4s ease-in-out, visibility 0s linear 0s !important;
}

/* Stop iframes (videos) when animations disabled */
.animations-disabled iframe {
  pointer-events: none;
}

/* ===== Sections above snow (z-index > 9999) ===== */
.database-categories,
.terms-intro,
.terms-section,
.terms-content,
.course-card,
.payment-section,
.payment-card,
.payment-cards,
.payment-methods,
.donate-wrapper,
.donate-header,
.subscribe-box,
.lesson-container,
.lesson-breadcrumb,
.lesson-header,
.lesson-content,
.lesson-block,
.lesson-navigation {
  position: relative;
  z-index: 10000;
}

.header-donate-btn {
  padding: 10px 20px;
  background: var(--accent-orange);
  color: #333;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  border-radius: 8px;
  transition:
    background-color 0.55s ease,
    color 0.55s ease,
    box-shadow 0.55s ease,
    transform 0.55s ease;
  font-family: inherit;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  white-space: nowrap;
}

.header-donate-btn i {
  font-size: 14px;
}

.header-donate-btn:hover {
  background: var(--accent-orange-hover);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(108, 124, 255, 0.3);
}

.header-donate-btn:focus {
  outline: none;
}

.header-donate-btn:active {
  transform: translateY(0);
}

.header-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 18px;
  font-weight: 700;
  color: var(--text-black);
  letter-spacing: 0.5px;
  text-decoration: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  outline: none;
}

.header-logo:hover,
.header-logo:active,
.header-logo:focus {
  opacity: 1;
  color: var(--text-black);
}

.header-logo:active {
  -webkit-tap-highlight-color: transparent;
}

[data-theme="dark"] .header-logo:hover,
[data-theme="dark"] .header-logo:active,
[data-theme="dark"] .header-logo:focus {
  color: var(--text-white);
}

[data-theme="dark"] .header-logo {
  color: var(--text-white);
}

[data-theme="light"] .header-logo {
  color: var(--text-black);
}

[data-theme="light"] .header-logo:hover,
[data-theme="light"] .header-logo:active,
[data-theme="light"] .header-logo:focus {
  color: var(--text-black);
}

/* <picture> иначе выше img и ломает выравнивание текста / обрезает логотип */
.header-logo picture {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  line-height: 0;
}

.header-logo-img {
  display: block;
  height: 40px;
  width: 40px;
  object-fit: contain;
  border-radius: 6px;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
  pointer-events: none;
}

.header-logo-text {
  display: inline-flex;
  align-items: center;
  line-height: 1;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}

.header-quick-sale {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-shrink: 0;
  min-height: 42px;
  padding: 9px 18px;
  border-radius: 10px;
  background: #c6f34a;
  color: #0b0f14;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.04em;
  line-height: 1;
  text-transform: uppercase;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: 0 0 0 1px rgba(198, 243, 74, 0.35);
  transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
  position: relative;
  z-index: 2;
}

.header-quick-sale:hover,
.header-quick-sale:focus {
  background: #d4ff63;
  color: #0b0f14;
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(198, 243, 74, 0.28);
}

.header-quick-sale:active {
  transform: translateY(0);
}

.header-quick-sale__icon {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.header-quick-sale__text {
  display: inline-block;
}

@media (max-width: 768px) {
  .header-quick-sale {
    min-height: 38px;
    padding: 8px 12px;
    font-size: 11px;
    z-index: 2;
  }
}

@media (max-width: 480px) {
  .header-quick-sale {
    min-height: 36px;
    padding: 7px 10px;
    gap: 6px;
  }

  .header-quick-sale__icon {
    width: 14px;
    height: 14px;
  }
}

.header-menu-btn {
  display: flex;
  flex-direction: column;
  gap: 4px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 8px;
  color: var(--text-black);
}

.menu-icon {
  width: 24px;
  height: 2px;
  /* Сайт по умолчанию тёмный — бургер белый */
  background: #ffffff;
  transition: all 0.3s ease;
}

[data-theme="light"] .header-burger-wrapper .menu-icon,
[data-theme="light"] .header-menu-btn .menu-icon {
  background: #000000;
}

.header-menu-btn:hover .menu-icon {
  background: var(--accent-orange);
}

[data-theme="light"] .header-menu-btn:hover .menu-icon,
[data-theme="light"] .header-menu-btn.active:hover .menu-icon {
  background: var(--accent-orange);
}

.header-menu-btn:focus {
  outline: none;
}

.header-menu-btn.active .menu-icon:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.header-menu-btn.active .menu-icon:nth-child(2) {
  opacity: 0;
}

.header-menu-btn.active .menu-icon:nth-child(3) {
  transform: rotate(-45deg) translate(7px, -6px);
}

/* Dropdown Menu */
.dropdown-menu {
  position: absolute;
  top: calc(100% + 27px);
  right: 50%;
  transform: translateX(50%);
  width: 240px;
  background: #2d2d2d;
  z-index: 1000;
  display: none;
  border-radius: 8px;
  overflow: visible;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.dropdown-menu::before {
  content: "";
  position: absolute;
  top: -8px;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 0;
  border-left: 8px solid transparent;
  border-right: 8px solid transparent;
  border-bottom: 8px solid #2d2d2d;
}

.dropdown-menu.active {
  display: block;
}

.dropdown-menu-main {
  width: 100%;
  background: #2d2d2d;
  padding: 8px 0;
  overflow-y: auto;
  max-height: 70vh;
  border-radius: 8px;
}

.dropdown-menu-item {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: 14px 20px;
  color: var(--text-white);
  font-size: 15px;
  cursor: pointer;
  transition: all 0.2s ease;
  border-left: 3px solid transparent;
}

.dropdown-menu-item:hover {
  background: rgba(255, 255, 255, 0.05);
}

.dropdown-menu-item-active {
  background: rgba(255, 255, 255, 0.08);
  border-left-color: var(--accent-orange);
}

.dropdown-menu-arrow {
  font-size: 10px;
  color: #858585;
  width: 12px;
  display: inline-block;
}

.dropdown-menu-item-active .dropdown-menu-arrow {
  color: var(--text-white);
}

/* Main */
.main {
  padding: 0;
  position: relative;
}

/* Hero Section Background */
.hero-section-wrapper {
  position: relative;
  background: linear-gradient(
    135deg,
    #0a1628 0%,
    #0d2137 25%,
    #0f2847 50%,
    #0a1f3a 75%,
    #061220 100%
  );
  overflow: hidden;
}

.hero-section-wrapper::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(
      ellipse 80% 50% at 20% 40%,
      rgba(79, 195, 247, 0.15) 0%,
      transparent 50%
    ),
    radial-gradient(
      ellipse 60% 40% at 80% 60%,
      rgba(108, 124, 255, 0.1) 0%,
      transparent 50%
    ),
    radial-gradient(
      ellipse 50% 30% at 50% 80%,
      rgba(156, 220, 254, 0.1) 0%,
      transparent 50%
    );
  pointer-events: none;
}

[data-theme="light"] .hero-section-wrapper {
  background: linear-gradient(
    135deg,
    #e8f4fc 0%,
    #d4ebf7 25%,
    #c1e2f3 50%,
    #d4ebf7 75%,
    #e8f4fc 100%
  );
}

[data-theme="light"] .hero-section-wrapper::before {
  background: radial-gradient(
      ellipse 80% 50% at 20% 40%,
      rgba(79, 195, 247, 0.2) 0%,
      transparent 50%
    ),
    radial-gradient(
      ellipse 60% 40% at 80% 60%,
      rgba(108, 124, 255, 0.15) 0%,
      transparent 50%
    );
}

/* Grid pattern overlay */
.hero-grid-pattern {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: linear-gradient(
      rgba(79, 195, 247, 0.03) 1px,
      transparent 1px
    ),
    linear-gradient(90deg, rgba(79, 195, 247, 0.03) 1px, transparent 1px);
  background-size: 50px 50px;
  pointer-events: none;
}

[data-theme="light"] .hero-grid-pattern {
  background-image: linear-gradient(
      rgba(0, 100, 150, 0.05) 1px,
      transparent 1px
    ),
    linear-gradient(90deg, rgba(0, 100, 150, 0.05) 1px, transparent 1px);
}

/* Hero Section */
.hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  padding: 60px 0;
  min-height: 70vh;
  position: relative;
  overflow: hidden;
}

/* Hero Background Animation Container */
.hero-bg-animation {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  overflow: hidden;
  z-index: 0;
  pointer-events: none;
}

/* Floating Code Elements */
.floating-elements {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.floating-element {
  position: absolute;
  font-family: "Consolas", "Monaco", "Courier New", monospace;
  font-weight: 600;
  opacity: 0;
  animation: floatUp 12s linear infinite;
  pointer-events: none;
  text-shadow: 0 0 20px currentColor;
  filter: blur(0px);
}

/* Р Р°Р·РЅС‹Рµ СЂР°Р·РјРµСЂС‹ Рё С†РІРµС‚Р° СЌР»РµРјРµРЅС‚РѕРІ */
.floating-element--bracket {
  font-size: 48px;
  color: rgba(108, 124, 255, 0.62);
}

.floating-element--tag {
  font-size: 32px;
  color: rgba(79, 195, 247, 0.7);
}

.floating-element--symbol {
  font-size: 40px;
  color: rgba(255, 198, 41, 0.6);
}

.floating-element--code {
  font-size: 18px;
  color: rgba(156, 220, 254, 0.5);
  background: rgba(30, 30, 30, 0.4);
  padding: 8px 16px;
  border-radius: 8px;
  backdrop-filter: blur(4px);
}

.floating-element--icon {
  font-size: 36px;
  color: rgba(78, 201, 176, 0.6);
}

.floating-element--binary {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.3);
  letter-spacing: 2px;
}

/* Animation keyframes */
@keyframes floatUp {
  0% {
    transform: translateY(100vh) rotate(0deg) scale(0.5);
    opacity: 0;
  }
  10% {
    opacity: 1;
  }
  90% {
    opacity: 1;
  }
  100% {
    transform: translateY(-100px) rotate(360deg) scale(1);
    opacity: 0;
  }
}

@keyframes floatUpSlow {
  0% {
    transform: translateY(100vh) rotate(0deg) translateX(0);
    opacity: 0;
  }
  10% {
    opacity: 0.8;
  }
  50% {
    transform: translateY(50vh) rotate(180deg) translateX(30px);
  }
  90% {
    opacity: 0.8;
  }
  100% {
    transform: translateY(-100px) rotate(360deg) translateX(-30px);
    opacity: 0;
  }
}

@keyframes pulse {
  0%,
  100% {
    transform: scale(1);
    opacity: 0.6;
  }
  50% {
    transform: scale(1.2);
    opacity: 1;
  }
}

@keyframes drift {
  0% {
    transform: translateX(0) translateY(0);
  }
  25% {
    transform: translateX(20px) translateY(-10px);
  }
  50% {
    transform: translateX(0) translateY(-20px);
  }
  75% {
    transform: translateX(-20px) translateY(-10px);
  }
  100% {
    transform: translateX(0) translateY(0);
  }
}

/* РџРѕР·РёС†РёРё СЌР»РµРјРµРЅС‚РѕРІ */
.floating-element:nth-child(1) {
  left: 5%;
  animation-delay: 0s;
  animation-duration: 15s;
}
.floating-element:nth-child(2) {
  left: 15%;
  animation-delay: 2s;
  animation-duration: 12s;
}
.floating-element:nth-child(3) {
  left: 25%;
  animation-delay: 4s;
  animation-duration: 18s;
}
.floating-element:nth-child(4) {
  left: 35%;
  animation-delay: 1s;
  animation-duration: 14s;
}
.floating-element:nth-child(5) {
  left: 45%;
  animation-delay: 3s;
  animation-duration: 16s;
}
.floating-element:nth-child(6) {
  left: 55%;
  animation-delay: 5s;
  animation-duration: 13s;
}
.floating-element:nth-child(7) {
  left: 65%;
  animation-delay: 2.5s;
  animation-duration: 17s;
}
.floating-element:nth-child(8) {
  left: 75%;
  animation-delay: 0.5s;
  animation-duration: 11s;
}
.floating-element:nth-child(9) {
  left: 85%;
  animation-delay: 4.5s;
  animation-duration: 15s;
}
.floating-element:nth-child(10) {
  left: 92%;
  animation-delay: 1.5s;
  animation-duration: 14s;
}
.floating-element:nth-child(11) {
  left: 10%;
  animation-delay: 6s;
  animation-duration: 16s;
}
.floating-element:nth-child(12) {
  left: 30%;
  animation-delay: 7s;
  animation-duration: 13s;
}
.floating-element:nth-child(13) {
  left: 50%;
  animation-delay: 8s;
  animation-duration: 15s;
}
.floating-element:nth-child(14) {
  left: 70%;
  animation-delay: 9s;
  animation-duration: 12s;
}
.floating-element:nth-child(15) {
  left: 90%;
  animation-delay: 10s;
  animation-duration: 14s;
}
.floating-element:nth-child(16) {
  left: 20%;
  animation-delay: 3.5s;
  animation-duration: 17s;
}
.floating-element:nth-child(17) {
  left: 40%;
  animation-delay: 5.5s;
  animation-duration: 11s;
}
.floating-element:nth-child(18) {
  left: 60%;
  animation-delay: 7.5s;
  animation-duration: 18s;
}
.floating-element:nth-child(19) {
  left: 80%;
  animation-delay: 2s;
  animation-duration: 13s;
}
.floating-element:nth-child(20) {
  left: 95%;
  animation-delay: 4s;
  animation-duration: 16s;
}

/* Code Rain Effect */
.code-rain {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.code-column {
  position: absolute;
  top: -100%;
  font-family: "Consolas", monospace;
  font-size: 14px;
  color: rgba(78, 201, 176, 0.4);
  animation: codeRain 8s linear infinite;
  white-space: nowrap;
  writing-mode: vertical-rl;
  text-orientation: mixed;
}

@keyframes codeRain {
  0% {
    transform: translateY(-100%);
    opacity: 0;
  }
  10% {
    opacity: 0.5;
  }
  90% {
    opacity: 0.5;
  }
  100% {
    transform: translateY(100vh);
    opacity: 0;
  }
}

/* Glowing orbs */
.glow-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  animation: orbFloat 20s ease-in-out infinite;
  pointer-events: none;
}

.glow-orb--1 {
  width: 300px;
  height: 300px;
  background: radial-gradient(
    circle,
    rgba(79, 195, 247, 0.3) 0%,
    transparent 70%
  );
  top: 10%;
  right: 10%;
  animation-delay: 0s;
}

.glow-orb--2 {
  width: 400px;
  height: 400px;
  background: radial-gradient(
    circle,
    rgba(108, 124, 255, 0.2) 0%,
    transparent 70%
  );
  bottom: 20%;
  right: 30%;
  animation-delay: 5s;
}

.glow-orb--3 {
  width: 250px;
  height: 250px;
  background: radial-gradient(
    circle,
    rgba(156, 220, 254, 0.25) 0%,
    transparent 70%
  );
  top: 40%;
  right: 50%;
  animation-delay: 10s;
}

@keyframes orbFloat {
  0%,
  100% {
    transform: translate(0, 0) scale(1);
  }
  25% {
    transform: translate(30px, -30px) scale(1.1);
  }
  50% {
    transform: translate(-20px, 20px) scale(0.9);
  }
  75% {
    transform: translate(20px, 30px) scale(1.05);
  }
}

/* Terminal Window Animation */
.animated-terminal {
  position: absolute;
  right: 5%;
  top: 50%;
  transform: translateY(-50%);
  width: 600px;
  background: linear-gradient(135deg, #1e1e1e 0%, #252526 100%);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 25px 80px rgba(0, 0, 0, 0.6),
    0 0 0 1px rgba(255, 255, 255, 0.05), inset 0 1px 0 rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(20px);
  animation: terminalFloat 6s ease-in-out infinite;
  z-index: 10;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

@keyframes terminalFloat {
  0%,
  100% {
    transform: translateY(-50%) translateX(0) rotate(0deg);
  }
  25% {
    transform: translateY(-51%) translateX(-5px) rotate(0.5deg);
  }
  50% {
    transform: translateY(-52%) translateX(-10px) rotate(0deg);
  }
  75% {
    transform: translateY(-51%) translateX(-5px) rotate(-0.5deg);
  }
}

.animated-terminal__header {
  background: linear-gradient(180deg, #2d2d2d 0%, #252526 100%);
  padding: 0 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px 16px 0 0;
  height: 52px;
  position: relative;
  box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.3);
}

.animated-terminal__file-tab {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(30, 30, 30, 0.6);
  padding: 8px 18px;
  height: 100%;
  border-top-left-radius: 16px;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  flex: 1;
  transition: background 0.2s ease;
  position: relative;
}

.animated-terminal__file-tab::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(79, 195, 247, 0.3),
    transparent
  );
  opacity: 0;
  transition: opacity 0.3s ease;
}

.animated-terminal__file-tab:hover::before {
  opacity: 1;
}

.animated-terminal__file-icon {
  color: #4fc3f7;
  font-size: 15px;
  filter: drop-shadow(0 0 4px rgba(79, 195, 247, 0.4));
  transition: all 0.2s ease;
}

.animated-terminal__file-tab:hover .animated-terminal__file-icon {
  color: #81d4fa;
  filter: drop-shadow(0 0 6px rgba(79, 195, 247, 0.6));
}

.animated-terminal__file-name {
  color: #e0e0e0;
  font-size: 13px;
  font-weight: 500;
  font-family: "Segoe UI", "Consolas", "Monaco", monospace;
  letter-spacing: 0.3px;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.animated-terminal__dots {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-shrink: 0;
}

.animated-terminal__dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  transition: all 0.2s ease;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.animated-terminal__dot--red {
  background: #ff5f56;
  box-shadow: 0 0 8px rgba(255, 95, 86, 0.3);
}

.animated-terminal__dot--yellow {
  background: #6c7cff;
  box-shadow: 0 0 8px rgba(108, 124, 255, 0.3);
}

.animated-terminal__dot--green {
  background: #27ca40;
  box-shadow: 0 0 8px rgba(39, 202, 64, 0.3);
}

.animated-terminal__dot:hover {
  transform: scale(1.1);
  opacity: 0.8;
}

.animated-terminal__title {
  flex: 1;
  text-align: center;
  color: #858585;
  font-size: 13px;
  font-family: "Consolas", monospace;
}

.animated-terminal__run-btn {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: linear-gradient(135deg, #27ca40 0%, #2edc4a 100%);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 13px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 12px rgba(39, 202, 64, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
  position: relative;
  overflow: hidden;
}

.animated-terminal__run-btn::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transform: translate(-50%, -50%);
  transition: width 0.4s ease, height 0.4s ease;
}

.animated-terminal__run-btn:hover {
  background: linear-gradient(135deg, #2edc4a 0%, #4ade80 100%);
  transform: translateY(-2px) scale(1.05);
  box-shadow: 0 6px 20px rgba(39, 202, 64, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.animated-terminal__run-btn:hover::before {
  width: 200%;
  height: 200%;
}

.animated-terminal__run-btn:active {
  transform: translateY(0) scale(1);
  box-shadow: 0 2px 8px rgba(39, 202, 64, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.animated-terminal__run-btn i {
  position: relative;
  z-index: 1;
  transition: transform 0.2s ease;
}

.animated-terminal__run-btn:hover i {
  transform: scale(1.1);
}

/* Light theme for terminal header */
[data-theme="light"] .animated-terminal {
  background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
  box-shadow: 0 25px 80px rgba(0, 0, 0, 0.15), 0 0 0 1px rgba(0, 0, 0, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(0, 0, 0, 0.1);
}

[data-theme="light"] .animated-terminal__header {
  background: linear-gradient(180deg, #f5f5f5 0%, #eeeeee 100%);
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
  box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.05);
}

[data-theme="light"] .animated-terminal__file-tab {
  background: rgba(255, 255, 255, 0.8);
  border-right: 1px solid rgba(0, 0, 0, 0.1);
}

[data-theme="light"] .animated-terminal__file-icon {
  color: #1976d2;
  filter: drop-shadow(0 0 4px rgba(25, 118, 210, 0.3));
}

[data-theme="light"]
  .animated-terminal__file-tab:hover
  .animated-terminal__file-icon {
  color: #1565c0;
  filter: drop-shadow(0 0 6px rgba(25, 118, 210, 0.5));
}

[data-theme="light"] .animated-terminal__file-name {
  color: #212121;
}

[data-theme="light"] .animated-terminal__body {
  background: #ffffff;
}

[data-theme="light"] .terminal-line-numbers {
  background: linear-gradient(180deg, #fafafa 0%, #f5f5f5 100%);
  color: #999999;
  box-shadow: inset -1px 0 0 rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .terminal-line-numbers span {
  color: #999999;
}

[data-theme="light"] .terminal-line-numbers span:hover {
  color: #1976d2;
  text-shadow: 0 0 6px rgba(25, 118, 210, 0.2);
}

[data-theme="light"] .terminal-line-numbers span::before {
  background: rgba(25, 118, 210, 0.3);
}

[data-theme="light"] .terminal-line-numbers::after {
  background: linear-gradient(
    180deg,
    transparent 0%,
    rgba(25, 118, 210, 0.2) 10%,
    rgba(25, 118, 210, 0.25) 50%,
    rgba(25, 118, 210, 0.2) 90%,
    transparent 100%
  );
  box-shadow: 0 0 4px rgba(25, 118, 210, 0.15);
}

[data-theme="light"] .terminal-code {
  background: #ffffff;
  color: #212121;
}

.animated-terminal__output-popup {
  position: absolute;
  top: 60px;
  right: 20px;
  transform: translateY(-10px) scale(0.9);
  background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
  border-radius: 10px;
  padding: 14px 18px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5), 0 0 20px rgba(76, 175, 80, 0.2);
  border: 1px solid rgba(76, 175, 80, 0.4);
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  z-index: 100;
  white-space: nowrap;
  pointer-events: none;
}

.animated-terminal__output-popup::before {
  content: "в–¶ Р’С‹РІРѕРґ:";
  display: block;
  font-size: 10px;
  color: #888;
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.animated-terminal__output-popup.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

.animated-terminal__output-text {
  font-family: "Consolas", "Monaco", "Courier New", monospace;
  font-size: 15px;
  color: #4caf50;
  text-shadow: 0 0 10px rgba(76, 175, 80, 0.5);
  animation: textGlow 1.5s ease-in-out infinite alternate;
}

@keyframes textGlow {
  0% {
    text-shadow: 0 0 10px rgba(76, 175, 80, 0.5);
  }
  100% {
    text-shadow: 0 0 20px rgba(76, 175, 80, 0.8),
      0 0 30px rgba(76, 175, 80, 0.4);
  }
}

[data-theme="light"] .animated-terminal__output-popup {
  background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1), 0 0 20px rgba(46, 125, 50, 0.1);
  border: 1px solid rgba(46, 125, 50, 0.3);
}

[data-theme="light"] .animated-terminal__output-popup::before {
  color: #666;
}

[data-theme="light"] .animated-terminal__output-text {
  color: #2e7d32;
  text-shadow: 0 0 10px rgba(46, 125, 50, 0.3);
}

.animated-terminal__body {
  padding: 20px;
  min-height: 280px;
  font-family: "Consolas", "Monaco", "Courier New", monospace;
  font-size: 14px;
  line-height: 1.8;
}

.terminal-line {
  opacity: 0;
  animation: typeLine 0.5s ease forwards;
  margin-bottom: 4px;
}

.terminal-line--prompt {
  color: #4ec9b0;
}

.terminal-line--command {
  color: #9cdcfe;
}

.terminal-line--output {
  color: #d4d4d4;
}

.terminal-line--success {
  color: #4caf50;
}

.terminal-line--highlight {
  color: #8ea5ff;
}

.terminal-line:nth-child(1) {
  animation-delay: 0.5s;
}
.terminal-line:nth-child(2) {
  animation-delay: 1.2s;
}
.terminal-line:nth-child(3) {
  animation-delay: 1.9s;
}
.terminal-line:nth-child(4) {
  animation-delay: 2.6s;
}
.terminal-line:nth-child(5) {
  animation-delay: 3.3s;
}
.terminal-line:nth-child(6) {
  animation-delay: 4s;
}
.terminal-line:nth-child(7) {
  animation-delay: 4.7s;
}
.terminal-line:nth-child(8) {
  animation-delay: 5.4s;
}
.terminal-line:nth-child(9) {
  animation-delay: 6.1s;
}
.terminal-line:nth-child(10) {
  animation-delay: 6.8s;
}

@keyframes typeLine {
  0% {
    opacity: 0;
    transform: translateX(-10px);
  }
  100% {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Cursor blink */
.terminal-cursor {
  display: inline-block;
  width: 8px;
  height: 16px;
  background: #4ec9b0;
  animation: cursorBlink 1s step-end infinite;
  vertical-align: middle;
  margin-left: 2px;
}

@keyframes cursorBlink {
  0%,
  50% {
    opacity: 1;
  }
  51%,
  100% {
    opacity: 0;
  }
}

/* Floating Code Cards */
.floating-code-card {
  position: absolute;
  background: rgba(30, 30, 30, 0.95);
  border-radius: 8px;
  padding: 10px 14px;
  font-family: "Consolas", monospace;
  font-size: 12px;
  color: #d4d4d4;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4), 0 0 20px rgba(79, 195, 247, 0.1);
  border: 1px solid rgba(79, 195, 247, 0.2);
  backdrop-filter: blur(8px);
  animation: cardFloat 8s ease-in-out infinite;
  z-index: 50;
  white-space: nowrap;
  max-width: calc(100% - 20px);
  overflow: hidden;
  text-overflow: ellipsis;
}

.floating-code-card--1 {
  top: 45%;
  right: 10px;
  transform: translateY(-50%);
  animation: cardFloat 6s linear infinite !important;
  animation-delay: 0s;
}

.floating-code-card--2 {
  top: 65%;
  right: 10px;
  transform: translateY(-50%);
  animation: cardFloatReverse 6s linear infinite !important;
  animation-delay: 0s;
}

.floating-code-card--3 {
  top: 50%;
  right: 10px;
  transform: translateY(-50%);
  animation-delay: 1s;
}

@keyframes cardFloat {
  0% {
    transform: translateY(-50%) translateX(0) rotate(0deg);
  }
  25% {
    transform: translateY(calc(-50% - 12px)) translateX(-3px) rotate(1.5deg);
  }
  50% {
    transform: translateY(calc(-50% + 2px)) translateX(2px) rotate(0.7deg);
  }
  75% {
    transform: translateY(calc(-50% + 10px)) translateX(3px) rotate(-1.5deg);
  }
  100% {
    transform: translateY(-50%) translateX(0) rotate(0deg);
  }
}

@keyframes cardFloatReverse {
  0% {
    transform: translateY(-50%) translateX(0) rotate(0deg);
  }
  25% {
    transform: translateY(calc(-50% + 12px)) translateX(3px) rotate(-1.5deg);
  }
  50% {
    transform: translateY(calc(-50% - 2px)) translateX(-2px) rotate(-0.7deg);
  }
  75% {
    transform: translateY(calc(-50% - 10px)) translateX(-3px) rotate(1.5deg);
  }
  100% {
    transform: translateY(-50%) translateX(0) rotate(0deg);
  }
}

.code-card__keyword {
  color: #569cd6;
}
.code-card__function {
  color: #dcdcaa;
}
.code-card__string {
  color: #ce9178;
}
.code-card__variable {
  color: #9cdcfe;
}
.code-card__builtin {
  color: #4ec9b0;
}

/* Light theme adjustments for floating elements */
[data-theme="light"] .floating-element {
  opacity: 0;
}

[data-theme="light"] .floating-element--bracket {
  color: rgba(108, 124, 255, 0.7);
}

[data-theme="light"] .floating-element--tag {
  color: rgba(0, 122, 204, 0.7);
}

[data-theme="light"] .floating-element--symbol {
  color: rgba(200, 150, 0, 0.7);
}

[data-theme="light"] .floating-element--code {
  color: rgba(0, 100, 150, 0.6);
  background: rgba(255, 255, 255, 0.6);
}

[data-theme="light"] .floating-element--icon {
  color: rgba(0, 150, 100, 0.7);
}

[data-theme="light"] .floating-element--binary {
  color: rgba(0, 0, 0, 0.2);
}

[data-theme="light"] .glow-orb--1 {
  background: radial-gradient(
    circle,
    rgba(79, 195, 247, 0.25) 0%,
    transparent 70%
  );
}

[data-theme="light"] .glow-orb--2 {
  background: radial-gradient(
    circle,
    rgba(108, 124, 255, 0.15) 0%,
    transparent 70%
  );
}

[data-theme="light"] .glow-orb--3 {
  background: radial-gradient(
    circle,
    rgba(0, 122, 204, 0.2) 0%,
    transparent 70%
  );
}

[data-theme="light"] .floating-code-card {
  background: rgba(255, 255, 255, 0.95);
  color: #333;
  border-color: rgba(0, 122, 204, 0.2);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1), 0 0 20px rgba(79, 195, 247, 0.1);
}

[data-theme="light"] .animated-terminal {
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

/* ========================================
   Code Editor (New Design)
   ======================================== */

.code-editor {
  position: relative;
  width: 100%;
  max-width: 600px;
  background: rgb(30, 30, 30);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
  font-family: Consolas, Monaco, "Courier New", monospace;
  border: 1px solid rgba(255, 255, 255, 0.12);
  animation: codeEditorFloat 6s ease-in-out infinite;
  z-index: 10;
  isolation: isolate;
}

@keyframes codeEditorFloat {
  0%,
  100% {
    transform: translateY(0) translateX(0);
  }
  25% {
    transform: translateY(-3px) translateX(-3px);
  }
  50% {
    transform: translateY(-6px) translateX(-6px);
  }
  75% {
    transform: translateY(-3px) translateX(-3px);
  }
}

.code-editor-header {
  background: rgb(37, 37, 38);
  padding: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  z-index: 30;
  overflow: visible;
}

.code-editor-tabs {
  display: flex;
  gap: 0;
  flex: 1;
}

.code-tab {
  padding: 12px 20px;
  background: rgb(45, 45, 48);
  color: rgb(133, 133, 133);
  font-size: 13px;
  font-weight: 500;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  cursor: pointer;
  transition: 0.3s;
  display: flex;
  align-items: center;
  gap: 8px;
}

.code-tab-icon {
  font-size: 14px;
}

.code-tab-active {
  background: rgb(30, 30, 30);
  color: rgb(204, 204, 204);
  border-bottom: 2px solid rgb(0, 122, 204);
}

.code-editor-actions {
  display: flex;
  gap: 8px;
  padding: 8px 12px;
}

.code-action-btn {
  background: transparent;
  border: none;
  color: rgb(204, 204, 204);
  font-size: 16px;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 4px;
  transition: 0.2s;
  font-family: inherit;
  display: flex;
  align-items: center;
  justify-content: center;
}

.code-action-btn i {
  font-size: 14px;
}

.code-action-btn__play-icon {
  display: block;
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.code-action-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-white);
}

.code-action-btn:focus {
  outline: none;
}

.code-editor-body {
  padding: 0;
  min-height: 280px;
  background: rgb(30, 30, 30);
  display: flex;
  align-items: stretch;
  position: relative;
  z-index: 1;
}

.code-line-numbers {
  background: rgb(37, 37, 38);
  padding: 16px 12px;
  color: rgb(133, 133, 133);
  font-size: 13px;
  line-height: 1.8;
  text-align: right;
  user-select: none;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  font-family: Consolas, Monaco, "Courier New", monospace;
  min-width: 40px;
  align-self: stretch;
  box-sizing: border-box;
}

.code-line-numbers span {
  display: block;
}

.code-content-wrapper {
  flex: 1;
  min-width: 0;
  padding: 16px 20px;
  overflow-x: hidden;
  box-sizing: border-box;
}

.code-content {
  margin: 0;
  padding: 0;
  font-size: 14px;
  line-height: 1.8;
  color: rgb(212, 212, 212);
  font-family: Consolas, Monaco, "Courier New", monospace;
  white-space: pre-wrap;
  overflow-x: hidden;
  overflow-wrap: anywhere;
  word-break: break-word;
  background: transparent;
}

.code-content .code-keyword {
  color: rgb(86, 156, 214);
}

.code-content .code-function {
  color: rgb(220, 220, 170);
}

.code-content .code-string {
  color: rgb(206, 145, 120);
}

.code-content .code-builtin {
  color: rgb(78, 201, 176);
}

.code-content .code-variable {
  color: rgb(156, 220, 254);
}

/* Code Result Panel */
.code-result-panel {
  position: fixed;
  top: 87px;
  right: 20px;
  width: 390px;
  max-height: 520px;
  background: #1a1a1f;
  border-radius: 14px;
  box-shadow:
    0 24px 64px rgba(0, 0, 0, 0.6),
    0 0 0 1px rgba(255, 255, 255, 0.07),
    0 0 30px rgba(108, 124, 255, 0.08);
  border: 1px solid rgba(108, 124, 255, 0.18);
  z-index: 100000;
  opacity: 0;
  visibility: hidden;
  transform: translateX(calc(100% + 16px)) scale(0.995);
  pointer-events: none;
  will-change: opacity, transform;
  transition:
    opacity 0.55s ease,
    transform 0.62s cubic-bezier(0.22, 1, 0.36, 1),
    visibility 0s linear 0.62s !important;
  overflow: hidden;
  font-family: Consolas, Monaco, "Courier New", monospace;
}

.code-result-panel.show {
  opacity: 1;
  visibility: visible;
  transform: translateX(0) scale(1);
  pointer-events: auto;
  transition:
    opacity 0.5s ease,
    transform 0.62s cubic-bezier(0.22, 1, 0.36, 1),
    visibility 0s linear 0s !important;
  z-index: 9999999;
}

@media (prefers-reduced-motion: reduce) {
  .code-result-panel,
  .code-result-panel.show {
    transition: none;
    transform: none;
  }
}

.code-result-header {
  background: #22222a;
  padding: 11px 16px;
  border-bottom: 1px solid rgba(108, 124, 255, 0.12);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

/* accent top line */
.code-result-panel::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, var(--accent-orange), var(--accent-purple));
  border-radius: 14px 14px 0 0;
  z-index: 2;
  transform-origin: left center;
  transform: scaleX(0);
}

.code-result-panel.show::before {
  animation: codeResultCountdown var(--result-autoclose-ms, 5000ms) linear forwards !important;
}

@keyframes codeResultCountdown {
  0% {
    transform: scaleX(1);
  }
  100% {
    transform: scaleX(0);
  }
}

.code-result-title {
  color: #cccccc;
  font-size: 12px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 7px;
}

/* running dot indicator */
.code-result-title::before {
  content: '';
  width: 8px;
  height: 8px;
  background: #4ec94e;
  border-radius: 50%;
  flex-shrink: 0;
  animation: crPulse 1.8s ease-in-out infinite;
}

@keyframes crPulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(78, 201, 78, 0.4); }
  50%       { opacity: 0.7; box-shadow: 0 0 0 5px rgba(78, 201, 78, 0); }
}

.code-result-close {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #888;
  font-size: 18px;
  cursor: pointer;
  padding: 0;
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  transition: background 0.2s, color 0.2s, transform 0.15s;
  line-height: 1;
  margin-left: auto;
}

.code-result-close:hover {
  background: rgba(255, 255, 255, 0.1);
  color: rgb(204, 204, 204);
}

.code-result-content {
  padding: 16px;
  color: rgb(78, 201, 176);
  font-size: 14px;
  line-height: 1.6;
  max-height: 400px;
  overflow-y: auto;
  white-space: pre-wrap;
  overflow-wrap: break-word;
}

.code-result-content::-webkit-scrollbar {
  width: 8px;
}

.code-result-content::-webkit-scrollbar-track {
  background: rgb(37, 37, 38);
}

.code-result-content::-webkit-scrollbar-thumb {
  background: rgb(62, 62, 66);
  border-radius: 4px;
}

.code-result-content::-webkit-scrollbar-thumb:hover {
  background: rgb(78, 78, 82);
}

/* Light theme for Code Editor */
[data-theme="light"] .code-editor {
  background: rgb(255, 255, 255);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15), 0 0 0 1px rgba(0, 0, 0, 0.08);
  border: 1px solid rgba(0, 0, 0, 0.1);
}

[data-theme="light"] .code-editor-header {
  background: rgb(245, 245, 245);
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

[data-theme="light"] .code-tab {
  background: rgb(230, 230, 230);
  color: rgb(100, 100, 100);
  border-right: 1px solid rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .code-tab-active {
  background: rgb(255, 255, 255);
  color: rgb(51, 51, 51);
  border-bottom: 2px solid rgb(0, 122, 204);
}

[data-theme="light"] .code-action-btn {
  color: rgb(100, 100, 100);
}

[data-theme="light"] .code-action-btn:hover {
  background: rgba(0, 0, 0, 0.1);
  color: rgb(51, 51, 51);
}

[data-theme="light"] .code-editor-body {
  background: rgb(255, 255, 255);
}

[data-theme="light"] .code-line-numbers {
  background: rgb(245, 245, 245);
  color: rgb(150, 150, 150);
  border-right: 1px solid rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .code-content {
  color: rgb(51, 51, 51);
}

[data-theme="light"] .code-content .code-keyword {
  color: rgb(0, 0, 255);
}

[data-theme="light"] .code-content .code-function {
  color: rgb(121, 94, 38);
}

[data-theme="light"] .code-content .code-string {
  color: rgb(163, 21, 21);
}

[data-theme="light"] .code-content .code-builtin {
  color: rgb(38, 127, 153);
}

[data-theme="light"] .code-content .code-variable {
  color: rgb(0, 16, 128);
}

[data-theme="light"] .code-result-panel {
  background: rgb(255, 255, 255);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15), 0 0 0 1px rgba(0, 0, 0, 0.08);
  border: 1px solid rgba(0, 0, 0, 0.1);
}

[data-theme="light"] .code-result-header {
  background: rgb(245, 245, 245);
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

[data-theme="light"] .code-result-title {
  color: rgb(51, 51, 51);
}

[data-theme="light"] .code-result-close {
  color: rgb(100, 100, 100);
}

[data-theme="light"] .code-result-close:hover {
  background: rgba(0, 0, 0, 0.1);
  color: rgb(51, 51, 51);
}

[data-theme="light"] .code-result-content {
  color: rgb(38, 127, 153);
}

[data-theme="light"] .code-result-content::-webkit-scrollbar-track {
  background: rgb(245, 245, 245);
}

[data-theme="light"] .code-result-content::-webkit-scrollbar-thumb {
  background: rgb(200, 200, 200);
}

[data-theme="light"] .code-result-content::-webkit-scrollbar-thumb:hover {
  background: rgb(170, 170, 170);
}

/* Code Editor Responsive */
@media (max-width: 968px) {
  .code-result-panel {
    top: 72px;
    right: 16px;
    left: auto;
    width: min(390px, calc(100vw - 32px));
    max-width: calc(100vw - 32px);
    transform: translateX(calc(100% + 20px)) scale(0.995);
  }

  .code-result-panel.show {
    right: 16px;
    left: auto;
    transform: translateX(0) scale(1);
  }
}

@media (max-width: 768px) {
  .code-editor {
    position: relative;
    right: auto;
    top: auto;
    transform: none;
    width: 100%;
    max-width: 100%;
    animation: none;
  }

  .code-content {
    font-size: 12px;
  }

  .code-line-numbers {
    font-size: 12px;
    padding: 16px 8px;
    min-width: 32px;
  }
}

@media (max-width: 480px) {
  .code-action-btn {
    padding: 4px 6px;
  }

  .code-action-btn i {
    font-size: 12px;
  }

  .code-tab {
    padding: 10px 14px;
    font-size: 12px;
  }
}

/* Hero Р°РґР°РїС‚Р°С†РёСЏ РѕС‚ 440px Рё РЅРёР¶Рµ */
@media (max-width: 440px) {
  .hero {
    grid-template-columns: 1fr;
    gap: 40px;
    text-align: center;
  }

  .hero-left {
    align-items: center;
    text-align: center;
    width: 100%;
  }

  .hero-title-line {
    font-size: 40px;
  }

  .hero-title-line-small {
    font-size: 32px;
  }

  .hero-description {
    max-width: 100%;
    font-size: 16px;
    margin: 0 auto;
  }

  .start-learning-btn {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    align-self: center;
    margin: 0 auto;
    width: 100%;
    max-width: 320px;
  }

  .hero-right {
    justify-content: center;
    width: 100%;
  }

  .hero-right .code-editor {
    max-width: 100%;
    width: 100%;
    margin: 0 auto;
  }
}

.hero-left {
  display: flex;
  flex-direction: column;
  gap: 20px;
  position: relative;
  z-index: 100;
}

.hero-title {
  display: flex;
  flex-direction: column;
  gap: 14px;
  font-weight: 700;
  line-height: 1.1;
  color: var(--text-white);
  transition: color 0.3s ease;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .hero-title {
  color: var(--text-white);
}

[data-theme="light"] .hero-title {
  color: #0a1f3a;
  text-shadow: none;
}

.hero-title-line {
  font-size: 56px;
  text-transform: uppercase;
  letter-spacing: -1px;
}

.hero-title-line-small {
  font-size: 48px;
}

/* Р’С‹РґРµР»РµРЅРёРµ СЃР»РѕРІР° РІ Р·Р°РіРѕР»РѕРІРєРµ РіРµСЂРѕСЏ */
.hero-title .highlight-yellow {
  background-color: #6c7cff;
  color: #fff;
  padding: 1px 4px;
  border-radius: 10px;
  font-weight: 600;
}

[data-theme="light"] .hero-title .highlight-yellow {
  background-color: #6c7cff;
  color: #fff;
}

.hero-description {
  font-size: 18px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.85);
  max-width: 500px;
  position: relative;
  transition: color 0.3s ease;
  margin-top: -8px;
}

[data-theme="dark"] .hero-description {
  color: rgba(255, 255, 255, 0.85);
}

[data-theme="light"] .hero-description {
  color: #2a4a6a;
}

/* Start Learning Button */
.start-learning-btn {
  padding: 16px 32px;
  border: none;
  border-radius: 12px;
  background: var(--accent-orange);
  color: #333;
  font-size: 16px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.3s ease;
  text-align: center;
  box-shadow: 0 4px 16px var(--glow-orange);
  align-self: flex-start;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.start-learning-btn i {
  font-size: 16px;
}

.start-learning-btn:hover {
  background: var(--accent-orange-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(108, 124, 255, 0.35);
}

.start-learning-btn:active {
  transform: translateY(0);
}

.start-learning-btn:focus {
  outline: none;
}

/* Hero Right - Code Editor */
.hero-right {
  position: relative;
  z-index: 100;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Old code-result-panel styles removed - using new styles from code-editor section */

.code-editor-header {
  background: #252526;
  padding: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  z-index: 30;
  overflow: visible;
}

.code-editor-tabs {
  display: flex;
  gap: 0;
  flex: 1;
}

.code-tab {
  padding: 12px 20px;
  background: #2d2d30;
  color: #858585;
  font-size: 13px;
  font-weight: 500;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 8px;
}

.code-tab-icon {
  font-size: 14px;
}

.code-tab-active {
  background: #1e1e1e;
  color: #cccccc;
  border-bottom: 2px solid #007acc;
}

.code-editor-actions {
  display: flex;
  gap: 8px;
  padding: 8px 12px;
}

.code-action-btn {
  background: transparent;
  border: none;
  color: #cccccc;
  font-size: 16px;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 4px;
  transition: all 0.2s ease;
  font-family: inherit;
  display: flex;
  align-items: center;
  justify-content: center;
}

.code-action-btn i {
  font-size: 14px;
}

.code-action-btn__play-icon {
  display: block;
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.code-action-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-white);
}

.code-action-btn:focus {
  outline: none;
}

.code-editor-body {
  padding: 0;
  min-height: 280px;
  background: #1e1e1e;
  display: flex;
  align-items: stretch;
  position: relative;
  z-index: 1;
}

.code-line-numbers {
  background: #252526;
  padding: 16px 12px;
  color: #858585;
  font-size: 13px;
  line-height: 1.8;
  text-align: right;
  user-select: none;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  font-family: "Consolas", "Monaco", "Courier New", monospace;
  min-width: 40px;
}

.code-line-numbers span {
  display: block;
}

.code-content-wrapper {
  flex: 1;
  padding: 16px 20px;
  overflow-x: hidden;
}

.code-content {
  margin: 0;
  padding: 0;
  font-size: 14px;
  line-height: 1.8;
  color: #d4d4d4;
  font-family: "Consolas", "Monaco", "Courier New", monospace;
  white-space: pre-wrap;
  overflow-x: hidden;
  overflow-wrap: anywhere;
  word-break: break-word;
  background: transparent;
  border: none !important;
  outline: none !important;
  text-decoration: none !important;
}

.code-content * {
  border-bottom: none !important;
  text-decoration: none !important;
  outline: none !important;
}

.code-content-wrapper pre,
.code-content-wrapper code,
.code-content-wrapper pre code,
.code-content-wrapper pre code span {
  border: none !important;
  border-bottom: none !important;
  border-top: none !important;
  border-left: none !important;
  border-right: none !important;
  outline: none !important;
  text-decoration: none !important;
  box-shadow: none !important;
}

.code-content-wrapper pre code:last-child,
.code-content-wrapper pre code span:last-child {
  border-bottom: none !important;
}

.code-content-wrapper pre code::after,
.code-content-wrapper pre code::before,
.code-content-wrapper pre code span::after,
.code-content-wrapper pre code span::before {
  content: none !important;
  display: none !important;
  border: none !important;
  border-bottom: none !important;
}

.code-keyword {
  color: #569cd6;
  text-decoration: none !important;
  border-bottom: none !important;
  border: none !important;
  outline: none !important;
  box-shadow: none !important;
}

/* РЎРїРµС†РёС„РёС‡РЅС‹Рµ РїСЂР°РІРёР»Р° РґР»СЏ РїРѕСЃР»РµРґРЅРµРіРѕ code-keyword, С‡С‚РѕР±С‹ СѓР±СЂР°С‚СЊ РєСЂР°СЃРЅСѓСЋ Р»РёРЅРёСЋ */
.code-content-wrapper pre code span.code-keyword:last-child,
.code-content-wrapper pre code span.code-keyword:last-of-type,
.code-content code span.code-keyword:last-child,
.code-content code span.code-keyword:last-of-type {
  border: none !important;
  border-bottom: none !important;
  border-top: none !important;
  border-left: none !important;
  border-right: none !important;
  outline: none !important;
  text-decoration: none !important;
  box-shadow: none !important;
  background: transparent !important;
  background-color: transparent !important;
}

.code-content-wrapper pre code span.code-keyword:last-child::after,
.code-content-wrapper pre code span.code-keyword:last-child::before,
.code-content-wrapper pre code span.code-keyword:last-of-type::after,
.code-content-wrapper pre code span.code-keyword:last-of-type::before,
.code-content code span.code-keyword:last-child::after,
.code-content code span.code-keyword:last-child::before,
.code-content code span.code-keyword:last-of-type::after,
.code-content code span.code-keyword:last-of-type::before {
  content: none !important;
  display: none !important;
  border: none !important;
  border-bottom: none !important;
  background: none !important;
}

/* РЈРЅРёРІРµСЂСЃР°Р»СЊРЅРѕРµ РїСЂР°РІРёР»Рѕ РґР»СЏ СѓРґР°Р»РµРЅРёСЏ Р»СЋР±С‹С… РІРёР·СѓР°Р»СЊРЅС‹С… Р°СЂС‚РµС„Р°РєС‚РѕРІ РїРѕСЃР»Рµ РїРѕСЃР»РµРґРЅРµРіРѕ СЌР»РµРјРµРЅС‚Р° РІ code */
.code-content-wrapper pre,
.code-content-wrapper pre code,
.code-content-wrapper pre code span,
.code-content-wrapper pre code span.code-keyword {
  position: relative;
}

.code-content-wrapper pre::after,
.code-content-wrapper pre::before,
.code-content-wrapper pre code::after,
.code-content-wrapper pre code::before,
.code-content-wrapper pre code span::after,
.code-content-wrapper pre code span::before,
.code-content-wrapper pre code span.code-keyword::after,
.code-content-wrapper pre code span.code-keyword::before,
.code-content-wrapper pre code span.code-keyword:last-child::after,
.code-content-wrapper pre code span.code-keyword:last-child::before,
.code-content-wrapper pre code span.code-keyword:last-of-type::after,
.code-content-wrapper pre code span.code-keyword:last-of-type::before {
  content: "" !important;
  display: none !important;
  position: absolute !important;
  bottom: auto !important;
  top: auto !important;
  left: auto !important;
  right: auto !important;
  height: 0 !important;
  width: 0 !important;
  border: none !important;
  border-bottom: none !important;
  border-top: none !important;
  border-left: none !important;
  border-right: none !important;
  background: none !important;
  background-color: transparent !important;
  box-shadow: none !important;
  outline: none !important;
  text-decoration: none !important;
  line-height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
}

.code-function {
  color: #dcdcaa;
}

.code-string {
  color: #ce9178;
}

.code-builtin {
  color: #4ec9b0;
}

.code-variable {
  color: #9cdcfe;
}

/* Courses Section */
.courses-section {
  padding: 50px 0 70px 0;
  margin-top: -30px;
  background: var(--bg-purple-light);
  transition: background-color 0.3s ease;
  position: relative;
  border-radius: 30px;
  z-index: 10;
}

[data-theme="dark"] .courses-section {
  background: #131416;
}

[data-theme="light"] .courses-section {
  background: #f5f5f5;
}

.courses-section .container {
  padding: 0 20px;
}

.courses-section-header {
  text-align: left;
  margin-bottom: 40px;
  position: relative;
  z-index: 100000;
}

.courses-section-title {
  font-size: 42px;
  font-weight: 700;
  color: var(--text-black);
  margin-bottom: 32px;
  transition: color 0.3s ease;
}

[data-theme="dark"] .courses-section-title {
  color: var(--text-white);
}

.courses-section-subtitle {
  font-size: 18px;
  color: #666666;
  margin: 0;
  text-align: left;
  transition: color 0.3s ease;
}

[data-theme="dark"] .courses-section-subtitle {
  color: var(--text-gray);
}

.courses-wrapper {
  width: 100%;
  position: relative;
  z-index: 100000;
}

.courses-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
  width: 100%;
}

.course-card {
  width: 100%;
  height: auto;
  aspect-ratio: 10 / 14;
  min-height: 0;
  min-width: 0;
  background: #252526;
  border-radius: 10px;
  overflow: hidden;
  cursor: pointer;
  border: 1px solid rgba(255, 255, 255, 0.08);
  position: relative;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  isolation: isolate;
  transition:
    transform 0.35s cubic-bezier(0.22, 1, 0.36, 1),
    border-color 0.35s ease,
    box-shadow 0.35s ease;
}

[data-theme="light"] .course-card {
  border: 1px solid rgba(0, 0, 0, 0.08);
}

.course-card,
.course-card:hover,
.course-card:active,
.course-card:focus {
  text-decoration: none;
}

.course-card-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  right: auto;
  background: rgba(0, 0, 0, 0.7);
  color: var(--text-white);
  padding: 4px 8px;
  border-radius: 6px;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.3px;
  text-transform: uppercase;
  z-index: 4;
  backdrop-filter: blur(10px);
  white-space: nowrap;
}

.course-card-badge--live {
  background: #c5ec7f;
  color: #1f2229;
}

.course-card-badge--soon {
  background: rgba(15, 18, 26, 0.78);
  color: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.course-card-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  top: 0;
  left: 0;
  z-index: 1;
  transition: filter 0.4s ease-in-out, transform 0.4s ease-in-out;
}

.course-card:not(.course-card-disabled):hover .course-card-image {
  transform: scale(1.04);
}

.course-card[data-category="frontend"] .course-card-image {
  object-fit: cover;
  object-position: center;
}

.course-card__shade {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background: linear-gradient(
    to top,
    rgba(8, 12, 22, 0.94) 0%,
    rgba(8, 12, 22, 0.42) 42%,
    rgba(8, 12, 22, 0.12) 100%
  );
  transition: opacity 0.35s ease;
}

.course-card-content-center {
  position: relative;
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  width: 100%;
  height: 100%;
  padding: 14px 12px 16px;
  background: transparent;
  transition: background 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}

.course-card:not(.course-card-disabled):hover {
  transform: translateY(-2px);
  border-color: rgba(108, 124, 255, 0.55);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.32);
}

.course-card--featured {
  border-color: #c5ec7f;
  box-shadow:
    0 0 0 1px rgba(197, 236, 127, 0.28),
    0 10px 28px rgba(0, 0, 0, 0.28);
}

.course-card--featured:hover {
  border-color: #d7f5a3;
  box-shadow:
    0 0 0 1px rgba(197, 236, 127, 0.5),
    0 18px 36px rgba(0, 0, 0, 0.38);
}

.course-card.is-filtered-out {
  display: none;
}

.course-card:hover .course-card-content-center {
  background: transparent;
}

.course-card:not(.course-card-disabled):hover .course-card__shade {
  opacity: 0.86;
}

/* Title stays readable; hover only lifts the card itself */
.course-card-title-center {
  transform: none;
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.course-card:hover .course-card-title-center {
  transform: none;
}

/* CTA button appears from below on hover */
.course-card-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 18px;
  border-radius: 20px;
  background: rgba(108, 124, 255, 0.9);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.3px;
  text-decoration: none;
  border: none;
  cursor: pointer;
  opacity: 0;
  transform: translateY(12px);
  transition:
    opacity 0.35s ease 0.05s,
    transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) 0.05s,
    background 0.2s ease;
  margin-top: 10px;
  margin-bottom: 4px;
  pointer-events: none;
}

.course-card:hover .course-card-cta {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.course-card-cta:hover {
  background: var(--accent-orange) !important;
}

.course-card-title-center {
  font-size: 16px;
  font-weight: 800;
  color: var(--text-white);
  text-align: center;
  line-height: 1.15;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
  margin-bottom: 4px;
  text-decoration: none;
  border-bottom: none;
}

.course-card-meta {
  margin: 0;
  font-size: 11px;
  font-weight: 500;
  line-height: 1.35;
  color: rgba(255, 255, 255, 0.62);
  text-align: center;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.45);
}

.course-card a .course-card-title-center,
.course-card .course-card-title-center {
  text-decoration: none !important;
  border-bottom: none !important;
}

/* Course Card Colors */
.course-card[data-category="frontend"] {
  background: #252526;
}

.course-card[data-category="1c"] {
  background: #252526;
}

.course-card[data-category="1c"] .course-card-image {
  object-fit: cover;
  object-position: center;
}

.course-card[data-category="designer"] .course-card-image {
  background: linear-gradient(135deg, #000000 0%, #dc2626 100%);
}

.course-card[data-category="3d"] .course-card-image {
  background: linear-gradient(135deg, #000000 0%, #131416 100%);
}

.course-card[data-category="marketplace"] .course-card-image {
  background: linear-gradient(135deg, #d4a574 0%, #f5deb3 100%);
}

.course-card[data-category="ai"] .course-card-image {
  background: linear-gradient(135deg, #6b21a8 0%, #9333ea 100%);
}

/* Disabled Course Card */
.course-card-disabled {
  opacity: 0.5;
  filter: grayscale(100%);
  cursor: not-allowed !important;
  pointer-events: none;
}

.course-card-disabled .course-card-image {
  filter: grayscale(100%) brightness(0.6);
}

.course-card-disabled .course-card-content-center {
  background: rgba(0, 0, 0, 0.6) !important;
}

.course-card-disabled:hover .course-card-content-center {
  background: rgba(0, 0, 0, 0.6) !important;
}

.course-card-disabled .course-card-title-center {
  color: rgba(255, 255, 255, 0.6);
}

.course-card-disabled .course-card-badge {
  background: rgba(0, 0, 0, 0.8);
  color: rgba(255, 255, 255, 0.6);
}

.course-card-disabled-label {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: rgba(0, 0, 0, 0.85);
  color: var(--text-white);
  padding: 7px 12px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 600;
  z-index: 10;
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  white-space: nowrap;
  text-align: center;
}

@media (max-width: 1200px) {
  .courses-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
  }
}

@media (max-width: 1100px) {
  .courses-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
  }

  .course-card {
    aspect-ratio: 10 / 14;
  }

  .hero-hub {
    padding-top: 12px;
  }

  .hero-section-wrapper > .container {
    padding-left: 16px;
    padding-right: 16px;
    width: 100%;
    max-width: 100%;
  }

  body.has-site-sidebar .hero-section-wrapper,
  body.has-site-sidebar .footer {
    width: 100%;
    max-width: 100%;
  }
}

@media (max-width: 768px) {
  .courses-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }

  .course-card {
    aspect-ratio: 10 / 14;
  }
}

@media (max-width: 640px) {
  .courses-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .course-card {
    height: auto;
    min-height: 0;
    aspect-ratio: 10 / 14;
    max-width: 100%;
    overflow: hidden;
  }

  .course-card-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
    padding: 0;
    transform: none !important;
  }

  .course-card:not(.course-card-disabled):hover .course-card-image {
    transform: none !important;
  }

  .course-card-badge {
    top: 8px;
    left: 8px;
    right: auto;
    font-size: 9px;
    padding: 4px 8px;
    white-space: nowrap;
    text-align: left;
    max-width: calc(100% - 16px);
  }

  .course-card-content-center {
    padding: 12px 10px 14px;
  }

  .course-card-title-center {
    font-size: 14px;
    margin-bottom: 4px;
  }
}

@media (max-width: 400px) {
  .courses-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .course-card-title-center {
    font-size: 16px;
  }
}

/* Hero hub: Cybershoke-style catalog on the first screen */
.hero-hub {
  position: relative;
  z-index: 2;
  padding: 28px 0 48px;
}

.hero-hub__filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0 0 18px;
}

.header .hero-hub__filters,
.header-hub-filters {
  flex-wrap: nowrap;
  align-items: center;
  gap: 4px;
  margin: 0;
  padding: 4px;
  border-radius: 12px;
  background: #16181d;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: none;
  position: relative;
  z-index: 2;
  overflow: visible;
}

.header .hero-hub__filters[hidden],
.header-hub-filters[hidden] {
  display: none !important;
}

[data-theme="light"] .header .hero-hub__filters,
[data-theme="light"] .header-hub-filters {
  background: #eef0f4;
  border-color: rgba(15, 23, 42, 0.1);
  box-shadow: none;
}

.hero-hub__filters::-webkit-scrollbar {
  display: none;
}

.hero-hub-chip-wrap {
  position: relative;
  display: inline-flex;
  flex-shrink: 0;
  overflow: visible;
}

.hero-hub-chip-wrap--has-badge {
  padding-top: 5px;
  padding-right: 8px;
}

.hero-hub-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  flex-shrink: 0;
  position: relative;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: #2a2d36;
  color: #e2e8f0;
  border-radius: 999px;
  padding: 7px 13px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.01em;
  line-height: 1.2;
  text-transform: none;
  cursor: pointer;
  font-family: inherit;
  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    color 0.2s ease,
    opacity 0.2s ease;
}

.header .hero-hub-chip,
.header-hub-filters .hero-hub-chip {
  border: none;
  border-radius: 10px;
  background: transparent;
  color: rgba(255, 255, 255, 0.58);
  padding: 9px 16px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.header .hero-hub-chip__icon,
.header-hub-filters .hero-hub-chip__icon {
  color: rgba(255, 255, 255, 0.45);
}

.header .hero-hub-chip:hover,
.header-hub-filters .hero-hub-chip:hover {
  background: #2a2e38;
  color: rgba(255, 255, 255, 0.92);
}

.header .hero-hub-chip:hover .hero-hub-chip__icon,
.header-hub-filters .hero-hub-chip:hover .hero-hub-chip__icon {
  color: rgba(255, 255, 255, 0.78);
}

.header .hero-hub-chip.is-active,
.header-hub-filters .hero-hub-chip.is-active {
  background: #c6f34a;
  border: none;
  color: #0b0f14;
  box-shadow: none;
}

.header .hero-hub-chip.is-active:hover,
.header-hub-filters .hero-hub-chip.is-active:hover {
  background: #c6f34a;
  color: #0b0f14;
}

.header .hero-hub-chip.is-active .hero-hub-chip__icon,
.header-hub-filters .hero-hub-chip.is-active .hero-hub-chip__icon,
.header .hero-hub-chip.is-active:hover .hero-hub-chip__icon,
.header-hub-filters .hero-hub-chip.is-active:hover .hero-hub-chip__icon {
  color: #0b0f14;
}

.header .hero-hub-chip--disabled,
.header-hub-filters .hero-hub-chip--disabled,
.header .hero-hub-chip--disabled:hover,
.header-hub-filters .hero-hub-chip--disabled:hover {
  background: transparent;
  color: rgba(255, 255, 255, 0.28);
  opacity: 1;
}

.header .hero-hub-chip--disabled .hero-hub-chip__icon,
.header-hub-filters .hero-hub-chip--disabled .hero-hub-chip__icon,
.header .hero-hub-chip--disabled:hover .hero-hub-chip__icon,
.header-hub-filters .hero-hub-chip--disabled:hover .hero-hub-chip__icon {
  color: rgba(255, 255, 255, 0.22);
}

.header .hero-hub-chip-wrap .hero-hub-chip__badge,
.header-hub-filters .hero-hub-chip-wrap .hero-hub-chip__badge {
  top: -4px;
  left: auto;
  right: -2px;
  transform: rotate(-8deg);
  transform-origin: right center;
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.55);
}

.hero-hub-chip__icon {
  width: 14px;
  font-size: 12px;
  text-align: center;
  color: rgba(255, 255, 255, 0.72);
  flex-shrink: 0;
}

.hero-hub-chip__label {
  white-space: nowrap;
}

.hero-hub-chip__badge {
  display: inline-flex;
  align-items: center;
  position: absolute;
  top: -3px;
  left: -2px;
  z-index: 3;
  margin: 0;
  padding: 1px 5px;
  border-radius: 3px;
  background: rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.55);
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.04em;
  line-height: 1.25;
  transform: rotate(-8deg);
  transform-origin: left center;
  pointer-events: none;
}

.hero-hub-chip:hover {
  background: #343842;
  border-color: rgba(255, 255, 255, 0.16);
  color: #fff;
}

.hero-hub-chip.is-active {
  background: rgba(108, 124, 255, 0.24);
  border-color: rgba(108, 124, 255, 0.55);
  color: #fff;
}

.hero-hub-chip.is-active .hero-hub-chip__icon {
  color: #aeb8ff;
}

.hero-hub-chip--disabled,
.hero-hub-chip--disabled:hover {
  background: #23262e;
  border-color: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.38);
  cursor: not-allowed;
  opacity: 0.72;
  pointer-events: none;
}

.hero-hub-chip--disabled .hero-hub-chip__icon {
  color: rgba(255, 255, 255, 0.28);
}

.hero-stats {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0;
  padding: 28px 0 36px;
  position: relative;
  z-index: 2;
}

.hero-stats::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 80%;
  height: 1px;
  background: linear-gradient(
    to right,
    transparent,
    rgba(255, 255, 255, 0.1),
    transparent
  );
}

.hero-stats__item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0 40px;
}

.hero-stats__num {
  font-size: 30px;
  font-weight: 800;
  color: #ffffff;
  line-height: 1;
  letter-spacing: -0.5px;
}

.hero-stats__label {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.45);
  margin-top: 5px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  white-space: nowrap;
}

.hero-stats__sep {
  width: 1px;
  height: 36px;
  background: rgba(255, 255, 255, 0.1);
  flex-shrink: 0;
}

[data-theme="light"] .hero-hub-chip {
  border-color: rgba(10, 31, 58, 0.1);
  background: #eef1f6;
  color: #1a1a2e;
}

[data-theme="light"] .hero-hub-chip__icon {
  color: rgba(26, 26, 46, 0.55);
}

[data-theme="light"] .hero-hub-chip:hover {
  background: #e2e7f0;
  color: #0a1f3a;
}

[data-theme="light"] .hero-hub-chip.is-active {
  background: rgba(108, 124, 255, 0.16);
  border-color: #6c7cff;
  color: #0a1f3a;
}

[data-theme="light"] .hero-hub-chip.is-active .hero-hub-chip__icon {
  color: #5a6fd6;
}

[data-theme="light"] .hero-hub-chip--disabled,
[data-theme="light"] .hero-hub-chip--disabled:hover {
  background: #e8ebf0;
  border-color: rgba(10, 31, 58, 0.08);
  color: rgba(26, 26, 46, 0.38);
}

[data-theme="light"] .hero-hub-chip--disabled .hero-hub-chip__icon {
  color: rgba(26, 26, 46, 0.28);
}

[data-theme="light"] .header .hero-hub-chip,
[data-theme="light"] .header-hub-filters .hero-hub-chip {
  color: rgba(26, 26, 46, 0.52);
}

[data-theme="light"] .header .hero-hub-chip__icon,
[data-theme="light"] .header-hub-filters .hero-hub-chip__icon {
  color: rgba(26, 26, 46, 0.4);
}

[data-theme="light"] .header .hero-hub-chip:hover,
[data-theme="light"] .header-hub-filters .hero-hub-chip:hover {
  background: rgba(15, 23, 42, 0.08);
  color: #1a1a2e;
}

[data-theme="light"] .header .hero-hub-chip:hover .hero-hub-chip__icon,
[data-theme="light"] .header-hub-filters .hero-hub-chip:hover .hero-hub-chip__icon {
  color: rgba(26, 26, 46, 0.62);
}

[data-theme="light"] .header .hero-hub-chip.is-active,
[data-theme="light"] .header-hub-filters .hero-hub-chip.is-active,
[data-theme="light"] .header .hero-hub-chip.is-active:hover,
[data-theme="light"] .header-hub-filters .hero-hub-chip.is-active:hover {
  background: #c6f34a;
  color: #0b0f14;
}

[data-theme="light"] .header .hero-hub-chip.is-active .hero-hub-chip__icon,
[data-theme="light"] .header-hub-filters .hero-hub-chip.is-active .hero-hub-chip__icon,
[data-theme="light"] .header .hero-hub-chip.is-active:hover .hero-hub-chip__icon,
[data-theme="light"] .header-hub-filters .hero-hub-chip.is-active:hover .hero-hub-chip__icon {
  color: #0b0f14;
}

[data-theme="light"] .header .hero-hub-chip-wrap .hero-hub-chip__badge,
[data-theme="light"] .header-hub-filters .hero-hub-chip-wrap .hero-hub-chip__badge {
  background: rgba(15, 23, 42, 0.08);
  color: rgba(26, 26, 46, 0.48);
}

[data-theme="light"] .hero-hub-chip__badge {
  background: rgba(15, 23, 42, 0.08);
  color: rgba(26, 26, 46, 0.48);
}

[data-theme="light"] .hero-stats__label {
  color: var(--text-black);
}

[data-theme="light"] .hero-stats::before {
  background: linear-gradient(
    to right,
    transparent,
    rgba(10, 31, 58, 0.12),
    transparent
  );
}

[data-theme="light"] .hero-stats__sep {
  background: rgba(10, 31, 58, 0.12);
}

@media (max-width: 768px) {
  .header .hero-hub__filters,
  .header-hub-filters {
    padding: 3px;
    gap: 3px;
    border-radius: 10px;
  }

  .header .hero-hub-chip,
  .header-hub-filters .hero-hub-chip {
    padding: 7px 12px;
    font-size: 12px;
    gap: 6px;
    border-radius: 8px;
  }

  .hero-hub-chip-wrap--has-badge {
    padding-top: 4px;
    padding-right: 6px;
  }

  .hero-hub {
    padding: 16px 0 4px;
  }

  .hero-stats {
    gap: 16px 0;
    padding: 20px 0 28px;
  }

  .hero-stats__item {
    padding: 0 16px;
  }

  .hero-stats__sep {
    display: none;
  }

  .hero-stats__num {
    font-size: 22px;
  }
}

@media (max-width: 480px) {
  .course-card-meta {
    font-size: 12px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .site-sidebar__support-pulse::before,
  .site-sidebar__support-pulse::after,
  .site-sidebar__support-pulse-dot {
    animation: none;
  }

  .course-card,
  .course-card-image,
  .course-card__shade,
  .hero-hub-chip {
    transition: none;
  }

  .course-card:not(.course-card-disabled):hover {
    transform: none;
  }

  .course-card:not(.course-card-disabled):hover .course-card-image {
    transform: none;
  }
}

/* Доступно скринридерам, но не занимает места в макете (WCAG 1.3.1 / 2.4.6) */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Skip link: visually hidden until keyboard focus (WCAG 2.4.1) */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100002;
  padding: 0.75rem 1rem;
  background: var(--bg-secondary, #1f2229);
  color: var(--text-primary, #fff);
  text-decoration: none;
  border-radius: 0 0 8px 8px;
  font-weight: 600;
}
.skip-link:focus,
.skip-link:focus-visible {
  left: 1rem;
  outline: 2px solid var(--accent-orange, #6c7cff);
  outline-offset: 2px;
}
