:root {
    --bg-color: #f0f0f0;
    --text-color: #333;
    --container-bg: white;
    --button-bg: #007bff;
    --button-text: white;
    --shadow-color: rgba(0,0,0,0.1);
}

.dark-mode {
    --bg-color: #121212;
    --text-color: #f0f0f0;
    --container-bg: #1e1e1e;
    --button-bg: #0d6efd;
    --button-text: white;
    --shadow-color: rgba(255,255,255,0.1);
}

body {
    font-family: sans-serif;
    min-height: 100vh;
    background-color: var(--bg-color);
    color: var(--text-color);
    transition: background-color 0.3s, color 0.3s;
    margin: 0;
    padding-top: 60px; /* Space for nav */
}

/* New utility class for pages with a simple centered layout */
.centered-layout {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

/* Site Header and Navigation */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: var(--container-bg);
    box-shadow: 0 2px 5px var(--shadow-color);
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 20px;
    box-sizing: border-box;
    transition: background-color 0.3s;
}

.site-nav {
    display: flex;
    gap: 20px;
}

.nav-link {
    color: var(--text-color);
    text-decoration: none;
    font-size: 16px;
    font-weight: bold;
    transition: color 0.3s;
}

.nav-link:hover {
    color: var(--button-bg);
}

.container {
    text-align: center;
    padding: 20px;
    background-color: var(--container-bg);
    border-radius: 10px;
    box-shadow: 0 0 10px var(--shadow-color);
    transition: background-color 0.3s;
    margin-top: 60px; /* Adjust for fixed header */
}


h1 {
    color: var(--text-color);
}

button {
    padding: 10px 20px;
    font-size: 16px;
    cursor: pointer;
    border: none;
    background-color: var(--button-bg);
    color: var(--button-text);
    border-radius: 5px;
    margin-bottom: 20px;
    transition: background-color 0.3s;
}

#numbers-display {
    display: flex;
    justify-content: center;
    gap: 10px;
    font-size: 24px;
    font-weight: bold;
}

.number-circle {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    color: white;
    font-weight: bold;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.2);
}

/* Theme Switcher Styles */
.theme-switcher {
    display: flex;
    align-items: center;
}

.switch-label {
    margin-right: 10px;
}

.switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 25px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .4s;
    border-radius: 25px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 19px;
    width: 19px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
}

input:checked + .slider {
    background-color: var(--button-bg);
}

input:checked + .slider:before {
    transform: translateX(25px);
}

/* --- Portfolio Page Styles --- */

/* General Section Styling */
.portfolio-section {
    width: 100%;
    padding: 60px 20px;
    box-sizing: border-box;
}

.portfolio-section:nth-child(odd) {
    background-color: var(--bg-color);
}

.portfolio-section:nth-child(even) {
    background-color: var(--container-bg);
}

.portfolio-section .container {
    margin-top: 0;
    max-width: 960px;
    margin-left: auto;
    margin-right: auto;
}

/* Hero (Introduction) Section */
.hero {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 100px 20px; /* More padding for hero */
}

.hero-content h1 {
    font-size: 3.5rem;
    margin-bottom: 10px;
}

.hero-content .subtitle {
    font-size: 1.5rem;
    color: var(--button-bg);
    margin-bottom: 20px;
}

/* Experience Timeline */
.timeline {
    position: relative;
    max-width: 750px;
    margin: 0 auto;
    text-align: left;
}

.timeline::after {
    content: '';
    position: absolute;
    width: 3px;
    background-color: var(--button-bg);
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -1.5px;
}

.timeline-item {
    padding: 10px 40px;
    position: relative;
    width: 50%;
    box-sizing: border-box;
}

.timeline-item:nth-child(odd) {
    left: 0;
    padding-right: 20px;
    text-align: right;
}

.timeline-item:nth-child(even) {
    left: 50%;
    padding-left: 20px;
    text-align: left;
}

.timeline-item::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    right: -10px;
    background-color: var(--container-bg);
    border: 4px solid var(--button-bg);
    top: 25px;
    border-radius: 50%;
    z-index: 1;
}

.timeline-item:nth-child(odd)::after {
    right: -10px;
}

.timeline-item:nth-child(even)::after {
    left: -10px;
}

.timeline-item h3 {
    margin-top: 0;
}
.timeline-item .company-name {
    font-weight: bold;
    color: var(--button-bg);
}
.timeline-item .dates {
    font-style: italic;
    font-size: 0.9em;
    margin-bottom: 10px;
}

/* Project Grid */
.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    text-align: left;
}

.project-card {
    background-color: var(--bg-color);
    padding: 20px;
    border-radius: 8px;
    border: 1px solid var(--shadow-color);
    transition: transform 0.3s, box-shadow 0.3s;
}

.project-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px var(--shadow-color);
}

.project-links a {
    margin-right: 15px;
    color: var(--button-bg);
    font-weight: bold;
    text-decoration: none;
}

/* Skills Section */
.skills-container {
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap;
    gap: 20px;
    text-align: left;
}

.skill-category ul {
    list-style: none;
    padding: 0;
}

.skill-category li {
    background-color: var(--bg-color);
    padding: 8px 12px;
    border-radius: 5px;
    margin-bottom: 8px;
}