@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:wght@400;500;600&family=Inter:wght@400;500;600;700&display=swap');

:root {
  color-scheme: dark;
  --bg: #060b10;
  --surface: #0a121a;
  --surface-2: #0e1923;
  --line: #1a2b38;
  --text: #dbe8ef;
  --muted: #6f8795;
  --cyan: #4ee1d1;
  --blue: #55a8ff;
  --orange: #ff9b62;
}

* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; background: var(--bg); color: var(--text); font-family: Inter, sans-serif; }
body::before { content: ""; position: fixed; inset: 0; pointer-events: none; opacity: .25; background-image: linear-gradient(rgba(78,225,209,.025) 1px, transparent 1px), linear-gradient(90deg, rgba(78,225,209,.025) 1px, transparent 1px); background-size: 32px 32px; }
button, input { font: inherit; }
button { color: inherit; }
header { height: 64px; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; padding: 0 max(24px, calc((100vw - 1480px) / 2)); background: rgba(6,11,16,.88); backdrop-filter: blur(16px); position: sticky; top: 0; z-index: 10; }
a { color: inherit; text-decoration: none; }
.brand { display: flex; gap: 12px; align-items: center; font-weight: 700; letter-spacing: -.02em; }
.brand span { font-family: "IBM Plex Mono", monospace; width: 32px; height: 32px; display: grid; place-items: center; color: var(--bg); background: var(--cyan); font-size: 12px; }
.header-right { display: flex; gap: 24px; font: 12px "IBM Plex Mono", monospace; color: var(--muted); }
.header-right a { color: var(--cyan); }
main { width: min(1480px, calc(100% - 48px)); margin: 0 auto; padding: 32px 0 80px; }
.drop { min-height: 88px; border: 1px dashed #294454; background: rgba(10,18,26,.75); display: flex; align-items: center; gap: 18px; padding: 18px; cursor: pointer; transition: .2s ease; }
.drop:hover, .drop.active { border-color: var(--cyan); background: rgba(78,225,209,.055); }
.drop-mark { font: 600 12px "IBM Plex Mono", monospace; border: 1px solid var(--line); width: 42px; height: 42px; display: grid; place-items: center; color: var(--cyan); }
.drop strong, .drop span { display: block; }
.drop strong { font-size: 14px; }
.drop span { font: 11px/1.7 "IBM Plex Mono", monospace; color: var(--muted); }
.drop button { margin-left: auto; border: 1px solid var(--cyan); background: transparent; color: var(--cyan); padding: 10px 16px; cursor: pointer; font: 600 11px "IBM Plex Mono", monospace; text-transform: uppercase; letter-spacing: .08em; }
.empty { min-height: 560px; display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--line); }
.empty h1, .file-title h1 { margin: 12px 0 20px; letter-spacing: -.055em; line-height: .96; font-size: clamp(46px, 7vw, 96px); }
.empty p { max-width: 600px; color: var(--muted); font-size: 17px; line-height: 1.7; }
.eyebrow { color: var(--cyan); font: 600 10px "IBM Plex Mono", monospace; letter-spacing: .18em; }
.formats { display: grid; grid-template-columns: repeat(2, 110px); gap: 1px; background: var(--line); border: 1px solid var(--line); }
.formats span { height: 90px; display: grid; place-items: center; background: var(--surface); font: 13px "IBM Plex Mono", monospace; color: var(--muted); }
.file-title { padding: 70px 0 38px; overflow: hidden; }
.file-title h1 { font-size: clamp(36px, 5vw, 72px); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.summary { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid var(--line); border-left: 1px solid var(--line); margin-bottom: 24px; }
.metric { min-height: 88px; padding: 18px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--surface); min-width: 0; }
.metric span, .metric strong { display: block; }
.metric span { color: var(--muted); font: 10px "IBM Plex Mono", monospace; text-transform: uppercase; margin-bottom: 12px; }
.metric strong { font: 500 14px "IBM Plex Mono", monospace; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.grid { display: grid; gap: 24px; margin: 24px 0; }
.wide-left { grid-template-columns: 1.6fr 1fr; }
.equal { grid-template-columns: 1fr 1fr; }
.panel { border: 1px solid var(--line); background: rgba(10,18,26,.88); min-width: 0; }
.panel-head { min-height: 76px; display: flex; align-items: center; justify-content: space-between; padding: 16px 18px; border-bottom: 1px solid var(--line); gap: 16px; }
.panel h2 { margin: 5px 0 0; font-size: 17px; letter-spacing: -.02em; }
.panel input { border: 1px solid var(--line); background: var(--bg); color: var(--text); padding: 9px 11px; width: 150px; font: 11px "IBM Plex Mono", monospace; outline: 0; }
.panel input:focus { border-color: var(--cyan); }
.panel label { color: var(--muted); font: 10px "IBM Plex Mono", monospace; display: flex; align-items: center; gap: 8px; }
.muted { color: var(--muted); font: 10px "IBM Plex Mono", monospace; }
.table { overflow-x: auto; }
.table-row { min-width: 720px; width: 100%; display: grid; grid-template-columns: 1.3fr 1fr 1fr 1fr .55fr .7fr; gap: 12px; align-items: center; padding: 12px 16px; border: 0; border-bottom: 1px solid rgba(26,43,56,.65); background: transparent; text-align: left; font: 11px "IBM Plex Mono", monospace; }
button.table-row { cursor: pointer; }
button.table-row:hover { background: var(--surface-2); color: var(--cyan); }
.table-head { color: var(--muted); text-transform: uppercase; font-size: 9px; }
.flags { color: var(--orange); }
#entropy { display: block; width: calc(100% - 36px); margin: 18px; cursor: crosshair; image-rendering: pixelated; }
.scale { display: flex; align-items: center; gap: 10px; padding: 0 18px 18px; color: var(--muted); font: 9px "IBM Plex Mono", monospace; }
.scale i { display: block; height: 4px; flex: 1; background: linear-gradient(90deg, hsl(190 88% 28%), hsl(100 88% 45%), hsl(15 88% 60%)); }
.hex, .strings { height: 560px; overflow: auto; padding: 8px 0; }
.hex-row { min-width: 610px; display: grid; grid-template-columns: 95px 390px 1fr; padding: 5px 14px; font: 11px/1.4 "IBM Plex Mono", monospace; }
.hex-row:hover { background: var(--surface-2); }
.hex-row span { color: var(--blue); }
.hex-row code { color: #aec0ca; }
.hex-row em { color: var(--cyan); font-style: normal; }
.string-row { width: 100%; display: grid; grid-template-columns: 95px 1fr; gap: 12px; padding: 7px 14px; border: 0; background: transparent; text-align: left; cursor: pointer; font: 11px "IBM Plex Mono", monospace; }
.string-row:hover { background: var(--surface-2); }
.string-row span { color: var(--blue); }
.string-row code { color: #aec0ca; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
footer { width: min(1480px, calc(100% - 48px)); margin: 0 auto; border-top: 1px solid var(--line); padding: 24px 0 40px; display: flex; justify-content: space-between; color: var(--muted); font: 10px "IBM Plex Mono", monospace; }

@media (max-width: 980px) {
  .wide-left, .equal { grid-template-columns: 1fr; }
  .summary { grid-template-columns: repeat(2, 1fr); }
  .empty { align-items: flex-start; flex-direction: column; justify-content: center; gap: 40px; }
}

@media (max-width: 620px) {
  main, footer { width: min(100% - 24px, 1480px); }
  header { padding: 0 12px; }
  .header-right span { display: none; }
  .drop-mark, .drop span { display: none; }
  .drop button { padding: 9px; }
  .summary { grid-template-columns: 1fr; }
  .formats { grid-template-columns: repeat(2, 90px); }
  .panel-head { align-items: flex-start; flex-direction: column; }
  .panel input { width: 100%; }
  footer { flex-direction: column; gap: 8px; }
}
