* {
    box-sizing: border-box;
}

/* Base page styling */
body {
    margin: 0;
    padding: 0;
    background: linear-gradient(45deg, #1a252f, #2471a3);
    color: #f0f0f0;
    font-family: Arial, sans-serif;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    text-shadow: 0 1px 3px rgba(0,0,0,0.25);
}

main {
    flex: 1;
}

/* Header styling */
.header {
    text-align: center;
    padding: 2rem 0;
    margin-bottom: 1.5rem;
    font-size: 2.5rem;
}

.header h1 {
    margin: 0;
    font-size: inherit;
    font-weight: inherit;
}

/* Navigation styling */
.nav {
    background: #2c3e50;
    padding: 1rem 0;
    margin-bottom: 2rem;
}

.nav-list {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    gap: 2rem;
    padding: 0;
    list-style: none;
    flex-wrap: wrap;
}

.nav-link {
    color: white;
    text-decoration: none;
    font-weight: 700;
    transition: all 0.3s ease;
    padding: 0.5rem 1rem;
    border-radius: 4px;
}

.nav-link:hover {
    background: rgba(255,255,255,0.1);
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.nav-link:focus-visible {
    outline: 3px solid #fff;
    outline-offset: 2px;
}

.active-nav {
    background: rgba(255,255,255,0.15);
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

/* Index Page - Button Container */
.button-container {
    max-width: 400px;
    margin: 2rem auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    padding: 0 1rem;
}

/* Index Page - Button Styles */
.btn {
    padding: 0.75rem 1.5rem;
    border-radius: 4px;
    border: none;
    cursor: pointer;
    font-weight: 700;
    transition: all 0.3s ease;
    display: block;
    width: 240px;
    margin: 0 auto;
    text-decoration: none;
    color: white;
    text-align: center;
    white-space: nowrap;
    font-size: 0.9rem;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

.btn-RadioTheory { background: #e67e22; }
.btn-Friday { background: #9400d3; }
.btn-WaveGames { background: #1abc9c; }

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
}

.btn:focus-visible {
    outline: 3px solid #fff;
    outline-offset: 2px;
}

/* Shared Content Container (For About/Contact) */
.content-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* About Page Styles */
.about-content {
    background: rgba(255, 255, 255, 0.1);
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.about-content h2 {
    margin-top: 0;
    color: #fff;
    border-bottom: 2px solid #3498db;
    padding-bottom: 0.5rem;
}

.about-content h3 {
    color: #2ecc71;
    margin: 1.5rem 0 1rem;
}

.features-list {
    padding-left: 1.5rem;
}

.features-list li {
    margin-bottom: 1rem;
    line-height: 1.6;
}

.features-list strong {
    color: #7ec8ff;
}

/* Contact Page Styles */
.contact-content {
    background: rgba(255, 255, 255, 0.1);
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.contact-content h2 {
    margin-top: 0;
    color: #fff;
    border-bottom: 2px solid #3498db;
    padding-bottom: 0.5rem;
}

.contact-content h3 {
    color: #2ecc71;
    margin: 1.5rem 0 1rem;
}

.contact-method {
    margin: 1.5rem 0;
}

.contact-details {
    background: rgba(255, 255, 255, 0.05);
    padding: 1rem;
    border-radius: 4px;
}

.email-link {
    color: #7ec8ff;
    font-weight: 700;
    text-decoration: none;
    margin: 1rem 0;
    transition: all 0.3s ease;
}

.email-link:hover {
    color: #7ec8ff;
    transform: scale(1.05);
}

.email-link:focus-visible {
    outline: 3px solid #fff;
    outline-offset: 2px;
}

.contact-notes {
    margin-top: 2rem;
    color: #ddd;
    line-height: 1.6;
    text-align: center;
}

.contact-notes em {
    color: #7ec8ff;
    font-style: normal;
    font-weight: bold;
}

/* Footer styling */
.footer {
    width: 100%;
    padding: 1rem;
    background: #2c3e50;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 60px;
}

.footer p {
    margin: 0;
}

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

.project-card {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.project-card:hover {
    transform: translateY(-5px);
}

.project-card h2 {
    margin-top: 0;
    color: #fff;
    border-bottom: 2px solid #e67e22;
    padding-bottom: 0.5rem;
}

.project-description {
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.project-details {
    margin: 1.5rem 0;
}

.project-actions {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    margin-top: 2rem;
}

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

/* Small-screen and keyboard fixes; the original visual design stays intact. */
.btn { max-width: 100%; white-space: normal; min-height: 44px; }
.features-list, .email-link { overflow-wrap: anywhere; }
main { padding-bottom: 2rem; }
.skip-link { position: absolute; top: -100px; left: 1rem; padding: .75rem 1rem; background: #2c3e50; color: white; z-index: 10; }
.skip-link:focus { top: 1rem; outline: 3px solid white; }
@media (max-width: 480px) {
    .nav-list { gap: .5rem; padding: 0 .5rem; }
    .nav-link { display: inline-block; min-height: 44px; }
    .about-content, .contact-content { padding: 1.25rem; }
}
@media (prefers-reduced-motion: reduce) {
    .btn, .nav-link, .email-link, .project-card { transition: none; }
    .btn:hover, .project-card:hover { transform: none; }
}

/* A light refresh for the existing personal hub. */
.home-intro { text-align: center; padding: 0 1.5rem; line-height: 1.6; }
.btn-Hedgehog { background: #2ecc71; }
.btn-RadioTheory, .btn-WaveGames, .btn-Hedgehog { color: #142a38; text-shadow: none; }
.nav-link { display: inline-block; min-height: 44px; }
.about-content p, .contact-content p, .project-details p { line-height: 1.6; }
code { overflow-wrap: anywhere; }
.email-link { text-decoration: underline; text-underline-offset: .2em; }
.header { padding-left: 1rem; padding-right: 1rem; }
.footer { min-height: 60px; height: auto; text-align: center; }
