:root {
  color-scheme: light;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #202733;
  background: #f5f6f8;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  --ink: #202733;
  --muted: #7d8795;
  --line: #e9edf1;
  --purple: #7458e8;
  --purple-light: #f0edff;
}

* { box-sizing: border-box; }

body {
  min-width: 320px;
  margin: 0;
  background: #f5f6f8;
}

button, input { font: inherit; }
button { color: inherit; }
a { color: inherit; }

.app-shell { min-height: 100vh; }

.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 2;
  display: flex;
  width: 256px;
  flex-direction: column;
  padding: 28px 17px 20px;
  border-right: 1px solid #e9edf1;
  background: #fff;
}

.brand {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 10px;
  margin: 0 0 55px 5px;
  color: #252b36;
  font-family: inherit;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -1.1px;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 11px;
  background: #785eea;
  box-shadow: 0 5px 12px #785eea33;
  color: #fff;
  font-size: 18px;
  letter-spacing: 0;
}

.brand-light { color: #8f82c9; font-weight: 500; }
.sidebar-heading { padding: 0 10px 12px; color: #a3aab4; font-size: 10px; font-weight: 700; letter-spacing: 1.2px; }
.repo-filters { display: grid; gap: 4px; }
.repo-list { display: grid; gap: 4px; }

.repo-filter {
  display: flex;
  min-width: 0;
  height: 43px;
  align-items: center;
  gap: 11px;
  padding: 0 10px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: #697381;
  cursor: pointer;
  text-align: left;
  transition: background .16s ease, color .16s ease;
}

.repo-filter:hover { background: #f7f6fc; color: #4f43a3; }
.repo-filter.is-active { background: var(--purple-light); color: #5d48c7; font-weight: 600; }
.filter-icon { display: grid; width: 21px; flex: 0 0 21px; place-items: center; color: #8880ac; font-size: 17px; }
.filter-name { overflow: hidden; flex: 1; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.filter-count { color: #a0a7b0; font-size: 11px; font-variant-numeric: tabular-nums; }
.repo-mark { width: 21px; height: 21px; border: 1px solid #e9e6f8; border-radius: 6px; font-size: 10px; font-weight: 700; }

.sidebar-bottom {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  margin-top: auto;
  padding: 15px 12px;
  border: 1px solid #eceaf7;
  border-radius: 11px;
  background: #faf9fe;
}

.storage-icon { display: grid; width: 27px; height: 27px; flex: 0 0 27px; place-items: center; border-radius: 8px; background: #eeeaff; color: #765ee1; font-weight: 700; }
.sidebar-bottom strong { display: block; margin: 2px 0 5px; font-size: 11px; }
.sidebar-bottom p { margin: 0; color: #8a91a0; font-size: 10px; line-height: 1.5; }

.main-content { max-width: 1600px; min-height: 100vh; margin-left: 256px; padding: 0 54px; }
.topbar { display: flex; height: 72px; align-items: center; justify-content: space-between; border-bottom: 1px solid #e7eaee; }
.breadcrumb { display: flex; align-items: center; gap: 10px; color: #929aa6; font-size: 12px; }
.breadcrumb strong { color: #3d4652; font-weight: 600; }
.breadcrumb-separator { color: #c5cad1; }
.connection-status { display: inline-flex; align-items: center; gap: 8px; color: #8a929e; font-size: 11px; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: #c8cdd4; }
.connection-status.is-online { color: #478c68; }
.connection-status.is-online .status-dot { background: #4eb67a; box-shadow: 0 0 0 3px #4eb67a1c; }
.connection-status.is-offline .status-dot { background: #e17a70; box-shadow: 0 0 0 3px #e17a701c; }

.page-intro { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; padding: 41px 0 28px; }
.eyebrow { margin: 0 0 10px; color: #8975dd; font-size: 10px; font-weight: 700; letter-spacing: 1.25px; }
h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: 7px; color: #222a35; font-family: inherit; font-size: clamp(26px, 3vw, 33px); font-weight: 700; letter-spacing: -1.3px; }
.intro-copy { margin: 0; color: #818a97; font-size: 13px; }
.refresh-button { display: inline-flex; height: 37px; align-items: center; gap: 8px; padding: 0 13px; border: 1px solid #e1e4e9; border-radius: 8px; background: #fff; color: #525d6a; cursor: pointer; font-size: 11px; font-weight: 600; transition: border-color .15s, background .15s; }
.refresh-button:hover { border-color: #c6bdf0; background: #fbfaff; }
.refresh-button:disabled { cursor: wait; opacity: .7; }
.refresh-button > span:first-child { font-size: 17px; line-height: 1; }
.refresh-button.is-loading > span:first-child { animation: spin .9s linear infinite; }

.stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 15px; }
.stat-card { display: flex; min-height: 83px; align-items: center; gap: 14px; padding: 15px 18px; border: 1px solid #eaedf1; border-radius: 11px; background: #fff; }
.stat-icon { display: grid; width: 39px; height: 39px; flex: 0 0 39px; place-items: center; border-radius: 10px; font-size: 18px; }
.stat-icon-files { background: #f0edff; color: #765de2; }
.stat-icon-repos { background: #e9f6f2; color: #48a88e; }
.stat-icon-size { background: #fff3e7; color: #df9b4f; }
.stat-label { display: block; margin-bottom: 5px; color: #989fab; font-size: 9px; font-weight: 700; letter-spacing: .8px; }
.stat-card strong { color: #2c3440; font-family: inherit; font-size: 19px; font-weight: 700; letter-spacing: -.5px; }

.file-section { margin-top: 38px; }
.section-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; margin-bottom: 19px; }
h2 { margin: 0 0 5px; color: #303945; font-family: inherit; font-size: 17px; font-weight: 700; letter-spacing: -.4px; }
.heading-count { color: #9ca4af; font-family: "DM Sans", sans-serif; font-size: 12px; font-weight: 500; }
.section-heading p { margin: 0; color: #9ba2ad; font-size: 11px; }
.search-box { display: flex; width: min(100%, 340px); height: 38px; align-items: center; gap: 9px; padding: 0 10px; border: 1px solid #e5e8ed; border-radius: 8px; background: #fff; color: #a1a8b3; }
.search-icon { color: #929baa; font-size: 22px; line-height: 1; transform: rotate(-20deg); }
.search-box input { width: 100%; min-width: 0; border: 0; outline: 0; background: transparent; color: #394350; font-size: 11px; }
.search-box input::placeholder { color: #adb4be; }
kbd { display: grid; width: 20px; height: 21px; flex: 0 0 20px; place-items: center; border: 1px solid #e9ebef; border-radius: 4px; background: #fafbfc; color: #a0a7b1; font-family: inherit; font-size: 10px; }

.file-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.file-card { min-width: 0; padding: 17px 17px 13px; border: 1px solid #e9edf1; border-radius: 11px; background: #fff; transition: border-color .16s, box-shadow .16s, transform .16s; }
.file-card:hover { transform: translateY(-2px); border-color: #dcd7f4; box-shadow: 0 8px 22px #3434500c; }
.file-card-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 13px; }
.file-type { display: inline-flex; min-width: 39px; height: 25px; align-items: center; justify-content: center; padding: 0 8px; border: 1px solid #ebe7fd; border-radius: 6px; background: #f7f5ff; color: #7258d8; font-size: 9px; font-weight: 700; letter-spacing: .4px; }
.download-button, .copy-button { display: grid; place-items: center; border: 0; background: transparent; color: #969eaa; cursor: pointer; }
.download-button { width: 29px; height: 29px; border: 1px solid #e9edf1; border-radius: 7px; transition: background .15s, color .15s, border-color .15s; }
.download-button:hover { border-color: #dbd5f5; background: #f5f2ff; color: #7056d7; }
.download-button svg { width: 15px; height: 15px; }
.file-name { overflow: hidden; margin: 0 0 9px; color: #303844; font-size: 13px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.file-repo { display: flex; align-items: center; gap: 6px; color: #8d95a1; font-size: 10px; }
.file-repo > span:first-child { color: #a39bc7; font-size: 13px; }
.file-details { display: flex; justify-content: space-between; gap: 8px; margin: 15px 0 12px; color: #939ba7; font-size: 10px; }
.file-details span { color: #596371; font-weight: 600; }
.file-details time { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.checksum { display: flex; min-width: 0; align-items: center; gap: 7px; padding-top: 10px; border-top: 1px solid #f0f1f3; color: #9aa2ae; }
.checksum > span { flex: 0 0 auto; font-size: 8px; font-weight: 700; letter-spacing: .45px; }
.checksum code { overflow: hidden; flex: 1; color: #858d9a; font-family: "SFMono-Regular", Consolas, monospace; font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.copy-button { width: 23px; height: 23px; flex: 0 0 23px; border-radius: 5px; }
.copy-button:hover, .copy-button.is-copied { background: #f0edff; color: #7056d7; }
.copy-button svg { width: 13px; height: 13px; }

.empty-state { grid-column: 1 / -1; display: flex; min-height: 230px; flex-direction: column; align-items: center; justify-content: center; padding: 30px; border: 1px dashed #e0e4ea; border-radius: 11px; background: #fff; text-align: center; }
.empty-icon { display: grid; width: 46px; height: 46px; place-items: center; margin-bottom: 13px; border-radius: 14px; background: #f2efff; color: #816ce2; font-size: 22px; }
.empty-state h3 { margin: 0 0 6px; color: #424b58; font-size: 14px; }
.empty-state p { max-width: 360px; margin: 0; color: #969eaa; font-size: 11px; line-height: 1.6; }

.load-error { display: flex; align-items: center; gap: 12px; margin: 0 0 14px; padding: 13px 15px; border: 1px solid #f1d8d5; border-radius: 9px; background: #fff9f8; }
.load-error[hidden] { display: none; }
.error-icon { display: grid; width: 26px; height: 26px; flex: 0 0 26px; place-items: center; border-radius: 50%; background: #fde9e6; color: #c26358; font-weight: 700; }
.load-error strong { display: block; margin-bottom: 3px; color: #914f48; font-size: 11px; }
.load-error p { margin: 0; color: #a27f7b; font-size: 10px; }
.load-error button { margin-left: auto; padding: 7px 10px; border: 1px solid #efd5d1; border-radius: 6px; background: #fff; color: #9d5e56; cursor: pointer; font-size: 10px; white-space: nowrap; }

.page-footer { display: flex; justify-content: space-between; gap: 18px; margin-top: 44px; padding: 18px 0 24px; border-top: 1px solid #e7eaee; color: #a1a8b1; font-size: 10px; }
.page-footer span:first-child { color: #737d8a; font-weight: 700; }
.visually-hidden { position: absolute; overflow: hidden; width: 1px; height: 1px; padding: 0; border: 0; clip: rect(0, 0, 0, 0); white-space: nowrap; }

@keyframes spin { to { transform: rotate(360deg); } }

@media (max-width: 1250px) {
  .main-content { padding-right: 32px; padding-left: 32px; }
  .file-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 780px) {
  .sidebar { position: static; width: 100%; min-height: 0; padding: 13px 18px 10px; border-right: 0; border-bottom: 1px solid #e9edf1; }
  .brand { margin: 0 0 13px; font-size: 18px; }
  .brand-mark { width: 31px; height: 31px; }
  .sidebar-heading { padding: 0 2px 8px; }
  .repo-filters { display: flex; overflow-x: auto; gap: 6px; padding-bottom: 2px; }
  .repo-filter { height: 36px; flex: 0 0 auto; gap: 7px; padding: 0 9px; }
  .filter-name { max-width: 160px; }
  .repo-list { display: flex; flex: 0 0 auto; gap: 6px; }
  .sidebar-bottom { display: none; }
  .main-content { min-height: 0; margin-left: 0; padding: 0 22px; }
  .topbar { height: 56px; }
  .page-intro { padding: 30px 0 22px; }
}

@media (max-width: 560px) {
  .main-content { padding: 0 15px; }
  .breadcrumb { max-width: 65%; overflow: hidden; white-space: nowrap; }
  .breadcrumb strong { overflow: hidden; text-overflow: ellipsis; }
  .connection-status { gap: 6px; font-size: 10px; }
  .page-intro { align-items: flex-start; }
  .eyebrow { font-size: 9px; }
  h1 { font-size: 27px; }
  .intro-copy { max-width: 260px; font-size: 12px; line-height: 1.5; }
  .refresh-button { width: 37px; flex: 0 0 37px; justify-content: center; padding: 0; font-size: 0; }
  .refresh-button > span:first-child { font-size: 19px; }
  .stats { grid-template-columns: 1fr; gap: 8px; }
  .stat-card { min-height: 66px; padding: 10px 13px; }
  .stat-icon { width: 34px; height: 34px; flex-basis: 34px; }
  .stat-card strong { font-size: 17px; }
  .file-section { margin-top: 29px; }
  .section-heading { align-items: stretch; flex-direction: column; }
  .search-box { width: 100%; }
  .file-grid { grid-template-columns: 1fr; }
  .file-card { padding: 15px; }
  .page-footer { flex-direction: column; gap: 7px; margin-top: 31px; line-height: 1.5; }
  .load-error { align-items: flex-start; flex-wrap: wrap; }
  .load-error > div { flex: 1; }
  .load-error button { margin-left: 38px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

.loading-indicator{min-height:220px;display:grid;place-items:center;background:#fff;border:1px dashed #dfe4ec;border-radius:14px}.loading-spinner{width:24px;height:24px;border:2px solid #e8e9f7;border-top-color:#7c5cff;border-radius:50%;animation:fd-spin .75s linear infinite}@keyframes fd-spin{to{transform:rotate(360deg)}}@media(prefers-reduced-motion:reduce){.loading-spinner{animation:none}}


/* Visual refresh: softer canvas, clearer hierarchy, refined surfaces */
:root {
  --ink: #182230;
  --muted: #748196;
  --line: #e4e9f1;
  --purple: #6654e8;
  --purple-light: #f0eeff;
}
body {
  color: var(--ink);
  background:
    radial-gradient(ellipse at 78% 0%, rgba(112, 94, 238, .075), transparent 34rem),
    #f7f8fc;
}
.sidebar {
  width: 264px;
  padding: 30px 18px 22px;
  border-right: 1px solid #e7eaf2;
  background: rgba(255,255,255,.94);
  box-shadow: 8px 0 36px rgba(29, 39, 68, .025);
}
.brand { margin-bottom: 58px; font-size: 21px; }
.brand-mark {
  border-radius: 12px;
  background: linear-gradient(145deg, #8875ff, #5e4bd8);
  box-shadow: 0 7px 16px rgba(102,84,232,.25);
}
.main-content { margin-left: 264px; padding: 0 clamp(24px, 4vw, 64px); }
.topbar { border-bottom-color: #e8ebf2; }
.connection-status {
  padding: 8px 11px;
  border: 1px solid #e7ebf1;
  border-radius: 999px;
  background: rgba(255,255,255,.8);
}
.page-intro { padding-top: 48px; padding-bottom: 32px; }
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 10px;
  border: 1px solid #e5e0ff;
  border-radius: 999px;
  background: #f5f3ff;
  color: #6a57d7;
  font-size: 9px;
  letter-spacing: 1.15px;
}
h1 { font-size: clamp(30px, 3.2vw, 40px); letter-spacing: -1.7px; }
.intro-copy { color: #788397; font-size: 13px; line-height: 1.7; }
.refresh-button {
  height: 41px;
  padding: 0 15px;
  border-color: #ded9ff;
  border-radius: 10px;
  background: #fff;
  color: #5f4bd4;
  box-shadow: 0 3px 10px rgba(37, 32, 92, .035);
  font-size: 12px;
}
.refresh-button:hover { border-color: #bdb2ff; background: #f8f6ff; }
.stats { gap: 17px; }
.stat-card {
  position: relative;
  overflow: hidden;
  min-height: 104px;
  gap: 16px;
  padding: 20px;
  border-color: #e7eaf2;
  border-radius: 16px;
  background: rgba(255,255,255,.92);
  box-shadow: 0 5px 18px rgba(35, 44, 72, .025);
  transition: transform .18s ease, box-shadow .18s ease;
}
.stat-card:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(35,44,72,.06); }
.stat-icon { width: 44px; height: 44px; flex-basis: 44px; border-radius: 13px; }
.stat-icon-files { background: #efedff; color: #6b57e5; }
.stat-icon-repos { background: #e8f7f1; color: #279b79; }
.stat-icon-size { background: #fff1e4; color: #d88938; }
.stat-label { margin-bottom: 7px; color: #8b95a7; font-size: 9px; letter-spacing: 1px; }
.stat-card strong { color: #202a3a; font-size: 22px; letter-spacing: -.7px; }
.file-section { margin-top: 44px; }
.section-heading { align-items: center; margin-bottom: 22px; }
h2 { color: #202a3a; font-size: 19px; letter-spacing: -.55px; }
.section-heading p { margin-top: 5px; color: #8791a2; font-size: 11px; }
.search-box {
  width: min(100%, 360px);
  height: 43px;
  padding: 0 13px;
  border-color: #e2e7ef;
  border-radius: 11px;
  background: rgba(255,255,255,.95);
  box-shadow: 0 3px 12px rgba(34,44,72,.025);
  transition: border-color .18s, box-shadow .18s;
}
.search-box:focus-within { border-color: #b9afff; box-shadow: 0 0 0 4px rgba(102,84,232,.08); }
.search-box input { font-size: 12px; }
.file-grid { gap: 17px; }
.file-card {
  padding: 19px 19px 15px;
  border-color: #e5e9f1;
  border-radius: 15px;
  background: rgba(255,255,255,.96);
  box-shadow: 0 4px 14px rgba(29, 40, 68, .025);
  transition: border-color .2s, box-shadow .2s, transform .2s;
}
.file-card:hover {
  transform: translateY(-3px);
  border-color: #d1caff;
  box-shadow: 0 14px 32px rgba(46, 39, 112, .075);
}
.file-type { height: 27px; border-radius: 7px; background: #f5f3ff; color: #6653d7; }
.download-button { width: 32px; height: 32px; border-radius: 9px; background: #fafbfe; }
.file-name { margin-bottom: 11px; color: #202a3a; font-size: 13px; }
.file-repo { color: #778397; font-size: 11px; }
.file-details { margin: 18px 0 14px; color: #8791a2; font-size: 10px; }
.file-details span { color: #445166; }
.checksum { padding-top: 12px; border-top-color: #edf0f5; }
.checksum code { color: #758197; }
.copy-button:hover, .copy-button.is-copied { background: #f0edff; color: #6653d7; }
.empty-state { border-color: #dfe4ef; border-radius: 16px; background: rgba(255,255,255,.8); }
.empty-icon { background: #f0edff; color: #6b58dc; }
.page-footer { margin-top: 54px; border-top-color: #e7ebf2; }
button:focus-visible, a:focus-visible, input:focus-visible {
  outline: 3px solid rgba(102,84,232,.3);
  outline-offset: 3px;
}
@media (max-width: 780px) {
  .sidebar { width: 100%; padding: 15px 18px 12px; }
  .brand { margin-bottom: 16px; }
  .main-content { margin-left: 0; padding: 0 22px; }
  .page-intro { padding-top: 30px; }
  .stats { gap: 10px; }
  .stat-card { padding: 14px; border-radius: 13px; }
}
@media (max-width: 560px) {
  .main-content { padding: 0 15px; }
  .page-intro { align-items: flex-start; }
  .stats { grid-template-columns: 1fr; }
  .stat-card { min-height: 76px; }
  .section-heading { align-items: stretch; flex-direction: column; }
  .search-box { width: 100%; }
  .file-grid { grid-template-columns: 1fr; gap: 12px; }
  .file-card { padding: 17px; }
  .page-footer { flex-direction: column; gap: 8px; }
}
