:root {
  --bg: #0f1115;
  --panel: #161a22;
  --border: #252a36;
  --text: #e6e6eb;
  --muted: #9aa0aa;
  --hover: #1f2532;
  --accent: #4f8cff;
}

* {
  box-sizing: border-box;
}

body {
  font-family: system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  margin: 0;
  padding: 1rem;
}

h1 {
  text-align: center;
  margin-bottom: 1rem;
}

#container {
  display: flex;
  gap: 1rem;
  height: calc(100vh - 100px);
}

#file-list {
  width: 30%;
  background: var(--panel);
  border: 1px solid var(--border);
  padding: 0.5rem;
  overflow-y: auto;
}

.file-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.6rem;
  margin-bottom: 0.3rem;
  background: transparent;
  border: none;
  color: var(--text);
  cursor: pointer;
  width: 100%;
  text-align: left;
}

.file-item:hover {
  background: var(--hover);
}

.file-icon {
  width: 1.5rem;
  text-align: center;
  font-size: 1.2rem;
}

.file-name {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

#preview {
  width: 70%;
  background: var(--panel);
  border: 1px solid var(--border);
  padding: 1rem;
  text-align: center;
}

#preview img,
#preview video,
#preview audio {
  max-width: 100%;
  max-height: 75vh;
}

#preview a {
  color: var(--accent);
  text-decoration: none;
  font-size: 1.1rem;
}

#preview a:hover {
  text-decoration: underline;
}

.empty {
  color: var(--muted);
  margin-top: 2rem;
}
