/* Общие стили */
* {
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body, html {
    margin: 0;
    padding: 0;
    height: 100%;
    background-image: url(data/background.jpg);
    color: #333;
}

.screen {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.hidden {
    display: none !important;
}

.dashboard-message.hidden {
    display: none !important;
}

.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s;
    text-decoration: none;
    display: inline-block;
    text-align: center;
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.btn:active {
    transform: translateY(0);
}

.btn.primary-btn {
    background-color: #2196f3;
    color: white;
}

.btn.primary-btn:hover {
    background-color: #1976d2;
}

.btn.save-btn {
    background-color: #4caf50;
    color: white;
}

.btn.save-btn:hover {
    background-color: #45a049;
}

.btn.logout-btn {
    background-color: #f44336;
    color: white;
}

.btn.logout-btn:hover {
    background-color: #d32f2f;
}

.btn.back-btn {
    background-color: #607d8b;
    color: white;
}

.btn.back-btn:hover {
    background-color: #455a64;
}

.btn.cancel-btn {
    background-color: #9e9e9e;
    color: white;
}

.btn.cancel-btn:hover {
    background-color: #616161;
}

.btn.edit-btn {
    background-color: #ffc107;
    color: #333;
    padding: 8px 15px;
}

.btn.edit-btn:hover {
    background-color: #e0a800;
}

.btn.delete-btn {
    background-color: #f44336;
    color: white;
    padding: 8px 15px;
}

.btn.delete-btn:hover {
    background-color: #d32f2f;
}

/* Сообщения */
.message {
    padding: 15px;
    border-radius: 5px;
    margin: 15px;
    text-align: center;
    font-weight: 500;
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1001;
    min-width: 300px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.message.success {
    background-color: #dff0d8;
    color: #3c763d;
    border: 1px solid #d6e9c6;
}

.message.error {
    background-color: #f2dede;
    color: #a94442;
    border: 1px solid #ebccd1;
}

/* Формы */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
    color: #555;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    transition: border-color 0.2s;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: #2196f3;
    box-shadow: 0 0 0 2px rgba(33, 150, 243, 0.1);
}

.form-row {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.form-row .form-group {
    flex: 1;
    min-width: 200px;
}

/* --- Страница входа --- */
.login-screen {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    justify-content: center;
    align-items: center;
}

.login-container {
    background: white;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    width: 100%;
    max-width: 400px;
    text-align: center;
}

.login-container h1 {
    margin: 0 0 10px 0;
    color: #333;
}

.login-container h2 {
    margin: 0 0 30px 0;
    color: #666;
    font-weight: normal;
}

.login-form {
    text-align: left;
}

/* --- Дашборд --- */
.dashboard-screen {
    background-image: url(data/background.jpg);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
}

.admin-header {
    background: white;
    padding: 20px 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.admin-header h1 {
    margin: 0;
    color: #333;
}

.admin-controls {
    display: flex;
    align-items: center;
    gap: 15px;
}

.user-info {
    color: #666;
    font-weight: 500;
}

.stats-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    padding: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.stat-card {
    background: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    text-align: center;
    transition: transform 0.2s;
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
}

.stat-card h3 {
    margin: 0 0 15px 0;
    color: #666;
    font-size: 18px;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: bold;
    color: #2196f3;
    margin: 10px 0;
}

.stat-desc {
    color: #999;
    font-size: 14px;
}

.management-sections {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 30px 30px;
}

.management-sections h2 {
    color: #333;
    margin-bottom: 20px;
}

.section-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.section-card {
    background: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
    overflow: hidden;
}

.section-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
}

.section-card h3 {
    margin: 0 0 10px 0;
    color: #333;
}

.section-card p {
    color: #666;
    margin: 0 0 20px 0;
    line-height: 1.5;
}

.card-icon {
    font-size: 2rem;
    position: absolute;
    bottom: 20px;
    right: 20px;
    opacity: 0.2;
}

.packages-section {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 30px 30px;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.section-header h2 {
    margin: 0;
    color: #333;
}

.packages-list {
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    overflow: hidden;
}

.package-item {
    padding: 20px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background-color 0.2s;
}

.package-item:hover {
    background-color: #f8f9fa;
}

.package-item:last-child {
    border-bottom: none;
}

.package-info h3 {
    margin: 0 0 8px 0;
    color: #333;
    display: flex;
    align-items: center;
    gap: 8px;
}

.package-info h3::before {
    content: "📦";
    font-size: 16px;
}

.package-info.classic h3::before {
    content: "📝";
}

.package-info.quiz h3::before {
    content: "❓";
}

.package-meta {
    color: #666;
    font-size: 14px;
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.package-meta span {
    display: flex;
    align-items: center;
    gap: 4px;
}

.package-meta span::before {
    font-size: 12px;
}

.package-meta .type::before {
    content: "🏷️";
}

.package-meta .count::before {
    content: "🔢";
}

.package-meta .date::before {
    content: "📅";
}

.package-actions {
    display: flex;
    gap: 10px;
}

.empty-state {
    text-align: center;
    padding: 40px;
    color: #666;
}

/* --- Редактор пакетов --- */
.editor-screen {
    background-color: #f8f9fa;
}

.editor-header {
    background: white;
    padding: 15px 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.editor-header h1 {
    margin: 0;
    color: #333;
}

.editor-controls {
    display: flex;
    gap: 10px;
}

.package-settings {
    background: white;
    padding: 25px 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    margin-bottom: 20px;
}

.questions-section {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 30px 30px;
}

.questions-section h2 {
    color: #333;
    margin-bottom: 20px;
}

.questions-list {
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    overflow: hidden;
}

/* --- Улучшенные стили для превью вопросов --- */
.question-preview {
    flex: 1;
    min-width: 0;
}

.question-preview h4 {
    margin: 0 0 8px 0;
    color: #2196f3;
    font-size: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.question-preview h4::before {
    content: "❓";
    font-size: 14px;
}

.question-item.classic .question-preview h4::before {
    content: "📝";
}

.question-item.quiz .question-preview h4::before {
    content: "❔";
}

.question-text {
    margin: 0 0 10px 0;
    color: #333;
    font-size: 15px;
    line-height: 1.4;
    max-height: 60px;
    overflow: hidden;
    position: relative;
}

.question-meta {
    color: #666;
    font-size: 13px;
    background-color: #f8f9fa;
    padding: 8px 12px;
    border-radius: 4px;
    border-left: 3px solid #2196f3;
}

.question-meta strong {
    color: #333;
}

.question-actions {
    display: flex;
    gap: 10px;
}

/* --- Модальные окна --- */
.modal {
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
}

.modal-content {
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    width: 90%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
}

.close-modal {
    position: absolute;
    right: 20px;
    top: 20px;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    color: #aaa;
}

.close-modal:hover {
    color: #333;
}

.question-modal h2 {
    margin-top: 0;
    color: #333;
}

.options-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.option-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

.option-input {
    flex: 1;
    margin: 0;
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.file-info {
    font-size: 12px;
    color: #666;
    margin-top: 5px;
}

/* --- Специфические стили для типов вопросов --- */
.classic-question .form-group,
.quiz-question .form-group {
    margin-bottom: 15px;
}

.option-item input[type="radio"] {
    margin: 0;
    width: 16px;
    height: 16px;
}

.option-item input[type="text"] {
    margin-left: 5px;
}

/* --- Адаптивность --- */
@media (max-width: 768px) {
    .admin-header,
    .editor-header {
        padding: 15px 20px;
    }
    
    .form-row {
        flex-direction: column;
        gap: 15px;
    }
    
    .section-header {
        flex-direction: column;
        gap: 15px;
        align-items: stretch;
    }
    
    .section-grid {
        grid-template-columns: 1fr;
    }
    
    .package-item,
    .question-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    .package-actions,
    .question-actions {
        align-self: stretch;
        justify-content: stretch;
    }
    
    .package-actions .btn,
    .question-actions .btn {
        flex: 1;
    }
    
    .modal-content {
        width: 95%;
        padding: 20px;
        margin: 10px;
    }
    
    .modal-actions {
        flex-direction: column;
    }
    
    .modal-actions .btn {
        width: 100%;
    }
    
    .message {
        left: 10px;
        right: 10px;
        min-width: auto;
    }
}

@media (max-width: 480px) {
    .login-container {
        padding: 20px;
        margin: 10px;
    }
    
    .admin-header,
    .editor-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .admin-controls {
        width: 100%;
        justify-content: center;
    }
    
    .editor-controls {
        width: 100%;
        flex-direction: column;
        gap: 10px;
    }
    
    .editor-controls .btn {
        width: 100%;
    }
    
    .option-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }
}

/* --- Стили для отображения информации о файлах --- */
.file-info {
    font-size: 12px;
    color: #666;
    margin-top: 5px;
    padding: 5px;
    background-color: #f0f0f0;
    border-radius: 3px;
    word-break: break-all;
}

.file-info.hidden {
    display: none;
}

.form-group input[type="file"] {
    padding: 5px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.modal-content {
    max-height: 90vh;
    overflow-y: auto;
}

/* --- Стили для дашборда --- */
.dashboard-body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-image: url(data/background.jpg);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    color: #fff;
    min-height: 100vh;
}

.dashboard-screen {
    width: 100%;
    min-height: 100vh;
    padding: 20px;
    position: relative;
}

.dashboard-header {
    position: relative;
    margin-bottom: 10px;
    text-align: center;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 15px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

.dashboard-header h1 {
    font-size: 2.8rem;
    margin-bottom: 1rem;
    color: #fff;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.back-link {
    position: absolute;
    top: 20px;
    left: 20px;
    background: rgba(255, 255, 255, 0.2);
    color: white;
    font-size: 1rem;
    padding: 12px 20px;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    text-decoration: none;
    z-index: 10;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
}

.back-link:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.user-info-panel {
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.user-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.user-avatar {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #4CAF50, #45a049);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 28px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.user-details {
    text-align: left;
}

.username {
    font-weight: 600;
    font-size: 1.3rem;
}

.user-role {
    font-size: 1rem;
    opacity: 0.9;
    background: rgba(255,255,255,0.2);
    padding: 6px 15px;
    border-radius: 20px;
    display: inline-block;
    margin-top: 4px;
}

.dashboard-nav {
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    padding: 15px 20px;
    border-radius: 15px;
    margin-bottom: 30px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.nav-content {
    max-width: 1200px;
    margin: 0 auto;
}

.nav-links {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.nav-links a {
    text-decoration: none;
    color: #fff;
    padding: 14px 25px;
    border-radius: 12px;
    transition: all 0.3s ease;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 10px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.1);
    font-weight: 500;
}

.nav-links a:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.nav-links a.active {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border-color: rgba(255, 255, 255, 0.4);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.3);
}

.dashboard-content {
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

.page-title {
    font-size: 2.2rem;
    margin-bottom: 25px;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 15px;
    justify-content: center;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.page-title-icon {
    font-size: 2.5rem;
    color: #ffd700;
}

.dashboard-stats-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

.dashboard-stat-card {
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    padding: 10px;
    border-radius: 20px;
    text-align: center;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.dashboard-stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
    background: rgba(255, 255, 255, 0.2);
}

.dashboard-stat-card.classic {
    border: 5px solid #4CAF50;
}

.dashboard-stat-card.quiz {
    border: 5px solid #FF9800;
}

.dashboard-stat-card.total {
    border: 5px solid #2196F3;
}

.dashboard-stat-card h3 {
    color: #fff;
    margin-bottom: 20px;
    font-size: 1.4rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.dashboard-stat-number {
    font-size: 3.5rem;
    font-weight: bold;
    color: #ffd700;
    margin: 20px 0;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.dashboard-stat-card.classic .dashboard-stat-number {
    color: #4CAF50;
}

.dashboard-stat-card.quiz .dashboard-stat-number {
    color: #FF9800;
}

.dashboard-stat-card.total .dashboard-stat-number {
    color: #2196F3;
}

.dashboard-stat-desc {
    color: #e0e0e0;
    font-size: 1.1rem;
}

.dashboard-packages-section {
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    overflow: hidden;
    margin-bottom: 30px;
    border: 1px solid rgba(255, 200, 49, 0.54);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.dashboard-section-header {
    padding: 25px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    background: rgba(255, 255, 255, 0.1);
}

.dashboard-section-header h2 {
    margin: 0;
    color: #fff;
    font-size: 1.6rem;
    display: flex;
    align-items: center;
    gap: 12px;
}

.dashboard-btn {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 12px;
    cursor: pointer;
    font-size: 1.1rem;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 12px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.dashboard-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
}

.dashboard-btn.primary {
    background: linear-gradient(135deg, #4CAF50, #45a049);
    box-shadow: 0 4px 15px rgba(76, 175, 80, 0.3);
}

.dashboard-btn.primary:hover {
    box-shadow: 0 8px 25px rgba(76, 175, 80, 0.4);
}

.dashboard-btn.secondary {
    background: linear-gradient(135deg, #FF9800, #F57C00);
    box-shadow: 0 4px 15px rgba(255, 152, 0, 0.3);
}

.dashboard-btn.secondary:hover {
    box-shadow: 0 8px 25px rgba(255, 152, 0, 0.4);
}

.dashboard-packages-list {
    padding: 25px;
}

.dashboard-package-item {
    padding: 15px;
    border: 2px solid #FF9800;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    transition: background-color 0.3s ease;
    border-radius: 12px;
    margin-bottom: 15px;
    background: rgba(44, 44, 44, 0.3);
}

.dashboard-package-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.dashboard-package-item:hover {
    background: rgba(18, 18, 18, 0.25);
}

.dashboard-package-info {
    flex: 1;
    min-width: 0;
}

.dashboard-package-info h3 {
    margin: 0 0 12px 0;
    color: #fff;
    font-size: 1.4rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.dashboard-package-meta {
    display: flex;
    gap: 25px;
    color: #e0e0e0;
    font-size: 1rem;
    flex-wrap: wrap;
}

.dashboard-package-actions {
    display: flex;
    gap: 12px;
    flex-shrink: 0;
}

.dashboard-btn.edit {
    background: linear-gradient(135deg, #ffc107, #e0a800);
    color: #333;
    padding: 12px 20px;
    font-size: 0.95rem;
    box-shadow: 0 4px 15px rgba(255, 193, 7, 0.3);
}

.dashboard-btn.edit:hover {
    box-shadow: 0 8px 25px rgba(255, 193, 7, 0.4);
}

.dashboard-btn.delete {
    background: linear-gradient(135deg, #f44336, #d32f2f);
    color: white;
    padding: 12px 20px;
    font-size: 0.95rem;
    box-shadow: 0 4px 15px rgba(244, 67, 54, 0.3);
}

.dashboard-btn.delete:hover {
    box-shadow: 0 8px 25px rgba(244, 67, 54, 0.4);
}

.dashboard-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.dashboard-empty-state {
    text-align: center;
    padding: 70px 20px;
    color: #e0e0e0;
}

.dashboard-empty-state-icon {
    font-size: 4rem;
    margin-bottom: 25px;
    opacity: 0.7;
}

.dashboard-message {
    padding: 18px 25px;
    border-radius: 12px;
    margin: 25px 0;
    text-align: center;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 12px;
    backdrop-filter: blur(10px);
}

.dashboard-message.success {
    background: linear-gradient(135deg, rgba(76, 175, 80, 0.9), rgba(69, 160, 73, 0.9));
    color: white;
    border: 1px solid rgba(76, 175, 80, 0.5);
}

.dashboard-message.error {
    background: linear-gradient(135deg, rgba(244, 67, 54, 0.9), rgba(211, 47, 47, 0.9));
    color: white;
    border: 1px solid rgba(244, 67, 54, 0.5);
}

.dashboard-no-permission {
    opacity: 0.7;
}

.dashboard-permission-info {
    font-size: 0.9rem;
    color: #ffb74d;
    margin-top: 8px;
    font-style: italic;
}

/* Модальное окно для дашборда */
.dashboard-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    display: none;
}

.dashboard-modal-content {
    background: linear-gradient(135deg, #2c3e50, #34495e);
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
    max-width: 500px;
    width: 90%;
    text-align: center;
    border: 2px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
}

.dashboard-modal-header {
    margin-bottom: 30px;
}

.dashboard-modal-header h3 {
    margin: 0;
    color: #fff;
    font-size: 2rem;
}

.dashboard-modal-buttons {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.dashboard-modal-button {
    padding: 20px;
    border: 2px solid;
    border-radius: 15px;
    cursor: pointer;
    font-size: 1.3rem;
    font-weight: 600;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    color: white;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.dashboard-modal-button.classic {
    border-color: #4CAF50;
    background: linear-gradient(135deg, #4CAF50, #45a049);
}

.dashboard-modal-button.quiz {
    border-color: #FF9800;
    background: linear-gradient(135deg, #FF9800, #F57C00);
}

.dashboard-modal-button.cancel {
    border-color: #6c757d;
    background: linear-gradient(135deg, #6c757d, #495057);
}

.dashboard-modal-button:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 10px 25px rgba(0,0,0,0.3);
}

/* Адаптивность для дашборда */
@media (max-width: 768px) {
    .dashboard-screen {
        padding: 15px 10px;
    }
    
    .dashboard-header {
        padding: 20px 15px;
    }
    
    .dashboard-header h1 {
        font-size: 2.2rem;
        padding-top: 50px;
    }
    
    .back-link {
        top: 15px;
        left: 15px;
        padding: 10px 15px;
        font-size: 0.9rem;
    }
    
    .user-info-panel {
        flex-direction: column;
        text-align: center;
        padding: 20px 15px;
    }
    
    .user-info {
        justify-content: center;
    }
    
    .user-details {
        text-align: center;
    }
    
    .nav-links {
        justify-content: center;
    }
    
    .nav-links a {
        padding: 12px 18px;
        font-size: 1rem;
    }
    
    .page-title {
        font-size: 1.8rem;
        text-align: center;
        justify-content: center;
    }
    
    .dashboard-section-header {
        flex-direction: column;
        text-align: center;
        padding: 20px;
    }
    
    .dashboard-section-header h2 {
        font-size: 1.4rem;
    }
    
    .dashboard-package-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
        padding: 20px;
    }
    
    .dashboard-package-actions {
        align-self: stretch;
        justify-content: stretch;
        width: 100%;
    }
    
    .dashboard-package-actions .dashboard-btn {
        flex: 1;
        justify-content: center;
    }
    
    .dashboard-stat-card {
        padding: 25px 20px;
    }
    
    .dashboard-stat-number {
        font-size: 2.8rem;
    }
    
    .dashboard-modal-content {
        padding: 30px 20px;
        margin: 20px;
    }
    
    .dashboard-modal-button {
        padding: 15px;
        font-size: 1.1rem;
    }
}

@media (max-width: 480px) {
    .dashboard-screen {
        padding: 10px 5px;
    }
    
    .dashboard-header {
        padding: 15px;
    }
    
    .dashboard-header h1 {
        font-size: 1.8rem;
        padding-top: 45px;
    }
    
    .dashboard-packages-list {
        padding: 15px;
    }
    
    .dashboard-package-item {
        padding: 15px;
    }
    
    .dashboard-btn {
        padding: 12px 18px;
        font-size: 0.9rem;
    }
    
    .dashboard-package-meta {
        flex-direction: column;
        gap: 8px;
    }
    
    .dashboard-package-info h3 {
        font-size: 1.2rem;
    }
    
    .dashboard-stat-number {
        font-size: 2.3rem;
    }
    
    .dashboard-modal-content {
        padding: 25px 15px;
    }
    
    .dashboard-modal-button {
        padding: 12px;
        font-size: 1rem;
    }
}

@media (min-width: 1200px) {
    .dashboard-content {
        padding: 0 20px;
    }
    
    .dashboard-packages-list {
        padding: 30px;
    }
}

/* Стили для bridge.html */
.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}

.info {
    background: white;
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.info h3 {
    margin-top: 0;
    color: #333;
}

.info button {
    margin: 5px;
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s;
}

.info button.success {
    background-color: #4caf50;
    color: white;
}

.info button.warning {
    background-color: #ff9800;
    color: white;
}

.status {
    padding: 15px;
    border-radius: 5px;
    margin: 10px 0;
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
}

.status.success {
    background-color: #d4edda;
    color: #155724;
    border-color: #c3e6cb;
}

.status.error {
    background-color: #f8d7da;
    color: #721c24;
    border-color: #f5c6cb;
}

.status.warning {
    background-color: #fff3cd;
    color: #856404;
    border-color: #ffeaa7;
}