/* =====================================================
   PORTFOLIO WEBSITE - MODERN CSS
   ===================================================== */

/* =====================================================
   1. ROOT VARIABLES & THEME
   ===================================================== */

:root {
    /* Light Mode Colors */
    --bg-primary: #ffffff;
    --bg-secondary: #f8f9fa;
    --bg-tertiary: #e9ecef;
    --text-primary: #212529;
    --text-secondary: #6c757d;
    --text-tertiary: #adb5bd;
    --accent-color: #6366f1;
    --accent-hover: #4f46e5;
    --border-color: #dee2e6;
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.15);
    --transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Dark Mode Colors */
body.dark-mode {
    --bg-primary: #1a1a2e;
    --bg-secondary: #16213e;
    --bg-tertiary: #0f3460;
    --text-primary: #eaeaea;
    --text-secondary: #b0b0b0;
    --text-tertiary: #808080;
    --border-color: #2d3561;
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.7);
}

/* =====================================================
   2. GLOBAL STYLES
   ===================================================== */

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    transition: var(--transition);
    overflow-x: hidden;
}

/* =====================================================
   3. CONTAINER & SPACING
   ===================================================== */

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* =====================================================
   4. TYPOGRAPHY
   ===================================================== */

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
}

p {
    color: var(--text-secondary);
    font-size: 16px;
    margin-bottom: 1rem;
}

.section-title {
    font-size: 3rem;
    text-align: center;
    margin-bottom: 4rem;
    position: relative;
    display: inline-block;
    width: 100%;
}

.section-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, var(--accent-color), transparent);
    margin: 15px auto 0;
    animation: slideInWidth 0.8s ease;
}

.accent {
    color: var(--accent-color);
    font-weight: 800;
}

/* =====================================================
   5. BUTTONS
   ===================================================== */

.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    border: none;
    transition: var(--transition);
    text-align: center;
}

.btn-primary {
    background-color: var(--accent-color);
    color: white;
    box-shadow: var(--shadow-md);
}

.btn-primary:hover {
    background-color: var(--accent-hover);
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background-color: transparent;
    color: var(--accent-color);
    border: 2px solid var(--accent-color);
}

.btn-secondary:hover {
    background-color: var(--accent-color);
    color: white;
    transform: translateY(-3px);
}

/* =====================================================
   6. NAVIGATION BAR
   ===================================================== */

.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background-color: var(--bg-primary);
    box-shadow: var(--shadow-md);
    z-index: 1000;
    border-bottom: 1px solid var(--border-color);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

.nav-logo a {
    font-size: 24px;
    font-weight: 800;
    color: var(--text-primary);
    text-decoration: none;
    letter-spacing: -1px;
}

.nav-logo a .accent {
    font-size: 28px;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 30px;
}

.nav-link {
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 500;
    position: relative;
    transition: var(--transition);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--accent-color);
    transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-link:hover {
    color: var(--accent-color);
}

/* Theme Toggle Button */
.theme-toggle {
    background-color: var(--bg-secondary);
    border: none;
    color: var(--text-primary);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    transition: var(--transition);
}

.theme-toggle:hover {
    background-color: var(--accent-color);
    color: white;
    transform: rotate(180deg);
}

/* Hamburger Menu */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 5px;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background-color: var(--text-primary);
    border-radius: 3px;
    transition: var(--transition);
}

/* =====================================================
   7. HERO SECTION
   ===================================================== */

.hero {
    margin-top: 70px;
    min-height: calc(100vh - 70px);
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-primary) 100%);
    padding: 60px 20px;
}

.hero-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    width: 100%;
}

.hero-text h1 {
    font-size: 4rem;
    margin-bottom: 20px;
    animation: slideInLeft 0.8s ease;
}

.hero-subtitle {
    font-size: 24px;
    color: var(--accent-color);
    font-weight: 600;
    margin-bottom: 30px;
    min-height: 40px;
    display: flex;
    align-items: center;
    word-break: break-word;
    white-space: normal;
}

.typing-text {
    display: inline;
}

.typing-text::after {
    content: '|';
    animation: blink 1s infinite;
    margin-left: 2px;
}

@keyframes blink {
    0%, 49% {
        opacity: 1;
    }
    50%, 100% {
        opacity: 0;
    }
}

.hero-description {
    font-size: 18px;
    color: var(--text-secondary);
    margin-bottom: 40px;
    line-height: 1.8;
    animation: slideInLeft 0.8s ease 0.2s both;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    animation: slideInLeft 0.8s ease 0.4s both;
}

.hero-image {
    display: flex;
    justify-content: center;
    align-items: center;
    animation: slideInRight 0.8s ease;
}

.avatar {
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-color), var(--accent-hover));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 150px;
    color: white;
    box-shadow: var(--shadow-lg);
    animation: float 3s ease-in-out infinite;
    overflow: hidden;
}

.profile-pic {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

/* =====================================================
   8. ABOUT SECTION
   ===================================================== */

.about {
    padding: 100px 20px;
    background-color: var(--bg-secondary);
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.about-text p {
    font-size: 18px;
    margin-bottom: 20px;
    line-height: 1.8;
}

.about-highlights {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-top: 30px;
}

.highlight-item {
    padding: 20px;
    background-color: var(--bg-primary);
    border-radius: 8px;
    text-align: center;
    transition: var(--transition);
}

.highlight-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.highlight-item i {
    font-size: 32px;
    color: var(--accent-color);
    margin-bottom: 10px;
}

.highlight-item h4 {
    font-size: 16px;
    color: var(--text-primary);
}

.about-image {
    display: flex;
    justify-content: center;
}

.image-placeholder {
    width: 350px;
    height: 350px;
    background: linear-gradient(135deg, var(--accent-color), var(--accent-hover));
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 120px;
    color: white;
    box-shadow: var(--shadow-lg);
    overflow: hidden;
}

.image-placeholder .profile-pic {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 10px;
}

/* =====================================================
   9. PROJECTS SECTION
   ===================================================== */

.projects {
    padding: 100px 20px;
    background-color: var(--bg-primary);
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
}

.project-card {
    background-color: var(--bg-secondary);
    border-radius: 10px;
    transition: var(--transition);
    border: 1px solid var(--border-color);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
    border-color: var(--accent-color);
}

.project-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
    flex-shrink: 0;
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.project-card:hover .project-image img {
    transform: scale(1.05);
}

.project-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 15px;
    padding: 20px 20px 0 20px;
}

.project-header i {
    font-size: 24px;
    color: var(--accent-color);
}

.project-category {
    background-color: var(--accent-color);
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.project-title {
    font-size: 22px;
    margin-bottom: 15px;
    color: var(--text-primary);
    padding: 0 20px;
}

.project-description {
    color: var(--text-secondary);
    font-size: 15px;
    line-height: 1.7;
    margin-bottom: 20px;
    padding: 0 20px;
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
    padding: 0 20px;
}

.tech-tag {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 500;
}

.project-links {
    display: flex;
    gap: 15px;
    padding: 0 20px 20px 20px;
}

.project-link {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--accent-color);
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
}

.project-link:hover {
    color: var(--accent-hover);
    gap: 12px;
}

/* =====================================================
   10. SKILLS SECTION
   ===================================================== */

.skills {
    padding: 100px 20px;
    background-color: var(--bg-secondary);
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
}

.skill-category {
    background-color: var(--bg-primary);
    padding: 40px 30px;
    border-radius: 10px;
    border: 1px solid var(--border-color);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.skill-category:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-5px);
}

.skill-category-title {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 30px;
    font-size: 20px;
    color: var(--text-primary);
    width: 100%;
}

.skill-category-title i {
    color: var(--accent-color);
    font-size: 24px;
}

.skill-items {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    width: 100%;
    max-width: 300px;
}

.skill-item {
    text-align: center;
    padding: 20px 15px;
    border-radius: 8px;
    background-color: var(--bg-secondary);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.skill-item:hover {
    background-color: var(--bg-tertiary);
    transform: scale(1.05);
}

.skill-icon {
    font-size: 40px;
    color: var(--accent-color);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.skill-item p {
    font-size: 14px;
    font-weight: 600;
    margin: 0;
    line-height: 1.4;
}

/* =====================================================
   11. EXPERIENCE SECTION
   ===================================================== */

.experience {
    padding: 100px 20px;
    background-color: var(--bg-primary);
}

.experience-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
}

.timeline {
    position: relative;
    padding-left: 40px;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 10px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(180deg, var(--accent-color), var(--bg-tertiary));
}

.timeline-item {
    position: relative;
    margin-bottom: 30px;
    padding-bottom: 20px;
}

.timeline-dot {
    position: absolute;
    left: -32px;
    top: 5px;
    width: 20px;
    height: 20px;
    background-color: var(--accent-color);
    border: 4px solid var(--bg-primary);
    border-radius: 50%;
    box-shadow: 0 0 0 3px var(--accent-color);
}

.timeline-content h3 {
    font-size: 18px;
    margin-bottom: 5px;
}

.timeline-date {
    color: var(--accent-color);
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 8px;
}

.timeline-description {
    color: var(--text-secondary);
    font-size: 15px;
    line-height: 1.6;
}

.achievements {
    background-color: var(--bg-secondary);
    padding: 40px;
    border-radius: 10px;
}

.achievements-title {
    font-size: 22px;
    margin-bottom: 25px;
    color: var(--text-primary);
}

.achievement-items {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.achievement-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background-color: var(--bg-primary);
    border-radius: 8px;
    border-left: 4px solid var(--accent-color);
}

.achievement-item i {
    font-size: 24px;
    color: var(--accent-color);
    flex-shrink: 0;
}

.achievement-item p {
    margin: 0;
    font-size: 15px;
    font-weight: 500;
}

/* =====================================================
   12. CONTACT SECTION
   ===================================================== */

.contact {
    padding: 100px 20px;
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%);
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: start;
}

.contact-info h3 {
    font-size: 28px;
    margin-bottom: 15px;
}

.contact-info > p {
    margin-bottom: 30px;
}

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 30px;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    gap: 20px;
}

.contact-item i {
    font-size: 24px;
    color: var(--accent-color);
    margin-top: 5px;
}

.contact-item h4 {
    font-size: 16px;
    margin-bottom: 5px;
}

.contact-item a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: var(--transition);
}

.contact-item a:hover {
    color: var(--accent-color);
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-links a {
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--bg-primary);
    border-radius: 50%;
    color: var(--accent-color);
    font-size: 18px;
    transition: var(--transition);
}

.social-links a:hover {
    background-color: var(--accent-color);
    color: white;
    transform: translateY(-5px);
}

/* Contact Form */
.contact-form {
    background-color: var(--bg-primary);
    padding: 40px;
    border-radius: 10px;
    box-shadow: var(--shadow-md);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text-primary);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-family: inherit;
    font-size: 15px;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.form-message {
    margin-top: 15px;
    padding: 12px 15px;
    border-radius: 6px;
    text-align: center;
    font-weight: 500;
    display: none;
}

.form-message.success {
    background-color: #d4edda;
    color: #155724;
    display: block;
}

.form-message.error {
    background-color: #f8d7da;
    color: #721c24;
    display: block;
}

/* =====================================================
   13. FOOTER
   ===================================================== */

.footer {
    background-color: var(--bg-secondary);
    padding: 30px 20px;
    border-top: 1px solid var(--border-color);
    text-align: center;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
}

.footer-content p {
    margin: 5px 0;
    font-size: 14px;
}

.footer-content i {
    color: var(--accent-color);
}

/* =====================================================
   14. ANIMATIONS
   ===================================================== */

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

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInWidth {
    from {
        width: 0;
    }
    to {
        width: 80px;
    }
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-20px);
    }
}

@keyframes typing {
    0% {
        content: '';
    }
    5% {
        content: 'C';
    }
    10% {
        content: 'Co';
    }
    15% {
        content: 'Com';
    }
    20% {
        content: 'Comp';
    }
    25% {
        content: 'Compu';
    }
    30% {
        content: 'Comput';
    }
    35% {
        content: 'Compute';
    }
    40% {
        content: 'Computer';
    }
    45% {
        content: 'Computer ';
    }
    50% {
        content: 'Computer S';
    }
    55% {
        content: 'Computer Sc';
    }
    60% {
        content: 'Computer Sci';
    }
    65% {
        content: 'Computer Scie';
    }
    70% {
        content: 'Computer Scien';
    }
    75% {
        content: 'Computer Scienc';
    }
    80% {
        content: 'Computer Science';
    }
    85% {
        content: 'Computer Science ';
    }
    90% {
        content: 'Computer Science S';
    }
    95% {
        content: 'Computer Science St';
    }
    100% {
        content: 'Computer Science Student & Developer';
    }
}

/* =====================================================
   15. RESPONSIVE DESIGN
   ===================================================== */

/* Tablets */
@media (max-width: 768px) {
    /* Navigation */
    .hamburger {
        display: flex;
    }

    .nav-menu {
        position: absolute;
        top: 70px;
        left: 0;
        width: 100%;
        background-color: var(--bg-primary);
        flex-direction: column;
        padding: 20px;
        gap: 15px;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
        box-shadow: var(--shadow-md);
    }

    .nav-menu.active {
        max-height: 400px;
    }

    .nav-link {
        font-size: 18px;
    }

    /* Hero Section */
    .hero-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .hero-text h1 {
        font-size: 2.5rem;
    }

    .hero-subtitle {
        font-size: 20px;
    }

    .hero-buttons {
        flex-direction: column;
    }

    .avatar {
        width: 200px;
        height: 200px;
        font-size: 100px;
    }

    /* Section Title */
    .section-title {
        font-size: 2rem;
        margin-bottom: 2.5rem;
    }

    /* About Section */
    .about-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .image-placeholder {
        width: 100%;
        height: 250px;
        font-size: 80px;
    }

    /* Experience Section */
    .experience-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .achievement-items {
        grid-template-columns: 1fr;
    }

    /* Contact Section */
    .contact-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }
}

/* Mobile Devices */
@media (max-width: 480px) {
    /* Hero Section */
    .hero-text h1 {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 18px;
    }

    .hero-description {
        font-size: 16px;
    }

    /* Section Title */
    .section-title {
        font-size: 1.8rem;
        margin-bottom: 2rem;
    }

    /* Projects Grid */
    .projects-grid {
        grid-template-columns: 1fr;
    }

    /* Skills Grid */
    .skills-grid {
        grid-template-columns: 1fr;
    }

    .skill-items {
        grid-template-columns: 1fr;
    }

    /* About Highlights */
    .about-highlights {
        grid-template-columns: 1fr;
    }

    /* Contact Details */
    .contact-details {
        gap: 15px;
    }

    .contact-form {
        padding: 25px;
    }

    /* General */
    .btn {
        padding: 10px 20px;
        font-size: 14px;
    }

    p {
        font-size: 15px;
    }
}

/* =====================================================
   16. UTILITY CLASSES
   ===================================================== */

.text-center {
    text-align: center;
}

.mt-20 {
    margin-top: 20px;
}

.mb-20 {
    margin-bottom: 20px;
}

.hidden {
    display: none !important;
}
