/**
Theme Name: Simple Developer 
Author: Josh Walton 
Author URI: https://www.joshmon27.com/
Version: 2.0
Description: An accessible, customizable portfolio theme for software developers showcasing their code and projects.
License: GPL v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: simple-developer
Domain Path: /languages
**/

/* ================================
   ACCESSIBILITY & TYPOGRAPHY
   ================================ */

/* Ensure readable font sizes and weights */
html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', sans-serif;
    font-size: 1rem;
    line-height: 1.6;
    color: #212529;
    background-color: #ffffff;
}

/* High contrast focus states for keyboard navigation */
a:focus,
button:focus,
input:focus,
textarea:focus,
select:focus {
    outline: 3px solid var(--sd-primary, #0d6efd) !important;
    outline-offset: 2px !important;
    box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.25);
}

/* Skip link - visually hidden but accessible to screen readers */
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background-color: var(--sd-primary, #0d6efd);
    color: white;
    padding: 8px 16px;
    text-decoration: none;
    z-index: 100;
    border-radius: 0 0 4px 0;
}

.skip-link:focus {
    top: 0;
}

/* Headings - clear hierarchy */
h1, h2, h3, h4, h5, h6 {
    margin-top: 1.5em;
    margin-bottom: 0.5em;
    font-weight: 600;
    line-height: 1.3;
}

h1 {
    font-size: 2.5rem;
}

h2 {
    font-size: 2rem;
}

h3 {
    font-size: 1.5rem;
}

h4 {
    font-size: 1.25rem;
}

h5 {
    font-size: 1.1rem;
}

h6 {
    font-size: 1rem;
}

/* Links */
a {
    color: var(--sd-primary, #0d6efd);
    text-decoration: underline;
    transition: all 0.3s ease;
}

a:hover {
    color: var(--sd-secondary, #6c757d);
    text-decoration: underline;
}

a:active {
    outline: 2px solid var(--sd-primary, #0d6efd);
}

/* Code blocks - important for developer portfolio */
code {
    background-color: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 4px;
    padding: 2px 6px;
    font-family: 'Courier New', 'Courier', monospace;
    font-size: 0.9em;
    color: #d63384;
}

pre {
    background-color: #2d2d2d;
    color: #f8f8f2;
    border-radius: 6px;
    padding: 1em;
    overflow-x: auto;
    margin: 1em 0;
    line-height: 1.5;
}

pre code {
    background-color: transparent;
    border: none;
    padding: 0;
    color: inherit;
}

/* ================================
   LAYOUT & STRUCTURE
   ================================ */

.main-content {
    min-height: calc(100vh - 200px);
    padding: 2rem 0;
}

.container {
    max-width: 1200px;
}

/* ================================
   NAVIGATION
   ================================ */

.navbar {
    padding: 0.85rem 0;
    backdrop-filter: blur(10px);
}

.navbar .container-fluid {
    max-width: 1200px;
    padding-left: 1rem;
    padding-right: 1rem;
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: bold;
}

.navbar-brand a {
    color: var(--sd-text, #212529);
    text-decoration: none;
}

.navbar-brand .small {
    font-size: 0.82rem;
    letter-spacing: 0.02em;
}

.navbar-nav {
    align-items: center;
    gap: 0.25rem;
}

.navbar-nav .nav-link {
    margin-left: 0;
    margin-right: 0;
    padding: 0.55rem 0.9rem;
    border-radius: 999px;
    font-weight: 500;
    color: var(--sd-text, #212529) !important;
    text-decoration: none;
    transition: all 0.3s ease;
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
    color: #fff !important;
    background-color: var(--sd-primary, #0d6efd);
    border-bottom: none;
    padding-bottom: 0.55rem;
    box-shadow: 0 8px 20px rgba(13, 110, 253, 0.18);
}

.dropdown-menu {
    margin-top: 0.5rem;
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.dropdown-menu a {
    color: var(--sd-text, #212529);
}

.dropdown-menu a:hover {
    background-color: var(--sd-primary, #0d6efd);
    color: white;
}

.project-featured-image {
    max-width: 820px;
}

.project-featured-image img {
    width: 100%;
    max-height: 460px;
    object-fit: cover;
    object-position: center;
    display: block;
}

.project-link-col {
    display: flex;
}

.project-link-item {
    width: 100%;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
}

.project-link-badge {
    justify-content: flex-start;
}

.project-link-badge-img {
    height: 34px;
    width: auto;
    max-width: 160px;
    display: block;
}

/* ================================
   PORTFOLIO & CONTENT
   ================================ */

/* Portfolio cards */
.portfolio-card {
    border: none;
    border-top: 4px solid var(--sd-primary, #0d6efd);
    border-radius: 8px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    height: 100%;
}

.portfolio-card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.portfolio-card-body {
    padding: 1.5rem;
}

.portfolio-card-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--sd-text, #212529);
}

.portfolio-card-description {
    font-size: 0.95rem;
    color: #6c757d;
    margin-bottom: 1rem;
}

.portfolio-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;
}

.portfolio-tag {
    display: inline-block;
    background-color: #e9ecef;
    color: var(--sd-text, #212529);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 500;
}

/* Buttons */
.btn {
    font-weight: 500;
    border-radius: 6px;
    padding: 0.625rem 1.25rem;
    transition: all 0.3s ease;
}

.btn:focus {
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

.btn-primary {
    background-color: var(--sd-primary, #0d6efd);
    border-color: var(--sd-primary, #0d6efd);
}

.btn-primary:hover {
    background-color: var(--sd-secondary, #6c757d);
    border-color: var(--sd-secondary, #6c757d);
}

.btn-secondary {
    background-color: var(--sd-secondary, #6c757d);
    border-color: var(--sd-secondary, #6c757d);
}

.btn-accent {
    background-color: var(--sd-accent, #198754);
    border-color: var(--sd-accent, #198754);
}

.btn-accent:hover {
    background-color: var(--sd-primary, #0d6efd);
    border-color: var(--sd-primary, #0d6efd);
}

/* ================================
   FORMS & INPUTS
   ================================ */

.form-label {
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.form-control,
.form-select,
textarea {
    border: 2px solid #e9ecef;
    border-radius: 6px;
    padding: 0.75rem;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-control:focus,
.form-select:focus,
textarea:focus {
    border-color: var(--sd-primary, #0d6efd);
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.1);
}

/* ================================
   RESPONSIVE DESIGN
   ================================ */

@media (max-width: 768px) {
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.5rem;
    }
    
    .main-content {
        padding: 1rem 0;
    }
    
    .navbar-brand {
        font-size: 1.25rem;
    }
    
    .portfolio-card {
        margin-bottom: 1.5rem;
    }

    .navbar-nav {
        align-items: stretch;
        gap: 0.35rem;
        margin-top: 1rem;
    }

    .navbar-nav .nav-link {
        padding: 0.75rem 1rem;
    }

    .project-featured-image img {
        max-height: 280px;
    }

    .project-link-badge {
        justify-content: center;
    }
}

/* ================================
   RESUME PAGE
   ================================ */

/* Section headings — styled as labelled dividers */
.resume-content h2 {
    font-size: 1.1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--sd-primary, #0d6efd);
    border-bottom: 2px solid var(--sd-primary, #0d6efd);
    padding-bottom: 0.35rem;
    margin-top: 2.25rem;
    margin-bottom: 1rem;
}

.resume-content h3 {
    font-size: 1.05rem;
    font-weight: 600;
    margin-top: 1.25rem;
    margin-bottom: 0.15rem;
}

/* Job/role meta line (company, dates) — use a paragraph directly after h3 */
.resume-content h3 + p {
    color: #6c757d;
    font-size: 0.9rem;
    margin-top: 0;
    margin-bottom: 0.5rem;
}

.resume-content ul {
    padding-left: 1.25rem;
}

.resume-content ul li {
    margin-bottom: 0.3rem;
}

/* Skill tags — wrap skills in a ul with class="skills-list" in the editor */
.resume-content .skills-list,
.resume-content ul.wp-block-list.skills-list {
    list-style: none;
    padding-left: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.resume-content .skills-list li {
    background-color: #e9ecef;
    color: var(--sd-text, #212529);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 0;
}

/* ================================
   PRINT STYLES
   ================================ */

@media print {
    .navbar,
    footer,
    .skip-link {
        display: none !important;
    }

    body {
        color: #000;
        background-color: #fff;
    }

    a {
        color: #000;
    }

    /* Resume-specific print adjustments */
    .resume-content h2 {
        color: #000;
        border-bottom-color: #000;
    }

    .resume-content .skills-list li {
        background-color: #f0f0f0;
        border: 1px solid #ccc;
    }

    /* Ensure resume column fills the page width */
    .col-lg-9,
    .col-xl-8 {
        width: 100% !important;
        max-width: 100% !important;
        flex: 0 0 100% !important;
    }

    /* Avoid orphaned headings */
    .resume-content h2,
    .resume-content h3 {
        page-break-after: avoid;
    }

    .resume-content ul,
    .resume-content p {
        page-break-inside: avoid;
    }
}
