* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: #f5f6fa;
  font-family: system-ui, sans-serif;
}

.container {
  max-width: 700px;
  margin: 60px auto;
  padding: 20px;
}

h1 {
  margin-bottom: 40px;
  text-align: center;
}

#drop-zone {
  padding: 60px 30px;
  border: 3px dashed #b7c0cc;
  border-radius: 12px;
  background: white;
  text-align: center;
  cursor: pointer;
  transition: .2s;
}

#drop-zone:hover {
  border-color: #0d6efd;
}

button {
  margin-top: 20px;
  padding: 10px 24px;
  border: 0;
  border-radius: 8px;
  background: #0d6efd;
  color: white;
  cursor: pointer;
}

button:hover {
  background: #0b5ed7;
}

.drag-over {
  border-color: #0d6efd !important;
  background: #eef5ff;
}

.icon {
  font-size: 3rem;
  margin-bottom: 20px;
}

#selected-files {
  list-style: none;
  margin: 0 0 10px;
  padding: 0;
  text-align: left;
  max-height: 200px;
  overflow-y: auto;
}

#selected-files li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 4px 0;
  border-bottom: 1px solid #eef1f5;
}

#selected-files li span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.remove-file {
  flex-shrink: 0;
  margin: 0;
  padding: 0 8px;
  background: transparent;
  color: #b7c0cc;
  font-size: 1.2rem;
  line-height: 1.8;
  border-radius: 4px;
}

.remove-file:hover {
  background: #fde8e8;
  color: #d9534f;
}

#submit {
  display: block;
  margin: 30px auto 0;
  min-width: 180px;
}

#submit:disabled {
  opacity: .5;
  cursor: not-allowed;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  background: white;
  border-bottom: 1px solid #e5e8ee;
}

.topbar-title {
  font-weight: 700;
  color: #16181d;
  text-decoration: none;
}

.logout-form {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0;
}

.topbar-user {
  color: #5a6472;
  font-size: .9rem;
}

.logout-form button {
  margin: 0;
  padding: 6px 16px;
  font-size: .85rem;
  background: #eef1f5;
  color: #495260;
}

.logout-form button:hover {
  background: #e2e6ec;
}

.back-link {
  margin-bottom: 10px;
}

.back-link a {
  color: #5a6472;
  text-decoration: none;
  font-size: .9rem;
}

.back-link a:hover {
  text-decoration: underline;
}

.tool-list {
  display: grid;
  gap: 16px;
}

.tool-card {
  display: block;
  padding: 24px;
  background: white;
  border-radius: 12px;
  border: 1px solid #e5e8ee;
  text-decoration: none;
  color: inherit;
  transition: .2s;
}

.tool-card:hover {
  border-color: #0d6efd;
  box-shadow: 0 2px 10px rgba(13, 110, 253, .08);
}

.tool-card h2 {
  margin: 0 0 6px;
  font-size: 1.1rem;
  color: #16181d;
}

.tool-card p {
  margin: 0;
  color: #5a6472;
  font-size: .9rem;
}

.container-narrow {
  max-width: 360px;
}

.login-form {
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: white;
  padding: 30px;
  border-radius: 12px;
  border: 1px solid #e5e8ee;
}

.login-form label {
  font-size: .85rem;
  color: #5a6472;
  margin-top: 10px;
}

.login-form input {
  padding: 10px 12px;
  border: 1px solid #d7dce3;
  border-radius: 8px;
  font-size: 1rem;
}

.login-form input:focus {
  outline: none;
  border-color: #0d6efd;
}

.login-form button {
  margin-top: 20px;
}

.error {
  margin: 0;
  padding: 10px 14px;
  background: #fde8e8;
  color: #b3261e;
  border-radius: 8px;
  font-size: .9rem;
}