@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@400;500;600;700;800&display=swap');

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

body {
  font-family: 'Nunito', sans-serif;
  -webkit-font-smoothing: antialiased;
  background: #BADDED;
}

a {
  text-decoration: none;
  color: inherit;
}

.bx-auth-error-item{
    color: #e53935;
    font-size: 14px;
}
.page {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  position: relative;
  width: 100%;
  min-height: 100vh;
 
}

.bg-nature {
  /*background-image: linear-gradient(180deg, rgb(79,195,247) 0%, rgb(179,229,252) 30%, rgb(225,245,254) 45%, rgb(200,230,201) 45%, rgb(129,199,132) 100%);*/
  background: url('../images/deti.png') no-repeat center bottom;
}

.bg-lesson {
 /* background-image: linear-gradient(180deg, rgb(79,195,247) 0%, rgb(129,212,249) 26.923%, rgb(225,245,254) 52.404%, rgb(200,230,201) 61.058%, rgb(129,199,132) 99.519%);*/
  background: url('../images/deti.png') no-repeat center bottom;
}

.mountains {
  background: url('../images/samoletik.svg') no-repeat center -120px;
}

.cta-character.lessons{
    position: absolute;
    bottom: 10px;
    right: 100px;
}

.cta-character.lessons.test{
    bottom: 65px;
}
/* ===== HEADER ===== */
.header {
  backdrop-filter: blur(6px);
  border-bottom: 1px solid rgba(255,255,255,0.2);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 24px 13px;
  flex-shrink: 0;
  width: 100%;
  z-index: 10;
  position: relative;
  background: rgba(255,255,255,0.7);
}

.header-left {
  display: flex;
  gap: 32px;
  align-items: center;
}

.header-logo {
  display: flex;
  gap: 8px;
  align-items: center;
  cursor: pointer;
}

.header-logo img {
  width: 20px;
  height: 20px;
  object-fit: contain;
}

.header-logo-text {
  font-weight: 800;
  color: #4caf50;
  font-size: 20px;
  line-height: 28px;
  white-space: nowrap;
}

.header-nav {
  display: flex;
  gap: 24px;
  align-items: center;
}

.header-nav a {
  font-weight: 700;
  color: #475569;
  font-size: 14px;
  letter-spacing: 0.35px;
  text-transform: uppercase;
  line-height: 20px;
  white-space: nowrap;
  transition: color 0.2s;
}

.header-nav a:hover {
  color: #334155;
}

.header-right {
  display: flex;
  gap: 16px;
  align-items: center;
}

.btn-notification {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
  border-radius: 50%;
  background: transparent;
  border: none;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-notification:hover {
  background: rgba(0,0,0,0.05);
}

.btn-notification img {
  width: 20px;
  height: 20px;
  object-fit: contain;
}

.avatar-link {
  background: #4caf50;
  border: 2px solid white;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  box-shadow: 0px 10px 15px -3px rgba(0,0,0,0.1), 0px 4px 6px -4px rgba(0,0,0,0.1);
  cursor: pointer;
  transition: filter 0.2s, transform 0.2s;
}

.avatar-link:hover {
  filter: brightness(1.1);
  transform: scale(1.05);
}

.avatar-link span {
  font-weight: 700;
  color: white;
  font-size: 16px;
  line-height: 24px;
}

/* ===== ANIMATIONS ===== */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(40px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes zoomIn {
  from { opacity: 0; transform: scale(0.8); }
  to { opacity: 1; transform: scale(1); }
}

@keyframes floatIn {
  from { opacity: 0; transform: translateY(-20px); }
  to { opacity: 0.9; transform: translateY(0); }
}

@keyframes slideFromRight {
  from { opacity: 0; transform: translateX(120px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes slideIn {
  from { opacity: 0; transform: translateX(-60px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes scaleUp {
  from { opacity: 0; transform: scale(0.85); }
  to { opacity: 1; transform: scale(1); }
}

@keyframes popIn {
  from { opacity: 0; transform: scale(0.6) translateY(20px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideFromLeft {
  from { opacity: 0; transform: translateX(-30px); }
  to { opacity: 1; transform: translateX(0); }
}

.anim-fade-up {
  animation: fadeUp 0.6s ease-out both;
}

.test-content.loading > .anim-fade-up{
    position: relative;
}
.test-content.loading > .anim-fade-up:after{
    content: "";
    position: absolute;
    width: 100%;
    height: 100%;
    left: 0;
    top: 0;
    background: rgba(255,255,255,0.3);
}

.anim-zoom-in {
  animation: zoomIn 0.5s ease-out both;
}

.anim-float-in {
  animation: floatIn 1s ease-out both;
}

.anim-slide-right {
  animation: slideFromRight 0.6s ease-out both;
  animation-delay: 0.5s;
}

.anim-slide-in {
  animation: slideIn 0.5s ease-out both;
}

.anim-scale-up {
  animation: scaleUp 0.7s ease-out both;
  animation-delay: 0.3s;
}

.anim-pop-in {
  animation: popIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

.anim-fade-in {
  animation: fadeIn 0.4s ease-out both;
}

.anim-slide-left {
  animation: slideFromLeft 0.35s ease-out both;
}

/* ===== MAIN PAGE ===== */
.main-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  flex: 1;
  position: relative;
  width: 100%;
  overflow: hidden;
  padding-top: 64px;
  z-index: 0;

}

.mountains {
  position: absolute;
  inset: 0;
  opacity: 0.4;
  pointer-events: none;
}

.mountain {
  position: absolute;
  width: 0;
  height: 0;
  filter: blur(0.5px);
}

.mountain-1 { bottom: 60%; left: 7%; border-left: 120px solid transparent; border-right: 120px solid transparent; border-bottom: 160px solid #90a4ae; }
.mountain-2 { bottom: 58%; left: 25%; border-left: 150px solid transparent; border-right: 150px solid transparent; border-bottom: 200px solid #90a4ae; }
.mountain-3 { bottom: 55%; left: 43%; border-left: 180px solid transparent; border-right: 180px solid transparent; border-bottom: 240px solid #90a4ae; }
.mountain-4 { bottom: 59%; right: 11%; border-left: 135px solid transparent; border-right: 135px solid transparent; border-bottom: 180px solid #90a4ae; }

.cloud {
  position: absolute;
  pointer-events: none;
}

.cloud-1 { left: 15%; top: 80px; }
.cloud-2 { left: calc(50% + 96px); transform: translateX(-50%); top: 128px; }
.cloud-3 { left: 73.75%; top: 96px; }

.cloud-bubble {
  position: absolute;
  background: white;
  border-radius: 50%;
}

.main-center {
  position: relative;
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 960px;
  padding: 0 24px;
  gap: 48px;
}

.main-title-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  text-align: center;
}

.main-title {
  font-weight: 800;
  color: #1e293b;
  font-size: 48px;
  letter-spacing: -1.2px;
  line-height: 56px;
}

.main-subtitle {
  font-weight: 600;
  color: #334155;
  font-size: 18px;
  line-height: 28px;
  max-width: 600px;
}

.categories-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  width: 100%;
}

.category-card {
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255,255,255,0.3);
  border-radius: 24px;
  box-shadow: 0px 4px 12px 0px rgba(0,0,0,0.08);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  cursor: pointer;
  transition: box-shadow 0.2s, transform 0.2s;
  background: rgba(255,255,255,0.6);
}

.category-card:hover {
  box-shadow: 0px 8px 24px 0px rgba(0,0,0,0.12);
  transform: translateY(-2px);
}

.category-icon {
  width: 48px;
  height: 48px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
}

.category-title {
  font-weight: 700;
  font-size: 18px;
  line-height: 24px;
}

.category-desc {
  font-weight: 500;
  color: #64748b;
  font-size: 14px;
  line-height: 20px;
  min-height: 42px;
}

/* ===== CTA ROW (speech bubble + character) ===== */
.cta-row {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 0;
  width: 100%;
}

.speech-bubble {
  background: rgba(255,255,255,0.7);
  backdrop-filter: blur(6px);
  /*border: 1px solid rgba(255,255,255,0.4);*/
  border-radius: 24px;
  padding: 20px 32px;
  box-shadow: 0px 4px 16px rgba(0,0,0,0.08);
  flex: 1;
  min-width: 0;
  margin: 0 100px;
  padding: 55px 35px;
  position: relative;
}

.speech-bubble::after {
  content: '';
  position: absolute;
  right: -20px;
  top: 50%;
  transform: translateY(-50%);
  width: 0;
  height: 0;
  border-top: 16px solid transparent;
  border-bottom: 16px solid transparent;
  border-left: 20px solid rgba(255,255,255,0.7);
}

.speech-bubble-text {
  font-weight: 800;
  color: #1e293b;
  font-size: 24px;
  line-height: 34px;
}

.cta-character {
  flex-shrink: 0;
}

.cta-character img {
  height: 460px;
  width: auto;
  object-fit: contain;
  filter: drop-shadow(0px 8px 24px rgba(0,0,0,0.15));
}

.character-image-small img {
  height: 280px;
  width: auto;
  object-fit: contain;
  filter: drop-shadow(0px 8px 24px rgba(0,0,0,0.15));
}

@media (max-width: 768px) {
  .cta-character.index img {
    height: 220px;
  }

  .speech-bubble-text {
    font-size: 20px;
    line-height: 28px;
  }

  .speech-bubble {
    padding: 46px 34px;
    margin: 0 55px;
  }
}

@media (max-width: 414px) {
  .cta-row {
    flex-direction: column;
    align-items: center;
    gap: 16px;
  }

  .cta-character.index img {
    height: 350px;
  }

  .speech-bubble{
     margin: 0 21px;
  }
  
  .speech-bubble-text {
    font-size: 18px;
    line-height: 26px;
  }
}

/* ===== LESSON PAGE ===== */
.lesson-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
  position: relative;
  width: 100%;
  overflow: hidden;
}

.lesson-sky {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, #7dd3fc 0%, #e0f2fe 100%);
}

.lesson-cloud-1 {
  position: absolute;
  background: rgba(255,255,255,0.4);
  filter: blur(12px);
  height: 48px;
  left: 320px;
  border-radius: 9999px;
  top: 40px;
  width: 128px;
}

.lesson-cloud-2 {
  position: absolute;
  background: rgba(255,255,255,0.3);
  filter: blur(12px);
  height: 64px;
  right: 427px;
  border-radius: 9999px;
  top: 80px;
  width: 192px;
}

.lesson-hill-wrap {
  position: absolute;
  bottom: -128px;
  display: flex;
  height: 484px;
  align-items: center;
  justify-content: center;
  left: -320px;
  width: 1920px;
}

.lesson-hill {
  transform: scale(1.5);
  flex: none;
}

.lesson-hill-inner {
  background: #10b981;
  height: 323px;
  border-radius: 601px 601px 0 0;
  width: 1280px;
}

.lesson-green-left {
  position: absolute;
  background: #22c55e;
  bottom: 0;
  height: 242px;
  left: 0;
  opacity: 0.8;
  border-radius: 0 9999px 0 0;
  width: 853px;
}

.lesson-green-right {
  position: absolute;
  background: #16a34a;
  bottom: 0;
  height: 242px;
  opacity: 0.8;
  right: 0;
  border-radius: 9999px 0 0 0;
  width: 853px;
}

.lesson-flow {
  position: relative;
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 960px;
  padding: 32px 24px 48px;
  gap: 32px;
  min-height: 1500px;
}

.lesson-content.detail .lesson-flow{
   min-height: 1375px;    
}

.lesson-header-flow {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 20px;
  width: 100%;
}

.lesson-title {
  font-weight: 800;
  color: #1e293b;
  font-size: 48px;
  letter-spacing: -1.2px;
  line-height: 48px;
  text-shadow: 0px 1px 1px rgba(0,0,0,0.05);
}

.lesson-desc-box {
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255,255,255,0.3);
  max-width: 672px;
  padding: 16px 17px 17px;
  border-radius: 24px;
  box-shadow: 0px 1px 2px 0px rgba(0,0,0,0.05);
  background: rgba(255,255,255,0.4);
  width: 100%;
}

.lesson-desc-text {
  font-weight: 600;
  color: #1e293b;
  font-size: 18px;
  line-height: 29px;
}

.lesson-video-flow {
  width: 100%;
}

.lesson-video-responsive {
  position: relative;
  width: 100%;
  padding-top: 56.25%;
  background: black;
  border: 4px solid rgba(255,255,255,0.5);
  border-radius: 24px;
  box-shadow: 0px 25px 50px 0px rgba(0,0,0,0.25);
  overflow: hidden;
}

.lesson-video-el {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: black;
}

.lesson-video-responsive .plyr {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.lesson-video-responsive .plyr__video-wrapper {
  height: 100%;
}

.lesson-video-responsive .plyr--video {
  border-radius: 0;
}

.lesson-video-inner {
  position: absolute;
  inset: 0;
  opacity: 0.8;
  overflow: hidden;
}

.lesson-video-inner img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.steps-flow {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  width: 100%;
  justify-content: center;
}

.steps-flow > .anim-pop-in {
  flex: 0 0 calc(33.333% - 8px);
  box-sizing: border-box;
  flex-grow: 1;
}

.steps-flow-single > .anim-pop-in {
  flex: 0 0 100%;
}

.step-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-left: 20px;
  padding-right: 16px;
  border-radius: 10px;
  height: 104px;
  width: 100%;
  box-sizing: border-box;
  background: #047834;
  border: none;
  border-left: 4px solid #22c55e;
  position: relative;
  cursor: pointer;
  transition: filter 0.2s, transform 0.2s;
  font-size: 15px;
}

.step-btn-full {
  justify-content: center;
  text-align: center;
}

.step-btn:hover {
  filter: brightness(1.1);
  transform: translateY(-1px);
}

.step-btn-yellow {
  border-left-color: #facc15;
}

.step-btn-disabled{
  background: rgb(65, 63, 59);
  border-left: none;
}

.step-btn-shadow {
  position: absolute;
  inset: 0;
  border-radius: 8px;
  box-shadow: 0px 0px 0px 2px rgba(0,0,0,0.2), 0px 10px 15px -3px rgba(0,0,0,0.1), 0px 4px 6px -4px rgba(0,0,0,0.1);
  pointer-events: none;
}

.step-label {
  font-weight: 700;
  color: #d1fae5;
  font-size: 12px;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  line-height: 16px;
}

.step-title {
  font-weight: 700;
  color: white;
  font-size: 19px;
  line-height: 20px;
}

.step-counter {
  background: rgba(0,0,0,0.2);
  border-radius: 16px;
  padding: 4px 8px;
  font-weight: 700;
  color: white;
  font-size: 19px;
  line-height: 16px;
  font-family: 'Liberation Mono', monospace;
}

.step-indicator {
  position: absolute;
  background: #facc15;
  height: 12px;
  right: 8px;
  border-radius: 50%;
  top: 8px;
  width: 12px;
}

.step-indicator.step-indicator-green {
  background: #22c55e;
}

/* ===== TEST PAGE ===== */
.test-content {
  position: relative;
  z-index: 10;
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 960px;
  padding: 24px 32px 0;
  flex: 1;
  margin: 0 auto;
}


.test-header h2 {
  font-weight: 800;
  color: #1e293b;
  font-size: 28px;
  letter-spacing: -0.5px;
  line-height: 36px;
}

.test-header p {
  font-weight: 700;
  color: #475569;
  font-size: 16px;
  margin-top: 4px;
}

.test-body {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  flex: 1;
  gap: 32px;
  padding-bottom: 40px;
}

.test-question-box {
  backdrop-filter: blur(8px);
  border-radius: 20px;
  padding: 32px 40px;
  max-width: 780px;
  width: 100%;
  text-align: center;
  box-shadow: 0px 4px 16px 0px rgba(0,0,0,0.08);
  background: rgba(255,255,255,0.65);
}

.test-question-text {
  font-weight: 600;
  color: #1e293b;
  font-size: 20px;
  line-height: 30px;
}

.test-options {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
  width: 100%;
  max-width: 780px;
}

.test-option-btn {
  flex: 1;
  min-width: 200px;
  padding: 16px 24px;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  color: white;
  font-weight: 700;
  font-size: 18px;
  line-height: 24px;
  font-family: 'Nunito', sans-serif;
  box-shadow: 0px 4px 12px 0px rgba(0,0,0,0.15);
  background: linear-gradient(180deg, #66bb6a 0%, #43a047 100%);
  transition: filter 0.2s, transform 0.2s;
}

.test-option-btn:hover {
  filter: brightness(1.1);
  transform: translateY(-1px);
}

.test-option-btn:active {
  transform: translateY(1px);
}

.test-result-item {
  border-radius: 12px;
  padding: 14px 20px;
  box-shadow: 0px 2px 8px 0px rgba(0,0,0,0.06);
  margin-bottom: 12px;
}

.test-result-correct {
  background: rgba(129,199,132,0.5);
}

.test-result-wrong {
  background: rgba(239,154,154,0.5);
}

.test-result-text {
  font-weight: 600;
  color: #1e293b;
  font-size: 16px;
  line-height: 24px;
}

.test-back-btn {
  width: 100%;
  padding: 16px 24px;
  border-radius: 12px;
  border: 2px solid #1e293b;
  cursor: pointer;
  font-weight: 700;
  font-size: 18px;
  line-height: 24px;
  color: #1e293b;
  font-family: 'Nunito', sans-serif;
  box-shadow: 0px 4px 12px 0px rgba(0,0,0,0.1);
  background: rgba(255,255,255,0.6);
  transition: background 0.2s, color 0.2s;
  margin-top: 12px;
  margin-bottom: 32px;
}

.test-back-btn:hover {
  background: #1e293b;
  color: white;
}

a.test-back-btn{
    display: block;
    text-align: center;
}

/* ===== AUTH PAGES ===== */
.auth-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  width: 100%;
  position: relative;
}

.auth-cloud-1 {
  position: absolute;
  background: rgba(255,255,255,0.4);
  filter: blur(12px);
  height: 48px;
  left: 20%;
  border-radius: 9999px;
  top: 10%;
  width: 128px;
}

.auth-cloud-2 {
  position: absolute;
  background: rgba(255,255,255,0.3);
  filter: blur(12px);
  height: 64px;
  right: 25%;
  border-radius: 9999px;
  top: 15%;
  width: 192px;
}

.auth-card {
  width: 100%;
  max-width: 440px;
  margin: 24px 16px;
  border-radius: 28px;
  box-shadow: 0px 8px 32px 0px rgba(0,0,0,0.12);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.4);
  padding: 40px 36px;
  background: rgba(255,255,255,0.75);
}

.auth-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 32px;
  justify-content: center;
}

.auth-logo img {
  width: 28px;
  height: 28px;
  object-fit: contain;
}

.auth-logo span {
  font-weight: 800;
  color: #4caf50;
  font-size: 24px;
  line-height: 32px;
}

.auth-title {
  font-weight: 800;
  color: #1e293b;
  font-size: 28px;
  letter-spacing: -0.5px;
  line-height: 36px;
  margin-bottom: 8px;
  text-align: center;
}

.auth-subtitle {
  font-weight: 500;
  color: #64748b;
  font-size: 15px;
  line-height: 22px;
  margin-bottom: 28px;
  text-align: center;
}

.auth-divider{
  font-weight: 500;
  color: #64748b;
  font-size: 15px;
  line-height: 22px;
  margin: 15px 0;  
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-label {
  font-weight: 700;
  color: #334155;
  font-size: 14px;
  line-height: 20px;
}

.form-input {
  width: 100%;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid rgba(0,0,0,0.15);
  font-size: 15px;
  outline: none;
  font-family: 'Nunito', sans-serif;
  background: rgba(255,255,255,0.8);
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form-input:focus {
  border-color: #4caf50;
  box-shadow: 0px 0px 0px 3px rgba(76,175,80,0.15);
}

.form-select {
  width: 100%;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid rgba(0,0,0,0.15);
  font-size: 15px;
  outline: none;
  font-family: 'Nunito', sans-serif;
  background: rgba(255,255,255,0.8);
  appearance: none;
  cursor: pointer;
  padding-right: 40px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23475569' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form-select:focus {
  border-color: #4caf50;
  box-shadow: 0px 0px 0px 3px rgba(76,175,80,0.15);
}

.form-checkbox-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  cursor: pointer;
  margin-top: 4px;
}

.form-checkbox {
  margin-top: 3px;
  width: 18px;
  height: 18px;
  border-radius: 4px;
  accent-color: #4caf50;
  cursor: pointer;
  flex-shrink: 0;
}

.form-checkbox-text {
  font-weight: 500;
  color: #475569;
  font-size: 13px;
  line-height: 19px;
}

.form-input.parsley-error,
.form-select.parsley-error {
  border-color: #e53935;
  box-shadow: 0px 0px 0px 3px rgba(229,57,53,0.12);
}

.parsley-errors-list {
  list-style: none;
  padding: 0;
  margin: 6px 0 0;
}

.parsley-errors-list li {
  color: #e53935;
  font-size: 12px;
  font-weight: 600;
  line-height: 18px;
}

.form-checkbox-row .parsley-errors-list {
  margin-top: 2px;
}

.auth-submit-btn {
  width: 100%;
  padding: 14px;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  color: white;
  font-weight: 700;
  font-size: 16px;
  line-height: 24px;
  font-family: 'Nunito', sans-serif;
  box-shadow: 0px 4px 12px 0px rgba(0,0,0,0.15);
  background: linear-gradient(180deg, #66bb6a 0%, #43a047 100%);
  margin-top: 8px;
  transition: filter 0.2s, transform 0.2s;
}

.auth-submit-btn:hover {
  filter: brightness(1.1);
  transform: translateY(-1px);
}

.auth-submit-btn:active {
  transform: translateY(1px);
}

.auth-footer {
  text-align: center;
  margin-top: 24px;
  font-weight: 500;
  color: #64748b;
  font-size: 14px;
  line-height: 20px;
}

.auth-footer a {
  color: #4caf50;
  font-weight: 700;
}

.auth-footer a:hover {
  text-decoration: underline;
}

/* ===== BURGER MENU ===== */
.burger-btn {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 4px;
  border-radius: 8px;
  transition: background 0.2s;
}

.burger-btn:hover {
  background: rgba(0,0,0,0.05);
}

.burger-line {
  display: block;
  width: 22px;
  height: 2px;
  background: #475569;
  border-radius: 2px;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.burger-btn.open .burger-line:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.burger-btn.open .burger-line:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.burger-btn.open .burger-line:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.mobile-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(255,255,255,0.97);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255,255,255,0.3);
  box-shadow: 0 8px 24px rgba(0,0,0,0.1);
  flex-direction: column;
  padding: 8px 0 16px;
  animation: mobileMenuDown 0.25s ease-out both;
}

@keyframes mobileMenuDown {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

.mobile-menu.open {
  display: flex;
}

.mobile-menu a {
  font-weight: 700;
  color: #475569;
  font-size: 15px;
  letter-spacing: 0.35px;
  text-transform: uppercase;
  padding: 12px 24px;
  transition: background 0.15s, color 0.15s;
}

.mobile-menu a:hover {
  background: rgba(76,175,80,0.08);
  color: #4caf50;
}

@media (max-width: 768px) {
  .header-nav {
    display: none;
  }

  .burger-btn {
    display: flex;
  }

  .header {
    position: relative;
  }

  .categories-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .main-title {
    font-size: 32px;
    line-height: 40px;
    letter-spacing: -0.8px;
  }

  .main-subtitle {
    font-size: 16px;
    line-height: 24px;
  }

  .main-center {
    gap: 32px;
    padding: 0 16px;
  }

  .lesson-title {
    font-size: 32px;
    line-height: 38px;
  }

  .lesson-desc-text {
    font-size: 16px;
    line-height: 24px;
  }

  .lesson-flow {
    padding: 100px 100px 40px;
    gap: 24px;
  }

  .lesson-video-responsive {
    border-radius: 16px;
    border-width: 3px;
  }

  .steps-flow {
    flex-direction: column;
    gap: 10px;
  }

  .steps-flow > .anim-pop-in {
    flex: 0 0 100%;
  }

  .step-btn,
  .step-btn-yellow {
    width: 100%;
    height: 64px;
  }

  .test-content {
    padding: 20px 16px 0;
  }

  .test-header h2 {
    font-size: 22px;
    line-height: 30px;
  }

  .test-question-box {
    padding: 24px 20px;
  }

  .test-question-text {
    font-size: 17px;
    line-height: 26px;
  }

  .test-option-btn {
    font-size: 16px;
    padding: 14px 20px;
    min-width: 140px;
  }

  .test-back-btn {
    font-size: 16px;
    padding: 14px 20px;
  }

  .test-result-text {
    font-size: 14px;
    line-height: 22px;
  }

  .character-image-small img {
    height: 200px;
  }

  .auth-card {
    padding: 32px 24px;
    border-radius: 24px;
    margin: 16px 12px;
  }

  .auth-title {
    font-size: 24px;
    line-height: 32px;
  }
}

@media (max-width: 414px) {
  .categories-grid {
    grid-template-columns: 1fr;
  }

  .main-title {
    font-size: 26px;
    line-height: 34px;
  }

  .main-center {
    gap: 24px;
  }

  .lesson-title {
    font-size: 26px;
    line-height: 32px;
  }

  .lesson-desc-text {
    font-size: 15px;
    line-height: 22px;
  }

  .test-header h2 {
    font-size: 20px;
    line-height: 28px;
  }

  .test-question-text {
    font-size: 16px;
    line-height: 24px;
  }

  .test-option-btn {
    min-width: 100%;
  }

  .test-body {
    gap: 24px;
    padding-bottom: 24px;
  }

  .character-image-small img {
    height: 150px;
  }

  .auth-card {
    padding: 28px 20px;
    border-radius: 20px;
  }

  .auth-title {
    font-size: 22px;
  }

  .auth-subtitle {
    font-size: 14px;
    margin-bottom: 20px;
  }
}

/* ===== UTILITY ===== */
.hidden {
  display: none !important;
}



/* ===== PERSONAL PAGE ===== */
.personal-flow {
  position: relative;
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 960px;
  padding: 32px 24px 120px;
  gap: 32px;
  margin: 0 auto;
}

/* --- Profile card --- */
.profile-card {
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,0.4);
  border-radius: 28px;
  box-shadow: 0px 8px 32px 0px rgba(0,0,0,0.1);
  /*padding: 32px 40px;*/
  background: rgba(255,255,255,0.7);
  width: 100%;
  /*align-items: center;
  gap: 32px;*/
  
  padding: 28px 36px;
  display: flex;
  flex-direction: column;
  gap: 0;
}

/* Top row */
.profile-top {
  display: flex;
  align-items: center;
  gap: 20px;
  padding-bottom: 24px;
}
/* Кнопка выхода */
.btn-logout {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  font-family: 'Nunito', sans-serif;
  font-weight: 700;
  font-size: 14px;
  color: #ef4444;
  background: rgba(239,68,68,0.08);
  border: 1.5px solid rgba(239,68,68,0.18);
  border-radius: 12px;
  padding: 8px 16px;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, transform 0.15s;
  line-height: 1;
}
.btn-logout:hover {
  background: rgba(239,68,68,0.14);
  border-color: rgba(239,68,68,0.35);
  transform: translateY(-1px);
}
/* Разделитель */
.profile-divider {
  height: 1px;
  background: rgba(0,0,0,0.07);
  margin: 0 -4px;
}
/* Сетка с врачом / поддержкой / ссылками */
.profile-meta-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 12px;
  padding: 20px 0;
}
.meta-tile {
  background: rgba(255,255,255,0.55);
  border: 1px solid rgba(255,255,255,0.6);
  border-radius: 16px;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 7px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}
.meta-tile-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 800;
  color: #334155;
  font-size: 13px;
  line-height: 18px;
}
.meta-icon { font-size: 15px; flex-shrink: 0; }
.meta-tile-name {
  font-weight: 700;
  color: #1e293b;
  font-size: 13px;
  line-height: 18px;
}
.meta-link {
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
  color: #4caf50;
  font-size: 13px;
  line-height: 18px;
  transition: color 0.15s;
  text-decoration: none;
}
.meta-link:hover { color: #388e3c; gap: 8px; }
.meta-link svg { flex-shrink: 0; opacity: 0.8; }
.meta-link-icon { font-weight: 700; }

.profile-avatar {
  flex-shrink: 0;
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: linear-gradient(135deg, #4caf50, #22c55e);
  border: 4px solid white;
  box-shadow: 0px 8px 24px rgba(0,0,0,0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  font-weight: 800;
  color: white;
}

.profile-info { flex: 1; min-width: 0; }

.profile-name {
  font-weight: 800;
  color: #1e293b;
  font-size: 28px;
  letter-spacing: -0.5px;
  line-height: 36px;
  margin-bottom: 4px;
}

.profile-label {
  font-weight: 600;
  color: #64748b;
  font-size: 15px;
  line-height: 22px;
}

.profile-stats {
  /*display: flex;
  gap: 16px;
  flex-shrink: 0;*/
  display: flex;
  gap: 12px;
  padding-top: 20px;
}

.stat-item {
  flex:1;  
  text-align: center;
  background: rgba(255,255,255,0.6);
  border-radius: 16px;
  padding: 16px 20px;
  border: 1px solid rgba(255,255,255,0.5);
  box-shadow: 0px 2px 8px rgba(0,0,0,0.06);
  min-width: 0px;
}

.stat-value {
  font-weight: 800;
  color: #1e293b;
  font-size: 26px;
  line-height: 34px;
}

.stat-value.green { color: #4caf50; }
.stat-value.blue  { color: #1e88e5; }

.stat-label {
  font-weight: 600;
  color: #64748b;
  font-size: 11px;
  line-height: 16px;
  letter-spacing: 0.3px;
  text-transform: uppercase;
  margin-top: 2px;
}

/* --- Section --- */
.section-block { width: 100%; display: flex; flex-direction: column; gap: 16px; }

.section-title {
  font-weight: 800;
  color: #1e293b;
  font-size: 22px;
  letter-spacing: -0.3px;
  line-height: 30px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.section-title-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: rgba(76,175,80,0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
}

/* --- Test result card --- */
.test-result-card {
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,0.4);
  border-radius: 20px;
  box-shadow: 0px 4px 16px 0px rgba(0,0,0,0.08);
  background: rgba(255,255,255,0.65);
  padding: 24px 28px;
  transition: box-shadow 0.2s, transform 0.2s;
}

.test-result-card:hover {
  box-shadow: 0px 8px 28px 0px rgba(0,0,0,0.12);
  transform: translateY(-2px);
}

.test-result-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.test-result-card-left {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
  flex: 1;
}

.test-result-icon {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
}

.test-result-info { min-width: 0; flex: 1; }

.test-result-name {
  font-weight: 800;
  color: #1e293b;
  font-size: 17px;
  line-height: 24px;
}

.test-result-date {
  font-weight: 600;
  color: #64748b;
  font-size: 13px;
  line-height: 20px;
  margin-top: 2px;
}

/* Progress bar */
.progress-bar-wrap {
  width: 100%;
  height: 6px;
  background: rgba(0,0,0,0.08);
  border-radius: 3px;
  overflow: hidden;
  margin-top: 8px;
}

.progress-bar-fill {
  height: 100%;
  border-radius: 3px;
}

.fill-excellent { background: linear-gradient(90deg, #66bb6a, #43a047); }
.fill-good      { background: linear-gradient(90deg, #42a5f5, #1e88e5); }
.fill-average   { background: linear-gradient(90deg, #ffa726, #fb8c00); }
.fill-poor      { background: linear-gradient(90deg, #ef5350, #e53935); }

/* Score badge */
.test-result-score-badge {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  border: 3px solid;
  font-weight: 800;
  font-size: 22px;
  line-height: 1;
}

.score-excellent { border-color:#4caf50; color:#4caf50; background:rgba(76,175,80,0.08); }
.score-good      { border-color:#1e88e5; color:#1e88e5; background:rgba(30,136,229,0.08); }
.score-average   { border-color:#fb8c00; color:#fb8c00; background:rgba(251,140,0,0.08); }
.score-poor      { border-color:#e53935; color:#e53935; background:rgba(229,57,53,0.08); }

.score-badge-label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.2px;
  margin-top: 2px;
}

/* Card footer row */
.card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.card-footer-badges { display: flex; gap: 8px; align-items: center; }

.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-weight: 700;
  font-size: 13px;
  border-radius: 8px;
  padding: 4px 10px;
  font-family: 'Nunito', sans-serif;
}

.badge-correct { background: rgba(76,175,80,0.12);  color: #4caf50; }
.badge-wrong   { background: rgba(229,57,53,0.1);  color: #e53935; }
.badge-total   { font-weight: 600; color: #64748b; font-size: 13px; }

/* Expand button */
.expand-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: none;
  cursor: pointer;
  font-family: 'Nunito', sans-serif;
  font-weight: 700;
  font-size: 13px;
  color: #475569;
  padding: 0;
  transition: color 0.2s;
}

.expand-btn:hover { color: #4caf50; }

.expand-icon {
  font-size: 10px;
  display: inline-block;
  transition: transform 0.2s;
}

.expand-icon.open { transform: rotate(180deg); }

/* Questions breakdown */
.questions-breakdown {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 16px;
}

.question-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  border-radius: 10px;
  padding: 10px 14px;
}

.question-row-correct { background: rgba(129,199,132,0.35); }
.question-row-wrong   { background: rgba(239,154,154,0.35); }

.question-status-icon {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  margin-top: 1px;
  color: white;
}

.icon-correct { background: #4caf50; }
.icon-wrong   { background: #e53935; }

.question-text {
  font-weight: 600;
  color: #1e293b;
  font-size: 14px;
  line-height: 22px;
}

.question-answer {
  font-weight: 500;
  color: #475569;
  font-size: 13px;
  line-height: 18px;
  margin-top: 2px;
}

.question-answer strong { color: #4caf50; }

/* ===== RESPONSIVE ===== */

@media (max-width: 1920px) {

  .lesson-flow{
      min-height: 1475px;
  } 
  .lesson-content.detail .lesson-flow{
     min-height: 1375px;    
  }
      
}


@media (max-width: 1366px) {
    
  .lesson-flow{
      min-height: 1470px;
  }  
  
  .lesson-content.detail .lesson-flow{
     min-height: 1365px;    
  }
      
  .bg-nature {
    /*background-image: linear-gradient(180deg, rgb(79,195,247) 0%, rgb(179,229,252) 30%, rgb(225,245,254) 45%, rgb(200,230,201) 45%, rgb(129,199,132) 100%);*/
        background: url('../images/big.gif') no-repeat center bottom;
  }

  .bg-lesson {
     /* background-image: linear-gradient(180deg, rgb(79,195,247) 0%, rgb(129,212,249) 26.923%, rgb(225,245,254) 52.404%, rgb(200,230,201) 61.058%, rgb(129,199,132) 99.519%);*/
      background: url('../images/big.gif') no-repeat center bottom;
  }    
    
}

@media (max-width: 768px) {
    
   .lesson-flow{
      min-height: 1500px;
    }   
    
  .header-nav { display: none; }
  .burger-btn { display: flex; }
  .header { position: relative; }

  .profile-card { /*flex-direction: column; text-align: center; padding: 24px 20px;*/padding: 20px 18px;  }
  .profile-top { flex-wrap: wrap; gap: 14px; }
  .profile-avatar { width: 60px; height: 60px; font-size: 24px; }
  .profile-name { font-size: 20px; line-height: 28px; }
  .btn-logout { margin-left: auto; }
  .profile-meta-grid { grid-template-columns: 1fr 1fr; }
  
  .profile-stats { width: 100%;/* justify-content: center;*/justify-content: stretch; }
  .personal-flow { padding: 24px 16px 100px; }
  .test-result-card { padding: 20px 18px; }
  .character-image-small img { height: 200px; }
  /*.stat-item { padding: 12px 14px; min-width: 70px; }
  .stat-value { font-size: 22px; }*/
  .stat-item { flex: 1; padding: 12px 10px; min-width: 0; }
  .stat-value { font-size: 22px; }
  
  .bg-nature {
    /*background-image: linear-gradient(180deg, rgb(79,195,247) 0%, rgb(179,229,252) 30%, rgb(225,245,254) 45%, rgb(200,230,201) 45%, rgb(129,199,132) 100%);*/
        background: url('../images/medium.gif') no-repeat center bottom;
  }

  .bg-lesson {
     /* background-image: linear-gradient(180deg, rgb(79,195,247) 0%, rgb(129,212,249) 26.923%, rgb(225,245,254) 52.404%, rgb(200,230,201) 61.058%, rgb(129,199,132) 99.519%);*/
      background: url('../images/medium.gif') no-repeat center bottom;
  }

}

@media (max-width: 600px) {
  .lesson-flow {
    padding: 50px 50px 40px;
    gap: 24px;
    min-height: 1425px;
  }
 
}  

@media (max-width: 520px) {
  .profile-meta-grid { grid-template-columns: 1fr; }
  .btn-logout { width: 100%; justify-content: center; margin-left: 0; }
}

@media (max-width: 414px) {
  
  .lesson-flow{
     min-height: 1235px; 
  }  
    
  .profile-stats { gap: 10px; }
  .test-result-card-header { flex-wrap: wrap; }
  
  .bg-nature {
    /*background-image: linear-gradient(180deg, rgb(79,195,247) 0%, rgb(179,229,252) 30%, rgb(225,245,254) 45%, rgb(200,230,201) 45%, rgb(129,199,132) 100%);*/
        background: url('../images/small.gif') no-repeat center bottom;
  }

  .bg-lesson {
     /* background-image: linear-gradient(180deg, rgb(79,195,247) 0%, rgb(129,212,249) 26.923%, rgb(225,245,254) 52.404%, rgb(200,230,201) 61.058%, rgb(129,199,132) 99.519%);*/
      background: url('../images/small.gif') no-repeat center bottom;
  }
  
}