/* Remove Base Style */

* {
    margin: 0;
    padding: 0;
}

/* Variables */
:root {
    --bg: #0f172a;
    --card-bg: #1f2937;
    --text-main: #e5e7eb;
    --text-secondary: #9ca3af;
    --accent: #3b82f6;
}

/* Base Page Style */
body {
    font-family: system-ui, sans-serif;
    background-color: var(--bg);
    color: var(--text-main);
    line-height: 1.6;
}

html {
    scroll-behavior: smooth;
}

/* Margins and Width */
main,
header,
footer {
    width: min(90%, 1100px);
    margin: 0 auto;
}

header,
footer {
    padding: 2rem;
}

main {
    padding: 2rem;
}

section {
    margin-bottom: 3rem;
}

/* Text Style */
h1, h2, h3 {
    line-height: 1.2;
    margin-bottom: 1rem;
}

h1 {
    font-size: 3.5rem
}

h2 {
    font-size: 1.8rem;
}

p {
    color: var(--text-secondary);
}

a {
    color: var(--accent);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* Navbar */
nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

nav ul {
    list-style: none;
    display: flex;
    gap: 2rem;
}

/* presentation */
.presentation {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* Tech Stack */
.tech-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tech-stack div {
    position: relative;
    display: flex;
    justify-content: center;
}

.tech-stack img {
    width: 48px;
    height: 48px;
    filter: brightness(0.9);
    transition: filter 0.3s;
}

.tech-stack img:hover {
    filter: brightness(1);
}

.tooltip {
    visibility: hidden;
    background-color: var(--card-bg);
    color: var(--text-main);
    font-weight: bold;
    text-align: center;
    padding: 5px 10px;
    position: absolute;
    bottom: 110%;
    opacity: 0;
    transition: opacity 0.4s;
    white-space: nowrap;
    border: 1px solid var(--accent);
    font-size: 0.9rem;
    pointer-events: none;
}

.tech-stack div:hover .tooltip {
    visibility: visible;
    opacity: 1;
}

/* Project List */
#projects > a{
    display: block;
    padding-bottom: 15px;
}

#projects p{
    padding-bottom: 10px;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-row-gap: 50px;
    grid-column-gap: 1rem;
}

@media (max-width: 768px) {
    .projects-grid {
        grid-template-columns: 1fr;
    }
}

/* Project Card */

.projects-grid article {
    background-color: var(--card-bg);
    padding: 2rem;
    border-radius: 8px;
    transition: 0.3s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
    justify-content: space-between;
}

.card-links {
    border-top: solid 1px var(--text-secondary);
    margin-top: 10px;
    display: flex;
    justify-content: space-between;
}

.card-links a {
    display: block;
}

.projects-grid article:hover {
    transform: scale(1.05);
}

/* Footer */
footer {
    border-top: 1px solid var(--accent);
    padding-top: 2rem;
    text-align: center;
    color: var(--text-secondary);
}