/* Public graduate search — mobile-first */
.show-list-page {
  background: #edf1f5;
}

.show-list-page #page-wrapper {
  margin-left: 0 !important;
  background: #edf1f5;
}

.show-list-page .container-fluid {
  padding-left: 12px;
  padding-right: 12px;
  max-width: none;
}

.show-list-page .navbar-header {
  background: #1f6feb;
}

.show-shell {
  --ink: #1b2a41;
  --muted: #5c6b7a;
  --line: #d7e0ea;
  --soft: #f4f7fb;
  --accent: #1f6feb;
  max-width: none;
  width: 100%;
  margin: 0 auto 28px;
  font-family: "THSarabunNew", "Sarabun", Helvetica, Arial, sans-serif;
  padding: 8px 12px 24px;
}

.show-hero {
  background: linear-gradient(135deg, #e8f1ff, #f7faff);
  border: 1px solid #c5d8f5;
  border-radius: 18px;
  padding: 22px 20px 18px;
  margin-bottom: 14px;
  box-shadow: 0 8px 24px rgba(27, 42, 65, 0.06);
}

.show-eyebrow {
  margin: 0 0 4px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent);
}

.show-title {
  margin: 0 0 6px;
  font-size: 32px;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.2;
}

.show-sub {
  margin: 0 0 16px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.4;
}

.show-search {
  position: relative;
  display: flex;
  align-items: center;
  background: #fff;
  border: 2px solid #9dbce8;
  border-radius: 14px;
  padding: 0 12px;
  box-shadow: 0 4px 14px rgba(31, 111, 235, 0.08);
}

.show-search:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(31, 111, 235, 0.18);
}

.show-search .fa-search {
  color: var(--accent);
  font-size: 16px;
  margin-right: 8px;
}

.show-search-input {
  flex: 1;
  border: 0;
  outline: 0;
  height: 52px;
  font-size: 18px;
  background: transparent;
  color: var(--ink);
  min-width: 0;
}

.show-search-input::placeholder {
  color: #9aa6b2;
}

.show-search-clear {
  border: 0;
  background: #eef2f6;
  color: #5c6b7a;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}

.show-result-meta {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 14px;
}

.show-dash {
  margin-bottom: 18px;
}

.show-stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 14px;
}

.show-stat {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 16px 16px 14px;
  box-shadow: 0 6px 18px rgba(27, 42, 65, 0.05);
}

.show-stat.is-ok {
  background: linear-gradient(180deg, #f3fbf6, #fff);
  border-color: #c9e9d5;
}

.show-stat.is-join {
  background: linear-gradient(180deg, #eef5ff, #fff);
  border-color: #c5d8f5;
}

.show-stat.is-warn {
  background: linear-gradient(180deg, #fff8ec, #fff);
  border-color: #f0d9a8;
}

.show-stat-label {
  display: block;
  font-size: 13px;
  font-weight: 700;
  color: var(--muted);
  margin-bottom: 4px;
}

.show-stat-value {
  display: block;
  font-size: 34px;
  line-height: 1.1;
  font-weight: 800;
  color: var(--ink);
}

.show-stat-hint {
  display: block;
  margin-top: 4px;
  font-size: 13px;
  color: var(--muted);
}

.show-chart-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.show-chart-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 14px 14px 10px;
  box-shadow: 0 6px 18px rgba(27, 42, 65, 0.05);
}

.show-chart-card.is-wide {
  grid-column: 1 / -1;
}

.show-chart-card h2 {
  margin: 0 0 8px;
  font-size: 16px;
  font-weight: 800;
  color: var(--ink);
}

.show-chart-canvas-wrap {
  position: relative;
  height: 240px;
}

.show-chart-canvas-wrap.is-bar {
  height: 280px;
}

.show-hero-search {
  margin-top: 8px;
}

.show-title-sm {
  font-size: 26px;
}

.show-toolbar {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 10px;
}

.show-toolbar .dt-buttons .btn {
  margin: 0;
}

.show-table-wrap {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 8px;
  box-shadow: 0 6px 18px rgba(27, 42, 65, 0.05);
  overflow: hidden;
}

.show-table {
  width: 100% !important;
  border-collapse: separate !important;
  border-spacing: 0;
}

.show-table thead th {
  background: var(--soft) !important;
  color: var(--muted) !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  border-bottom: 1px solid var(--line) !important;
  padding: 12px 10px !important;
  white-space: nowrap;
}

.show-table tbody td {
  padding: 12px 10px !important;
  border-top: 1px solid #eef2f6 !important;
  color: var(--ink);
  font-size: 15px;
  vertical-align: middle !important;
}

.show-table tbody tr:hover td {
  background: #f7faff;
}

.show-badge {
  display: inline-block;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.4;
  margin: 1px 2px 1px 0;
  white-space: nowrap;
}

.show-badge.is-ok {
  background: #e3f6ea;
  color: #1e7a46;
}

.show-badge.is-warn {
  background: #fff1d6;
  color: #b7791f;
}

.show-badge.is-wait {
  background: #ffe8e8;
  color: #c0392b;
}

.show-badge.is-join {
  background: #e8f1ff;
  color: #1f6feb;
}

.show-badge.is-mute {
  background: #eef1f4;
  color: #6b7785;
}

.show-pay-stack {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 180px;
  width: 100%;
}

.show-table thead th:nth-child(3),
.show-table tbody td:nth-child(3) {
  width: 20%;
  min-width: 220px;
  white-space: normal !important;
}

.show-table thead th:nth-child(5),
.show-table tbody td:nth-child(5) {
  white-space: nowrap !important;
}

.show-pay-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.show-pay-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  min-width: 86px;
}

.dataTables_wrapper .dataTables_info,
.dataTables_wrapper .dataTables_paginate {
  padding: 10px 6px !important;
  color: var(--muted) !important;
  font-size: 14px !important;
}

.dataTables_wrapper .dataTables_paginate .paginate_button {
  border-radius: 8px !important;
  padding: 4px 10px !important;
}

.dataTables_wrapper .dataTables_paginate .paginate_button.current {
  background: var(--accent) !important;
  border-color: var(--accent) !important;
  color: #fff !important;
}

/* Hide default DT filter — we use custom search */
.dataTables_filter {
  display: none !important;
}

@media (max-width: 991px) {
  .show-stat-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .show-chart-grid {
    grid-template-columns: 1fr;
  }

  .show-chart-canvas-wrap,
  .show-chart-canvas-wrap.is-bar {
    height: 260px;
  }
}

@media (max-width: 767px) {
  .show-shell {
    padding: 4px 0 20px;
  }

  .show-hero {
    border-radius: 14px;
    padding: 16px 14px 14px;
  }

  .show-title {
    font-size: 26px;
  }

  .show-title-sm {
    font-size: 22px;
  }

  .show-stat-grid {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  .show-stat {
    padding: 12px;
  }

  .show-stat-value {
    font-size: 28px;
  }

  .show-search-input {
    height: 48px;
    font-size: 16px;
  }

  .show-table-wrap {
    padding: 0;
    background: transparent;
    border: 0;
    box-shadow: none;
  }

  .show-table thead {
    display: none;
  }

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

  .show-table tbody tr {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 14px;
    margin-bottom: 10px;
    padding: 10px 12px 6px;
    box-shadow: 0 4px 12px rgba(27, 42, 65, 0.05);
  }

  .show-table tbody td {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    padding: 7px 0 !important;
    border-top: 1px dashed #e8eef5 !important;
    text-align: right;
    white-space: normal !important;
  }

  .show-table tbody td:first-child {
    border-top: 0 !important;
  }

  .show-table tbody td::before {
    content: attr(data-label);
    font-size: 12px;
    font-weight: 700;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.02em;
    text-align: left;
    flex: 0 0 38%;
  }

  /* Keep key fields prominent; de-emphasize order number */
  .show-table tbody td:nth-child(1) {
    display: none;
  }

  .show-table tbody td:nth-child(7) {
    font-size: 17px;
  }

  .show-table tbody td[data-label="รหัสนักศึกษา"] {
    white-space: nowrap !important;
  }

  .show-table tbody td[data-label="รหัสนักศึกษา"] strong {
    white-space: nowrap;
  }

  .show-table tbody td[data-label="ชำระเงิน"] {
    flex-direction: column;
    align-items: stretch;
    text-align: left;
  }

  .show-table tbody td[data-label="ชำระเงิน"]::before {
    margin-bottom: 4px;
  }

  .show-table tbody td[data-label="ชำระเงิน"] .show-pay-stack {
    width: 100%;
  }

  .show-table tbody td[data-label="ชำระเงิน"] .show-pay-line {
    justify-content: space-between;
    padding: 6px 8px;
    border-radius: 8px;
    background: #f7f9fb;
  }

  .dataTables_wrapper .dataTables_info,
  .dataTables_wrapper .dataTables_paginate {
    text-align: center !important;
    float: none !important;
  }

  .dataTables_wrapper .dataTables_paginate {
    margin-top: 4px;
  }
}
