/* =====================================================================
   matteopasotti.it — site styles
   ===================================================================== */

:root {
    --clr-dotnet:  #512bd4;
    --clr-mageia:  #1f5c99;
    --clr-python:  #306998;
    --clr-accent:  #0dcaf0;
    --clr-dark:    #1a1a2e;
}

/* ----- Hero ---------------------------------------------------------- */

.hero {
    background: linear-gradient(135deg, var(--clr-dark) 0%, #16213e 100%);
    color: #fff;
}

.text-accent { color: var(--clr-accent) !important; }

/* ----- Topic cards --------------------------------------------------- */

.topic-card {
    color: #fff;
    transition: opacity .15s;
}
.topic-card:hover { opacity: .88; }

.topic-dotnet  { background-color: var(--clr-dotnet); }
.topic-mageia  { background-color: var(--clr-mageia); }
.topic-python  { background-color: var(--clr-python); }
.topic-general { background-color: #495057; }

/* ----- Category badge colours ---------------------------------------- */

.badge-dotnet  { background-color: var(--clr-dotnet)  !important; color: #fff !important; }
.badge-mageia  { background-color: var(--clr-mageia)  !important; color: #fff !important; }
.badge-python  { background-color: var(--clr-python)  !important; color: #fff !important; }

/* Coloured icons in nav / about */
.text-dotnet { color: var(--clr-dotnet) !important; }
.text-mageia { color: var(--clr-mageia) !important; }
.text-python { color: var(--clr-python) !important; }

/* ----- Post cards ---------------------------------------------------- */

.post-card {
    border: 1px solid rgba(0,0,0,.08);
    box-shadow: 0 2px 6px rgba(0,0,0,.06);
    transition: transform .15s, box-shadow .15s;
    color: inherit;
}
.post-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(0,0,0,.1);
    color: inherit;
}

/* ----- Post content -------------------------------------------------- */

.post-content { font-size: 1.05rem; line-height: 1.75; }

.post-content h2 { margin-top: 2rem;   font-weight: 700; }
.post-content h3 { margin-top: 1.5rem; font-weight: 600; }
.post-content h4 { margin-top: 1.25rem; }

.post-content pre {
    background: #0d1117;
    border-radius: .5rem;
    padding: 1.25rem;
    overflow-x: auto;
}
.post-content :not(pre) > code {
    background: #f3f4f6;
    color: #d63384;
    padding: .15em .4em;
    border-radius: .25rem;
    font-size: .9em;
}
.post-content img {
    max-width: 100%;
    border-radius: .5rem;
    display: block;
    margin: 1.5rem auto;
}
.post-content blockquote {
    border-left: 4px solid var(--clr-accent);
    padding-left: 1rem;
    color: #6c757d;
    margin: 1.5rem 0;
}
.post-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5rem 0;
}
.post-content th,
.post-content td {
    border: 1px solid #dee2e6;
    padding: .5rem .75rem;
}
.post-content th { background: #f8f9fa; }

/* ----- Footer -------------------------------------------------------- */

.site-footer {
    background: var(--clr-dark);
    color: rgba(255,255,255,.65);
}
.footer-link {
    color: var(--clr-accent);
    text-decoration: none;
}
.footer-link:hover { text-decoration: underline; }
