:root {
    --bg: #07070a;
    --panel: #0f1114;
    --gold: #b88a2d;
    --muted: #cfc7bb;
    --glass: rgba(255, 255, 255, 0.03);
}

html, body {
    height: 100%;
    margin: 0;
    font-family: Montserrat, system-ui, Segoe UI, Roboto, Arial;
    background: linear-gradient(180deg, #050507 0%, #0b0b0f 70%);
    color: var(--muted)
}

/* parchment overlay */
body::after {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background-image: linear-gradient(180deg, rgba(0, 0, 0, 0.08), transparent 40%), url('https://images.unsplash.com/photo-1504674900247-0877df9cc836?q=80&w=1600&auto=format&fit=crop&s=6ad5d8da7f5b8e7b3c4f3b2f9f1d2b3a');
    background-size: cover;
    opacity: 0.04;
    mix-blend-mode: overlay
}

header {
    position: sticky;
    top: 0;
    z-index: 60;
    background: linear-gradient(180deg, rgba(6, 6, 8, 0.6), rgba(6, 6, 8, 0.35));
    backdrop-filter: blur(4px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}

.nav {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 20px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px
}

.brand .sig {
    font-family: Cinzel, serif;
    font-size: 20px;
    color: var(--gold)
}

nav a {
    color: var(--muted);
    text-decoration: none;
    padding: 8px 12px;
    border-radius: 6px;
    font-weight: 600
}

.nav-link {
    color: var(--muted);
}

nav a:hover {
    color: var(--text);
    background: rgba(255, 255, 255, 0.02);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.6) inset
}

/* blurred fixed background image like original */
#backgroundImage {
    position: fixed;
    inset: 0;
    background-image: url('rsc/imgs/background-test-image.jpg');
    background-position: center;
    background-size: cover;
    background-attachment: fixed;
    z-index: -100;
    filter: blur(10px);
    opacity: 0.28
}

/* page wrapper */
.wrap {
    max-width: 1200px;
    margin: 40px auto;
    padding: 16px
}

h1.section-title {
    font-family: Cinzel, serif;
    color: var(--gold);
    text-align: center;
    margin-bottom: 28px
}

/* project card */
.project-card {
    width: 100%;
    max-width: 320px;
    margin: 0 auto;
    border-radius: 12px;
    overflow: hidden;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(255, 255, 255, 0.01));
    border: 1px solid rgba(255, 255, 255, 0.03);
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.6);
    transition: transform .22s ease, box-shadow .22s ease
}

.project-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 28px 60px rgba(0, 0, 0, 0.7)
}

.project-card img {
    width: 100%;
    height: 190px;
    object-fit: cover;
    background: white
}

.project-body {
    padding: 14px
}

.project-body h4 {
    font-family: Cinzel, serif;
    margin: 8px 0;
    color: var(--gold);
    text-align: center
}

.project-body p {
    color: var(--muted);
    font-size: 14px;
    min-height: 56px
}

/* tools row */
.tools-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-top: 12px
}

.tool-badge {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    background: var(--glass);
    border: 1px solid rgba(255, 255, 255, 0.02);
    overflow: hidden;
}

.tool-badge img {
    width: 28px;
    height: 28px;
    aspect-ratio: 1/1;
    object-fit: contain;
    background-color: transparent;
}

/* grid */
.grid {
    display: grid;
    grid-template-columns:repeat(auto-fit, minmax(260px, 1fr));
    gap: 22px;
    align-items: start
}

/* modal (uses Bootstrap modal styles but enhance visuals) */
.modal-content {
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.85), rgba(0, 0, 0, 0.5));
    border: 1px solid rgba(255, 255, 255, 0.03);
    color: var(--muted)
}

.modal-header {
    border-bottom: 1px solid rgba(255, 255, 255, 0.03)
}

.modal-title {
    font-family: Cinzel, serif;
    color: var(--gold)
}

.modal-body p {
    color: var(--muted)
}

/* responsive tweaks */
@media (max-width: 768px) {
    .project-card img {
        height: 160px
    }
}