:root {
  color-scheme: light;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #f5f7fb;
  color: #1c2533;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    linear-gradient(135deg, rgba(35, 117, 255, 0.08), transparent 38%),
    linear-gradient(315deg, rgba(18, 169, 125, 0.08), transparent 42%),
    #f5f7fb;
}

.app {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 40px 0;
}

.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
}

.eyebrow {
  margin: 0 0 6px;
  color: #28715e;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  font-size: clamp(2rem, 5vw, 3.4rem);
  line-height: 1;
}

.file-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid #1d5ed8;
  border-radius: 8px;
  background: #246bfe;
  color: #fff;
  font-weight: 750;
  cursor: pointer;
  white-space: nowrap;
  box-shadow: 0 10px 22px rgba(36, 107, 254, 0.18);
}

.file-button:hover {
  background: #1d5ed8;
}

.file-button input {
  position: absolute;
  inline-size: 1px;
  block-size: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.drop-zone {
  display: grid;
  place-items: center;
  min-height: 170px;
  padding: 28px;
  border: 2px dashed #93a6c5;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.74);
  text-align: center;
  transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.drop-zone.is-over {
  border-color: #12a97d;
  background: #ecfff9;
  transform: translateY(-1px);
}

.drop-zone p {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 750;
}

.drop-zone small {
  display: block;
  margin-top: 8px;
  color: #5e6d82;
}

.status {
  min-height: 22px;
  margin: 16px 0;
  color: #5e6d82;
  font-weight: 650;
}

.status.error {
  color: #b42318;
}

.table-shell {
  overflow: auto;
  /* ~50 lignes visibles (≈ 44px/ligne + l'en-tête), au-delà : scroll vertical */
  max-height: calc(51 * 44px);
  border: 1px solid #d7dfeb;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 18px 42px rgba(21, 33, 56, 0.08);
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 620px;
}

th,
td {
  padding: 12px 14px;
  border-bottom: 1px solid #e7ecf3;
  text-align: left;
  vertical-align: top;
  white-space: pre-wrap;
}

th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #eef4ff;
  color: #23324d;
  font-size: 0.86rem;
  text-transform: uppercase;
}

tr:nth-child(even) td {
  background: #fafcff;
}

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

@media (max-width: 680px) {
  .app {
    width: min(100% - 20px, 1120px);
    padding: 24px 0;
  }

  .toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .file-button {
    width: 100%;
  }
}
