:root {
    --bg-color: #050510;
    --text-color: #e0e0e0;
    --primary-color: #5abcb9; /* Muted Cyan */
    --secondary-color: #ffffff; /* White */
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
    --font-main: 'Signika', sans-serif;
    --font-small: 'Fira Sans', sans-serif;
    --font-display: 'Signika', sans-serif;
}

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

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-main);
    overflow-x: hidden;
    line-height: 1.6;
}

/* Apply Fira Sans only to specific small text elements */
.date, .role, .tags span, .hero-location, footer, .location-text, .direct-contact, .company {
    font-family: var(--font-small);
}

h1, h2, h3, h4, h5, h6, .logo, .nav-links a {
    font-family: var(--font-main);
}

/* Intro Animation Sequence */

/* 1. Logo (Already has logo-intro, plays immediately) */

/* 2. Stars (Canvas) - Fades in after logo */
#bg-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    opacity: 0;
    animation: stars-fade-in 2s ease-in-out 0.5s forwards;
}

@keyframes stars-fade-in {
    to { opacity: 1; }
}

/* 3. Hero Text - Scales in after stars */
.hero-content h1, 
.hero-content h2, 
.hero-content .hero-location, 
.hero-content .scroll-indicator {
    opacity: 0;
    transform: scale(0.5);
    animation: text-scale-reveal 1s ease-out 1s forwards;
}

@keyframes text-scale-reveal {
    to { 
        opacity: 1; 
        transform: scale(1); 
    }
}

/* 4. Navigation - Fades in last */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    padding: 1.5rem 3rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 100;
    background: linear-gradient(to bottom, rgba(5,5,16,0.9), transparent);
    backdrop-filter: blur(2px);
    opacity: 0;
    animation: nav-fade-in 1s ease-out 1.5s forwards;
}

@keyframes nav-fade-in {
    to { opacity: 1; }
}

.nav-links a {
    color: var(--text-color);
    text-decoration: none;
    margin-left: 2rem;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.9rem;
    transition: color 0.3s ease, text-shadow 0.3s ease;
}

.nav-links a:hover {
    color: var(--primary-color);
    text-shadow: 0 0 8px var(--primary-color);
}

.hero-logo {
    width: 200px;
    height: auto;
    margin-bottom: 2rem;
    fill: #ffffff;
    filter: drop-shadow(0 0 6px var(--primary-color));
    display: block;
    margin-left: auto;
    margin-right: auto;
    animation: logo-intro 1.5s ease-out forwards;
}

@keyframes logo-intro {
    0% {
        opacity: 0;
        transform: translateY(-20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Hero Section */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 2rem;
}

.hero-content h1 {
    font-family: var(--font-display);
    font-size: 4rem;
    font-weight: 900;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
    color: #fff;
    text-shadow: 0 0 20px var(--primary-color);
    position: relative;
}

.hero-content h2 {
    font-size: 1.5rem;
    color: var(--secondary-color);
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.hero-location {
    font-size: 1.1rem;
    color: #e0e0e0;
    opacity: 0.8;
    margin-top: 1rem;
    letter-spacing: 1px;
}

.location {
    margin-bottom: 2rem;
    opacity: 0.8;
}

.scroll-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.chevron {
    width: 20px;
    height: 20px;
    border-bottom: 3px solid var(--primary-color);
    border-right: 3px solid var(--primary-color);
    transform: rotate(45deg);
    opacity: 0;
    animation: chevron-wipe 2s infinite;
}

.chevron:nth-child(1) {
    animation-delay: 0s;
}

.chevron:nth-child(2) {
    animation-delay: 0.2s;
}

.chevron:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes chevron-wipe {
    0% {
        opacity: 0;
        transform: rotate(45deg) scale(0.5);
    }
    50% {
        opacity: 1;
        transform: rotate(45deg) scale(1);
    }
    100% {
        opacity: 0;
        transform: rotate(45deg) scale(1.2);
    }
}

/* Main Content */
main {
    max-width: 1000px;
    margin: 0 auto;
    padding: 2rem;
}

.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    padding: 3rem;
    margin-bottom: 4rem;
    border-radius: 0;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

.section-title {
    font-family: var(--font-display);
    font-size: 2rem;
    color: var(--secondary-color);
    margin-bottom: 2rem;
    border-bottom: 1px solid var(--glass-border);
    padding-bottom: 1rem;
    display: inline-block;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.4);
}

/* Experience & Education */
.job-entry, .edu-entry {
    margin-bottom: 2rem;
    padding-left: 0;
}

.job-header h3, .edu-entry h3 {
    font-size: 1.3rem;
    margin-bottom: 0.2rem;
    color: #fff;
}

.company, .date {
    display: block;
    font-size: 0.9rem;
    color: #aaa;
    margin-bottom: 0.5rem;
}

.role {
    display: block;
    font-size: 1.1rem;
    color: #f4a261; /* Desaturated orange */
    font-weight: 600;
    margin-bottom: 0.2rem;
}

ul {
    list-style-type: none;
}

ul li {
    margin-bottom: 0.5rem;
    position: relative;
    padding-left: 1.2rem;
}

ul li::before {
    content: '>';
    color: var(--primary-color);
    position: absolute;
    left: 0;
    top: 0.2rem;
    font-family: var(--font-display);
    font-size: 0.8rem;
}

/* Projects */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.project-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    border-radius: 0;
    transition: transform 0.3s ease, border-color 0.3s ease;
    overflow: hidden; /* For image rounded corners */
    display: flex;
    flex-direction: column;
}

.project-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary-color);
}

.project-image {
    width: 100%;
    height: 180px;
    overflow: hidden;
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.project-card:hover .project-image img {
    transform: scale(1.05);
}

.project-content {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.project-content h3 {
    color: #fff;
    margin-bottom: 0.8rem;
    font-size: 1.2rem;
}

.project-content p {
    font-size: 0.9rem;
    color: #ccc;
    margin-bottom: 1.2rem;
    line-height: 1.5;
    flex-grow: 1;
}

.project-link {
    display: inline-block;
    margin-top: 1rem;
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 700;
    font-size: 0.9rem;
    transition: text-shadow 0.3s ease;
    align-self: flex-start;
}

.project-link:hover {
    text-shadow: 0 0 5px var(--primary-color);
}

/* Skills */
.skills-grid {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.skill-category {
    display: grid;
    grid-template-columns: 200px 1fr;
    align-items: baseline;
    gap: 2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.skill-category:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.skill-category h3, .contact-info-block h3 {
    color: #f4a261;
    font-size: 1.2rem;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.tags {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 1rem;
}

.tags span {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    padding: 0.5rem;
    font-size: 0.9rem;
    color: #e0e0e0;
    transition: all 0.2s ease;
    text-align: center;
    display: block;
    width: 100%;
}

.tags span:hover {
    border-color: var(--primary-color);
    background: rgba(90, 188, 185, 0.05);
    transform: translateY(-2px);
}

/* About Section */
.about-container {
    display: flex;
    gap: 3rem;
    align-items: flex-start;
}

.about-image {
    flex: 0 0 250px;
}

.headshot {
    width: 100%;
    border-radius: 0;
    border: 2px solid var(--glass-border);
    box-shadow: 0 0 20px rgba(90, 188, 185, 0.2);
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.about-content {
    flex: 1;
}

.bio-text {
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    color: #e0e0e0;
}

.interests-tags h3 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    font-size: 1.2rem;
}

/* Interest Showcase */
#interests-showcase {
    display: none;
}

.interests-grid-showcase {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
}

.interest-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--glass-border);
    border-radius: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
}

.interest-card:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--primary-color);
    transform: translateY(-5px);
}

.interest-image {
    width: 100%;
    height: 140px;
    overflow: hidden;
}

.interest-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.interest-card:hover .interest-image img {
    transform: scale(1.05);
}

.interest-content {
    padding: 1.2rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.interest-card h3 {
    color: #fff;
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.interest-card p {
    font-size: 0.85rem;
    color: #aaa;
    line-height: 1.4;
    margin-bottom: 1rem;
    flex-grow: 1;
}

.interest-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 700;
    font-size: 0.85rem;
    align-self: flex-start;
    transition: text-shadow 0.3s ease;
}

.interest-link:hover {
    text-shadow: 0 0 5px var(--primary-color);
}

/* Contact Section */
.text-center {
    text-align: center;
}

.contact-links-container {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.direct-contact, .location-text {
    font-size: 1.2rem;
    color: #e0e0e0;
    text-decoration: none;
    transition: color 0.3s ease, text-shadow 0.3s ease;
}

.direct-contact:hover {
    color: var(--primary-color);
    text-shadow: 0 0 10px var(--primary-color);
}

.location-text {
    opacity: 0.7;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
}

.social-btn {
    padding: 0.8rem 2rem;
    border: 1px solid var(--primary-color);
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s ease;
    border-radius: 0;
}

.social-btn:hover {
    background: var(--primary-color);
    color: var(--bg-color);
    box-shadow: 0 0 15px var(--primary-color);
}

/* Footer */
footer {
    text-align: center;
    padding: 2rem;
    opacity: 0.6;
    font-size: 0.8rem;
}

/* Response for About Section and General Mobile Layout */
@media (max-width: 768px) {
    /* Hide Navbar */
    nav {
        display: none;
    }

    /* Adjust Layout & Spacing */
    main {
        padding: 1rem;
        width: 100%;
    }

    .glass-panel {
        padding: 1.5rem 1rem; /* Reduce horizontal padding */
        margin-bottom: 2rem; /* Reduce dead space between sections */
    }

    /* Hero Section Adjustments */
    .hero {
        padding: 1rem;
    }

    .hero-content h1 {
        font-size: 2.5rem; /* Prevent overflow */
        line-height: 1.2;
    }

    .hero-content h2 {
        font-size: 1.1rem;
    }

    .hero-logo {
        width: 120px; /* Smaller logo */
    }

    /* About Section */
    .about-container {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 2rem;
    }

    .about-image {
        flex: 0 0 auto; /* Allow auto sizing */
        width: 150px; /* Smaller headshot */
        margin-bottom: 1rem;
    }

    /* Skills & General Text */
    .skill-category {
        grid-template-columns: 1fr;
        gap: 0.5rem;
        text-align: center; /* Center align skills on mobile */
    }

    .tags {
        justify-content: center; /* Center tags */
    }

    .section-title {
        font-size: 1.5rem;
        text-align: center;
        display: block; /* Ensure it takes full width for centering */
    }
}
