﻿:root {
  --bg1: #101112;
  --bg2: #202122;
  --text1: #f0f6fc;
  --text2: #d0d6dc;
  --text3: #b0b6bc;
}


* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

                           html {font-size: 10px;}
@media (min-width: 500px) {html {font-size: 12px;} }
@media (min-width: 800px) {html {font-size: 14px;} }


body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, "SimSun", "宋体", sans-serif;
    background-color: var(--bg1);
    color: var(--text1);
    min-height: 100vh;
    padding: 20px;
    display: flex;
    justify-content: center;
    gap: 20px;
}

main {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 100%;
    max-width: 800px;
}

.main-container {
    background-color: var(--bg2);
    border: 1px solid #30363d;
    border-radius: 8px;
    padding: 24px;
}

h1 {
    color: var(--text1);
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 12px;
}

h2 {
    color: var(--text1);
    font-size: 1.5rem;
    margin-bottom: 16px;
}

p > a {
    color: inherit;
    text-decoration: underline;
    font-weight: 500;
}

p > a:hover {
    color: inherit;
    text-decoration: none;
    font-weight: 500;
}

p {
    color: var(--text2);
    font-size: 1rem;
    margin-bottom: 8px;
}

p.project-name {
    font-size: 1.1rem;
    color: var(--text1);
}

#commits {
    max-height: 350px;
    overflow-y: auto;
    overflow-x: hidden;
    scrollbar-width: thin;
    scrollbar-color: #30363d var(--bg2);
}

#commits::-webkit-scrollbar {
    width: 8px;
}

#commits::-webkit-scrollbar-track {
    background: var(--bg2);
    border-radius: 4px;
}

#commits::-webkit-scrollbar-thumb {
    background: #30363d;
    border-radius: 4px;
}

#commits::-webkit-scrollbar-thumb:hover {
    background: #484f58;
}

#masters {
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: thin;
    scrollbar-color: #30363d var(--bg2);
}

#masters::-webkit-scrollbar {
    height: 8px;
}

#masters::-webkit-scrollbar-track {
    background: var(--bg2);
    border-radius: 4px;
}

#masters::-webkit-scrollbar-thumb {
    background: #30363d;
    border-radius: 4px;
}

#masters::-webkit-scrollbar-thumb:hover {
    background: #484f58;
}

#masters .items-list {
    display: flex;
    gap: 16px;
    padding: 8px 0;
}

#masters .items {
    min-width: 280px;
    max-width: 320px;
    flex-shrink: 0;
    background-color: var(--bg1);
    border: 1px solid #30363d;
    border-radius: 8px;
    padding: 16px;
}

.loading {
    text-align: center;
    padding: 40px;
    color: var(--text2);
    font-size: 1rem;
}

.loading::after {
    content: '';
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid #30363d;
    border-top-color: #58a6ff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: 8px;
    vertical-align: middle;
}

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

.items-list {
    list-style: none;
}

.items {
    padding: 12px;
    transition: background-color 0.15s ease;
}

.items:hover {
    background-color: #1c1d1e;
}

.repo-name {
    color: var(--text1);
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.repo-description {
    color: var(--text3);
    font-size: 0.9rem;
    line-height: 1.4;
}

.repo-homepage {
    color: var(--text3);
    font-size: 0.9rem;
    margin-bottom: 14px;
}

.repo-lang {
    color: #58a6ff;
    font-size: 0.8rem;
    margin-bottom: 0;
}

.repo-created {
    color: var(--text3);
    font-size: 0.8rem;
    margin-bottom: 0;
}

.commit-title {
    color: var(--text1);
    font-size: 1.1rem;
    margin-bottom: 6px;
    line-height: 1.2;
}

.commit-description {
    color: var(--text3);
    font-size: 0.8rem;
    margin-bottom: 8px;
    line-height: 1.0;
}

.items > span {
    display: flex;
    align-items: center;
    gap: 10px;
}

.commit-time {
    color: var(--text2);
    font-size: 1rem;
}

.commit-author {
    color: var(--text2);
    font-size: 1rem;
}

.error-message {
    text-align: center;
    padding: 40px;
    color: #f85149;
    font-size: 1.1rem;
}

aside {
    width: 80px;
    background-color: var(--bg2);
    border: 1px solid #30363d;
    border-radius: 8px;
    padding: 20px 15px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 25px;
}

aside a {
    display: block;
    color: var(--text1);
    opacity: 0.8;
    transition: opacity 0.15s ease;
}

aside a:hover {
    opacity: 1;
}
#bilibili .bili-scroll {
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: thin;
    scrollbar-color: #30363d var(--bg2);
}
#bilibili .bili-scroll::-webkit-scrollbar { height: 8px; }
#bilibili .bili-scroll::-webkit-scrollbar-track { background: var(--bg2); border-radius: 4px; }
#bilibili .bili-scroll::-webkit-scrollbar-thumb { background: #30363d; border-radius: 4px; }
#bilibili .bili-scroll::-webkit-scrollbar-thumb:hover { background: #484f58; }
#bilibili .items-list {
    display: flex;
    gap: 16px;
    padding: 8px 0;
}
#bilibili .bili-card {
    min-width: 400px;
    max-width: 480px;
    flex-shrink: 0;
    background-color: var(--bg1);
    border: 1px solid #30363d;
    border-radius: 8px;
    padding: 8px;
}
.bili-card iframe {
    width: 100%;
    height: 238px;
    border: 0;
    display: block;
    border-radius: 6px;
}
