/* Общая карточка файла: информация слева, явные действия справа. */

.file-card {
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--surface);
}

.file-card__icon {
  width: 38px;
  height: 38px;
  flex: none;
  border-radius: 8px;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
}

.file-card__icon--pdf {
  background: #fdecec;
  box-shadow: inset 0 0 0 1px rgba(217, 48, 37, 0.1);
  color: #d93025;
}

.file-card__icon--image {
  background: var(--accent-tint);
  box-shadow: inset 0 0 0 1px rgba(124, 92, 255, 0.12);
  color: var(--accent-ink);
}

.file-card__icon--xlsx {
  background: #e7f5ec;
  box-shadow: inset 0 0 0 1px rgba(16, 124, 65, 0.1);
  color: #107c41;
}

.file-card__icon--docx {
  background: #eaf2ff;
  box-shadow: inset 0 0 0 1px rgba(24, 90, 189, 0.1);
  color: #185abd;
}

.file-card__icon--zip {
  background: #fff1dc;
  box-shadow: inset 0 0 0 1px rgba(213, 124, 31, 0.12);
  color: #b96616;
}

.file-card__icon--generic {
  background: var(--surface-2);
  color: var(--ink-2);
}

.file-card__info {
  min-width: 0;
}

.file-card__title {
  color: var(--ink);
  font-size: 14.5px;
  font-weight: 600;
  line-height: 1.3;
}

.file-card__description {
  margin-top: 3px;
  color: var(--ink-2);
  font-size: 13px;
  line-height: 1.35;
}

.file-card__meta {
  margin-top: 3px;
  color: var(--ink-3);
  font-size: 12.5px;
  line-height: 1.35;
}

.file-card__actions {
  gap: 7px;
  margin-left: auto;
}

.file-card__action {
  gap: 6px;
  min-height: 36px;
  padding: 7px 11px;
  border: 1px solid var(--line-2);
  border-radius: var(--r-pill);
  color: var(--ink-2);
  font-size: 12.5px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
}

.file-card__action--open {
  background: transparent;
}

.file-card__action--download {
  border-color: transparent;
  background: var(--accent-tint);
  color: var(--accent-ink);
}

.file-card__action:hover,
.file-card__action:focus-visible {
  border-color: var(--accent);
  background: var(--accent);
  color: var(--on-accent);
}

.file-card__action svg {
  flex: none;
}

.event-files .file-card {
  grid-template-columns: 38px minmax(0, 1fr);
  align-items: start;
  gap: 10px 12px;
}

.event-files .file-card__actions {
  grid-column: 1 / -1;
  justify-content: flex-end;
  width: 100%;
  margin-left: 0;
}

@media (max-width: 575.98px) {
  .file-card {
    grid-template-columns: 38px minmax(0, 1fr);
    align-items: start;
    gap: 10px 12px;
  }

  .file-card__actions {
    grid-column: 1 / -1;
    justify-content: flex-end;
    width: 100%;
    margin-left: 0;
    padding-top: 2px;
  }
}
