/* Стили для элементов прогресса загрузки */
.progress {
    height: 20px;
    background-color: #f0f0f0;
    border-radius: 10px;
    overflow: hidden;
    position: relative;
}
.progress-bar {
    transition: width 0.3s ease-in-out;
    position: relative;
    overflow: hidden;
}
.progress-bar::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        45deg,
        rgba(255,255,255,0.2) 25%,
        transparent 25%,
        transparent 50%,
        rgba(255,255,255,0.2) 50%,
        rgba(255,255,255,0.2) 75%,
        transparent 75%
    );
    background-size: 30px 30px;
    animation: progress-animation 1s linear infinite;
}
@keyframes progress-animation {
    0% { background-position: 0 0; }
    100% { background-position: 30px 0; }
}
.upload-item {
    margin-bottom: 15px;
    padding: 15px;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}
.upload-status {
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 10px;
}
.upload-status-icon {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: inline-block;
}
.upload-status-icon.pending {
    background: #ffc107;
    animation: pulse 1s infinite;
}
.upload-status-icon.success {
    background: #28a745;
}
.upload-status-icon.error {
    background: #dc3545;
}
@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}
/* Стили для зоны перетаскивания */
.drop-zone {
    border: 3px dashed #ccc;
    border-radius: 8px;
    padding: 30px;
    text-align: center;
    background: #f8f9fa;
    transition: all 0.3s ease;
    position: relative;
}
.drop-zone.dragover {
    background: #e9ecef;
    border-color: #0d6efd;
    transform: scale(1.02);
}
.drop-zone::before {
    content: '📁';
    font-size: 2em;
    display: block;
    margin-bottom: 10px;
}

/* Стили для списка файлов */
.file-item {
    padding: 1rem;
}

.file-info {
    display: flex;
    flex-direction: column;
}

.file-name {
    font-weight: 500;
    color: #000;
}

.file-date {
    font-size: 0.8rem;
}

.file-size {
    font-size: 0.8rem;
}

.file-actions .btn {
    display: inline-flex;
    align-items: center;
}

/* Адаптивность для мобильных устройств */
@media (max-width: 767.98px) {
    .drop-zone {
        border: none;
        padding: 0;
        background: transparent;
    }

    .drop-zone::before {
        display: none;
    }
    .file-item {
        flex-direction: column;
        align-items: flex-start;
    }

    .file-actions {
        width: 100%;
        display: flex;
        justify-content: space-between;
        margin-top: 1rem;
    }

    .file-actions .btn {
        flex-grow: 1;
        text-align: center;
    }

    .file-actions .btn:not(:last-child) {
        margin-right: 0.5rem;
    }
}

/* Выделение кнопки "Выбрать файлы" */
#fileInput::file-selector-button {
    background-color: #198754;
    color: #fff;
    border-color: #198754;
    transition: background-color .15s ease-in-out, border-color .15s ease-in-out;
}

#fileInput::file-selector-button:hover {
    background-color: #157347;
    border-color: #146c43;
}
.topbutton, .bottombutton {
  display: none; /* Скрыты по умолчанию, пока не начнётся скролл*/
  position: fixed;
  right: 20px;
  width: 100px;
  padding: 10px;
  text-align: center;
  background: #4CAF50; /* Зелёный */
  color: white;
  text-decoration: none;
  border-radius: 5px;
  font-family: Arial, sans-serif;
  font-size: 14px;
  cursor: pointer;
  z-index: 1000;
  transition: opacity 0.3s, background 0.3s;
}

.topbutton {
  bottom: 70px; /* Положение кнопки "Наверх" */
}

.bottombutton {
  bottom: 20px; /* Положение кнопки "Вниз" */
}

.topbutton:hover, .bottombutton:hover {
  background: #2E8B57; /* Тёмно‑зелёный при наведении */
  opacity: 0.9;
}
