/* main.css - Core styles and variables */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Dark theme (default) */
    --bg-deep: #0a0c12;
    --card-dark: #131720;
    --border-subtle: #2a2f3a;
    --text-bright: #eef2f8;
    --text-soft: #9aa7b9;
    --text-muted: #6b7b8f;
    --accent-teal: #2dd4bf;
    --accent-teal-dim: #1e3f3a;
    --nav-bg: #0f1219;
    --hover-glow: rgba(45, 212, 191, 0.15);
    --particle-color: rgba(45, 212, 191, 0.3);
    --radius-md: 18px;
    --radius-lg: 28px;
    --shadow-color: rgba(0, 0, 0, 0.5);
    --chart-grid: rgba(255, 255, 255, 0.1);
    --chart-label: #9aa7b9;
    --chart-tick: #9aa7b9;
}

body {
    background-color: var(--bg-deep);
    color: var(--text-bright);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    padding: 2rem 1rem;
    position: relative;
    transition: background-color 0.3s ease, color 0.2s ease;
}

.wrapper {
    max-width: 1300px;
    width: 100%;
    display: flex;
    gap: 2rem;
    position: relative;
    z-index: 5;
}

.main-content {
    flex: 1;
    min-width: 0;
}

/* Card styles */
.card {
    background: rgba(19, 23, 32, 0.85);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    border-radius: var(--radius-md);
    padding: 2rem 2.2rem;
    margin-bottom: 2rem;
    border: 1px solid var(--border-subtle);
    box-shadow: 0 20px 30px -15px var(--shadow-color);
    transition: all 0.25s ease;
    scroll-margin-top: 2rem;
}

.card:hover {
    border-color: var(--accent-teal);
    box-shadow: 0 25px 35px -18px var(--accent-teal);
}

/* Typography */
h1 {
    font-size: 2.8rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    background: linear-gradient(145deg, var(--text-bright), var(--accent-teal));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    line-height: 1.2;
    margin-bottom: 0.5rem;
}

.subhead {
    font-size: 1.2rem;
    color: var(--text-soft);
    margin-bottom: 0.5rem;
}

h2 {
    font-size: 1.8rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.7rem;
    border-bottom: 2px solid var(--accent-teal);
    padding-bottom: 0.5rem;
    margin-bottom: 1.8rem;
    color: var(--text-bright);
}

h2 i {
    color: var(--accent-teal);
}

h3 {
    color: var(--text-bright);
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

/* Contact bar */
.contact-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    align-items: center;
    margin: 1.5rem 0 0.5rem;
    color: var(--text-soft);
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.contact-item i {
    color: var(--accent-teal);
    width: 1.2rem;
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-left: auto;
}

.social-link {
    background: var(--accent-teal-dim);
    border: 1px solid var(--accent-teal);
    color: var(--accent-teal);
    padding: 0.4rem 1.3rem;
    border-radius: 40px;
    text-decoration: none;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    transition: 0.2s ease;
}

.social-link:hover {
    background: var(--accent-teal);
    color: var(--bg-deep);
    border-color: var(--accent-teal);
    transform: scale(1.02);
    text-decoration: none;
}

/* Skills */
.skills-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}

.skill-tag {
    background: var(--accent-teal-dim);
    padding: 0.4rem 1.2rem;
    border-radius: 40px;
    color: var(--accent-teal);
    font-size: 0.85rem;
    border: 1px solid var(--accent-teal);
    display: inline-block;
    margin: 0.2rem;
    font-weight: 500;
    transition: 0.2s ease;
}

.skill-tag:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(45, 212, 191, 0.2);
}

.languages {
    display: flex;
    gap: 2.5rem;
    margin-top: 1rem;
    color: var(--text-soft);
}

/* Chart container */
.chart-container {
    background: var(--card-dark);
    border-radius: 20px;
    padding: 1.5rem;
    border: 1px solid var(--border-subtle);
    margin-top: 1rem;
    height: 350px;
    width: 100%;
    transition: background-color 0.3s ease;
}

/* GitHub contributions */
.github-contrib {
    background: var(--card-dark);
    border-radius: 20px;
    padding: 1.5rem;
    border: 1px dashed var(--accent-teal);
    text-align: center;
    margin: 1rem 0;
    color: var(--text-soft);
}

/* Grid layouts */
.help-grid, .testimonial-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 1rem;
}

.help-card {
    background: var(--card-dark);
    border-radius: 28px;
    padding: 2rem 1.5rem;
    border: 1px solid var(--border-subtle);
    transition: 0.2s ease;
    text-align: center;
}

.help-card:hover {
    border-color: var(--accent-teal);
    transform: translateY(-5px);
}

.help-icon {
    font-size: 2.8rem;
    color: var(--accent-teal);
    margin-bottom: 1rem;
}

/* Contact form */
.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 0.8rem;
    margin-bottom: 1rem;
    background: var(--card-dark);
    border: 1px solid var(--border-subtle);
    border-radius: 12px;
    color: var(--text-bright);
    font-family: inherit;
    transition: border-color 0.2s ease;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--accent-teal);
    box-shadow: 0 0 0 2px var(--accent-teal-dim);
}

.btn {
    background: var(--accent-teal);
    color: var(--bg-deep);
    border: none;
    padding: 0.7rem 1.5rem;
    border-radius: 40px;
    font-weight: 600;
    cursor: pointer;
    display: inline-block;
    text-decoration: none;
    transition: 0.2s ease;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(45, 212, 191, 0.3);
    text-decoration: none;
}

/* Lists */
ul {
    list-style: none;
}

li {
    color: var(--text-soft);
    margin-bottom: 0.5rem;
}

a {
    color: var(--accent-teal);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    text-decoration: underline;
}

/* Footer */
.footer-note {
    text-align: center;
    color: var(--text-soft);
    padding: 2rem 0 0.5rem;
}

/* Animation keyframes */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes slideIn {
    from { transform: translateX(-20px); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

/* Responsive */
@media (max-width: 800px) {
    .wrapper {
        flex-direction: column;
    }
    
    .skills-grid {
        grid-template-columns: 1fr;
    }
    
    .contact-bar {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .social-links {
        margin-left: 0;
    }
    
    h1 {
        font-size: 2.2rem;
    }
}

@media (max-width: 480px) {
    body {
        padding: 1rem 0.5rem;
    }
    
    .card {
        padding: 1.5rem;
    }
    
    h2 {
        font-size: 1.5rem;
    }
}

/* Print styles */
@media print {
    .left-nav, .theme-toggle, .contact-form, .btn, .github-contrib, #particle-bg {
        display: none !important;
    }
    
    body {
        background: white;
        color: black;
        padding: 1rem;
    }
    
    .card {
        border: 1px solid #ccc;
        break-inside: avoid;
        background: white;
        box-shadow: none;
    }
    
    h1 {
        color: black;
        background: none;
        -webkit-background-clip: unset;
        background-clip: unset;
    }
}