:root {
  --bg: #eef1f6;
  --side: #f7f8fb;
  --card: #fff;
  --line: #e6eaf0;
  --text: #1c2430;
  --muted: #8b95a5;
  --blue: #2f6bff;
  --blue-2: #2457d6;
  --green: #1f9d55;
  --red: #e5484d;
  --shadow: 0 8px 28px rgba(28, 36, 48, .06);
}
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: "Segoe UI", system-ui, sans-serif;
  color: var(--text);
  background: linear-gradient(180deg, #f4f6fa 0%, #e9eef5 100%);
  min-height: 100vh;
}
button, input, select, textarea { font: inherit; }
a { color: var(--blue); text-decoration: none; }
.app { display: flex; min-height: 100vh; }
.side {
  width: 232px;
  flex: 0 0 232px;
  background: var(--side);
  border-right: 1px solid var(--line);
  padding: 18px 14px;
  display: flex;
  flex-direction: column;
}
.brand { display: flex; gap: 10px; align-items: center; padding: 4px 8px 18px; }
.logo {
  width: 36px; height: 36px; border-radius: 50%;
  background: #f5b400; color: #fff; display: grid; place-items: center; font-weight: 800;
}
.brand b { display: block; font-size: 14px; }
.brand span { color: var(--muted); font-size: 12px; }
.side nav { display: flex; flex-direction: column; gap: 4px; }
.side nav a {
  display: flex; align-items: center; gap: 10px;
  color: #3c4656; padding: 10px 12px; border-radius: 12px; font-size: 14px;
  transition: background .16s ease, color .16s ease;
}
.side nav a:hover { background: #e7edf6; }
.side nav a.active, .side nav a.active:hover { background: #1d2430; color: #fff; }
.side nav a svg { width: 16px; height: 16px; flex: 0 0 16px; }
.side .spacer { flex: 1; }
.main { flex: 1; padding: 28px 32px 48px; min-width: 0; }
.top { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; margin-bottom: 18px; }
.top h1 { margin: 0 0 6px; font-size: 28px; font-weight: 700; }
.sub { margin: 0; color: var(--muted); font-size: 13px; }
.flash {
  background: #e8f8ee; color: #146c36; border: 1px solid #b7e7c7;
  padding: 10px 14px; border-radius: 12px; margin-bottom: 14px;
}
.card {
  background: var(--card); border: 1px solid var(--line); border-radius: 16px;
  box-shadow: var(--shadow); padding: 18px 20px; margin-bottom: 16px;
}
.card h2 {
  margin: 0 0 14px; font-size: 12px; letter-spacing: .06em; color: #667085; font-weight: 700;
}
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.os-card .head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.os-card .head b { font-size: 13px; letter-spacing: .04em; }
.os-ico { width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; color: #5b6573; background: #f3f5f8; }
.file-meta { font-size: 13px; margin-bottom: 12px; }
.file-meta .name { font-weight: 600; }
.file-meta .dim { color: var(--muted); font-size: 12px; margin-top: 2px; }
.pick { display: flex; gap: 8px; align-items: center; }
.pick input[type=file] { display: none; }
.pick .browse, .btn, button, a.btn {
  border: 1px solid #d5dce6; background: #fff; color: var(--text);
  border-radius: 10px; padding: 0 14px; min-height: 40px;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  cursor: pointer; line-height: 1; white-space: nowrap;
  box-shadow: 0 1px 1px rgba(28, 36, 48, .04);
  transition: background .16s ease, border-color .16s ease, box-shadow .16s ease, transform .12s ease;
}
.pick .browse:hover, .btn:hover, button:hover, a.btn:hover {
  border-color: #c5d0e0; background: #f7f9fc;
}
.pick .browse:active, .btn:active, button:active, a.btn:active { transform: translateY(1px); box-shadow: none; }
.pick .chosen {
  flex: 1; min-width: 0; color: var(--muted); font-size: 13px;
  border: 1px solid var(--line); border-radius: 10px; padding: 0 12px;
  min-height: 40px; display: flex; align-items: center; background: #fafbfc;
}
.btn.blue, button.primary {
  background: var(--blue); color: #fff; border-color: transparent; font-weight: 600;
  box-shadow: 0 1px 2px rgba(47, 107, 255, .28);
}
.btn.blue:hover, button.primary:hover {
  background: var(--blue-2); border-color: transparent;
  box-shadow: 0 6px 16px rgba(47, 107, 255, .28);
}
.btn.ghost { background: #fff; }
.btn.green { background: var(--green); color: #fff; border-color: transparent; }
.btn.green:hover { background: #18864a; border-color: transparent; }
.btn.red { background: #fff; color: var(--red); border-color: #f3c1c3; }
.btn.red:hover { background: #fff5f5; border-color: #e7a8ab; }
span.btn { cursor: default; box-shadow: none; }
span.btn:hover { background: var(--green); }
.btn.sm, button.sm { min-height: 32px; padding: 0 10px; font-size: 13px; border-radius: 8px; }
.test-dl { margin-top: 10px; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th { text-align: left; font-size: 11px; letter-spacing: .04em; color: #98a2b3; font-weight: 700; padding: 8px; }
td { padding: 10px 8px; border-top: 1px solid var(--line); vertical-align: middle; }
.hash { font-family: Consolas, monospace; color: #667085; font-size: 12px; }
label.field, .login-card label { display: block; font-size: 13px; font-weight: 600; margin: 14px 0 6px; color: #344054; }
input[type=text], input:not([type]), input[type=number], input[type=password], input[type=url], select, textarea {
  width: 100%; border: 1px solid #d9e0ea; border-radius: 10px; padding: 10px 12px; background: #fff;
  min-height: 42px; color: var(--text);
  transition: border-color .15s ease, box-shadow .15s ease;
}
textarea { min-height: 120px; resize: vertical; line-height: 1.45; }
input:focus, select:focus, textarea:focus {
  outline: none; border-color: #8eafff; box-shadow: 0 0 0 3px rgba(47, 107, 255, .16);
}
select {
  appearance: none; padding-right: 36px; cursor: pointer;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16' fill='none'><path d='M4 6l4 4 4-4' stroke='%23667085' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/></svg>");
  background-repeat: no-repeat; background-position: right 12px center;
}
input[type=checkbox] {
  appearance: none; width: 18px; height: 18px; margin: 0; flex: 0 0 18px;
  border: 1.5px solid #c5ceda; border-radius: 6px; background: #fff;
  display: inline-grid; place-items: center; cursor: pointer;
  transition: background .15s ease, border-color .15s ease, transform .12s ease, box-shadow .15s ease;
}
input[type=checkbox]:hover { border-color: var(--blue); }
input[type=checkbox]:active { transform: scale(.9); }
input[type=checkbox]:focus-visible { outline: 2px solid rgba(47, 107, 255, .35); outline-offset: 2px; }
input[type=checkbox]:checked {
  background: var(--blue) url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'><path d='M2.2 6.2 4.7 8.7 9.8 3.4' fill='none' stroke='white' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/></svg>") center / 12px 12px no-repeat;
  border-color: var(--blue);
}
.row-3 { display: grid; grid-template-columns: 1.4fr .6fr .9fr; gap: 12px; align-items: start; }
.checks { display: flex; gap: 8px 18px; flex-wrap: wrap; align-items: center; font-size: 14px; margin-top: 4px; }
.checks label, .switch, details > label {
  display: inline-flex; align-items: center; gap: 8px; min-height: 36px; cursor: pointer; font-weight: 500;
}
.switch { width: 100%; font-weight: 600; padding: 4px 0; }
.hint { color: var(--muted); font-size: 12px; line-height: 1.45; margin: 6px 0 0; }
.actions { display: flex; justify-content: flex-end; align-items: center; gap: 8px; margin-top: 16px; }
details { border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px 12px; background: #fbfcfe; }
details summary { cursor: pointer; font-weight: 600; color: #344054; padding: 4px 0; }
details summary:hover { color: var(--blue); }
td form { display: inline-flex; vertical-align: middle; margin: 0 4px 0 0; }
.login-card h1 { margin: 0 0 8px; font-size: 24px; }
.login-card form { display: flex; flex-direction: column; }
.login-card button { margin-top: 16px; width: 100%; }
pre.embed {
  background: #f7f8fb; border: 1px solid var(--line); border-radius: 10px;
  padding: 12px; overflow: auto; font-size: 13px; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin: 8px 0 0;
}
pre.embed code { white-space: pre-wrap; word-break: break-all; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 16px; }
.stat b { display: block; font-size: 32px; margin-top: 6px; }
.stat span { color: var(--muted); font-size: 13px; }
.geo { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; letter-spacing: .04em; }
.flag {
  width: 22px; height: 16px; flex: 0 0 22px; border-radius: 4px; overflow: hidden;
  box-shadow: 0 0 0 1px rgba(28, 36, 48, .14), 0 1px 2px rgba(28, 36, 48, .06);
}
.flag svg { display: block; width: 100%; height: 100%; }
.preview-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 14px; }
.mode-pick { display: block; cursor: pointer; }
.fake {
  display: block; border: 1px solid var(--line); border-radius: 14px; padding: 18px; background: #fbfcfe;
  transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
}
.mode-pick:hover .fake { border-color: #b9ccff; }
.mode-pick.is-on .fake {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(47, 107, 255, .16);
  background: #f4f7ff;
}
.pick-flag {
  display: inline-block; font-size: 11px; font-weight: 700; letter-spacing: .04em;
  text-transform: uppercase; color: #667085; background: #eef1f6; border-radius: 999px; padding: 3px 8px;
}
.mode-pick .pick-on { display: none; }
.mode-pick.is-on .pick-off { display: none; }
.mode-pick.is-on .pick-on { display: inline-block; color: #fff; background: var(--blue); }
.fake h3 { margin: 8px 0 6px; font-size: 16px; }
.fake p { margin: 0 0 8px; color: #475467; font-size: 13px; line-height: 1.45; }
.fake .btns { display: flex; justify-content: flex-end; gap: 8px; margin-top: 12px; }
.login-body { display: grid; place-items: center; }
.login-card { width: 380px; }
.err { color: var(--red); }
@media (max-width: 1100px) {
  .grid-2, .preview-grid, .row-3, .stats { grid-template-columns: 1fr; }
  .side { width: 76px; flex-basis: 76px; }
  .brand b, .brand span, .side nav a span { display: none; }
}
