/* ============================================
   SURVEY PLATFORM — Clean Professional Style
   ============================================ */

:root {
    /* Основная палитра — сине-зелёный градиент */
    --primary: #28B496;          /* Teal Green */
    --primary-dark: #1F9A80;     /* Darker Teal */
    --primary-light: #33C4A4;    /* Light Teal */
    
    --secondary: #28B496;        /* Brand Teal */
    --secondary-dark: #1F9A80;   /* Darker Brand Teal */
    
    /* Bootstrap override — убираем синюю обводку */
    --bs-btn-focus-shadow-rgb: 40, 180, 150;
    --bs-primary-rgb: 40, 180, 150;
    --bs-link-color-rgb: 40, 180, 150;
    
    --accent: #28B496;           /* Teal */
    --accent-dark: #1F9A80;      /* Darker Teal */
    
    --success: #28B496;          /* Success Teal */
    --warning: #f59e0b;          /* Amber */
    --error: #dc2626;            /* Red */
    
    /* Нейтральные */
    --gray-50: #f8f9fa;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-400: #94a3b8;
    --gray-500: #64748b;
    --gray-600: #475569;
    --gray-700: #334155;
    --gray-800: #1e293b;
    --gray-900: #0f172a;
    
    /* Фон */
    --background: #f8f9fa;
    --text: #1e293b;
    --border: #dfe6e9;
    
    /* Тени — мягкие */
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 8px 16px rgba(0, 0, 0, 0.1);
    
    /* Радиусы */
    --radius-sm: 8px;
    --radius: 12px;
    --radius-lg: 16px;
    
    /* Типографика */
    --font-sans: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
    
    /* Анимации */
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ============================================
   BASE & RESET
   ============================================ */

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-sans);
    background-color: var(--background);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ============================================
   LAYOUT & CONTAINERS
   ============================================ */

.container {
    max-width: 1400px;
    margin: 1.5rem auto;
    padding: 2.5rem;
    background: white;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    min-height: calc(100vh - 6rem);
}

.container-wide {
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem;
}

.survey-card {
    background: white;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    border: 2px solid var(--border);
    overflow: hidden;
    transition: var(--transition);
}

.survey-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.card-header {
    background: var(--primary);
    color: white;
    padding: 1.5rem 2rem;
    font-weight: 700;
    font-size: 1.25rem;
}

.card-body {
    padding: 2rem;
}

/* ============================================
   PROJECT SELECT PAGE
   ============================================ */

.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
    padding: 2rem 0;
}

.project-card-public {
    background: white;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    padding: 2rem;
    text-align: center;
    box-shadow: var(--shadow);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.project-card-public:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: var(--secondary);
}

.project-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    display: inline-block;
}

.project-stats {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--gray-100);
    padding: 0.5rem 1rem;
    border-radius: 9999px;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--gray-600);
    margin: 1rem 0;
}

/* ============================================
   ADMIN LOGIN PAGE
   ============================================ */

.admin-login-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
}

.admin-login-box {
    background: white;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    padding: 3rem;
    width: 100%;
    max-width: 450px;
    box-shadow: var(--shadow-lg);
    text-align: center;
    position: relative;
}

.admin-login-icon {
    width: 80px;
    height: 80px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 2rem;
    color: white;
    box-shadow: var(--shadow);
}

.admin-login-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.admin-login-subtitle {
    color: var(--gray-500);
    margin-bottom: 2rem;
    font-size: 0.95rem;
}

.admin-login-form {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.admin-login-form .form-group {
    text-align: left;
    margin-bottom: 0;
}

.admin-login-form .form-label {
    display: block;
    font-weight: 600;
    color: var(--gray-700);
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
}

.admin-login-form .form-input {
    width: 100%;
    padding: 1rem 1.25rem;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 1rem;
    font-family: inherit;
    background: var(--gray-50);
    transition: var(--transition);
}

.admin-login-form .form-input:focus {
    outline: none;
    border-color: var(--secondary);
    background: white;
    box-shadow: 0 0 0 3px rgba(40, 180, 150, 0.1);
}

.admin-login-form .form-input::placeholder {
    color: var(--gray-400);
}

.admin-login-btn {
    width: 100%;
    padding: 1rem;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: var(--radius-sm);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    margin-top: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.admin-login-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.admin-login-btn:active {
    transform: translateY(0);
}

.admin-login-footer {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
    color: var(--gray-500);
    font-size: 0.875rem;
}

.admin-login-footer a {
    color: var(--secondary);
    text-decoration: none;
    font-weight: 500;
}

.admin-login-footer a:hover {
    text-decoration: underline;
}

/* Admin Login Alerts */
.admin-login-box .alert {
    margin-bottom: 1.5rem;
    padding: 1rem;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
}

.admin-login-box .alert-error {
    background: #fef2f2;
    border: 1px solid var(--error);
    color: var(--error);
}

.admin-login-box .alert-success {
    background: #f0fdf4;
    border: 1px solid var(--success);
    color: var(--success);
}

/* Password visibility toggle */
.password-wrapper {
    position: relative;
}

.password-toggle {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--gray-400);
    cursor: pointer;
    padding: 0.25rem;
    font-size: 1.25rem;
    transition: var(--transition);
}

.password-toggle:hover {
    color: var(--gray-600);
}

/* Remember me checkbox */
.remember-me {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: var(--gray-600);
    cursor: pointer;
}

.remember-me input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--secondary);
    cursor: pointer;
}

/* ============================================
   STANDARD LOGIN PAGE (User Login)
   ============================================ */

.login-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    background: var(--background);
}

.login-box {
    background: white;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    padding: 3rem;
    width: 100%;
    max-width: 420px;
    box-shadow: var(--shadow);
    text-align: center;
}

.login-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.login-subtitle {
    color: var(--gray-500);
    margin-bottom: 2rem;
}

/* ============================================
   FORMS & INPUTS
   ============================================ */

.form-group {
    margin-bottom: 1.5rem;
    text-align: left;
}

.form-label {
    display: block;
    font-weight: 600;
    color: var(--gray-700);
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.form-input {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 1rem;
    font-family: inherit;
    background: white;
    transition: var(--transition);
}

.form-input:focus {
    outline: none;
    border-color: var(--secondary);
    box-shadow: 0 0 0 3px rgba(40, 180, 150, 0.1);
}

.form-input::placeholder {
    color: var(--gray-400);
}

/* ============================================
   BUTTONS
   ============================================ */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 6px rgba(40, 180, 150, 0.2);
}

.btn:focus {
    outline: 2px solid #28B496 !important;
    outline-offset: 2px !important;
    box-shadow: none !important;
}

.btn:focus-visible {
    outline: 2px solid #28B496 !important;
    outline-offset: 2px !important;
    box-shadow: none !important;
}

.btn-primary:focus,
.btn-primary:focus-visible,
.btn-primary:active:focus,
button.btn-primary:focus,
button.btn-primary:focus-visible {
    outline: 2px solid #28B496 !important;
    outline-offset: 2px !important;
    box-shadow: none !important;
    background: white !important;
    color: #28B496 !important;
    border-color: #28B496 !important;
}

*:focus {
    --bs-btn-focus-shadow-rgb: 40, 180, 150 !important;
}

.btn:active {
    transform: translateY(0);
}

.btn-primary {
    background: white;
    color: #28B496;
    border: 2px solid #28B496;
    --bs-btn-focus-shadow-rgb: 40, 180, 150;
    --bs-btn-bg: #28B496;
    --bs-btn-border-color: #28B496;
    --bs-btn-hover-bg: #28B496;
    --bs-btn-hover-border-color: #28B496;
    --bs-btn-active-bg: #1F9A80;
    --bs-btn-active-border-color: #1F9A80;
}

.btn-primary:hover {
    background: #28B496;
    color: white;
    border-color: #28B496;
}

.btn-success {
    background: var(--success);
    color: white;
}

.btn-danger {
    background: var(--error);
    color: white;
}

.btn-warning {
    background: var(--warning);
    color: var(--gray-900);
}

.btn-outline {
    background: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
}

.btn-outline:hover {
    background: var(--primary);
    color: white;
}

.btn-lg {
    padding: 1rem 2rem;
    font-size: 1.125rem;
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

/* ============================================
   QUESTION CARDS
   ============================================ */

.question-wrapper {
    background: white;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    padding: 3rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow);
    position: relative;
    animation: fadeIn 0.4s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.question-number {
    position: absolute;
    top: -12px;
    left: 20px;
    background: white;
    color: #28B496;
    border: 2px solid #28B496;
    font-weight: 700;
    padding: 0.4rem 1rem;
    border-radius: var(--radius-sm);
    font-size: 0.875rem;
}

.question-title {
    font-size: 1.2rem;
    font-weight: 400;
    color: var(--text);
    margin-bottom: 1.5rem;
    line-height: 1.4;
    margin-top: 0.5rem;
}

.required-badge {
    color: #dc2626;
    font-weight: 400;
}

/* ============================================
   CHOICE OPTIONS
   ============================================ */

.choice-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.choice-option {
    position: relative;
    display: flex;
    align-items: center;
    padding: 1rem 1.25rem;
    background: var(--gray-50);
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
}

.choice-option:hover {
    border-color: var(--secondary);
    background: white;
}

.choice-option input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.choice-indicator {
    width: 20px;
    height: 20px;
    border: 2px solid var(--gray-400);
    border-radius: 50%;
    margin-right: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    flex-shrink: 0;
}

.choice-option input[type="checkbox"] + .choice-indicator {
    border-radius: 4px;
}

.choice-option input:checked + .choice-indicator {
    background: var(--secondary);
    border-color: var(--secondary);
}

.choice-option input:checked + .choice-indicator::after {
    content: '✓';
    color: white;
    font-weight: 700;
    font-size: 12px;
}

.choice-option:has(input:checked) {
    border-color: var(--secondary);
    background: #f0f8ff;
}

.choice-text {
    font-weight: 500;
    color: var(--gray-700);
}

/* Style for hasNone option - same as regular choices */
.choice-option[data-none="true"] .choice-text,
.choice-option:has(input[data-none]) .choice-text,
.choice-list label[data-none="true"] .choice-text {
    font-weight: 500 !important;
    color: var(--gray-700) !important;
    font-style: normal !important;
}

/* Style for hasOther option - same as regular choices */
.choice-option.choice-other .choice-text,
.choice-option:has(input[data-other]) .choice-text {
    font-weight: 500 !important;
    color: var(--gray-700) !important;
    font-style: normal !important;
}

/* ============================================
   IMAGE GRID
   ============================================ */

.image-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    margin: 1.5rem 0;
}

.image-option {
    position: relative;
    background: white;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    overflow: hidden;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.image-option:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
    border-color: var(--secondary);
}

.image-option input {
    position: absolute;
    opacity: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
    z-index: 10;
}

.image-option img {
    width: 100%;
    height: 150px;
    object-fit: contain;
    display: block;
    border-bottom: 2px solid var(--border);
    background: var(--gray-50);
    padding: 10px;
    margin: 0 auto;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.image-option img.loaded {
    opacity: 1;
}

.image-option-label {
    padding: 1rem;
    text-align: center;
    font-weight: 600;
    color: var(--text);
    background: var(--gray-50);
}

.image-option:has(input:checked) {
    border-color: var(--secondary);
    background: #f0f8ff;
}

.image-option:has(input:checked) .image-option-label {
    background: var(--secondary);
    color: white;
}

/* Responsive Image Grid */
@media (max-width: 1200px) {
    .image-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .image-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }
    
    .image-option img {
        height: 120px;
        padding: 8px;
    }
}

@media (max-width: 480px) {
    .image-grid {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }
    
    .image-option img {
        height: 150px;
        padding: 6px;
    }
}

/* ============================================
   LIKERT SCALE
   ============================================ */

.likert-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 1rem;
    margin: 1.5rem 0;
}

.likert-option {
    position: relative;
    text-align: center;
    padding: 1.5rem 1rem;
    background: var(--gray-50);
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
}

.likert-option:hover {
    border-color: var(--secondary);
    background: white;
}

.likert-option input {
    position: absolute;
    opacity: 0;
}

.likert-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--gray-400);
    margin-bottom: 0.5rem;
    transition: var(--transition);
}

.likert-label {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--gray-600);
    line-height: 1.3;
}

.likert-option:has(input:checked) {
    border-color: var(--secondary);
    background: var(--secondary);
}

.likert-option:has(input:checked) .likert-value,
.likert-option:has(input:checked) .likert-label {
    color: white;
}

/* ============================================
   MATRIX QUESTIONS
   ============================================ */

.matrix-wrapper {
    overflow-x: auto;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    background: white;
    margin: 1rem 0;
}

.matrix-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 600px;
}

.matrix-table th {
    background: var(--primary);
    color: white;
    padding: 1rem;
    font-weight: 600;
    text-align: center;
    border-right: 1px solid rgba(255,255,255,0.2);
}

.matrix-table th:first-child {
    text-align: left;
}

.matrix-table th:last-child {
    border-right: none;
}

.matrix-table td {
    padding: 1rem;
    text-align: center;
    border-bottom: 1px solid var(--border);
    border-right: 1px solid var(--border);
}

.matrix-table td:first-child {
    text-align: left;
    font-weight: 600;
    color: var(--gray-700);
    background: var(--gray-50);
}

.matrix-table tr:last-child td {
    border-bottom: none;
}

.matrix-table input[type="radio"],
.matrix-table input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--secondary);
    cursor: pointer;
}

/* Matrix "Other" row styling */
.matrix-other-row {
    background: #f9f0fb !important;
}

.matrix-other-row td:first-child {
    background: #f3e5f5 !important;
    border-left: 3px solid #9b59b6;
    color: #6c3483;
}

.matrix-other-input {
    width: 100%;
    padding: 0.5rem;
    border: 2px solid #9b59b6;
    border-radius: 4px;
    font-size: 0.875rem;
    background: white;
}

.matrix-other-input:focus {
    outline: none;
    border-color: #8e44ad;
    box-shadow: 0 0 0 3px rgba(155, 89, 182, 0.2);
}

/* ============================================
   RANKING (DRAG & DROP)
   ============================================ */

.ranking-list {
    list-style: none;
    padding: 0;
    margin: 1.5rem 0;
}

.ranking-item {
    display: flex;
    align-items: center;
    padding: 1rem 1.25rem;
    margin-bottom: 0.75rem;
    background: white;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: grab;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.ranking-item:hover {
    border-color: var(--secondary);
    transform: translateX(4px);
}

.ranking-item.sortable-ghost {
    opacity: 0.5;
    background: var(--gray-100);
    border-style: dashed;
}

.ranking-item.sortable-drag {
    cursor: grabbing;
    box-shadow: var(--shadow-lg);
    z-index: 100;
}

.ranking-handle {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gray-100);
    border: 1px solid var(--border);
    border-radius: 4px;
    margin-right: 1rem;
    font-size: 1.25rem;
    color: var(--gray-500);
}

.ranking-number {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--secondary);
    color: white;
    font-weight: 700;
    border-radius: 50%;
    margin-right: 1rem;
    font-size: 0.875rem;
}

.ranking-text {
    flex: 1;
    font-weight: 500;
    color: var(--gray-700);
}

/* ============================================
   PROGRESS BAR
   ============================================ */

.progress-wrapper {
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 0.75rem 1rem;
    margin-bottom: 1.5rem;
    box-shadow: none;
}

.progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.progress-title {
    font-weight: 400;
    color: var(--gray-400);
    font-size: 0.75rem;
}

.progress-stats {
    font-size: 0.75rem;
    color: var(--gray-400);
    font-weight: 400;
}

.progress-bar-bg {
    height: 4px;
    background: var(--gray-100);
    border-radius: 9999px;
    overflow: hidden;
    position: relative;
}

.progress-bar-fill {
    height: 100%;
    background: var(--secondary);
    border-radius: 9999px;
    transition: width 0.5s ease;
}

/* ============================================
   VIDEO & PICTURE CONTAINERS
   ============================================ */

.media-container {
    background: var(--gray-900);
    border-radius: var(--radius);
    padding: 1rem;
    margin: 1.5rem 0;
    overflow: hidden;
    text-align: center;
}

.media-container-picture {
    background: white;
    border: 2px solid var(--border);
}

.media-container-picture .media-caption {
    color: var(--text-primary);
}

.media-container video {
    width: 100%;
    max-height: 70vh;
    object-fit: contain;
    border-radius: var(--radius-sm);
    display: block;
    background: #000;
}

.media-container img {
    max-width: 100%;
    max-height: 70vh;
    height: auto;
    object-fit: contain;
    border-radius: var(--radius-sm);
    display: block;
    margin: 0 auto;
}

/* Mobile fix */
@media (max-width: 768px) {
    .media-container {
        padding: 0.5rem;
    }
    .media-container video {
        width: 100%;
        max-height: 60vh;
    }
    .media-container img {
        max-height: 50vh;
    }
}

.media-caption {
    color: white;
    text-align: center;
    padding: 1rem;
    font-weight: 500;
}

/* ============================================
   MULTIPLE TEXT INPUTS
   ============================================ */

.text-inputs-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.text-input-item {
    display: flex;
    gap: 0.5rem;
}

.text-input-item input {
    flex: 1;
}

.btn-add-field {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: var(--gray-50);
    border: 2px dashed var(--gray-300);
    border-radius: var(--radius-sm);
    color: var(--gray-600);
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.btn-add-field:hover {
    border-color: var(--secondary);
    color: var(--secondary);
    background: #f0f8ff;
}

/* ============================================
   NAVIGATION BUTTONS
   ============================================ */

.nav-buttons {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 2px solid var(--border);
    justify-content: flex-start;
}

.nav-buttons .btn {
    flex: 0 0 auto;
    min-width: 200px;
    max-width: 300px;
}

.nav-buttons .btn-primary {
    min-width: 200px;
    max-width: 300px;
}

@media (max-width: 768px) {
    .nav-buttons {
        flex-direction: column;
    }
}

/* ============================================
   ALERTS & FLASH MESSAGES
   ============================================ */

.alert {
    padding: 1rem 1.25rem;
    border: 2px solid;
    border-radius: var(--radius-sm);
    margin-bottom: 1.5rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.alert-success {
    background: #f0fdf4;
    border-color: var(--success);
    color: #166534;
}

.alert-error {
    background: #fef2f2;
    border-color: var(--error);
    color: #991b1b;
}

.alert-warning {
    background: #fffbeb;
    border-color: var(--warning);
    color: #92400e;
}

.alert-info {
    background: #f0f9ff;
    border-color: var(--secondary);
    color: #0c4a6e;
}

/* HTML content */
.html-content {
    font-size: 1.125rem;
    line-height: 1.6;
}

.html-content .alert-info {
    background-color: transparent !important;
    border: none !important;
    box-shadow: none !important;
    color: var(--primary) !important;
    padding: 0 !important;
    margin: 1rem 0 !important;
}

/* ============================================
   ADMIN DASHBOARD — УЛУЧШЕННЫЙ СТИЛЬ
   ============================================ */

.admin-header {
    background: var(--primary);
    color: white;
    padding: 0;
    margin-bottom: 2rem;
    box-shadow: var(--shadow);
}

.admin-nav {
    max-width: 1400px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.admin-nav-brand {
    font-size: 1.5rem;
    font-weight: 700;
    color: white;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.admin-nav-brand::before {
    content: "📊";
    font-size: 1.75rem;
}

.admin-nav-links {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.admin-nav-links a {
    color: rgba(255,255,255,0.9);
    text-decoration: none;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.admin-nav-links a:hover {
    color: white;
    background: rgba(255,255,255,0.1);
}

.admin-nav-logout {
    background: rgba(255,255,255,0.15);
    border: 1px solid rgba(255,255,255,0.3);
}

.admin-nav-logout:hover {
    background: rgba(255,255,255,0.25);
}

/* Admin Container */
.admin-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem 2rem;
}

/* Admin Toolbar */
.admin-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 2px solid var(--border);
}

.admin-toolbar-title {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.admin-toolbar-title::before {
    content: "🗂️";
    font-size: 1.75rem;
}

.admin-toolbar-actions {
    display: flex;
    gap: 0.75rem;
}

/* Admin Grid — улучшенная сетка */
.admin-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(380px, 1fr));
    gap: 1.5rem;
}

/* Admin Card — улучшенные карточки */
.admin-card {
    background: white;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.admin-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--secondary);
}

.admin-card-header {
    padding: 1.5rem;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: white;
    position: relative;
}

.admin-card-header::after {
    content: "📋";
    position: absolute;
    top: 1rem;
    right: 1rem;
    font-size: 2rem;
    opacity: 0.3;
}

.admin-card-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    padding-right: 2.5rem;
}

.admin-card-id {
    font-size: 0.8rem;
    opacity: 0.8;
    font-family: var(--font-mono);
}

.admin-card-description {
    padding: 1rem 1.5rem;
    color: var(--gray-600);
    font-size: 0.95rem;
    min-height: 60px;
}

.admin-card-stats {
    display: flex;
    gap: 1rem;
    padding: 0 1.5rem 1rem;
}

.admin-stat {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 0.75rem;
    background: var(--gray-100);
    border-radius: 9999px;
    font-size: 0.875rem;
    font-weight: 600;
}

.admin-stat-responses {
    color: var(--success);
    background: #f0fdf4;
}

.admin-stat-responses::before {
    content: "✓";
    font-weight: 700;
}

.admin-stat-status {
    color: var(--gray-600);
}

.admin-stat-status.active {
    color: var(--success);
    background: #f0fdf4;
}

.admin-stat-status.active::before {
    content: "●";
    color: var(--success);
}

/* Admin Card Actions */
.admin-card-actions {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.5rem;
    padding: 1rem 1.5rem;
    background: var(--gray-50);
    border-top: 1px solid var(--border);
    margin-top: auto;
}

.admin-card-actions .btn {
    width: 100%;
    justify-content: flex-start;
    padding: 0.75rem 1rem;
    font-size: 0.95rem;
}

.admin-card-actions .btn::before {
    font-size: 1.1rem;
    width: 24px;
    text-align: center;
}

/* Иконки для кнопок */
.btn-questionnaire::before { content: "📝"; }
.btn-results::before { content: "📈"; }
.btn-media::before { content: "🖼️"; }
.btn-edit::before { content: "✏️"; }
.btn-delete::before { content: "🗑️"; }
.btn-duplicate::before { content: "📋"; }
.btn-view::before { content: "👁️"; }

/* Admin Card Footer */
.admin-card-footer {
    display: flex;
    gap: 0.5rem;
    padding: 1rem 1.5rem;
    background: var(--gray-50);
    border-top: 1px solid var(--border);
}

/* Admin Stats Overview */
.admin-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.admin-stat-card {
    background: white;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    padding: 1.5rem;
    text-align: center;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.admin-stat-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
    border-color: var(--secondary);
}

.admin-stat-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.admin-stat-value {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.admin-stat-label {
    color: var(--gray-600);
    font-size: 0.95rem;
    font-weight: 500;
}

/* Admin Table */
.admin-table-wrapper {
    background: white;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
}

.admin-table th,
.admin-table td {
    padding: 1rem 1.5rem;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.admin-table th {
    background: var(--gray-50);
    font-weight: 600;
    color: var(--primary);
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 0.05em;
}

.admin-table tr:hover {
    background: var(--gray-50);
}

.admin-table td {
    color: var(--gray-700);
}

/* Admin Badges */
.admin-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.35rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.8rem;
    font-weight: 600;
}

.admin-badge::before {
    font-size: 0.7rem;
}

.admin-badge-success {
    background: #f0fdf4;
    color: #166534;
}

.admin-badge-success::before {
    content: "✓";
}

.admin-badge-warning {
    background: #fef3c7;
    color: #92400e;
}

.admin-badge-warning::before {
    content: "⚠";
}

.admin-badge-error {
    background: #fef2f2;
    color: #991b1b;
}

.admin-badge-error::before {
    content: "✕";
}

.admin-badge-info {
    background: #f0f9ff;
    color: #0c4a6e;
}

.admin-badge-info::before {
    content: "ℹ";
}

/* Admin Empty State */
.admin-empty {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--gray-500);
    background: white;
    border: 2px dashed var(--border);
    border-radius: var(--radius);
    margin: 2rem 0;
}

.admin-empty-icon {
    font-size: 4rem;
    margin-bottom: 1.5rem;
    opacity: 0.5;
}

.admin-empty-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--gray-700);
    margin-bottom: 0.5rem;
}

.admin-empty-text {
    color: var(--gray-500);
    margin-bottom: 1.5rem;
}

/* Admin Modal */
.admin-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;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

.admin-modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.admin-modal {
    background: white;
    border-radius: var(--radius);
    padding: 2rem;
    width: 90%;
    max-width: 500px;
    box-shadow: var(--shadow-lg);
    transform: scale(0.9);
    transition: var(--transition);
}

.admin-modal-overlay.active .admin-modal {
    transform: scale(1);
}

.admin-modal-header {
    margin-bottom: 1.5rem;
}

.admin-modal-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary);
}

.admin-modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    margin-top: 2rem;
}

/* ============================================
   JSON EDITOR
   ============================================ */

.json-editor {
    font-family: var(--font-mono);
    font-size: 13px;
    line-height: 1.6;
    background: var(--gray-900);
    color: #a5b4fc;
    padding: 1.5rem;
    border: none;
    border-radius: var(--radius-sm);
    min-height: 600px;
    resize: vertical;
    width: 100%;
}

.json-editor:focus {
    outline: none;
    box-shadow: 0 0 0 4px rgba(52, 152, 219, 0.3);
}

/* ============================================
   RESULTS PAGE — CHARTS
   ============================================ */

.results-header {
    background: white;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow);
    text-align: center;
}

.results-header h1 {
    color: var(--primary);
    margin-bottom: 1rem;
    font-size: 2rem;
}

.results-header p {
    color: var(--gray-600);
    margin-bottom: 0;
}

.results-grid {
    display: grid;
    gap: 2rem;
}

.chart-card {
    background: white;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    padding: 2rem;
    box-shadow: var(--shadow);
    margin-bottom: 2rem;
    transition: var(--transition);
}

.chart-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.chart-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--border);
    flex-wrap: wrap;
    gap: 1rem;
}

.chart-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary);
    line-height: 1.4;
    flex: 1;
}

.chart-container {
    position: relative;
    height: 400px;
    margin: 30px 0;
    padding: 20px;
    background: #fff;
    border-radius: var(--radius-sm);
}

.chart-stats {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--gray-100);
    padding: 0.5rem 1rem;
    border-radius: 9999px;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--gray-600);
}

/* Matrix Results */
.matrix-chart-container {
    height: 500px;
    margin: 1.5rem 0;
}

.matrix-results {
    padding: 20px;
    border-radius: var(--radius);
    margin-bottom: 30px;
    box-shadow: var(--shadow);
    background: white;
    border: 2px solid var(--border);
    overflow-x: auto;
}

.matrix-results table {
    width: 100%;
    min-width: 600px;
    border-collapse: collapse;
}

.matrix-results th,
.matrix-results td {
    padding: 0.75rem;
    text-align: center;
    border: 1px solid var(--border);
}

.matrix-results th {
    background-color: var(--gray-50);
    font-weight: 600;
    color: var(--primary);
}

.matrix-results tr:hover {
    background-color: var(--gray-50);
}

.table-responsive {
    margin-bottom: 30px;
    overflow-x: auto;
}

/* Image Results Grid */
.results-image-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 1rem;
    margin: 1.5rem 0;
}

.results-image-item {
    text-align: center;
    padding: 0.25rem;
    background: var(--gray-50);
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.results-image-item:hover {
    border-color: var(--secondary);
    transform: translateY(-3px);
}

.results-image-item img {
    width: 100%;
    height: 140px;
    object-fit: contain;
    border-radius: 4px;
    margin-bottom: 0.25rem;
}

.results-image-placeholder {
    width: 100%;
    height: 140px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: var(--gray-100);
    border: 2px dashed var(--gray-300);
    border-radius: 4px;
    margin-bottom: 0.5rem;
    color: var(--gray-500);
    font-size: 0.75rem;
    text-align: center;
    padding: 0.5rem;
}

.results-image-placeholder i {
    font-size: 2rem;
    margin-bottom: 0.25rem;
}

.results-image-percent {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--secondary);
}

/* ============================================
   EXPORT BUTTONS
   ============================================ */

.export-toolbar {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 2rem;
    justify-content: center;
}

.export-toolbar .btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 768px) {
    .container {
        margin: 1rem;
        padding: 1.5rem;
    }
    
    .container-wide {
        padding: 1rem;
    }
    
    .admin-container {
        padding: 0 1rem 1rem;
    }
    
    .admin-nav {
        padding: 1rem;
        flex-direction: column;
        gap: 1rem;
    }
    
    .admin-toolbar {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .admin-grid {
        grid-template-columns: 1fr;
    }
    
    .admin-stats {
        grid-template-columns: 1fr;
    }
    
    .question-wrapper {
        padding: 1.5rem;
    }
    
    .likert-grid {
        grid-template-columns: 1fr;
    }
    
    .admin-grid {
        grid-template-columns: 1fr;
    }
    
    .login-box {
        padding: 2rem;
    }
    
    .admin-login-box {
        padding: 2rem;
    }
    
    .admin-login-icon {
        width: 60px;
        height: 60px;
        font-size: 1.5rem;
    }
    
    .admin-login-title {
        font-size: 1.5rem;
    }
    
    .chart-container {
        height: 300px;
        margin: 20px 0;
        padding: 15px;
    }
    
    .chart-container h5 {
        margin-bottom: 15px;
    }
    
    .image-results {
        margin-top: 20px;
    }
    
    .matrix-question,
    .matrix-results {
        overflow-x: auto;
        display: block;
    }
    
    .chart-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .results-header h1 {
        font-size: 1.5rem;
    }
}

@media (max-width: 480px) {
    h1 { font-size: 2rem; }
    h2 { font-size: 1.75rem; }
    
    .question {
        padding: 1.5rem;
    }
    
    .question-title {
        font-size: 1.1rem;
    }
    
    .chart-container {
        padding: 10px;
        margin: 40px 0;
        height: 250px;
    }
    
    .chart-container h5 {
        font-size: 1.1rem;
        margin-bottom: 12px;
    }
    
    .results-image-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .admin-login-wrapper {
        padding: 1rem;
    }
    
    .admin-login-box {
        padding: 1.5rem;
    }
    
    .admin-toolbar-title {
        font-size: 1.5rem;
    }
}

/* ============================================
   UTILITIES
   ============================================ */

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }

.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }

.hidden { display: none !important; }
.sr-only { position: absolute; left: -9999px; }

/* Loading animation */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255,255,255,.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Required field indicator */
.required { 
    color: var(--accent); 
}

.hidden-question { 
    display: none; 
}

/* Video and Picture containers */
.video-container, 
.picture-container, 
.ranking-container {
    margin: 20px 0;
}

video, 
.picture-frame img {
    width: 100%;
    max-width: 800px;
    height: auto;
    border-radius: var(--radius-sm);
}

/* Picture frame specific */
.picture-frame {
    text-align: center;
}

/* Progress info display */
.progress-info {
    display: flex;
    justify-content: space-between;
    margin-bottom: 5px;
    font-size: 0.9em;
    color: var(--gray-600);
}

/* Matrix chart positioning */
.matrix-chart {
    position: relative;
    height: 400px;
    margin-top: 30px;
    margin-bottom: 50px;
}

/* Index container specific */
.index-container {
    text-align: center;
    padding: 3rem 2rem;
}

/* Login container specific */
.login-container {
    max-width: 400px;
    margin: 4rem auto;
    padding: 2.5rem;
    background: white;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    text-align: center;
}

.login-container h1 {
    color: var(--primary);
    margin-bottom: 1.5rem;
    font-size: 1.8rem;
}

.login-container form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.login-container input {
    padding: 0.8rem;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 1rem;
    transition: var(--transition);
}

.login-container input:focus {
    border-color: var(--secondary);
    outline: none;
    box-shadow: 0 0 0 3px rgba(40, 180, 150, 0.1);
}

.login-container button {
    background: var(--secondary);
    color: white;
    padding: 0.8rem;
    border: none;
    border-radius: var(--radius-sm);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.login-container button:hover {
    background: var(--secondary-dark);
    transform: translateY(-2px);
}

/* Card image top */
.card-img-top {
    width: 100%;
    height: auto;
    object-fit: cover;
    border-bottom: 2px solid var(--border);
}

/* Choice hover effect */
.choice {
    padding: 1rem;
    margin: 0.75rem 0;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 1rem;
}

.choice:hover {
    border-color: var(--secondary);
    background: #f8fcff;
}

/* Image card specific */
.image-card {
    position: relative;
    border-radius: var(--radius);
    overflow: hidden;
    transition: var(--transition);
    aspect-ratio: 1;
    background: white;
    border: 2px solid var(--border);
}

.image-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
}

.image-card img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-bottom: 2px solid var(--border);
}

.image-card .card-body {
    padding: 1rem;
    text-align: center;
}

.image-card input[type="radio"],
.image-card input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
}

.image-card label {
    display: block;
    font-weight: 500;
    color: var(--text);
    margin-top: 0.5rem;
}

.image-card:has(input:checked) {
    border-color: var(--secondary);
    background: #f0f8ff;
}

/* Responsive image cards */
@media (max-width: 1200px) {
    .image-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .image-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }

    .image-card img {
        height: 120px;
    }
}

@media (max-width: 480px) {
    .image-grid {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }

    .image-card img {
        height: 100px;
    }
}

/* General card styles */
.card {
    border: none;
    border-radius: var(--radius-sm);
    overflow: hidden;
    transition: var(--transition);
    background: white;
    box-shadow: var(--shadow-sm);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
}

/* Likert scale alternative */
.likert-scale {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 1rem;
    margin: 2rem 0;
}

.likert-choice {
    padding: 1rem;
    text-align: center;
    background: var(--gray-50);
    border-radius: var(--radius-sm);
    transition: var(--transition);
    border: 2px solid var(--border);
}

.likert-choice:hover {
    background: var(--secondary);
    color: white;
    border-color: var(--secondary);
}

/* Navigation buttons alternative */
.navigation-buttons {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 2px solid var(--border);
}

@media (max-width: 768px) {
    .navigation-buttons {
        flex-direction: column;
    }
    
    .navigation-buttons .btn {
        width: 100%;
    }
}

/* Form control styles */
.form-control {
    padding: 0.75rem 1rem;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    transition: var(--transition);
    width: 100%;
}

.form-control:focus {
    border-color: var(--secondary);
    box-shadow: 0 0 0 3px rgba(40, 180, 150, 0.1);
    outline: none;
}

textarea.form-control {
    min-height: 120px;
    resize: vertical;
}

/* Typography adjustments */
h1, h2, h3, h5 {
    color: var(--primary);
    margin-bottom: 1.5rem;
    font-weight: 700;
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h5 { font-size: 1.25rem; }

p {
    color: var(--gray-600);
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

/* Question specific */
.question {
    padding: 2rem;
    margin-bottom: 2rem;
    background: white;
    border-radius: var(--radius);
    border: 2px solid var(--border);
    transition: var(--transition);
    animation: fadeIn 0.4s ease-out;
}

.question:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow);
}

/* Input radio and checkbox accent */
input[type="radio"],
input[type="checkbox"] {
    width: 20px;
    height: 20px;
    accent-color: var(--secondary);
    cursor: pointer;
}

/* Matrix question responsive */
.matrix-question {
    overflow-x: auto;
    margin: 1rem 0;
}

.matrix-question table {
    width: 100%;
    min-width: 600px;
    border-collapse: collapse;
}

.matrix-question th,
.matrix-question td {
    padding: 0.75rem;
    text-align: center;
    border: 1px solid var(--border);
}

.matrix-question th {
    background-color: var(--gray-50);
    font-weight: 600;
}

.matrix-question tr:hover {
    background-color: var(--gray-50);
}

.matrix-question input[type="radio"],
.matrix-question input[type="checkbox"] {
    transform: scale(1.2);
    accent-color: var(--secondary);
}

/* Ranking container specific */
.ranking-container {
    margin: 20px 0;
}

/* Utility shadow */
.shadow-sm { 
    box-shadow: var(--shadow-sm); 
}

/* Time display */
.time-display {
    text-align: center;
    margin-bottom: 10px;
    font-size: 14px;
    color: var(--gray-600);
}

/* Progress container alternative */
.progress-container {
    width: 100%;
    height: 10px;
    background: var(--gray-100);
    border-radius: 10px;
    margin-bottom: 20px;
    position: relative;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: var(--secondary);
    width: 0;
    transition: width 0.3s ease;
    position: absolute;
    left: 0;
    top: 0;
    border-radius: 10px;
}

/* Image choice specific */
.image-choice {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
    padding: 0.5rem;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.image-choice:hover {
    border-color: var(--secondary);
    background: #f8fcff;
}

.image-choice img {
    width: 100px;
    height: 100px;
    object-fit: cover;
    margin-right: 10px;
    border-radius: var(--radius-sm);
}

/* Chart canvas specific */
canvas {
    max-width: 100%;
    height: auto;
}
.admin-container {
    max-width: 1400px !important;
    margin: 0 auto !important;
    padding: 0 2rem 2rem !important;
    width: 100% !important;
}

.admin-nav {
    max-width: 1400px !important;
    margin: 0 auto !important;
    padding: 1rem 2rem !important;
}

.admin-grid {
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(380px, 1fr)) !important;
    gap: 1.5rem !important;
}