:root {
  color-scheme: light;
  --ink: #18181b;
  --text: #27272a;
  --muted: #71717a;
  --subtle: #a1a1aa;
  --border: #e4e4e7;
  --surface: #ffffff;
  --surface-muted: #fafafa;
  --page: #f7f6f3;
  --accent: #f97316;
  --accent-dark: #c2410c;
  --accent-soft: #fff7ed;
  --primary-action: #03624c;
  --primary-action-hover: #024c3b;
  --primary-action-text: #ffffff;
  --info: #1d4ed8;
  --info-soft: #eff6ff;
  --success: #047857;
  --success-soft: #ecfdf5;
  --danger: #b91c1c;
  --danger-soft: #fef2f2;
  --warning: #a16207;
  --warning-soft: #fffbeb;
  --radius-sm: 6px;
  --radius: 10px;
  --shadow: 0 1px 2px rgb(24 24 27 / 0.05);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  min-width: 320px;
  margin: 0;
  background: var(--page);
  color: var(--text);
  font-size: 15px;
  line-height: 1.5;
}

button,
select {
  font: inherit;
}

button,
select,
a {
  -webkit-tap-highlight-color: transparent;
}

:focus-visible {
  outline: 3px solid rgb(249 115 22 / 0.42);
  outline-offset: 2px;
}

.skip-link {
  position: fixed;
  z-index: 100;
  top: 12px;
  left: 12px;
  transform: translateY(-150%);
  border-radius: var(--radius-sm);
  background: var(--ink);
  color: white;
  padding: 10px 14px;
}

.skip-link:focus {
  transform: translateY(0);
}

.app-header {
  border-bottom: 1px solid #212631;
  background: #212631;
  color: #ffffff;
}

.header-inner,
.page-shell {
  width: min(100% - 48px, 1400px);
  margin-inline: auto;
}

.header-inner {
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: #ffffff;
  text-decoration: none;
}

.brand-logo {
  display: block;
  width: 132px;
  height: auto;
  flex: 0 0 auto;
}

.reviewer-context {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 10px;
}

.reviewer-avatar {
  display: inline-grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 50%;
  background: rgb(255 255 255 / 0.12);
  color: #ffffff;
  font-size: 12px;
  font-weight: 700;
}

.reviewer-identity {
  display: grid;
  line-height: 1.25;
}

.reviewer-identity strong {
  font-size: 13px;
  font-weight: 650;
}

.reviewer-identity span {
  color: #ffffff;
  font-size: 12px;
}

.page-shell {
  padding-block: 42px 64px;
}

.page-intro {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 32px;
  margin-bottom: 24px;
}

.eyebrow {
  margin: 0 0 6px;
  color: var(--primary-action);
  font-size: 12px;
  font-weight: 750;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 8px;
  color: var(--ink);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(30px, 4vw, 40px);
  line-height: 1.15;
}

.page-description {
  max-width: 720px;
  margin-bottom: 0;
  color: var(--muted);
  font-size: 16px;
}

.conference-name {
  display: flex;
  gap: 8px;
  align-items: baseline;
  margin-bottom: 6px;
  color: var(--ink);
}

.conference-name span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 750;
  letter-spacing: 0.055em;
  text-transform: uppercase;
}

.conference-name strong {
  font-size: 14px;
}

.summary-strip {
  margin-bottom: 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.summary-strip dl {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin: 0;
}

.summary-strip dl > div {
  position: relative;
  min-width: 0;
  padding: 17px 20px;
}

.summary-strip dl > div + div::before {
  position: absolute;
  inset: 17px auto 17px 0;
  width: 1px;
  background: var(--border);
  content: "";
}

.summary-strip dt {
  color: var(--muted);
  font-size: 12px;
  font-weight: 650;
}

.summary-strip dd {
  margin: 2px 0 0;
  color: var(--ink);
  font-size: 24px;
  font-weight: 700;
  line-height: 1.2;
}

.summary-strip .summary-attention dd {
  color: var(--danger);
}

.assignments-panel {
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.panel-toolbar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  padding: 20px 22px;
  border-bottom: 1px solid var(--border);
}

.panel-toolbar h2 {
  margin-bottom: 2px;
  color: var(--ink);
  font-size: 19px;
  line-height: 1.3;
}

.panel-toolbar p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 13px;
}

.filter-field {
  display: flex;
  align-items: center;
  gap: 10px;
}

.filter-field label {
  color: var(--muted);
  font-size: 13px;
  font-weight: 650;
  white-space: nowrap;
}

.filter-field select {
  min-height: 40px;
  min-width: 178px;
  border: 1px solid #d4d4d8;
  border-radius: var(--radius-sm);
  background: white;
  color: var(--text);
  padding: 7px 34px 7px 11px;
}

.table-wrap {
  overflow-x: auto;
}

.assignments-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

.assignments-table th,
.assignments-table td {
  padding: 18px 16px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}

.assignments-table th:first-child,
.assignments-table td:first-child {
  padding-left: 22px;
}

.assignments-table th:last-child,
.assignments-table td:last-child {
  padding-right: 22px;
}

.assignments-table th {
  background: var(--surface-muted);
  color: var(--muted);
  font-size: 11px;
  font-weight: 750;
  letter-spacing: 0.055em;
  text-transform: uppercase;
  white-space: nowrap;
}

.assignments-table tbody tr {
  transition: background-color 120ms ease;
}

.assignments-table tbody tr:hover {
  background: #fdfdfc;
}

.assignments-table tbody tr:last-child td {
  border-bottom: 0;
}

.assignments-table tr.is-overdue td:first-child {
  box-shadow: inset 3px 0 0 var(--danger);
}

.assignments-table tr.is-due-soon td:first-child {
  box-shadow: inset 3px 0 0 #f59e0b;
}

.paper-cell {
  min-width: 310px;
  max-width: 500px;
}

.paper-title {
  display: block;
  margin-bottom: 7px;
  color: var(--ink);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 16px;
  font-weight: 650;
  line-height: 1.35;
}

.paper-metadata {
  display: grid;
  gap: 5px;
}

.paper-track,
.paper-keywords {
  display: flex;
  align-items: baseline;
  gap: 7px;
  margin: 0;
}

.paper-metadata-label {
  flex: 0 0 auto;
  color: var(--muted);
  font-size: 10px;
  font-weight: 750;
  letter-spacing: 0.045em;
  text-transform: uppercase;
}

.paper-track strong {
  color: #52525b;
  font-size: 12px;
  font-weight: 650;
}

.paper-keywords {
  align-items: flex-start;
}

.paper-keyword-list {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.paper-keyword-list li {
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface-muted);
  color: #52525b;
  padding: 1px 6px;
  font-size: 10px;
  line-height: 1.45;
}

.cell-muted,
.deadline-note {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

.date-cell,
.deadline-cell {
  min-width: 140px;
  color: #3f3f46;
  font-size: 13px;
  white-space: nowrap;
}

.deadline-note {
  margin-top: 2px;
  font-weight: 650;
}

.deadline-note.overdue {
  color: var(--danger);
}

.deadline-note.due-soon {
  color: var(--warning);
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.status-badge::before {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  content: "";
}

.status-pending {
  border-color: #d6d3d1;
  background: #fafaf9;
  color: #57534e;
}

.status-in-progress {
  border-color: #bfdbfe;
  background: var(--info-soft);
  color: var(--info);
}

.status-completed {
  border-color: #bbf7d0;
  background: #f0fdf4;
  color: #166534;
}

.status-completed::before {
  background: #16a34a;
}

.action-cell {
  width: 1%;
  text-align: right;
  white-space: nowrap;
}

.primary-button,
.secondary-button,
.view-button {
  min-height: 40px;
  border-radius: var(--radius-sm);
  padding: 8px 13px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.primary-button {
  border: 1px solid var(--primary-action);
  background: var(--primary-action);
  color: var(--primary-action-text);
}

.primary-button:hover {
  background: var(--primary-action-hover);
}

.secondary-button,
.view-button {
  border: 1px solid #d4d4d8;
  background: white;
  color: var(--ink);
}

.secondary-button:hover,
.view-button:hover {
  border-color: #a1a1aa;
  background: var(--surface-muted);
}

.empty-state {
  padding: 52px 24px 56px;
  text-align: center;
}

.empty-icon {
  display: inline-grid;
  width: 42px;
  height: 42px;
  margin-bottom: 14px;
  place-items: center;
  border-radius: 50%;
  background: var(--surface-muted);
  color: var(--muted);
  font-size: 20px;
}

.empty-state h3 {
  margin-bottom: 5px;
  color: var(--ink);
  font-size: 17px;
}

.empty-state p {
  margin-bottom: 18px;
  color: var(--muted);
}

.action-notice {
  position: fixed;
  z-index: 20;
  right: 24px;
  bottom: 24px;
  max-width: min(420px, calc(100% - 48px));
  border: 1px solid #d4d4d8;
  border-left: 4px solid var(--accent);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 14px 30px rgb(24 24 27 / 0.16);
  color: var(--text);
  padding: 13px 16px;
  font-size: 13px;
}

.noscript-message {
  margin: 20px;
  border: 1px solid #fcd34d;
  background: var(--warning-soft);
  padding: 12px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  clip-path: inset(50%);
}

@media (max-width: 920px) {
  .header-inner,
  .page-shell {
    width: min(100% - 32px, 1400px);
  }

  .assignments-table th,
  .assignments-table td {
    padding-inline: 12px;
  }

  .assignments-table th:first-child,
  .assignments-table td:first-child {
    padding-left: 18px;
  }

  .assignments-table th:last-child,
  .assignments-table td:last-child {
    padding-right: 18px;
  }

  .paper-cell {
    min-width: 270px;
  }
}

@media (max-width: 760px) {
  .page-shell {
    padding-block: 30px 48px;
  }

  .page-intro {
    display: block;
  }

  .summary-strip dl {
    grid-template-columns: repeat(2, 1fr);
  }

  .summary-strip dl > div:nth-child(3)::before {
    display: none;
  }

  .summary-strip dl > div:nth-child(n + 3) {
    border-top: 1px solid var(--border);
  }

  .panel-toolbar {
    align-items: stretch;
    flex-direction: column;
    gap: 15px;
  }

  .filter-field {
    align-items: stretch;
    flex-direction: column;
    gap: 5px;
  }

  .filter-field select {
    width: 100%;
  }

  .table-wrap {
    overflow: visible;
  }

  .assignments-table,
  .assignments-table tbody,
  .assignments-table tr,
  .assignments-table td {
    display: block;
    width: 100%;
  }

  .assignments-table thead {
    display: none;
  }

  .assignments-table tbody tr {
    padding: 20px;
    border-bottom: 1px solid var(--border);
  }

  .assignments-table tbody tr:last-child {
    border-bottom: 0;
  }

  .assignments-table tr.is-overdue,
  .assignments-table tr.is-due-soon {
    box-shadow: inset 3px 0 0 var(--danger);
  }

  .assignments-table tr.is-due-soon {
    box-shadow: inset 3px 0 0 #f59e0b;
  }

  .assignments-table td,
  .assignments-table td:first-child,
  .assignments-table td:last-child {
    min-width: 0;
    max-width: none;
    padding: 0;
    border: 0;
    box-shadow: none;
    white-space: normal;
  }

  .assignments-table td:not(.paper-cell, .action-cell) {
    display: grid;
    grid-template-columns: minmax(100px, 0.75fr) 1.5fr;
    gap: 14px;
    align-items: start;
    margin-top: 13px;
    font-size: 13px;
  }

  .assignments-table td:not(.paper-cell, .action-cell)::before {
    color: var(--muted);
    content: attr(data-label);
    font-size: 11px;
    font-weight: 750;
    letter-spacing: 0.045em;
    text-transform: uppercase;
  }

  .paper-cell {
    margin-bottom: 18px;
  }

  .paper-title {
    font-size: 17px;
  }

  .action-cell {
    margin-top: 18px;
    text-align: left;
  }

  .primary-button,
  .view-button {
    width: 100%;
  }
}

@media (max-width: 520px) {
  .header-inner,
  .page-shell {
    width: min(100% - 24px, 1400px);
  }

  .header-inner {
    min-height: 62px;
  }

  .brand-name,
  .reviewer-identity strong {
    display: none;
  }

  .reviewer-identity span {
    color: #ffffff;
    font-size: 13px;
    font-weight: 650;
  }

  h1 {
    font-size: 30px;
  }

  .page-description {
    font-size: 14px;
  }

  .summary-strip dl > div {
    padding: 14px 16px;
  }

  .summary-strip dd {
    font-size: 21px;
  }

  .panel-toolbar {
    padding: 18px;
  }

  .assignments-table tbody tr {
    padding: 18px;
  }

  .action-notice {
    right: 12px;
    bottom: 12px;
    max-width: calc(100% - 24px);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}

.auth-actions {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 8px;
}

.auth-sign-out {
  flex: 0 0 auto;
  border: 1px solid rgba(255, 255, 255, 0.45);
  border-radius: 8px;
  padding: 7px 11px;
  background: transparent;
  color: inherit;
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
  cursor: pointer;
}

.auth-sign-out:hover {
  background: rgba(255, 255, 255, 0.1);
}

.auth-sign-out:disabled {
  cursor: wait;
  opacity: 0.65;
}

@media (max-width: 520px) {
  .auth-sign-out {
    padding: 7px 8px;
    font-size: 11px;
  }
}
