*, *::before, *::after { box-sizing: border-box; }

body {
  margin: 0;
  font-family: system-ui, sans-serif;
  font-size: 14px;
  color: #1a1a1a;
  background: #f5f5f5;
}

/* ── Login / logout-success ── */
.login-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  gap: 1.5rem;
}

.login-container h1 {
  margin: 0;
  font-size: 1.8rem;
}

/* ── Layout ── */
header {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 1.5rem;
  background: #fff;
  border-bottom: 1px solid #e0e0e0;
}

header h1 {
  margin: 0;
  font-size: 1.1rem;
  flex: 1;
}

header a {
  color: #555;
  text-decoration: none;
  font-size: 0.9rem;
}

main {
  max-width: 960px;
  margin: 2rem auto;
  padding: 0 1.5rem;
}

/* ── Toolbar ── */
.toolbar {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.toolbar h2 {
  margin: 0;
  flex: 1;
}

/* ── Messages ── */
.success {
  color: #2d6a2d;
  background: #eaf5ea;
  border: 1px solid #b7dfb7;
  border-radius: 4px;
  padding: 0.5rem 0.75rem;
  margin-bottom: 1rem;
}

/* ── Project list ── */
.project-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.project-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: #fff;
  border: 1px solid #e0e0e0;
  border-radius: 6px;
  padding: 0.75rem 1rem;
}

.project-card strong {
  flex: 1;
}

.project-card form {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* ── Table ── */
table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  border: 1px solid #e0e0e0;
  border-radius: 6px;
  overflow: hidden;
}

th {
  text-align: left;
  padding: 0.6rem 0.75rem;
  background: #f0f0f0;
  border-bottom: 1px solid #e0e0e0;
  font-weight: 600;
}

td {
  padding: 0.5rem 0.75rem;
  border-bottom: 1px solid #f0f0f0;
  vertical-align: middle;
}

tr:last-child td {
  border-bottom: none;
}

.text-input {
  width: 100%;
  padding: 0.3rem 0.5rem;
  border: 1px solid #d0d0d0;
  border-radius: 4px;
  font-size: 14px;
  font-family: inherit;
}

.text-input:focus {
  outline: none;
  border-color: #4a90d9;
}

.bexio-text {
  margin-top: 0.2rem;
  padding: 0 0.5rem;
  font-size: 12px;
  color: #888;
}

.actions {
  white-space: nowrap;
  display: flex;
  gap: 0.4rem;
}

/* ── Buttons ── */
button, .btn-primary {
  display: inline-block;
  padding: 0.4rem 0.85rem;
  border: 1px solid #c0c0c0;
  border-radius: 4px;
  background: #fff;
  color: #1a1a1a;
  font-size: 14px;
  font-family: inherit;
  cursor: pointer;
  text-decoration: none;
  line-height: 1.4;
}

button:hover, .btn-primary:hover {
  background: #f0f0f0;
}

.btn-primary {
  background: #2563eb;
  border-color: #2563eb;
  color: #fff;
}

.btn-primary:hover {
  background: #1d4fd8;
  border-color: #1d4fd8;
}

.btn-danger {
  border-color: #dc2626;
  color: #dc2626;
}

.btn-danger:hover {
  background: #fef2f2;
}

input[type="date"] {
  padding: 0.35rem 0.5rem;
  border: 1px solid #c0c0c0;
  border-radius: 4px;
  font-size: 14px;
  font-family: inherit;
}
