.auth-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 80px);
  background: linear-gradient(135deg, #667eea, #764ba2);
  padding: 20px;
}

.auth-container {
  width: 100%;
  max-width: 420px;
}
/* Базовая кнопка */
.btn {
  display: inline-block;
  padding: 12px 20px;
  font-size: 15px;
  font-weight: 600;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  text-align: center;
  transition: all 0.2s ease;
}

/* Основная кнопка */
.btn.primary {
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: #fff;
  box-shadow: 0 4px 12px rgba(102,126,234,0.3);
}

.btn.primary:hover {
  background: linear-gradient(135deg, #5a67d8, #6b46c1);
}

/* Растягиваем на всю ширину */
.btn.w-full {
  width: 100%;
}

/* Большая кнопка */
.btn.big {
  font-size: 16px;
  padding: 14px 22px;
}

.auth-box {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.1);
  padding: 32px;
  text-align: center;
}

.auth-header i {
  font-size: 48px;
  color: var(--accent, #667eea);
  margin-bottom: 12px;
}

.auth-box h1 {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 6px;
}

.auth-box .subtitle {
  font-size: 14px;
  color: #666;
  margin-bottom: 20px;
}

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

.auth-form label {
  font-weight: 600;
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 6px;
}

.auth-form input {
  width: 100%;
  padding: 12px 14px;
  border-radius: 8px;
  border: 1px solid #ddd;
  transition: 0.2s;
}

.auth-form input:focus {
  border-color: var(--accent, #667eea);
  outline: none;
  box-shadow: 0 0 0 3px rgba(102,126,234,0.15);
}

.auth-error {
  background: #ffe6e6;
  color: #c00;
  padding: 10px;
  border-radius: 8px;
  font-size: 14px;
  margin-bottom: 16px;
}

.auth-links {
  margin-top: 20px;
  font-size: 14px;
  color: #555;
}

.auth-links a {
  color: var(--accent, #667eea);
  font-weight: 600;
  text-decoration: none;
}

.auth-links span {
  margin: 0 6px;
  color: #aaa;
}


:root {
    /* Цветовая палитра */
    --primary: #6366F1;
    --primary-dark: #4F46E5;
    --secondary: #EC4899;
    --accent: #10B981;
    --warning: #F59E0B;
    --danger: #EF4444;
    
    /* Градиенты */
    --gradient-primary: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gradient-secondary: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    --gradient-success: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    
    /* Цвета фона */
    --bg-primary: #FAFBFC;
    --bg-secondary: #F8FAFC;
    --bg-dark: #1E293B;
    --bg-card: #FFFFFF;
    
    /* Текст */
    --text-primary: #1E293B;
    --text-secondary: #64748B;
    --text-light: #94A3B8;
    --text-white: #FFFFFF;
    
    /* Тени */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    
    /* Радиусы */
    --radius-sm: 6px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    
    /* Переходы */
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-fast: all 0.15s ease-out;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background: var(--bg-primary);
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}
.course-actions {
    display: flex;
    gap: 12px;
    margin-top: 15px;
}
.course-actions .course-cta {
    flex: 1;
}
.course-actions .more-link {
    background: #fff;
    color: var(--primary);
    border: 2px solid var(--primary);
    text-align: center;
}
.course-actions .more-link:hover {
    background: var(--primary);
    color: #fff;
}

/* Навигация */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    z-index: 1000;
    padding: 15px 0;
    transition: var(--transition);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 24px;
    font-weight: 800;
    color: var(--primary);
}

.nav-logo i {
    font-size: 28px;
}

.nav-menu {
    display: flex;
    gap: 30px;
    list-style: none;
}

.nav-link {
    text-decoration: none;
    color: var(--text-primary);
    font-weight: 500;
    transition: var(--transition);
    position: relative;
}

.nav-link:hover {
    color: var(--primary);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: var(--transition);
}

.nav-link:hover::after {
    width: 100%;
}

.nav-auth {
    display: flex;
    gap: 15px;
}
/* ===================== */
/*        FOOTER         */
/* ===================== */
.footer {
    background: var(--bg-dark);
    color: var(--text-white);
    padding: 60px 20px 30px;
    margin-top: 60px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer h3, 
.footer h4 {
    color: var(--text-white);
    margin-bottom: 20px;
    font-weight: 700;
}

.footer-about p {
    color: var(--text-light);
    font-size: 0.95rem;
    line-height: 1.6;
}

.footer-links ul {
    list-style: none;
    padding: 0;
}

.footer-links ul li {
    margin-bottom: 10px;
}

.footer-links a {
    color: var(--text-light);
    text-decoration: none;
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--primary);
}

.footer-contact p {
    margin-bottom: 10px;
    color: var(--text-light);
    display: flex;
    align-items: center;
    gap: 8px;
}

.footer-social .social-icons {
    display: flex;
    gap: 12px;
    margin-top: 10px;
}

.footer-social a {
    color: var(--text-light);
    font-size: 18px;
    transition: var(--transition);
}

.footer-social a:hover {
    color: var(--primary);
    transform: translateY(-3px);
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 20px;
    text-align: center;
    font-size: 0.9rem;
    color: var(--text-light);
}

.btn-login {
    background: transparent;
    border: 1px solid var(--primary);
    color: var(--primary);
    padding: 10px 20px;
    border-radius: var(--radius-md);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.btn-login:hover {
    background: var(--primary);
    color: white;
}

.btn-register {
    background: var(--primary);
    border: none;
    color: white;
    padding: 10px 20px;
    border-radius: var(--radius-md);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.btn-register:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.nav-toggle span {
    width: 25px;
    height: 3px;
    background: var(--text-primary);
    margin: 3px 0;
    transition: var(--transition);
}

/* Главная секция */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.hero-particles {
    position: absolute;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(circle at 25% 25%, rgba(255, 255, 255, 0.1) 2px, transparent 2px),
        radial-gradient(circle at 75% 75%, rgba(255, 255, 255, 0.1) 2px, transparent 2px);
    background-size: 50px 50px;
    animation: float 20s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(180deg); }
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    padding: 100px 0 50px;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 20px;
    color: white;
}

.gradient-text {
    background: linear-gradient(135deg, #FFD700, #FFA500);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.highlight {
    color: #FFD700;
    position: relative;
}

.highlight::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: #FFD700;
    border-radius: 2px;
}

.hero-subtitle {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 30px;
    line-height: 1.6;
}

.hero-stats {
    display: flex;
    gap: 40px;
    margin-bottom: 40px;
}

.stat {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 2.5rem;
    font-weight: 800;
    color: #FFD700;
    line-height: 1;
}

.stat-text {
    color: rgba(255, 255, 255, 0.8);
    font-weight: 500;
}

.hero-buttons {
    display: flex;
    gap: 20px;
}

.btn-primary, .btn-secondary {
    padding: 15px 30px;
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    display: flex;
    align-items: center;
    gap: 10px;
}

.btn-primary {
    background: #FFD700;
    color: var(--text-primary);
}

.btn-primary:hover {
    background: #FFA500;
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-3px);
}

/* Hero Visual */
.hero-visual {
    position: relative;
}

.hero-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    padding: 30px;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.floating {
    animation: cardFloat 6s ease-in-out infinite;
}

@keyframes cardFloat {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-15px) rotate(1deg); }
}

.card-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 25px;
}

.avatar {
    width: 50px;
    height: 50px;
    background: var(--gradient-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 20px;
}

.user-info h4 {
    color: var(--text-primary);
    margin-bottom: 5px;
}

.user-info p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.progress-section h5 {
    color: var(--text-primary);
    margin-bottom: 10px;
    font-weight: 600;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: #E5E7EB;
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 10px;
}

.progress-fill {
    height: 100%;
    background: var(--gradient-success);
    border-radius: 10px;
    animation: progressGrow 3s ease-out;
}

@keyframes progressGrow {
    0% { width: 0%; }
    100% { width: 87%; }
}

.progress-text {
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
}

.achievement {
    margin-top: 20px;
    padding: 15px;
    background: linear-gradient(135deg, #FFD700, #FFA500);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-primary);
    font-weight: 600;
}

.achievement i {
    font-size: 20px;
}

/* Floating Elements */
.floating-elements {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
}

.float-item {
    position: absolute;
    width: 60px;
    height: 60px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
}

.item-1 {
    top: 10%;
    right: 10%;
    animation: floatMove 8s ease-in-out infinite;
}

.item-2 {
    top: 60%;
    right: 80%;
    animation: floatMove 10s ease-in-out infinite reverse;
}

.item-3 {
    bottom: 20%;
    right: 20%;
    animation: floatMove 7s ease-in-out infinite;
}

.item-4 {
    top: 30%;
    left: -20px;
    animation: floatMove 9s ease-in-out infinite reverse;
}

@keyframes floatMove {
    0%, 100% { transform: translateY(0px) translateX(0px) rotate(0deg); }
    25% { transform: translateY(-20px) translateX(10px) rotate(90deg); }
    50% { transform: translateY(-10px) translateX(-10px) rotate(180deg); }
    75% { transform: translateY(-25px) translateX(5px) rotate(270deg); }
}

/* Секции */
section {
    padding: 80px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-header h2 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 15px;
    color: var(--text-primary);
}

.section-header p {
    font-size: 1.1rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

/* Features */
.features {
    background: var(--bg-secondary);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
}

.feature-card {
    background: var(--bg-card);
    padding: 40px 30px;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-md);
    text-align: center;
    transition: var(--transition);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-xl);
}

.feature-icon {
    width: 80px;
    height: 80px;
    background: var(--gradient-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    color: white;
    font-size: 30px;
}

.feature-card h3 {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 15px;
    color: var(--text-primary);
}

.feature-card p {
    color: var(--text-secondary);
    line-height: 1.6;
}

/* Courses */
.courses {
    background: var(--bg-primary);
}

.course-filters {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 50px;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 12px 24px;
    border: 2px solid transparent;
    background: var(--bg-card);
    color: var(--text-secondary);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: var(--transition);
    font-weight: 500;
}

.filter-btn:hover, .filter-btn.active {
    background: var(--primary);
    color: white;
    transform: translateY(-2px);
}

.courses-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 50px;
}

.course-card {
    background: var(--bg-card);
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.course-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-xl);
}

.course-header {
    padding: 20px;
    background: var(--gradient-primary);
    color: white;
    position: relative;
}

.course-subject {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 5px;
}

.course-level {
    opacity: 0.9;
    font-weight: 500;
}

.course-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    padding: 5px 12px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-sm);
    font-size: 0.8rem;
    font-weight: 600;
}

.course-content {
    padding: 25px;
}

.course-description {
    color: var(--text-secondary);
    margin-bottom: 20px;
    line-height: 1.6;
}

.course-stats {
    display: flex;
    justify-content: space-between;
    margin-bottom: 25px;
}

.course-stat {
    text-align: center;
}

.course-stat-number {
    display: block;
    font-weight: 700;
    color: var(--text-primary);
    font-size: 1.1rem;
}

.course-stat-text {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.course-price {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.price-current {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--primary);
}

.price-old {
    text-decoration: line-through;
    color: var(--text-light);
    font-size: 1rem;
}

.course-cta {
    width: 100%;
    padding: 15px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.course-cta:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}

.courses-cta {
    text-align: center;
}

.btn-primary.large {
    font-size: 1.1rem;
    padding: 18px 40px;
}

/* CTA Section */
.cta-section {
    background: var(--gradient-primary);
    color: white;
}

.cta-content {
    text-align: center;
    margin-bottom: 50px;
}

.cta-content h2 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 15px;
}

.cta-content p {
    font-size: 1.2rem;
    opacity: 0.9;
    margin-bottom: 30px;
}

.cta-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.success-stories {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.story {
    background: rgba(255, 255, 255, 0.1);
    padding: 20px;
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    gap: 15px;
}

.story-avatar {
    font-size: 2rem;
    flex-shrink: 0;
}

.story-text {
    font-size: 0.95rem;
    line-height: 1.5;
}

/* Модальные окна */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
}

.modal-content {
    background-color: var(--bg-card);
    margin: 5% auto;
    padding: 40px;
    border-radius: var(--radius-xl);
    width: 90%;
    max-width: 450px;
    position: relative;
    animation: modalSlideIn 0.3s ease-out;
}

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

.close {
    color: var(--text-light);
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    position: absolute;
    top: 15px;
    right: 20px;
}

.close:hover {
    color: var(--text-primary);
}

.modal-content h2 {
    margin-bottom: 30px;
    color: var(--text-primary);
    text-align: center;
}

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

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

.form-group label {
    font-weight: 600;
    color: var(--text-primary);
}

.form-group input,
.form-group select {
    padding: 12px 16px;
    border: 2px solid #E5E7EB;
    border-radius: var(--radius-md);
    font-size: 1rem;
    transition: var(--transition);
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.full-width {
    width: 100%;
}

.auth-switch {
    text-align: center;
    margin-top: 20px;
    color: var(--text-secondary);
}

.auth-switch a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}

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

/* Utility classes */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mt-1 { margin-top: 0.25rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-3 { margin-top: 1rem; }
.mt-4 { margin-top: 1.5rem; }
.mt-5 { margin-top: 3rem; }

.mb-1 { margin-bottom: 0.25rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 1rem; }
.mb-4 { margin-bottom: 1.5rem; }
.mb-5 { margin-bottom: 3rem; }

.hidden { display: none; }
.visible { display: block; }

/* Скролл */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}