/* --- Basic Reset & Global Styles --- */
* {
    box-sizing: border-box; /* Fixes padding/width calculation issues */
}

body {
    font-family: 'Lato', sans-serif;
    background-color: #f8f9fa;
    color: #343a40;
    margin: 0;
    line-height: 1.6;
}

.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 40px 20px;
    width: 100%; /* Ensures container never exceeds viewport width */
}

h1, h2, h3 {
    font-family: 'Poppins', sans-serif;
    font-weight: 600;
    color: #212529;
}

a {
    color: #0056b3;
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: #003d80;
}

ul {
    list-style-position: outside;
    padding-left: 20px;
    text-align: left;
}

li {
    margin-bottom: 8px;
}

/* --- Navigation --- */
nav {
    background-color: #ffffff;
    border-bottom: 1px solid #e9ecef;
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

nav .nav-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap; /* Allows wrapping on very small screens */
}

nav a {
    font-family: 'Poppins', sans-serif;
    font-weight: 400;
    color: #495057;
    margin: 0 15px; /* Slightly reduced margin for mobile safety */
    font-size: 1rem;
}

nav a:hover {
    color: #0056b3;
}

/* --- Hero / About Me Section --- */
.hero {
    padding: 60px 0;
    text-align: center;
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 10px;
    font-weight: 700;
    line-height: 1.2; /* Better spacing for multi-line titles on mobile */
}

.hero .tagline {
    font-family: 'Poppins', sans-serif;
    font-size: 1.5rem;
    color: #6c757d;
    margin-bottom: 25px;
    font-weight: 300;
}

.hero .bio {
    font-size: 1.1rem;
    max-width: 700px;
    margin: 0 auto 30px auto;
}

/* --- Call to Action Buttons --- */
.cta-buttons a {
    display: inline-block;
    background-color: #0056b3;
    color: #ffffff;
    padding: 12px 25px;
    border-radius: 5px;
    font-family: 'Poppins', sans-serif;
    font-weight: 600;
    margin: 10px;
    transition: all 0.3s ease; /* Smooths background and transform */
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.cta-buttons a.secondary {
    background-color: transparent;
    color: #0056b3;
    border: 2px solid #0056b3;
    box-shadow: none;
}

.cta-buttons a:hover {
    background-color: #003d80;
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.cta-buttons a.secondary:hover {
    background-color: #0056b3;
    color: #ffffff;
}

/* --- Social Links --- */
.social-links {
    margin-top: 40px;
    text-align: center;
}

.social-links a {
    font-size: 1.8rem;
    margin: 0 15px;
    color: #495057;
    transition: all 0.3s ease;
    display: inline-block; /* Required for transform to work */
}

.social-links a:hover {
    color: #0056b3;
    transform: translateY(-3px);
}

/* --- Footer --- */
footer {
    margin-top: 50px;
    padding: 20px;
    font-size: 0.9rem;
    color: #6c757d;
    text-align: center;
    background-color: #f8f9fa; /* Ensures footer background consistency */
}

/* --- Project Page Styles --- */
.page-header {
    text-align: center;
    padding-bottom: 20px;
    border-bottom: 1px solid #e9ecef;
    margin-bottom: 40px;
}

.page-header h1 {
    font-size: 2.8rem;
}

.project-card {
    background-color: #ffffff;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    text-align: left;
}

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

.project-card h3 {
    margin-top: 0;
    font-size: 1.6rem;
}

.project-tags {
    margin-bottom: 15px;
}

.project-tags span {
    display: inline-block;
    background-color: #e9ecef;
    color: #495057;
    padding: 5px 10px;
    border-radius: 15px;
    font-size: 0.8rem;
    margin-right: 8px;
    margin-bottom: 8px;
    font-weight: 600;
}

.project-group-header {
    font-family: 'Poppins', sans-serif;
    font-weight: 600;
    font-size: 1.8rem;
    color: #343a40;
    margin-top: 40px;
    margin-bottom: 20px;
    border-bottom: 2px solid #e9ecef;
    padding-bottom: 8px;
}

.project-group-header:first-of-type {
    margin-top: 0;
}

/* --- Generic Section Styles --- */
.bordered-section {
    padding: 60px 0;
    border-top: 1px solid #e9ecef;
    text-align: left;
}

.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.section-header h2 {
    font-size: 2.5rem;
}

/* --- Core Competencies Section --- */
.competencies-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
}

.competency-card {
    background-color: #ffffff;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
    text-align: left;
    transition: transform 0.3s ease; /* Interactive Polish */
    height: 100%; /* Ensures equal height in grid */
}

.competency-card:hover {
    transform: translateY(-3px);
}

.competency-card h3 {
    font-size: 1.3rem;
    color: #0056b3;
    margin-top: 0;
    margin-bottom: 15px;
}

.competency-card p {
    font-size: 0.95rem;
    line-height: 1.7;
    margin: 0;
    color: #495057;
}

/* --- Experience Section --- */
.experience-item {
    background-color: #ffffff;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 30px;
    margin-bottom: 25px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    text-align: left;
}

.experience-item h3 {
    margin-top: 0;
    color: #0056b3;
    font-size: 1.4rem;
}

.experience-item h4 {
    margin: 5px 0;
    font-size: 1rem;
    color: #495057;
    font-weight: 700;
}

.experience-item .dates {
    font-style: italic;
    font-size: 0.9rem;
    color: #6c757d;
    margin-bottom: 15px;
}

/* --- Education & Certs Sections --- */
.grid-layout {
    display: grid;
    /* Adjusted from 300px to 280px to prevent overflow on small mobiles */
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
}

.info-card {
    background-color: #fff;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 25px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
    transition: all 0.3s ease; /* Phase 2 Polish */
    height: 100%;
}

/* New Hover State for Info Cards */
.info-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 15px rgba(0,0,0,0.1);
}

.info-card h3 {
    margin-top: 0;
    color: #0056b3;
}

.info-card p {
    margin-bottom: 5px;
}

.info-card .award {
    font-size: 0.9rem;
    font-style: italic;
    color: #6c757d;
    margin-top: 10px;
}

/* --- CTA Section --- */
.cta-section {
    background-color: #ffffff;
    padding: 60px 20px;
    text-align: center;
    margin: 40px auto;
    border-radius: 8px;
    box-shadow: 0 8px 15px rgba(0,0,0,0.05);
    border-top: 1px solid #e9ecef;
    max-width: 900px; /* Ensures alignment with other containers */
}

.cta-section h2 {
    font-size: 2rem;
    margin-top: 0;
}

.cta-section p {
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto 30px auto;
}

/* --- Tableau Embed Styles --- */
.viz-wrapper {
    margin-top: 25px;
    margin-bottom: 15px;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    /* Changed from hidden to auto to allow scrolling if chart is too wide */
    overflow-x: auto; 
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    background-color: #fff;
    width: 100%; 
}

/* --- Media Queries --- */
@media screen and (max-width: 600px) {
    .hero h1 {
        font-size: 2.5rem; /* Reduced slightly more for mobile */
    }
    .hero .tagline {
        font-size: 1.1rem;
    }
    nav a {
        margin: 0 8px;
        font-size: 0.9rem;
    }
    .project-card, .experience-item {
        padding: 20px; /* Reclaim space on small screens */
    }
}
