/* ---------- Yonetim paneli ---------- */

.page-wide {
  max-width: 1120px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.login-form {
  display: flex;
  gap: 10px;
  width: min(100%, 420px);
  margin-top: 8px;
}

.login-form input {
  flex: 1;
}

.panel-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding: 24px 24px 0;
}

.panel-head h1 {
  margin: 0;
  font-size: 1.35rem;
}

.panel-sub {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13.5px;
}

.panel-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.toolbar {
  padding: 18px 24px 12px;
}

.toolbar input {
  width: 100%;
  max-width: 460px;
}

.table-wrap {
  overflow-x: auto;
  padding: 0 8px 8px;
}

table.responses {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

table.responses th,
table.responses td {
  text-align: left;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}

table.responses thead th {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  font-weight: 700;
  background: var(--surface-2);
}

table.responses thead th:first-child {
  border-top-left-radius: 10px;
}

table.responses thead th:last-child {
  border-top-right-radius: 10px;
}

table.responses tbody tr:hover {
  background: var(--surface-2);
}

table.responses td.num {
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

table.responses td:nth-child(2) {
  color: var(--muted);
}

.row-actions {
  text-align: right;
}

.link-btn {
  font: inherit;
  font-size: 13.5px;
  font-weight: 600;
  background: none;
  border: none;
  padding: 4px 6px;
  color: var(--accent-strong);
  cursor: pointer;
  border-radius: 8px;
}

.link-btn:hover {
  background: var(--accent-soft);
}

.link-btn.danger {
  color: var(--danger);
}

.link-btn.danger:hover {
  background: var(--danger-soft);
}

.empty {
  padding: 8px 24px 32px;
}

/* Detay penceresi */

.detail-dialog {
  width: min(760px, calc(100vw - 32px));
  max-height: min(86vh, 900px);
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 30px 80px -20px rgba(0, 0, 0, 0.45);
}

.detail-dialog::backdrop {
  background: rgba(8, 20, 18, 0.55);
  backdrop-filter: blur(2px);
}

.dialog-head {
  position: sticky;
  top: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 20px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}

.dialog-head h2 {
  margin: 0;
  font-size: 1.1rem;
}

.icon-btn {
  font: inherit;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--muted);
  cursor: pointer;
}

.icon-btn:hover {
  background: var(--accent-soft);
  color: var(--accent-strong);
}

.detail-body {
  padding: 8px 20px 20px;
  overflow-y: auto;
  max-height: calc(86vh - 140px);
}

.detail-meta {
  margin: 8px 0 16px;
  font-size: 13px;
  color: var(--muted);
}

.detail-section {
  margin-bottom: 18px;
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface-2);
}

.detail-section h3 {
  margin: 0 0 12px;
  font-size: 13px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--accent-strong);
}

.detail-item + .detail-item {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px dashed var(--border);
}

.detail-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  white-space: pre-line;
  margin-bottom: 4px;
}

.detail-value {
  font-size: 14.5px;
  white-space: pre-line;
  overflow-wrap: anywhere;
}

.detail-value.muted {
  color: var(--muted);
}

.dialog-foot {
  position: sticky;
  bottom: 0;
  display: flex;
  justify-content: flex-end;
  padding: 12px 20px;
  background: var(--surface);
  border-top: 1px solid var(--border);
}

@media (max-width: 600px) {
  .login-form {
    flex-direction: column;
  }

  .panel-head {
    padding: 18px 18px 0;
  }

  .toolbar {
    padding: 14px 18px 10px;
  }

  .panel-actions {
    width: 100%;
  }

  .panel-actions .btn {
    flex: 1;
  }
}
