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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: #f5f7fa;
  color: #333;
}

/* Sidebar */
.sidebar {
  position: fixed;
  left: -260px;
  top: 0;
  width: 260px;
  height: 100vh;
  background: #1e293b;
  color: white;
  transition: left 0.3s;
  z-index: 1000;
}

.sidebar-open {
  left: 0;
}

.sidebar-header {
  padding: 20px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}

.logo {
  color: white;
  text-decoration: none;
  font-size: 20px;
  font-weight: bold;
}

.logo span {
  display: inline-block;
  background: #667eea;
  padding: 5px 10px;
  border-radius: 5px;
  margin-right: 10px;
}

.sidebar-nav {
  padding: 20px 0;
}

.nav-link {
  display: block;
  padding: 12px 20px;
  color: #cbd5e1;
  text-decoration: none;
  transition: all 0.2s;
}

.nav-link:hover, .nav-link.active {
  background: rgba(255,255,255,0.1);
  color: white;
}

.nav-divider {
  height: 1px;
  background: rgba(255,255,255,0.1);
  margin: 10px 0;
}

/* Main Wrapper */
.main-wrapper {
  margin-left: 0;
  min-height: 100vh;
}

@media (min-width: 768px) {
  .sidebar {
    left: 0;
  }
  .main-wrapper {
    margin-left: 260px;
  }
}

/* Header */
.header {
  background: white;
  padding: 15px 20px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  display: flex;
  align-items: center;
  gap: 20px;
}

.menu-toggle {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  display: block;
}

@media (min-width: 768px) {
  .menu-toggle {
    display: none;
  }
}

.header-search {
  flex: 1;
  max-width: 400px;
}

.search-input {
  width: 100%;
  padding: 8px 15px;
  border: 1px solid #e2e8f0;
  border-radius: 5px;
  font-size: 14px;
}

.header-right {
  margin-left: auto;
}

.user-info {
  color: #64748b;
  font-size: 14px;
}

/* Content */
.content {
  padding: 30px 20px;
  max-width: 1200px;
  margin: 0 auto;
}

/* Cards */
.card {
  background: white;
  border-radius: 10px;
  padding: 20px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
  margin-bottom: 20px;
}

/* Stats Grid */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.stat-card {
  background: white;
  padding: 25px;
  border-radius: 10px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
  border-left: 4px solid #667eea;
}

.stat-label {
  color: #64748b;
  font-size: 14px;
  margin-bottom: 10px;
}

.stat-value {
  font-size: 32px;
  font-weight: bold;
  color: #1e293b;
}

/* Buttons */
.btn {
  padding: 10px 20px;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-size: 14px;
  text-decoration: none;
  display: inline-block;
}

.btn-primary {
  background: #667eea;
  color: white;
}

.btn-primary:hover {
  background: #5568d3;
}

.btn-secondary {
  background: #e2e8f0;
  color: #475569;
}

/* Table */
.table {
  width: 100%;
  background: white;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.table th, .table td {
  padding: 15px;
  text-align: left;
  border-bottom: 1px solid #e2e8f0;
}

.table th {
  background: #f8fafc;
  font-weight: 600;
  color: #475569;
}

/* Modal */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0,0,0,0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
}

.modal {
  background: white;
  border-radius: 10px;
  padding: 30px;
  max-width: 500px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 15px;
  border-bottom: 2px solid #e2e8f0;
}

.modal-title {
  font-size: 20px;
  font-weight: bold;
}

.modal-close {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: #64748b;
}

/* Forms */
.form-group {
  margin-bottom: 20px;
}

.form-label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: #475569;
}

.form-input {
  width: 100%;
  padding: 10px 15px;
  border: 2px solid #e2e8f0;
  border-radius: 5px;
  font-size: 14px;
}

.form-input:focus {
  outline: none;
  border-color: #667eea;
}

/* Page Header */
.page-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
}

.page-title {
  font-size: 28px;
  font-weight: bold;
  color: #1e293b;
}

/* Empty State */
.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: #64748b;
}

.empty-state h2 {
  margin-bottom: 10px;
  color: #1e293b;
}
/* === Base Styles === */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: #f5f7fa;
    color: #1a1a1a;
    line-height: 1.6;
}

/* === Sidebar === */
.sidebar {
    width: 260px;
    background: linear-gradient(180deg, #1e293b 0%, #0f172a 100%);
    color: white;
    padding: 20px 0;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
    z-index: 100;
    box-shadow: 4px 0 10px rgba(0,0,0,0.1);
}

.sidebar-brand {
    padding: 0 20px 30px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: white;
    font-weight: 700;
    font-size: 22px;
}

.logo-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 20px;
}

.logo-text {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.sidebar-nav {
    padding: 20px 0;
}

.nav-section {
    margin-bottom: 30px;
}

.nav-section-title {
    padding: 0 20px 10px;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #94a3b8;
    font-weight: 600;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    color: #cbd5e1;
    text-decoration: none;
    transition: all 0.3s;
    font-size: 14px;
}

.nav-item:hover {
    background: rgba(255,255,255,0.05);
    color: white;
    padding-left: 24px;
}

.nav-item.active {
    background: linear-gradient(90deg, rgba(102,126,234,0.2) 0%, transparent 100%);
    color: #667eea;
    border-left: 3px solid #667eea;
}

.nav-item span {
    font-size: 18px;
}

/* === Main Content === */
.main {
    margin-left: 260px;
    min-height: 100vh;
    padding: 0;
}

/* === Header === */
.header {
    background: white;
    padding: 16px 32px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 10;
}

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

.mobile-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #64748b;
}

.header-search {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #f1f5f9;
    padding: 8px 16px;
    border-radius: 8px;
    min-width: 300px;
}

.header-search input {
    border: none;
    background: none;
    outline: none;
    font-size: 14px;
    width: 100%;
}

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

.header-btn {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    color: #64748b;
    transition: all 0.2s;
    position: relative;
}

.header-btn:hover {
    color: #667eea;
    transform: scale(1.1);
}

.user-avatar {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.user-avatar:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(102,126,234,0.4);
}

/* === Content Area === */
.content {
    padding: 32px;
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 40px;
}

.dashboard-title {
    font-size: 32px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 8px;
}

.dashboard-subtitle {
    color: #64748b;
    font-size: 15px;
}

/* === Buttons === */
.btn {
    padding: 10px 20px;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(102,126,234,0.4);
}

.btn-secondary {
    background: #f1f5f9;
    color: #475569;
}

.btn-secondary:hover {
    background: #e2e8f0;
}

.btn-lg {
    padding: 14px 28px;
    font-size: 16px;
}

/* === Stats Grid === */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    margin-bottom: 40px;
}

.stat-card {
    background: white;
    border-radius: 16px;
    padding: 28px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    transition: all 0.3s;
    border: 2px solid transparent;
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.1);
}

.stat-card-primary {
    border-color: #3b82f6;
}

.stat-card-success {
    border-color: #10b981;
}

.stat-card-warning {
    border-color: #f59e0b;
}

.stat-card-info {
    border-color: #8b5cf6;
}

.stat-icon {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    margin-bottom: 16px;
}

.stat-card-success .stat-icon {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
}

.stat-card-warning .stat-icon {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}

.stat-card-info .stat-icon {
    background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%);
}

.stat-label {
    font-size: 14px;
    color: #64748b;
    margin-bottom: 8px;
}

.stat-value {
    font-size: 42px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 8px;
}

.stat-change {
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 4px;
    color: #10b981;
}

.stat-change.neutral {
    color: #64748b;
}

/* === Quick Actions === */
.quick-actions {
    margin-bottom: 40px;
}

.section-title {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 20px;
    color: #1e293b;
}

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

.action-card {
    background: white;
    border-radius: 12px;
    padding: 24px;
    border: 1px solid #e2e8f0;
    display: flex;
    gap: 16px;
    transition: all 0.3s;
}

.action-card:hover {
    border-color: #667eea;
    box-shadow: 0 4px 12px rgba(102,126,234,0.1);
    transform: translateY(-2px);
}

.action-icon {
    font-size: 32px;
}

.action-content h3 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 8px;
    color: #1e293b;
}

.action-content p {
    font-size: 14px;
    color: #64748b;
    margin-bottom: 12px;
}

.action-link {
    color: #667eea;
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
}

.action-link:hover {
    text-decoration: underline;
}

/* === Help Section === */
.help-section {
    margin-bottom: 40px;
}

.help-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 16px;
}

.help-card {
    background: white;
    border-radius: 12px;
    padding: 20px;
    display: flex;
    gap: 16px;
    border: 1px solid #e2e8f0;
    text-decoration: none;
    transition: all 0.3s;
}

.help-card:hover {
    border-color: #667eea;
    box-shadow: 0 4px 12px rgba(102,126,234,0.1);
    transform: translateY(-2px);
}

.help-icon {
    font-size: 28px;
}

.help-content h3 {
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 4px;
    color: #1e293b;
}

.help-content p {
    font-size: 13px;
    color: #64748b;
}

/* === Responsive === */
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
    }
    
    .sidebar.open {
        transform: translateX(0);
    }
    
    .main {
        margin-left: 0;
    }
    
    .mobile-toggle {
        display: block;
    }
    
    .header-search {
        min-width: 200px;
    }
    
    .dashboard-header {
        flex-direction: column;
        gap: 20px;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .content {
        padding: 20px;
    }
}

/* === Modal Styles === */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0,0,0,0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.modal {
  background: white;
  border-radius: 16px;
  padding: 32px;
  max-width: 500px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 2px solid #e5e7eb;
}

.modal-title {
  font-size: 24px;
  font-weight: 700;
  color: #1e293b;
}

.modal-close {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: #64748b;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  transition: all 0.2s;
}

.modal-close:hover {
  background: #f1f5f9;
  color: #1e293b;
}

.modal-body {
  padding: 0;
}

.modal-actions {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid #e5e7eb;
}
/* === Публичные страницы === */

/* Контейнер */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* === Публичная шапка === */
.public-header {
  background: white;
  border-bottom: 1px solid #e5e7eb;
  padding: 16px 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

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

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: #111827;
  font-weight: 700;
  font-size: 20px;
}

.logo-icon {
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 24px;
}

.logo-text {
  font-size: 22px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.public-nav {
  display: flex;
  gap: 28px;
  flex: 1;
}

.public-nav .nav-link {
  color: #4b5563;
  text-decoration: none;
  font-size: 15px;
  font-weight: 500;
  transition: color 0.2s;
}

.public-nav .nav-link:hover {
  color: #667eea;
}

.public-actions {
  display: flex;
  gap: 12px;
}

/* === Кнопки === */
.btn {
  padding: 10px 24px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  font-weight: 600;
  font-size: 14px;
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
}

.btn-primary {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 16px rgba(102,126,234,0.4);
}

.btn-secondary {
  background: #f3f4f6;
  color: #374151;
}

.btn-secondary:hover {
  background: #e5e7eb;
}

.btn-lg {
  padding: 14px 32px;
  font-size: 16px;
}

/* === Hero секция === */
.hero {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 100px 0;
  text-align: center;
}

.hero-content {
  max-width: 800px;
  margin: 0 auto;
}

.hero h1 {
  font-size: 48px;
  line-height: 1.2;
  margin-bottom: 24px;
  font-weight: 800;
}

.hero-subtitle {
  font-size: 20px;
  opacity: 0.95;
  margin-bottom: 40px;
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  margin-bottom: 60px;
}

.hero-stats {
  display: flex;
  justify-content: center;
  gap: 60px;
  padding-top: 40px;
  border-top: 1px solid rgba(255,255,255,0.2);
}

.hero-stats .stat {
  text-align: center;
}

.hero-stats .stat-value {
  font-size: 42px;
  font-weight: 700;
  margin-bottom: 8px;
}

.hero-stats .stat-label {
  font-size: 14px;
  opacity: 0.9;
}

/* === Features секция === */
.features {
  padding: 100px 0;
  background: #f9fafb;
}

.features h2 {
  font-size: 36px;
  margin-bottom: 16px;
  text-align: center;
  color: #111827;
}

.section-subtitle {
  color: #6b7280;
  font-size: 18px;
  margin-bottom: 60px;
  text-align: center;
}

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

.feature-card {
  background: white;
  padding: 32px;
  border-radius: 12px;
  border: 1px solid #e5e7eb;
  transition: all 0.3s;
  text-decoration: none;
  color: inherit;
  display: block;
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 24px rgba(0,0,0,0.1);
  border-color: #667eea;
}

.feature-icon {
  font-size: 48px;
  margin-bottom: 20px;
}

.feature-card h3 {
  font-size: 20px;
  margin-bottom: 12px;
  color: #111827;
}

.feature-card p {
  color: #6b7280;
  line-height: 1.6;
  margin-bottom: 16px;
}

.feature-link {
  color: #667eea;
  font-weight: 600;
  font-size: 14px;
}

/* === How it works === */
.how-it-works {
  padding: 100px 0;
  background: white;
}

.how-it-works h2 {
  font-size: 36px;
  margin-bottom: 60px;
  text-align: center;
}

.steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
}

.step {
  flex: 1;
  min-width: 250px;
  padding: 32px;
  background: #f9fafb;
  border-radius: 12px;
  text-align: center;
}

.step-number {
  width: 56px;
  height: 56px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 24px;
  margin: 0 auto 20px;
}

.step h3 {
  font-size: 20px;
  margin-bottom: 12px;
}

.step p {
  color: #6b7280;
  font-size: 15px;
  line-height: 1.6;
}

.step-arrow {
  font-size: 32px;
  color: #d1d5db;
}

/* === CTA секция === */
.cta-section {
  padding: 100px 0;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  text-align: center;
}

.cta-section h2 {
  font-size: 36px;
  margin-bottom: 16px;
}

.cta-section p {
  font-size: 18px;
  margin-bottom: 32px;
  opacity: 0.95;
}

/* === Footer === */
.public-footer {
  background: #1f2937;
  color: #d1d5db;
  padding: 60px 0 20px;
}

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

.footer-col h4 {
  color: white;
  font-size: 16px;
  margin-bottom: 16px;
}

.footer-col p, .footer-col li {
  font-size: 14px;
  line-height: 1.8;
  color: #9ca3af;
  list-style: none;
}

.footer-col a {
  color: #9ca3af;
  text-decoration: none;
  transition: color 0.2s;
}

.footer-col a:hover {
  color: white;
}

.footer-bottom {
  padding-top: 20px;
  border-top: 1px solid #374151;
  text-align: center;
  font-size: 13px;
  color: #6b7280;
}

/* === Адаптивность === */
@media (max-width: 768px) {
  .public-nav { 
    display: none; 
  }
  
  .hero h1 { 
    font-size: 32px; 
  }
  
  .hero-subtitle { 
    font-size: 16px; 
  }
  
  .hero-actions { 
    flex-direction: column; 
  }
  
  .hero-stats { 
    flex-direction: column; 
    gap: 20px; 
  }
  
  .steps { 
    flex-direction: column; 
  }
  
  .step-arrow { 
    transform: rotate(90deg); 
  }
  
  .features-grid {
    grid-template-columns: 1fr;
  }
}
