/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Comic Neue', cursive;
    background: #000000;
    color: #ffffff;
    line-height: 1.6;
    overflow-x: hidden;
    padding-top: 90px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 3px solid #fff;
    z-index: 1000;
    padding: 1rem 0;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: #fff;
    font-weight: 700;
    font-size: 1.1rem;
    transition: all 0.3s ease;
}

.nav-logo:hover {
    transform: translateY(-2px);
    color: #ccc;
}

.nav-links {
    display: flex;
    gap: 2.5rem;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 1.2rem;
}

.nav-link {
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    position: relative;
}

.nav-link:hover {
    color: #ccc;
    transform: translateY(-2px);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: #fff;
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #000000;
    padding-top: 80px;
    position: relative;
}

.hero-content {
    text-align: center;
    max-width: 800px;
}

.title {
    font-size: 4rem;
    font-weight: 700;
    margin-bottom: 1rem;
    letter-spacing: 2px;
    animation: slideInDown 1s ease-out;
}

.subtitle {
    font-size: 1.5rem;
    color: #ccc;
    margin-bottom: 3rem;
    animation: slideInUp 1s ease-out 0.3s both;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 3rem;
    margin-top: 2rem;
}

.stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: #fff;
}

.stat-label {
    font-size: 1rem;
    color: #aaa;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Section Styles */
section {
    padding: 80px 0;
    position: relative;
}

.section-title {
    font-size: 3rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 4rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 4px;
    background: #fff;
    border-radius: 2px;
}

/* Projects Section */
.projects {
    background: #000000;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.project-card {
    background: #1a1a1a;
    border: 3px solid #fff;
    border-radius: 15px;
    overflow: hidden;
    transition: all 0.3s ease;
    position: relative;
    color: #fff;
}

.project-card.featured {
    border-color: #ffd700;
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.3);
}

.project-card::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    border: 2px solid #fff;
    border-radius: 18px;
    transform: rotate(1deg);
    z-index: -1;
}

.project-card:hover {
    transform: translateY(-10px) rotate(1deg);
    box-shadow: 15px 15px 0 rgba(0, 0, 0, 0.3);
}

.project-image {
    height: 250px;
    background: #1a1a1a;
    display: flex;
    align-items: center;
    justify-content: center;
    border-bottom: 3px solid #fff;
    overflow: hidden;
    position: relative;
}

.project-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.project-placeholder {
    font-size: 5rem;
    opacity: 0.7;
}

.project-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.project-card:hover .project-overlay {
    opacity: 1;
}

.project-links {
    display: flex;
    gap: 1rem;
}

.project-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: #fff;
    color: #000;
    padding: 0.8rem 1.2rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.project-link:hover {
    transform: translateY(-2px);
    box-shadow: 4px 4px 0 rgba(255, 255, 255, 0.3);
}

.project-content {
    padding: 2rem;
}

.project-badge {
    display: inline-block;
    background: #ffd700;
    color: #000;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 1rem;
}

.project-content h3 {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.project-content p {
    color: #ccc;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.tag {
    background: #000;
    color: #fff;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.project-features {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.feature {
    background: #333;
    color: #fff;
    padding: 0.2rem 0.6rem;
    border-radius: 15px;
    font-size: 0.7rem;
    font-weight: 600;
}

/* Skills Section */
.skills {
    background: #1a1a1a;
}

.skills-categories {
    display: flex;
    flex-direction: column;
    gap: 3rem;
}

.skill-category h3 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 2rem;
    text-align: center;
    color: #fff;
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.skill-item {
    background: #000;
    border: 3px solid #fff;
    border-radius: 15px;
    padding: 1.5rem;
    text-align: center;
    transition: all 0.3s ease;
    position: relative;
}

.skill-item::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    border: 2px solid #fff;
    border-radius: 18px;
    transform: rotate(1deg);
    z-index: -1;
}

.skill-item:hover {
    transform: translateY(-5px) rotate(2deg);
    box-shadow: 8px 8px 0 rgba(0, 0, 0, 0.3);
}

.skill-item i {
    font-size: 3rem;
    margin-bottom: 1rem;
    display: block;
}

.skill-item span {
    font-weight: 700;
    font-size: 1.2rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1rem;
    display: block;
}

.skill-level {
    width: 100%;
    height: 8px;
    background: #333;
    border-radius: 4px;
    overflow: hidden;
    margin-top: 1rem;
}

.skill-bar {
    height: 100%;
    background: linear-gradient(90deg, #ffd700, #ffed4e);
    border-radius: 4px;
    transition: width 1s ease;
    width: 0;
}

/* Contact Section */
.contact {
    background: #000000;
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: start;
}

.contact-info h3 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: #fff;
}

.contact-info p {
    font-size: 1.1rem;
    color: #ccc;
    margin-bottom: 2rem;
    line-height: 1.6;
}

.contact-methods {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.contact-method {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.5rem;
    border: 3px solid #fff;
    border-radius: 10px;
    text-decoration: none;
    color: #fff;
    font-weight: 700;
    transition: all 0.3s ease;
    position: relative;
}

.contact-method::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    border: 2px solid #fff;
    border-radius: 12px;
    transform: rotate(1deg);
    z-index: -1;
}

.contact-method:hover {
    transform: translateY(-3px) rotate(1deg);
    box-shadow: 6px 6px 0 rgba(0, 0, 0, 0.3);
}

.contact-method.discord {
    background: #5865F2;
}

.contact-method.email {
    background: #333;
}

.contact-method i {
    font-size: 1.5rem;
}

/* Contact Form */
.contact-form-container {
    background: #1a1a1a;
    border: 3px solid #fff;
    border-radius: 15px;
    padding: 2rem;
    position: relative;
}

.contact-form-container::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    border: 2px solid #fff;
    border-radius: 18px;
    transform: rotate(1deg);
    z-index: -1;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 1rem;
    border: 2px solid #fff;
    border-radius: 10px;
    font-family: 'Comic Neue', cursive;
    font-size: 1rem;
    background: #1a1a1a;
    color: #fff;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: #ccc;
    box-shadow: 4px 4px 0 rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.submit-btn {
    background: #fff;
    color: #000;
    border: none;
    padding: 1rem 2rem;
    border-radius: 10px;
    font-family: 'Comic Neue', cursive;
    font-weight: 700;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    position: relative;
    overflow: hidden;
    width: 100%;
    justify-content: center;
}

.submit-btn::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    border: 2px solid #fff;
    border-radius: 12px;
    transform: rotate(1deg);
    z-index: -1;
}

.submit-btn:hover {
    transform: translateY(-3px) rotate(1deg);
    box-shadow: 6px 6px 0 rgba(0, 0, 0, 0.3);
}

/* Footer */
.footer {
    background: #fff;
    color: #000;
    padding: 3rem 0 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h4 {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.footer-section a {
    display: block;
    color: #333;
    text-decoration: none;
    margin-bottom: 0.5rem;
    transition: color 0.3s ease;
}

.footer-section a:hover {
    color: #000;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 2px solid #000;
}

.footer-bottom p {
    margin-bottom: 0.5rem;
}

/* Theme Toggle */
.theme-toggle {
    position: static;
    margin: 0;
    z-index: auto;
}

.theme-toggle i {
    font-size: 1.2rem;
    color: #fff;
    transition: all 0.3s ease;
}

/* Light Mode Styles */
body.light-mode {
    background: #ffffff;
    color: #000000;
}

body.light-mode .navbar {
    background: rgba(255, 255, 255, 0.95);
    border-bottom-color: #000;
}

body.light-mode .nav-logo,
body.light-mode .nav-link {
    color: #000;
}

body.light-mode .nav-link:hover {
    color: #333;
}

body.light-mode .nav-link::after {
    background: #000;
}

body.light-mode .hero {
    background: #f8f8f8;
}

body.light-mode .projects {
    background: #f8f8f8;
}

body.light-mode .skills {
    background: #f0f0f0;
}

body.light-mode .contact {
    background: #f8f8f8;
}

body.light-mode .project-card,
body.light-mode .skill-item,
body.light-mode .contact-form-container {
    background: #fff;
    color: #000;
    border-color: #000;
}

body.light-mode .project-card::before,
body.light-mode .skill-item::before,
body.light-mode .contact-form-container::before {
    border-color: #000;
}

body.light-mode .form-group input,
body.light-mode .form-group textarea,
body.light-mode .form-group select {
    background: #fff;
    color: #000;
    border-color: #000;
}

body.light-mode .submit-btn {
    background: #000;
    color: #fff;
}

body.light-mode .submit-btn::before {
    border-color: #000;
}

body.light-mode .theme-toggle {
    background: #fff;
    border-color: #000;
}

body.light-mode .theme-toggle::before {
    border-color: #000;
}

body.light-mode .theme-toggle i {
    color: #000;
}

body.light-mode .footer {
    background: #000;
    color: #fff;
}

body.light-mode .footer-section a {
    color: #ccc;
}

body.light-mode .footer-section a:hover {
    color: #fff;
}

body.light-mode .footer-bottom {
    border-top-color: #fff;
}

/* Animations */
@keyframes slideInDown {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-links {
        gap: 1.2rem;
    }
    .nav-actions {
        gap: 0.7rem;
    }
    .title {
        font-size: 2.5rem;
    }
    
    .subtitle {
        font-size: 1.2rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .hero-stats {
        flex-direction: column;
        gap: 1rem;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
    }
    
    .skills-grid {
        grid-template-columns: 1fr;
    }
    
    .contact-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }
    
    .nav-links {
        gap: 0.5rem;
    }
    .nav-actions {
        gap: 0.3rem;
    }
    .title {
        font-size: 2rem;
    }
    
    .subtitle {
        font-size: 1rem;
    }
    
    section {
        padding: 60px 0;
    }
    
    .project-card {
        margin: 0 10px;
    }
}

/* --- SEARCH BUTTON & TOGGLE FIXES FOR PORTFOLIO --- */
.search-container {
    position: static;
    margin: 0;
    z-index: auto;
}

.search-bar {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    background: #1a1a1a;
    border: 3px solid #fff;
    border-radius: 50%;
    position: relative;
    transition: border-radius 0.3s, width 0.3s, height 0.3s;
    overflow: hidden;
    box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.3);
}

/* Collapsed: only show toggle button, hide input and clear */
.search-input,
.search-clear {
    display: none;
}
.search-bar .search-icon {
    display: none;
}
.search-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    background: none;
    border: none;
    color: #fff;
    font-size: 1.3rem;
    cursor: pointer;
    z-index: 2;
}

/* Expanded: show input, hide toggle, make bar pill-shaped */
.search-container.expanded {
    width: 300px;
    height: 50px;
}
.search-container.expanded .search-bar {
    border-radius: 25px;
}
.search-container.expanded .search-input {
    display: block;
    flex: 1;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 1rem;
    font-family: 'Comic Neue', cursive;
    outline: none;
    padding: 0 10px;
    opacity: 1;
    width: auto;
    transition: all 0.3s ease;
}
.search-container.expanded .search-clear {
    display: block;
}
.search-container.expanded .search-toggle {
    display: none;
}

/* Theme toggle always below search, always a circle */
.theme-toggle {
    position: static;
    margin: 0;
    z-index: auto;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .search-container {
        top: 12px;
        right: 12px;
        width: 45px;
        height: 45px;
    }
    .search-container.expanded {
        width: 220px;
        height: 45px;
    }
    .theme-toggle {
        top: 65px;
        right: 12px;
        width: 45px;
        height: 45px;
    }
}
@media (max-width: 480px) {
    .search-container {
        top: 6px;
        right: 6px;
        width: 40px;
        height: 40px;
    }
    .search-container.expanded {
        width: 95vw;
        min-width: 0;
        height: 40px;
    }
    .theme-toggle {
        top: 52px;
        right: 6px;
        width: 40px;
        height: 40px;
    }
}

html, body {
    overflow-x: hidden;
    box-sizing: border-box;
}
*, *:before, *:after {
    box-sizing: inherit;
}
.main-header, .main-nav {
    max-width: 100vw;
    width: 100%;
}

html {
    scroll-padding-top: 80px;
}

.main-header {
    width: 100%;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1200;
    background: #000;
    border-bottom: 3px solid #fff;
    box-shadow: none;
}
.main-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    min-height: 64px;
    padding: 0 2rem;
    background: #000;
}
.main-nav .nav-link {
    color: #fff;
    font-family: 'Comic Neue', cursive;
    font-size: 1.15rem;
    font-weight: 700;
    text-decoration: none;
    padding: 0.7rem 2.2rem;
    border-radius: 12px;
    border: 2px solid #fff;
    background: #1a1a1a;
    box-shadow: none;
    transition: all 0.2s;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.main-nav .nav-link:hover {
    background: #fff;
    color: #000;
    border-color: #000;
    box-shadow: none;
    transform: translateY(-2px) scale(1.05);
}
.nav-actions {
    display: flex;
    align-items: center;
    gap: 1.2rem;
    height: 48px;
}
.search-container {
    position: static !important;
    margin: 0 !important;
    height: 48px;
    display: flex;
    align-items: center;
    background: none;
    border: none;
}
.search-bar {
    display: flex;
    align-items: center;
    background: #1a1a1a;
    border: 2px solid #fff;
    border-radius: 12px;
    width: 48px;
    height: 48px;
    overflow: hidden;
    transition: border-radius 0.3s, width 0.3s;
    box-shadow: none;
}
.search-container.expanded .search-bar {
    border-radius: 12px;
    width: 260px;
}
.search-toggle i, .theme-toggle i {
    font-size: 1.7rem;
}
.search-input, .search-clear { display: none; }
.search-container.expanded .search-input {
    display: block;
    flex: 1;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 1rem;
    padding: 0 10px;
    height: 100%;
}
.search-container.expanded .search-clear { display: block; }
.search-container.expanded .search-toggle { display: none; }
.theme-toggle {
    position: static !important;
    margin: 0 !important;
    z-index: auto !important;
    width: 48px;
    height: 48px;
    background: #1a1a1a;
    border: 2px solid #fff;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: none;
}
@media (max-width: 900px) {
    .main-nav { padding: 0 0.5rem; }
    .nav-link { padding: 0.7rem 1rem; font-size: 1rem; }
    .search-container.expanded .search-bar { width: 180px; }
}
@media (max-width: 600px) {
    .main-header { border-bottom-width: 2px; }
    .main-nav { min-height: 48px; }
    .nav-link, .nav-actions, .search-bar, .theme-toggle, .search-container { height: 38px; }
    .nav-link { padding: 0.4rem 0.7rem; font-size: 0.95rem; border-radius: 8px; }
    .search-bar, .theme-toggle { border-radius: 8px; }
    .search-toggle i, .theme-toggle i { font-size: 1.2rem; }
    .search-container.expanded .search-bar { width: 110px; }
    .nav-links { gap: 0.5rem; }
    .nav-actions { gap: 0.3rem; }
}

.scroll-popup {
    position: fixed !important;
    top: 10px !important;
    right: 20px !important;
    left: auto !important;
    margin: 0 !important;
    z-index: 2000 !important;
}
@media (max-width: 600px) {
    .scroll-popup {
        top: 6px !important;
        right: 8px !important;
    }
} 