/* === GLOBAL STYLES === */
:root {
    /* Egyptian-Inspired Dark Palette */
    --bg-color: #1b1a17;
    --container-color: #2c2a26;
    --text-color: #eae6e0;
    --text-secondary: #a39e93;
    --accent-primary: #d4af37;
    --accent-secondary: #265a8a;

    --font-body: "Inter", sans-serif;
    --font-mono: "Source Code Pro", monospace;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-body);
    font-weight: 400; /* Inter Regular */
    line-height: 1.7;
}

/* === LAYOUT & SECTIONS === */
.content {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 40px;
}

section {
    min-height: 100vh;
    padding: 100px 0;
    border-bottom: 1px solid var(--container-color);
}

section:last-child {
    border-bottom: none;
}

/* === RIGHT-SIDE NAVIGATION === */
.side-nav {
    position: fixed;
    top: 50%;
    right: 30px;
    transform: translateY(
        -50%
    ); /* ...then pull it back up by half its own height to perfectly center it */

    /* Card styling */
    width: auto; /* Width will be based on its content */
    background-color: var(--container-color);
    border-radius: 8px; /* Rounded corners */
    padding: 20px 15px; /* Add some internal spacing */
    border-top: 3px solid var(--accent-primary);
    border-bottom: 3px solid var(--accent-primary);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3); /* Lifts it off the page */
}

.side-nav ul {
    list-style: none;
}

.side-nav li {
    margin: 15px 0; /* Reduced margin for a more compact card */
    text-align: center;
}

.side-nav a {
    text-decoration: none;
    font-family: var(--font-body);
    font-weight: 500; /* Inter Medium */
    font-size: 1.1rem;
    padding: 5px 10px;
    position: relative;
    transition: all 0.3s ease;

    /* Start in the "inactive" state */
    color: var(--text-secondary);
    transform: scale(1);
    opacity: 0.7;
}

/* --- Nav Hover Effect --- */
.side-nav a::before,
.side-nav a::after {
    content: "[";
    position: absolute;
    color: var(--accent-primary);
    opacity: 0;
    transition: all 0.3s ease;
}

.side-nav a::after {
    content: "]";
    right: -15px;
}

.side-nav a::before {
    left: -15px;
}

.side-nav a:hover {
    color: var(--text-color);
    opacity: 1;
}

.side-nav a:hover::before {
    opacity: 1;
    left: -25px;
}

.side-nav a:hover::after {
    opacity: 1;
    right: -25px;
}

/* JS scrollspy */
.side-nav a.active {
    color: var(--accent-primary);
    transform: scale(1.1);
    opacity: 1;
}

/* === TYPOGRAPHY & CONTENT STYLING === */
h1 {
    font-family: var(--font-body);
    font-weight: 700; /* Inter Bold */
    font-size: 3.5rem;
    color: #ffffff;
    margin-bottom: 10px;
}

.tagline {
    font-family: var(--font-body);
    font-weight: 300; /* Inter Light */
    font-size: 1.5rem;
    font-style: italic;
    color: var(--text-secondary);
    margin-bottom: 30px;
}

h2 {
    font-family: var(--font-body);
    font-weight: 700; /* Inter Bold */
    font-size: 2.5rem;
    color: var(--accent-primary);
    margin-bottom: 40px;
    border-bottom: 2px solid #333;
    padding-bottom: 10px;
}

/* Style for the "//" mono accent */
h2 .mono {
    font-family: var(--font-mono);
    font-weight: 400;
    color: var(--text-secondary);
    margin-right: 10px;
}

h3 {
    font-family: var(--font-body);
    font-weight: 700; /* Inter Bold */
    font-size: 1.5rem;
    color: var(--accent-secondary);
    margin-bottom: 10px;
}

p {
    font-size: 1.1rem;
    margin-bottom: 20px;
    max-width: 80ch;
}

/* === SECTION-SPECIFIC STYLES === */

/* === SKILLS LIST STYLES (in Introduction) === */

/* Adds spacing above the new "Core Skills" heading */
#introduction h3 {
    margin-top: 40px;
    margin-bottom: 20px;
}

.skills-list {
    display: flex; /* Makes the list horizontal */
    flex-wrap: wrap; /* Allows skills to flow to the next line */
    list-style: none; /* Removes bullets */
    padding: 0;
    margin: 0;
    gap: 12px; /* Spacing between skill tags */
}

.skills-list li {
    background-color: var(--container-color);
    color: var(--text-color);
    padding: 8px 16px;
    border-radius: 20px;
    font-family: var(--font-mono);
    font-size: 0.9rem;
    border: 1px solid var(--accent-secondary);
    transition: all 0.2s ease;
}

.skills-list li:hover {
    background-color: var(--accent-secondary);
    color: #fff;
    transform: scale(1.05);
}

/* --- Projects --- */
.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.project-card {
    background-color: var(--container-color);
    padding: 25px;
    border-radius: 8px;
    border-left: 5px solid var(--accent-secondary);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

.project-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
}

.project-card .tech-stack {
    font-family: var(--font-mono);
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.project-card .tech-stack strong {
    color: var(--accent-secondary);
}

/* === WORK EXPERIENCE STYLES === */

.experience-list {
    display: flex;
    flex-direction: column;
    gap: 40px; /* Space between each job item */
}

.experience-item {
    padding-left: 20px;
    border-left: 3px solid var(--accent-primary); /* Gold border, same as Education */
}

.experience-item h3 {
    color: #fff; /* Make the title white */
    font-weight: 700;
}

.experience-item .company-info {
    color: var(--text-secondary);
    font-style: italic;
    font-size: 1rem;
    margin-bottom: 15px;
}

/* Style the achievement list */
.experience-item ul {
    list-style: none; /* Remove default bullets */
    padding-left: 10px;
}

.experience-item li {
    position: relative;
    padding-left: 30px; /* Space for the custom bullet */
    margin-bottom: 10px;
    font-size: 1.1rem;
    line-height: 1.6;
}

/* Custom bullet point, same as "Interests" section */
.experience-item li::before {
    content: "»";
    position: absolute;
    left: 0;
    top: 0;
    color: var(--accent-primary);
    font-weight: bold;
    font-size: 1.2rem;
}

/* --- Education --- */
.education-item {
    margin-bottom: 30px;
    padding-left: 20px;
    border-left: 3px solid var(--accent-primary);
}
.education-item h3 {
    color: #fff;
    font-weight: 700; /* Inter Bold */
}
.education-item p {
    font-size: 1rem;
    margin-bottom: 5px;
}
.education-item p:first-of-type {
    color: var(--text-secondary);
    font-style: italic;
}

/* --- Interests --- */
.interests-container {
    display: flex;
    flex-wrap: wrap;
    gap: 40px;
}

.interest-category {
    flex: 1;
    min-width: 250px;
}

.interest-category ul {
    list-style: none;
    padding-left: 10px;
}

.interest-category li {
    position: relative;
    padding-left: 30px;
    margin-bottom: 10px;
    font-size: 1.1rem;
}

.interest-category li::before {
    content: "»";
    position: absolute;
    left: 0;
    top: 0;
    color: var(--accent-primary);
    font-weight: bold;
    font-size: 1.2rem;
}

/* --- Image Placeholders --- */
.img-placeholder {
    width: 100%;
    border-radius: 4px;
    overflow: hidden; /* This makes the image's corners match the rounded border */
}

.img-placeholder img {
    width: 100%;
    height: auto;
    display: block; /* Fixes potential extra space below the image */
}

/*
.img-placeholder.large {
    max-height: 300px; /* Set a max-height
    margin-top: 40px;
}

/* To make .large images not get squished
.img-placeholder.large img {
    object-fit: cover; /* Crops the image nicely, rather than squishing it
    height: 300px; /* Match the container height
}
*/

/* === LARGE SPOTIFY EMBED STYLES === */

.spotify-showcase {
    width: 100%;
    height: 400px; /* Gives plenty of space for the playlist tracklist */
    margin-top: 50px;

    background-color: var(--container-color);
    border: 2px solid var(--accent-primary);
    border-radius: 16px; /* Slightly larger radius for the container */
    padding: 10px; /* Creates a 'frame' effect between the border and the player */

    /* Depth and Glow */
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5); /* Deep shadow */
    transition: all 0.3s ease;
}

/* Interaction: The container glows gold when you hover over it */
.spotify-showcase:hover {
    box-shadow:
        0 0 20px rgba(212, 175, 55, 0.15),
        /* Outer Gold Glow */ inset 0 0 20px rgba(0, 0, 0, 0.5); /* Inner Depth */
    border-color: #fff; /* Border flashes white briefly on hover */
    transform: translateY(-2px);
}

/* === FOOTER STYLES === */

footer {
    padding: 50px 0;
    background-color: var(--bg-color);
    border-top: 1px solid var(--container-color);
}

.footer-content {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 40px;

    /* Layout */
    display: flex;
    justify-content: space-between; /* Puts socials left, email right */
    align-items: center;
    flex-wrap: wrap; /* Allows it to stack on small screens */
    gap: 20px; /* Adds space if it wraps */
}

.social-links {
    display: flex;
    align-items: center;
    gap: 25px;
}

.social-links a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: all 0.3s ease;
}

.social-links a:hover {
    color: var(--accent-primary);
    transform: translateY(-3px);
}

.social-links svg {
    width: 28px; /* Icon size */
    height: 28px;
    fill: currentColor; /* the SVG color matches the 'a' tag's color */
}

.email p {
    font-family: var(--font-mono);
    color: var(--text-secondary);
    font-size: 1rem;
    margin: 0; /* Remove default paragraph margin */
}

/* This class hides text visually but keeps it for screen readers */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

@media print {
    @page {
        margin: 2cm;
    }

    body {
        background-color: #fff !important;
        background-image: none !important;
        color: #000 !important;
        padding: 0 !important;
        -webkit-print-color-adjust: exact;
    }

    /* HIDE INTERACTIVE & NAVIGATION ELEMENTS */
    .side-nav,
    .spotify-showcase,
    .spotify-wrapper,
    .social-links,
    .img-placeholder,
    button {
        display: none !important;
    }

    /* TYPOGRAPHY & LAYOUT ADJUSTMENTS */
    main.content {
        max-width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    section {
        min-height: auto !important; /* Remove full-screen forcing */
        padding: 20px 0 !important;
        border-bottom: 1px solid #ccc !important;
        page-break-inside: avoid; /* Try not to split sections mid-page */
    }

    h1 {
        font-size: 28pt;
        color: #000 !important;
        text-align: center;
        margin-bottom: 5px;
    }

    .tagline {
        text-align: center;
        color: #444 !important;
        font-size: 14pt;
        margin-bottom: 30px;
    }

    h2 {
        font-size: 18pt;
        color: #000 !important;
        border-bottom: 2px solid #000 !important;
        text-shadow: none !important;
        margin-top: 0;
    }

    h2 .mono {
        display: none;
    }

    h3 {
        color: #333 !important;
        font-size: 14pt;
        text-shadow: none !important;
    }

    p,
    li {
        font-size: 11pt;
        line-height: 1.5;
        color: #000 !important;
    }

    /* SPECIFIC SECTIONS */

    /* Layout: List projects vertically instead of grid */
    .project-grid {
        display: block !important;
    }

    .project-card {
        background: none !important;
        border: none !important;
        border-left: 3px solid #000 !important;
        box-shadow: none !important;
        margin-bottom: 20px;
        padding: 0 0 0 15px !important;
        break-inside: avoid; /* Don't cut a project in half across pages */
    }

    .experience-item {
        border-left: 3px solid #000 !important;
    }

    /* Turn pills into simple bordered text */
    .skills-list li {
        background: none !important;
        border: 1px solid #000 !important;
        color: #000 !important;
    }

    /* URL REVEAL */
    a {
        text-decoration: none !important;
        color: #000 !important;
    }

    /* Only show URLs for external links (not nav anchors) */
    a[href^="http"]::after {
        content: " (" attr(href) ")";
        font-size: 0.9em;
        font-style: italic;
        color: #555;
    }

    footer {
        border-top: none !important;
        padding-top: 20px;
    }

    .footer-content {
        display: block;
        text-align: center;
    }

    .email p {
        font-size: 12pt;
        font-weight: bold;
    }
}
