/* General page layout */
body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  margin: 0;
  padding: 0;
  background-color: #fafafa;
  color: #222;
}

/* Centered content container */
.container {
  max-width: 1100px;
  margin: 40px auto;
  padding: 0 16px;
}

/* Headings */
h1 {
  text-align: center;
  margin-bottom: 32px;
}

/* Table basics */
table {
  width: 100%;
  border-collapse: collapse;
  background-color: white;
  border: 1px solid #ccc;
}

/* Header row */
thead th {
  white-space: nowrap;
  background-color: #f0f0f0;
  font-weight: 600;
  text-align: left;
  padding: 10px;
  border-bottom: 2px solid #ccc;
}

/* Body cells */
tbody td {
  padding: 8px 10px;
  border-bottom: 1px solid #e0e0e0;
}

/* Zebra striping */
tbody tr:nth-child(even) {
  background-color: #fafafa;
}

th.amount,
td.amount {
  text-align: right;
  white-space: nowrap;
}

/* Empty state */
.empty {
  text-align: center;
  padding: 16px;
  color: #666;
}

a.button, button {
  display: inline-block;
  padding: 8px 12px;
  border: 1px solid #ccc;
  background: #f0f0f0;
  color: #222;
  text-decoration: none;
  border-radius: 6px;
  cursor: pointer;
}


/* Navbar */

.navbar {
  display: flex;
  align-items: center;
  gap: 32px;
  padding: 16px 24px;
}

.navbar-title {
  margin-right: auto;  /* pushes all following items to the right */
}

.navbar a {
  font-size: 1.2rem;           /* bigger font */
  font-weight: 700;            /* bold */
  text-decoration: none;       /* no underline by default */
  color: inherit;              /* use page text color */
}

.navbar a:hover {
  text-decoration: underline;  /* underline on hover */
}

.page-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin: 1rem;
}




/* outer box */
.filters {
  border: 1px solid #ccc;
  border-radius: 8px;
  padding: 0.25rem;
  max-width: fit-content; /* optional */
}

/* clickable header */
.filter-toggle {
  display: list-item;           /* REQUIRED for triangle */
  list-style-position: inside;  /* triangle inside the box */

  cursor: pointer;
  font-size: 1.2rem;
  font-weight: 700;

  padding: 0.5rem 0.75rem;
  user-select: none;
}


/* hover feedback */
.filter-toggle:hover {
  background: #f2f2f2;
}

/* optional: visual separation when open */
.filters[open] .filter-toggle {
  border-bottom: 1px solid #ddd;
}

.filter-form {
  display: flex;
  flex-direction: column;   /* STACK rows vertically */
  gap: 0.75rem;
  padding: 0.75rem;
}

/* each logical row */
.filter-row {
  display: grid;
  grid-template-columns: 120px 1fr; /* label | fields */
  align-items: center;
  gap: 1rem;
}

/* left column */
.filter-label {
  font-weight: 600;
}

/* right column */
.filter-fields {
  display: flex;
  gap: 1rem;
  align-items: center;
}

/* inputs expand nicely */
.filter-fields input[type="text"] {
  width: 100%;
  max-width: 320px;
}


.full-width {
  width: 100%;
}

.full-width input {
  width: 100%;
}



.transaction-summary {
  margin-bottom: 1rem;
}



.status-ok {
  color: #2e7d32;
  font-weight: bold;
}

.status-partial {
  color: #f9a825;
  font-weight: bold;
}

.status-open {
  color: #c62828;
  font-weight: bold;
}


.transaction-box table {
  border-collapse: collapse;
  margin-top: 8px;
  margin-bottom: 24px;

}

.transaction-box th {
  text-align: left;
  padding-right: 12px;
  font-weight: 600;
  white-space: nowrap;
}

.transaction-box td {
  padding: 2px 0;
}


.suggestions-box {
  padding: 16px;
  margin-bottom: 24px;
  border: 1px solid #ccc;
}

.manual-box {
  padding: 16px;
  border: 1px solid #ccc;
}

/* Pagination */
.pagination {
  margin: 1.5rem 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  font-size: 0.95rem;
}

.pagination a {
  padding: 0.35rem 0.7rem;
  border: 1px solid #ccc;
  color: inherit;
  text-decoration: none;
  border-radius: 4px;
}

.pagination a:hover {
  background-color: #f2f2f2;
}

.pagination span {
  padding: 0.35rem 0.7rem;
  color: #555;
}


.th-status { white-space: nowrap; }

.status-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  color: inherit;
  text-decoration: none;
}

.status-toggle:hover {
  text-decoration: underline;
}

.status-toggle-icon {
  display: inline-flex;
  width: 1.2rem;
  height: 1.2rem;
  align-items: center;
  justify-content: center;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 0.85rem;
  line-height: 1;
}

.th-date { white-space: nowrap; }

.sort-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  color: inherit;
  text-decoration: none;
}

.sort-toggle:hover { text-decoration: underline; }

.sort-icon {
  display: inline-flex;
  width: 1.2rem;
  height: 1.2rem;
  align-items: center;
  justify-content: center;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 0.85rem;
  line-height: 1;
}

