/* Base Font Variables - Minimal, modern style */
:root {
    --font-primary: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-heading: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-system: -apple-system, system-ui, sans-serif;
}

/* Theme Variables - Light Theme (Morning Fog) */
:root, :root[data-theme="morning-fog"] {
    --bg-color: #f2efe8;
    --text-color: #6d6355;
    --primary-color: #2c2926;
    --secondary-color: #a69d93;
    --accent-color: #8b2500;
    --card-bg: #faf8f5;
    --border-color: #ddd8cd;
    --nav-bg: #f2efe8;
    --big-intro: #2c2926;
    --muted-text: #6d6355;
    --light-text: #faf8f5;
    --cursor-color: #2c2926;
    --date-color: #a69d93;
    --list-text: #6d6355;
    --error-color: #8b2500;
    --button-text-color: #f2efe8;
    --input-bg: #edeae3;
    --input-border: #ddd8cd;
    --hover-bg: #e9e5db;
    --button-active: #2c2926;
    --button-hover-bg: #8b2500;
    --button-hover-border: var(--button-hover-bg);
    --button-hover-text-color: #f2efe8;
    --button-bg: #2c2926;
    --shadow: 0 4px 12px rgba(44,41,38,0.06);
    --theme-toggle-icon-color: #6d6355;
    --theme-toggle-glow: rgba(109, 99, 85, 0.2);
    --subtitle-color: #6d6355;
    --heading-color: #2c2926;
    --timeline-title-color: var(--big-intro);
    --timeline-desc-color: var(--subtitle-color);
    --emphasis-color: var(--primary-color);
    --about-desc-color: var(--subtitle-color);
}

/* Theme Variables - Dark Theme (Piano Symphony) */
:root[data-theme="piano-symphony"] {
    /* === Background Colors === */
    --bg-color: #1c1b19;                       /* Warm dark charcoal */
    --card-bg: #2a2825;                        /* Warm dark brown */
    --nav-bg: rgba(28, 27, 25, 0.9);           /* Semi-transparent dark for navbar */
    --hover-bg: #3a3632;                       /* Warm hover state */

    /* === Text Colors === */
    --text-color: #c8c2b8;                     /* Warm off-white */
    --big-intro: #e8e2d8;                      /* Warm ivory for large headings */
    --heading-color: var(--big-intro);         /* Section headings */
    --subtitle-color: #a69d93;                 /* Warm muted for subheadings */
    --muted-text: #8a8078;                     /* Warm muted for tertiary text */
    --light-text: #f2efe8;                     /* Warm white */
    --date-color: var(--muted-text);           /* Dates in timeline */
    --list-text: var(--text-color);            /* List items */
    --cursor-color: var(--primary-color);      /* Blinking cursor */
    --error-color: #c45a3a;                    /* Warm red for errors */

    /* === Button Colors === */
    --button-bg: #e8e2d8;                      /* Ivory button */
    --button-text-color: #1c1b19;              /* Dark text on bright button */
    --button-hover-bg: #8b2500;                /* Vermillion hover */
    --button-hover-border: var(--button-hover-bg);
    --button-hover-text-color: #f2efe8;
    --button-active: #6d6355;                  /* Warm active state */

    /* === Border Colors === */
    --border-color: #3a3632;                   /* Subtle warm border */
    --input-border: #4a4540;                   /* Warm input border */

    /* === Accent Colors === */
    --primary-color: #e8e2d8;                  /* Warm ivory accent */
    --secondary-color: #a69d93;                /* Warm muted secondary */
    --accent-color: #8b2500;                   /* Vermillion for highlights */

    /* === Input Colors === */
    --input-bg: #2a2825;                       /* Warm dark input bg */

    /* === Effects & Shadows === */
    --shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    --theme-toggle-icon-color: var(--text-color);
    --theme-toggle-glow: rgba(232, 226, 216, 0.15);

    /* === Timeline Colors === */
    --timeline-title-color: var(--big-intro);
    --timeline-desc-color: var(--subtitle-color);
    --about-desc-color: var(--subtitle-color);
}


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

body {
    font-family: var(--font-primary);
    line-height: 1.6;
    color: var(--text-color);
    background: var(--bg-color);
    transition: background-color 0.3s, color 0.3s;
    font-weight: 400;
    font-size: 1rem;
    position: relative;
    z-index: 1;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    letter-spacing: -0.01em;
}

html {
    min-height: 100%;
}

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

/* Header & Navigation */
header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background-color: transparent;
    box-shadow: none;
    backdrop-filter: none;
    transition: transform 0.5s cubic-bezier(0.4,0,0.2,1), opacity 0.5s cubic-bezier(0.4,0,0.2,1);
}

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

.logo {
    flex: 0 0 auto;
    height: 35px;
    width: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.logo-text {
    color: var(--big-intro);
    font-family: 'DM Sans', 'Montserrat', Arial, sans-serif;
    font-weight: 500;
    font-size: 1.1rem;
    letter-spacing: -0.5px;
}

.logo img {
    height: 100%;
    width: auto;
    object-fit: contain;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 0.2rem;
    align-items: center;
    margin: 0;
    padding: 0;
}

.nav-dot {
    color: var(--secondary-color);
    opacity: 0.7;
    font-size: 1.1em;
    margin: 0 0.6rem;
    user-select: none;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    height: 1em;
}

.nav-links li:not(.nav-dot) {
    display: flex;
    align-items: center;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    font-size: 1rem;
    transition: color 0.2s ease-out;
    padding: 0.5rem 0;
}

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

.nav-links a.active {
    color: var(--primary-color);
    font-weight: 600;
}

.resume-btn {
    display: none;
}

/* Sections */
.section, .about-section, .contact-section {
    padding: 6rem 0;
    min-height: 100vh;
    display: flex;
    align-items: center;
    background: transparent !important;
}

#about {
    text-align: center;
}

.profile-image {
    margin: 0 auto;
    width: 200px;
    height: 200px;
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
}

.profile-image .profile-pic {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    object-fit: cover;
    position: relative;
    z-index: 2;
    display: block;
    margin: 0 auto;
    background: transparent;
    border: 2px solid var(--border-color);
    box-shadow: none;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    color: var(--text-color);
    font-weight: 500;
    letter-spacing: -0.02em;
}

h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

h2 {
    font-size: 1.75rem;
    margin-bottom: 2rem;
    color: var(--primary-color);
}

.subtitle {
    font-size: 1.5rem;
    color: var(--secondary-color);
    margin-bottom: 2rem;
}

/* Timeline */
.timeline {
    position: relative;
    max-width: 850px;
    margin: 0 auto;
    padding: 2rem 0 2rem 3rem;
}

/* Vertical line - thin and subtle */
.timeline::before {
    content: '';
    position: absolute;
    left: 15px;
    top: 0;
    bottom: 0;
    width: 1px;
    background: linear-gradient(to bottom,
        transparent 0%,
        var(--border-color) 10%,
        var(--border-color) 90%,
        transparent 100%);
    opacity: 0.5;
}

.timeline-item {
    margin-bottom: 2.5rem;
    position: relative;
}

/* Timeline dot - small, filled */
.timeline-item::before {
    content: '';
    position: absolute;
    left: -22px;
    top: 0.45rem;
    width: 7px;
    height: 7px;
    background-color: var(--primary-color);
    border: none;
    border-radius: 50%;
    transition: all 0.3s ease;
    z-index: 2;
    opacity: 0.7;
}

.timeline-item:hover::before {
    opacity: 1;
    transform: scale(1.4);
}

/* Hide the date wrapper - dates will be inline */
.timeline-date-wrapper {
    display: none;
}

/* Year markers - minimal */
.timeline-year {
    position: relative;
    margin-bottom: 1rem;
    margin-left: -6rem;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--muted-text);
    letter-spacing: 2px;
    opacity: 0.5;
    text-align: right;
    width: 4rem;
    padding-right: 1rem;
}

/* Subtle horizontal bar for years */
.timeline-year::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    width: 0.5rem;
    height: 1px;
    background-color: var(--muted-text);
    opacity: 0.3;
}

.timeline-content {
    flex: 1;
    background: none;
    padding: 0;
    border-radius: 0;
    color: var(--text-color);
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.35s ease-out, transform 0.35s ease-out;
    position: relative;
}

.timeline-item.visible .timeline-content {
    opacity: 1;
    transform: none;
}

.timeline-content:hover {
    box-shadow: none;
}

.timeline-content h3 {
    color: var(--timeline-title-color);
    font-size: 1.05rem;
    font-weight: 500;
    margin-bottom: 0.35rem;
    letter-spacing: -0.01em;
}

/* Date styling */
.timeline-content .date {
    display: inline-block;
    font-size: 0.78rem;
    color: var(--date-color);
    margin-bottom: 0.6rem;
    font-weight: 400;
    letter-spacing: 0.02em;
}

.timeline-content ul {
    margin-top: 0.25rem;
    list-style-type: none;
    padding-left: 0;
}

.timeline-content ul li {
    margin-bottom: 0.35rem;
    line-height: 1.6;
    font-size: 0.9rem;
    position: relative;
    padding-left: 1rem;
}

.timeline-content ul li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.7em;
    width: 3px;
    height: 3px;
    background: var(--muted-text);
    border-radius: 50%;
    opacity: 0.4;
}

.timeline-content ul li::marker {
    color: transparent;
}

.intro-description,
.timeline-content ul,
.timeline-content li {
    color: var(--timeline-desc-color);
    margin-bottom: 0.4em;
    font-weight: 300;
    text-align: left;
}

.timeline-content b,
.timeline-content strong {
    font-weight: 600;
    color: var(--primary-color);
}

/* Footer */
footer {
    background-color: var(--card-bg);
    padding: 2rem 0;
    text-align: center;
}

.social-links {
    margin-bottom: 1rem;
}

.social-links a {
    color: var(--text-color);
    font-size: 1.5rem;
    margin: 0 1rem;
    transition: color 0.2s ease-out, transform 0.2s ease-out;
}

.social-links a::after {
    display: none;
}

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

.company.highlight {
    font-weight: bold;
    font-size: 1.15em;
    color: var(--primary-color);
    letter-spacing: 0.5px;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    position: relative;
    transition: color 0.2s ease-out;
}

a:visited {
    color: var(--primary-color);
}

a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -2px;
    width: 0;
    height: 2px;
    background: currentColor;
    transition: width 0.2s ease-out;
}

a:hover::after, a:focus::after {
    width: 100%;
}

a:hover, a:focus {
    color: var(--primary-color);
}

.intro-section {
    position: relative;
}

.intro-container.left-intro {
    align-items: flex-start;
    justify-content: flex-start;
    width: 100%;
    max-width: 1100px;
    margin: 0 auto;
    position: relative;
    min-height: 100vh;
}

.intro-flex {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    margin-top: 15rem;
    animation: fadeSlideUp 0.8s ease-out;
}

.big-intro {
    color: var(--big-intro);
    font-size: 3.5rem;
    font-weight: 500;
    font-family: var(--font-heading);
    margin-bottom: 1.5rem;
    letter-spacing: -0.03em;
    line-height: 1.1;
    text-align: left;
}

.intro-main {
    color: var(--subtitle-color);
    font-size: 1.5rem;
    font-weight: 400;
    margin-left: 2px;
    margin-bottom: 2.5rem;
    letter-spacing: -0.01em;
    line-height: 1.4;
    white-space: nowrap;
    position: relative;
}

.intro-main::after {
    content: '|';
    color: var(--cursor-color);
    animation: blink-caret 1s step-end infinite;
    margin-left: 2px;
}

/* Keyframes for the blinking caret */
@keyframes blink-caret {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

@keyframes fadeSlideUp {
    0% { opacity: 0; transform: translateY(40px); }
    100% { opacity: 1; transform: none; }
}


@keyframes bounceDown {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(10px);
    }
}

.section-heading {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.2rem;
    width: 100%;
}

.section-heading h2 {
    color: var(--heading-color);
    font-size: 1.5rem !important;
    font-weight: 500;
    font-family: var(--font-heading);
    margin: 0;
    flex-shrink: 0;
    background: none;
    padding: 0;
    border-radius: 0;
    display: inline;
    align-items: center;
    height: 1.5em;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

.section-line {
    flex: 1;
    height: 1px;
    background: var(--border-color);
    opacity: 0.6;
    margin-left: 1.2rem;
    border-radius: 1px;
    align-self: center;
}

.contact-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    background: var(--button-bg);
    color: var(--button-text-color);
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    z-index: 1;
    padding: 0.8rem 2.2rem;
    font-size: 1.1rem;
    box-shadow: none;
    border: 1px solid transparent;
}

.contact-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, var(--button-hover-bg), var(--button-bg));
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: 0;
}

.contact-btn:hover::before, .contact-btn:focus::before {
    opacity: 0.9;
}

/* Alternative subtle fade animation - uncomment to use instead of ripple effect
.contact-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--button-hover-bg);
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: 0;
}

.contact-btn:hover::before, .contact-btn:focus::before {
    opacity: 1;
    width: auto;
    height: auto;
}
*/

.contact-btn span {
    position: relative;
    z-index: 1;
    display: inline-block;
    transition: color 0.3s ease;
}

.contact-btn::after {
    content: none;
}

.contact-btn i {
    position: relative;
    z-index: 1;
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1), color 0.3s ease, opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    transform-origin: center;
}

.contact-btn:hover span {
    color: var(--button-hover-text-color);
}

.contact-btn:hover i, .contact-btn:focus i {
    color: var(--button-hover-text-color);
    transform: translate(12px, -12px) scale(0.6);
    opacity: 0;
}

.contact-btn:active {
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(0,0,0,0.20);
    background: var(--button-active);
}

.about-section {
    background: var(--bg-color);
    padding: 6rem 0 4rem 0;
}

.about-container {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: center;
    gap: 3rem;
    max-width: 1100px;
    margin: 0 auto;
}

.about-text {
    flex: 2 1 350px;
    min-width: 300px;
    text-align: justify;
}

.about-text p {
    margin-bottom: 1.5em;
    color: var(--about-desc-color);
}

.about-image {
    flex: 1 1 220px;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    position: relative;
    z-index: 1;
    margin-top: 3rem
}

.contact-section {
    background: var(--bg-color);
    padding: 6rem 0 4rem 0;
    text-align: center;
}

.contact-card {
    margin: 0 auto;
    max-width: 420px;
    background: var(--card-bg);
    border-radius: 12px;
    box-shadow: none;
    border: 1px solid var(--border-color);
    padding: 2.5rem 2rem 2rem 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.contact-note {
    color: var(--subtitle-color);
    font-size: 1.08rem;
    margin-bottom: 2.2rem;
    font-style: italic;
}

.contact-form {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.input-group {
    position: relative;
    margin-bottom: -0.1rem;
}

.input-group input,
.input-group textarea {
    width: 100%;
    background: var(--input-bg);
    color: var(--text-color);
    border: 1.5px solid var(--input-border);
    border-radius: 8px;
    font-family: var(--font-primary);
    font-size: 1.02rem;
    padding: 0.6rem 0.9rem 0.5rem 0.9rem;
    margin-bottom: 0.08rem;
    box-shadow: none;
    transition: border-color 0.2s ease-out, background 0.2s ease-out;
}

.input-group input:focus,
.input-group textarea:focus {
    border-color: var(--primary-color);
    background: var(--hover-bg);
    outline: none;
}

.message-group textarea {
    min-height: 120px;
    resize: vertical;
}

.submit-btn {
    background: var(--primary-color);
    color: var(--button-text-color);
    border: none;
    border-radius: 8px;
    font-family: var(--font-primary);
    font-weight: 500;
    font-size: 1.1rem;
    cursor: pointer;
    transition: background 0.2s, color 0.2s, box-shadow 0.2s, transform 0.2s;
    box-shadow: none;
    padding: 1rem 2rem;
    height: 3.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.submit-btn i {
    color: var(--button-text-color);
}

.submit-btn:hover {
    background: var(--button-hover-bg);
    box-shadow: 0 6px 18px 0 rgba(0,0,0,0.18);
    transform: scale(1.01);
}

.submit-btn:hover span {
    color: var(--button-hover-text-color);
}

.submit-btn:hover i {
    color: var(--button-hover-text-color);
    transform: translate(12px, -12px) scale(0.6);
    opacity: 0;
}

.fade-in-section {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.4s ease-out, transform 0.4s ease-out;
    will-change: opacity, transform;
}

.fade-in-section.is-visible {
    opacity: 1;
    transform: none;
}

.company-link {
    color: var(--primary-color);
    font-weight: 250;
}

.contact-btn-icon {
    font-size: 0.9em;
}
.scroll-down-arrow {
    position: absolute;
    bottom: clamp(80px, 12vh, 160px);
    left: 50%;
    transform: translateX(-50%);
    font-size: clamp(1.5rem, 2.2vw, 2.2rem);
    color: var(--text-color);
    animation: bounceDown 2s ease-in-out infinite;
    cursor: pointer;
    opacity: 0.85;
    transition: opacity 0.3s, color 0.3s;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
    will-change: transform;
    backface-visibility: hidden;
    transform: translateZ(0);
}

.scroll-down-arrow:hover {
    opacity: 1;
    color: var(--accent-color);
}

@keyframes bounceDown {
    0%, 100% {
        transform: translateY(0) translateX(-50%);
    }
    50% {
        transform: translateY(16px) translateX(-50%);
    }
}

@keyframes fadeInScrollText {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 0.85; transform: translateY(0); }
}

.section-divider {
    width: 100vw;
    margin: 0;
    padding: 0;
    line-height: 0;
    position: relative;
    z-index: 2;
    background: transparent;
}

.section-divider svg {
    display: block;
    width: 100vw;
    height: 80px;
    color: var(--primary-color);
}

.error-message {
    color: var(--error-color);
    font-size: 0.89rem;
    margin-top: 0.08rem;
    margin-bottom: 0.08rem;
    min-height: 1em;
    text-align: left;
    padding-left: 0.2rem;
    letter-spacing: 0.01em;
    font-weight: 400;
    opacity: 0.92;
    line-height: 1.2;
    transition: opacity 0.2s;
}

input, textarea {
    background: var(--card-bg);
    color: var(--text-color);
    border: none;
    border-radius: 8px;
    font-family: var(--font-primary);
    font-size: 1.02rem;
    padding: 0.6rem 0.9rem 0.5rem 0.9rem;
}

input::placeholder, textarea::placeholder {
    color: var(--secondary-color);
    opacity: 1;
}

::-webkit-scrollbar {
    width: 8px;
    background: var(--bg-color);
}
::-webkit-scrollbar-thumb {
    background: var(--card-bg);
    border-radius: 8px;
}

.theme-toggle-btn {
    margin-left: 1.5rem;
    position: relative;
}

.theme-toggle-icon {
    background: none;
    border: none;
    color: var(--theme-toggle-icon);
    font-size: 1.6rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 50%;
    transition: transform 0.2s ease-out, color 0.2s ease-out, box-shadow 0.2s ease-out, background 0.2s ease-out;
    outline: none;
    position: relative;
    z-index: 1;
    will-change: transform;
    backface-visibility: hidden;
    transform: translateZ(0);
}

.theme-toggle-icon:hover {
    background: var(--theme-toggle-glow);
    box-shadow: 0 0 0 3px var(--theme-toggle-glow), 0 0 8px 2px var(--theme-toggle-glow);
    color: var(--theme-toggle-icon);
}

.theme-toggle-icon:focus {
    outline: none;
    box-shadow: none;
    background: none;
}

.theme-toggle-icon:focus-visible {
    outline: 2px solid var(--theme-toggle-glow);
    outline-offset: 2px;
}


/* Tooltip for theme name */
.theme-toggle-btn[title] {
    position: relative;
}
.theme-toggle-btn[title]:hover::after {
    content: attr(title);
    position: absolute;
    left: 50%;
    top: 120%;
    transform: translateX(-50%);
    background: var(--bg-color);
    color: var(--primary-color);
    padding: 0.35em 0.8em;
    border-radius: 6px;
    font-size: 0.95rem;
    white-space: nowrap;
    pointer-events: none;
    opacity: 1;
    z-index: 10;
    box-shadow: 0 2px 8px var(--shadow);
}
.theme-toggle-btn[title]::after {
    opacity: 0;
    transition: opacity 0.2s;
}


/* Contact Form Button Specific Styles */
.contact-form .submit-btn {
    background: var(--primary-color);
    color: var(--button-text-color);
    border: none;
    border-radius: 8px;
    font-family: var(--font-primary);
    font-weight: 500;
    font-size: 1.1rem;
    cursor: pointer;
    transition: background 0.2s, color 0.2s, box-shadow 0.2s, transform 0.2s;
    box-shadow: none;
    padding: 1rem 2rem;
    height: 3.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.contact-form .submit-btn:hover {
    background: var(--button-hover-bg);
    color: var(--button-text-color);
    box-shadow: 0 6px 18px 0 rgba(0,0,0,0.18);
    transform: scale(1.01);
}

/* Reset general button styles */
button {
    background: none;
    border: none;
    padding: 0;
    height: auto;
    display: inline-flex;
    align-items: center;
}

.contact-btn:hover, .contact-btn:focus {
    color: var(--button-hover-text-color);
    box-shadow: 0 4px 20px rgba(108, 92, 231, 0.25);
    transform: translateY(-2px);
    border-color: rgba(108, 92, 231, 0.3);
}

.about-paragraph {
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 0.35s ease-out, transform 0.35s ease-out;
    margin-bottom: 2.2rem;
}
.about-paragraph.visible {
    opacity: 1;
    transform: none;
}
.about-text .about-paragraph-title {
    display: flex;
    align-items: center;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--secondary-color);
    margin-bottom: 0.7rem;
    letter-spacing: 0.03em;
    font-family: var(--font-heading);
    position: relative;
    gap: 0.7rem;
    text-transform: uppercase;
}
.about-paragraph-title::before {
    content: '';
    display: inline-block;
    width: 1.2px;
    height: 1.1em;
    background: var(--secondary-color);
    border-radius: 2px;
    margin-right: 0.5rem;
    opacity: 0.4;
    flex-shrink: 0;
}

.intro-flex .contact-btn {
    opacity: 0;
    transform: translateY(32px);
    pointer-events: none;
    transition: opacity 0.7s cubic-bezier(0.4,0,0.2,1), transform 0.7s cubic-bezier(0.4,0,0.2,1);
}
.intro-flex .contact-btn.visible {
    opacity: 1;
    transform: none;
    pointer-events: auto;
}

.nav-links li:not(:last-child)::after { content: none; }

/* Footer nav styles */
.footer-nav {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.2rem;
    margin-bottom: 1.2rem;
    flex-wrap: wrap;
}
.footer-nav a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    font-size: 1.05rem;
    transition: color 0.2s ease-out;
    margin: 0 0.1rem;
}
.footer-nav a:hover {
    color: var(--primary-color);
}
.footer-divider {
    color: var(--secondary-color);
    opacity: 0.7;
    margin: 0 0.5rem;
    font-size: 1.2em;
    user-select: none;
}

/* Header hide/show transition */
.hide-header {
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
}

.company-link,
.timeline-content b,
.timeline-content strong {
    color: var(--emphasis-color);
}

/* Submit button icon transition */
.submit-btn i {
  transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.submit-btn i.submitted {
  color: #7ed6a7;
}

/* Filter Tabs */
.filter-tabs {
  display: flex;
  justify-content: center;
  gap: 0.6rem;
  margin-top: 1.5rem;
  margin-bottom: 0.5rem;
  flex-wrap: wrap;
}

.filter-tab {
  background: transparent;
  border: 1.5px solid var(--border-color);
  border-radius: 999px;
  padding: 0.4rem 1.2rem;
  font-family: var(--font-primary);
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-color);
  cursor: pointer;
  transition: background 0.2s ease-out, color 0.2s ease-out, border-color 0.2s ease-out;
  height: auto;
}

.filter-tab:hover {
  border-color: var(--primary-color);
  color: var(--primary-color);
}

.filter-tab.active {
  background: var(--primary-color);
  color: var(--button-text-color);
  border-color: var(--primary-color);
}

/* Project Grid */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.2rem;
  margin-top: 1.5rem;
}

/* Compact Project Cards */
.project-card {
  display: flex;
  flex-direction: column;
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 1.2rem 1.3rem;
  transition: transform 0.2s ease-out, border-color 0.2s ease-out, opacity 0.3s ease-out;
  position: relative;
  min-width: 0;
}

.project-card:hover {
  transform: translateY(-2px);
  border-color: var(--primary-color);
}

.project-card .card-year {
  font-size: 0.78rem;
  color: var(--muted-text);
  font-weight: 400;
  letter-spacing: 0.02em;
  margin-bottom: 0.25rem;
}

.project-card .card-title {
  font-size: 1rem;
  font-weight: 500;
  color: var(--timeline-title-color);
  margin-bottom: 0.3rem;
  line-height: 1.3;
}

.project-card .card-title a {
  color: inherit;
}

.project-card .card-title a::after {
  display: none;
}

.project-card .card-desc {
  color: var(--timeline-desc-color);
  font-size: 0.88rem;
  line-height: 1.5;
  margin-bottom: 0.6rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.project-card .card-tech {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: auto;
  margin-bottom: 0.5rem;
}

.project-card .card-tech span {
  font-size: 0.76rem;
  color: var(--muted-text);
  font-weight: 500;
  white-space: nowrap;
}

.project-card .card-links {
  display: flex;
  gap: 0.8rem;
  margin-top: 0.2rem;
}

.project-card .card-links a {
  color: var(--primary-color);
  font-size: 1.1rem;
  transition: transform 0.2s ease-out, color 0.2s ease-out;
}

.project-card .card-links a::after {
  display: none;
}

.project-card .card-links a:hover {
  color: var(--accent-color);
  transform: scale(1.15) translateY(-1px);
}

/* Filter hidden state */
.project-card.hidden {
  display: none;
}

/* Show More Button */
.show-more-btn {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin: 1.5rem auto 0;
  padding: 0.5rem 1.4rem;
  background: none;
  border: 1px solid var(--border-color);
  border-radius: 999px;
  color: var(--primary-color);
  font-family: var(--font-primary);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  letter-spacing: 0.02em;
  transition: border-color 0.2s ease-out, color 0.2s ease-out;
}

.show-more-btn:hover {
  border-color: var(--primary-color);
  color: var(--accent-color);
}

.show-more-btn.expanded .show-more-icon {
  transform: rotate(180deg);
}

.show-more-icon {
  transition: transform 0.25s ease-out;
}

/* Card fade transition */
.project-card {
  opacity: 0;
  transition: opacity 0.25s ease-out, transform 0.2s ease-out, border-color 0.2s ease-out;
}

.project-card.card-visible {
  opacity: 1;
}


/* Media Queries */
@media (max-width: 900px) {
    /* Navigation */
    .resume-btn {
        margin: 1rem 0 0 0;
        width: 100%;
        text-align: center;
    }

    /* Projects */
    .projects-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    /* Navigation */
    .nav-links {
        display: none;
    }

    /* Layout */
    .section {
        padding: 4rem 0;
    }

    /* Typography */
    h1 {
        font-size: 2.5rem;
    }
    h2 {
        font-size: 2rem;
    }
    .subtitle {
        font-size: 1.2rem;
    }
}

@media (max-width: 600px) {
    /* Contact */
    .contact-card {
        padding: 1.5rem;
    }

    /* Projects */
    .projects-grid {
        grid-template-columns: 1fr;
    }
    .project-card {
        padding: 1rem 1.1rem;
    }
}

/* Image Loading Optimizations */
img {
    content-visibility: auto;
    contain: size layout paint;
}

.profile-pic {
    content-visibility: auto;
    contain: size layout paint;
    will-change: transform;
}