:root {
    --tg-color-scheme: light;
    --tg-theme-bg-color: #ffffff;
    --tg-theme-text-color: #000000;
    --tg-theme-hint-color: #999999;
    --tg-theme-link-color: #2481cc;
    --tg-theme-button-color: #3390ec;
    --tg-theme-button-text-color: #ffffff;
    --tg-theme-secondary-bg-color: #f1f1f1;
    --tg-theme-header-bg-color: #ffffff;
    --tg-theme-section-bg-color: #ffffff;
    --tg-theme-section-header-text-color: #6e7aa1;
}

body {
    background-color: var(--tg-theme-bg-color);
    color: var(--tg-theme-text-color);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;
}

.container-fluid {
    padding: 0;
    padding-bottom: 80px;
}

.card {
    background-color: var(--tg-theme-secondary-bg-color);
    border:1px solid rgba(0, 0, 0, 0.1);
    border-radius: 12px;
    margin-bottom:1rem;
    box-shadow:0 2px 4px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.card-body {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.card-header {
    background-color: var(--tg-theme-section-bg-color);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    font-weight: 600;
    border-radius: 12px 12px 0 0;
    padding: 1rem;
}

.btn {
    border-radius: 8px;
    font-weight: 500;
}

.btn-primary {
    background-color: var(--tg-theme-button-color);
    border-color: var(--tg-theme-button-color);
}

.btn-primary:hover {
    background-color: #297acc;
    border-color: #297acc;
}

.btn-outline-secondary {
    border-color: var(--tg-theme-hint-color);
    color: var(--tg-theme-text-color);
}

.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 280px;
    height: 100vh;
    background-color: var(--tg-theme-secondary-bg-color);
    border-right: 1px solid rgba(0, 0, 0, 0.1);
    overflow-y: auto;
    z-index: 1000;
    transform: translateX(-100%);
    transition: transform 0.3s ease-in-out;
}

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

.sidebar-header {
    padding: 1rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    background-color: var(--tg-theme-section-bg-color);
}

.sidebar-content {
    padding: 1rem;
}

.backpack-list-item {
    padding: 0.75rem;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.2s;
    margin-bottom: 0.5rem;
}

.backpack-list-item:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.backpack-list-item.active {
    background-color: var(--tg-theme-button-color);
    color: var(--tg-theme-button-text-color);
}

.weight-display {
    text-align: center;
    padding: 1.5rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 12px;
    margin-bottom: 1rem;
}

.weight-display .total-weight {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.weight-display .weight-breakdown {
    display: flex;
    justify-content: space-around;
    font-size: 0.9rem;
}

.weight-breakdown-item {
    text-align: center;
}

.weight-breakdown-item .label {
    opacity: 0.8;
    font-size: 0.75rem;
}

.weight-breakdown-item .value {
    font-weight: 600;
    font-size: 1.1rem;
}

.equipment-item {
    padding: 1rem;
    padding-left: 0.5rem;
    border-radius: 8px;
    background-color: var(--tg-theme-bg-color);
    margin-bottom: 0.75rem;
    border: 1px solid rgba(0, 0, 0, 0.05);
    transition: all 0.2s;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    display: flex;
    align-items: stretch;
    gap: 0.5rem;
}

.equipment-item:hover {
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.equipment-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.equipment-item-name {
    font-weight: 600;
    font-size: 1.1rem;
    flex-grow: 1;
}

.equipment-item-weight {
    font-weight: 500;
    color: var(--tg-theme-hint-color);
    margin-left: 1rem;
}

.equipment-item-notes {
    font-size: 0.85rem;
    color: var(--tg-theme-hint-color);
    margin-top: 0.5rem;
    font-style: italic;
}

/* Drag handle для перетаскивания карточек */
.equipment-drag-handle {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    cursor: grab;
    opacity: 0.3;
    transition: opacity 0.2s;
    user-select: none;
    touch-action: none;
    font-size: 1.2rem;
    color: var(--tg-theme-text-color, #000);
}

.equipment-drag-handle:hover {
    opacity: 0.6;
}

.equipment-drag-handle:active {
    cursor: grabbing;
}

.equipment-item-content {
    flex: 1;
    min-width: 0;
}

/* Редактируемые поля должны быть доступны для выделения */
.item-name-editable,
.item-desc-editable {
    user-select: text !important;
    -webkit-user-select: text !important;
    -moz-user-select: text !important;
    -ms-user-select: text !important;
    cursor: text;
}

.item-name-editable:hover,
.item-desc-editable:hover {
    background-color: rgba(0, 0, 0, 0.03);
    border-radius: 4px;
    padding: 2px 4px;
    margin: -2px -4px;
}

/* Редактируемое количество */
.item-quantity-editable {
    user-select: text !important;
    -webkit-user-select: text !important;
    -moz-user-select: text !important;
    -ms-user-select: text !important;
    cursor: text;
    border-bottom: 1px dashed transparent;
    transition: all 0.2s;
    display: inline-block;
    min-width: 20px;
    text-align: center;
}

.item-quantity-editable:hover {
    border-bottom-color: var(--tg-theme-button-color);
    background-color: rgba(0, 0, 0, 0.03);
    padding: 0 2px;
    margin: 0 -2px;
}

.item-quantity-editable:focus {
    outline: none;
    border-bottom: 1px solid var(--tg-theme-button-color);
    background-color: rgba(51, 144, 236, 0.1);
    padding: 0 2px;
    margin: 0 -2px;
}

/* Редактируемый вес */
.item-weight-editable {
    user-select: text !important;
    -webkit-user-select: text !important;
    -moz-user-select: text !important;
    -ms-user-select: text !important;
    cursor: text;
    border-bottom: 1px dashed transparent;
    transition: all 0.2s;
    display: inline-block;
    min-width: 50px;
    text-align: center;
}

.item-weight-editable:hover {
    border-bottom-color: var(--tg-theme-button-color);
    background-color: rgba(0, 0, 0, 0.03);
    padding: 0 2px;
    margin: 0 -2px;
}

.item-weight-editable:focus {
    outline: none;
    border-bottom: 1px solid var(--tg-theme-button-color);
    background-color: rgba(51, 144, 236, 0.1);
    padding: 0 2px;
    margin: 0 -2px;
}

.toggles-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.unit-toggle {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Контейнер для кнопок действий */
.action-buttons {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Скрытие текста кнопок на мобильных */
.action-buttons .btn-text {
    display: inline;
}

/* Адаптивные стили для мобильных устройств */
@media (max-width: 768px) {
    /* Скрываем текст кнопок, показываем только иконки */
    .action-buttons .btn-text {
        display: none;
    }

    .action-buttons .btn-icon {
        display: inline;
    }

    /* Скрываем подписи переключателей */
    .toggle-label {
        display: none;
    }

    /* Уменьшаем отступы в контейнере */
    .toggles-container {
        flex-wrap: wrap;
    }

    .unit-toggle {
        min-width: fit-content;
    }

    /* Кнопки действий на мобильных */
    .action-buttons {
        flex: 0 0 auto;
    }

    /* Увеличиваем размер drag-handle для мобильных устройств */
    .equipment-drag-handle {
        min-width: 32px;
        font-size: 1.5rem;
        padding: 0.25rem 0;
    }

    /* Небольшая подсказка при первом касании */
    .equipment-item:active .equipment-drag-handle {
        opacity: 0.8;
    }

}

.category-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 500;
    color: white;
    margin-right: 0.5rem;
}

.loading-spinner {
    display: inline-block;
    width: 1rem;
    height: 1rem;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 0.6s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.alert {
    border-radius: 8px;
}

.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 999;
    display: none;
}

.overlay.show {
    display: block;
}

.chart-container {
    position: relative;
    height: 300px;
    margin-bottom: 1rem;
}

.draggable-item {
    /* Убираем cursor grab - теперь только для drag-handle */
    touch-action: pan-y; /* Разрешаем скроллинг по вертикали */
    -webkit-user-select: none;
    user-select: none;
}

.draggable-item.dragging {
    opacity: 0.5;
    transform: scale(0.95);
    z-index: 1000;
    position: relative;
}

.drop-zone {
    min-height: 100px;
    border: 2px dashed transparent;
    border-radius: 8px;
    transition: all 0.2s;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

.backpack-list,
.left-at-home-list {
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    /* Корректный скроллинг на мобильных устройствах */
    touch-action: pan-y;
    -webkit-overflow-scrolling: touch;
}

/* Списки должны прокручиваться при касании не на drag-handle */
.backpack-list *,
.left-at-home-list * {
    touch-action: pan-y;
}

/* Drag handle изымается из общего потока касаний */
.equipment-drag-handle {
    touch-action: none;
}

.drop-zone.drag-over {
    background-color: rgba(51, 144, 236, 0.1);
    border-color: #3390ec;
}

.drop-zone.drag-over-left-at-home {
    background-color: rgba(40, 167, 69, 0.1);
    border-color: #28a745;
}

.drop-zone.drag-over-backpack {
    background-color: rgba(51, 144, 236, 0.1);
    border-color: #3390ec;
}

.backpack-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.backpack-table thead {
    background-color: var(--tg-theme-section-bg-color);
    position: sticky;
    top: 0;
    z-index: 1;
}

.backpack-table th {
    padding: 0.5rem;
    text-align: left;
    font-weight: 600;
    border-bottom: 2px solid rgba(0, 0, 0, 0.1);
    background-color: var(--tg-theme-section-bg-color);
}

.backpack-table td {
    padding: 0.5rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.backpack-table tbody tr:hover {
    background-color: rgba(0, 0, 0, 0.02);
}

.backpack-table-category {
    padding: 1rem 0.5rem 0.5rem 0.5rem;
    font-weight: 600;
    font-size: 1.1rem;
    color: var(--tg-theme-section-header-text-color);
    background-color: var(--tg-theme-secondary-bg-color);
    border-bottom: 2px solid rgba(0, 0, 0, 0.1);
    cursor: move;
    user-select: none;
}

.table-view-category {
    margin-top: 1.5rem;
}

/* Кнопки в заголовке категории таблицы */
.backpack-table-category .btn-group {
    flex-shrink: 0;
}

.backpack-table-category .btn {
    font-size: 0.8rem;
    padding: 0.25rem 0.5rem;
    white-space: nowrap;
}

/* Стили для списка снаряжения в модальном окне */
.catalog-equipment-item {
    cursor: pointer;
    transition: background-color 0.2s;
}

.catalog-equipment-item:hover {
    background-color: var(--tg-theme-hover-bg-color, #f8f9fa);
}

.drag-placeholder {
    min-height: 40px;
    background: linear-gradient(135deg, rgba(51, 144, 236, 0.1) 0%, rgba(51, 144, 236, 0.2) 100%);
    border: 2px dashed #3390ec;
    border-radius: 8px;
    margin: 0.5rem 0;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: pulse 1.5s ease-in-out infinite;
    backdrop-filter: blur(2px);
}

.drag-placeholder::before {
    content: "📍 Вставить сюда";
    font-size: 0.9rem;
    color: #3390ec;
    font-weight: 500;
}

@keyframes pulse {
    0%, 100% {
        opacity: 0.5;
    }
    50% {
        opacity: 0.8;
    }
}

.needed-item-row {
    border-bottom: 1px solid #eee;
    transition: background-color 0.2s;
}

.needed-item-row:hover {
    background-color: #f8f9fa;
}

.needed-item-row:last-child {
    border-bottom: none;
}

/* Стили для чекбокса в списке "Нужно купить" (рюкзак) */
.equipment-item .form-check {
    margin: 0;
    padding: 0;
}

.equipment-item .backpack-needed-checkbox {
    width: 1.2rem;
    height: 1.2rem;
    cursor: pointer;
    margin: 0;
}

.equipment-item .form-check-label {
    cursor: pointer;
    user-select: none;
    margin-left: 0.5rem;
    font-size: 0.9rem;
    color: var(--tg-theme-text-color);
}

.equipment-item .backpack-needed-checkbox:checked {
    background-color: #28a745;
    border-color: #28a745;
}

.equipment-item .backpack-needed-checkbox:focus {
    box-shadow: 0 0 0 0.2rem rgba(40, 167, 69, 0.25);
    border-color: #28a745;
}

/* Редактируемые ячейки таблицы */
.backpack-table .editable {
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
}

.backpack-table .editable:hover {
    background-color: rgba(51, 144, 236, 0.1);
    padding: 0.5rem;
    margin: -0.5rem;
}

.backpack-table .editable.editing {
    background-color: rgba(51, 144, 236, 0.15);
    outline: 2px solid var(--tg-theme-button-color);
    outline-offset: -2px;
    padding: 0.5rem;
    margin: -0.5rem;
}

.backpack-table .editable.editing:focus {
    outline: 2px solid var(--tg-theme-button-color);
    background-color: rgba(51, 144, 236, 0.2);
}

/* Чекбоксы статусов в таблице */
.backpack-table .status-checkbox {
    cursor: pointer;
    user-select: none;
    transition: transform 0.2s;
    display: inline-block;
}

.backpack-table .status-checkbox:hover {
    transform: scale(1.2);
}

.backpack-table .status-checkbox:active {
    transform: scale(0.95);
}

/* Цветовая индикация для разных типов статусов */
.backpack-table .status-checkbox.packed-checkbox:hover {
    filter: drop-shadow(0 0 2px #28a745);
}

.backpack-table .status-checkbox.consumable-checkbox:hover {
    filter: drop-shadow(0 0 2px #ffc107);
}

.backpack-table .status-checkbox.worn-checkbox:hover {
    filter: drop-shadow(0 0 2px #17a2b8);
}

.delete-category-btn {
    text-decoration: none;
}

/* Стили для drag-n-drop в таблице */
.table-view-category-placeholder {
    background-color: rgba(51, 144, 236, 0.1);
    border: 2px dashed #3390ec;
    border-radius: 8px;
    margin: 0.5rem 0;
}

.item-placeholder {
    background-color: rgba(51, 144, 236, 0.1);
    border: 2px dashed #3390ec;
    border-radius: 4px;
}

.table-view-category.ui-sortable-helper {
    opacity: 0.9;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.table-view-category .category-drag-handle {
    cursor: move;
}

.backpack-table .item-drag-handle:hover {
    opacity: 1;
    cursor: grab;
}

.backpack-table .item-drag-handle:active {
    cursor: grabbing;
}

#userInfo {
    text-align: right;
    align-items: center;
}

.card-header:first-child {
    border-radius: inherit;
    /* border-radius: var(--bs-card-inner-border-radius) var(--bs-card-inner-border-radius) 0 0; */
}

.backpack-delete-btn {
    text-decoration: none;
}
/* ========== Стили для Telegram WebApp кнопок в sidebar ========== */
#telegramWebappLinks {
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    padding-top: 1rem;
}

#telegramWebappLinks .btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    padding: 0.5rem 0.75rem;
    transition: all 0.2s ease-in-out;
}

#telegramWebappLinks .btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

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

#telegramWebappLinks .btn-icon {
    font-size: 1rem;
    line-height: 1;
}

#telegramWebappLinks .btn-text {
    flex: 1;
    text-align: left;
}

/* ========== Стили для AI Report Widget ========== */
.ai-report-widget {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 1040;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
    transition: all 0.3s ease-in-out;
    animation: ai-pulse 2s ease-in-out infinite;
}

.ai-report-widget:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
}

.ai-report-widget:active {
    transform: scale(0.95);
}

.ai-report-widget .ai-icon {
    font-size: 1.8rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

@keyframes ai-pulse {
    0%, 100% {
        box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4), 0 0 0 0 rgba(102, 126, 234, 0.4);
    }
    50% {
        box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4), 0 0 0 15px rgba(102, 126, 234, 0);
    }
}

/* AI Report Panel */
.ai-report-panel {
    position: fixed;
    top: 0;
    right: 0;
    width: 800px;
    max-width: 90vw;
    height: 100vh;
    background: linear-gradient(180deg, #667eea 0%, #764ba2 100%);
    z-index: 1050;
    transform: translateX(100%);
    transition: transform 0.3s ease-in-out;
    display: flex;
    flex-direction: column;
    box-shadow: -4px 0 20px rgba(0, 0, 0, 0.2);
}

.ai-report-panel.show {
    transform: translateX(0);
}

.ai-panel-header {
    padding: 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    background: rgba(0, 0, 0, 0.1);
}

.ai-panel-header h5 {
    color: white;
    font-weight: 600;
}

.ai-panel-header .btn-buy-tokens-header {
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
    border-color: rgba(255, 255, 255, 0.5);
    color: white;
    transition: all 0.2s;
}

.ai-panel-header .btn-buy-tokens-header:hover {
    background-color: rgba(255, 255, 255, 0.2);
    border-color: white;
    color: white;
}

.ai-panel-content {
    flex: 1;
    overflow-y: auto;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.95);
    color: #333;
}

.ai-panel-footer {
    padding: 1rem 1.5rem;
    background: rgba(0, 0, 0, 0.1);
    border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.ai-panel-footer .text-muted {
    color: rgba(255, 255, 255, 0.7) !important;
}

/* AI Report Content Styles */
.ai-report-section {
    margin-bottom: 2rem;
}

.ai-report-section-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #667eea;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #667eea;
}

.ai-report-category {
    margin-bottom: 1.5rem;
}

.ai-report-category-name {
    font-weight: 600;
    color: #764ba2;
    margin-bottom: 0.75rem;
    font-size: 1.05rem;
}

.ai-report-item {
    padding: 0.75rem;
    background: #f8f9fa;
    border-radius: 8px;
    margin-bottom: 0.5rem;
    border-left: 3px solid #667eea;
}

.ai-report-item-name {
    font-weight: 500;
    color: #333;
}

.ai-report-item-details {
    font-size: 0.9rem;
    color: #666;
    margin-top: 0.25rem;
}

.ai-report-summary {
    line-height: 1.6;
    color: #333;
    white-space: pre-wrap;
}

/* AI Loading Spinner */
.ai-loading-spinner {
    display: inline-block;
    width: 2rem;
    height: 2rem;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 0.8s linear infinite;
}

/* Panel overlay для закрытия по клику вне панели */
.ai-panel-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1045;
    display: none;
}

.ai-panel-overlay.show {
    display: block;
}

/* Адаптивные стили для мобильных */
@media (max-width: 768px) {
    .ai-report-widget {
        bottom: 1.5rem;
        right: 1rem;
        width: 50px;
        height: 50px;
    }

    .ai-report-widget .ai-icon {
        font-size: 1.5rem;
    }

    .ai-report-panel {
        width: 100vw;
        max-width: 100vw;
    }

    .ai-panel-header,
    .ai-panel-content,
    .ai-panel-footer {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    .ai-panel-content {
        padding-top: 1rem;
        padding-bottom: 1rem;
    }
}

/* Стили для ошибок и сообщений */
.ai-report-error {
    padding: 1rem;
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 8px;
    color: #721c24;
    margin-bottom: 1rem;
}

.ai-report-empty {
    text-align: center;
    padding: 2rem 1rem;
    color: #6c757d;
}

.ai-report-empty-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

/* ========== Стили для Markdown контента в AI отчёте ========== */
.ai-report-content {
    line-height: 1.7;
    color: #333;
}

.ai-report-content h1,
.ai-report-content h2,
.ai-report-content h3,
.ai-report-content h4,
.ai-report-content h5,
.ai-report-content h6 {
    margin-top: 1.5rem;
    margin-bottom: 1rem;
    font-weight: 600;
    color: #667eea;
}

.ai-report-content h1 {
    font-size: 1.8rem;
    border-bottom: 2px solid #667eea;
    padding-bottom: 0.5rem;
}

.ai-report-content h2 {
    font-size: 1.5rem;
    border-bottom: 1px solid #e0e0e0;
    padding-bottom: 0.3rem;
}

.ai-report-content h3 {
    font-size: 1.3rem;
    color: #764ba2;
}

.ai-report-content p {
    margin-bottom: 1rem;
}

.ai-report-content ul,
.ai-report-content ol {
    margin-bottom: 1rem;
    padding-left: 1.5rem;
}

.ai-report-content li {
    margin-bottom: 0.5rem;
}

.ai-report-content ul li {
    list-style-type: disc;
}

.ai-report-content ol li {
    list-style-type: decimal;
}

.ai-report-content code {
    background: #f4f4f4;
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
    color: #e83e8c;
}

.ai-report-content pre {
    background: #f4f4f4;
    padding: 1rem;
    border-radius: 8px;
    overflow-x: auto;
    margin-bottom: 1rem;
}

.ai-report-content pre code {
    background: none;
    padding: 0;
    color: #333;
}

.ai-report-content blockquote {
    border-left: 4px solid #667eea;
    padding-left: 1rem;
    margin: 1rem 0;
    color: #6c757d;
    font-style: italic;
}

.ai-report-content strong {
    font-weight: 600;
    color: #333;
}

.ai-report-content em {
    font-style: italic;
}

.ai-report-content a {
    color: #667eea;
    text-decoration: none;
    border-bottom: 1px dotted #667eea;
}

.ai-report-content a:hover {
    color: #764ba2;
    border-bottom-style: solid;
}

.ai-report-content table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1rem;
}

.ai-report-content th,
.ai-report-content td {
    border: 1px solid #dee2e6;
    padding: 0.5rem;
    text-align: left;
}

.ai-report-content th {
    background: #f8f9fa;
    font-weight: 600;
}

.ai-report-content hr {
    border: none;
    border-top: 1px solid #dee2e6;
    margin: 2rem 0;
}

/* Анимация для сообщения загрузки */
.ai-loading-message {
    font-size: 1.1rem;
    color: #667eea;
    animation: pulse-text 2s ease-in-out infinite;
}

@keyframes pulse-text {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

/* Стили для кнопки AI-анализа снаряжения */
.ai-analysis-btn {
    position: relative;
    font-size: 1.1rem;
    padding: 0.25rem 0.5rem;
}

.ai-analysis-btn:hover {
    background-color: #667eea !important;
    border-color: #667eea !important;
}

/* Индикатор загрузки для кнопки AI */
.ai-analysis-btn.loading {
    opacity: 0.6;
    pointer-events: none;
}

