/* Import color variables */
@import 'colors.css';

/* Breadcrumb back link */
.breadcrumb {
    max-width: 1200px;
    margin: 0.6rem auto 0;
    padding: 0 2rem;
}
.breadcrumb a {
    color: var(--text-gray);
    text-decoration: none;
    font-size: 0.88rem;
    transition: color 0.2s;
}
.breadcrumb a:hover { color: var(--primary-orange); }

/* ---- Navbar (shared across all pages) ---- */
.navbar {
    background: rgba(0,0,0,0.5);
    padding: 1rem 2rem;
    border-bottom: 1px solid var(--border-gray);
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(10px);
}
.navbar-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.nav-logo { font-size: 1.5rem; font-weight: 700; color: var(--primary-orange); text-decoration: none; }
.nav-links { display: flex; gap: 2rem; }
.nav-links a { color: var(--light-gray); text-decoration: none; transition: color 0.3s; }
.nav-links a:hover, .nav-links a.active { color: var(--primary-orange); }

/* ---- Subpage Header ---- */
.page-header {
    text-align: center;
    padding: 1.5rem 2rem 1rem;
    background: linear-gradient(135deg, var(--darker-bg) 0%, var(--dark-bg) 100%);
}
.page-header h1 { font-size: 2rem; color: var(--primary-orange); margin-bottom: 0.4rem; }
.page-header p { font-size: 0.95rem; color: var(--text-gray); }

/* ---- Listing page intro text ---- */
.page-intro {
    max-width: 700px;
    margin: 1rem auto 0;
    padding: 0 2rem 1.25rem;
    text-align: center;
    color: var(--text-gray);
    font-size: 0.95rem;
    line-height: 1.7;
}

/* ---- Tool content wrapper (subpages) ---- */
.tool-wrap {
    max-width: 960px;
    margin: 2rem auto 4rem;
    padding: 0 1.5rem;
}

/* Footer link */
.footer a { color: var(--primary-orange); text-decoration: none; }

/* Back Button */
.back-button {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--card-bg);
    color: var(--light-gray);
    border: 2px solid var(--border-gray);
    padding: 0.6rem 1.2rem;
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.3s;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
}
.back-button:hover { border-color: var(--primary-orange); color: var(--primary-orange); }

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
    background: linear-gradient(135deg, var(--darker-bg) 0%, var(--dark-bg) 100%);
    color: var(--light-gray);
    min-height: 100vh;
    line-height: 1.6;
}

/* Header Section */
.header {
    text-align: center;
    padding: 4rem 2rem 2rem;
    background: rgba(0, 0, 0, 0.3);
}

.logo {
    font-size: 3.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary-orange) 0%, var(--orange-dark) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1rem;
}

.tagline {
    font-size: 1.5rem;
    color: var(--text-gray);
    font-weight: 300;
    margin-bottom: 1rem;
}

/* About Me Section */
.about-section {
    max-width: 800px;
    margin: 3rem auto;
    padding: 0 2rem;
    text-align: center;
}

.about-section h2 {
    color: var(--primary-orange);
    font-size: 2rem;
    margin-bottom: 1rem;
}

.about-section p {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--light-gray);
    margin-bottom: 1rem;
}

.skills {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 1.5rem;
}

.skill-tag {
    background: var(--card-bg);
    border: 1px solid var(--border-gray);
    padding: 0.5rem 1rem;
    border-radius: 6px;
    font-size: 0.9rem;
    color: var(--primary-orange);
}

/* Category Bars */
.categories-section {
    max-width: 1200px;
    margin: 4rem auto;
    padding: 0 2rem;
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.category-card {
    background: var(--card-bg);
    border: 2px solid var(--border-gray);
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    color: inherit;
    display: block;
}

.category-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary-orange);
    box-shadow: 0 10px 30px rgba(255, 107, 53, 0.2);
}

.category-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.category-card h3 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    color: var(--light-gray);
}

.category-count {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-orange);
    margin-top: 0.5rem;
}

/* Wide category bar (Engineering) */
.category-card--wide {
    margin-top: 1.5rem;
    padding: 1.5rem 2rem;
    text-align: left;
}

/* Category specific colors */
.category-card[data-category="3d-print"]:hover {
    border-color: var(--category-3dprint);
}

.category-card[data-category="electronics"]:hover {
    border-color: var(--category-electronics);
}

.category-card[data-category="mechanical"]:hover {
    border-color: var(--category-mechanical);
}

.category-card[data-category="other"]:hover {
    border-color: var(--category-other);
}

/* Current Projects Section */
.projects-section {
    max-width: 1200px;
    margin: 4rem auto;
    padding: 0 2rem;
}

.projects-section h2 {
    color: var(--primary-orange);
    font-size: 2rem;
    margin-bottom: 2rem;
    text-align: center;
}

.wip-section {
    background: var(--card-bg);
    border: 2px solid var(--orange-dark);
    border-radius: 12px;
    padding: 2rem;
    margin-bottom: 3rem;
}

.wip-section h3 {
    color: var(--primary-orange);
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.progress-bar {
    background: var(--darker-bg);
    height: 30px;
    border-radius: 15px;
    overflow: hidden;
    border: 2px solid var(--border-gray);
    margin: 1rem 0;
}

.progress-fill {
    background: linear-gradient(90deg, var(--primary-orange) 0%, var(--orange-dark) 100%);
    height: 100%;
    width: 0%;
    transition: width 0.5s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 0.9rem;
}

.eta {
    color: var(--text-gray);
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

/* Recent Projects Grid */
.recent-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.project-card {
    background: var(--card-bg);
    border: 1px solid var(--border-gray);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    cursor: pointer;
}

.project-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary-orange);
    box-shadow: 0 10px 30px rgba(255, 107, 53, 0.2);
}

.project-image {
    width: 100%;
    height: 200px;
    background: var(--darker-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-gray);
    font-size: 3rem;
}

.project-content {
    padding: 1.5rem;
}

.project-title {
    font-size: 1.3rem;
    color: var(--light-gray);
    margin-bottom: 0.5rem;
}

.project-meta {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    font-size: 0.85rem;
    color: var(--text-gray);
}

.project-description {
    color: var(--text-gray);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* Footer */
.footer {
    text-align: center;
    padding: 3rem 2rem;
    color: var(--text-gray);
    font-size: 0.9rem;
    border-top: 1px solid var(--border-gray);
    margin-top: 4rem;
}

/* Status Message (temporary) */
.status {
    max-width: 600px;
    margin: 3rem auto;
    padding: 1.5rem;
    background: rgba(255, 107, 53, 0.1);
    border: 2px solid var(--primary-orange);
    border-radius: 12px;
    color: var(--primary-orange);
    text-align: center;
}

/* ---- Hamburger Menu ---- */
.hamburger {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 26px;
    height: 18px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    flex-shrink: 0;
}

.hamburger span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--light-gray);
    border-radius: 2px;
    transition: transform 0.3s, opacity 0.3s;
}

.hamburger.nav-open span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.hamburger.nav-open span:nth-child(2) { opacity: 0; }
.hamburger.nav-open span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

@media (max-width: 640px) {
    .hamburger { display: flex; }

    .navbar .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        flex-direction: column;
        gap: 0;
        background: rgba(6, 6, 16, 0.97);
        border-bottom: 1px solid var(--border-gray);
        z-index: 200;
    }

    .navbar .nav-links.nav-open { display: flex; }

    .navbar .nav-links a {
        padding: 0.8rem 2rem;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    }

    .navbar-content { position: relative; }
}

/* Responsive */
@media (max-width: 768px) {
    .logo {
        font-size: 2.5rem;
    }
    
    .tagline {
        font-size: 1.2rem;
    }
    
    .categories-grid {
        grid-template-columns: 1fr;
    }
    
    .recent-grid {
        grid-template-columns: 1fr;
    }
}