:root {
    --bg-dark: #ffffff;
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --accent-color: #8b5cf6;
    --accent-glow: rgba(139, 92, 246, 0.3);
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(139, 92, 246, 0.2);
}



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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

h1,
h2,
h3,
.logo {
    font-family: 'Outfit', sans-serif;
}


/* Navigation */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    padding: 1.25rem 0;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--glass-border);
    z-index: 100;
    background: rgba(255, 255, 255, 0.8);
}

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

.logo {
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -1px;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.3s ease;
}

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

/* Typography & Utilities */
.gradient-text {
    background: linear-gradient(to right, #a78bfa, #38bdf8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

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

.mt-4 {
    margin-top: 2rem;
    display: inline-block;
}

/* Sections */
main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.section {
    padding: 6rem 0;
    min-height: 50vh;
}

.section-title {
    font-size: 2.5rem;
    margin-bottom: 3rem;
    text-align: center;
    font-weight: 600;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 5rem;
}

.hero-content {
    flex: 1;
    padding-right: 2rem;
}

.main-title {
    font-size: 4.5rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    letter-spacing: -1px;
}

.subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
    max-width: 500px;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
}

.btn {
    padding: 0.8rem 1.8rem;
    border-radius: 9999px;
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    cursor: pointer;
}

.btn.primary {
    background-color: var(--accent-color);
    color: white;
    box-shadow: 0 0 20px var(--accent-glow);
}

.btn.primary:hover {
    box-shadow: 0 0 30px var(--accent-glow);
    transform: translateY(-2px);
}

.btn.secondary {
    background-color: transparent;
    border: 1px solid var(--glass-border);
    color: var(--text-primary);
}

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

/* Glassmorphism */
.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    border-radius: 1.5rem;
    padding: 2.5rem;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}

/* Hero Graphic Animations */
.hero-graphic {
    flex: 1;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 500px;
    perspective: 1000px;
}

.blob-shape {
    position: absolute;
    width: 450px;
    height: 450px;
    max-width: 90vw;
    max-height: 90vw;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.4), rgba(139, 92, 246, 0.1));
    animation: wiggle 8s ease-in-out infinite alternate;
    z-index: 1;
}

@keyframes wiggle {
    0% {
        border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
    }

    50% {
        border-radius: 30% 60% 70% 40% / 50% 60% 30% 60%;
    }

    100% {
        border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
    }
}

.hero-image {
    position: relative;
    z-index: 2;
    width: 420px;
    max-width: 85vw;
    height: auto;
    object-fit: cover;
    filter: drop-shadow(0 10px 30px rgba(139, 92, 246, 0.3));
}

.glass-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.5));
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    box-shadow: 0 8px 32px 0 rgba(139, 92, 246, 0.15);
    border-radius: 1.5rem;
    padding: 2rem;
    width: 320px;
    position: relative;
    z-index: 2;
    transition: transform 0.1s ease-out;
    transform-style: preserve-3d;
}

.card-content {
    transform: translateZ(30px);
}

.card-content h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.card-content p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}

.code-snippet {
    background: rgba(139, 92, 246, 0.05);
    padding: 1rem;
    border-radius: 0.5rem;
    font-family: monospace;
    font-size: 0.85rem;
    color: var(--accent-color);
}

.floating-element {
    position: absolute;
    border-radius: 50%;
    filter: blur(40px);
    z-index: 1;
}

.el-1 {
    width: 250px;
    height: 250px;
    background: rgba(139, 92, 246, 0.3);
    top: -10%;
    right: 5%;
    animation: float-alt 10s ease-in-out infinite;
}

.el-2 {
    width: 200px;
    height: 200px;
    background: rgba(56, 189, 248, 0.3);
    bottom: -10%;
    left: 5%;
    animation: float 8s ease-in-out infinite;
}

/* Projects Grid */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
}

.project-card {
    transition: transform 0.3s ease, border-color 0.3s ease;
    display: flex;
    flex-direction: column;
}

.project-card:hover {
    transform: translateY(-5px);
    border-color: rgba(255, 255, 255, 0.2);
}

.project-tag {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: rgba(139, 92, 246, 0.15);
    color: #a78bfa;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
    margin-bottom: 1rem;
    width: fit-content;
}

.project-card h3 {
    margin-bottom: 0.75rem;
    font-size: 1.4rem;
}

.project-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    flex-grow: 1;
}

.project-link {
    display: inline-block;
    margin-top: 1.5rem;
    color: var(--accent-color);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

.project-link:hover {
    color: #a78bfa;
}

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

/* Animations */
@keyframes float {
    0% {
        transform: translateY(0px) translateX(0px);
    }

    50% {
        transform: translateY(-20px) translateX(10px);
    }

    100% {
        transform: translateY(0px) translateX(0px);
    }
}

@keyframes float-alt {
    0% {
        transform: translateY(0px) scale(1);
    }

    50% {
        transform: translateY(20px) scale(1.05);
    }

    100% {
        transform: translateY(0px) scale(1);
    }
}

@media (max-width: 900px) {
    .hero {
        flex-direction: column;
        text-align: center;
        padding-top: 8rem;
    }

    .hero-content {
        padding-right: 0;
    }

    .main-title {
        font-size: 3.5rem;
    }

    .subtitle {
        margin: 0 auto 2.5rem auto;
    }

    .cta-buttons {
        justify-content: center;
    }

    .hero-graphic {
        margin-top: 4rem;
        width: 100%;
    }
}

@media (max-width: 600px) {
    .main-title {
        font-size: 2.5rem;
    }

    .nav-links {
        display: none;
    }
}

/* Midterm Section Styles */
.mb-6 {
    margin-bottom: 2.5rem;
}

.mt-4 {
    margin-top: 1.5rem;
}

.mb-2 {
    margin-bottom: 0.5rem;
}

/* Table Styles */
.table-responsive {
    width: 100%;
    overflow-x: auto;
}

.activity-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.95rem;
}

.activity-table th,
.activity-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid var(--glass-border);
}

.activity-table th {
    background-color: rgba(139, 92, 246, 0.1);
    color: var(--text-primary);
    font-weight: 600;
}

.activity-table td {
    color: var(--text-secondary);
}

.activity-table tbody tr:hover {
    background-color: rgba(139, 92, 246, 0.05);
}

.midterm-container {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.subsection-title {
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
    border-bottom: 1px solid var(--glass-border);
    padding-bottom: 0.5rem;
}

.qa-item {
    background: var(--glass-bg);
    border-radius: 0.8rem;
    padding: 1.5rem;
    margin-bottom: 1rem;
    border: 1px solid var(--glass-border);
}

.qa-item .question {
    font-size: 1.1rem;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.qa-item .answer {
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.qa-item .explanation {
    font-size: 0.9rem;
    color: var(--accent-color);
    background: rgba(139, 92, 246, 0.1);
    padding: 0.8rem;
    border-radius: 0.5rem;
}

.intro-text {
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

.activity-card {
    background: var(--glass-bg);
    border-radius: 1rem;
    padding: 1.5rem;
    margin-bottom: 2rem;
    border: 1px solid var(--glass-border);
    scroll-margin-top: 100px;
}

.activity-card h4 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.activity-details {
    margin-top: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    color: var(--text-secondary);
}

.activity-details p strong {
    color: var(--text-primary);
}

.media-container {
    width: 100%;
    border-radius: 0.8rem;
    overflow: hidden;
    border: 1px solid var(--glass-border);
    background: #f1f5f9;
    margin-top: 1rem;
    margin-bottom: 1rem;
}

.content-img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

.code-block {
    background: #f8fafc;
    border-radius: 0.8rem;
    padding: 1.5rem;
    overflow-x: auto;
    border: 1px solid var(--glass-border);
    margin: 1rem 0;
}

.code-block pre {
    margin: 0;
}

.code-block code {
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.9rem;
    color: #334155;
    line-height: 1.5;
}

.download-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1.5rem;
    background: rgba(139, 92, 246, 0.15);
    color: var(--accent-color) !important;
    border-color: var(--accent-color);
}

.download-btn:hover {
    background: rgba(139, 92, 246, 0.25);
}

.reflection-box {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.05), transparent);
    border-left: 4px solid var(--accent-color);
    padding: 1.5rem;
    border-radius: 0 0.8rem 0.8rem 0;
    margin-top: 1.5rem;
}

.reflection-box h4 {
    margin-bottom: 0.8rem;
    color: var(--text-primary);
    font-size: 1.2rem;
}

.reflection-box p {
    color: var(--text-secondary);
    line-height: 1.7;
}

.key-insight {
    background: linear-gradient(145deg, rgba(139, 92, 246, 0.1), rgba(56, 189, 248, 0.05));
    border: 1px solid var(--glass-border);
    border-left: 5px solid var(--accent-color);
    padding: 1.8rem;
    border-radius: 1rem;
    margin-top: 2rem;
    position: relative;
    box-shadow: 0 10px 25px -5px rgba(139, 92, 246, 0.1);
    transition: transform 0.3s ease;
}

.key-insight:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 30px -5px rgba(139, 92, 246, 0.2);
}

.key-insight h5 {
    color: var(--accent-color);
    font-size: 1.1rem;
    margin-bottom: 0.8rem;
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.key-insight p {
    color: var(--text-primary);
    font-weight: 500;
    line-height: 1.7;
    margin: 0;
}

/* Dropdown Styles */
details.activity-card summary {
    cursor: pointer;
    list-style: none;
    outline: none;
}

details.activity-card summary::-webkit-details-marker {
    display: none;
}

details.activity-card summary .summary-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

details.activity-card summary h4 {
    margin-bottom: 0;
}

.dropdown-icon {
    transition: transform 0.3s ease;
    color: var(--accent-color);
    font-size: 1.2rem;
}

details.activity-card[open] .dropdown-icon {
    transform: rotate(180deg);
}