/* --- Global Styles & Variables --- */

/* Define a color palette for a dark, mysterious theme */
:root {
    --background-color: #121212; /* A very dark grey, not pure black */
    --text-color: #EAEAEA;       /* A soft, off-white for text */
    --primary-color: #BB86FC;    /* A subtle accent color for links (optional) */
    --secondary-color: #333333;  /* A slightly lighter grey for borders/backgrounds */
}

/* Apply a base reset and smooth scrolling */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth; /* For smooth navigation when clicking on nav links */
}

body {
    /* 'IBM Plex Mono' for the terminal feel, with a generic monospace fallback */
    font-family: 'IBM Plex Mono', monospace;
    background-color: var(--background-color);
    color: var(--text-color);
    line-height: 1.6;
}

/* --- Layout: Header, Main, Footer --- */

/* Center the content and limit its width for better readability on large screens */
header, main, footer {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 40px;
    padding-bottom: 40px;
    border-bottom: 1px solid var(--secondary-color);
}

section {
    padding: 60px 0; /* Add vertical space between sections */
}

footer {
    text-align: center;
    font-size: 0.9em;
    color: #888;
    margin-top: 40px;
    border-top: 1px solid var(--secondary-color);
}

/* --- Typography & Links --- */

h1, h2, h3 {
    /* 'Special Elite' for the typewriter feel, with a generic cursive fallback */
    font-family: 'Special Elite', cursive;
    line-height: 1.2;
    margin-bottom: 10px;
}

h1 {
    font-size: 2.5em;
}

h2 {
    font-size: 2em;
    margin-bottom: 20px;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease; /* Smooth color change on hover */
}

a:hover {
    color: var(--text-color);
}

/* --- Navigation --- */

nav ul {
    list-style-type: none; /* Remove bullet points */
    display: flex;
    gap: 20px; /* Space between navigation items */
}

nav a {
    color: var(--text-color);
    font-weight: bold;
    padding: 5px 0;
    border-bottom: 2px solid transparent; /* Prepare for a hover effect */
    transition: border-color 0.3s ease;
}

nav a:hover {
    border-bottom-color: var(--primary-color); /* Highlight on hover */
}

/* --- Project Section & Cards --- */

/* Add space below the main description paragraph in the projects section */
#projects > p {
    margin-bottom: 40px;
}

/* Style each project as a card */
#projects article {
    background-color: #1a1a1a; /* A slightly lighter dark shade for the card */
    border: 1px solid var(--secondary-color);
    border-radius: 8px; /* Rounded corners */
    padding: 25px;
    margin-bottom: 20px;
    transition: transform 0.3s ease, border-color 0.3s ease; /* Smooth transition for hover */
}

/* Add a subtle lift and highlight effect on hover */
#projects article:hover {
    transform: translateY(-5px);
    border-color: var(--primary-color);
}

/* --- Responsive Design --- */

/* Styles for screens 680px or smaller (tablets and mobile phones) */
@media (max-width: 680px) {

    /* Reduce padding on the main containers for more space */
    header, main, footer {
        padding-left: 15px;
        padding-right: 15px;
    }

    /* Stack the header items vertically */
    header {
        flex-direction: column;
        gap: 25px; /* Space between title and nav */
    }

    /* Stack the navigation links and center them */
    nav ul {
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }

}
