/* ============================================================
   SheiraGTPS.hub — pink & girly GitHub-style theme
   ============================================================ */

:root {
  --pink-50:  #fff5f9;
  --pink-100: #ffe6f1;
  --pink-200: #ffd0e4;
  --pink-300: #ffb3d3;
  --pink-400: #ff8fc0;
  --pink-500: #f96ba8;
  --pink-600: #e34b8d;
  --pink-700: #c02f71;

  --lilac:    #c9a7ff;
  --peach:    #ffd9c7;
  --mint:     #b8f2e6;

  --bg:        #fff7fb;
  --bg-soft:   #fff0f7;
  --surface:   #ffffff;
  --surface-2: #fff9fc;
  --border:    #f7d4e5;
  --border-strong: #f0b8d3;

  --text:      #4a2b3c;
  --text-soft: #8a6478;
  --text-mute: #b08fa1;

  --code-bg:   #2b1b26;
  --code-text: #ffe6f1;

  --shadow-sm: 0 2px 6px rgba(227, 75, 141, .08);
  --shadow-md: 0 10px 30px rgba(227, 75, 141, .12);
  --shadow-lg: 0 24px 60px rgba(192, 47, 113, .18);

  --radius:    18px;
  --radius-sm: 12px;
  --radius-pill: 999px;

  --font: 'Quicksand', ui-rounded, 'Segoe UI', system-ui, -apple-system, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
}

html[data-theme="dark"] {
  --bg:        #1b1017;
  --bg-soft:   #241520;
  --surface:   #251620;
  --surface-2: #2d1a27;
  --border:    #432536;
  --border-strong: #5c3249;

  --text:      #ffe9f3;
  --text-soft: #d3a8bf;
  --text-mute: #a97e94;

  --code-bg:   #140b10;
  --code-text: #ffd9ea;

  --shadow-sm: 0 2px 6px rgba(0, 0, 0, .35);
  --shadow-md: 0 10px 30px rgba(0, 0, 0, .4);
  --shadow-lg: 0 24px 60px rgba(0, 0, 0, .5);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  transition: background .35s ease, color .35s ease;
}

a { color: var(--pink-600); text-decoration: none; }
a:hover { text-decoration: underline; }

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

::selection { background: var(--pink-200); color: var(--pink-700); }

/* ---------- decorative background ---------- */
.bg-blobs {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}

.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: .55;
}
.blob-1 { width: 46vw; height: 46vw; top: -14vw; left: -10vw; background: #ffd3e7; }
.blob-2 { width: 38vw; height: 38vw; top: 18vh; right: -14vw; background: #e8d4ff; }
.blob-3 { width: 40vw; height: 40vw; bottom: -16vw; left: 24vw; background: #ffe1d4; }
html[data-theme="dark"] .blob { opacity: .18; }

.sparkle {
  position: absolute;
  color: var(--pink-400);
  opacity: .5;
  font-size: 22px;
  animation: floaty 7s ease-in-out infinite;
}
.s1 { top: 12%; left: 6%; }
.s2 { top: 28%; right: 8%; animation-delay: 1.4s; font-size: 28px; }
.s3 { bottom: 22%; left: 12%; animation-delay: 2.6s; }
.s4 { bottom: 10%; right: 16%; animation-delay: 3.8s; font-size: 18px; }

@keyframes floaty {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50%      { transform: translateY(-14px) rotate(12deg); }
}

/* ---------- top bar ---------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 40;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}

.topbar-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 14px 22px;
  display: flex;
  align-items: center;
  gap: 18px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none !important;
  flex-shrink: 0;
}

.brand-mark {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--pink-400), var(--pink-600) 60%, #b06cff);
  color: #fff;
  font-weight: 700;
  font-size: 20px;
  box-shadow: 0 6px 16px rgba(227, 75, 141, .35);
  transform: rotate(-4deg);
}
.brand-mark.small { width: 30px; height: 30px; font-size: 15px; border-radius: 10px; }

.brand-text {
  font-weight: 700;
  font-size: 19px;
  color: var(--text);
  letter-spacing: -.02em;
}
.brand-text em { font-style: normal; color: var(--pink-500); }

.search-wrap {
  position: relative;
  flex: 1;
  max-width: 460px;
}
.search-wrap .search-icon {
  position: absolute;
  left: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--pink-400);
  font-size: 18px;
  pointer-events: none;
}
.search-wrap input {
  width: 100%;
  padding: 11px 46px 11px 42px;
  border-radius: var(--radius-pill);
  border: 1.5px solid var(--border);
  background: var(--surface);
  color: var(--text);
  outline: none;
  transition: border-color .2s, box-shadow .2s;
}
.search-wrap input::placeholder { color: var(--text-mute); }
.search-wrap input:focus {
  border-color: var(--pink-300);
  box-shadow: 0 0 0 4px rgba(255, 143, 192, .18);
}
.search-wrap kbd {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  font-family: var(--mono);
  font-size: 11px;
  color: var(--text-mute);
  border: 1px solid var(--border);
  background: var(--surface-2);
  padding: 2px 7px;
  border-radius: 7px;
}

.topnav {
  display: flex;
  gap: 4px;
}
.topnav a {
  padding: 8px 13px;
  border-radius: var(--radius-pill);
  font-weight: 600;
  font-size: 14.5px;
  color: var(--text-soft);
  text-decoration: none;
  transition: background .2s, color .2s;
}
.topnav a:hover { background: var(--pink-100); color: var(--pink-700); text-decoration: none; }
.topnav a.active { background: var(--pink-100); color: var(--pink-700); }

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

.icon-btn {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  border: 1.5px solid var(--border);
  background: var(--surface);
  color: var(--text-soft);
  cursor: pointer;
  transition: transform .15s, border-color .2s, color .2s, background .2s;
}
.icon-btn:hover { transform: translateY(-1px); border-color: var(--pink-300); color: var(--pink-600); }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: var(--radius-pill);
  border: 1.5px solid transparent;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  transition: transform .15s, box-shadow .2s, background .2s, border-color .2s, color .2s;
  white-space: nowrap;
}
.btn:active { transform: scale(.97); }

.btn-primary {
  background: linear-gradient(135deg, var(--pink-400), var(--pink-600));
  color: #fff;
  box-shadow: 0 8px 20px rgba(227, 75, 141, .3);
}
.btn-primary:hover { box-shadow: 0 12px 26px rgba(227, 75, 141, .42); transform: translateY(-1px); }

.btn-ghost {
  background: var(--surface);
  border-color: var(--border-strong);
  color: var(--text-soft);
}
.btn-ghost:hover { border-color: var(--pink-300); color: var(--pink-600); }

.btn-soft {
  background: var(--pink-100);
  color: var(--pink-700);
  border-color: transparent;
}
.btn-soft:hover { background: var(--pink-200); }

.btn-danger-soft {
  background: transparent;
  border-color: var(--border);
  color: var(--text-mute);
}
.btn-danger-soft:hover { border-color: #ff9aa9; color: #d6336c; background: #fff0f2; }

.btn.sm { padding: 7px 13px; font-size: 13px; }

/* ---------- auth area ---------- */
.auth-area { display: flex; align-items: center; gap: 8px; }
.owner-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 6px 5px 12px;
  border-radius: var(--radius-pill);
  border: 1.5px solid var(--pink-200);
  background: var(--surface);
  font-size: 13px;
  font-weight: 700;
  color: var(--pink-700);
  white-space: nowrap;
}
.owner-chip .mini-avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 14px;
  background: linear-gradient(135deg, var(--pink-200), #e7d3ff);
}
.owner-chip button {
  border: none;
  background: transparent;
  color: var(--text-mute);
  cursor: pointer;
  font-size: 12px;
  padding: 4px 8px;
  border-radius: var(--radius-pill);
  font-weight: 700;
}
.owner-chip button:hover { background: var(--pink-100); color: var(--pink-700); }

.login-note {
  margin: 0 0 4px;
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--text-soft);
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
}
.login-note strong { color: var(--pink-600); }
.login-ok {
  background: #e9fbf4;
  border: 1px solid #bfeedd;
  color: #14795f;
  border-radius: 12px;
  padding: 10px 12px;
  margin: 0 0 14px;
  font-size: 13px;
  font-weight: 600;
}
.link-btn {
  background: none;
  border: 0;
  padding: 0;
  color: var(--pink-600);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  text-decoration: underline;
}
.link-btn:hover { color: var(--pink-700); }

.modal-card.narrow { width: min(460px, 100%); }

.owner-panel {
  border: 1.5px dashed var(--pink-300);
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(255, 230, 241, .7), rgba(243, 232, 255, .55));
  padding: 18px 20px;
  margin-bottom: 18px;
}
.owner-panel h3 {
  margin: 0 0 4px;
  font-size: 15.5px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.owner-panel p { margin: 0 0 12px; font-size: 13px; color: var(--text-soft); line-height: 1.6; }
.owner-panel .row { display: flex; gap: 8px; flex-wrap: wrap; }

.lock-hint {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--text-mute);
  padding: 7px 13px;
  border-radius: var(--radius-pill);
  border: 1px dashed var(--border-strong);
  background: var(--surface-2);
}

/* ---------- layout ---------- */
.app {
  flex: 1;
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 30px 22px 70px;
  outline: none;
  animation: fadeUp .45s ease both;
}
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

.page-head { margin-bottom: 26px; }
.page-title {
  margin: 0 0 6px;
  font-size: clamp(24px, 3.4vw, 34px);
  letter-spacing: -.03em;
  font-weight: 700;
}
.page-sub { margin: 0; color: var(--text-soft); font-size: 15px; }

/* ---------- profile hero ---------- */
.hero {
  position: relative;
  border-radius: 26px;
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: var(--shadow-md);
  overflow: hidden;
  margin-bottom: 26px;
}
.hero-cover {
  height: 160px;
  background:
    radial-gradient(circle at 18% 30%, rgba(255,255,255,.55), transparent 45%),
    radial-gradient(circle at 82% 20%, rgba(255,255,255,.35), transparent 40%),
    linear-gradient(115deg, #ffc3dd, #ffa8ce 32%, #e0b8ff 68%, #ffd9c7);
  position: relative;
}
.hero-cover::after {
  content: "✿  ♡  ✦  ❀  ♡  ✿";
  position: absolute;
  inset: auto 0 12px 0;
  text-align: center;
  letter-spacing: 22px;
  color: rgba(255, 255, 255, .65);
  font-size: 14px;
}
.hero-body {
  padding: 0 30px 28px;
  position: relative;
}
.hero-avatar {
  width: 104px;
  height: 104px;
  border-radius: 32px;
  margin-top: -52px;
  display: grid;
  place-items: center;
  font-size: 46px;
  background: linear-gradient(150deg, #fff, var(--pink-100));
  border: 5px solid var(--surface);
  box-shadow: 0 10px 26px rgba(227, 75, 141, .22);
  transform: rotate(-3deg);
}
.hero-top {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 16px;
  justify-content: space-between;
}
.hero-name {
  margin: 14px 0 2px;
  font-size: 30px;
  letter-spacing: -.03em;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.hero-handle { color: var(--text-soft); font-weight: 500; font-size: 17px; }
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 11px;
  border-radius: var(--radius-pill);
  font-size: 12px;
  font-weight: 700;
  background: var(--pink-100);
  color: var(--pink-700);
  border: 1px solid var(--pink-200);
}
.badge.lilac { background: #f2eaff; color: #7c4dcc; border-color: #e3d3ff; }
.badge.mint  { background: #e2fbf4; color: #158a72; border-color: #c2f2e6; }
.badge.new {
  background: linear-gradient(135deg, #ff8fc0, #e34b8d);
  color: #fff;
  border-color: transparent;
  box-shadow: 0 4px 12px rgba(227, 75, 141, .35);
  font-size: 10px;
  letter-spacing: .06em;
  padding: 3px 9px;
  vertical-align: middle;
  animation: badge-pop .5s ease;
}
@keyframes badge-pop {
  0%   { transform: scale(.6); opacity: 0; }
  70%  { transform: scale(1.08); }
  100% { transform: scale(1); opacity: 1; }
}
.badge.draft {
  background: #fff6e0;
  color: #9a6b00;
  border-color: #ffe2a8;
  font-size: 10px;
  letter-spacing: .04em;
  padding: 3px 9px;
  vertical-align: middle;
}
.publish-warn {
  background: #fff6e0;
  border: 1px solid #ffe2a8;
  color: #8a6100;
  border-radius: 12px;
  padding: 10px 12px;
  margin: 0 0 12px !important;
  font-size: 13px !important;
  line-height: 1.5;
}

.hero-bio {
  max-width: 640px;
  margin: 10px 0 18px;
  color: var(--text-soft);
  line-height: 1.6;
  font-size: 15px;
}

.hero-cta {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  padding-top: 14px;
}

.hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.stat-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 15px;
  border-radius: var(--radius-pill);
  background: var(--surface-2);
  border: 1px solid var(--border);
  font-size: 13.5px;
  color: var(--text-soft);
}
.stat-pill strong { color: var(--text); font-size: 15px; }
.stat-pill .dot { color: var(--pink-400); }

/* ---------- toolbar / filters ---------- */
.toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 18px;
}
.toolbar-spacer { flex: 1; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  padding: 7px 14px;
  border-radius: var(--radius-pill);
  border: 1.5px solid var(--border);
  background: var(--surface);
  color: var(--text-soft);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all .2s;
}
.chip:hover { border-color: var(--pink-300); color: var(--pink-600); }
.chip.active {
  background: linear-gradient(135deg, var(--pink-400), var(--pink-600));
  border-color: transparent;
  color: #fff;
  box-shadow: 0 6px 16px rgba(227, 75, 141, .28);
}

.select-wrap { position: relative; }
.select-wrap select {
  appearance: none;
  padding: 9px 34px 9px 14px;
  border-radius: var(--radius-pill);
  border: 1.5px solid var(--border);
  background: var(--surface);
  color: var(--text-soft);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  outline: none;
}
.select-wrap::after {
  content: "▾";
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  color: var(--pink-400);
  font-size: 12px;
}

/* ---------- repo cards ---------- */
.repo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 16px;
}
.repo-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 20px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  transition: transform .2s, box-shadow .2s, border-color .2s;
  overflow: hidden;
}
.repo-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 4px;
  background: linear-gradient(90deg, var(--pink-300), var(--lilac), var(--peach));
  opacity: 0;
  transition: opacity .2s;
}
.repo-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--pink-200);
}
.repo-card:hover::before { opacity: 1; }

.repo-card.featured {
  background:
    linear-gradient(180deg, rgba(255, 230, 241, .6), transparent 60%),
    var(--surface);
}
.repo-card.featured::before { opacity: 1; }

.repo-head {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}
.repo-icon {
  width: 38px;
  height: 38px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: var(--pink-100);
  font-size: 18px;
}
.repo-name {
  margin: 0;
  font-size: 16.5px;
  font-weight: 700;
  letter-spacing: -.01em;
  color: var(--text);
  word-break: break-word;
}
.repo-file {
  display: block;
  font-family: var(--mono);
  font-size: 11.5px;
  color: var(--text-mute);
  margin-top: 2px;
}
.repo-desc {
  margin: 0;
  color: var(--text-soft);
  font-size: 13.5px;
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 42px;
}
.repo-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: var(--radius-pill);
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text-soft);
}
.repo-foot {
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px dashed var(--border);
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 12px;
  color: var(--text-mute);
  flex-wrap: wrap;
}
.repo-foot .meta { display: inline-flex; align-items: center; gap: 5px; }
.repo-foot .lang-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--pink-500);
  display: inline-block;
}
.star-btn {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 11px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--text-soft);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all .18s;
}
.star-btn:hover { border-color: var(--pink-300); color: var(--pink-600); }
.star-btn.starred {
  background: #fff0f6;
  border-color: var(--pink-300);
  color: var(--pink-600);
}
.star-btn.starred .star-glyph { animation: pop .35s ease; }
@keyframes pop { 0% { transform: scale(1); } 50% { transform: scale(1.5) rotate(18deg); } 100% { transform: scale(1); } }

.empty-state {
  text-align: center;
  padding: 60px 20px;
  border: 1.5px dashed var(--border-strong);
  border-radius: var(--radius);
  background: var(--surface-2);
  color: var(--text-soft);
}
.empty-state .big { font-size: 42px; display: block; margin-bottom: 10px; }
.empty-state h3 { margin: 0 0 6px; color: var(--text); }
.empty-state p { margin: 0 0 18px; font-size: 14px; }

/* ---------- detail view ---------- */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  color: var(--text-mute);
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.breadcrumb a { color: var(--pink-600); font-weight: 600; }
.breadcrumb .sep { color: var(--pink-300); }

.detail-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 18px;
}
.detail-head h1 {
  margin: 0;
  font-size: clamp(22px, 3vw, 30px);
  letter-spacing: -.03em;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.detail-actions { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; }

.panel {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  margin-bottom: 18px;
}
.panel-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 18px;
  background: var(--surface-2);
  border-bottom: 1px solid var(--border);
  font-size: 13px;
  font-weight: 700;
  color: var(--text-soft);
  flex-wrap: wrap;
}
.panel-head .file-name { font-family: var(--mono); color: var(--text); font-size: 12.5px; }
.panel-head .right { margin-left: auto; display: flex; gap: 8px; align-items: center; }
.panel-body { padding: 18px; }
.panel-body p { margin: 0 0 12px; color: var(--text-soft); line-height: 1.65; font-size: 14.5px; }
.panel-body p:last-child { margin-bottom: 0; }

.meta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
}
.meta-box {
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  border: 1px solid var(--border);
}
.meta-box .k { font-size: 11px; text-transform: uppercase; letter-spacing: .07em; color: var(--text-mute); font-weight: 700; }
.meta-box .v { font-size: 15px; font-weight: 700; margin-top: 3px; }

/* ---------- code viewer ---------- */
.code-wrap {
  position: relative;
  background: var(--code-bg);
  overflow: auto;
  max-height: 640px;
  border-radius: 0;
}
.code-wrap pre {
  margin: 0;
  padding: 18px 20px 22px;
  font-family: var(--mono);
  font-size: 12.5px;
  line-height: 1.65;
  color: var(--code-text);
  tab-size: 4;
}
.code-line { display: block; white-space: pre; }
.code-line .ln {
  display: inline-block;
  width: 3.4em;
  margin-right: 14px;
  text-align: right;
  color: #8a6b7c;
  user-select: none;
}
.code-wrap pre code { font: inherit; }

/* simple lua highlight */
.tok-com { color: #a98ea0; font-style: italic; }
.tok-str { color: #ffb3d3; }
.tok-num { color: #ffd9a0; }
.tok-kw  { color: #c9a7ff; font-weight: 500; }
.tok-fn  { color: #9fe6ff; }
.tok-bool { color: #ff9e9e; }

.code-note {
  padding: 10px 18px;
  font-size: 12px;
  color: var(--text-mute);
  border-top: 1px solid var(--border);
  background: var(--surface-2);
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

/* ---------- about ---------- */
.about-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
}
.feature {
  padding: 22px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}
.feature .ico {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  font-size: 20px;
  margin-bottom: 12px;
  background: linear-gradient(135deg, var(--pink-100), #f3e8ff);
}
.feature h3 { margin: 0 0 6px; font-size: 16px; }
.feature p { margin: 0; color: var(--text-soft); font-size: 14px; line-height: 1.6; }

.steps { counter-reset: step; display: grid; gap: 12px; }
.step {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 16px 18px;
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  border: 1px solid var(--border);
}
.step::before {
  counter-increment: step;
  content: counter(step);
  flex-shrink: 0;
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--pink-400), var(--pink-600));
  color: #fff;
  font-weight: 700;
  font-size: 14px;
}
.step h4 { margin: 2px 0 4px; font-size: 14.5px; }
.step p { margin: 0; color: var(--text-soft); font-size: 13.5px; line-height: 1.55; }

.notice {
  display: flex;
  gap: 12px;
  padding: 14px 18px;
  border-radius: var(--radius-sm);
  background: #fff6e9;
  border: 1px solid #ffe0b8;
  color: #8a5a1a;
  font-size: 13.5px;
  line-height: 1.6;
}
html[data-theme="dark"] .notice { background: #33261a; border-color: #5c4426; color: #ffd9a0; }

/* ---------- footer ---------- */
.footer {
  border-top: 1px solid var(--border);
  background: color-mix(in srgb, var(--bg-soft) 70%, transparent);
  backdrop-filter: blur(8px);
}
.footer-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 26px 22px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 26px;
  font-size: 13px;
  color: var(--text-mute);
}
.footer-brand { display: flex; align-items: center; gap: 10px; }
.footer-brand p { margin: 0; }
.footer-brand strong { color: var(--pink-600); }
.heart { color: var(--pink-500); }
.footer-note { margin: 0; flex: 1; min-width: 220px; }
.footer-links { display: flex; gap: 16px; }
.footer-links a { color: var(--text-soft); font-weight: 600; }
.footer-links a:hover { color: var(--pink-600); }

/* ---------- modal ---------- */
.modal[hidden] { display: none; }
.modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 20px;
}
.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(74, 43, 60, .38);
  backdrop-filter: blur(4px);
  animation: fadeIn .2s ease;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

.modal-card {
  position: relative;
  width: min(760px, 100%);
  max-height: 92vh;
  overflow: auto;
  border-radius: 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
  animation: modalIn .28s cubic-bezier(.2, .9, .3, 1.2);
}
@keyframes modalIn {
  from { opacity: 0; transform: translateY(18px) scale(.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.modal-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 20px 24px 0;
}
.modal-head h2 { margin: 0; font-size: 20px; letter-spacing: -.02em; }
.modal-head .spark { color: var(--pink-400); }
.modal-head .icon-btn { margin-left: auto; border: none; background: transparent; }

.post-form { padding: 20px 24px 24px; display: grid; gap: 14px; }
.post-form label { display: grid; gap: 6px; font-size: 13px; font-weight: 700; color: var(--text-soft); }
.post-form label small { font-weight: 500; color: var(--text-mute); }
.post-form input[type="text"],
.post-form input[type="password"],
.post-form input[type="search"],
.post-form input:not([type]),
.post-form textarea {
  width: 100%;
  padding: 11px 14px;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--border);
  background: var(--surface-2);
  color: var(--text);
  outline: none;
  transition: border-color .2s, box-shadow .2s;
  font-weight: 500;
}
.post-form input[readonly] { color: var(--text-soft); font-family: var(--mono); font-size: 12.5px; }
.post-form input:focus, .post-form textarea:focus {
  border-color: var(--pink-300);
  box-shadow: 0 0 0 4px rgba(255, 143, 192, .16);
}
.post-form textarea { resize: vertical; font-family: inherit; }
.post-form textarea#codeInput { font-family: var(--mono); font-size: 12.5px; line-height: 1.6; background: var(--code-bg); color: var(--code-text); border-color: #4a2f3d; }
.post-form input[type="file"] {
  padding: 9px;
  border: 1.5px dashed var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  font-size: 12.5px;
  color: var(--text-soft);
  cursor: pointer;
  width: 100%;
}
.post-form input[type="file"]::file-selector-button {
  border: none;
  border-radius: var(--radius-pill);
  padding: 6px 12px;
  margin-right: 10px;
  background: var(--pink-100);
  color: var(--pink-700);
  font-weight: 700;
  font-size: 12px;
  cursor: pointer;
}
.form-row.two { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.code-label { grid-column: 1 / -1; }
.form-foot {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  padding-top: 6px;
}
.form-hint { font-size: 12px; color: var(--text-mute); }
.form-actions { margin-left: auto; display: flex; gap: 8px; }

/* ---------- toast ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 26px;
  transform: translate(-50%, 24px);
  padding: 12px 20px;
  border-radius: var(--radius-pill);
  background: linear-gradient(135deg, var(--pink-500), var(--pink-700));
  color: #fff;
  font-size: 13.5px;
  font-weight: 700;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s, transform .25s;
  z-index: 200;
  max-width: min(90vw, 460px);
  text-align: center;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .topnav { display: none; }
  .topbar-inner { gap: 12px; }
}
@media (max-width: 680px) {
  .topbar-inner { padding: 12px 16px; flex-wrap: wrap; }
  .search-wrap { order: 3; flex-basis: 100%; max-width: none; }
  .topbar-actions { margin-left: auto; }
  .app { padding: 22px 16px 60px; }
  .hero-body { padding: 0 18px 22px; }
  .hero-avatar { width: 86px; height: 86px; font-size: 38px; border-radius: 26px; }
  .hero-name { font-size: 25px; }
  .repo-grid { grid-template-columns: 1fr; }
  .form-row.two { grid-template-columns: 1fr; }
  .detail-actions { margin-left: 0; width: 100%; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
  #newPostBtn span.plus { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}
