/* Modern Professional Theme - Bento Style */
:root {
    /* Color Palette - Sophisticated Dark Mode */
    --bg-body: #0a0a0a;
    --bg-card: #171717;
    --bg-card-hover: #262626;

    /* Text Colors */
    --text-main: #ededed;
    --text-secondary: #a1a1aa;
    --text-muted: #525252;

    /* Accents - Subtle Blue/Violet */
    --accent-primary: #3b82f6;
    /* Modern Blue */
    --accent-secondary: #8b5cf6;
    /* Modern Violet */
    --accent-glow: rgba(59, 130, 246, 0.5);

    /* Borders */
    --border-subtle: #262626;
    --border-active: #404040;

    /* Spacing & Layout */
    --container-width: 1200px;
    --header-height: 70px;
    --radius-lg: 24px;
    --radius-md: 16px;
    --radius-sm: 8px;

    /* Transitions */
    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
    /* Apple-like ease */
}

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

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-body);
    color: var(--text-main);
    font-family: 'Inter', sans-serif;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 700;
    letter-spacing: -0.02em;
    /* Tight tracking for modern look */
    color: var(--text-main);
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.2s ease;
}

ul {
    list-style: none;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-body);
}

::-webkit-scrollbar-thumb {
    background: var(--border-active);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}

/* Utilities */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
}

.section-padding {
    padding: 100px 0;
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    background: rgba(10, 10, 10, 0.8);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-subtle);
    z-index: 1000;
    display: flex;
    align-items: center;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo {
    font-size: 1.25rem;
    font-weight: 700;
    background: linear-gradient(to right, var(--text-main), var(--text-secondary));
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-links {
    display: flex;
    gap: 32px;
}

.nav-links a {
    font-size: 0.95rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.nav-links a:hover {
    color: var(--text-main);
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: var(--text-main);
    font-size: 1.5rem;
    cursor: pointer;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    padding-top: var(--header-height);
}

/* Background Gradients */
.hero::before {
    content: '';
    position: absolute;
    top: -10%;
    left: 50%;
    transform: translateX(-50%);
    width: 60%;
    height: 60%;
    background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%);
    opacity: 0.3;
    pointer-events: none;
    filter: blur(80px);
}

/* Project Detail Page Utilities */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    list-style: none;
    padding: 0;
    margin: 0;
}

.feature-item {
    display: flex;
    gap: 20px;
    align-items: flex-start;
    padding: 28px;
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    transition: all 0.3s ease;
}

.feature-item:hover {
    border-color: var(--border-active);
    background: var(--bg-card-hover);
    transform: translateY(-2px);
}

.feature-icon {
    color: var(--accent-primary);
    font-size: 1.75rem;
    margin-top: 2px;
    flex-shrink: 0;
}

.feature-item strong {
    display: block;
    color: var(--text-main);
    margin-bottom: 8px;
    font-size: 1.05rem;
    font-weight: 600;
}

.feature-item p {
    color: var(--text-secondary);
    margin: 0;
    font-size: 0.95rem;
    line-height: 1.7;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    /* Text left, Image right */
    gap: 60px;
    align-items: center;
}

.hero-text h1 {
    font-size: 4rem;
    line-height: 1.1;
    margin-bottom: 24px;
}

.hero-text h1 span {
    color: var(--accent-primary);
}

.hero-text p {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 32px;
    max-width: 500px;
}

.hero-image {
    position: relative;
    display: flex;
    justify-content: center;
}

.hero-profile-img {
    width: 300px;
    height: 300px;
    border-radius: var(--radius-lg);
    object-fit: cover;
    border: 4px solid var(--border-subtle);
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.5);
    background-color: var(--bg-card);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background-color: var(--text-main);
    color: var(--bg-body);
    border-radius: var(--radius-md);
    font-weight: 600;
    transition: transform 0.2s var(--ease-out);
}

.btn:hover {
    transform: translateY(-2px);
    background-color: #fff;
}

.btn-secondary {
    background-color: var(--bg-card);
    color: var(--text-main);
    border: 1px solid var(--border-active);
}

.btn-secondary:hover {
    background-color: var(--bg-card-hover);
}

/* Contact Section */
.contact-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 32px;
}

.contact-item {
    transition: transform 0.2s ease;
}

.contact-item:hover {
    transform: translateX(4px);
}

/* Form Styles */
input[type="text"],
input[type="email"],
textarea {
    transition: border-color 0.2s ease, background-color 0.2s ease;
}

input[type="text"]:focus,
input[type="email"]:focus,
textarea:focus {
    outline: none;
    border-color: var(--accent-primary);
    background: var(--bg-card-hover);
}

/* Responsive Design */

/* Bento Grid System */
.bento-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: minmax(180px, auto);
    gap: 24px;
}

.bento-item {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: 32px;
    display: flex;
    flex-direction: column;
    transition: border-color 0.3s ease, transform 0.3s var(--ease-out);
    position: relative;
    overflow: hidden;
}

.bento-item:hover {
    border-color: var(--border-active);
    transform: translateY(-4px);
    background: var(--bg-card-hover);
}

/* Bento Spans */
.span-2 {
    grid-column: span 2;
}

.span-3 {
    grid-column: span 3;
}

.row-2 {
    grid-row: span 2;
}

/* Bento Content */
.bento-icon {
    font-size: 2rem;
    color: var(--accent-primary);
    margin-bottom: 20px;
}

.bento-title {
    font-size: 1.5rem;
    margin-bottom: 12px;
}

.bento-text {
    color: var(--text-secondary);
    font-size: 1rem;
}

/* Skills Tags in Bento */
.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: auto;
}

.skill-tag {
    background: rgba(255, 255, 255, 0.05);
    padding: 6px 12px;
    border-radius: 99px;
    font-size: 0.85rem;
    color: var(--text-secondary);
    border: 1px solid var(--border-subtle);
}

/* Mobile Responsive */
@media (max-width: 968px) {
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 40px;
    }

    .hero-text p {
        margin: 0 auto 32px auto;
    }

    .bento-grid {
        grid-template-columns: 1fr;
    }

    .span-2,
    .span-3 {
        grid-column: span 1;
    }

    .nav-links {
        display: none;
        /* Mobile menu needed */
    }

    .mobile-menu-btn {
        display: block;
    }

    /* Mobile Menu Active State */
    .nav-links.active {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: var(--header-height);
        left: 0;
        width: 100%;
        background: var(--bg-card);
        padding: 24px;
        border-bottom: 1px solid var(--border-subtle);
    }
}

/* =========================================
   Infinite Scroll Marquee Styles
   ========================================= */

.marquee-container {
    width: 100%;
    overflow: hidden;
    padding: 20px 0;
    position: relative;
    /* Fade effect on sides */
    mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
    -webkit-mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
}

.marquee-track {
    display: flex;
    gap: 24px;
    width: max-content;
    /* Ensure track is wide enough */
}

/* Animation Classes */
.scroll-left {
    animation: scrollLeft 40s linear infinite;
}

.scroll-right {
    animation: scrollRight 40s linear infinite;
}

/* Pause on Hover */
.marquee-track:hover {
    animation-play-state: paused;
}

@keyframes scrollLeft {
    from {
        transform: translateX(0);
    }

    to {
        transform: translateX(-50%);
    }
}

@keyframes scrollRight {
    from {
        transform: translateX(-50%);
    }

    to {
        transform: translateX(0);
    }
}

/* Marquee Card Specifics */
.marquee-card {
    width: 350px;
    /* Fixed width for consistency */
    flex-shrink: 0;
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: 24px;
    transition: transform 0.3s ease, border-color 0.3s ease;
    text-decoration: none;
    display: block;
}

.marquee-card:hover {
    transform: translateY(-4px);
    border-color: var(--accent-primary);
    background: var(--bg-card-hover);
}

.marquee-card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 16px;
}

.marquee-icon {
    font-size: 1.5rem;
    color: var(--accent-primary);
    background: rgba(59, 130, 246, 0.1);
    padding: 12px;
    border-radius: 12px;
}

.marquee-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--text-main);
}

.marquee-desc {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 16px;
    line-height: 1.5;
    /* Limit lines */
    display: -webkit-box;
    line-clamp: 3;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}