* {
    box-sizing: border-box;
}

:root {
    --bg: #f3f4f6;
    --card: #ffffff;
    --text: #111827;
    --muted: #4b5563;
    --border: #e5e7eb;
    --shadow: 0 8px 24px rgba(0,0,0,.06);
}

body {
    margin: 0;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.5;
}

a {
    color: inherit;
    text-decoration: none;
}

.wrap {
    max-width: 100vw;
    margin: 0 auto;
    padding: 1.5rem;
}

.site-header {
    background: linear-gradient(135deg, #111827, #1f2937);
    color: #fff;
    padding: 1.25rem 0;
    margin-bottom: 1.5rem;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.eyebrow {
    margin: 0 0 .25rem;
    font-size: .8rem;
    text-transform: uppercase;
    letter-spacing: .12em;
    opacity: .75;
}

.site-title {
    margin: 0;
    font-size: 1.8rem;
    line-height: 1.1;
}

.site-nav a {
    display: inline-block;
    padding: .6rem .9rem;
    border: 1px solid rgba(255,255,255,.2);
    border-radius: 999px;
    transition: background .15s ease, border-color .15s ease;
}

.site-nav a:hover {
    background: rgba(255,255,255,.08);
    border-color: rgba(255,255,255,.35);
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.25rem;
    align-items: stretch;
}

.tile,
.detail {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 18px;
    box-shadow: var(--shadow);
}

.tile {
    position: relative;
    overflow: hidden;
    height: 100%;
    display: flex;
    flex-direction: column;
    padding: 1rem;
    transition: transform .15s ease, box-shadow .15s ease;
    min-height: 100%;
}

.tile:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 28px rgba(0,0,0,.10);
}

.tile::before {
    content: "";
    position: absolute;
    inset: 0 0 auto 0;
    height: 5px;
    background: var(--accent, #2563eb);
}

.tile-top {
    height: 0px;
    border-radius: 14px;
    margin-bottom: .9rem;
    background: linear-gradient(135deg, color-mix(in srgb, var(--accent, #2563eb) 18%, white), white);
}


.detail img {
    width: 100%;
    object-fit: cover;
    object-position: center;
    border-radius: 12px;
    background: #e5e7eb;
}

.tile img {
    width: 50%;
    height: auto;
    object-fit: cover;
    object-position: center;
    border-radius: 12px;
    margin-bottom: .9rem;
    background: #e5e7eb;
}

.tile h2 {
    display: flex;
    align-items: center;
    gap: .55rem;
    margin: 0 0 .5rem;
    font-size: 1.15rem;
    line-height: 1.2;
}

.dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--accent, #2563eb);
    flex: none;
}

.tile p {
    margin: 0;
    color: var(--muted);
    word-wrap: break-word;
}

.warn {
    display: inline-block;
    margin-top: .75rem;
    color: #b91c1c;
    font-weight: 700;
}

.detail {
    position: relative;
    padding: 1.25rem;
    border-top: 5px solid var(--accent, #2563eb);
}

.detail img {
    max-height: 360px;
    margin-bottom: 1rem;
}

.detail h1 {
    margin-top: 0;
}

.detail p,
.detail li {
    color: var(--text);
}

.site-footer {
    padding: 2rem 0;
    color: var(--muted);
    font-size: .95rem;
}

@media (max-width: 640px) {
    .header-inner {
        flex-direction: column;
        align-items: flex-start;
    }

    .site-title {
        font-size: 1.5rem;
    }

    .tile img {
        height: auto;
    }
}

.readme-preview {
    margin: .75rem 0 0;
    padding: .85rem;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    color: var(--muted);
    font-size: .9rem;
    line-height: 1.45;
    white-space: pre-wrap;
    word-break: break-word;
    overflow: auto;
    height: 160px;
    max-height: 260px;

}
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.25rem;
    align-items: stretch;
}