:root {
  color-scheme: light;
  --bg: #f6f8fb;
  --nav: #111827;
  --nav-muted: #a3adbd;
  --surface: #ffffff;
  --surface-weak: #f9fafb;
  --surface-strong: #eef2f7;
  --line: #e1e7ef;
  --line-strong: #cbd5e1;
  --text: #111827;
  --muted: #667085;
  --accent: #0f766e;
  --accent-hover: #0b5f59;
  --accent-soft: #ecfdf7;
  --blue-soft: #eef6ff;
  --blue-text: #1d4f8f;
  --danger: #b42318;
  --danger-soft: #fff1f0;
  --sans: "Malgun Gothic", "맑은 고딕", sans-serif;
  --mono: var(--sans);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  letter-spacing: 0;
  line-height: 1.45;
}

button,
input,
select,
textarea {
  font: inherit;
}

.app-shell {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  min-height: 100vh;
}

.tool-sidebar {
  position: sticky;
  top: 0;
  display: flex;
  flex-direction: column;
  gap: 18px;
  height: 100vh;
  min-width: 0;
  padding: 18px 12px;
  background: var(--nav);
  color: #ffffff;
}

.brand {
  padding: 4px 8px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.brand h1 {
  margin: 0;
  font-size: 22px;
  line-height: 1.2;
}

.brand span {
  display: block;
  margin-top: 6px;
  color: var(--nav-muted);
  font-size: 12px;
}

.login-page {
  min-height: 100vh;
  background: #10141b;
}

.login-shell {
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: 24px;
}

.login-panel {
  display: grid;
  gap: 18px;
  width: min(100%, 360px);
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.22);
}

.login-panel h1 {
  margin: 0;
  font-size: 24px;
  line-height: 1.2;
}

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

.login-panel .login-hint {
  margin: -6px 0 0;
}

.login-panel label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
}

.login-panel input {
  width: 100%;
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0 10px;
  color: var(--text);
}

.login-error {
  min-height: 18px;
  color: var(--danger);
  font-size: 13px;
}

.login-link {
  color: var(--accent);
  font-size: 13px;
  text-decoration: none;
}

.admin-panel {
  padding: 18px;
  overflow: auto;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--surface);
}

.admin-table th,
.admin-table td {
  border-bottom: 1px solid var(--line);
  padding: 10px;
  text-align: left;
  font-size: 13px;
}

.admin-table select {
  min-height: 32px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0 8px;
  background: #ffffff;
}

.tool-nav {
  display: grid;
  gap: 6px;
}

.tool-nav-item {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 42px;
  padding: 0 12px;
  border: 1px solid transparent;
  border-radius: 7px;
  background: transparent;
  color: #d0d5dd;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
}

.tool-nav-item:hover {
  background: rgba(255, 255, 255, 0.06);
}

.tool-nav-item.active {
  border-color: rgba(255, 255, 255, 0.14);
  background: #ffffff;
  color: var(--text);
}

.tool-main {
  display: flex;
  flex-direction: column;
  height: 100vh;
  min-width: 0;
  min-height: 100vh;
  overflow: hidden;
}

.app-topbar {
  display: flex;
  flex: 0 0 48px;
  align-items: center;
  justify-content: flex-end;
  min-width: 0;
  padding: 0 18px;
  border-bottom: 1px solid var(--line);
  background: #ffffff;
}

.account-bar {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  width: auto;
  min-width: 0;
  min-height: 32px;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
}

.current-user {
  min-width: 0;
  max-width: 240px;
  padding: 0;
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
}

.account-button {
  display: inline-flex;
  min-height: 32px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--accent);
  border-radius: 6px;
  background: var(--accent);
  color: #ffffff;
  padding: 0 13px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
}

.account-button:hover {
  border-color: var(--accent-hover);
  background: var(--accent-hover);
  color: #ffffff;
}

.account-bar.signed-in .account-button {
  border-color: var(--line-strong);
  background: #ffffff;
  color: var(--text);
  font-weight: 500;
}

.account-bar.signed-in .account-button:hover {
  border-color: var(--danger);
  background: var(--danger-soft);
  color: var(--danger);
}

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

.tool-panel {
  display: none;
  min-height: 0;
  flex: 1;
}

.tool-panel.active {
  display: flex;
  flex-direction: column;
}

#cyberchef-panel.active {
  display: block;
  height: auto;
  min-height: 0;
}

.embedded-cyberchef {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  background: #ffffff;
}

.topbar,
.tool-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-height: 68px;
  padding: 12px 18px;
  background: var(--surface);
  border-bottom: 1px solid var(--line);
}

.tool-header h2,
.topbar h2 {
  margin: 0;
  font-size: 22px;
  line-height: 1.2;
}

.tool-header p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.url-stack {
  min-width: 0;
}

.top-actions,
.detail-actions,
.form-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 0 13px;
  border: 1px solid var(--accent);
  border-radius: 6px;
  background: var(--accent);
  color: #ffffff;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
}

.button:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
}

.button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
  filter: none;
}

.button.ghost {
  background: #ffffff;
  color: var(--accent);
}

.button.ghost:hover {
  background: var(--accent-soft);
  border-color: var(--accent);
}

.button.danger {
  border-color: var(--danger);
  background: var(--danger);
}

.button.ghost.danger-text {
  border-color: #f4c7c3;
  background: #ffffff;
  color: var(--danger);
}

.button.ghost.danger-text:hover {
  border-color: var(--danger);
  background: var(--danger-soft);
}

.button.small {
  min-height: 32px;
  padding: 0 10px;
  font-size: 13px;
}

.requestbin-layout {
  display: grid;
  --request-sidebar-width: 300px;
  grid-template-columns: minmax(240px, min(var(--request-sidebar-width), 34vw)) 6px minmax(0, 1fr);
  width: 100%;
  height: auto;
  min-height: 0;
  min-width: 0;
  flex: 1 1 0;
  overflow: hidden;
  background: #ffffff;
}

.request-sidebar {
  display: flex;
  min-width: 0;
  min-height: 0;
  max-width: 100%;
  flex-direction: column;
  overflow: hidden;
  border-right: 1px solid var(--line);
  background: #f7f9fc;
}

.request-resizer {
  position: relative;
  background: #eef3f8;
  border-right: 1px solid var(--line);
  cursor: col-resize;
  touch-action: none;
}

.request-resizer::before {
  content: "";
  position: absolute;
  inset: 0 2px;
  background: transparent;
}

.request-resizer:hover,
.request-resizer:focus-visible,
.requestbin-layout.resizing .request-resizer {
  background: #cad6e3;
  outline: none;
}

.requestbin-layout.resizing,
.requestbin-layout.resizing * {
  cursor: col-resize;
  user-select: none;
}

.bins-head,
.sidebar-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-width: 0;
  padding: 13px 14px;
  border-bottom: 1px solid var(--line);
}

.bins-head {
  display: grid;
  min-height: auto;
  min-width: 0;
  gap: 11px;
  background: var(--surface);
}

.panel-section-title {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: space-between;
  color: var(--text);
}

.bins-head-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  width: 100%;
  align-items: center;
}

.new-bin-id {
  width: 100%;
  min-width: 0;
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0 9px;
  color: var(--text);
}

.text-danger-action {
  border: 0;
  background: transparent;
  color: var(--danger);
  cursor: pointer;
  font-size: 12px;
  padding: 0;
}

.text-danger-action:hover {
  text-decoration: underline;
  text-underline-offset: 2px;
}

.sidebar-head span,
.bin-count {
  display: inline-flex;
  min-width: 28px;
  height: 24px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--surface-strong);
  color: var(--muted);
  font-size: 12px;
}

.bin-list {
  flex: 0 0 auto;
  max-height: clamp(116px, 24vh, 216px);
  min-height: 84px;
  overflow: auto;
  padding: 10px;
  border-bottom: 1px solid var(--line);
  background: #f1f5f9;
}

.bin-item {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto 24px;
  grid-template-areas: "id count delete";
  align-items: center;
  gap: 4px 8px;
  width: 100%;
  min-width: 0;
  min-height: 46px;
  margin-bottom: 7px;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.bin-item:hover {
  border-color: var(--line-strong);
}

.bin-item.active {
  border-color: var(--accent);
  background: var(--accent-soft);
  box-shadow: inset 3px 0 0 var(--accent);
}

.bin-id {
  grid-area: id;
  min-width: 0;
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: var(--sans);
  font-size: 13px;
  font-weight: 500;
}

.bin-count {
  grid-area: count;
  align-self: center;
}

.bin-delete {
  grid-area: delete;
}

.sidebar-toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 0 14px;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
  color: var(--muted);
  font-size: 13px;
}

.sidebar-toggle input {
  width: 16px;
  height: 16px;
}

.settings-form input[type="url"],
.settings-form input[type="password"],
.settings-form textarea {
  width: 100%;
  min-height: 36px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #ffffff;
  color: var(--text);
  padding: 0 10px;
}

.settings-form textarea {
  min-height: 150px;
  padding: 10px;
  resize: vertical;
  font-family: var(--mono);
  font-size: 13px;
}

.request-list {
  flex: 1;
  min-height: 0;
  min-width: 0;
  overflow: auto;
  padding: 10px;
}

.request-item {
  position: relative;
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr) auto 26px;
  grid-template-areas:
    "method path time delete"
    "method bytes bytes delete";
  gap: 5px 9px;
  width: 100%;
  min-width: 0;
  min-height: 64px;
  margin-bottom: 7px;
  padding: 10px 10px 10px 11px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.request-item:hover {
  border-color: var(--line-strong);
}

.request-item.active {
  border-color: var(--accent);
  background: var(--accent-soft);
  box-shadow: inset 3px 0 0 var(--accent);
}

.request-item.expanded {
  grid-template-columns: 58px minmax(0, 1fr) 26px;
  grid-template-areas:
    "method time delete"
    "path path delete"
    "bytes bytes delete";
  min-height: 92px;
  align-items: start;
}

.request-item.long:not(.expanded)::before {
  content: "click again to expand";
  position: absolute;
  right: 42px;
  bottom: 8px;
  color: var(--muted);
  font-size: 11px;
  opacity: 0;
}

.request-item.long.active:hover::before {
  opacity: 1;
}

.request-item .method {
  grid-area: method;
  align-self: center;
  justify-self: start;
  min-width: 48px;
  border-radius: 5px;
  background: var(--blue-soft);
  color: var(--blue-text);
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 700;
  padding: 5px 7px;
  text-align: center;
}

.request-item .path {
  grid-area: path;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: var(--mono);
  font-size: 13px;
}

.request-item.expanded .path {
  max-height: 120px;
  overflow: auto;
  white-space: normal;
  overflow-wrap: anywhere;
  text-overflow: clip;
}

.request-item .time {
  grid-area: time;
  color: var(--muted);
  font-size: 12px;
  text-align: right;
}

.request-item .bytes {
  grid-area: bytes;
  color: var(--muted);
  font-size: 12px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.request-item.expanded .bytes {
  max-height: 72px;
  overflow: auto;
  white-space: normal;
  overflow-wrap: anywhere;
  text-overflow: clip;
}

.bin-delete,
.request-delete {
  grid-area: delete;
  display: inline-flex;
  align-self: center;
  justify-self: end;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  padding: 0;
  border: 1px solid var(--danger);
  border-radius: 999px;
  background: var(--danger);
  color: #ffffff;
  font-family: var(--mono);
  font-size: 12px;
  line-height: 1;
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.12s ease, transform 0.12s ease;
}

.icon-delete svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2.4;
}

.bin-delete {
  align-self: center;
}

.bin-item:hover .bin-delete,
.bin-item:focus-within .bin-delete,
.bin-delete:focus-visible,
.request-item:hover .request-delete,
.request-item:focus-within .request-delete,
.request-delete:focus-visible {
  opacity: 1;
  pointer-events: auto;
}

.bin-delete:hover,
.request-delete:hover {
  transform: scale(1.04);
}

.request-item.expanded .request-delete {
  align-self: start;
}

.request-workspace {
  min-width: 0;
  min-height: 0;
  max-width: 100%;
  overflow: auto;
  display: flex;
  flex-direction: column;
  background: #ffffff;
}

.bin-overview,
.detail {
  display: flex;
  flex-direction: column;
  width: 100%;
  min-width: 0;
  min-height: 0;
  gap: 10px;
}

.bin-overview {
  flex: 0 0 auto;
  padding: 14px 18px 12px;
  border-bottom: 1px solid var(--line);
  background: #ffffff;
}

.detail {
  flex: 0 0 auto;
  padding: 14px 18px 18px;
}

.detail.title-expanded,
.detail.value-expanded {
  flex: 0 0 auto;
}

.detail.title-expanded .detail-content,
.detail.value-expanded .detail-content {
  flex: 0 0 auto;
  min-height: 260px;
  overflow: visible;
}

.bin-overview-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-start;
}

.overview-title {
  font-family: var(--mono);
  font-size: 20px;
  font-weight: 700;
  overflow-wrap: anywhere;
}

.overview-meta {
  margin-top: 6px;
  color: var(--muted);
  font-size: 13px;
}

.endpoint-panel {
  display: grid;
  gap: 6px;
  max-width: none;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fbfcfe;
  padding: 10px 12px;
}

.endpoint-panel > span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.endpoint-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
}

.endpoint-row code {
  min-width: 0;
  min-height: 32px;
  display: flex;
  align-items: center;
  overflow-wrap: anywhere;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #ffffff;
  padding: 8px 10px;
  color: var(--text);
  font-family: var(--mono);
  font-size: 13px;
}

.hidden {
  display: none;
}

.detail-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-start;
}

.detail-head > div:first-child {
  min-width: 0;
  flex: 1;
}

.detail-title {
  max-width: 100%;
  min-height: 24px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: var(--mono);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.35;
}

.detail-title.long {
  cursor: pointer;
}

.detail-title.long:hover,
.detail-title.long:focus-visible {
  color: var(--accent);
  outline: 0;
}

.detail-title.expanded {
  max-height: none;
  overflow: visible;
  text-overflow: clip;
  white-space: normal;
  overflow-wrap: anywhere;
}

.detail-meta {
  margin-top: 6px;
  color: var(--muted);
  font-size: 13px;
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(132px, 1fr));
  gap: 8px;
}

.stat-grid div {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fbfcfe;
  padding: 7px 10px;
}

.stat-grid span {
  display: block;
  color: var(--muted);
  font-size: 11px;
  margin-bottom: 3px;
}

.stat-grid strong {
  display: block;
  min-height: 18px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
}

.sub-tabs {
  display: flex;
  align-items: center;
  gap: 2px;
  border-bottom: 1px solid var(--line);
  background: #ffffff;
  padding: 6px 10px 0;
  overflow-x: auto;
}

.sub-tab {
  min-height: 36px;
  padding: 0 13px;
  border: 1px solid transparent;
  border-bottom: 0;
  border-radius: 6px 6px 0 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

.sub-tab.active {
  border-color: var(--line);
  background: #f8fafc;
  color: var(--text);
}

.detail-content {
  flex: 0 0 auto;
  min-height: 220px;
  min-width: 0;
  max-width: 100%;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #ffffff;
  overflow: visible;
}

.detail-empty-state {
  display: grid;
  min-height: 180px;
  place-items: center;
  color: var(--muted);
  font-size: 13px;
}

.empty-state {
  display: grid;
  min-height: 58px;
  place-items: center;
  border: 1px dashed #c9d2de;
  border-radius: 6px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.78);
  font-size: 13px;
}

.request-empty {
  min-height: 92px;
}

.kv-table {
  width: 100%;
  min-width: 0;
  border-collapse: collapse;
  table-layout: fixed;
}

.kv-table th,
.kv-table td {
  border-bottom: 1px solid var(--line);
  padding: 10px 12px;
  vertical-align: top;
  overflow-wrap: anywhere;
}

.kv-table th {
  width: 220px;
  color: var(--muted);
  font-weight: 600;
  text-align: left;
  font-family: var(--mono);
  font-size: 13px;
}

.kv-table td {
  font-family: var(--mono);
  font-size: 13px;
}

.data-pairs {
  display: grid;
  min-width: 0;
  gap: 10px;
  padding: 12px;
}

.data-pair,
.data-text-block {
  display: grid;
  gap: 8px;
  min-width: 0;
  max-width: 100%;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #ffffff;
  padding: 12px;
}

.data-pair:hover {
  border-color: var(--line-strong);
}

.data-pair-head {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.data-key {
  min-width: 0;
  color: #475467;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 700;
}

.data-value-wrap,
.data-text-block {
  position: relative;
}

.data-value-wrap.collapsed {
  max-height: 142px;
  overflow: hidden;
}

.data-value-wrap.collapsed::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 40px;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0), #ffffff);
}

.data-value-wrap.expanded,
.data-text-block.expanded {
  max-height: none;
  overflow: visible;
}

.data-text-block.collapsed .data-value {
  max-height: 142px;
  overflow: hidden;
}

.data-value {
  margin: 0;
  padding: 10px 11px;
  border: 1px solid #edf1f5;
  border-radius: 5px;
  background: #f8fafc;
  color: #182230;
  white-space: pre-wrap;
  overflow-wrap: break-word;
  word-break: break-word;
  font-family: var(--mono);
  font-size: 12px;
  line-height: 1.58;
}

.data-expand {
  justify-self: start;
  flex: 0 0 auto;
  min-height: 30px;
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  background: #ffffff;
  color: #344054;
  padding: 0 10px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
}

.data-expand:hover {
  border-color: var(--accent);
  color: var(--accent);
}

pre {
  margin: 0;
  padding: 14px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font-family: var(--mono);
  font-size: 13px;
  line-height: 1.55;
}

.settings-form {
  display: grid;
  gap: 14px;
  max-width: 760px;
  padding: 18px;
}

.settings-form label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
}

.settings-form label > span {
  font-weight: 700;
}

.toggle-row {
  display: flex !important;
  grid-template-columns: none;
  align-items: center;
  gap: 10px;
  color: var(--text) !important;
}

.toggle-row input {
  width: 18px;
  height: 18px;
}

.status-output {
  max-width: 760px;
  margin: 0 18px 18px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--surface);
}

.chef-frame {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 0;
  border: 0;
  background: #ffffff;
}

.cyberchef-page {
  overflow: hidden;
}

.cyberchef-shell {
  height: 100vh;
  min-height: 0;
}

.cyberchef-main {
  height: 100%;
  min-height: 0;
  overflow: hidden;
  background: #ffffff;
}

@media (max-width: 980px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .tool-sidebar {
    position: sticky;
    top: 0;
    z-index: 10;
    display: block;
    height: auto;
    padding: 10px;
  }

  .brand {
    display: none;
  }

  .tool-nav {
    display: flex;
    gap: 8px;
    overflow-x: auto;
  }

  .app-topbar {
    flex-basis: 46px;
    padding: 0 14px;
  }

  .account-bar {
    justify-content: flex-end;
  }

  .current-user {
    max-width: 180px;
  }

  .tool-nav-item {
    width: auto;
    min-width: 132px;
    justify-content: center;
  }

  .requestbin-layout {
    grid-template-columns: 1fr;
    height: auto;
    min-height: 0;
  }

  .request-resizer {
    display: none;
  }

  .cyberchef-shell {
    grid-template-rows: auto minmax(0, 1fr);
  }

  .cyberchef-main {
    height: auto;
  }

  .request-sidebar {
    max-height: none;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .bin-list {
    max-height: 180px;
  }

  .request-list {
    flex: none;
    max-height: 300px;
  }

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

@media (max-width: 560px) {
  .topbar,
  .tool-header {
    align-items: flex-start;
    flex-direction: column;
    padding: 14px;
  }

  .top-actions,
  .detail-actions,
  .form-actions {
    width: 100%;
  }

  .button {
    flex: 1;
  }

  .bins-head-actions {
    grid-template-columns: 1fr;
  }

  .detail-head {
    flex-direction: column;
  }

  .stat-grid {
    grid-template-columns: 1fr;
  }

  .kv-table th {
    width: 120px;
  }
}
