* {
  box-sizing: border-box;
}

html {
  font-size: var(--app-density-root, 16px);
}

@font-face {
  font-family: "HDHyundai";
  src: url("/hiris/static/font/HDHyundai/HDHyundai-Light.ttf") format("truetype");
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "HDHyundai";
  src: url("/hiris/static/font/HDHyundai/HDHyundai-Medium.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "HDHyundai";
  src: url("/hiris/static/font/HDHyundai/HDHyundai-Medium.ttf") format("truetype");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "HDHyundai";
  src: url("/hiris/static/font/HDHyundai/HDHyundai-Bold.ttf") format("truetype");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "HDHyundai";
  src: url("/hiris/static/font/HDHyundai/HDHyundai-Bold.ttf") format("truetype");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

body {
  margin: 0;
  font-family: "HDHyundai", "Pretendard", "Noto Sans KR", sans-serif;
  background: #f4f6f8;
  color: #1a1a1a;
}

header {
  background: #0b3d6e;
  color: #fff;
  padding: 1rem 1.5rem;
}

.header-inner {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 1rem;
}

.header-brand {
  margin: 0;
  justify-self: start;
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1.2;
}

.header-title {
  margin: 0;
  justify-self: center;
  text-align: center;
  font-size: 1.25rem;
  font-weight: 700;
  white-space: nowrap;
}

.header-nav {
  display: flex;
  align-items: center;
  justify-self: end;
  gap: 0.75rem;
}

.header-link {
  color: #fff;
  text-decoration: none;
  font-size: 0.875rem;
  padding: 0.45rem 0.75rem;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 6px;
  white-space: nowrap;
}

.header-link:hover {
  background: rgba(255, 255, 255, 0.12);
}

.header-button {
  border: 1px solid rgba(255, 255, 255, 0.35);
  cursor: pointer;
  font: inherit;
}

.header-select {
  min-width: 180px;
  max-width: 280px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 6px;
  padding: 0.45rem 0.75rem;
  background: #fff;
  color: #0f172a;
  font: inherit;
}

.btn-link {
  display: inline-block;
  margin-top: 0.75rem;
  color: #0b3d6e;
  font-weight: 600;
}

header h1 {
  margin: 0;
  font-size: 1.25rem;
}

.layout {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 1rem;
  padding: 1rem;
  min-height: calc(100vh - 72px);
}

.panel {
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
  padding: 1rem;
}

.panel h2 {
  margin: 0 0 0.75rem;
  font-size: 1rem;
}

.row {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

input[type="text"],
select {
  flex: 1;
  padding: 0.5rem 0.75rem;
  border: 1px solid #d0d7de;
  border-radius: 6px;
  font-size: 0.875rem;
}

button {
  padding: 0.5rem 0.875rem;
  border: none;
  border-radius: 6px;
  background: #0b3d6e;
  color: #fff;
  font-size: 0.875rem;
  cursor: pointer;
}

button:hover {
  background: #094a86;
}

button.secondary {
  background: #6c757d;
}

button.secondary:hover {
  background: #5a6268;
}

button.danger {
  background: #dc3545;
}

button.danger:hover {
  background: #c82333;
}

button.small {
  padding: 0.25rem 0.5rem;
  font-size: 0.75rem;
}

button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.empty {
  color: #888;
  font-size: 0.875rem;
}

.report-box {
  background: #f8f9fa;
  border: 1px solid #e9ecef;
  border-radius: 8px;
  padding: 1rem;
  line-height: 1.6;
  font-size: 0.9rem;
}

.report-section {
  margin-bottom: 1rem;
}

.report-section:last-child {
  margin-bottom: 0;
}

.report-section h3 {
  font-size: 0.85rem;
  color: #555;
  margin: 0 0 0.35rem;
  font-weight: 600;
}

.report-summary {
  margin: 0;
  white-space: pre-wrap;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.tag {
  display: inline-block;
  padding: 0.2rem 0.5rem;
  background: rgba(0, 130, 51, 0.12);
  color: #008233;
  border-radius: 999px;
  font-size: 0.75rem;
}

.question-list {
  margin: 0;
  padding-left: 1.25rem;
  font-size: 0.875rem;
}

.question-list li {
  margin-bottom: 0.35rem;
}

.question-list li.question-item.is-expanded {
  margin-bottom: 0.65rem;
}

.question-list li:last-child {
  margin-bottom: 0;
}

.question-reveal {
  display: grid;
  gap: 0.75rem;
}

.detail-section-headline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.55rem;
}

.detail-section-headline h3 {
  margin-bottom: 0;
}

.common-question-stage {
  display: grid;
  grid-template-columns: minmax(2.75rem, 1fr) minmax(0, 3fr) minmax(2.75rem, 1fr);
  align-items: center;
  column-gap: 0.75rem;
  min-width: 0;
}

.common-question-nav {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.35rem;
  height: 2.35rem;
  min-width: 2.35rem;
  padding: 0;
  border: 1px solid #dbe4ee;
  border-radius: 50%;
  background: #fff;
  color: #0b3d6e;
  font-size: 0;
  font-weight: 800;
  line-height: 1;
  box-shadow: 0 2px 7px rgba(15, 23, 42, 0.08);
}

.common-question-nav span {
  position: relative;
  display: block;
  width: 0.64rem;
  height: 0.64rem;
  line-height: 0;
  transform: none;
}

.common-question-nav span::before {
  content: "";
  position: absolute;
  inset: 0;
  border-top: 2px solid currentColor;
  border-right: 2px solid currentColor;
}

.common-question-wing--prev span::before {
  transform: rotate(225deg);
}

.common-question-wing--next span::before {
  transform: rotate(45deg);
}

.common-question-wing--prev {
  grid-column: 1;
  justify-self: end;
}

.common-question-wing--next {
  grid-column: 3;
  justify-self: start;
}

.common-question-nav:hover:not(:disabled),
.common-question-nav:focus-visible:not(:disabled) {
  background: #eef7f8;
  color: #0e6075;
  outline: none;
}

.common-question-nav:focus-visible:not(:disabled) {
  box-shadow: 0 0 0 3px rgba(14, 116, 144, 0.18);
}

.common-question-nav:disabled {
  color: #b8c1cc;
  cursor: default;
}

.common-question-pager {
  grid-column: 2;
  min-width: 0;
}

.common-question-page {
  min-height: 0;
}

.common-question-page[hidden] {
  display: none;
}

.detail-common-question-section {
  padding-bottom: 0;
}

.detail-questions li[hidden] {
  display: none;
}

.question-reveal-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
}

.question-more-btn,
.question-collapse-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  min-height: 34px;
  min-width: 0;
  padding: 0.3rem 0.72rem 0.3rem 0.38rem;
  border: 1px solid #dbe4ee;
  border-radius: 999px;
  background: #fff;
  color: #344054;
  font-size: 0.8rem;
  font-weight: 700;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06);
}

.question-reveal-actions button[hidden] {
  display: none;
}

.question-collapse-btn {
  padding-right: 0.78rem;
  border-color: #e4e8ef;
  color: #475467;
}

.question-more-btn:hover,
.question-more-btn:focus-visible,
.question-collapse-btn:hover,
.question-collapse-btn:focus-visible {
  border-color: #a8d8e3;
  background: #eef7f8;
  color: #0e6075;
}

.question-more-btn:focus-visible,
.question-collapse-btn:focus-visible {
  outline: 3px solid rgba(14, 116, 144, 0.18);
  outline-offset: 2px;
}

.question-more-icon,
.question-collapse-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.35rem;
  height: 1.35rem;
  border-radius: 999px;
  background: #e6f3f6;
  color: #0e6075;
  font-size: 1rem;
  line-height: 1;
}

.question-collapse-icon {
  background: #eef2f7;
  color: #475467;
}

.question-more-count {
  color: #667085;
  font-size: 0.76em;
  font-weight: 700;
}

.report-empty {
  color: #888;
  font-size: 0.85rem;
}

.text-preview {
  margin-top: 0.5rem;
  padding: 0.75rem;
  background: #fafafa;
  border-radius: 6px;
  font-size: 0.8rem;
  color: #444;
  max-height: 120px;
  overflow-y: auto;
  white-space: pre-wrap;
}

.message {
  padding: 0.75rem;
  border-radius: 6px;
  font-size: 0.875rem;
  margin: 1rem 1rem 0;
}

.message.error {
  background: #f8d7da;
  color: #721c24;
}

.message.info {
  background: #d1ecf1;
  color: #0c5460;
}

.loading {
  display: inline-block;
  width: 14px;
  height: 14px;
  border: 2px solid #fff;
  border-top-color: transparent;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  vertical-align: middle;
  margin-right: 0.35rem;
}

.loading.dark {
  border-color: #856404;
  border-top-color: transparent;
  margin-right: 0;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

#detail-panel {
  max-height: calc(100vh - 72px);
  overflow-y: auto;
}

.panel-desc {
  margin: 0 0 1rem;
  font-size: 0.85rem;
  color: #666;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal[hidden] {
  display: none;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
}

.modal-box {
  position: relative;
  background: #fff;
  border-radius: 12px;
  padding: 1.5rem;
  min-width: 280px;
  max-width: 90vw;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.18);
  text-align: center;
}

.modal-box h3 {
  margin: 0 0 0.75rem;
  font-size: 1.1rem;
}

.modal-box p {
  margin: 0 0 1.25rem;
  color: #444;
  line-height: 1.5;
}

.modal-box button:not(.modal-close) {
  min-width: 100px;
}

@media (max-width: 900px) {
  .layout {
    grid-template-columns: 1fr;
  }

  .dashboard-layout {
    grid-template-columns: 1fr;
  }

  .interview-layout {
    height: auto;
    min-height: calc(100dvh - 88px);
    overflow: visible;
  }

  .card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* ── Dashboard ─────────────────────────────────────── */
.dashboard-layout {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 1rem;
  padding: 1rem;
  min-height: calc(100vh - 88px);
  align-items: start;
}

.sidebar-panel {
  position: sticky;
  top: 1rem;
  max-height: calc(100vh - 104px);
  overflow-y: auto;
}

.sidebar-toolbar {
  margin-bottom: 1rem;
}

.filter-label {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: #444;
  margin-bottom: 0.75rem;
}

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

.sidebar-section {
  margin-bottom: 1.25rem;
  padding-top: 1rem;
  border-top: 1px solid #eee;
}

.sidebar-section h2 {
  margin: 0 0 0.35rem;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.count-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.5rem;
  padding: 0.1rem 0.45rem;
  border-radius: 999px;
  background: #eef4fa;
  color: #0b3d6e;
  font-size: 0.75rem;
}

.mini-list {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: 220px;
  overflow-y: auto;
}

.mini-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0.35rem;
  border-bottom: 1px solid #f0f0f0;
  font-size: 0.8rem;
}

.mini-id {
  font-family: monospace;
  color: #888;
  font-size: 0.7rem;
  flex-shrink: 0;
}

.mini-name {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mini-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #6c757d;
  flex-shrink: 0;
}

.mini-dot.analyzed {
  background: #0d6efd;
}

.group-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.group-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #f8f9fa;
  color: #1a1a1a;
  border: 1px solid #e9ecef;
  padding: 0.55rem 0.75rem;
  font-size: 0.85rem;
}

.group-btn:hover {
  background: #eef4fa;
}

.group-btn.active {
  background: #0b3d6e;
  color: #fff;
  border-color: #0b3d6e;
}

.group-count {
  font-size: 0.75rem;
  opacity: 0.85;
}

.board-panel {
  min-height: 520px;
}

.board-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.board-header h2 {
  margin: 0;
}

.board-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 3rem 1rem;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.modal-open {
  overflow: hidden;
}

.modal-box-wide {
  width: min(720px, 92vw);
  max-height: 88vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  text-align: left;
}

.modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.modal-head h2 {
  margin: 0 0 0.25rem;
}

.modal-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.modal-body {
  overflow-y: auto;
  text-align: left;
  max-height: calc(88vh - 120px);
}

.report-loading {
  color: #666;
  font-size: 0.9rem;
}

body.dashboard-page .modal-box .header-link {
  color: #0b3d6e;
  border-color: #ced4da;
}

/* ── Mockup UI (면접 대시보드) ─────────────────────── */
.mockup-ui {
  background: #eef1f5;
}

.app-header {
  background: linear-gradient(90deg, #0b3d6e 0%, #125a9c 100%);
}

.interview-layout {
  display: grid;
  grid-template-columns: minmax(360px, 1fr) minmax(0, 1fr);
  gap: 1rem;
  padding: 1rem;
  height: calc(100dvh - 88px);
  min-height: 0;
  align-items: stretch;
  overflow: hidden;
}

.db-panel {
  padding: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.db-panel-head {
  background: #0b3d6e;
  color: #fff;
  padding: 0.75rem 1rem;
}

.db-panel-head h2 {
  margin: 0;
  font-size: var(--dashboard-title-size);
  font-weight: 700;
}

.head-sub {
  font-weight: 400;
  opacity: 0.85;
  font-size: var(--dashboard-body-size);
}

.db-toolbar {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid #e9ecef;
  background: #fff;
  align-items: start;
}

.db-toolbar-search {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-width: 0;
}

.db-toolbar input {
  min-width: 0;
}

#search-input {
  font-size: var(--dashboard-body-size);
  flex: 1;
  min-width: 0;
}

.semantic-search-row {
  display: flex;
  gap: 0.4rem;
  align-items: center;
  min-width: 0;
}

.semantic-search-row .primary.small {
  flex-shrink: 0;
  white-space: nowrap;
}

.filter-select {
  min-width: 120px;
}

.db-table-wrap {
  overflow: auto;
  flex: 1;
  background: #fff;
}

.db-table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--dashboard-label-size);
  min-width: 780px;
}

.db-table thead {
  position: sticky;
  top: 0;
  background: #f8f9fa;
  z-index: 1;
}

.db-table th,
.db-table td {
  padding: 0.55rem 0.5rem;
  border-bottom: 1px solid #f0f0f0;
  text-align: left;
  vertical-align: middle;
}

.db-table th {
  font-weight: 600;
  color: #555;
  white-space: nowrap;
}

.db-table .col-check {
  width: 36px;
  text-align: center;
}

.db-table .col-photo {
  width: 48px;
}

.sidebar-block {
  padding: 0.75rem 1rem;
  border-top: 1px solid #e9ecef;
  background: #fff;
}

.sidebar-block-title {
  margin: 0 0 0.5rem;
  font-size: var(--dashboard-body-size);
  font-weight: 700;
  color: #333;
}

.group-block {
  background: #fafbfc;
  flex-shrink: 0;
}

.group-block-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}

.group-block-head .sidebar-block-title {
  margin: 0;
}

.group-pagination {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.group-pagination[hidden] {
  display: none;
}

.group-pagination .page-nav-btn {
  width: 26px;
  height: 26px;
  font-size: 1rem;
}

.interview-group-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.interview-group-btn {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: #fff;
  color: #1a1a1a;
  border: 1px solid #dee2e6;
  padding: 0.5rem 0.75rem;
  font-size: var(--dashboard-label-size);
  font-weight: 600;
  border-radius: 6px;
  text-align: left;
}

.interview-group-btn:hover {
  background: #eef4fa;
  border-color: #0b3d6e;
}

.interview-group-btn.active {
  background: #0b3d6e;
  color: #fff;
  border-color: #0b3d6e;
}

.group-btn-num {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(11, 61, 110, 0.1);
  color: #0b3d6e;
  font-size: 0.72rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.interview-group-btn.active .group-btn-num {
  background: rgba(255, 255, 255, 0.25);
  color: #fff;
}

.group-btn-label {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.members-block {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.members-block .db-table-wrap {
  max-height: none;
  overflow: auto;
  flex: 1;
  min-height: 0;
}

.members-block .db-table {
  font-size: var(--dashboard-label-size);
}

.db-row {
  cursor: pointer;
}

.db-row:hover {
  background: #f8fbff;
}

.db-row.selected {
  background: #eef4fa;
}

.col-name {
  font-weight: 600;
  white-space: nowrap;
}

.db-table .small-cell {
  max-width: 150px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.col-field {
  max-width: 140px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.muted-cell {
  color: #888;
}

.db-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  border-top: 1px solid #e9ecef;
  background: #fafbfc;
}

.selection-pill {
  font-size: 0.8rem;
  font-weight: 600;
  color: #0b3d6e;
  background: #e7f1ff;
  padding: 0.35rem 0.65rem;
  border-radius: 999px;
  white-space: nowrap;
}

.cards-panel {
  padding: 1rem;
  min-height: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.cards-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1rem;
  width: 100%;
  max-width: 660px;
}

.cards-panel-head h2 {
  margin: 0;
  font-size: var(--dashboard-title-size);
}

.cards-panel-tools {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.dashboard-text-prefs {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.dashboard-text-label {
  flex-shrink: 0;
  color: #4a5568;
  font-size: var(--dashboard-label-size);
  font-weight: 700;
}

.dashboard-text-seg {
  display: inline-flex;
  border: 1px solid #c5d4e4;
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
}

.dashboard-text-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.5rem;
  min-height: 2.5rem;
  margin: 0;
  padding: 0.5rem 0.72rem;
  border: 0;
  border-right: 1px solid #c5d4e4;
  border-radius: 0;
  background: #fff;
  color: #4a5568;
  line-height: 1;
}

.dashboard-text-btn:last-child {
  border-right: 0;
}

.dashboard-text-btn:hover {
  background: #eef4fa;
  color: #0b3d6e;
}

.dashboard-text-btn.active {
  background: #0b3d6e;
  color: #fff;
}

.dashboard-text-btn:focus-visible {
  outline: 2px solid #0b3d6e;
  outline-offset: -2px;
  z-index: 1;
}

.dashboard-size-a {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 800;
  line-height: 1;
}

.dashboard-size-sm { font-size: 0.85rem; }
.dashboard-size-md { font-size: 1.15rem; }
.dashboard-size-lg { font-size: 1.45rem; }

.db-toolbar-extra {
  padding: 0 1rem 0.75rem;
  border-bottom: 1px solid #e9ecef;
  background: #fff;
}

.db-toolbar-extra .exclude-toggle {
  width: 100%;
}

.cards-panel-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-shrink: 0;
}

.exclude-toggle.active {
  background: #dc3545;
  color: #fff;
}

.exclude-toggle.active:hover {
  background: #c82333;
}

.card-exclude-btn,
.row-exclude-btn {
  display: none;
}

.exclude-mode .card-exclude-btn {
  display: flex;
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 3;
  width: 26px;
  height: 26px;
  border: none;
  border-radius: 50%;
  background: #dc3545;
  color: #fff;
  font-size: 1rem;
  line-height: 1;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(220, 53, 69, 0.35);
}

.card-exclude-btn:hover {
  background: #c82333;
}

.exclude-mode .row-exclude-btn {
  display: inline-flex;
  margin-left: 0.35rem;
  width: 20px;
  height: 20px;
  border: none;
  border-radius: 50%;
  background: #dc3545;
  color: #fff;
  font-size: 0.85rem;
  line-height: 1;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  vertical-align: middle;
}

.row-exclude-btn:hover {
  background: #c82333;
}

.exclude-mode .db-row {
  cursor: default;
}

.card-pagination {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.page-nav-btn {
  width: 30px;
  height: 30px;
  padding: 0;
  border-radius: 50%;
  background: #fff;
  color: #0b3d6e;
  border: 1px solid #cdd6e0;
  font-size: 1.1rem;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.page-nav-btn:hover:not(:disabled) {
  background: #eef4fa;
  border-color: #0b3d6e;
}

.page-nav-btn:disabled {
  color: #c3c9d1;
  border-color: #e5e9ef;
  cursor: not-allowed;
}

.page-info-text {
  font-size: 0.8rem;
  font-weight: 600;
  color: #555;
  min-width: 40px;
  text-align: center;
}

.card-num {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 2;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #0b3d6e;
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* 기본형: 중앙 팝업 (관리자 지원서 보기 등) */
.detail-modal-box {
  width: min(1100px, 94vw);
  max-height: 92vh;
  overflow: hidden;
  text-align: left;
  padding: 1.5rem 1.75rem;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 0.5rem;
}

/* 전체화면형: 대시보드 면접자 상세 팝업 */
.detail-modal-box.detail-modal-fullscreen {
  position: relative;
  width: 100vw;
  height: 100vh;
  max-width: none;
  max-height: none;
  border-radius: 0;
  padding: 1.1rem 1.75rem 1.5rem;
}

/* 세로 구분선: 모달 전체 높이와 동일, 접히면 숨김 */
.detail-modal-box.detail-modal-fullscreen::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: calc(1.75rem + 280px);
  width: 1px;
  background: #e4e8ee;
  pointer-events: none;
  z-index: 5;
}

.detail-modal-box.detail-modal-fullscreen.sidebar-collapsed::after {
  display: none;
}

/* 좌·우 통합 세로 스크롤 (개별 스크롤 제거, 드로어 접기는 유지) */
.detail-modal-box.detail-modal-fullscreen .detail-layout {
  overflow-x: hidden;
  overflow-y: auto;
  align-items: start;
  gap: 0;
  overscroll-behavior: contain;
}

.detail-modal-box.detail-modal-fullscreen .detail-sidebar {
  max-height: none;
  overflow: visible;
  border-right: none;
  padding-right: 1.5rem;
}

.detail-modal-box.detail-modal-fullscreen .detail-sidebar-body {
  overflow: visible;
  flex: 0 0 auto;
}

.detail-modal-box.detail-modal-fullscreen .detail-main,
.detail-modal-box.detail-modal-fullscreen .detail-main-panels,
.detail-modal-box.detail-modal-fullscreen .detail-panel {
  overflow: visible;
  height: auto;
}

.detail-modal-box.detail-modal-fullscreen .detail-main {
  padding-left: 1.5rem;
}

.detail-modal-box.detail-modal-fullscreen .detail-layout.sidebar-collapsed {
  grid-template-columns: 0 minmax(0, 1fr);
  gap: 0;
}

.detail-modal-box.detail-modal-fullscreen .detail-layout.sidebar-collapsed .detail-main {
  padding-left: 0;
}

.detail-modal-box.detail-modal-fullscreen .detail-layout.sidebar-collapsed .detail-sidebar {
  padding-right: 0;
}

.detail-modal-box.detail-modal-fullscreen .detail-body {
  flex: none;
  max-height: none;
  overflow: visible;
}

.detail-modal-box.detail-modal-fullscreen .toggle-original-btn {
  margin-top: 0.75rem;
}

/* X 버튼과 같은 줄: 좌측 << / 우측 닫기 */
.detail-modal-box.detail-modal-fullscreen .detail-modal-chrome {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
  min-height: 32px;
  margin: -0.25rem 0 0.15rem;
}

.detail-modal-box.detail-modal-fullscreen button.detail-sidebar-toggle {
  position: static;
  top: auto;
  right: auto;
  left: auto;
  transform: none;
  align-self: auto;
  margin: 0;
  min-width: 32px;
  width: 32px;
  height: 32px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: transparent;
  color: #b0b8c1;
  box-shadow: none;
  z-index: 30;
}

.detail-modal-box.detail-modal-fullscreen button.detail-sidebar-toggle:hover,
.detail-modal-box.detail-modal-fullscreen button.detail-sidebar-toggle:focus-visible {
  color: #0b3d6e;
  background: #f1f3f5;
  border: none;
  box-shadow: none;
  outline: none;
}

.detail-modal-box.detail-modal-fullscreen .detail-sidebar-toggle-icon {
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: -0.08em;
  line-height: 1;
}

.detail-modal-box.detail-modal-fullscreen .detail-modal-chrome .modal-close {
  justify-self: auto;
  align-self: auto;
  margin: 0;
}

.detail-layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 1.75rem;
  min-height: 0;
  overflow: hidden;
  transition: grid-template-columns 0.14s ease, gap 0.14s ease;
}

.detail-layout.sidebar-open-instant {
  transition: none !important;
}

.detail-sidebar {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  padding-right: 1.5rem;
  border-right: 1px solid #e4e8ee;
  max-height: 100%;
  overflow: visible;
  min-width: 0;
}

.detail-sidebar-body {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  min-height: 0;
  flex: 1;
  overflow-y: auto;
}

/* 좌측 컬럼 접기: 구분선 중앙에 얹히는 둥근 핸들 */
.modal-box button.detail-sidebar-toggle {
  position: absolute;
  top: 50%;
  right: -15px;
  transform: translateY(-50%);
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 30px;
  width: 30px;
  height: 30px;
  padding: 0;
  border: 1px solid #c5d4e4;
  border-radius: 50%;
  background: #eef4fa;
  color: #0b3d6e;
  cursor: pointer;
  box-shadow: 0 1px 4px rgba(11, 61, 110, 0.16);
  transition: color 0.15s ease, border-color 0.15s ease, background-color 0.15s ease, box-shadow 0.15s ease;
}

.modal-box button.detail-sidebar-toggle:hover,
.modal-box button.detail-sidebar-toggle:focus-visible {
  color: #fff;
  border-color: #0b3d6e;
  background: #0b3d6e;
  box-shadow: 0 2px 8px rgba(11, 61, 110, 0.28);
  outline: none;
}

.detail-sidebar-toggle-icon {
  font-size: 1.2rem;
  font-weight: 700;
  line-height: 1;
}

.detail-layout.sidebar-collapsed {
  grid-template-columns: 30px minmax(0, 1fr);
  gap: 1rem;
}

.detail-layout.sidebar-collapsed .detail-sidebar {
  padding-right: 0;
  border-right: none;
  overflow: visible;
}

.detail-layout.sidebar-collapsed .detail-sidebar-body {
  display: none;
}

.detail-layout.sidebar-collapsed .detail-sidebar-toggle {
  right: auto;
  left: 0;
}

.detail-main {
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* 분석 패널(왼쪽) + 지원서 원문 패널(오른쪽) 나란히 배치 */
.detail-main-panels {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1.5rem;
  min-height: 0;
  height: 100%;
  overflow: hidden;
}

.detail-main-panels.split {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

.detail-panel {
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.detail-panel[hidden] {
  display: none;
}

.detail-panel-application {
  border-left: 1px solid #e4e8ee;
  padding-left: 1.5rem;
}

.detail-panel-title {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin: 0 0 0.75rem;
  padding-bottom: 0.6rem;
  border-bottom: 1px solid #edf0f4;
  font-size: 0.95rem;
  font-weight: 700;
  color: #0b3d6e;
  flex-shrink: 0;
}

.modal-box button.modal-close {
  position: static;
  justify-self: end;
  align-self: start;
  margin: -0.25rem -0.25rem 0 0;
}

.icon-close-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: unset;
  max-width: unset;
  width: 32px;
  height: 32px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: transparent;
  color: #b0b8c1;
  cursor: pointer;
  transition: background-color 0.15s ease;
}

.icon-close-btn svg {
  width: 24px;
  height: 24px;
  display: block;
}

.icon-close-btn:hover,
.icon-close-btn:focus-visible {
  background: #f1f3f5;
  outline: none;
}

.detail-photo {
  width: 100%;
  height: 240px;
  object-fit: contain;
  object-position: center center;
  border-radius: 8px;
  border: 1px solid #e0e0e0;
  background: #f0f2f5;
}

.detail-name-row {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
}

.detail-name-row h2 {
  margin: 0;
  font-size: 1.25rem;
}

.detail-index {
  color: #0b3d6e;
  font-weight: 700;
}

.detail-exam-no {
  margin: 0;
  font-size: 0.85rem;
  font-weight: 600;
  color: #2f3742;
}

.detail-meta {
  margin: 0;
  display: grid;
  gap: 0.4rem;
}

.detail-meta-row {
  display: flex;
  gap: 0.5rem;
  align-items: baseline;
  font-size: 0.85rem;
}

.detail-meta-row dt {
  flex: 0 0 42px;
  color: #0b3d6e;
  font-weight: 700;
}

.detail-meta-row dd {
  margin: 0;
  color: #2f3742;
  word-break: keep-all;
}

.detail-role {
  margin: 0.1rem 0;
  color: #444;
  font-size: 0.85rem;
}

.detail-contact {
  margin: 0;
  font-size: 0.78rem;
  color: #666;
  word-break: break-all;
}

.detail-sidebar-summary {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding-top: 0.5rem;
  border-top: 1px solid #edf0f4;
}

.detail-sidebar-summary-title {
  font-size: 0.8rem;
  font-weight: 700;
  color: #0b3d6e;
}

.detail-career-summary {
  margin: 0;
  font-size: 0.8rem;
  line-height: 1.45;
  color: #2f3742;
  word-break: keep-all;
}

.detail-sidebar-keywords {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  padding-top: 0.5rem;
  border-top: 1px solid #edf0f4;
}

.detail-sidebar-keywords-title {
  font-size: 0.8rem;
  font-weight: 700;
  color: #0b3d6e;
}

.detail-sidebar-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

#modal-keywords.detail-sidebar-tags {
  flex-direction: column;
  flex-wrap: nowrap;
  gap: 0.55rem;
}

.detail-keyword-group {
  display: flex;
  flex-direction: column;
  gap: 0.28rem;
}

.detail-keyword-group-title {
  font-size: 0.72rem;
  font-weight: 700;
  color: #5c6675;
}

.keyword-tag {
  cursor: pointer;
  font: inherit;
  border: 1px solid #cfe8dd;
  background: #eff8f3;
  color: #12663f;
}

.keyword-tag:hover,
.keyword-tag:focus-visible {
  background: #eff8f3;
  color: #12663f;
  border-color: #0f7a4a;
  box-shadow: 0 0 0 2px #0f7a4a;
}

.detail-sidebar-tags-empty {
  font-size: 0.78rem;
  color: #97a0ac;
}

.toggle-original-btn {
  margin-top: auto;
  cursor: pointer;
  border: 1px solid transparent;
  width: 100%;
}

.toggle-original-btn.active {
  background: #fff;
  color: #0b3d6e;
  border-color: #0b3d6e;
}

.detail-body {
  flex: 1;
  min-height: 0;
  max-height: 100%;
  overflow-y: auto;
  padding-right: 0.25rem;
}

.detail-application-panel {
  background: #fbfcfe;
}

.detail-panel-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.85rem;
  padding-bottom: 0.65rem;
  border-bottom: 1px solid #edf0f4;
}

.detail-panel-head h3 {
  margin: 0;
  color: #0b3d6e;
  font-size: 1rem;
}

.detail-panel-sub {
  color: #7a8491;
  font-size: 0.75rem;
  white-space: nowrap;
}

.application-original {
  font-size: 0.82rem;
  line-height: 1.5;
}

.application-doc {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.application-block {
  border: 1px solid #e6eaf0;
  border-radius: 10px;
  background: #fff;
  overflow: hidden;
}

.application-block-title {
  margin: 0;
  padding: 0.55rem 0.85rem;
  font-size: 0.82rem;
  font-weight: 700;
  color: #0b3d6e;
  background: #f4f7fb;
  border-bottom: 1px solid #e6eaf0;
}

.application-block-body {
  padding: 0.75rem 0.85rem;
}

.application-block--structured .application-block-body {
  background: #fbfcfe;
}

.application-block--essay .application-block-body {
  padding: 0;
}

.application-essay-text {
  margin: 0;
  padding: 0.78rem 0.85rem;
  color: #2f3742;
  line-height: 1.65;
  white-space: pre-wrap;
  word-break: break-word;
}

.application-record-list {
  display: grid;
  gap: 0.65rem;
}

.application-record-card {
  display: grid;
  gap: 0.58rem;
  min-width: 0;
  padding: 0.72rem;
  border: 1px solid #edf0f4;
  border-radius: 8px;
  background: #fff;
}

.application-record-card h5 {
  margin: 0;
  color: #111827;
  font-size: 0.84rem;
  font-weight: 800;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.application-record-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.5rem;
  margin: 0;
}

.application-record-row {
  min-width: 0;
  padding: 0.5rem 0.56rem;
  border: 1px solid #eef2f7;
  border-radius: 7px;
  background: #fbfcfe;
}

.application-record-row.is-long {
  grid-column: 1 / -1;
}

.application-record-row dt {
  margin: 0 0 0.16rem;
  color: #0b3d6e;
  font-size: 0.73rem;
  font-weight: 800;
  word-break: keep-all;
}

.application-record-row dd {
  margin: 0;
  color: #2f3742;
  line-height: 1.5;
  white-space: pre-wrap;
  word-break: break-word;
}

.application-flat-row {
  display: grid;
  grid-template-columns: minmax(90px, 0.32fr) minmax(0, 1fr);
  gap: 0.75rem;
  padding: 0.55rem 0.85rem;
  border: 1px solid #eef1f5;
  border-radius: 8px;
  background: #fff;
}

.application-flat-key {
  color: #0b3d6e;
  font-weight: 700;
  word-break: keep-all;
}

.application-flat-val {
  color: #2f3742;
  word-break: break-word;
  white-space: pre-wrap;
}

/* 지원서 원문 하이라이트: 단색 통일 + 강조 테두리 */
.application-source-highlight {
  --source-highlight-bg: #d8f5e8;
  --source-highlight-border: #0f9f6e;
  border: 3px solid var(--source-highlight-border) !important;
  background: var(--source-highlight-bg) !important;
  box-shadow: none;
  scroll-margin-top: 0.85rem;
}

/* 안쪽 면은 같은 배경만 맞추고, 굵은 테두리는 최외곽에만 유지 */
.application-source-highlight .application-block-title,
.application-source-highlight .resume-section-head,
.application-source-highlight .resume-field,
.application-source-highlight .resume-nested-card,
.application-source-highlight .resume-record-list,
.application-source-highlight .resume-record-card,
.application-source-highlight .resume-record-row,
.application-source-highlight .resume-table-wrap,
.application-source-highlight .resume-long-field,
.application-source-highlight .resume-essay,
.application-source-highlight .resume-table th,
.application-source-highlight .resume-table td,
.application-source-highlight .application-record-card,
.application-source-highlight .application-record-row,
.application-source-highlight .application-flat-row {
  border-color: rgba(15, 159, 110, 0.28) !important;
  border-width: 1px !important;
  background: var(--source-highlight-bg, #d8f5e8) !important;
  box-shadow: none !important;
}

.application-source-highlight .resume-section-head h4,
.application-source-highlight .resume-section-head span,
.application-source-highlight .application-block-title {
  color: #0b6b45;
}

/* 테이블: border-collapse 때문에 border 굵기가 잘 안 먹음 → 행은 inset box-shadow로 외곽 표시 */
.resume-table-wrap.application-source-highlight {
  border: 3px solid var(--source-highlight-border, #0f9f6e) !important;
  outline: none;
  box-shadow: none;
}

.resume-table-wrap.application-source-highlight .resume-table {
  border-collapse: separate;
  border-spacing: 0;
}

.resume-table-wrap.application-source-highlight .resume-table th,
.resume-table-wrap.application-source-highlight .resume-table td {
  border-color: rgba(15, 159, 110, 0.22) !important;
}

.resume-table tbody tr.application-source-highlight {
  --source-highlight-bg: #d8f5e8;
  --source-highlight-border: #0f9f6e;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  outline: none !important;
}

.resume-table tbody tr.application-source-highlight > td {
  background: var(--source-highlight-bg, #d8f5e8) !important;
  border-color: rgba(15, 159, 110, 0.2) !important;
  scroll-margin-top: 0.85rem;
  box-shadow:
    inset 0 3px 0 0 var(--source-highlight-border, #0f9f6e),
    inset 0 -3px 0 0 var(--source-highlight-border, #0f9f6e) !important;
}

.resume-table tbody tr.application-source-highlight > td:first-child:not(:last-child) {
  box-shadow:
    inset 3px 0 0 0 var(--source-highlight-border, #0f9f6e),
    inset 0 3px 0 0 var(--source-highlight-border, #0f9f6e),
    inset 0 -3px 0 0 var(--source-highlight-border, #0f9f6e) !important;
}

.resume-table tbody tr.application-source-highlight > td:last-child:not(:first-child) {
  box-shadow:
    inset -3px 0 0 0 var(--source-highlight-border, #0f9f6e),
    inset 0 3px 0 0 var(--source-highlight-border, #0f9f6e),
    inset 0 -3px 0 0 var(--source-highlight-border, #0f9f6e) !important;
}

/* 부모 wrap이 하이라이트된 경우 안쪽 행 굵은 테두리는 끈다(이중 방지 보조) */
.resume-table-wrap.application-source-highlight tbody tr.application-source-highlight > td,
.resume-table-wrap.application-source-highlight tbody tr.application-source-highlight > td:first-child:not(:last-child),
.resume-table-wrap.application-source-highlight tbody tr.application-source-highlight > td:last-child:not(:first-child),
.resume-table-wrap.application-source-highlight tbody tr.application-source-highlight > td:first-child:last-child {
  box-shadow: none !important;
}

.resume-original {
  color: #1f2933;
}

.resume-document {
  display: grid;
  gap: 0.9rem;
}

.resume-section {
  border: 1px solid #e1e7ef;
  border-radius: 10px;
  background: #fff;
  overflow: hidden;
}

.resume-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.58rem 0.85rem;
  border-bottom: 1px solid #c5d0de;
  background: #dce6f2;
}

.resume-section-head h4 {
  margin: 0;
  color: #0b3d6e;
  font-size: 0.9rem;
  font-weight: 800;
}

.resume-section-head span {
  color: #4a5568;
  font-size: 0.76rem;
  font-weight: 700;
}

.resume-section-body {
  display: grid;
  gap: 0.7rem;
  padding: 0.85rem;
}

.resume-field-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.55rem;
  margin: 0;
}

.resume-field-grid.identity,
.resume-field-grid.military {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.resume-field-grid.compact {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.resume-field-grid.roomy,
.resume-field-grid.remaining {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.resume-field {
  min-width: 0;
  padding: 0.52rem 0.62rem;
  border: 1px solid #edf0f4;
  border-radius: 8px;
  background: #fff;
}

.resume-field.wide {
  grid-column: 1 / -1;
}

.resume-field dt {
  margin: 0 0 0.18rem;
  color: #0b3d6e;
  font-size: 0.74rem;
  font-weight: 800;
  word-break: keep-all;
}

.resume-field dd {
  margin: 0;
  color: #2f3742;
  font-weight: 600;
  line-height: 1.45;
  white-space: pre-wrap;
  word-break: break-word;
}

.resume-nested-card {
  display: grid;
  gap: 0.58rem;
  padding: 0.72rem;
  border: 1px solid #edf0f4;
  border-radius: 8px;
  background: #fbfcfe;
}

.resume-record-list {
  display: grid;
  gap: 0.65rem;
  min-width: 0;
  padding: 0.08rem;
  border: 1px solid transparent;
  border-radius: 8px;
}

.resume-record-card {
  display: grid;
  gap: 0.58rem;
  min-width: 0;
  padding: 0.72rem;
  border: 1px solid #edf0f4;
  border-radius: 8px;
  background: #fbfcfe;
}

.resume-nested-card h5,
.resume-record-card h5,
.resume-essay h5 {
  margin: 0;
  color: #111827;
  font-size: 0.86rem;
  font-weight: 800;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.resume-record-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.52rem;
  margin: 0;
}

.resume-record-row {
  min-width: 0;
  padding: 0.52rem 0.6rem;
  border: 1px solid #eef2f7;
  border-radius: 7px;
  background: #fff;
}

.resume-record-row.wide {
  grid-column: 1 / -1;
}

.resume-record-row dt {
  margin: 0 0 0.16rem;
  color: #0b3d6e;
  font-size: 0.74rem;
  font-weight: 800;
  word-break: keep-all;
}

.resume-record-row dd {
  margin: 0;
  color: #2f3742;
  font-weight: 600;
  line-height: 1.5;
  white-space: pre-wrap;
  word-break: break-word;
}

.resume-subtable-title {
  color: #667085;
  font-size: 0.76rem;
  font-weight: 800;
}

.resume-table-wrap {
  overflow-x: auto;
  border: 1px solid #edf0f4;
  border-radius: 8px;
  background: #fff;
}

.resume-table {
  width: 100%;
  min-width: 560px;
  border-collapse: collapse;
}

.resume-table th,
.resume-table td {
  padding: 0.5rem 0.58rem;
  border-bottom: 1px solid #edf0f4;
  text-align: left;
  vertical-align: top;
  line-height: 1.45;
}

.resume-table th {
  color: #0b3d6e;
  background: #f8fafc;
  font-size: 0.74rem;
  font-weight: 800;
  white-space: nowrap;
}

.resume-table td {
  color: #2f3742;
  white-space: pre-wrap;
  word-break: break-word;
}

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

.resume-long-field,
.resume-essay {
  padding: 0.72rem;
  border: 1px solid #edf0f4;
  border-radius: 8px;
  background: #fff;
}

.resume-essay {
  display: grid;
  gap: 0.45rem;
}

.resume-essay p {
  margin: 0;
  color: #2f3742;
  line-height: 1.6;
  white-space: pre-wrap;
  word-break: break-word;
}

.application-object {
  display: grid;
  gap: 0.6rem;
  margin: 0;
}

.application-row {
  display: grid;
  grid-template-columns: minmax(100px, 0.36fr) minmax(0, 1fr);
  gap: 0.75rem;
  padding: 0.65rem 0.75rem;
  border: 1px solid #edf0f4;
  border-radius: 8px;
  background: #fff;
}

.application-row dt {
  color: #0b3d6e;
  font-weight: 700;
  word-break: keep-all;
}

.application-row dd {
  margin: 0;
  color: #2f3742;
  word-break: break-word;
  white-space: pre-wrap;
}

.application-array {
  margin: 0;
  padding-left: 1.1rem;
}

.application-array li {
  margin-bottom: 0.45rem;
}

.btn-primary.wide {
  display: inline-block;
  text-decoration: none;
  text-align: center;
  padding: 0.55rem 1rem;
  border-radius: 6px;
  background: #0b3d6e;
  color: #fff;
  font-size: 0.85rem;
  font-weight: 600;
}

.btn-primary.wide:hover {
  background: #094a86;
}

.detail-section {
  margin-bottom: 1.25rem;
}

.detail-section h3 {
  margin: 0 0 0.5rem;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.summary-list {
  margin: 0;
  padding-left: 1.1rem;
  font-size: 0.85rem;
  line-height: 1.55;
}

.summary-list li {
  margin-bottom: 0.35rem;
}

.detail-tags {
  margin-top: 0.5rem;
}

.detail-questions {
  list-style: none;
  padding-left: 0;
  margin: 0;
}

.detail-questions li {
  display: grid;
  grid-template-columns: 0.9rem minmax(0, 1fr);
  align-items: start;
  column-gap: 0.5rem;
  margin-bottom: 0.95rem;
  font-size: 0.85rem;
  line-height: 1.55;
}

.detail-questions li > .question-select-btn,
.detail-questions li > .question-source-panel,
.detail-questions li > .question-text {
  grid-column: 2;
  min-width: 0;
}

.detail-questions li::before {
  content: "*";
  color: #0b3d6e;
  font-weight: 800;
  line-height: 1.55;
}

.detail-questions li.report-empty {
  display: block;
}

.detail-questions li.report-empty::before {
  content: none;
}

.detail-questions li:last-child {
  margin-bottom: 0;
}

.question-line {
  display: block;
}

.question-text {
  min-width: 0;
}

.question-line + .question-line {
  margin-top: 0.22rem;
}

.question-select-btn,
.question-source-btn {
  display: block;
  width: 100%;
  cursor: pointer;
  border: 0;
  padding: 0;
  min-width: 0;
  background: transparent !important;
  color: inherit !important;
  font: inherit;
  text-align: left;
  line-height: 1.55;
  vertical-align: baseline;
  border-radius: 0;
}

.modal-box button.question-select-btn,
.modal-box button.question-source-btn,
.modal-box button.question-more-btn,
.modal-box button.question-collapse-btn,
.modal-box button.common-question-nav,
.modal-box button.question-source-chip {
  min-width: 0;
}

.question-select-btn:hover,
.question-select-btn:focus,
.question-select-btn:focus-visible,
.question-select-btn:active,
.question-source-btn:hover,
.question-source-btn:focus,
.question-source-btn:focus-visible,
.question-source-btn:active {
  background: transparent !important;
  color: inherit !important;
  text-decoration: underline;
  text-decoration-color: rgba(92, 102, 117, 0.32);
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
  outline: none;
}

.question-item.is-expanded .question-select-btn.is-selected,
.question-select-btn.is-selected {
  text-decoration: underline;
  text-decoration-color: rgba(11, 61, 110, 0.45);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
  color: #0b3d6e !important;
  font-weight: 700;
}

.question-source-panel {
  margin: 0.45rem 0 0.15rem 0.15rem;
  padding: 0.55rem 0.65rem 0.6rem;
  border-left: 3px solid #8eb0d4;
  background: #f3f7fb;
  border-radius: 0 8px 8px 0;
  font-size: 1em;
}

.question-source-hint {
  margin: 0 0 0.4rem;
  color: #4a6280;
  font-size: 0.9em;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.question-source-chips {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
}

.question-source-details {
  display: grid;
  gap: 0.45rem;
  margin-top: 0.45rem;
}

.question-source-details:empty {
  display: none;
}

.question-source-preview {
  display: grid;
  gap: 0.4rem;
  width: 100%;
  padding: 0.55rem 0.65rem 0.6rem;
  border: 1px solid #c5d6e8;
  border-radius: 10px;
  background: #fff;
  color: inherit;
  text-align: left;
  font-size: 1em;
}

.question-source-preview[hidden] {
  display: none;
}

.question-source-preview-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.55rem;
}

.question-source-preview-label {
  min-width: 0;
  color: #0b3d6e;
  font-size: 1.05em;
  font-weight: 800;
  line-height: 1.35;
}

.question-source-preview-key {
  flex: 0 0 auto;
  color: #6b7c90;
  font-size: 0.85em;
  font-weight: 700;
}

.question-source-preview-body {
  min-width: 0;
  font-size: 1em;
}

.question-source-preview-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.35rem;
  margin: 0;
}

.question-source-preview-row {
  min-width: 0;
  padding: 0.35rem 0.45rem;
  border: 1px solid #e8eef5;
  border-radius: 6px;
  background: #fbfcfe;
}

.question-source-preview-row dt {
  margin: 0 0 0.12rem;
  color: #4a6280;
  font-size: 0.85em;
  font-weight: 800;
}

.question-source-preview-row dd {
  margin: 0;
  color: #2f3742;
  font-size: 0.95em;
  font-weight: 600;
  line-height: 1.4;
  white-space: pre-wrap;
  word-break: break-word;
}

.question-source-preview-text,
.question-source-preview-empty {
  margin: 0;
  color: #2f3742;
  font-size: 1em;
  line-height: 1.5;
  white-space: pre-wrap;
  word-break: break-word;
}

.question-source-preview-empty {
  color: #8a96a6;
}

.question-source-preview-item + .question-source-preview-item {
  margin-top: 0.35rem;
  padding-top: 0.35rem;
  border-top: 1px dashed #d9e2ec;
}

.question-source-preview-item strong {
  display: block;
  margin-bottom: 0.2rem;
  color: #0b3d6e;
  font-size: 0.95em;
}

.question-source-open-original {
  justify-self: start;
  margin-top: 0.1rem;
  padding: 0.28rem 0.55rem;
  border: 1px solid #9fb8d4;
  border-radius: 999px;
  background: #f3f7fb;
  color: #1a4a73;
  font-size: 0.9em;
  font-weight: 800;
  cursor: pointer;
}

.question-source-open-original:hover,
.question-source-open-original:focus-visible {
  background: #e8f1fa;
  border-color: #6f97c0;
  color: #0b3d6e;
  outline: none;
}

.question-source-chip {
  display: inline-flex;
  flex: 0 0 auto;
  width: auto;
  min-width: 0;
  max-width: 100%;
  align-items: center;
  padding: 0.28rem 0.62rem;
  border: 1px solid #9fb8d4;
  border-radius: 999px;
  background: #fff;
  color: #1a4a73;
  font-size: 0.95em;
  font-weight: 700;
  line-height: 1.3;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.question-source-chip:hover,
.question-source-chip:focus-visible {
  background: #e8f1fa;
  border-color: #6f97c0;
  color: #0b3d6e;
  outline: none;
}

.question-source-chip.is-active {
  background: #d6e8f8;
  border-color: #3d7ab0;
  color: #0b3d6e;
  box-shadow: 0 0 0 1px rgba(61, 122, 176, 0.25);
}

@media (max-width: 1100px) {
  .interview-layout {
    grid-template-columns: 1fr;
  }

  .detail-modal-box {
    overflow-y: auto;
  }

  .detail-modal-box.detail-modal-fullscreen .detail-layout {
    overflow: visible;
    align-items: stretch;
  }

  .detail-modal-box.detail-modal-fullscreen::after {
    display: none;
  }

  .detail-modal-box.detail-modal-fullscreen .detail-main,
  .detail-modal-box.detail-modal-fullscreen .detail-layout.sidebar-collapsed .detail-main {
    border-left: none;
    padding-left: 0;
  }

  .detail-modal-box.detail-modal-fullscreen button.detail-sidebar-toggle,
  .detail-modal-box.detail-modal-fullscreen .detail-layout.sidebar-collapsed button.detail-sidebar-toggle {
    position: static;
    top: auto;
    bottom: auto;
    left: auto;
    right: auto;
    transform: none;
    align-self: auto;
  }

  .detail-modal-box.detail-modal-fullscreen .detail-layout.sidebar-collapsed .detail-sidebar {
    position: relative;
    height: auto;
    max-height: none;
  }

  .detail-layout {
    grid-template-columns: 1fr;
  }

  .detail-layout.sidebar-collapsed {
    grid-template-columns: 1fr;
  }

  .detail-sidebar {
    border-right: none;
    border-bottom: 1px solid #e4e8ee;
    padding-right: 0;
    padding-bottom: 1rem;
    max-height: none;
    overflow: visible;
  }

  .detail-layout.sidebar-collapsed .detail-sidebar {
    border-bottom: none;
    padding-bottom: 0;
    min-height: 36px;
  }

  .modal-box button.detail-sidebar-toggle {
    right: 0;
  }

  .detail-photo {
    width: 160px;
    align-self: center;
  }

  .toggle-original-btn {
    margin-top: 0.5rem;
  }

  .detail-body {
    max-height: none;
    overflow: visible;
  }

  .detail-main-panels.split {
    grid-template-columns: 1fr;
  }

  .detail-panel-application {
    border-left: none;
    padding-left: 0;
    border-top: 1px solid #e4e8ee;
    padding-top: 1rem;
  }

  .resume-field-grid,
  .resume-field-grid.identity,
  .resume-field-grid.military,
  .resume-field-grid.compact,
  .resume-field-grid.roomy,
  .resume-field-grid.remaining {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

}

@media (max-width: 640px) {
  .detail-section-headline {
    align-items: flex-start;
    flex-direction: column;
  }

  .common-question-stage {
    grid-template-columns: 2.4rem minmax(0, 1fr) 2.4rem;
    column-gap: 0.45rem;
  }

  .common-question-nav {
    width: 2.15rem;
    height: 2.15rem;
    min-width: 2.15rem;
  }

  .common-question-nav span {
    width: 0.58rem;
    height: 0.58rem;
  }

  .resume-field-grid,
  .resume-field-grid.identity,
  .resume-field-grid.military,
  .resume-field-grid.compact,
  .resume-field-grid.roomy,
  .resume-field-grid.remaining {
    grid-template-columns: 1fr;
  }

  .resume-record-grid,
  .application-record-grid {
    grid-template-columns: 1fr;
  }

  .resume-section-body {
    padding: 0.7rem;
  }
}

/* ── Shared visual refresh ───────────────────────────────────── */
:root {
  --ui-ink: #172033;
  --ui-muted: #667085;
  --ui-line: #dbe4ee;
  --ui-soft: #f4f7fa;
  --ui-blue: #073b66;
  --ui-blue-hover: #115a92;
  --ui-cyan: #0e7490;
  --ui-green: #138a58;
  --ui-red: #c93f3f;
  --ui-focus: rgba(14, 116, 144, 0.24);
  --ui-shadow-sm: 0 1px 2px rgba(23, 32, 51, 0.05);
  --ui-shadow-md: 0 14px 34px rgba(23, 32, 51, 0.10);
}

body {
  background: #eef3f7;
  color: var(--ui-ink);
  letter-spacing: 0;
}

header,
.app-header {
  background: var(--ui-blue);
}

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

.header-brand,
.header-title {
  letter-spacing: 0;
}

.header-link {
  border-radius: 8px;
  font-weight: 700;
  transition: background-color 0.14s ease, border-color 0.14s ease;
}

.panel,
.modal-box,
.report-box,
.career-card,
.application-block {
  border: 1px solid var(--ui-line);
  box-shadow: var(--ui-shadow-sm);
}

input[type="text"],
input[type="password"],
input[type="file"],
select,
.form-textarea,
.form-input-wide {
  border-color: var(--ui-line);
  border-radius: 8px;
  color: var(--ui-ink);
}

input[type="text"]:focus,
input[type="password"]:focus,
input[type="file"]:focus,
select:focus,
.form-textarea:focus,
.form-input-wide:focus {
  border-color: var(--ui-cyan);
  box-shadow: 0 0 0 3px var(--ui-focus);
  outline: none;
}

button,
.btn-primary.wide,
button.primary,
.primary {
  border-radius: 8px;
  background: var(--ui-blue);
  font-weight: 700;
  transition: background-color 0.14s ease, border-color 0.14s ease, box-shadow 0.14s ease, transform 0.14s ease;
}

button:hover,
.btn-primary.wide:hover,
button.primary:hover,
.primary:hover {
  background: var(--ui-blue-hover);
}

button:focus-visible,
.btn-primary.wide:focus-visible,
.header-link:focus-visible {
  outline: 3px solid var(--ui-focus);
  outline-offset: 2px;
}

button.secondary,
.secondary {
  border: 1px solid var(--ui-line);
  background: #eef3f7;
  color: #344054;
}

button.secondary:hover,
.secondary:hover {
  background: #e4ebf2;
  color: #172033;
}

button.danger {
  background: var(--ui-red);
}

button.danger:hover {
  background: #ad3030;
}

button.small {
  min-height: 34px;
  padding: 0.38rem 0.68rem;
}

.message {
  border: 1px solid transparent;
  border-radius: 8px;
  font-weight: 700;
  box-shadow: var(--ui-shadow-sm);
}

.message.info {
  background: #e6f3f6;
  color: #0e6075;
  border-color: #c7e6ee;
}

.message.error {
  background: #fdecec;
  color: #963434;
  border-color: #f6cccc;
}

.tag {
  border: 1px solid #cfe8dd;
  background: #eff8f3;
  color: #12663f;
  font-weight: 700;
}

.status-pill,
.badge {
  font-weight: 800;
}
