main.panel {
  max-width: 960px;
  margin: 32px auto;
  padding: 28px;
}
main.panel > h1 { margin: 20px 0; }
main.panel form, .workforce-panel form {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  align-items: end;
  margin: 18px 0;
}
main.panel label, .workforce-panel label { display: grid; gap: 8px; }
main.panel input, main.panel select, .workforce-panel input, .workforce-panel select { width: 100%; min-width: 0; }
main.panel button, .workforce-panel button { min-height: 42px; }
#message, #invitation { white-space: pre-wrap; overflow-wrap: anywhere; }
#message:empty, #invitation:empty { display: none; }
#invitation { background: #edf1e8; border-radius: 8px; padding: 16px; }
#employees > section { padding: 20px; margin: 16px 0; }
#employees > section > button { margin: 0 10px 10px 0; }
#forms form { grid-template-columns: 1fr; }
#forms { max-width: 440px; margin: auto; }
@media (max-width: 600px) {
  main.panel { margin: 12px; padding: 18px; }
  main.panel form, .workforce-panel form { grid-template-columns: 1fr; }
}

.workforce-panel { padding: 24px; }
.workforce-panel h2 { margin-top: 20px; }
.workforce-panel #employees > section { margin-bottom: 0; }

.invitation-number { display: block; font-size: 26px; letter-spacing: 2px; }
.invitation-actions { display: flex; flex-wrap: wrap; gap: 10px; margin: 14px 0; }
.invitation-qr { display: block; width: min(240px, 100%); height: auto; margin: 16px auto; background: white; }
.invitation-qr[hidden] { display: none; }

dialog.invitation-screen { position: fixed; inset: 0; margin: 0; width: 100%; max-width: none; height: 100dvh; max-height: none; border: 0; border-radius: 0; padding: 24px; background: white; color: #183c34; }
dialog.invitation-screen::backdrop { background: white; }
.invitation-screen-close { position: sticky; top: 0; display: block; margin-left: auto; min-height: 44px; }
.invitation-screen-content { min-height: calc(100% - 60px); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 24px; text-align: center; }
.invitation-screen-content img { width: min(70vw, 60dvh, 480px); height: auto; }
.invitation-screen-content strong { font-size: clamp(20px, 5vw, 32px); }
.workforce-network { border-block: 1px solid var(--line); margin-block: 24px; padding-block: 8px 24px; }
.allowed-ip-row { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.allowed-ip-row span { overflow-wrap: anywhere; min-width: 0; flex: 1 1 180px; }

body.invitation-only > :not(.invitation-screen) { display: none !important; }

.employee-feedback:empty { display: none; }
.employee-feedback { margin: 4px 0; padding: 12px; border-radius: 8px; background: #fff0e9; color: #843b2e; overflow-wrap: anywhere; }
.employee-feedback[data-status="pending"] { background: #edf1e8; color: #183c34; }

.workforce-attendance { margin: 24px 0; border-bottom: 1px solid var(--line); padding-bottom: 24px; }
.attendance-row { padding: 16px 0; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; }
.attendance-records p { border-bottom: 1px solid var(--line); padding: 12px 0; }
