/**
 * ============================================================
 * STYLES.CSS - ФУЛФИЛМЕНТ МИДА
 * ============================================================
 * Полные стили для системы управления фулфилментом
 * Версия: 2.0 (Финальная)
 * ============================================================
 */

/* ============================================================
   ГЛОБАЛЬНЫЕ СТИЛИ И ПЕРЕМЕННЫЕ
   ============================================================ */

:root {
    /* Цвета */
    --primary: #667eea;
    --primary-dark: #5568d3;
    --primary-light: #7c94f5;
    --secondary: #10b981;
    --secondary-dark: #059669;
    --danger: #ef4444;
    --danger-dark: #dc2626;
    --warning: #f59e0b;
    --warning-dark: #d97706;
    --info: #3b82f6;
    --success: #10b981;
    
    /* Нейтральные цвета */
    --dark: #1f2937;
    --gray: #6b7280;
    --gray-light: #9ca3af;
    --gray-lighter: #d1d5db;
    --light: #f9fafb;
    --white: #ffffff;
    
    /* Границы и тени */
    --border: #e5e7eb;
    --border-light: #f3f4f6;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 8px 16px -4px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 20px 40px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    
    /* Радиусы */
    --radius-sm: 4px;
    --radius: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    
    /* Отступы */
    --spacing-xs: 4px;
    --spacing-sm: 8px;
    --spacing: 12px;
    --spacing-md: 16px;
    --spacing-lg: 24px;
    --spacing-xl: 32px;
    
    /* Шрифты */
    --font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --font-mono: 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, 'Courier New', monospace;
    
    /* Переходы */
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-fast: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ============================================================
   БАЗОВЫЕ СТИЛИ
   ============================================================ */

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-sans);
    font-size: 15px;
    line-height: 1.6;
    color: var(--dark);
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    background-attachment: fixed;
    min-height: 100vh;
}

body.logged-in {
    background: var(--light);
}

/* ============================================================
   ТИПОГРАФИЯ
   ============================================================ */

h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: 1rem;
    color: var(--dark);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.75rem; }
h4 { font-size: 1.5rem; }
h5 { font-size: 1.25rem; }
h6 { font-size: 1rem; }

p {
    margin-bottom: 1rem;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: var(--transition-fast);
}

a:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

strong {
    font-weight: 600;
}

code {
    font-family: var(--font-mono);
    background: var(--light);
    padding: 2px 6px;
    border-radius: var(--radius-sm);
    font-size: 0.9em;
}

pre {
    background: var(--dark);
    color: var(--white);
    padding: 1rem;
    border-radius: var(--radius);
    overflow-x: auto;
    margin-bottom: 1rem;
}

hr {
    border: none;
    border-top: 1px solid var(--border);
    margin: 2rem 0;
}

/* ============================================================
   КОНТЕЙНЕРЫ
   ============================================================ */

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

.container-fluid {
    width: 100%;
    padding: 0 20px;
}

/* ============================================================
   HEADER
   ============================================================ */

header {
    background: linear-gradient(135deg, var(--primary) 0%, #764ba2 100%);
    color: var(--white);
    padding: 1rem 0;
    box-shadow: var(--shadow-md);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo h1 {
    font-size: 1.75rem;
    margin: 0;
    color: var(--white);
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo i {
    font-size: 1.5rem;
}

nav {
    display: flex;
    align-items: center;
    gap: 1rem;
}

nav a {
    color: var(--white);
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: var(--radius);
    transition: var(--transition-fast);
}

nav a:hover {
    background: rgba(255, 255, 255, 0.1);
    text-decoration: none;
}

/* User Menu */
.user-menu {
    display: flex;
    align-items: center;
    gap: 15px;
    position: relative;
}

.user-name {
    color: var(--white);
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
}



/* Header Messages Button */
.header-messages-btn {
    position: relative;
}

.messages-icon-btn {
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: var(--white);
    padding: 10px 15px;
    border-radius: var(--radius);
    cursor: pointer;
    font-size: 1.2rem;
    transition: var(--transition-fast);
    position: relative;
}

.messages-icon-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.header-messages-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: var(--danger);
    color: var(--white);
    font-size: 10px;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 10px;
    min-width: 18px;
    text-align: center;
}


/* Messages Dropdown */
.messages-dropdown {
    position: fixed;
    background: var(--white);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-xl);
    width: 360px;
    max-height: 500px;
    z-index: 2000;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.messages-dropdown-header {
    padding: 15px 20px;
    background: linear-gradient(135deg, var(--primary) 0%, #764ba2 100%);
    color: var(--white);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.messages-dropdown-header h3 {
    margin: 0;
    font-size: 1.1rem;
}

.messages-dropdown-close {
    cursor: pointer;
    font-size: 1.5rem;
    font-weight: 300;
    transition: var(--transition-fast);
}

.messages-dropdown-close:hover {
    transform: rotate(90deg);
}

.messages-dropdown-body {
    flex: 1;
    overflow-y: auto;
    padding: 10px;
}

.messages-dropdown-footer {
    padding: 10px;
    border-top: 1px solid var(--border);
    text-align: center;
}

.messages-dialogs-list {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.message-dialog-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border-radius: var(--radius);
    cursor: pointer;
    transition: var(--transition-fast);
    position: relative;
}

.message-dialog-item:hover {
    background: var(--light);
}

.message-dialog-item.has-unread {
    background: rgba(102, 126, 234, 0.05);
}

.dialog-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary) 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    flex-shrink: 0;
}

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

.dialog-name {
    font-weight: 600;
    font-size: 0.95rem;
    margin-bottom: 2px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dialog-last-message {
    font-size: 0.85rem;
    color: var(--gray);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dialog-unread-badge {
    background: var(--danger);
    color: var(--white);
    font-size: 11px;
    font-weight: 600;
    padding: 2px 7px;
    border-radius: 10px;
    min-width: 20px;
    text-align: center;
}

.messages-loading {
    text-align: center;
    padding: 30px;
    color: var(--gray);
}

.messages-empty {
    text-align: center;
    padding: 30px;
    color: var(--gray);
}

/* ============================================================
   MAIN CONTENT
   ============================================================ */

main {
    min-height: calc(100vh - 200px);
    padding: 2rem 0;
}

/* ============================================================
   HERO SECTION (ПУБЛИЧНАЯ СТРАНИЦА)
   ============================================================ */

.hero {
    text-align: center;
    padding: 4rem 2rem;
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    margin-bottom: 3rem;
}

.hero h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: var(--dark);
}

.hero p {
    font-size: 1.25rem;
    color: var(--gray);
    max-width: 800px;
    margin: 0 auto 2rem;
}

/* ============================================================
   FEATURES (ПУБЛИЧНАЯ СТРАНИЦА)
   ============================================================ */

.features {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    padding: 3rem 2rem;
    margin-bottom: 3rem;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.feature-card {
    text-align: center;
    padding: 2rem;
    border: 2px solid var(--border-light);
    border-radius: var(--radius-md);
    transition: var(--transition);
}

.feature-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
    transform: translateY(-5px);
}

.feature-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
}

.feature-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.feature-card p {
    color: var(--gray);
    margin: 0;
}

/* ============================================================
   FAQ SECTION
   ============================================================ */

.faq-section {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    padding: 3rem 2rem;
    margin-bottom: 3rem;
}

.faq-list {
    max-width: 900px;
    margin: 0 auto;
}

.faq-item {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    margin-bottom: 1rem;
    overflow: hidden;
    transition: var(--transition);
}

.faq-item.active {
    border-color: var(--primary);
    box-shadow: var(--shadow-sm);
}

.faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem 1.5rem;
    cursor: pointer;
    background: var(--light);
    transition: var(--transition-fast);
}

.faq-question:hover {
    background: #f3f4f6;
}

.faq-item.active .faq-question {
    background: rgba(102, 126, 234, 0.05);
}

.faq-question h4 {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--dark);
}

.faq-toggle {
    font-size: 1.5rem;
    font-weight: 300;
    color: var(--primary);
    transition: var(--transition);
}

.faq-item.active .faq-toggle {
    transform: rotate(45deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}

.faq-item.active .faq-answer {
    max-height: 500px;
    transition: max-height 0.5s ease-in;
}

.faq-answer p {
    padding: 1.25rem 1.5rem;
    margin: 0;
    color: var(--gray);
    line-height: 1.7;
}

/* ============================================================
   CONTACT SECTION
   ============================================================ */

.contact-section {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    padding: 3rem 2rem;
    margin-bottom: 3rem;
}

/* ============================================================
   DASHBOARD
   ============================================================ */

.dashboard {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    padding: 2rem;
}

.dashboard h2 {
    margin-bottom: 2rem;
    color: var(--dark);
}

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

.stat-card {
    background: linear-gradient(135deg, var(--primary) 0%, #764ba2 100%);
    color: var(--white);
    padding: 1.5rem;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow);
    transition: var(--transition);
    cursor: pointer;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.stat-icon {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    opacity: 0.9;
}

.stat-info h3 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
    color: var(--white);
}

.stat-info p {
    margin: 0;
    font-size: 0.95rem;
    opacity: 0.9;
}

.stat-label {
    font-size: 0.9rem;
    opacity: 0.8;
    margin-bottom: 0.5rem;
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
}

/* ============================================================
   TABS
   ============================================================ */

.tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 2rem;
    border-bottom: 2px solid var(--border);
    overflow-x: auto;
}

.tab-btn {
    padding: 12px 24px;
    background: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    cursor: pointer;
    font-size: 15px;
    font-weight: 500;
    color: var(--gray);
    transition: var(--transition-fast);
    white-space: nowrap;
}

.tab-btn:hover {
    background: var(--light);
    color: var(--dark);
}

.tab-btn.active {
    border-bottom-color: var(--primary);
    color: var(--primary);
    font-weight: 600;
}

.tab-btn i {
    margin-right: 8px;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
    animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.tab-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.tab-header h3 {
    margin: 0;
    font-size: 1.5rem;
}

.tab-header div {
    display: flex;
    gap: 10px;
}

/* ============================================================
   BUTTONS
   ============================================================ */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    font-size: 15px;
    font-weight: 600;
    border: none;
    border-radius: var(--radius);
    cursor: pointer;
    transition: var(--transition-fast);
    text-decoration: none;
    font-family: inherit;
}

.btn:hover {
    text-decoration: none;
    transform: translateY(-2px);
}

.btn:active {
    transform: translateY(0);
}

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

.btn-primary:hover {
    box-shadow: 0 6px 12px rgba(102, 126, 234, 0.3);
}

.btn-secondary {
    background: var(--gray-lighter);
    color: var(--dark);
}

.btn-secondary:hover {
    background: var(--gray-light);
}

.btn-success {
    background: linear-gradient(135deg, var(--secondary) 0%, var(--secondary-dark) 100%);
    color: var(--white);
}

.btn-success:hover {
    box-shadow: 0 6px 12px rgba(16, 185, 129, 0.3);
}

.btn-danger {
    background: var(--danger);
    color: var(--white);
}

.btn-danger:hover {
    background: var(--danger-dark);
    box-shadow: 0 6px 12px rgba(239, 68, 68, 0.3);
}

.btn-warning {
    background: var(--warning);
    color: var(--white);
}

.btn-warning:hover {
    background: var(--warning-dark);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--primary);
    color: var(--primary);
}

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

.btn-link {
    background: transparent;
    color: var(--primary);
    padding: 8px 16px;
}

.btn-link:hover {
    background: rgba(102, 126, 234, 0.05);
    text-decoration: underline;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 13px;
}

.btn-large {
    padding: 16px 32px;
    font-size: 1.1rem;
}

.btn:disabled,
.btn.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
}

.w-100 {
    width: 100%;
}

/* ============================================================
   FORMS
   ============================================================ */

.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--dark);
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 15px;
    font-family: inherit;
    transition: var(--transition-fast);
}

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

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--gray-light);
}

.form-group small {
    display: block;
    margin-top: 0.5rem;
    color: var(--gray);
    font-size: 0.85rem;
}

.form-links {
    display: flex;
    justify-content: space-between;
    margin-top: 1rem;
    font-size: 0.9rem;
}

.checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    user-select: none;
}

.checkbox-label input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: var(--primary);
}

.checkbox-label span {
    font-weight: 400;
}

/* Form Grid */
.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.form-grid-2col {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.form-grid-3col {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

/* Form Section */
.form-section {
    background: var(--light);
    padding: 1.5rem;
    border-radius: var(--radius);
    margin-bottom: 1.5rem;
    border: 1px solid var(--border-light);
}

.form-section h4 {
    margin: 0 0 1rem 0;
    color: var(--primary);
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* ============================================================
   CARDS
   ============================================================ */

.card {
    background: var(--white);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow);
    padding: 1.5rem;
    transition: var(--transition);
}

.card:hover {
    box-shadow: var(--shadow-md);
}

/* Applications List */
.applications-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 1.5rem;
}

.application-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    cursor: pointer;
    transition: var(--transition);
}

.application-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
    transform: translateY(-3px);
}

.app-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-light);
}

.app-header h4 {
    margin: 0;
    font-size: 1.1rem;
}

.app-body p {
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
}

.app-footer {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-light);
}

/* Products Grid */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
}

.product-card {
    background: var(--white);
    border: 2px solid var(--border);
    border-radius: var(--radius-md);
    padding: 1rem;
    cursor: pointer;
    transition: var(--transition);
}

.product-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
    transform: translateY(-5px);
}

.product-card-image {
    width: 100%;
    height: 200px;
    object-fit: contain;
    background: var(--light);
    border-radius: var(--radius);
    margin-bottom: 1rem;
    padding: 10px;
}

.product-no-image {
    width: 100%;
    height: 200px;
    background: var(--light);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: var(--gray-lighter);
    margin-bottom: 1rem;
}

.product-card-body {
    padding: 0.5rem 0;
}

.product-card-article {
    font-size: 0.85rem;
    color: var(--gray);
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.product-card-title {
    font-size: 1rem;
    margin-bottom: 0.5rem;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    min-height: 48px;
}

.product-meta {
    font-size: 0.85rem;
    color: var(--gray);
    margin-bottom: 0.25rem;
    display: flex;
    align-items: center;
    gap: 6px;
}

.product-meta i {
    width: 16px;
    color: var(--primary);
}

.product-card-actions {
    margin-top: 1rem;
    display: flex;
    gap: 8px;
}

/* Tech Cards List */
.techcards-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.techcard-item {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    transition: var(--transition);
}

.techcard-item:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
}

.techcard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-light);
}

.techcard-header h4 {
    margin: 0;
    font-size: 1.2rem;
}

.tc-article {
    display: inline-block;
    margin-left: 10px;
    padding: 4px 10px;
    background: var(--light);
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    color: var(--gray);
}

.techcard-body p {
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
}

.techcard-sizes {
    background: var(--light);
    padding: 10px;
    border-radius: var(--radius);
    margin-top: 1rem;
    font-size: 0.9rem;
}

.techcard-date {
    color: var(--gray);
    font-size: 0.85rem;
    margin-top: 1rem;
}

.techcard-footer {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-light);
    display: flex;
    gap: 8px;
}

/* Tech Card Tabs */
.tech-cards-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 1.5rem;
}

.tech-card-tab {
    padding: 10px 20px;
    background: var(--light);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    cursor: pointer;
    transition: var(--transition-fast);
    font-weight: 500;
}

.tech-card-tab:hover {
    background: #f3f4f6;
}

.tech-card-tab.active {
    background: var(--primary);
    color: var(--white);
    border-color: var(--primary);
}

/* Invoices List */
.invoices-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 1.5rem;
}

.invoice-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    transition: var(--transition);
}

.invoice-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
}

.invoice-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-light);
}

.invoice-header h4 {
    margin: 0;
    font-size: 1.1rem;
}

.invoice-date {
    color: var(--gray);
    font-size: 0.9rem;
}

.invoice-body {
    margin-bottom: 1rem;
}

.invoice-amount {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    background: rgba(102, 126, 234, 0.05);
    border-radius: var(--radius);
    margin-bottom: 1rem;
}

.amount-label {
    font-weight: 600;
    color: var(--dark);
}

.amount-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
}

.invoice-description {
    color: var(--gray);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.invoice-due-date {
    color: var(--gray);
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 6px;
}

.invoice-footer {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

/* ============================================================
   STATUS BADGES
   ============================================================ */

.status-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
}

.status-new {
    background: rgba(59, 130, 246, 0.1);
    color: var(--info);
}

.status-pending {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning);
}

.status-progress,
.status-inprogress {
    background: rgba(102, 126, 234, 0.1);
    color: var(--primary);
}

.status-completed {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
}

.status-cancelled,
.status-rejected {
    background: rgba(239, 68, 68, 0.1);
    color: var(--danger);
}

.status-draft {
    background: rgba(107, 114, 128, 0.1);
    color: var(--gray);
}

.status-default {
    background: var(--light);
    color: var(--gray);
}

.badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 600;
    background: var(--primary);
    color: var(--white);
}

.badge-secondary {
    background: var(--gray-light);
    color: var(--white);
}

/* ============================================================
   MODALS
   ============================================================ */

.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 20px;
    backdrop-filter: blur(2px);
}

.modal-content {
    background: var(--white);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-xl);
    position: relative;
    animation: modalSlideIn 0.3s ease-out;
}

.modal-large {
    max-width: 1200px;
}

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

.modal-content h2 {
    padding: 1.5rem 2rem;
    background: linear-gradient(135deg, var(--primary) 0%, #764ba2 100%);
    color: var(--white);
    margin: 0;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.modal-content > form,
.modal-content > div:not(:first-child) {
    padding: 2rem;
}

.close {
    position: absolute;
    top: 1.5rem;
    right: 2rem;
    color: var(--white);
    font-size: 2rem;
    font-weight: 300;
    cursor: pointer;
    transition: var(--transition-fast);
    z-index: 10;
}

.close:hover {
    transform: rotate(90deg);
}

/* ============================================================
   APPLICATION TYPES
   ============================================================ */

.application-types {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.app-type-btn {
    padding: 2rem 1rem;
    background: var(--light);
    border: 2px solid var(--border);
    border-radius: var(--radius-md);
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
}

.app-type-btn:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow);
    transform: translateY(-3px);
}

.app-type-btn i {
    font-size: 3rem;
    display: block;
    margin-bottom: 0.5rem;
}

.app-type-btn span {
    font-weight: 600;
    color: var(--dark);
}

/* ============================================================
   MARKETPLACE
   ============================================================ */

.marketplace-buttons {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.marketplace-btn {
    padding: 3rem 2rem;
    background: var(--light);
    border: 2px solid var(--border);
    border-radius: var(--radius-lg);
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
}

.marketplace-btn:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
    transform: translateY(-5px);
}

.marketplace-btn h3 {
    margin: 1rem 0 0.5rem;
    font-size: 1.5rem;
}

.marketplace-btn p {
    margin: 0;
    color: var(--gray);
}

.marketplace-products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1.5rem;
    max-height: 60vh;
    overflow-y: auto;
    padding: 1rem;
    background: var(--light);
    border-radius: var(--radius);
}

.marketplace-product-card {
    position: relative;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1rem;
    transition: var(--transition);
}

.marketplace-product-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow);
}

.mp-product-checkbox {
    position: absolute;
    top: 10px;
    left: 10px;
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: var(--primary);
}

.marketplace-product-card img {
    width: 100%;
    height: 150px;
    object-fit: contain;
    border-radius: var(--radius-sm);
    margin-bottom: 0.75rem;
}

.marketplace-product-card h5 {
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.marketplace-product-card p {
    font-size: 0.8rem;
    color: var(--gray);
    margin-bottom: 0.25rem;
}

.vendor-code,
.brand,
.category {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* ============================================================
   CHAT
   ============================================================ */

.chat-container {
    display: grid;
    grid-template-columns: 300px 1fr;
    height: 600px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}

.chat-users {
    background: var(--light);
    border-right: 1px solid var(--border);
    overflow-y: auto;
}

.chat-users-list {
    display: flex;
    flex-direction: column;
}

.chat-user-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 15px;
    cursor: pointer;
    transition: var(--transition-fast);
    border-bottom: 1px solid var(--border-light);
}

.chat-user-item:hover {
    background: var(--white);
}

.chat-user-item.has-unread {
    background: rgba(102, 126, 234, 0.05);
}

.chat-user-avatar {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary) 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.chat-user-info {
    flex: 1;
}

.chat-user-name {
    font-weight: 600;
    font-size: 0.95rem;
    margin-bottom: 2px;
}

.chat-user-role {
    font-size: 0.8rem;
    color: var(--gray);
}

.chat-user-badge {
    background: var(--danger);
    color: var(--white);
    font-size: 11px;
    font-weight: 600;
    padding: 2px 7px;
    border-radius: 10px;
    min-width: 20px;
    text-align: center;
}

.chat-messages {
    display: flex;
    flex-direction: column;
}

.chat-messages-container {
    flex: 1;
    overflow-y: auto;
    background: var(--white);
}

.messages-list {
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.message-item {
    display: flex;
}

.message-mine {
    justify-content: flex-end;
}

.message-other {
    justify-content: flex-start;
}

.message-bubble {
    max-width: 70%;
    padding: 12px 16px;
    border-radius: var(--radius-md);
    word-wrap: break-word;
}

.message-mine .message-bubble {
    background: linear-gradient(135deg, var(--primary) 0%, #764ba2 100%);
    color: var(--white);
    border-bottom-right-radius: 4px;
}

.message-other .message-bubble {
    background: var(--light);
    color: var(--dark);
    border-bottom-left-radius: 4px;
}

.message-text {
    margin-bottom: 5px;
}

.message-time {
    font-size: 0.75rem;
    opacity: 0.7;
}

.chat-input {
    display: flex;
    gap: 10px;
    padding: 15px;
    border-top: 1px solid var(--border);
    background: var(--light);
}

.chat-input input {
    flex: 1;
    padding: 12px 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 15px;
}

.chat-input input:focus {
    outline: none;
    border-color: var(--primary);
}

.empty-messages {
    text-align: center;
    padding: 3rem;
    color: var(--gray);
}

/* ============================================================
   SIZES MANAGEMENT (TECH CARDS)
   ============================================================ */

.sizes-container {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.size-row {
    display: grid;
    grid-template-columns: 150px 200px 120px 40px;
    gap: 12px;
    align-items: center;
    padding: 12px;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.size-row input {
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 14px;
}

.remove-size-btn {
    background: var(--danger);
    color: var(--white);
    border: none;
    width: 36px;
    height: 36px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-fast);
}

.remove-size-btn:hover {
    background: var(--danger-dark);
}

.add-size-btn {
    background: var(--success);
    color: var(--white);
    border: none;
    padding: 12px 24px;
    border-radius: var(--radius);
    cursor: pointer;
    font-weight: 600;
    margin-top: 10px;
    transition: var(--transition-fast);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.add-size-btn:hover {
    background: var(--secondary-dark);
}

/* ============================================================
   PRODUCT SELECTION (TECH CARDS)
   ============================================================ */

.products-selection-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 15px;
    max-height: 400px;
    overflow-y: auto;
    padding: 15px;
    background: var(--light);
    border-radius: var(--radius);
}

.product-select-card {
    border: 2px solid var(--border);
    border-radius: var(--radius);
    padding: 12px;
    cursor: pointer;
    transition: var(--transition);
    background: var(--white);
    text-align: center;
}

.product-select-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow);
}

.product-select-card.selected {
    border-color: var(--primary);
    background: rgba(102, 126, 234, 0.05);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.product-select-card img {
    width: 100%;
    height: 120px;
    object-fit: contain;
    border-radius: var(--radius-sm);
    margin-bottom: 8px;
}

.product-select-card h5 {
    font-size: 0.85rem;
    margin: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.product-select-card p {
    font-size: 0.75rem;
    color: var(--gray);
    margin: 4px 0 0 0;
}

/* ============================================================
   AUTOCOMPLETE
   ============================================================ */

.autocomplete-suggestions {
    position: absolute;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    width: 100%;
    margin-top: 2px;
}

.autocomplete-suggestion {
    padding: 12px 16px;
    cursor: pointer;
    border-bottom: 1px solid var(--border-light);
    transition: var(--transition-fast);
}

.autocomplete-suggestion:hover {
    background: var(--light);
}

.autocomplete-suggestion:last-child {
    border-bottom: none;
}

/* ============================================================
   DICTIONARIES
   ============================================================ */

.dict-section {
    background: var(--white);
    padding: 2rem;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow);
    margin-bottom: 2rem;
}

.dict-section h3 {
    margin: 0 0 1rem 0;
    color: var(--primary);
    font-size: 1.5rem;
}

.dict-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1.5rem;
}

.dict-table th {
    background: linear-gradient(135deg, var(--primary) 0%, #764ba2 100%);
    color: var(--white);
    padding: 12px 16px;
    text-align: left;
    font-weight: 600;
}

.dict-table th:first-child {
    border-radius: var(--radius) 0 0 0;
}

.dict-table th:last-child {
    border-radius: 0 var(--radius) 0 0;
}

.dict-table td {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border);
}

.dict-table tr:hover td {
    background: rgba(102, 126, 234, 0.03);
}

.dict-table tr:last-child td {
    border-bottom: none;
}

/* ============================================================
   DETAIL VIEWS
   ============================================================ */

.detail-section {
    background: var(--light);
    padding: 1.5rem;
    border-radius: var(--radius);
    margin-bottom: 1.5rem;
}

.detail-section h4 {
    margin: 0 0 1rem 0;
    color: var(--primary);
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.detail-table {
    width: 100%;
    border-collapse: collapse;
}

.detail-table td {
    padding: 10px 0;
    border-bottom: 1px solid var(--border-light);
}

.detail-table td:first-child {
    width: 200px;
    font-weight: 600;
}

.detail-table tr:last-child td {
    border-bottom: none;
}

.product-detail-grid {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 2rem;
}

.product-detail-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
}

.product-detail-table td {
    padding: 12px 0;
    border-bottom: 1px solid var(--border-light);
    vertical-align: top;
}

.product-detail-table td:first-child {
    width: 180px;
    font-weight: 600;
    color: var(--gray);
}

.product-detail-table tr:last-child td {
    border-bottom: none;
}

.processing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 10px;
}

.processing-item {
    background: var(--white);
    padding: 10px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    font-size: 0.9rem;
}

/* ============================================================
   NOTIFICATIONS
   ============================================================ */

.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 16px 24px;
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    font-size: 15px;
    font-weight: 500;
    z-index: 2000;
    transform: translateX(400px);
    transition: transform 0.3s ease-out;
    max-width: 400px;
}

.notification.show {
    transform: translateX(0);
}

.notification-success {
    background: var(--success);
    color: var(--white);
}

.notification-error {
    background: var(--danger);
    color: var(--white);
}

.notification-warning {
    background: var(--warning);
    color: var(--white);
}

.notification-info {
    background: var(--info);
    color: var(--white);
}

/* ============================================================
   EMPTY STATES
   ============================================================ */

.empty-state {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--gray);
}

.empty-state i {
    font-size: 4rem;
    color: var(--gray-lighter);
    margin-bottom: 1rem;
    display: block;
}

.empty-state h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--dark);
}

.empty-state p {
    margin-bottom: 1.5rem;
}

/* ============================================================
   LOADING STATES
   ============================================================ */

.loading {
    text-align: center;
    padding: 3rem 2rem;
    color: var(--gray);
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(102, 126, 234, 0.1);
    border-top: 4px solid var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ============================================================
   INFO PANELS
   ============================================================ */

.info-notice {
    background: rgba(59, 130, 246, 0.05);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: var(--radius);
    padding: 1rem 1.25rem;
    margin-bottom: 1.5rem;
}

.info-notice p {
    margin: 0;
    color: var(--info);
    display: flex;
    align-items: center;
    gap: 8px;
}

.info-text {
    background: rgba(102, 126, 234, 0.05);
    border-left: 4px solid var(--primary);
    padding: 1rem 1.25rem;
    margin-bottom: 1.5rem;
    border-radius: 0 var(--radius) var(--radius) 0;
}

.info-text p {
    margin: 0;
    color: var(--gray);
}

/* ============================================================
   FOOTER
   ============================================================ */

footer {
    background: var(--dark);
    color: var(--white);
    padding: 2rem 0;
    text-align: center;
    margin-top: 3rem;
}

footer p {
    margin: 0.5rem 0;
    opacity: 0.8;
}

/* ============================================================
   UTILITIES
   ============================================================ */

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

.text-right {
    text-align: right;
}

.text-left {
    text-align: left;
}

.flex {
    display: flex;
}

.flex-center {
    display: flex;
    align-items: center;
    justify-content: center;
}

.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }
.gap-3 { gap: 1.5rem; }
.gap-4 { gap: 2rem; }

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

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

.p-1 { padding: 0.5rem; }
.p-2 { padding: 1rem; }
.p-3 { padding: 1.5rem; }
.p-4 { padding: 2rem; }

.hidden {
    display: none !important;
}

/* ============================================================
   SCROLLBAR STYLING
   ============================================================ */

::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--light);
    border-radius: var(--radius-sm);
}

::-webkit-scrollbar-thumb {
    background: var(--gray-light);
    border-radius: var(--radius-sm);
}

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

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

@media (max-width: 1200px) {
    .product-detail-grid {
        grid-template-columns: 1fr;
    }
    
    .chat-container {
        grid-template-columns: 250px 1fr;
    }
}

@media (max-width: 992px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .form-grid-2col,
    .form-grid-3col {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    body {
        font-size: 14px;
    }
    
    .container {
        padding: 0 15px;
    }
    
    header {
        padding: 0.75rem 0;
    }
    
    .logo h1 {
        font-size: 1.25rem;
    }
    
    .hero h2 {
        font-size: 1.75rem;
    }
    
    .hero p {
        font-size: 1rem;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .products-grid,
    .applications-list,
    .invoices-list {
        grid-template-columns: 1fr;
    }
    
    .tabs {
        flex-wrap: nowrap;
        overflow-x: auto;
    }
    
    .tab-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .tab-header div {
        width: 100%;
    }
    
    .chat-container {
        grid-template-columns: 1fr;
        height: auto;
    }
    
    .chat-users {
        max-height: 300px;
    }
    
    .size-row {
        grid-template-columns: 1fr;
    }
    
    .products-selection-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .modal-content {
        max-width: 100%;
        max-height: 100vh;
        border-radius: 0;
    }
    
    .messages-dropdown {
        width: calc(100vw - 20px);
        max-width: 360px;
        right: 10px !important;
        left: auto !important;
    }
}

@media (max-width: 480px) {
    h1 { font-size: 1.75rem; }
    h2 { font-size: 1.5rem; }
    h3 { font-size: 1.25rem; }
    
    .btn {
        padding: 10px 16px;
        font-size: 14px;
    }
    
    .application-types {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .marketplace-buttons {
        grid-template-columns: 1fr;
    }
    
    .products-selection-grid {
        grid-template-columns: 1fr;
    }
    
    .user-menu {
        flex-direction: row;
    }
    
    .user-name {
        display: none;
    }
}

/* ============================================================
   PRINT STYLES
   ============================================================ */

@media print {
    header,
    footer,
    .tabs,
    .btn,
    .modal {
        display: none !important;
    }
    
    body {
        background: white;
    }
    
    .dashboard {
        box-shadow: none;
    }
}
/* Счета */
.invoice-filters {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

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

.invoices-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 20px;
}

.invoice-card {
    background: white;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: transform 0.3s;
}

.invoice-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
}

.invoice-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #f0f0f0;
}

.invoice-header h4 {
    margin: 0;
    color: #333;
}

.invoice-body {
    margin-bottom: 15px;
}

.invoice-amount,
.invoice-paid,
.invoice-due {
    padding: 8px 0;
    font-size: 15px;
}

.invoice-amount {
    font-size: 18px;
    color: #667eea;
}

.overdue-date {
    color: #dc3545;
    font-weight: bold;
}

.invoice-description {
    margin-top: 10px;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 5px;
    font-size: 14px;
    color: #666;
}

.invoice-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* ============================================================
   ФИКСИРОВАННОЕ DROPDOWN МЕНЮ
   ============================================================ */

.user-menu {
    display: flex;
    align-items: center;
    gap: 15px;
    position: relative;
}

.user-name {
    font-weight: 500;
    color: white;
    display: flex;
    align-items: center;
    gap: 8px;
}

.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-btn {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    padding: 10px 15px;
    font-size: 18px;
    cursor: pointer;
    border-radius: 5px;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 45px;
    height: 45px;
}

.dropdown-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.05);
}

.dropdown-content {
    display: none;
    position: absolute;
    right: 0;
    top: calc(100% + 5px);
    background: white;
    min-width: 250px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.2);
    border-radius: 10px;
    z-index: 10000;
    overflow: hidden;
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    /* ФИКСАЦИЯ ПОЗИЦИИ */
    pointer-events: none;
}

.dropdown-content.show {
    display: block;
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.dropdown-content a {
    color: #333;
    padding: 15px 20px;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.3s;
    font-size: 15px;
    border-bottom: 1px solid #f0f0f0;
}

.dropdown-content a:last-child {
    border-bottom: none;
}

.dropdown-content a:hover {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding-left: 25px;
}

.dropdown-content a i {
    width: 20px;
    text-align: center;
    font-size: 16px;
}

.badge {
    background: #dc3545;
    color: white;
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: bold;
    margin-left: auto;
}

/* Стрелка для dropdown */
.dropdown-content::before {
    content: '';
    position: absolute;
    top: -8px;
    right: 15px;
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-bottom: 8px solid white;
}

/* ============================================================
   ЧАТ
   ============================================================ */

.chat-container {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 20px;
    height: 600px;
}

.chat-sidebar {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 15px;
    overflow-y: auto;
}

.chat-contacts {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.chat-contact {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: white;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
}

.chat-contact:hover {
    background: #667eea;
    color: white;
    transform: translateX(5px);
}

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

.contact-avatar {
    font-size: 32px;
    color: inherit;
}

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

.contact-name {
    font-weight: 600;
    margin-bottom: 3px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.contact-last-message {
    font-size: 12px;
    opacity: 0.8;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.unread-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    background: #dc3545;
    color: white;
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: bold;
}

.chat-main {
    display: flex;
    flex-direction: column;
    background: white;
    border-radius: 10px;
    overflow: hidden;
}

.chat-messages {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.chat-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #999;
}

.chat-message {
    max-width: 70%;
    padding: 12px 16px;
    border-radius: 12px;
    word-wrap: break-word;
}

.message-sent {
    align-self: flex-end;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-bottom-right-radius: 4px;
}

.message-received {
    align-self: flex-start;
    background: #f1f3f5;
    color: #333;
    border-bottom-left-radius: 4px;
}

.message-content {
    margin-bottom: 5px;
    line-height: 1.5;
}

.message-time {
    font-size: 11px;
    opacity: 0.7;
    text-align: right;
}

.chat-input {
    padding: 15px;
    border-top: 1px solid #e0e0e0;
    background: #f8f9fa;
}

.chat-input input[type="text"] {
    flex: 1;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 25px;
    font-size: 14px;
    outline: none;
    transition: all 0.3s;
}

.chat-input input[type="text"]:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

/* Профиль */
.profile-form {
    padding: 20px 0;
}

.profile-header {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 30px;
    padding: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 10px;
    color: white;
}

.profile-avatar {
    font-size: 64px;
}

.profile-info h3 {
    margin: 0 0 10px 0;
}

.user-role-badge {
    display: inline-block;
    padding: 5px 15px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    font-size: 14px;
}

.readonly-field {
    background: #f8f9fa !important;
    cursor: not-allowed;
}

.form-actions {
    display: flex;
    gap: 15px;
    margin-top: 30px;
}

.btn-large {
    padding: 15px 30px;
    font-size: 16px;
}

/* Техкарты с разными статусами */
.techcard-active {
    border-left: 4px solid #28a745;
}

.techcard-draft {
    border-left: 4px solid #ffc107;
}

.techcard-product-name {
    font-weight: 600;
    color: #667eea;
    margin: 5px 0;
}

.techcard-meta {
    display: flex;
    gap: 15px;
    margin-top: 10px;
    font-size: 13px;
    color: #666;
}

.techcard-tabs {
    display: flex;
    gap: 10px;
    border-bottom: 2px solid #e0e0e0;
    margin-bottom: 20px;
}

.techcard-tab-btn {
    padding: 12px 24px;
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    cursor: pointer;
    font-size: 15px;
    color: #666;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 8px;
}

.techcard-tab-btn:hover {
    color: #667eea;
    background: rgba(102, 126, 234, 0.05);
}

.techcard-tab-btn.active {
    color: #667eea;
    border-bottom-color: #667eea;
    font-weight: 600;
}

/* Справочники */
.dictionary-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    border-bottom: 2px solid #e0e0e0;
}

.dict-tab-btn {
    padding: 12px 24px;
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    cursor: pointer;
    font-size: 15px;
    color: #666;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 8px;
}

.dict-tab-btn:hover {
    color: #667eea;
    background: rgba(102, 126, 234, 0.05);
}

.dict-tab-btn.active {
    color: #667eea;
    border-bottom-color: #667eea;
    font-weight: 600;
}

.dict-tab-content {
    display: none;
}

.dict-tab-content.active {
    display: block;
}

.dictionary-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    gap: 15px;
}

.search-input {
    flex: 1;
    max-width: 400px;
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 25px;
    font-size: 14px;
    outline: none;
    transition: all 0.3s;
}

.search-input:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 15px;
}

.category-card {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    transition: all 0.3s;
}

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

.category-icon {
    font-size: 32px;
    color: #667eea;
}

.category-info {
    flex: 1;
}

.category-info h4 {
    margin: 0;
    color: #333;
}

.category-actions {
    display: flex;
    gap: 5px;
}

/* Responsive */
@media (max-width: 768px) {
    .chat-container {
        grid-template-columns: 1fr;
        height: auto;
    }
    
    .chat-sidebar {
        height: 200px;
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    .dictionary-actions {
        flex-direction: column;
        align-items: stretch;
    }
    
    .search-input {
        max-width: 100%;
    }
}

/* ============================================================
   СОВРЕМЕННЫЕ СПРАВОЧНИКИ
   ============================================================ */

.dictionary-tabs-modern {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 30px;
}

.dict-tab-btn-modern {
    background: white;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    position: relative;
    overflow: hidden;
}

.dict-tab-btn-modern::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    transform: scaleX(0);
    transition: transform 0.3s;
}

.dict-tab-btn-modern:hover {
    border-color: #667eea;
    transform: translateY(-3px);
    box-shadow: 0 5px 20px rgba(102, 126, 234, 0.2);
}

.dict-tab-btn-modern.active {
    border-color: #667eea;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.05) 0%, rgba(118, 75, 162, 0.05) 100%);
}

.dict-tab-btn-modern.active::before {
    transform: scaleX(1);
}

.dict-tab-btn-modern i {
    font-size: 32px;
    color: #667eea;
}

.dict-tab-btn-modern span {
    font-weight: 600;
    font-size: 16px;
    color: #333;
}

.dict-tab-btn-modern small {
    font-size: 12px;
    color: #999;
    background: #f0f0f0;
    padding: 3px 10px;
    border-radius: 12px;
}

.dict-tab-btn-modern.active small {
    background: #667eea;
    color: white;
}

.dictionary-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    gap: 20px;
    flex-wrap: wrap;
}

.btn-add-dict {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    font-size: 15px;
    white-space: nowrap;
}

.search-box {
    position: relative;
    flex: 1;
    max-width: 400px;
}

.search-box i {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #999;
}

.search-box input {
    width: 100%;
    padding: 12px 15px 12px 45px;
    border: 2px solid #e0e0e0;
    border-radius: 25px;
    font-size: 14px;
    outline: none;
    transition: all 0.3s;
}

.search-box input:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
}

/* Smart Form */
.smart-form {
    padding: 10px 0;
}

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

.form-group label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
}

.form-group label i {
    color: #667eea;
}

.required {
    color: #dc3545;
    font-size: 18px;
}

.field-hint {
    display: block;
    margin-top: 5px;
    color: #999;
    font-size: 12px;
}

.btn-block {
    width: 100%;
    padding: 14px;
    font-size: 16px;
}

/* Таблица справочника товаров */
.products-dict-table {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.products-dict-table table {
    width: 100%;
    border-collapse: collapse;
}

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

.products-dict-table th {
    padding: 15px;
    text-align: left;
    font-weight: 600;
}

.products-dict-table td {
    padding: 15px;
    border-bottom: 1px solid #f0f0f0;
}

.products-dict-table tbody tr {
    transition: all 0.3s;
}

.products-dict-table tbody tr:hover {
    background: #f8f9ff;
}

.product-article {
    font-weight: 700;
    color: #667eea;
    font-family: 'Courier New', monospace;
}

.product-name {
    font-weight: 600;
    color: #333;
}

.product-meta {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    font-size: 13px;
    color: #666;
}

.product-meta span {
    display: flex;
    align-items: center;
    gap: 5px;
}

.action-buttons {
    display: flex;
    gap: 8px;
}

/* Cards для категорий и стран */
.dict-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.dict-card {
    background: white;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    padding: 20px;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 15px;
}

.dict-card:hover {
    border-color: #667eea;
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.15);
    transform: translateY(-3px);
}

.dict-card-icon {
    font-size: 40px;
    color: #667eea;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(102, 126, 234, 0.1);
    border-radius: 10px;
}

.dict-card-content {
    flex: 1;
}

.dict-card-title {
    font-weight: 600;
    font-size: 16px;
    color: #333;
    margin-bottom: 5px;
}

.dict-card-meta {
    font-size: 13px;
    color: #999;
}

.dict-card-actions {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

/* ============================================================
   ТЕХНИЧЕСКИЕ КАРТЫ - РЕДАКТИРОВАНИЕ
   ============================================================ */

.modal-xlarge {
    max-width: 1000px;
    max-height: 90vh;
    overflow-y: auto;
}

.form-section {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 25px;
}

.form-section h3 {
    margin: 0 0 20px 0;
    color: #667eea;
    font-size: 18px;
    display: flex;
    align-items: center;
    gap: 10px;
    padding-bottom: 15px;
    border-bottom: 2px solid #e0e0e0;
}

.sizes-table {
    width: 100%;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    margin-top: 10px;
}

.sizes-table table {
    width: 100%;
    border-collapse: collapse;
}

.sizes-table th {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 12px;
    text-align: left;
    font-weight: 600;
}

.sizes-table td {
    padding: 10px;
    border-bottom: 1px solid #f0f0f0;
}

.sizes-table input {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 5px;
}

.size-row {
    background: white;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 10px;
    border: 1px solid #e0e0e0;
    display: grid;
    grid-template-columns: 1fr 2fr 1fr auto;
    gap: 15px;
    align-items: end;
}

.size-row:hover {
    border-color: #667eea;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.1);
}

.techcard-view-container {
    padding: 20px 0;
}

.techcard-view-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 10px;
    margin-bottom: 30px;
}

.techcard-view-section {
    background: white;
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    border: 1px solid #e0e0e0;
}

.techcard-view-section h3 {
    color: #667eea;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f0f0f0;
}

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

.techcard-info-item {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.techcard-info-label {
    font-size: 12px;
    color: #999;
    text-transform: uppercase;
    font-weight: 600;
}

.techcard-info-value {
    font-size: 16px;
    color: #333;
    font-weight: 500;
}

/* Карточки товаров для выбора */
.product-card-select {
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.product-card-select:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    transform: translateY(-2px);
}

.product-card-select .product-checkbox:checked ~ label {
    color: #28a745;
}

.product-card-select:has(.product-checkbox:checked) {
    border-color: #28a745;
    background-color: #f8fff9;
}

/* Стили для модальных окон */
#marketplaceProductsContent {
    min-height: 200px;
}

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

* Стили для переключателя платформ */
.platform-switch-btn {
    position: relative;
    overflow: hidden;
}

.platform-switch-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, transparent 0%, rgba(0,0,0,0.03) 100%);
    opacity: 0;
    transition: opacity 0.3s;
}

.platform-switch-btn:hover::before {
    opacity: 1;
}

.platform-switch-btn.active {
    transform: scale(1.05);
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
}

.platform-switch-btn.active[data-platform="wildberries"] {
    background: linear-gradient(135deg, #CB11AB 0%, #a00d8a 100%) !important;
    color: white !important;
}

.platform-switch-btn.active[data-platform="wildberries"] > div > div {
    color: white !important;
}

.platform-switch-btn.active[data-platform="ozon"] {
    background: linear-gradient(135deg, #005BFF 0%, #0041b8 100%) !important;
    color: white !important;
}

.platform-switch-btn.active[data-platform="ozon"] > div > div {
    color: white !important;
}

/* Анимация для spinner */
.spinner-border {
    display: inline-block;
    width: 3rem;
    height: 3rem;
    vertical-align: text-bottom;
    border: 0.25em solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    animation: spinner-border 0.75s linear infinite;
}

@keyframes spinner-border {
    to { transform: rotate(360deg); }
}

/* Оптимизация прокрутки */
#marketplaceProductsGrid > div {
    scroll-behavior: smooth;
}

/* Ховер эффекты для карточек */
.marketplace-product-card:hover {
    transform: translateY(-3px) !important;
    box-shadow: 0 6px 16px rgba(0,0,0,0.12) !important;
}

.modal {
    display: none; /* По умолчанию скрыто */
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.4);
    align-items: center;
    justify-content: center;
}

.modal-content {
    background-color: #fefefe;
    margin: auto;
    padding: 0;
    border: 1px solid #888;
    width: 90%;
    max-width: 1400px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
    animation: slideIn 0.3s ease;
}

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

.close {
    color: #aaa;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close:hover,
.close:focus {
    color: #000;
}

/* Стили для товаров из маркетплейсов */
.marketplace-product-card {
    position: relative;
    background: white;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    padding: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.marketplace-product-card:hover {
    border-color: #2196F3;
    box-shadow: 0 4px 12px rgba(33, 150, 243, 0.2);
    transform: translateY(-2px);
}

.marketplace-product-card.selected {
    border-color: #4CAF50;
    background: #f1f8f4;
    box-shadow: 0 4px 12px rgba(76, 175, 80, 0.3);
}

.marketplace-product-card .product-checkbox {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 20px;
    color: #999;
    z-index: 10;
}

.marketplace-product-card.selected .product-checkbox {
    color: #4CAF50;
}

.marketplace-product-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 6px;
    margin-bottom: 10px;
}

.marketplace-product-card .product-info {
    text-align: left;
}

.marketplace-product-card .product-article {
    font-size: 11px;
    color: #666;
    background: #f5f5f5;
    padding: 3px 8px;
    border-radius: 4px;
    display: inline-block;
    margin-bottom: 5px;
}

.marketplace-product-card .product-title {
    font-size: 13px;
    margin: 5px 0;
    color: #333;
    font-weight: 600;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    line-height: 1.3;
}

.marketplace-product-card .product-brand,
.marketplace-product-card .product-sizes {
    font-size: 11px;
    color: #666;
    margin: 3px 0;
}

.marketplace-product-card .product-brand i,
.marketplace-product-card .product-sizes i {
    margin-right: 4px;
    color: #999;
}

/* ============================================
   УЛУЧШЕННЫЕ ЗАЯВКИ
   ============================================ */

.applications-filter-bar {
    display: flex;
    gap: 10px;
    margin-bottom: 25px;
    flex-wrap: wrap;
    padding: 15px;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    border-radius: 12px;
}

.app-filter-btn {
    padding: 10px 20px;
    border: 2px solid transparent;
    border-radius: 8px;
    background: white;
    color: #666;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 8px;
}

.app-filter-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

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

.applications-enhanced-list {
    display: grid;
    gap: 20px;
}

.application-enhanced-card {
    background: white;
    border-radius: 12px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

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

.app-enhanced-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
}

.app-enhanced-title {
    display: flex;
    align-items: center;
    gap: 15px;
}

.status-badge-enhanced {
    padding: 6px 14px;
    border-radius: 20px;
    color: white;
    font-size: 13px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.app-enhanced-description {
    padding: 12px;
    background: #f8f9fa;
    border-radius: 8px;
    margin-bottom: 15px;
    color: #666;
    line-height: 1.6;
}

.app-enhanced-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    color: #999;
    padding-top: 15px;
    border-top: 1px solid #eee;
}

.app-enhanced-id {
    font-weight: 700;
    color: #667eea;
}

/* Детальный просмотр */
.application-detail-view {
    padding: 10px;
}

.app-detail-header {
    background: white;
    padding: 25px;
    border-radius: 12px;
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.app-detail-section {
    background: white;
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 20px;
}

.app-detail-section h3 {
    margin: 0 0 15px 0;
    color: #333;
    font-size: 18px;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Кнопки типов заявок */
.application-types-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 25px;
}

.app-type-card {
    background: white;
    padding: 20px;
    border-radius: 12px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    border: 2px solid #e0e0e0;
}

.app-type-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.12);
    border-color: #667eea;
}

.app-type-card .icon {
    font-size: 48px;
    margin-bottom: 10px;
}

.app-type-card .title {
    font-weight: 600;
    color: #333;
    margin-bottom: 5px;
}

.app-type-card .description {
    font-size: 12px;
    color: #666;
}


/* ============================================
   БЛОК ДАННЫХ КЛИЕНТА В ЗАЯВКЕ
   ============================================ */

.application-client-info {
    background: linear-gradient(135deg, #667eea15 0%, #764ba215 100%);
    border-left: 4px solid #667eea;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 25px;
}

.client-info-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
}

.client-info-header > div {
    display: flex;
    align-items: center;
    gap: 12px;
}

.btn-check-profile {
    padding: 8px 16px;
    background: white;
    border: 2px solid #667eea;
    border-radius: 6px;
    color: #667eea;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 6px;
}

.btn-check-profile:hover {
    background: #667eea;
    color: white;
    transform: translateY(-2px);
}

.client-info-details {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 2px dashed #667eea40;
    animation: slideDown 0.3s ease;
}

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

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

.client-info-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    background: white;
    padding: 15px;
    border-radius: 8px;
}

.client-info-item > i {
    font-size: 20px;
    color: #667eea;
    margin-top: 3px;
}

.client-info-item label {
    display: block;
    font-size: 12px;
    color: #999;
    margin-bottom: 4px;
    font-weight: 600;
    text-transform: uppercase;
}

.client-info-item p {
    margin: 0;
    font-size: 14px;
    color: #333;
    font-weight: 500;
}

.modal-header-custom {
    margin-bottom: 25px;
}

.modal-header-custom h2 {
    margin: 0 0 10px 0;
    color: #333;
}

/* Checkbox группы */
.checkbox-group {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 10px;
    margin-top: 10px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
}

.checkbox-label:hover {
    background: #e9ecef;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.checkbox-label span {
    font-size: 14px;
    color: #333;
}

.required {
    color: #dc3545;
    margin-left: 3px;
}


/* ============================================
   КУБИКИ ТИПОВ ЗАЯВОК
   ============================================ */

.application-types-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 15px;
    margin-bottom: 25px;
}

.app-type-card {
    background: white;
    padding: 25px 20px;
    border-radius: 12px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    border: 2px solid #e0e0e0;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.app-type-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
    border-color: #667eea;
}

.app-type-card .icon {
    font-size: 48px;
    margin-bottom: 12px;
    display: block;
}

.app-type-card .title {
    font-weight: 700;
    color: #333;
    margin-bottom: 6px;
    font-size: 15px;
}

.app-type-card .description {
    font-size: 12px;
    color: #666;
}

/* ============================================
   ПЕРЕКЛЮЧАТЕЛЬ ВИДОВ
   ============================================ */

.view-switcher {
    display: inline-flex;
    gap: 5px;
    background: #f5f5f5;
    padding: 5px;
    border-radius: 8px;
}

.view-switch-btn {
    padding: 8px 14px;
    border: none;
    background: transparent;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s;
    color: #666;
    font-size: 16px;
}

.view-switch-btn:hover {
    background: white;
    color: #667eea;
}

.view-switch-btn.active {
    background: #667eea;
    color: white;
}

/* ============================================
   ФИЛЬТРЫ ЗАЯВОК
   ============================================ */

.applications-filter-bar {
    display: flex;
    gap: 10px;
    margin-bottom: 25px;
    flex-wrap: wrap;
    padding: 15px;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    border-radius: 12px;
}

.app-filter-btn {
    padding: 10px 20px;
    border: 2px solid transparent;
    border-radius: 8px;
    background: white;
    color: #666;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 8px;
}

.app-filter-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

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

/* ============================================
   KANBAN VIEW
   ============================================ */

.kanban-board {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    min-height: 400px;
}

.kanban-column {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 15px;
}

.kanban-column-header {
    padding: 12px 15px;
    border-radius: 8px;
    color: white;
    font-weight: 700;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.kanban-count {
    margin-left: auto;
    background: rgba(255,255,255,0.3);
    padding: 2px 10px;
    border-radius: 12px;
    font-size: 13px;
}

.kanban-cards {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.kanban-card {
    background: white;
    padding: 15px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    border-left: 4px solid #667eea;
}

.kanban-card:hover {
    transform: translateX(5px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.kanban-card-icon {
    font-size: 24px;
    margin-bottom: 8px;
}

.kanban-card-title {
    font-weight: 600;
    color: #333;
    margin-bottom: 5px;
}

.kanban-card-type {
    font-size: 12px;
    color: #999;
    margin-bottom: 8px;
}

.kanban-card-desc {
    font-size: 13px;
    color: #666;
    margin-bottom: 10px;
    line-height: 1.4;
}

.kanban-card-footer {
    font-size: 11px;
    color: #999;
    display: flex;
    align-items: center;
    gap: 5px;
}

/* ============================================
   LIST VIEW (с жизненным циклом)
   ============================================ */

.applications-list-view {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.app-list-item {
    background: white;
    border-radius: 12px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.3s;
    border: 2px solid #e0e0e0;
    display: flex;
    gap: 20px;
    align-items: center;
}

.app-list-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
    border-color: #667eea;
}

.app-list-left {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    min-width: 80px;
}

.app-list-icon {
    font-size: 36px;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
}

.app-list-number {
    font-size: 13px;
    font-weight: 700;
    color: #667eea;
}

.app-list-center {
    flex: 1;
}

.app-list-title {
    font-size: 18px;
    font-weight: 700;
    color: #333;
    margin-bottom: 8px;
}

.app-list-meta {
    display: flex;
    gap: 20px;
    font-size: 13px;
    color: #666;
    margin-bottom: 10px;
}

.app-list-meta span {
    display: flex;
    align-items: center;
    gap: 6px;
}

.app-list-description {
    font-size: 14px;
    color: #666;
    line-height: 1.5;
    margin-bottom: 15px;
}

/* Жизненный цикл */
.app-lifecycle {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #eee;
}

.lifecycle-steps {
    display: flex;
    align-items: center;
    gap: 0;
}

.lifecycle-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.lifecycle-step span {
    font-size: 11px;
    color: #999;
    font-weight: 600;
}

.lifecycle-step.active span {
    color: #667eea;
}

.lifecycle-dot {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #e0e0e0;
    border: 3px solid white;
    box-shadow: 0 0 0 2px #e0e0e0;
}

.lifecycle-step.active .lifecycle-dot {
    background: #667eea;
    box-shadow: 0 0 0 2px #667eea;
}

.lifecycle-line {
    height: 2px;
    flex: 1;
    background: #e0e0e0;
    margin: 0 10px;
}

.lifecycle-line.active {
    background: #667eea;
}

.app-list-right {
    min-width: 120px;
    text-align: center;
}

.app-list-status {
    padding: 8px 16px;
    border-radius: 20px;
    color: white;
    font-size: 13px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}

/* ============================================
   TILES VIEW
   ============================================ */

.applications-tiles-view {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
}

.app-tile {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.app-tile:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
}

.app-tile-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
}

.app-tile-icon {
    font-size: 32px;
}

.app-tile-status {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.app-tile-body {
    padding: 0 20px 15px 20px;
}

.app-tile-body h4 {
    margin: 0 0 8px 0;
    font-size: 16px;
    color: #333;
}

.app-tile-type {
    font-size: 12px;
    color: #999;
    margin-bottom: 10px;
}

.app-tile-description {
    font-size: 13px;
    color: #666;
    line-height: 1.5;
}

.app-tile-footer {
    padding: 15px 20px;
    background: #f8f9fa;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: #666;
}

.app-tile-id {
    font-weight: 700;
    color: #667eea;
}

/* ============================================
   МОДАЛЬНОЕ ОКНО ВЫБОРА ТИПА ЗАЯВКИ
   ============================================ */

.modal-app-types {
    max-width: 1100px;
    width: 95%;
    padding: 40px;
    max-height: 90vh;
    overflow-y: auto;
}

.app-types-modal-header {
    text-align: center;
    margin-bottom: 40px;
    padding-bottom: 25px;
    border-bottom: 3px solid #e9ecef;
}

.app-types-modal-header h2 {
    margin: 0 0 12px 0;
    font-size: 32px;
    color: #333;
    font-weight: 800;
}

.app-types-modal-header p {
    margin: 0;
    color: #666;
    font-size: 16px;
}


.tile-emoji {
    font-size: 90px;
    position: relative;
    z-index: 2;
    transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.1));
}

.app-type-tile-card:hover .tile-emoji {
    transform: scale(1.25) rotate(12deg);
}

/* Градиентные фоны с улучшенными цветами */
.callback-bg {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.calculation-bg {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

.acceptance-bg {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

.processing-bg {
    background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
}

.shipment-bg {
    background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
}

.other-bg {
    background: linear-gradient(135deg, #30cfd0 0%, #330867 100%);
}

.app-tile-info {
    padding: 25px 20px;
    text-align: center;
    background: white;
    position: relative;
    z-index: 2;
}

.app-tile-info h3 {
    margin: 0 0 10px 0;
    font-size: 19px;
    font-weight: 800;
    color: #333;
    transition: color 0.3s;
}

.app-type-tile-card:hover .app-tile-info h3 {
    color: #667eea;
}

.app-tile-info p {
    margin: 0;
    font-size: 14px;
    color: #666;
    line-height: 1.5;
}

/* Адаптивность */
@media (max-width: 1024px) {
    .modal-app-types {
        max-width: 900px;
    }
    


@media (max-width: 900px) {
    .modal-app-types {
        max-width: 700px;
        padding: 30px;
    }
    

    
    .app-tile-img {
        height: 180px;
    }
    
    .tile-emoji {
        font-size: 80px;
    }
}

@media (max-width: 600px) {
    .modal-app-types {
        width: 100%;
        max-width: 100%;
        padding: 20px;
        border-radius: 0;
    }
    

    
    .app-tile-img {
        height: 160px;
    }
    
    .tile-emoji {
        font-size: 70px;
    }
    
    .app-types-modal-header h2 {
        font-size: 24px;
    }
}

/* Анимация появления карточек */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.app-type-tile-card {
    animation: fadeInUp 0.5s ease-out;
}

.app-type-tile-card:nth-child(1) { animation-delay: 0.05s; }
.app-type-tile-card:nth-child(2) { animation-delay: 0.1s; }
.app-type-tile-card:nth-child(3) { animation-delay: 0.15s; }
.app-type-tile-card:nth-child(4) { animation-delay: 0.2s; }
.app-type-tile-card:nth-child(5) { animation-delay: 0.25s; }
.app-type-tile-card:nth-child(6) { animation-delay: 0.3s; }

/* ============================================
   ЖИЗНЕННЫЙ ЦИКЛ SVG
   ============================================ */

.app-lifecycle-svg {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #f0f0f0;
}

.lifecycle-svg {
    width: 100%;
    height: 80px;
    display: block;
}

/* Анимация пульсации для активного этапа */
@keyframes pulse {
    0%, 100% {
        opacity: 0.6;
        r: 15;
    }
    50% {
        opacity: 0;
        r: 25;
    }
}

/* ============================================
   ОБНОВЛЕННЫЙ VIEW SWITCHER (крупнее)
   ============================================ */

.view-switcher {
    display: inline-flex;
    gap: 8px;
    background: linear-gradient(135deg, #f5f7fa 0%, #e0e7ef 100%);
    padding: 6px;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.view-switch-btn {
    padding: 10px 18px;
    border: none;
    background: transparent;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
    color: #666;
    font-size: 18px;
}

.view-switch-btn:hover {
    background: white;
    color: #667eea;
    transform: translateY(-2px);
}

.view-switch-btn.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

/* ============================================
   ОБНОВЛЕННЫЙ APP LIST ITEM
   ============================================ */

.app-list-item {
    background: white;
    border-radius: 16px;
    padding: 25px;
    cursor: pointer;
    transition: all 0.3s;
    border: 2px solid #e0e0e0;
    display: flex;
    gap: 25px;
    align-items: flex-start;
}

.app-list-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0,0,0,0.12);
    border-color: #667eea;
}

.app-list-left {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    min-width: 90px;
}

.app-list-icon {
    font-size: 42px;
    width: 70px;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
}

.app-list-number {
    font-size: 14px;
    font-weight: 700;
    color: #667eea;
}

.app-list-center {
    flex: 1;
    min-width: 0;
}

.app-list-title {
    font-size: 20px;
    font-weight: 700;
    color: #333;
    margin-bottom: 10px;
}

.app-list-meta {
    display: flex;
    gap: 25px;
    font-size: 14px;
    color: #666;
    margin-bottom: 12px;
}

.app-list-meta span {
    display: flex;
    align-items: center;
    gap: 8px;
}

.app-list-description {
    font-size: 14px;
    color: #666;
    line-height: 1.6;
}

.app-list-right {
    min-width: 140px;
    text-align: center;
}

.app-list-status {
    padding: 10px 20px;
    border-radius: 24px;
    color: white;
    font-size: 14px;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

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

@media (max-width: 768px) {
    .app-list-item {
        flex-direction: column;
    }
    
    .app-list-left {
        flex-direction: row;
        width: 100%;
        justify-content: center;
    }
    
    .lifecycle-svg {
        height: 100px;
    }
}

/* ============================================
   МОДАЛЬНОЕ ОКНО С ТИПАМИ ЗАЯВОК (ПЛИТКИ)
   ============================================ */

.modal-types-grid {
    max-width: 1000px;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-types-header {
    text-align: center;
    margin-bottom: 35px;
    padding-bottom: 20px;
    border-bottom: 2px solid #e0e0e0;
}

.modal-types-header h2 {
    margin: 0 0 10px 0;
    color: #333;
    font-size: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.modal-types-header p {
    margin: 0;
    color: #666;
    font-size: 14px;
}



.app-type-tile {
    background: white;
    border: 3px solid #e0e0e0;
    border-radius: 16px;
    padding: 0;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    overflow: hidden;
}

.app-type-tile:hover {
    transform: translateY(-10px) scale(1.05);
    border-color: #667eea;
    box-shadow: 0 20px 50px rgba(102, 126, 234, 0.3);
}

.app-type-tile-image {
    width: 100%;
    height: 160px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    position: relative;
    overflow: hidden;
}

.app-type-tile:hover .app-type-tile-image svg {
    transform: scale(1.15) rotate(5deg);
}

.app-type-tile-image svg {
    width: 100%;
    height: 100%;
    transition: transform 0.4s;
}

.app-type-tile-content {
    padding: 20px;
    text-align: center;
    background: white;
}

.app-type-tile-content h3 {
    margin: 0 0 8px 0;
    font-size: 18px;
    color: #333;
    font-weight: 700;
    transition: color 0.3s;
}

.app-type-tile:hover .app-type-tile-content h3 {
    color: #667eea;
}

.app-type-tile-content p {
    margin: 0;
    color: #666;
    font-size: 13px;
}





/* ============================================
   ПЕРЕКЛЮЧАТЕЛЬ ВИДОВ
   ============================================ */

.view-switcher {
    display: inline-flex;
    gap: 8px;
    background: linear-gradient(135deg, #f5f7fa 0%, #e0e7ef 100%);
    padding: 6px;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.view-switch-btn {
    padding: 10px 18px;
    border: none;
    background: transparent;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
    color: #666;
    font-size: 18px;
}

.view-switch-btn:hover {
    background: white;
    color: #667eea;
    transform: translateY(-2px);
}

.view-switch-btn.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

/* ============================================
   ФИЛЬТРЫ ЗАЯВОК
   ============================================ */

.applications-filter-bar {
    display: flex;
    gap: 10px;
    margin-bottom: 25px;
    flex-wrap: wrap;
    padding: 15px;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    border-radius: 12px;
}

.app-filter-btn {
    padding: 10px 20px;
    border: 2px solid transparent;
    border-radius: 8px;
    background: white;
    color: #666;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 8px;
}

.app-filter-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

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

/* ============================================
   СПИСОК ЗАЯВОК
   ============================================ */

.applications-list-view {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.app-list-item {
    background: white;
    border-radius: 16px;
    padding: 25px;
    cursor: pointer;
    transition: all 0.3s;
    border: 2px solid #e0e0e0;
    display: flex;
    gap: 25px;
    align-items: flex-start;
}

.app-list-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0,0,0,0.12);
    border-color: #667eea;
}

.app-list-left {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    min-width: 90px;
}

.app-list-icon {
    font-size: 42px;
    width: 70px;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
}

.app-list-number {
    font-size: 14px;
    font-weight: 700;
    color: #667eea;
}

.app-list-center {
    flex: 1;
    min-width: 0;
}

.app-list-title {
    font-size: 20px;
    font-weight: 700;
    color: #333;
    margin-bottom: 10px;
}

.app-list-meta {
    display: flex;
    gap: 25px;
    font-size: 14px;
    color: #666;
    margin-bottom: 12px;
}

.app-list-meta span {
    display: flex;
    align-items: center;
    gap: 8px;
}

.app-list-description {
    font-size: 14px;
    color: #666;
    line-height: 1.6;
    margin-bottom: 15px;
}

.app-list-right {
    min-width: 140px;
    text-align: center;
}

.app-list-status {
    padding: 10px 20px;
    border-radius: 24px;
    color: white;
    font-size: 14px;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

/* ============================================
   ЖИЗНЕННЫЙ ЦИКЛ ЗАЯВКИ
   ============================================ */

.lifecycle-container {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0;
    margin-top: 20px;
    padding: 20px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 12px;
}

.lifecycle-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    position: relative;
}

.lifecycle-circle {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 4px solid #e0e0e0;
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.4s;
    font-size: 20px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.lifecycle-step.active .lifecycle-circle {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(0,0,0,0.15);
}

.lifecycle-circle.pulse {
    animation: pulse-ring 1.5s infinite;
}

@keyframes pulse-ring {
    0% {
        box-shadow: 0 0 0 0 rgba(255, 193, 7, 0.7);
    }
    50% {
        box-shadow: 0 0 0 15px rgba(255, 193, 7, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(255, 193, 7, 0);
    }
}

.lifecycle-label {
    font-size: 12px;
    font-weight: 700;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.lifecycle-line {
    flex: 1;
    height: 4px;
    background: #e0e0e0;
    margin: 0 15px;
    border-radius: 2px;
    transition: all 0.4s;
    position: relative;
    top: -20px;
    min-width: 60px;
}

.lifecycle-line.active {
    background: linear-gradient(90deg, currentColor 0%, currentColor 100%);
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

/* ============================================
   KANBAN VIEW
   ============================================ */

.kanban-board {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    min-height: 400px;
}

.kanban-column {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 15px;
}

.kanban-column-header {
    padding: 12px 15px;
    border-radius: 8px;
    color: white;
    font-weight: 700;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.kanban-count {
    margin-left: auto;
    background: rgba(255,255,255,0.3);
    padding: 2px 10px;
    border-radius: 12px;
    font-size: 13px;
}

.kanban-cards {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.kanban-card {
    background: white;
    padding: 15px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    border-left: 4px solid #667eea;
}

.kanban-card:hover {
    transform: translateX(5px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.kanban-card-icon {
    font-size: 24px;
    margin-bottom: 8px;
}

.kanban-card-title {
    font-weight: 600;
    color: #333;
    margin-bottom: 5px;
}

.kanban-card-type {
    font-size: 12px;
    color: #999;
    margin-bottom: 8px;
}

.kanban-card-desc {
    font-size: 13px;
    color: #666;
    margin-bottom: 10px;
    line-height: 1.4;
}

.kanban-card-footer {
    font-size: 11px;
    color: #999;
    display: flex;
    align-items: center;
    gap: 5px;
}

/* ============================================
   TILES VIEW
   ============================================ */

.applications-tiles-view {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
}

.app-tile {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.app-tile:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
}

.app-tile-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
}

.app-tile-icon {
    font-size: 32px;
}

.app-tile-status {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.app-tile-body {
    padding: 0 20px 15px 20px;
}

.app-tile-body h4 {
    margin: 0 0 8px 0;
    font-size: 16px;
    color: #333;
}

.app-tile-type {
    font-size: 12px;
    color: #999;
    margin-bottom: 10px;
}

.app-tile-description {
    font-size: 13px;
    color: #666;
    line-height: 1.5;
}

.app-tile-footer {
    padding: 15px 20px;
    background: #f8f9fa;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: #666;
}

.app-tile-id {
    font-weight: 700;
    color: #667eea;
}

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

@media (max-width: 768px) {
    .app-list-item {
        flex-direction: column;
    }
    
    .app-list-left {
        flex-direction: row;
        width: 100%;
        justify-content: center;
    }
    
    .lifecycle-container {
        overflow-x: auto;
    }
    
    .lifecycle-line {
        min-width: 40px;
    }
}

/* ============================================
   МОДАЛЬНОЕ ОКНО ВЫБОРА ТИПА ЗАЯВКИ
   ============================================ */

.modal-app-types {
    max-width: 950px;
    padding: 35px;
}

.app-types-modal-header {
    text-align: center;
    margin-bottom: 35px;
}

.app-types-modal-header h2 {
    margin: 0 0 10px 0;
    font-size: 28px;
    color: #333;
}

.app-types-modal-header p {
    margin: 0;
    color: #666;
    font-size: 15px;
}



.app-type-tile-card {
    background: white;
    border: 3px solid #e9ecef;
    border-radius: 16px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.app-type-tile-card:hover {
    transform: translateY(-10px) scale(1.03);
    border-color: #667eea;
    box-shadow: 0 20px 50px rgba(102, 126, 234, 0.3);
}

.app-tile-img {
    height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.tile-emoji {
    font-size: 80px;
    position: relative;
    z-index: 2;
    transition: transform 0.4s;
}

.app-type-tile-card:hover .tile-emoji {
    transform: scale(1.2) rotate(10deg);
}

/* Градиентные фоны */
.callback-bg {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.calculation-bg {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

.acceptance-bg {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

.processing-bg {
    background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
}

.shipment-bg {
    background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
}

.other-bg {
    background: linear-gradient(135deg, #30cfd0 0%, #330867 100%);
}

.app-tile-info {
    padding: 20px;
    text-align: center;
    background: white;
}

.app-tile-info h3 {
    margin: 0 0 8px 0;
    font-size: 18px;
    font-weight: 700;
    color: #333;
}

.app-tile-info p {
    margin: 0;
    font-size: 13px;
    color: #666;
}

/* Адаптив */




/* ============================================
   ЖИЗНЕННЫЙ ЦИКЛ В СПИСКЕ ЗАЯВОК
   ============================================ */

.lifecycle-track {
    display: flex;
    align-items: center;
    gap: 0;
    margin-top: 20px;
    padding: 20px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 12px;
}

.lifecycle-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.lifecycle-dot {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 4px solid #e0e0e0;
    background: #e0e0e0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: white;
    transition: all 0.4s;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    position: relative;
}

.lifecycle-item.completed .lifecycle-dot {
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

.lifecycle-dot.pulsing::before {
    content: '';
    position: absolute;
    top: -5px;
    left: -5px;
    right: -5px;
    bottom: -5px;
    border-radius: 50%;
    border: 3px solid currentColor;
    animation: pulse-animation 1.5s infinite;
    opacity: 0.6;
}

@keyframes pulse-animation {
    0% {
        transform: scale(1);
        opacity: 0.6;
    }
    50% {
        transform: scale(1.2);
        opacity: 0.3;
    }
    100% {
        transform: scale(1);
        opacity: 0.6;
    }
}

.lifecycle-text {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #999;
}

.lifecycle-connector {
    flex: 1;
    height: 4px;
    background: #e0e0e0;
    margin: 0 15px;
    border-radius: 2px;
    position: relative;
    top: -20px;
    min-width: 50px;
    transition: all 0.4s;
}

.lifecycle-connector.active {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

/* ============================================
   СПИСОК ЗАЯВОК
   ============================================ */

.applications-list-view {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.app-list-item {
    background: white;
    border-radius: 16px;
    padding: 25px;
    cursor: pointer;
    transition: all 0.3s;
    border: 2px solid #e0e0e0;
    display: flex;
    gap: 25px;
    align-items: flex-start;
}

.app-list-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.12);
    border-color: #667eea;
}

.app-list-left {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    min-width: 90px;
}

.app-list-icon {
    font-size: 42px;
    width: 70px;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
}

.app-list-number {
    font-size: 14px;
    font-weight: 700;
    color: #667eea;
}

.app-list-center {
    flex: 1;
    min-width: 0;
}

.app-list-title {
    font-size: 20px;
    font-weight: 700;
    color: #333;
    margin-bottom: 10px;
}

.app-list-meta {
    display: flex;
    gap: 25px;
    font-size: 14px;
    color: #666;
    margin-bottom: 12px;
}

.app-list-meta span {
    display: flex;
    align-items: center;
    gap: 8px;
}

.app-list-description {
    font-size: 14px;
    color: #666;
    line-height: 1.6;
    margin-bottom: 15px;
}

.app-list-right {
    min-width: 140px;
    text-align: center;
}

.app-list-status {
    padding: 10px 20px;
    border-radius: 24px;
    color: white;
    font-size: 14px;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* ============================================
   ФИЛЬТРЫ И КНОПКИ
   ============================================ */

.applications-filter-bar {
    display: flex;
    gap: 10px;
    margin-bottom: 25px;
    flex-wrap: wrap;
    padding: 15px;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    border-radius: 12px;
}

.app-filter-btn {
    padding: 10px 20px;
    border: 2px solid transparent;
    border-radius: 8px;
    background: white;
    color: #666;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 8px;
}

.app-filter-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

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

.view-switcher {
    display: inline-flex;
    gap: 8px;
    background: linear-gradient(135deg, #f5f7fa 0%, #e0e7ef 100%);
    padding: 6px;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.view-switch-btn {
    padding: 10px 18px;
    border: none;
    background: transparent;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
    color: #666;
    font-size: 18px;
}

.view-switch-btn:hover {
    background: white;
    color: #667eea;
    transform: translateY(-2px);
}

.view-switch-btn.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

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

@media (max-width: 768px) {
    .app-list-item {
        flex-direction: column;
    }
    
    .app-list-left {
        flex-direction: row;
        width: 100%;
        justify-content: center;
    }
    
    .lifecycle-track {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    .lifecycle-connector {
        min-width: 30px;
    }
}




.app-type-tile-card {
    background: white;
    border: 3px solid #e9ecef;
    border-radius: 20px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    position: relative;
    min-height: 280px;
    display: flex;
    flex-direction: column;
}

.app-type-tile-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0) 100%);
    opacity: 0;
    transition: opacity 0.4s;
    z-index: 1;
}

.app-type-tile-card:hover::before {
    opacity: 1;
}

.app-type-tile-card:hover {
    transform: translateY(-12px) scale(1.04);
    border-color: #667eea;
    box-shadow: 0 25px 60px rgba(102, 126, 234, 0.35);
}

.app-tile-img {
    height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
}

.app-tile-img::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at center, rgba(255,255,255,0.2) 0%, transparent 70%);
}

.tile-emoji {
    font-size: 85px;
    position: relative;
    z-index: 2;
    transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.1));
}

.app-type-tile-card:hover .tile-emoji {
    transform: scale(1.25) rotate(12deg);
}

/* Градиентные фоны с улучшенными цветами */
.callback-bg {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.calculation-bg {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

.acceptance-bg {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

.processing-bg {
    background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
}

.shipment-bg {
    background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
}

.other-bg {
    background: linear-gradient(135deg, #30cfd0 0%, #330867 100%);
}

.app-tile-info {
    padding: 20px;
    text-align: center;
    background: white;
    position: relative;
    z-index: 2;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.app-tile-info h3 {
    margin: 0 0 8px 0;
    font-size: 18px;
    font-weight: 800;
    color: #333;
    transition: color 0.3s;
}

.app-type-tile-card:hover .app-tile-info h3 {
    color: #667eea;
}

.app-tile-info p {
    margin: 0;
    font-size: 13px;
    color: #666;
    line-height: 1.5;
}

/* Анимация появления карточек */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.app-type-tile-card {
    animation: fadeInUp 0.5s ease-out;
}

.app-type-tile-card:nth-child(1) { animation-delay: 0.05s; }
.app-type-tile-card:nth-child(2) { animation-delay: 0.1s; }
.app-type-tile-card:nth-child(3) { animation-delay: 0.15s; }
.app-type-tile-card:nth-child(4) { animation-delay: 0.2s; }
.app-type-tile-card:nth-child(5) { animation-delay: 0.25s; }
.app-type-tile-card:nth-child(6) { animation-delay: 0.3s; }

/* Адаптивность */
@media (max-width: 1024px) {
    .modal-app-types {
        max-width: 900px;
    }
    


@media (max-width: 900px) {
    .modal-app-types {
        max-width: 700px;
        padding: 30px;
    }
    

    

    
    .tile-emoji {
        font-size: 75px;
    }
}

@media (max-width: 600px) {
    .modal-app-types {
        width: 100%;
        max-width: 100%;
        padding: 20px;
        border-radius: 0;
    }
    

    
    .app-tile-img {
        height: 140px;
    }
    
    .tile-emoji {
        font-size: 65px;
    }
    
    .app-types-modal-header h2 {
        font-size: 24px;
    }
}

.app-types-tiles {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(2, 1fr);
    gap: 30px;
    padding: 10px;
    width: 100%;
}

.app-type-tile-card {
    background: white;
    border: 3px solid #e9ecef;
    border-radius: 20px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    position: relative;
    min-height: 280px;
    display: flex;
    flex-direction: column;
}

.app-type-tile-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0) 100%);
    opacity: 0;
    transition: opacity 0.4s;
    z-index: 1;
}

.app-type-tile-card:hover::before {
    opacity: 1;
}

.app-type-tile-card:hover {
    transform: translateY(-12px) scale(1.04);
    border-color: #667eea;
    box-shadow: 0 25px 60px rgba(102, 126, 234, 0.35);
}

.app-tile-img {
    height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
}

.app-tile-img::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at center, rgba(255,255,255,0.2) 0%, transparent 70%);
}

.tile-emoji {
    font-size: 85px;
    position: relative;
    z-index: 2;
    transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.1));
}

.app-type-tile-card:hover .tile-emoji {
    transform: scale(1.25) rotate(12deg);
}

/* Градиентные фоны с улучшенными цветами */
.callback-bg {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.calculation-bg {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

.acceptance-bg {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

.processing-bg {
    background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
}

.shipment-bg {
    background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
}

.other-bg {
    background: linear-gradient(135deg, #30cfd0 0%, #330867 100%);
}

.app-tile-info {
    padding: 20px;
    text-align: center;
    background: white;
    position: relative;
    z-index: 2;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.app-tile-info h3 {
    margin: 0 0 8px 0;
    font-size: 18px;
    font-weight: 800;
    color: #333;
    transition: color 0.3s;
}

.app-type-tile-card:hover .app-tile-info h3 {
    color: #667eea;
}

.app-tile-info p {
    margin: 0;
    font-size: 13px;
    color: #666;
    line-height: 1.5;
}

/* Анимация появления карточек */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.app-type-tile-card {
    animation: fadeInUp 0.5s ease-out;
}

.app-type-tile-card:nth-child(1) { animation-delay: 0.05s; }
.app-type-tile-card:nth-child(2) { animation-delay: 0.1s; }
.app-type-tile-card:nth-child(3) { animation-delay: 0.15s; }
.app-type-tile-card:nth-child(4) { animation-delay: 0.2s; }
.app-type-tile-card:nth-child(5) { animation-delay: 0.25s; }
.app-type-tile-card:nth-child(6) { animation-delay: 0.3s; }

/* Адаптивность */
@media (max-width: 1024px) {
    .modal-app-types {
        max-width: 900px;
    }
    
    .app-types-tiles {
        gap: 25px;
    }
}

@media (max-width: 900px) {
    .modal-app-types {
        max-width: 700px;
        padding: 30px;
    }
    
    .app-types-tiles {
        grid-template-columns: repeat(2, 1fr);
        grid-template-rows: repeat(3, 1fr);
        gap: 20px;
    }
    
    .app-tile-img {
        height: 160px;
    }
    
    .tile-emoji {
        font-size: 75px;
    }
}

@media (max-width: 600px) {
    .modal-app-types {
        width: 100%;
        max-width: 100%;
        padding: 20px;
        border-radius: 0;
    }
    
    .app-types-tiles {
        grid-template-columns: 1fr;
        grid-template-rows: auto;
        gap: 15px;
    }
    
    .app-tile-img {
        height: 140px;
    }
    
    .tile-emoji {
        font-size: 65px;
    }
    
    .app-types-modal-header h2 {
        font-size: 24px;
    }
}

/* ============================================
   ИСПРАВЛЕНИЕ: МОДАЛЬНОЕ ОКНО С ТИПАМИ ЗАЯВОК
   ============================================ */

/* Переопределяем все предыдущие стили */
.modal-app-types {
    max-width: 1100px !important;
    width: 95% !important;
    padding: 40px !important;
}

.app-types-tiles {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    grid-template-rows: repeat(2, 1fr) !important;
    gap: 30px !important;
    padding: 10px !important;
    width: 100% !important;
}

.app-type-tile-card {
    background: white !important;
    border: 3px solid #e9ecef !important;
    border-radius: 20px !important;
    overflow: hidden !important;
    cursor: pointer !important;
    min-height: 280px !important;
    display: flex !important;
    flex-direction: column !important;
}

/* Адаптив */
@media (max-width: 900px) {
    .app-types-tiles {
        grid-template-columns: repeat(2, 1fr) !important;
        grid-template-rows: repeat(3, 1fr) !important;
    }
}

@media (max-width: 600px) {
    .app-types-tiles {
        grid-template-columns: 1fr !important;
        grid-template-rows: auto !important;
    }
}

/* ============================================
   ФИКС: ПЛИТКИ ЗАЯВОК 3x2
   ============================================ */

.modal-app-types {
    max-width: 1100px !important;
    width: 95% !important;
    padding: 40px !important;
    max-height: 90vh !important;
    overflow-y: auto !important;
}

.app-types-modal-header {
    text-align: center !important;
    margin-bottom: 40px !important;
    padding-bottom: 25px !important;
    border-bottom: 3px solid #e9ecef !important;
}

.app-types-modal-header h2 {
    margin: 0 0 12px 0 !important;
    font-size: 32px !important;
    color: #333 !important;
    font-weight: 800 !important;
}

.app-types-modal-header p {
    margin: 0 !important;
    color: #666 !important;
    font-size: 16px !important;
}

.app-types-tiles {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    grid-template-rows: repeat(2, 1fr) !important;
    gap: 30px !important;
    padding: 10px !important;
    width: 100% !important;
}

.app-type-tile-card {
    background: white !important;
    border: 3px solid #e9ecef !important;
    border-radius: 20px !important;
    overflow: hidden !important;
    cursor: pointer !important;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08) !important;
    position: relative !important;
    min-height: 280px !important;
    display: flex !important;
    flex-direction: column !important;
}

.app-type-tile-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0) 100%);
    opacity: 0;
    transition: opacity 0.4s;
    z-index: 1;
}

.app-type-tile-card:hover::before {
    opacity: 1;
}

.app-type-tile-card:hover {
    transform: translateY(-12px) scale(1.04) !important;
    border-color: #667eea !important;
    box-shadow: 0 25px 60px rgba(102, 126, 234, 0.35) !important;
}

.app-tile-img {
    height: 180px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    position: relative !important;
    overflow: hidden !important;
    flex-shrink: 0 !important;
}

.app-tile-img::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at center, rgba(255,255,255,0.2) 0%, transparent 70%);
}

.tile-emoji {
    font-size: 85px !important;
    position: relative !important;
    z-index: 2 !important;
    transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.1)) !important;
}

.app-type-tile-card:hover .tile-emoji {
    transform: scale(1.25) rotate(12deg) !important;
}

/* Градиенты */
.callback-bg {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
}

.calculation-bg {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%) !important;
}

.acceptance-bg {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%) !important;
}

.processing-bg {
    background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%) !important;
}

.shipment-bg {
    background: linear-gradient(135deg, #fa709a 0%, #fee140 100%) !important;
}

.other-bg {
    background: linear-gradient(135deg, #30cfd0 0%, #330867 100%) !important;
}

.app-tile-info {
    padding: 20px !important;
    text-align: center !important;
    background: white !important;
    position: relative !important;
    z-index: 2 !important;
    flex: 1 !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
}

.app-tile-info h3 {
    margin: 0 0 8px 0 !important;
    font-size: 18px !important;
    font-weight: 800 !important;
    color: #333 !important;
    transition: color 0.3s !important;
}

.app-type-tile-card:hover .app-tile-info h3 {
    color: #667eea !important;
}

.app-tile-info p {
    margin: 0 !important;
    font-size: 13px !important;
    color: #666 !important;
    line-height: 1.5 !important;
}

/* Анимация появления */
@keyframes fadeInUpTiles {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.app-type-tile-card {
    animation: fadeInUpTiles 0.5s ease-out !important;
}

.app-type-tile-card:nth-child(1) { animation-delay: 0.05s !important; }
.app-type-tile-card:nth-child(2) { animation-delay: 0.1s !important; }
.app-type-tile-card:nth-child(3) { animation-delay: 0.15s !important; }
.app-type-tile-card:nth-child(4) { animation-delay: 0.2s !important; }
.app-type-tile-card:nth-child(5) { animation-delay: 0.25s !important; }
.app-type-tile-card:nth-child(6) { animation-delay: 0.3s !important; }

/* Адаптив */
@media (max-width: 1024px) {
    .modal-app-types {
        max-width: 900px !important;
    }
    
    .app-types-tiles {
        gap: 25px !important;
    }
}

@media (max-width: 900px) {
    .modal-app-types {
        max-width: 700px !important;
        padding: 30px !important;
    }
    
    .app-types-tiles {
        grid-template-columns: repeat(2, 1fr) !important;
        grid-template-rows: repeat(3, 1fr) !important;
        gap: 20px !important;
    }
    
    .app-tile-img {
        height: 160px !important;
    }
    
    .tile-emoji {
        font-size: 75px !important;
    }
}

@media (max-width: 600px) {
    .modal-app-types {
        width: 100% !important;
        max-width: 100% !important;
        padding: 20px !important;
        border-radius: 0 !important;
    }
    
    .app-types-tiles {
        grid-template-columns: 1fr !important;
        grid-template-rows: auto !important;
        gap: 15px !important;
    }
    
    .app-tile-img {
        height: 140px !important;
    }
    
    .tile-emoji {
        font-size: 65px !important;
    }
    
    .app-types-modal-header h2 {
        font-size: 24px !important;
    }
}

/* Стили для справочника размеров */
.sizes-table table {
    width: 100%;
    border-collapse: collapse;
}

.sizes-table th {
    background: #f8f9fa;
    padding: 12px 15px;
    text-align: left;
    font-weight: 600;
    color: #495057;
    border-bottom: 2px solid #dee2e6;
}

.sizes-table td {
    padding: 12px 15px;
    border-bottom: 1px solid #e9ecef;
    vertical-align: middle;
}

.sizes-table tr:hover {
    background-color: #f8f9fa;
}

.size-value {
    background: #e3f2fd;
    padding: 4px 10px;
    border-radius: 4px;
    font-weight: 600;
    color: #1976d2;
}

.size-barcode {
    font-family: 'Courier New', monospace;
    background: #f5f5f5;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 14px;
}

/* Стили для карточек категорий */
.dict-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.dict-card {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

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

.dict-card-icon {
    font-size: 32px;
    color: #667eea;
    background: linear-gradient(135deg, #667eea15 0%, #764ba215 100%);
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.dict-card-content {
    flex: 1;
    min-width: 0;
}

.dict-card-title {
    font-weight: 600;
    font-size: 16px;
    color: #333;
    margin-bottom: 5px;
}

.dict-card-meta {
    font-size: 13px;
    color: #666;
}

.dict-card-actions {
    display: flex;
    gap: 8px;
}

/* Адаптивность для таблиц */
.table-responsive {
    overflow-x: auto;
    margin-top: 20px;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
}

.data-table {
    width: 100%;
    min-width: 800px;
}

.data-table th, .data-table td {
    padding: 12px 16px;
    border-bottom: 1px solid #e0e0e0;
}

.data-table th {
    background: #f8f9fa;
    font-weight: 600;
    color: #495057;
}

.data-table tr:hover {
    background-color: #f8f9fa;
}

/* Стили для лучших справочников */
.best-dict-tabs {
    display: flex;
    gap: 0;
    margin: 20px 0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.best-dict-tab-btn {
    flex: 1;
    padding: 20px;
    border: none;
    background: #f8f9fa;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    transition: all 0.3s;
    border-bottom: 3px solid transparent;
}

.best-dict-tab-btn.active {
    background: white;
    border-bottom-color: #4a6ee0;
    box-shadow: 0 4px 12px rgba(74, 110, 224, 0.1);
}

.best-dict-tab-btn:hover:not(.active) {
    background: #e9ecef;
}

.best-tab-icon {
    font-size: 24px;
    color: #666;
}

.best-dict-tab-btn.active .best-tab-icon {
    color: #4a6ee0;
}

.best-dict-tab-content {
    display: none;
}

.best-dict-tab-content.active {
    display: block;
}

.best-dict-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding: 15px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.best-dict-table-container {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.best-dict-table {
    width: 100%;
    border-collapse: collapse;
}

.best-dict-table th {
    background: #f8f9fa;
    padding: 15px;
    text-align: left;
    font-weight: 600;
    color: #495057;
    border-bottom: 2px solid #e9ecef;
}

.best-dict-table td {
    padding: 15px;
    border-bottom: 1px solid #e9ecef;
    vertical-align: middle;
}

.best-dict-table tr:hover {
    background-color: #f8f9fa;
}

.best-dict-table .article-group {
    font-weight: bold;
    background: linear-gradient(135deg, #4a6ee0 0%, #7239ea 100%);
    color: white;
    padding: 12px 15px;
    border-radius: 6px;
    display: inline-block;
    margin: 5px 0;
}

.edit-mode {
    background-color: #fffde7 !important;
}

.editable-cell {
    padding: 8px;
    border: 2px solid #4a6ee0;
    border-radius: 4px;
    width: 100%;
    box-sizing: border-box;
}

.select-editable {
    width: 100%;
    padding: 8px;
    border: 2px solid #4a6ee0;
    border-radius: 4px;
    background: white;
}

.action-buttons {
    display: flex;
    gap: 8px;
}

.btn-action {
    padding: 8px 12px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-edit {
    background: #ffc107;
    color: #212529;
}

.btn-edit:hover {
    background: #e0a800;
}

.btn-save {
    background: #28a745;
    color: white;
}

.btn-save:hover {
    background: #218838;
}

.btn-delete {
    background: #dc3545;
    color: white;
}

.btn-delete:hover {
    background: #c82333;
}

.btn-cancel {
    background: #6c757d;
    color: white;
}

.btn-cancel:hover {
    background: #5a6268;
}

/* Стили для техкарт V3 */
.size-row-v3 {
    display: grid;
    grid-template-columns: 120px 150px 100px 100px 100px 100px 100px 60px 60px;
    gap: 10px;
    margin-bottom: 10px;
    align-items: center;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 8px;
}

.size-row-v3 input {
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 13px;
}

.size-row-v3 input:focus {
    outline: none;
    border-color: #667eea;
}

.techcard-view-container {
    padding: 20px;
}

.techcard-view-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #e0e0e0;
}

/* Адаптивность для мобильных устройств */
@media (max-width: 768px) {
    .size-row-v3 {
        grid-template-columns: 1fr;
        gap: 8px;
    }
    
    .size-row-v3 input {
        width: 100%;
    }
}


/* ============================================================ */
/* СТИЛИ ДЛЯ ТЕХКАРТЫ V3 - УЛУЧШЕННЫЙ ДИЗАЙН */
/* ============================================================ */

/* Модальное окно увеличенного размера */
.modal-xl {
    max-width: 95%;
    width: 1400px;
    max-height: 90vh;
    overflow-y: auto;
}

/* Заголовок техкарты */
.tc-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
    border-bottom: 2px solid #e0e0e0;
    margin-bottom: 25px;
}

.tc-header-left h2 {
    margin: 0;
    font-size: 24px;
    color: #2c3e50;
    display: flex;
    align-items: center;
    gap: 10px;
}

.tc-number {
    display: inline-block;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    margin-left: 10px;
}

/* Переключатель статуса */
.status-toggle {
    display: flex;
    align-items: center;
    cursor: pointer;
    user-select: none;
}

.status-toggle input[type="checkbox"] {
    display: none;
}

.toggle-label {
    display: flex;
    align-items: center;
    background: #e0e0e0;
    border-radius: 25px;
    padding: 5px;
    position: relative;
    transition: all 0.3s ease;
}

.toggle-label span {
    padding: 8px 20px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 13px;
    transition: all 0.3s ease;
    z-index: 1;
}

.status-draft {
    color: #666;
}

.status-active {
    color: #999;
}

.status-toggle input[type="checkbox"]:checked ~ .toggle-label {
    background: #4caf50;
}

.status-toggle input[type="checkbox"]:checked ~ .toggle-label .status-draft {
    color: #999;
}

.status-toggle input[type="checkbox"]:checked ~ .toggle-label .status-active {
    color: white;
    background: rgba(255, 255, 255, 0.2);
}

.status-toggle input[type="checkbox"]:not(:checked) ~ .toggle-label .status-draft {
    color: white;
    background: rgba(0, 0, 0, 0.1);
}

/* Блоки */
.tc-block {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    margin-bottom: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.tc-block-header {
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    padding: 15px 20px;
    border-bottom: 1px solid #e0e0e0;
    border-radius: 10px 10px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.tc-block-header h3 {
    margin: 0;
    font-size: 18px;
    color: #2c3e50;
    display: flex;
    align-items: center;
    gap: 10px;
}

.tc-block-content {
    padding: 20px;
}

/* Строка с колонками */
.tc-row {
    display: flex;
    gap: 20px;
}

.tc-col-photo {
    flex: 0 0 300px;
}

.tc-col-data {
    flex: 1;
}

/* Фото товара */
.tc-photo-wrapper {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.tc-photo-placeholder {
    width: 280px;
    height: 280px;
    border: 2px dashed #ccc;
    border-radius: 10px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background: #f9f9f9;
    transition: all 0.3s ease;
}

.tc-photo-placeholder:hover {
    border-color: #667eea;
    background: #f5f7ff;
}

.tc-photo-placeholder i {
    font-size: 64px;
    color: #ccc;
    margin-bottom: 10px;
}

.tc-photo-placeholder p {
    color: #999;
    margin: 0;
    font-size: 14px;
}

.tc-photo-placeholder img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
}

.tc-photo-name {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.tc-photo-name label {
    font-weight: 600;
    color: #333;
    font-size: 14px;
}

/* Сетка полей */
.tc-grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

/* Таблица размеров */
.tc-table-wrapper {
    overflow-x: auto;
}

.tc-sizes-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.tc-sizes-table thead {
    background: #f5f5f5;
}

.tc-sizes-table th {
    padding: 12px 8px;
    text-align: left;
    font-weight: 600;
    border-bottom: 2px solid #ddd;
    white-space: nowrap;
}

.tc-sizes-table td {
    padding: 10px 8px;
    border-bottom: 1px solid #eee;
}

.tc-sizes-table tbody tr:hover {
    background: #f9f9f9;
}

.tc-input-sm {
    width: 100%;
    padding: 6px 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 13px;
    transition: border-color 0.3s ease;
}

.tc-input-sm:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 2px rgba(102, 126, 234, 0.1);
}

.tc-input-sm:disabled,
.tc-input-sm:read-only {
    background: #f9f9f9;
    cursor: not-allowed;
}

.tc-size-number {
    font-weight: 600;
    color: #666;
}

.tc-actions {
    text-align: center;
}

/* Сетка услуг */
.tc-services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
}

@media (max-width: 1200px) {
    .tc-services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .tc-services-grid {
        grid-template-columns: 1fr;
    }
}

/* Секция услуги */
.tc-service-section {
    background: #f9f9f9;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 15px;
    transition: all 0.3s ease;
}

.tc-service-section:hover {
    border-color: #667eea;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.1);
}

.tc-service-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid #ddd;
    font-weight: 600;
    color: #333;
    font-size: 14px;
}

.tc-service-header i {
    color: #667eea;
    font-size: 16px;
}

.tc-service-fields {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Чекбоксы */
.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 13px;
    color: #555;
    user-select: none;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.checkbox-label:hover {
    color: #333;
}

/* Форм-группа */
.form-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.form-group label {
    font-size: 13px;
    font-weight: 500;
    color: #555;
}

.form-control-sm {
    padding: 6px 10px;
    font-size: 13px;
    border: 1px solid #ddd;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.form-control-sm:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 2px rgba(102, 126, 234, 0.1);
}

/* Обязательное поле */
.required {
    color: #e74c3c;
    font-weight: bold;
}

/* Кнопки */
.btn-xs {
    padding: 4px 8px;
    font-size: 12px;
}

.btn-danger {
    background: #e74c3c;
    color: white;
    border: none;
}

.btn-danger:hover {
    background: #c0392b;
}

/* Футер модального окна */
.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding-top: 20px;
    border-top: 1px solid #e0e0e0;
    margin-top: 20px;
}

/* Адаптивность */
@media (max-width: 768px) {
    .modal-xl {
        width: 95%;
        max-width: 95%;
    }

    .tc-row {
        flex-direction: column;
    }

    .tc-col-photo {
        flex: 1;
    }

    .tc-grid-2 {
        grid-template-columns: 1fr;
    }

    .tc-photo-placeholder {
        width: 100%;
        height: 250px;
    }
}

/* Анимация загрузки */
.loading {
    text-align: center;
    padding: 40px;
    color: #999;
}

.loading i {
    font-size: 32px;
    margin-bottom: 10px;
}

/* Пустое состояние */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #999;
}

.empty-state i {
    font-size: 64px;
    color: #ddd;
    margin-bottom: 20px;
}

.empty-state h3 {
    color: #666;
    margin-bottom: 20px;
}

/* Карточки техкарт */
.tech-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
}

.techcard-card {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.techcard-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    border-color: #667eea;
}

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

.techcard-header h4 {
    margin: 0 0 5px 0;
    color: #2c3e50;
    font-size: 16px;
}

.techcard-product-name {
    margin: 0;
    color: #666;
    font-size: 14px;
}

.techcard-body {
    margin-bottom: 15px;
}

.techcard-body p {
    margin: 8px 0;
    font-size: 13px;
    color: #555;
}

.techcard-date {
    display: flex;
    align-items: center;
    gap: 5px;
    color: #999;
    font-size: 12px;
    margin-top: 10px;
}

.techcard-footer {
    border-top: 1px solid #eee;
    padding-top: 15px;
}

/* Бейджи статусов */
.status-badge {
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.status-completed {
    background: #d4edda;
    color: #155724;
}

.status-draft {
    background: #fff3cd;
    color: #856404;
}

.status-pending {
    background: #cce5ff;
    color: #004085;
}

/* Скролл для больших таблиц */
.tc-table-wrapper::-webkit-scrollbar {
    height: 8px;
}

.tc-table-wrapper::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.tc-table-wrapper::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}

.tc-table-wrapper::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* ============================================================ */
/* ДОПОЛНИТЕЛЬНЫЕ СТИЛИ ДЛЯ МАРКИРОВКИ - ДОБАВИТЬ В КОНЕЦ */
/* ============================================================ */

/* Маркировка - чекбоксы в ряд */
.tc-marking-fields {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
}

.checkbox-inline {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    font-size: 13px;
    color: #555;
    user-select: none;
    white-space: nowrap;
}

.checkbox-inline input[type="checkbox"] {
    width: 16px;
    height: 16px;
    cursor: pointer;
}

.checkbox-inline:hover {
    color: #333;
}

.form-group-inline {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.inline-input {
    display: inline-block !important;
    width: 80px !important;
    margin: 0 !important;
}

/* Адаптация для маленьких экранов */
@media (max-width: 768px) {
    .tc-marking-fields {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* Основной контейнер модального окна */
.modal-xl {
    max-width: 1400px;
    width: 95%;
    max-height: 95vh;
    overflow-y: auto;
}

/* Header технической карты */
.tc-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 30px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 8px 8px 0 0;
    margin: -20px -30px 20px -30px;
}

.tc-header-left h2 {
    margin: 0;
    font-size: 24px;
    font-weight: 600;
}

.tc-number {
    display: inline-block;
    margin-left: 15px;
    padding: 5px 15px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
}

.status-toggle {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
}

.status-toggle input[type="checkbox"] {
    width: 50px;
    height: 26px;
    appearance: none;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 13px;
    position: relative;
    cursor: pointer;
    transition: all 0.3s;
}

.status-toggle input[type="checkbox"]:before {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: white;
    top: 3px;
    left: 3px;
    transition: all 0.3s;
}

.status-toggle input[type="checkbox"]:checked {
    background: #4CAF50;
}

.status-toggle input[type="checkbox"]:checked:before {
    left: 27px;
}

.toggle-label {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 14px;
}

.status-draft {
    opacity: 1;
}

.status-active {
    opacity: 0.5;
}

.status-toggle input[type="checkbox"]:checked ~ .toggle-label .status-draft {
    opacity: 0.5;
}

.status-toggle input[type="checkbox"]:checked ~ .toggle-label .status-active {
    opacity: 1;
}

/* Блоки */
.tc-block {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    margin-bottom: 20px;
    overflow: hidden;
}

.tc-block-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background: #f8f9fa;
    border-bottom: 2px solid #e0e0e0;
}

.tc-block-header h3 {
    margin: 0;
    font-size: 18px;
    color: #333;
    display: flex;
    align-items: center;
    gap: 10px;
}

.tc-block-header h3 i {
    color: #667eea;
}

.tc-block-content {
    padding: 20px;
}

/* Блок 1: Основная информация */
.tc-row {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 30px;
}

.tc-col-photo {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.tc-photo-wrapper {
    width: 100%;
    aspect-ratio: 1;
    border: 2px dashed #ddd;
    border-radius: 8px;
    overflow: hidden;
}

.tc-photo-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: #f8f9fa;
    color: #999;
}

.tc-photo-placeholder i {
    font-size: 48px;
    margin-bottom: 10px;
}

.tc-photo-placeholder img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.tc-grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

/* Таблица размеров */
.tc-table-wrapper {
    overflow-x: auto;
}

.tc-sizes-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

.tc-sizes-table th {
    background: #f8f9fa;
    padding: 12px 8px;
    text-align: left;
    font-weight: 600;
    border: 1px solid #dee2e6;
    white-space: nowrap;
}

.tc-sizes-table td {
    padding: 8px;
    border: 1px solid #dee2e6;
}

.tc-size-row {
    transition: background 0.2s;
}

.tc-size-row:hover {
    background: #f8f9fa;
}

.tc-size-number {
    text-align: center;
    font-weight: 600;
    color: #666;
}

.tc-input-sm {
    width: 100%;
    padding: 6px 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 13px;
}

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

.tc-actions {
    text-align: center;
}

.required {
    color: red;
    margin-left: 3px;
}

/* Сервисы и услуги */
.tc-services-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.tc-service-section {
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 15px;
    background: #f8f9fa;
}

.tc-service-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
    font-weight: 600;
    color: #333;
    font-size: 15px;
}

.tc-service-header i {
    color: #667eea;
    font-size: 18px;
}

.tc-service-fields {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

/* Маркировка */
.tc-marking-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.tc-marking-section {
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 15px;
    background: #f8f9fa;
}

.tc-marking-title {
    margin: 0 0 15px 0;
    font-size: 16px;
    font-weight: 600;
    color: #333;
    padding-bottom: 10px;
    border-bottom: 2px solid #667eea;
}

.tc-marking-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Дополнительные услуги */
.tc-additional-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.tc-additional-item {
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 15px;
    background: white;
}

.tc-additional-expandable {
    background: #f8f9fa;
}

.tc-checkbox-label-main {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 15px;
    font-weight: 600;
    color: #333;
    cursor: pointer;
    margin-bottom: 10px;
}

.tc-checkbox-label-main input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

.tc-checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    cursor: pointer;
    margin-bottom: 8px;
}

.tc-checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.tc-expandable-content {
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid #dee2e6;
}

.tc-expandable-fields {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-top: 10px;
}

.tc-additional-details {
    margin-top: 10px;
}

/* Form elements */
.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
    color: #555;
    font-size: 13px;
}

.form-control {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.3s;
}

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

.form-control-sm {
    padding: 6px 10px;
    font-size: 13px;
}

/* Footer */
.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 20px 30px;
    border-top: 1px solid #e0e0e0;
    margin: 20px -30px -20px -30px;
    background: #f8f9fa;
}

/* Responsive */
@media (max-width: 1200px) {
    .tc-row {
        grid-template-columns: 1fr;
    }
    
    .tc-services-grid,
    .tc-marking-grid,
    .tc-additional-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .modal-xl {
        width: 100%;
        max-height: 100vh;
        border-radius: 0;
    }
    
    .tc-grid-2 {
        grid-template-columns: 1fr;
    }
}

/* Улучшенные стили для Kanban доски */
.kanban-board {
    padding: 10px;
}

.kanban-column {
    min-height: 400px;
    transition: all 0.3s;
}

.kanban-card:hover {
    transform: translateY(-3px) !important;
    box-shadow: 0 6px 16px rgba(0,0,0,0.12) !important;
}

@media (max-width: 768px) {
    .kanban-board {
        grid-template-columns: 1fr !important;
    }
}

/* Анимация пульсации для блока ожидания */
@keyframes pulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(111, 66, 193, 0.4);
    }
    50% {
        box-shadow: 0 0 0 10px rgba(111, 66, 193, 0);
    }
}

/* Стили для статусов ожидания */
.status-controller-review {
    background: rgba(111, 66, 193, 0.1);
    color: #6f42c1;
}

.status-manager-review {
    background: rgba(139, 92, 246, 0.1);
    color: #8b5cf6;
}

.status-client-response {
    background: rgba(167, 139, 250, 0.1);
    color: #a78bfa;
}

/* Kanban колонки для подстатусов */
.kanban-column[data-subtype="controller_review"] {
    border-top: 3px solid #6f42c1;
}

.kanban-column[data-subtype="manager_review"] {
    border-top: 3px solid #8b5cf6;
}

.kanban-column[data-subtype="client_response"] {
    border-top: 3px solid #a78bfa;
}

/* Анимация пульсации границы для заявок, требующих ответа */
@keyframes pulse-border {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(255, 152, 0, 0.4);
    }
    50% {
        box-shadow: 0 0 0 8px rgba(255, 152, 0, 0);
    }
}

/* Анимация для блоков внимания */
@keyframes pulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(111, 66, 193, 0.4);
    }
    50% {
        box-shadow: 0 0 0 10px rgba(111, 66, 193, 0);
    }
}

/* ===== ВКЛАДКИ В МОДАЛЬНОМ ОКНЕ ПРОФИЛЯ ===== */
.profile-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 25px;
    border-bottom: 2px solid #e0e0e0;
    padding-bottom: 0;
}

.profile-tab-btn {
    flex: 1;
    padding: 12px 20px;
    border: none;
    background: transparent;
    color: #666;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border-bottom: 3px solid transparent;
    position: relative;
    bottom: -2px;
}

.profile-tab-btn:hover {
    color: #2196F3;
    background: rgba(33, 150, 243, 0.05);
}

.profile-tab-btn.active {
    color: #2196F3;
    border-bottom-color: #2196F3;
    background: rgba(33, 150, 243, 0.08);
}

.profile-tab-btn i {
    margin-right: 8px;
}

.profile-tab-content {
    display: none;
    animation: fadeIn 0.3s ease;
}

.profile-tab-content.active {
    display: block;
}

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

/* Стили для информационного блока */
.info-box {
    background: #e3f2fd;
    border-left: 4px solid #2196F3;
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 4px;
}

.info-box p {
    margin: 0;
    color: #1565c0;
}

.info-box i {
    margin-right: 8px;
}

/* Обязательные поля */
.required {
    color: #f44336;
    margin-left: 3px;
}

/* ===== УЛУЧШЕННЫЕ СТИЛИ КНОПОК В ПРОФИЛЕ ===== */
.btn-profile-save,
.btn-profile-cancel {
    min-height: 50px !important;
    font-size: 16px !important;
    font-weight: 600 !important;
    padding: 14px 30px !important;
    border-radius: 8px !important;
    transition: all 0.3s ease !important;
    text-transform: none !important;
    letter-spacing: 0.3px !important;
}

.btn-profile-save {
    background: linear-gradient(135deg, #2196F3 0%, #1976D2 100%) !important;
    box-shadow: 0 4px 12px rgba(33, 150, 243, 0.3) !important;
}

.btn-profile-save:hover {
    background: linear-gradient(135deg, #1976D2 0%, #1565C0 100%) !important;
    box-shadow: 0 6px 16px rgba(33, 150, 243, 0.4) !important;
    transform: translateY(-2px) !important;
}

.btn-profile-save:active {
    transform: translateY(0) !important;
}

.btn-profile-cancel {
    background: linear-gradient(135deg, #757575 0%, #616161 100%) !important;
    box-shadow: 0 4px 12px rgba(117, 117, 117, 0.3) !important;
}

.btn-profile-cancel:hover {
    background: linear-gradient(135deg, #616161 0%, #424242 100%) !important;
    box-shadow: 0 6px 16px rgba(117, 117, 117, 0.4) !important;
    transform: translateY(-2px) !important;
}

/* Улучшенные стили вкладок профиля */
.profile-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 25px;
    border-bottom: 2px solid #e0e0e0;
    padding-bottom: 0;
}

.profile-tab-btn {
    flex: 1;
    padding: 14px 20px;
    border: none;
    background: transparent;
    color: #666;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border-bottom: 3px solid transparent;
    position: relative;
    bottom: -2px;
}

.profile-tab-btn:hover {
    color: #2196F3;
    background: rgba(33, 150, 243, 0.05);
}

.profile-tab-btn.active {
    color: #2196F3;
    border-bottom-color: #2196F3;
    background: rgba(33, 150, 243, 0.08);
}

.profile-tab-btn i {
    margin-right: 8px;
    font-size: 16px;
}

.profile-tab-content {
    display: none;
    animation: fadeInProfile 0.3s ease;
}

.profile-tab-content.active {
    display: block;
}

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

/* Стили для информационного блока */
.info-box {
    background: #e3f2fd;
    border-left: 4px solid #2196F3;
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 4px;
}

.info-box p {
    margin: 0;
    color: #1565c0;
}

.info-box i {
    margin-right: 8px;
}

/* Обязательные поля */
.required {
    color: #f44336;
    margin-left: 3px;
    font-weight: bold;
}

/* Readonly поля */
.readonly-field {
    background-color: #f5f5f5 !important;
    cursor: not-allowed !important;
    color: #666 !important;
}

/* Отступы в форме профиля */
.profile-form {
    margin-top: 20px;
}

.form-actions {
    display: flex;
    gap: 15px;
    margin-top: 30px;
}

.form-actions .btn {
    flex: 1;
}

/* Профильная шапка */
.profile-header {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 20px;
    background: linear-gradient(135deg, #f5f5f5 0%, #e0e0e0 100%);
    border-radius: 8px;
    margin-bottom: 25px;
}

.profile-avatar {
    font-size: 60px;
    color: #2196F3;
}

.profile-info h3 {
    margin: 0 0 5px 0;
    font-size: 22px;
    color: #333;
}

.user-role-badge {
    display: inline-block;
    padding: 4px 12px;
    background: #2196F3;
    color: white;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}


/* ===== СТИЛИ ДЛЯ НОВОГО МОДАЛЬНОГО ОКНА ПРОФИЛЯ ===== */
.profile-form-new {
    margin: 0;
}

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

.profile-section-title {
    font-size: 18px;
    font-weight: 700;
    color: #333;
    margin: 0 0 20px 0;
    padding-bottom: 10px;
    border-bottom: 2px solid #e0e0e0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.profile-section-title i {
    color: #2196F3;
    font-size: 20px;
}

/* Улучшенные кнопки */
.btn-profile-save {
    min-height: 50px !important;
    font-size: 16px !important;
    font-weight: 600 !important;
    padding: 14px 40px !important;
    border-radius: 8px !important;
    transition: all 0.3s ease !important;
}

.btn-primary.btn-profile-save {
    background: linear-gradient(135deg, #2196F3 0%, #1976D2 100%) !important;
    box-shadow: 0 4px 12px rgba(33, 150, 243, 0.3) !important;
}

.btn-primary.btn-profile-save:hover {
    background: linear-gradient(135deg, #1976D2 0%, #1565C0 100%) !important;
    box-shadow: 0 6px 16px rgba(33, 150, 243, 0.4) !important;
    transform: translateY(-2px) !important;
}

.btn-success.btn-profile-save {
    background: linear-gradient(135deg, #4CAF50 0%, #388E3C 100%) !important;
    box-shadow: 0 4px 12px rgba(76, 175, 80, 0.3) !important;
}

.btn-success.btn-profile-save:hover {
    background: linear-gradient(135deg, #388E3C 0%, #2E7D32 100%) !important;
    box-shadow: 0 6px 16px rgba(76, 175, 80, 0.4) !important;
    transform: translateY(-2px) !important;
}

.btn-profile-save:active {
    transform: translateY(0) !important;
}

/* Информационный блок */
.info-box {
    background: #e3f2fd;
    border-left: 4px solid #2196F3;
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 4px;
}

.info-box p {
    margin: 0;
    color: #1565c0;
    font-size: 14px;
}

.info-box i {
    margin-right: 8px;
}

/* Обязательные поля */
.required {
    color: #f44336;
    margin-left: 3px;
    font-weight: bold;
}

/* Readonly поля */
.readonly-field {
    background-color: #f5f5f5 !important;
    cursor: not-allowed !important;
    color: #666 !important;
}


/* ===== РАЗМЫТИЕ ФОНА МОДАЛЬНЫХ ОКОН ===== */
.modal-blur {
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    background: rgba(0, 0, 0, 0.6) !important;
}

/* ===== СТИЛИ ДЛЯ ФОРМЫ ВХОДА ===== */
.modal-auth {
    max-width: 450px !important;
    padding: 0 !important;
    border-radius: 16px !important;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3) !important;
    animation: modalSlideIn 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

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

.auth-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 40px 30px 30px;
    text-align: center;
    position: relative;
}

.auth-icon {
    width: 80px;
    height: 80px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

.auth-icon i {
    font-size: 36px;
    color: white;
}

.auth-header h2 {
    margin: 0 0 10px 0;
    font-size: 28px;
    font-weight: 700;
    color: white;
}

.auth-subtitle {
    margin: 0;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 400;
}

.auth-form {
    padding: 40px 30px 30px;
    background: white;
}

.auth-form .form-group {
    margin-bottom: 20px;
}

.auth-form .form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #333;
    font-size: 14px;
}

.auth-form .form-group label i {
    margin-right: 8px;
    color: #667eea;
}

.auth-form input[type="email"],
.auth-form input[type="password"],
.auth-form input[type="text"] {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.3s ease;
}

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

.form-group-checkbox {
    margin: 20px 0;
}

.checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    user-select: none;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin-right: 10px;
    cursor: pointer;
}

.checkbox-label span {
    color: #666;
    font-size: 14px;
}

.btn-auth {
    width: 100%;
    padding: 16px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 8px;
    margin-top: 10px;
    transition: all 0.3s ease;
}

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

.btn-auth:active {
    transform: translateY(0);
}

.auth-links {
    margin-top: 25px;
    text-align: center;
    display: flex;
    justify-content: space-between;
    gap: 15px;
}

.auth-links a {
    color: #667eea;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 5px;
}

.auth-links a:hover {
    color: #764ba2;
    transform: translateY(-1px);
}

.auth-links a i {
    font-size: 13px;
}

/* Закрыть кнопка */
.modal-auth .close {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 32px;
    color: white;
    opacity: 0.9;
    z-index: 10;
}

.modal-auth .close:hover {
    opacity: 1;
    transform: rotate(90deg);
}

/* Расширенная таблица справочника */
.best-dict-table th,
.best-dict-table td {
    font-size: 13px;
    padding: 10px 8px;
}

.best-dict-table textarea.editable-cell {
    width: 100%;
    min-height: 50px;
    font-family: inherit;
}

.article-group {
    font-weight: 700;
    color: #2196F3;
    font-size: 14px;
}

.status-badge.status-draft {
    background: #ff9800;
}

.status-badge.status-completed {
    background: #4caf50;
}


/* Секция формы */
.form-section {
    margin-bottom: 30px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #2196F3;
}

.form-section h3 {
    margin: 0 0 20px 0;
    color: #333;
    font-size: 16px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.form-section h3 i {
    color: #2196F3;
}

/* Отключенная секция (для не-админов) */
.disabled-section {
    opacity: 0.6;
    background: #f5f5f5;
    border-left-color: #999;
}

.disabled-section h3 i {
    color: #999;
}

/* Бейдж "только для админа" */
.admin-only-badge {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    margin-left: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Подсказки под полями */
.field-hint {
    display: block;
    margin-top: 5px;
    font-size: 12px;
    color: #666;
    font-style: italic;
}

/* Индикатор обязательного поля */
.required {
    color: #e74c3c;
    font-weight: bold;
    margin-left: 2px;
}

/* Улучшенные кнопки */
.btn-large {
    padding: 12px 30px;
    font-size: 15px;
    font-weight: 600;
}

.form-actions {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 2px solid #e0e0e0;
}


/* Кликабельный статус */
.status-badge[onclick] {
    cursor: pointer;
    transition: all 0.3s;
}

.status-badge[onclick]:hover {
    opacity: 0.8;
    transform: scale(1.05);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.status-badge.status-completed[onclick]:hover {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
}

.status-badge.status-cancelled[onclick]:hover {
    background: linear-gradient(135deg, #dc3545 0%, #fd7e14 100%);
}

/* ============================================
   СТИЛИ ДЛЯ КАРТОЧЕК ТОВАРОВ
   ============================================ */

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
    padding: 20px 0;
}

.product-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    border: 2px solid transparent;
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    border-color: #2196F3;
}

.product-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.product-article {
    font-weight: 600;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.product-delete-btn {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.product-delete-btn:hover {
    background: rgba(231, 76, 60, 0.9);
    transform: rotate(90deg);
}

.product-card-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
    background: #f8f9fa;
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.product-card:hover .product-card-image img {
    transform: scale(1.05);
}

.product-card-body {
    padding: 16px;
}

.product-name {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin: 0 0 12px 0;
    line-height: 1.4;
    min-height: 44px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-info-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    font-size: 13px;
    color: #666;
}

.product-info-row i {
    color: #2196F3;
    width: 16px;
    text-align: center;
}

.product-card-footer {
    padding: 12px 16px;
    background: #f8f9fa;
    border-top: 1px solid #e0e0e0;
}

.product-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.product-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

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

.badge-country {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: white;
}

.badge-season {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    color: white;
}

/* Адаптивность */
@media (max-width: 1200px) {
    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
        gap: 20px;
    }
}

@media (max-width: 768px) {
    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 16px;
    }
    
    .product-card-image {
        height: 160px;
    }
}

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

/* Пустое состояние */
.empty-state {
    animation: fadeIn 0.5s ease-in;
}

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

/* ============================================
   СТИЛИ ДЛЯ ГРУПП РАЗМЕРОВ
   ============================================ */

.sizes-groups-container {
    display: flex;
    flex-direction: column;
    gap: 24px;
    padding: 20px 0;
}

.size-group-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    border: 1px solid #e0e0e0;
    transition: all 0.3s ease;
}

.size-group-card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
    border-color: #2196F3;
}

/* Заголовок группы */
.size-group-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.size-group-info {
    flex: 1;
}

.size-group-article {
    margin: 0 0 5px 0;
    font-size: 18px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.size-group-product {
    margin: 0;
    font-size: 13px;
    opacity: 0.9;
}

.size-group-meta {
    display: flex;
    gap: 10px;
    align-items: center;
}

.size-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge-manual {
    background: rgba(255, 255, 255, 0.25);
    color: white;
}

.badge-product {
    background: rgba(76, 175, 80, 0.9);
    color: white;
}

.size-count-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.25);
    color: white;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

/* Список размеров */
.sizes-list {
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.size-item {
    background: #f8f9fa;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.size-item:hover {
    border-color: #2196F3;
    background: #f0f7ff;
}

.size-item.editing {
    border-color: #667eea;
    background: #f5f3ff;
}

/* Режим просмотра */
.size-item-view {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
}

.size-info {
    display: flex;
    gap: 30px;
    align-items: center;
}

.size-value {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 15px;
}

.size-value i {
    color: #667eea;
}

.size-value strong {
    font-size: 16px;
    color: #333;
}

.barcode-value {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: #666;
}

.barcode-value i {
    color: #999;
}

.barcode-value code {
    background: white;
    padding: 4px 10px;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 13px;
    border: 1px solid #ddd;
}

.size-actions {
    display: flex;
    gap: 8px;
}

/* Режим редактирования */
.size-item-edit {
    padding: 16px;
}

.size-edit-fields {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 16px;
    margin-bottom: 12px;
}

.size-edit-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.size-edit-field label {
    font-size: 12px;
    font-weight: 600;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.size-input,
.barcode-input {
    padding: 10px 12px;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    font-size: 14px;
    transition: all 0.3s;
}

.size-input:focus,
.barcode-input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.size-edit-actions {
    display: flex;
    gap: 8px;
    justify-content: flex-end;
}

/* Кнопки */
.btn-icon {
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
    font-size: 14px;
}

.btn-icon:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.btn-edit {
    background: #2196F3;
    color: white;
}

.btn-edit:hover {
    background: #1976D2;
}

.btn-delete {
    background: #f44336;
    color: white;
}

.btn-delete:hover {
    background: #d32f2f;
}

.btn-save {
    background: #4CAF50;
    color: white;
}

.btn-save:hover {
    background: #388E3C;
}

.btn-cancel {
    background: #9E9E9E;
    color: white;
}

.btn-cancel:hover {
    background: #757575;
}

/* Футер группы */
.size-group-footer {
    padding: 16px 24px;
    background: #f8f9fa;
    border-top: 1px solid #e0e0e0;
}

.btn-add-size-to-article {
    width: 100%;
    padding: 12px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.3s;
}

.btn-add-size-to-article:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

/* Адаптивность */
@media (max-width: 768px) {
    .size-group-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .size-group-meta {
        width: 100%;
        flex-wrap: wrap;
    }
    
    .size-item-view {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .size-info {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
        width: 100%;
    }
    
    .size-actions {
        width: 100%;
        justify-content: flex-end;
    }
    
    .size-edit-fields {
        grid-template-columns: 1fr;
    }
}


/* ============================================
   СОВРЕМЕННЫЕ БЛОКИ РАЗМЕРОВ (ГОРИЗОНТАЛЬНО)
   ============================================ */

.sizes-grid-modern {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
    gap: 24px;
    padding: 20px 0;
}

.size-block-modern {
    background: white;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.size-block-modern:hover {
    border-color: #667eea;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

/* Заголовок блока */
.size-block-header-modern {
    padding: 16px 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-bottom: 2px solid #5568d3;
}

.size-block-title {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.article-label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.25);
    border-radius: 6px;
    color: white;
    font-size: 14px;
    font-weight: 600;
}

.article-label i {
    font-size: 16px;
}

.product-name-label {
    color: white;
    font-size: 14px;
    opacity: 0.95;
}

/* Тело блока с таблицей */
.size-block-body-modern {
    padding: 16px;
}

.sizes-table-inline {
    width: 100%;
    border-collapse: collapse;
}

.sizes-table-inline thead th {
    background: #f8f9fa;
    padding: 10px 12px;
    text-align: left;
    font-size: 12px;
    font-weight: 600;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid #e0e0e0;
}

.sizes-table-inline tbody tr {
    border-bottom: 1px solid #f0f0f0;
    transition: all 0.2s;
}

.sizes-table-inline tbody tr:hover {
    background: #f8f9fa;
}

.sizes-table-inline tbody tr.editing-row {
    background: #f5f3ff;
}

.sizes-table-inline tbody td {
    padding: 12px;
    vertical-align: middle;
}

/* Отображение размера */
.size-display {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 600;
    color: #333;
}

.size-display i {
    color: #667eea;
}

.barcode-display {
    display: inline-block;
    padding: 6px 12px;
    background: #f8f9fa;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    font-family: 'Courier New', monospace;
    font-size: 13px;
    color: #333;
}

/* Inline редактирование */
.inline-edit-input {
    width: 100%;
    padding: 8px 12px;
    border: 2px solid #667eea;
    border-radius: 6px;
    font-size: 14px;
    transition: all 0.3s;
}

.inline-edit-input:focus {
    outline: none;
    border-color: #5568d3;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

/* Inline кнопки действий */
.inline-actions {
    display: flex;
    gap: 6px;
    justify-content: flex-end;
}

.btn-inline {
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    font-size: 13px;
}

.btn-inline:hover {
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.btn-inline.btn-edit {
    background: #2196F3;
    color: white;
}

.btn-inline.btn-edit:hover {
    background: #1976D2;
}

.btn-inline.btn-delete {
    background: #f44336;
    color: white;
}

.btn-inline.btn-delete:hover {
    background: #d32f2f;
}

.btn-inline.btn-save {
    background: #4CAF50;
    color: white;
}

.btn-inline.btn-save:hover {
    background: #388E3C;
}

.btn-inline.btn-cancel {
    background: #9E9E9E;
    color: white;
}

.btn-inline.btn-cancel:hover {
    background: #757575;
}

/* Форма добавления в блоке */
.add-size-row-inline {
    background: #fafbfc;
}

.add-size-form-inline {
    padding: 12px;
}

.add-size-source {
    margin-bottom: 12px;
}

.source-select {
    width: 100%;
    padding: 10px 12px;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s;
}

.source-select:focus {
    outline: none;
    border-color: #667eea;
}

.add-fields-container {
    margin-top: 12px;
}

.source-fields {
    display: flex;
    gap: 10px;
    align-items: center;
}

.inline-input {
    flex: 1;
    padding: 10px 12px;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    font-size: 14px;
    transition: all 0.3s;
}

.inline-input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.btn-add-inline {
    padding: 10px 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.3s;
    white-space: nowrap;
}

.btn-add-inline:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.product-select {
    width: 100%;
    padding: 10px 12px;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    font-size: 14px;
    margin-bottom: 12px;
}

.available-sizes {
    padding: 12px;
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
}

.available-sizes p {
    margin: 0 0 10px 0;
    font-size: 13px;
    color: #666;
}

.sizes-checkboxes {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 12px;
}

.size-checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px;
    background: #f8f9fa;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s;
}

.size-checkbox-label:hover {
    background: #e3f2fd;
}

.size-checkbox-label input[type="checkbox"] {
    cursor: pointer;
}

.btn-add-selected {
    width: 100%;
    padding: 10px;
    background: #4CAF50;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: all 0.3s;
}

.btn-add-selected:hover {
    background: #388E3C;
    transform: translateY(-2px);
}

.loading-inline {
    padding: 20px;
    text-align: center;
    color: #666;
}

.no-sizes {
    padding: 12px;
    text-align: center;
    color: #999;
    font-style: italic;
}

/* Адаптивность */
@media (max-width: 1200px) {
    .sizes-grid-modern {
        grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    }
}

@media (max-width: 768px) {
    .sizes-grid-modern {
        grid-template-columns: 1fr;
    }
    
    .size-block-title {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .source-fields {
        flex-direction: column;
    }
    
    .btn-add-inline {
        width: 100%;
        justify-content: center;
    }
}


/* ============================================
   СТИЛИ ДЛЯ ТАБЛИЦ РАЗМЕРОВ
   ============================================ */

.sizes-table-wrapper {
    display: flex;
    flex-direction: column;
    gap: 30px;
    padding: 20px 0;
}

/* Блок группы размеров */
.size-group-block {
    background: white;
    border: 3px solid #667eea;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    border-style: dashed;
}

/* Заголовок группы */
.size-group-title-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-bottom: 3px solid #5568d3;
    flex-wrap: wrap;
    gap: 12px;
}

.title-left {
    display: flex;
    align-items: center;
    gap: 10px;
    color: white;
    font-size: 16px;
}

.title-left i {
    font-size: 20px;
}

.title-left strong {
    font-weight: 700;
}

.article-value {
    padding: 6px 14px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 6px;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.title-right {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.product-name-info {
    display: flex;
    align-items: center;
    gap: 6px;
    color: white;
    font-size: 14px;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 6px;
}

.source-badge,
.count-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.source-badge {
    background: rgba(255, 255, 255, 0.95);
    color: #667eea;
}

.badge-manual {
    background: rgba(255, 193, 7, 0.95);
    color: #333;
}

.badge-product {
    background: rgba(76, 175, 80, 0.95);
    color: white;
}

.count-badge {
    background: rgba(255, 255, 255, 0.3);
    color: white;
}

/* Таблица данных */
.sizes-data-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
}

.sizes-data-table thead {
    background: #f8f9fa;
    border-bottom: 2px solid #e0e0e0;
}

.sizes-data-table thead th {
    padding: 14px 16px;
    text-align: left;
    font-size: 13px;
    font-weight: 700;
    color: #333;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-right: 1px solid #e0e0e0;
}

.sizes-data-table thead th:last-child {
    border-right: none;
}

.sizes-data-table tbody tr {
    border-bottom: 1px solid #f0f0f0;
    transition: all 0.2s ease;
}

.sizes-data-table tbody tr:hover {
    background: #f8f9fa;
}

.sizes-data-table tbody tr.editing-mode {
    background: #fff3e0;
}

.sizes-data-table tbody tr.add-row {
    background: #e8f5e9;
    border-top: 2px dashed #4CAF50;
}

.sizes-data-table tbody tr.add-row:hover {
    background: #c8e6c9;
}

.sizes-data-table tbody td {
    padding: 12px 16px;
    vertical-align: middle;
    border-right: 1px solid #f0f0f0;
}

.sizes-data-table tbody td:last-child {
    border-right: none;
}

/* Номер строки */
.row-number {
    font-weight: 700;
    color: #999;
    text-align: center;
    font-size: 14px;
}

.add-row .row-number {
    color: #4CAF50;
    font-size: 20px;
}

/* Отображение размера */
.size-text {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 15px;
    font-weight: 600;
    color: #333;
}

/* Штрих-код */
.barcode-code {
    display: inline-block;
    padding: 6px 12px;
    background: #f5f5f5;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    font-family: 'Courier New', monospace;
    font-size: 13px;
    color: #333;
    letter-spacing: 1px;
}

/* Поля ввода в таблице */
.table-input {
    width: 100%;
    padding: 8px 12px;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    font-size: 14px;
    transition: all 0.3s;
}

.table-input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.add-input {
    border-color: #4CAF50;
    background: #f1f8f4;
}

.add-input:focus {
    border-color: #388E3C;
    box-shadow: 0 0 0 3px rgba(76, 175, 80, 0.1);
}

/* Кнопки в таблице */
.action-buttons {
    display: flex;
    gap: 8px;
    justify-content: center;
}

.btn-table {
    padding: 8px 12px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s;
    white-space: nowrap;
}

.btn-table:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.btn-table.btn-edit {
    background: #2196F3;
    color: white;
}

.btn-table.btn-edit:hover {
    background: #1976D2;
}

.btn-table.btn-delete {
    background: #f44336;
    color: white;
}

.btn-table.btn-delete:hover {
    background: #d32f2f;
}

.btn-table.btn-save {
    background: #4CAF50;
    color: white;
}

.btn-table.btn-save:hover {
    background: #388E3C;
}

.btn-table.btn-cancel {
    background: #9E9E9E;
    color: white;
}

.btn-table.btn-cancel:hover {
    background: #757575;
}

.btn-table.btn-add {
    background: linear-gradient(135deg, #4CAF50 0%, #66BB6A 100%);
    color: white;
    padding: 10px 16px;
}

.btn-table.btn-add:hover {
    background: linear-gradient(135deg, #388E3C 0%, #4CAF50 100%);
}

/* Адаптивность */
@media (max-width: 768px) {
    .size-group-title-bar {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .title-left,
    .title-right {
        width: 100%;
    }
    
    .sizes-data-table {
        font-size: 13px;
    }
    
    .sizes-data-table thead th,
    .sizes-data-table tbody td {
        padding: 8px;
    }
    
    .action-buttons {
        flex-direction: column;
    }
    
    .btn-table {
        width: 100%;
        justify-content: center;
    }
}

/* Пустое состояние */
.empty-state {
    animation: fadeIn 0.5s ease-in;
}

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

/* Улучшение поиска */
.search-box {
    position: relative;
    flex: 1;
    max-width: 400px;
}

.search-box i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #999;
    pointer-events: none;
}

.search-box input {
    width: 100%;
    padding: 10px 12px 10px 38px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.3s;
}

.search-box input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.search-box input::placeholder {
    color: #999;
}

/* === CLIENT DASHBOARD 3 БЛОКА === */
.client-dashboard-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 30px;
}

.dashboard-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    overflow: hidden;
    transition: all 0.3s ease;
}

.dashboard-card:hover {
    box-shadow: 0 8px 25px rgba(0,0,0,0.12);
    transform: translateY(-3px);
}

.dashboard-card .card-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 15px 20px;
    border-bottom: none;
}

.dashboard-card .card-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.dashboard-card .card-body {
    padding: 20px;
}

/* Блок 1: Заявки */
.stats-row {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 15px;
}

.stat-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    background: #f8f9fa;
    border-radius: 6px;
}

.stat-label {
    font-size: 13px;
    color: #666;
}

.stat-value {
    font-size: 18px;
    font-weight: 700;
    color: #333;
}

.stat-value.highlight {
    color: #667eea;
    font-size: 20px;
}

.pie-chart-container {
    margin-top: 15px;
    text-align: center;
}

#appTypesPieChart {
    max-width: 100%;
    height: auto;
}

/* Блок 2: Каталог */
.catalog-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

.catalog-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: #f8f9fa;
    border-radius: 8px;
    transition: all 0.3s;
}

.catalog-item:hover {
    background: #e9ecef;
    transform: translateX(3px);
}

.catalog-icon {
    width: 45px;
    height: 45px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: white;
}

.catalog-icon.all { background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); }
.catalog-icon.wb { background: linear-gradient(135deg, #CB11AB 0%, #a00d8a 100%); }
.catalog-icon.ozon { background: linear-gradient(135deg, #005BFF 0%, #0041b8 100%); }
.catalog-icon.techcards { background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%); }

.catalog-info {
    flex: 1;
}

.catalog-value {
    font-size: 22px;
    font-weight: 700;
    color: #333;
    line-height: 1;
}

.catalog-label {
    font-size: 12px;
    color: #666;
    margin-top: 3px;
}

/* Блок 3: Финансы */
.finance-stats {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.finance-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    border-radius: 8px;
    transition: all 0.3s;
}

.finance-item.total {
    background: rgba(102, 126, 234, 0.1);
    border-left: 4px solid #667eea;
}

.finance-item.unpaid {
    background: rgba(239, 68, 68, 0.1);
    border-left: 4px solid #ef4444;
}

.finance-icon {
    width: 50px;
    height: 50px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}

.finance-item.total .finance-icon {
    background: #667eea;
    color: white;
}

.finance-item.unpaid .finance-icon {
    background: #ef4444;
    color: white;
}

.finance-info {
    flex: 1;
}

.finance-label {
    font-size: 13px;
    color: #666;
    margin-bottom: 5px;
}

.finance-value {
    font-size: 24px;
    font-weight: 700;
    color: #333;
    line-height: 1;
}

.finance-count {
    font-size: 11px;
    color: #999;
    margin-top: 3px;
}

/* Адаптивность */
@media (max-width: 1200px) {
    .client-dashboard-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .catalog-stats {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .catalog-stats {
        grid-template-columns: 1fr;
    }
}


/* ==========================================
   CLIENT DASHBOARD - 3 БЛОКА
   ========================================== */

.client-dashboard-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 30px;
}

.dashboard-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    overflow: hidden;
    transition: all 0.3s ease;
    border: 1px solid #e0e0e0;
}

.dashboard-card:hover {
    box-shadow: 0 6px 20px rgba(0,0,0,0.12);
    transform: translateY(-3px);
}

.dashboard-card .card-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 12px 18px;
}

.dashboard-card .card-header h3 {
    margin: 0;
    font-size: 15px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.dashboard-card .card-body {
    padding: 18px;
}

/* Блок 1: Заявки */
.stats-row {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 12px;
}

.stat-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    background: #f8f9fa;
    border-radius: 6px;
}

.stat-label {
    font-size: 12px;
    color: #666;
    font-weight: 500;
}

.stat-value {
    font-size: 16px;
    font-weight: 700;
    color: #333;
}

.stat-value.highlight {
    color: #667eea;
    font-size: 18px;
}

.pie-chart-container {
    margin-top: 12px;
    text-align: center;
    background: #f8f9fa;
    border-radius: 8px;
    padding: 15px 10px;
}

#appTypesPieChart {
    max-width: 100%;
    height: auto;
}

/* Блок 2: Каталог */
.catalog-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.catalog-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 8px;
    transition: all 0.3s;
}

.catalog-item:hover {
    background: #e9ecef;
    transform: translateX(3px);
}

.catalog-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    color: white;
    flex-shrink: 0;
}

.catalog-icon.all { background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); }
.catalog-icon.wb { background: linear-gradient(135deg, #CB11AB 0%, #a00d8a 100%); }
.catalog-icon.ozon { background: linear-gradient(135deg, #005BFF 0%, #0041b8 100%); }
.catalog-icon.techcards { background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%); }

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

.catalog-value {
    font-size: 20px;
    font-weight: 700;
    color: #333;
    line-height: 1.2;
}

.catalog-label {
    font-size: 11px;
    color: #666;
    margin-top: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Блок 3: Финансы */
.finance-stats {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.finance-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border-radius: 8px;
    transition: all 0.3s;
}

.finance-item.total {
    background: rgba(102, 126, 234, 0.08);
    border-left: 4px solid #667eea;
}

.finance-item.unpaid {
    background: rgba(239, 68, 68, 0.08);
    border-left: 4px solid #ef4444;
}

.finance-icon {
    width: 45px;
    height: 45px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content center;
    font-size: 22px;
    flex-shrink: 0;
}

.finance-item.total .finance-icon {
    background: #667eea;
    color: white;
}

.finance-item.unpaid .finance-icon {
    background: #ef4444;
    color: white;
}

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

.finance-label {
    font-size: 12px;
    color: #666;
    margin-bottom: 4px;
    font-weight: 500;
}

.finance-value {
    font-size: 22px;
    font-weight: 700;
    color: #333;
    line-height: 1.1;
}

.finance-count {
    font-size: 11px;
    color: #999;
    margin-top: 3px;
}

/* Адаптивность */
@media (max-width: 1200px) {
    .client-dashboard-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
}

@media (max-width: 768px) {
    .catalog-stats {
        grid-template-columns: 1fr;
    }
    
    .dashboard-card .card-body {
        padding: 15px;
    }
}

/* === ADMIN DASHBOARD === */
.dashboard-header {
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    border-radius: 12px;
    padding: 20px 25px;
    margin-bottom: 25px;
}

.dashboard-header h2 {
    margin: 0 0 5px 0;
    font-size: 24px;
}

.dashboard-header p {
    margin: 0;
    font-size: 14px;
}

/* Стили для табов уже есть в вашем CSS, но добавим специфичные для админки */
.tab-content {
    animation: fadeInTab 0.3s ease;
}

@keyframes fadeInTab {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}


/* Стили для складской вкладки */
.form-control {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
}

.badge {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

#inventoryChart {
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    background: white;
}

/* Тех карты в заявках */
.techcards-selection-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 15px;
    max-height: 500px;
    overflow-y: auto;
    padding: 10px;
}

.techcard-select-item {
    display: flex;
    align-items: start;
    gap: 15px;
    padding: 15px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s;
    background: white;
}

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

.techcard-select-item.selected {
    border-color: #667eea;
    background: linear-gradient(135deg, #f0f4ff 0%, #e5edff 100%);
}

.techcard-checkbox {
    font-size: 24px;
    color: #667eea;
    flex-shrink: 0;
}

.techcard-select-item.selected .techcard-checkbox {
    color: #10b981;
}

.techcard-info {
    flex: 1;
}

.techcard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
    gap: 10px;
}

.techcard-details {
    font-size: 12px;
    color: #666;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.techcard-details > div {
    display: flex;
    align-items: center;
    gap: 6px;
}

.techcard-details i {
    color: #667eea;
    width: 14px;
}

.techcard-detail-block {
    animation: slideIn 0.3s ease;
}

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

/* Таблицы в тех картах */
.techcard-detail-block .data-table th {
    padding: 8px;
    font-size: 11px;
    font-weight: 600;
}

.techcard-detail-block .data-table td {
    padding: 8px;
    border-bottom: 1px solid #f0f0f0;
}

.techcard-detail-block .data-table code {
    background: #f5f5f5;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 11px;
}


/* ============================================
   INSTRUCTION MODAL - СОВРЕМЕННЫЙ ДИЗАЙН
   ============================================ */

.instruction-modal-modern {
    max-width: 800px;
    width: 95%;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    padding: 0;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.instruction-hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 50px 40px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.instruction-hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    animation: pulse 4s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 0.5; }
    50% { transform: scale(1.1); opacity: 0.8; }
}

.instruction-hero-icon {
    font-size: 72px;
    margin-bottom: 20px;
    position: relative;
    z-index: 1;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-15px); }
}

.instruction-hero h2 {
    margin: 0 0 15px 0;
    font-size: 32px;
    font-weight: 700;
    color: white;
    position: relative;
    z-index: 1;
}

.instruction-hero p {
    margin: 0;
    font-size: 16px;
    line-height: 1.6;
    opacity: 0.95;
    max-width: 600px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.instruction-content-modern {
    flex: 1;
    overflow-y: auto;
    padding: 40px;
    background: #fafbfc;
}

.welcome-message {
    background: white;
    padding: 25px;
    border-radius: 12px;
    margin-bottom: 30px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    border-left: 4px solid #667eea;
}

.welcome-message p {
    margin: 0;
    color: #555;
    line-height: 1.8;
    font-size: 15px;
}

/* Аккордеон */
.instruction-accordion {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 30px;
}

.accordion-item {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    transition: all 0.3s ease;
}

.accordion-item:hover {
    box-shadow: 0 4px 16px rgba(102, 126, 234, 0.15);
}

.accordion-item.active {
    box-shadow: 0 4px 16px rgba(102, 126, 234, 0.2);
}

.accordion-header {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 20px 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: white;
    user-select: none;
}

.accordion-header:hover {
    background: #f8f9fa;
}

.accordion-item.active .accordion-header {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.08) 0%, rgba(118, 75, 162, 0.08) 100%);
}

.accordion-icon {
    flex-shrink: 0;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 22px;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.accordion-title {
    flex: 1;
}

.accordion-title h3 {
    margin: 0 0 5px 0;
    font-size: 18px;
    font-weight: 600;
    color: #1f2937;
}

.accordion-subtitle {
    font-size: 13px;
    color: #6b7280;
}

.accordion-arrow {
    flex-shrink: 0;
    width: 32px;
    height: 32px;
    background: #f3f4f6;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #667eea;
    font-size: 14px;
    transition: all 0.3s ease;
}

.accordion-item.active .accordion-arrow {
    transform: rotate(180deg);
    background: #667eea;
    color: white;
}

.accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.3s ease;
    padding: 0 25px;
}

.accordion-item.active .accordion-content {
    max-height: 500px;
    padding: 0 25px 25px 25px;
}

.instruction-steps {
    margin: 0;
    padding: 0;
    list-style: none;
}

.instruction-steps li {
    position: relative;
    padding: 12px 0 12px 35px;
    color: #555;
    line-height: 1.7;
    font-size: 15px;
    border-bottom: 1px dashed #e5e7eb;
}

.instruction-steps li:last-child {
    border-bottom: none;
}

.instruction-steps li::before {
    content: '✓';
    position: absolute;
    left: 0;
    top: 12px;
    width: 24px;
    height: 24px;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
}

.instruction-steps li strong {
    color: #667eea;
}

/* Блок полезной информации */
.instruction-info-box {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 30px;
    border: 2px solid #fbbf24;
}

.info-box-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 15px;
}

.info-box-header i {
    font-size: 28px;
    color: #f59e0b;
}

.info-box-header h4 {
    margin: 0;
    font-size: 20px;
    color: #92400e;
    font-weight: 700;
}

.info-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.info-list li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 12px;
    color: #78350f;
    line-height: 1.7;
    font-size: 14px;
}

.info-list li:last-child {
    margin-bottom: 0;
}

.info-list li i {
    flex-shrink: 0;
    color: #10b981;
    font-size: 16px;
    margin-top: 2px;
}

/* Footer */
.instruction-footer {
    background: white;
    padding: 25px;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.footer-icon {
    font-size: 40px;
    color: #ef4444;
    margin-bottom: 15px;
    animation: heartbeat 1.5s ease-in-out infinite;
}

@keyframes heartbeat {
    0%, 100% { transform: scale(1); }
    25% { transform: scale(1.1); }
    50% { transform: scale(1); }
}

.instruction-footer p {
    margin: 0;
    color: #667eea;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.6;
}

/* Scrollbar */
.instruction-content-modern::-webkit-scrollbar {
    width: 8px;
}

.instruction-content-modern::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.instruction-content-modern::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 10px;
}

.instruction-content-modern::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #5568d3 0%, #6a3f92 100%);
}

/* Responsive */
@media (max-width: 768px) {
    .instruction-modal-modern {
        width: 100%;
        max-height: 100vh;
        border-radius: 0;
    }

    .instruction-hero {
        padding: 40px 25px;
    }

    .instruction-hero-icon {
        font-size: 56px;
    }

    .instruction-hero h2 {
        font-size: 24px;
    }

    .instruction-hero p {
        font-size: 14px;
    }

    .instruction-content-modern {
        padding: 25px 20px;
    }

    .accordion-header {
        padding: 15px 20px;
        gap: 15px;
    }

    .accordion-icon {
        width: 42px;
        height: 42px;
        font-size: 18px;
    }

    .accordion-title h3 {
        font-size: 16px;
    }

    .accordion-subtitle {
        font-size: 12px;
    }

    .accordion-content {
        padding: 0 20px;
    }

    .accordion-item.active .accordion-content {
        padding: 0 20px 20px 20px;
    }

    .instruction-steps li {
        padding-left: 30px;
        font-size: 14px;
    }

    .instruction-steps li::before {
        width: 20px;
        height: 20px;
        font-size: 11px;
    }

    .info-box-header h4 {
        font-size: 18px;
    }

    .info-list li {
        font-size: 13px;
    }
}


@keyframes slideUp {
    from {
        transform: translateY(100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@media (max-width: 768px) {
    #cookieBanner > div > div {
        flex-direction: column;
        text-align: center;
    }
    #cookieBanner button {
        width: 100%;
    }
}

@keyframes slideDown {
    from {
        transform: translateY(0);
        opacity: 1;
    }
    to {
        transform: translateY(100%);
        opacity: 0;
    }
}


/* Логотип */
.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    transition: transform 0.3s ease;
    cursor: pointer;
}

.logo:hover {
    transform: scale(1.02);
}

.logo img {
    height: 50px;
    width: auto;
    display: block;
}

.logo h1 {
    margin: 0;
    font-size: 22px;
    line-height: 1.2;
    color: #00437A;
}

.logo h1 span {
    color: #FF6520;
}

@media (max-width: 768px) {
    .logo {
        gap: 8px;
    }
    
    .logo img {
        height: 40px;
    }
    
    .logo h1 {
        font-size: 18px;
    }
}

@media (max-width: 480px) {
    .logo img {
        height: 35px;
    }
    
    .logo h1 {
        font-size: 16px;
    }
}


/* Стили для таблицы заявок */
.applications-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

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

.applications-table thead th {
    padding: 15px;
    text-align: left;
    font-weight: 600;
    font-size: 14px;
}

.applications-table tbody tr {
    border-bottom: 1px solid #e0e0e0;
    transition: background 0.2s;
}

.applications-table tbody tr:hover {
    background: #f8f9fa;
}

.applications-table tbody td {
    padding: 12px 15px;
    color: #333;
    font-size: 14px;
}

.table-responsive {
    overflow-x: auto;
    margin-top: 20px;
}



/* ============================================================
   КОНЕЦ ФАЙЛА
   ============================================================ */