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

:root {
    --sidebar-bg: #171717;
    --sidebar-hover: #2A2B32;
    --main-bg: #ffffff;
    --text-primary: #ececec;
    --text-secondary: #8e8ea0;
    --border-color: #4d4d4f;
    --black: #000000;
    --white: #ffffff;
    --gray: #666666;
    --light-gray: #f9f9f9;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Inter', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.7;
    color: var(--black);
    background-color: var(--main-bg);
    font-size: 16px;
    margin: 0;
    padding-left: 260px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    transition: padding-left 0.3s ease;
}

body.sidebar-collapsed {
    padding-left: 70px;
}

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

/* Sidebar Navigation */
.sidebar {
    position: fixed;
    top: 1.5rem;
    left: 0;
    height: calc(100vh - 3rem);
    width: 260px;
    background-color: var(--sidebar-bg);
    color: var(--text-primary);
    z-index: 1000;
    display: flex;
    flex-direction: column;
    padding: 0;
    overflow-y: auto;
    overflow-x: hidden;
    box-shadow: 2px 0 8px rgba(0, 0, 0, 0.1);
    border-radius: 0 12px 12px 0;
    transition: width 0.3s ease;
}

.sidebar::-webkit-scrollbar {
    width: 0px;
    background: transparent;
}

.sidebar.collapsed {
    width: 70px;
}

.sidebar.collapsed .nav-item span {
    display: none;
}

.sidebar.collapsed .logo {
    display: none;
}

.sidebar-header {
    padding: 1.25rem 1rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.sidebar-toggle {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    transition: background 0.2s ease, color 0.2s ease;
    font-size: 1.2rem;
}

.sidebar-toggle:hover {
    background: var(--sidebar-hover);
    color: var(--text-primary);
}

.logo {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-primary);
    letter-spacing: -0.5px;
}

.sidebar-nav {
    flex: 1;
    padding: 0.5rem 0.5rem;
}

.nav-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    padding: 0;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 0.75rem;
    color: var(--text-secondary);
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.15s ease;
    font-size: 0.875rem;
    font-weight: 500;
    letter-spacing: -0.01em;
}

.nav-item:hover {
    background-color: var(--sidebar-hover);
    color: var(--text-primary);
}

.nav-item.active {
    background-color: var(--sidebar-hover);
    color: var(--text-primary);
}

/* Sidebar Footer - Pro Mode */
.sidebar-footer {
    margin-top: auto;
    padding: 1.5rem 1rem;
    border-top: 1px solid var(--border-color);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s ease;
    transform-origin: bottom;
}

.sidebar.collapsed .sidebar-footer {
    opacity: 0;
    visibility: hidden;
    transform: scaleY(0);
    padding: 0;
    border: none;
}

.pro-mode-toggle {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    user-select: none;
}

.pro-mode-toggle input[type="checkbox"] {
    display: none;
}

.toggle-slider {
    position: relative;
    width: 42px;
    height: 24px;
    background: var(--border-color);
    border-radius: 12px;
    transition: background 0.3s ease;
}

.toggle-slider::before {
    content: '';
    position: absolute;
    width: 18px;
    height: 18px;
    background: var(--white);
    border-radius: 50%;
    top: 3px;
    left: 3px;
    transition: transform 0.3s ease;
}

.pro-mode-toggle input:checked + .toggle-slider {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    position: relative;
}

.pro-mode-toggle input:checked + .toggle-slider::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    height: 100%;
    border-radius: 12px;
    animation: colorBoom 0.8s ease-out;
    pointer-events: none;
}

.pro-mode-toggle input:checked + .toggle-slider::before {
    transform: translateX(18px);
}

@keyframes colorBoom {
    0% {
        width: 42px;
        height: 24px;
        opacity: 1;
        box-shadow: 
            0 0 0 0 rgba(255, 20, 147, 0.8),
            0 0 0 0 rgba(0, 255, 255, 0.8),
            0 0 0 0 rgba(255, 255, 0, 0.8),
            0 0 0 0 rgba(138, 43, 226, 0.8);
    }
    50% {
        box-shadow: 
            0 0 20px 10px rgba(255, 20, 147, 0.6),
            0 0 20px 15px rgba(0, 255, 255, 0.6),
            0 0 20px 12px rgba(255, 255, 0, 0.6),
            0 0 20px 18px rgba(138, 43, 226, 0.6);
    }
    100% {
        width: 100px;
        height: 80px;
        opacity: 0;
        box-shadow: 
            0 0 40px 20px rgba(255, 20, 147, 0),
            0 0 40px 25px rgba(0, 255, 255, 0),
            0 0 40px 22px rgba(255, 255, 0, 0),
            0 0 40px 28px rgba(138, 43, 226, 0);
    }
}

.toggle-label {
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
}

.pro-mode-toggle:hover .toggle-label {
    color: var(--text-primary);
}

/* Liquid Effect */
#liquidEffect {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 10;
    opacity: 0;
    transition: opacity 0.5s ease;
    overflow: hidden;
    contain: layout style paint;
    will-change: contents;
}

body.pro-mode #liquidEffect {
    opacity: 1;
}

main {
    position: relative;
    z-index: 1;
    background: transparent;
}

section,
.hero-content,
.experience-card,
.education-card,
.project-card,
.about-content,
.footer-content {
    position: relative;
    z-index: 100;
}

.liquid-blob {
    position: absolute;
    filter: blur(45px);
    pointer-events: none;
    will-change: transform;
    backface-visibility: hidden;
    transform-style: preserve-3d;
    contain: layout style paint;
}

.nav-icon {
    width: 18px;
    height: 18px;
    min-width: 18px;
    stroke-width: 2;
    opacity: 0.9;
}

/* Hero Section */
#hero {
    padding: 80px 0 60px;
    background: var(--main-bg);
    color: var(--black);
}

.hero-content {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    align-items: center;
    gap: 4rem;
}

.hero-text {
    flex: 1;
}

.hero-image {
    flex-shrink: 0;
}

.hero-image img {
    width: 380px;
    height: auto;
    object-fit: contain;
    border-radius: 16px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    line-height: 1.1;
    letter-spacing: -0.03em;
}

.highlight {
    font-weight: 700;
    background: linear-gradient(135deg, #000 0%, #333 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.5rem;
    font-weight: 400;
    margin-bottom: 1.5rem;
    color: var(--gray);
    letter-spacing: -0.01em;
}

.hero-description {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--gray);
    font-weight: 400;
}

/* Sections */
.section {
    padding: 80px 2rem;
    max-width: 900px;
    margin: 0 auto;
}

.bg-light {
    background-color: var(--light-gray);
    border-radius: 0;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 3rem;
    color: var(--black);
    letter-spacing: -0.02em;
}

/* About Section */
.about-content {
    font-size: 1.05rem;
    line-height: 1.8;
    color: var(--gray);
}

.about-content p {
    margin-bottom: 1.5rem;
}

.about-content strong {
    color: var(--black);
    font-weight: 600;
}

.highlight-text-marker {
    background: linear-gradient(90deg, #ffeb3b 0%, #ffeb3b 0%);
    background-position: 0 70%;
    background-size: 0% 50%;
    background-repeat: no-repeat;
    padding: 0 0.2rem;
    position: relative;
    display: inline-block;
}

.highlight-text-marker.animate {
    animation: highlight-text 2s ease-out 0.5s forwards;
}

.highlight-text-marker.animate::before {
    animation: pen-move 2s ease-out 0.5s forwards;
}

.highlight-text-marker::before {
    content: '';
    position: absolute;
    left: -80px;
    top: -60%;
    transform: translateY(-50%) rotate(-15deg);
    width: 80px;
    height: 80px;
    background-image: url('highlighter-pen-yellow-color-3d-illustration-icon-png.png');
    background-size: contain;
    background-repeat: no-repeat;
    opacity: 0;
    pointer-events: none;
    z-index: 10;
}

@keyframes highlight-text {
    0% {
        background-size: 0% 50%;
    }
    100% {
        background-size: 100% 50%;
    }
}

@keyframes pen-move {
    0% {
        left: -30px;
        opacity: 1;
    }
    95% {
        opacity: 1;
    }
    100% {
        left: calc(100% - 20px);
        opacity: 0;
    }
}

/* Education Section */
.education-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

.education-card {
    background: var(--white);
    padding: 2rem;
    border-radius: 8px;
    border: none;
}

.education-card:last-child {
    border-bottom: none;
}

.card-icon {
    display: none;
}

.education-card h3 {
    font-size: 1.2rem;
    color: var(--black);
    margin-bottom: 0.5rem;
    font-weight: 600;
    letter-spacing: -0.01em;
}

.institution {
    font-weight: 400;
    color: var(--gray);
    margin-bottom: 0.8rem;
    font-size: 0.95rem;
}

.description {
    color: var(--gray);
    font-size: 0.95rem;
    line-height: 1.7;
}

.tse-ranking {
    margin-bottom: 2.5rem;
    padding: 1rem 1.5rem;
    background: #e7f3ff;
    border-radius: 6px;
    border-left: 3px solid #3b82f6;
    display: flex;
    align-items: flex-start;
    gap: 0.8rem;
}

.ranking-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    background: #3b82f6;
    color: white;
    font-size: 0.75rem;
    font-weight: 700;
    font-style: italic;
    border-radius: 3px;
    flex-shrink: 0;
    margin-top: 0.1rem;
}

.tse-ranking > div {
    flex: 1;
}

.tse-ranking p {
    color: var(--gray);
    font-size: 0.9rem;
    margin: 0 0 0.3rem 0;
    line-height: 1.6;
}

.tse-ranking p:last-child {
    margin-bottom: 0;
}

.tse-ranking strong {
    color: var(--black);
    font-weight: 600;
}

.tse-photo-container {
    margin: 2rem 0;
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.tse-photo {
    width: 300px;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    flex-shrink: 0;
}

.tse-caption {
    color: var(--gray);
    font-size: 0.9rem;
    font-style: italic;
    line-height: 1.6;
    flex: 1;
    margin: 0;
}

/* Experience Section */
.experience-header-wrapper {
    margin-bottom: 3rem;
}

.experience-header-wrapper .section-title {
    margin-bottom: 1.5rem;
}

.experience-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.experience-filters {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.filter-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1rem;
    background: var(--white);
    border: 2px solid #e5e5e5;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 500;
    color: var(--gray);
    font-size: 0.9rem;
}

.filter-btn:hover {
    border-color: var(--black);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.filter-btn.active {
    background: var(--black);
    color: var(--white);
    border-color: var(--black);
}

.filter-color {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    display: inline-block;
}

.timeline-toggle {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    background: var(--white);
    border: 2px solid #e5e5e5;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-weight: 500;
    color: var(--gray);
    font-size: 0.9rem;
    position: relative;
    overflow: hidden;
}

.timeline-toggle::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.05);
    transform: translate(-50%, -50%);
    transition: width 0.4s ease, height 0.4s ease;
}

.timeline-toggle:hover::before {
    width: 300px;
    height: 300px;
}

.timeline-toggle:hover {
    border-color: var(--black);
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
}

.timeline-toggle:active {
    transform: translateY(-1px) scale(0.98);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.timeline-icon {
    width: 20px;
    height: 20px;
    transition: transform 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    position: relative;
    z-index: 1;
}

.timeline-toggle:hover .timeline-icon {
    transform: scale(1.2);
}

.timeline-toggle.reversed .timeline-icon {
    transform: rotate(180deg);
    animation: bounceRotate 0.6s ease-out;
}

@keyframes bounceRotate {
    0% {
        transform: rotate(0deg) scale(1);
    }
    50% {
        transform: rotate(200deg) scale(1.3);
    }
    100% {
        transform: rotate(180deg) scale(1);
    }
}

.timeline-order-text {
    position: relative;
    z-index: 1;
    transition: all 0.3s ease;
}

.timeline-toggle:hover .timeline-order-text {
    transform: translateX(2px);
}

.timeline-container {
    position: relative;
    padding-left: 2rem;
    --gradient-direction: 180deg;
}

.timeline-container::before {
    content: '';
    position: absolute;
    left: 0.5rem;
    top: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(var(--gradient-direction), var(--black) 0%, #e5e5e5 100%);
    border-radius: 2px;
    transition: background 0.6s ease;
}

.timeline-item {
    position: relative;
    margin-bottom: 3rem;
    animation: fadeIn 0.6s ease-out;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.timeline-item.hidden {
    display: none;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.timeline-marker {
    position: absolute;
    left: -2.05rem;
    top: 0.5rem;
    width: 1.25rem;
    height: 1.25rem;
    background: var(--white);
    border: 3px solid var(--black);
    border-radius: 50%;
    z-index: 2;
    box-shadow: 0 0 0 4px var(--white);
    transition: all 0.3s ease;
}

.timeline-item:hover .timeline-marker {
    transform: scale(1.3);
    border-width: 4px;
    box-shadow: 0 0 0 6px rgba(0, 0, 0, 0.05);
}

.timeline-date {
    position: absolute;
    right: calc(100% + 2.5rem);
    top: 0.3rem;
    font-weight: 600;
    color: var(--black);
    font-size: 0.9rem;
    white-space: nowrap;
    opacity: 0.8;
    text-align: right;
    width: 9rem;
}

.experience-card {
    display: flex;
    gap: 1.5rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid #e5e5e5;
}

.experience-card:last-child {
    border-bottom: none;
}

.experience-icon {
    width: 52px;
    height: 52px;
    min-width: 52px;
    background: var(--sidebar-bg);
    color: var(--text-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.3rem;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.experience-icon:not(.experience-icon-img) {
    background: transparent;
    box-shadow: none;
    font-size: 2.5rem;
}

.experience-icon-img {
    background: var(--white);
    padding: 6px;
}

.experience-icon-img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.experience-content {
    flex: 1;
}

.experience-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
    gap: 3rem;
}

.experience-header h3 {
    font-size: 1.15rem;
    color: var(--black);
    margin-bottom: 0.3rem;
    font-weight: 600;
    letter-spacing: -0.01em;
}

.company {
    font-weight: 400;
    color: var(--gray);
    font-size: 0.9rem;
}

.experience-date {
    font-size: 0.85rem;
    color: var(--gray);
    white-space: nowrap;
}

.experience-badge {
    padding: 0.4rem 0.9rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    white-space: nowrap;
    letter-spacing: 0.02em;
}

.experience-content .description {
    color: var(--gray);
    line-height: 1.8;
    font-size: 0.95rem;
}

.experience-content .description strong {
    color: var(--black);
    font-weight: 500;
}

.experience-content .description em {
    font-style: italic;
    color: var(--gray);
}

.experience-image {
    margin: 1.5rem 0;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.experience-image img {
    width: 300px;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    flex-shrink: 0;
}

.dga-secret-image {
    width: 300px !important;
    height: 300px !important;
    opacity: 0.3;
    background: #e5e5e5;
    padding: 2rem;
    border-radius: 8px;
    object-fit: contain;
}

.image-caption {
    font-size: 0.8rem;
    color: var(--gray);
    font-style: italic;
    line-height: 1.5;
    flex: 1;
}

/* Projects Section */
.projects-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0;
}

.project-card {
    background: var(--main-bg);
    padding: 0 0 2.5rem 0;
    border-bottom: 1px solid #e5e5e5;
    margin-bottom: 2.5rem;
}

.project-card:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.project-icon {
    display: none;
}

.project-card h3 {
    font-size: 1.2rem;
    color: var(--black);
    margin-bottom: 0.5rem;
    font-weight: 600;
    letter-spacing: -0.01em;
}

.project-company {
    font-size: 0.85rem;
    color: var(--gray);
    font-weight: 400;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.project-description {
    color: var(--gray);
    line-height: 1.7;
    margin-bottom: 1.2rem;
    font-size: 0.95rem;
}

.project-description strong {
    color: var(--black);
    font-weight: 500;
}

.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
}

.tag {
    display: inline-block;
    background: var(--light-gray);
    color: var(--gray);
    padding: 0;
    font-size: 0.85rem;
    font-weight: 500;
    border: 1px solid #e5e5e5;
    padding: 0.4rem 0.9rem;
    border-radius: 12px;
    letter-spacing: -0.01em;
    transition: all 0.2s ease;
}

.tag:hover {
    background: var(--sidebar-bg);
    color: var(--text-primary);
    border-color: var(--sidebar-bg);
}

/* Skills Section */
.skills-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
}

.skill-category {
    background: var(--main-bg);
    padding: 0;
}

.skill-category h3 {
    font-size: 1.1rem;
    color: var(--black);
    margin-bottom: 1.2rem;
    font-weight: 600;
    letter-spacing: -0.01em;
}

.skill-category ul {
    list-style: none;
}

.skill-category li {
    padding: 0.5rem 0;
    color: var(--gray);
    font-weight: 400;
    position: relative;
    padding-left: 1.2rem;
    font-size: 0.95rem;
}

.skill-category li::before {
    content: '—';
    position: absolute;
    left: 0;
    color: var(--gray);
    font-weight: 400;
}

.more-projects {
    text-align: center;
    margin-top: 3rem;
    padding: 2rem;
    background: var(--white);
    border-radius: 8px;
}

.more-projects p {
    color: var(--gray);
    font-size: 1rem;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.contact-btn {
    display: inline-block;
    padding: 0.75rem 2rem;
    background: var(--black);
    color: var(--white);
    text-decoration: none;
    border-radius: 6px;
    font-size: 0.95rem;
    font-weight: 500;
    transition: background 0.2s ease, transform 0.2s ease;
}

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

/* Footer */
footer {
    background: var(--black);
    color: var(--white);
    padding: 3rem 2rem 1.5rem;
    margin-top: 4rem;
    margin-left: -260px;
    padding-left: calc(260px + 2rem);
    border-radius: 0 12px 12px 0;
    transition: margin-left 0.3s ease, padding-left 0.3s ease;
}

body.sidebar-collapsed footer {
    margin-left: -70px;
    padding-left: calc(70px + 2rem);
}

.footer-content {
    max-width: 900px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding-bottom: 2rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-left h3 {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 0.3rem;
    color: var(--white);
}

.footer-left p {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
    margin: 0;
}

.footer-right {
    display: flex;
    gap: 2rem;
}

.footer-right a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.footer-right a:hover {
    color: var(--white);
}

.footer-icon {
    width: 20px;
    height: 20px;
}

.footer-bottom {
    max-width: 900px;
    margin: 0 auto;
    padding-top: 1.5rem;
    text-align: center;
}

.footer-bottom p {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.8rem;
    margin: 0;
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Design */
@media (max-width: 1166px) {
    body {
        padding-left: 0;
    }

    body.sidebar-collapsed {
        padding-left: 0;
    }

    .sidebar {
        display: none;
    }
    
    .sidebar-footer {
        display: none;
    }
    
    #liquidEffect {
        display: none !important;
    }
    
    /* Timeline dates visible on iPad */
    .timeline-date {
        position: static;
        margin-bottom: 0.5rem;
        font-size: 0.85rem;
        font-weight: 600;
    }
    
    .timeline-container {
        padding-left: 2rem;
    }
    
    .timeline-marker {
        left: -1.75rem;
    }
}

@media (max-width: 768px) {
    .hero-content {
        flex-direction: column-reverse;
        gap: 2rem;
        padding: 0 1.5rem;
    }

    .hero-image img {
        width: 280px;
        height: auto;
    }

    .hero-title {
        font-size: 2.2rem;
    }

    .hero-subtitle {
        font-size: 1.2rem;
    }

    .section-title {
        font-size: 1.6rem;
    }

    .section {
        padding: 60px 1.5rem;
    }

    .experience-card {
        flex-direction: column;
        gap: 1rem;
    }
    
    .experience-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .experience-badge {
        margin-top: 0.5rem;
        font-size: 0.75rem;
        padding: 0.35rem 0.8rem;
    }
    
    .timeline-container {
        padding-left: 2rem;
    }
    
    .timeline-container::before {
        left: 0.5rem;
    }
    
    .timeline-marker {
        left: -1.875rem;
    }
    
    .timeline-date {
        position: static;
        margin-bottom: 0.5rem;
        font-size: 0.85rem;
    }
    
    .experience-controls {
        flex-direction: column;
        align-items: stretch;
        gap: 1rem;
    }
    
    .experience-filters {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
        width: 100%;
    }
    
    .filter-btn {
        font-size: 0.85rem;
        padding: 0.6rem 0.75rem;
        justify-content: center;
    }
    
    .timeline-toggle {
        width: 100%;
        justify-content: center;
        padding: 0.75rem 1rem;
    }

    .experience-image {
        flex-direction: column;
        align-items: flex-start;
    }

    .experience-image img,
    .dga-secret-image {
        width: 100% !important;
        max-width: 280px;
    }

    .tse-photo-container {
        flex-direction: column;
        align-items: flex-start;
    }

    .tse-photo {
        width: 100%;
        max-width: 280px;
    }

    /* Fix SafeMask banner and video width on mobile */
    .project-card img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
    }

    .project-card iframe {
        width: 100% !important;
        aspect-ratio: 16/9 !important;
        max-width: 100% !important;
        display: block !important;
        margin: 1rem 0 !important;
        height: auto !important;
        left: 0 !important;
        right: 0 !important;
        position: relative !important;
    }

    .project-description {
        overflow-x: hidden;
        width: 100%;
    }

    .project-description div[style*="text-align: center"] {
        padding: 0 !important;
        margin: 1rem 0 !important;
        width: 100% !important;
        text-align: left !important;
        overflow: hidden !important;
    }

    /* Disable highlighter on "Reduce data leak risk" text on mobile */
    .project-description .highlight-text-marker {
        background: none !important;
        padding: 0 !important;
    }

    .project-description .highlight-text-marker::before {
        display: none !important;
    }

    .project-description .highlight-text-marker.animate {
        animation: none !important;
    }

    footer {
        margin-left: 0;
        padding-left: 2rem;
        border-radius: 0;
    }

    body.sidebar-collapsed footer {
        margin-left: 0;
        padding-left: 2rem;
    }

    .footer-right {
        gap: 1.5rem;
    }

    .footer-right a {
        font-size: 0.85rem;
    }
}

@media (max-width: 480px) {
    .hero-image img {
        width: 220px;
        height: auto;
    }

    .hero-title {
        font-size: 1.8rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .nav-links {
        font-size: 0.85rem;
        gap: 1rem;
    }

    .section {
        padding: 50px 1.2rem;
    }

    .logo {
        font-size: 1rem;
    }

    .experience-image img,
    .dga-secret-image {
        max-width: 100%;
    }

    .tse-photo {
        max-width: 100%;
    }

    .tse-ranking {
        padding: 0.75rem 1rem;
    }

    .ranking-icon {
        font-size: 1rem;
    }

    .footer-content {
        flex-direction: column;
        gap: 1.5rem;
    }

    .footer-left,
    .footer-right {
        width: 100%;
    }

    .footer-right {
        flex-direction: column;
        align-items: flex-start;
    }

    .contact-btn {
        width: 100%;
        text-align: center;
    }

    .education-card,
    .project-card {
        padding: 1.5rem;
    }
}

/* Mobile Menu Styles */
.mobile-menu-btn {
    display: none;
    position: fixed;
    top: 1.5rem;
    right: 1.5rem;
    z-index: 100;
    width: 50px;
    height: 50px;
    background: var(--black);
    border: none;
    border-radius: 12px;
    cursor: pointer;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
    pointer-events: auto;
}

.mobile-menu-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.mobile-menu-btn span {
    width: 24px;
    height: 2.5px;
    background: var(--white);
    border-radius: 2px;
    transition: all 0.3s ease;
}

.mobile-menu-btn.active {
    display: none;
}

.mobile-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    visibility: hidden;
}

.mobile-menu-overlay.active {
    opacity: 1;
    pointer-events: auto;
    visibility: visible;
}

.mobile-menu {
    display: none;
    position: fixed;
    top: 0;
    left: -100%;
    width: 280px;
    height: 100%;
    background: var(--sidebar-bg);
    z-index: 1000;
    transition: left 0.3s ease;
    overflow-y: auto;
    box-shadow: 4px 0 12px rgba(0, 0, 0, 0.1);
    pointer-events: none;
    visibility: hidden;
}

.mobile-menu.active {
    left: 0;
    pointer-events: auto;
    visibility: visible;
}

.mobile-menu-close {
    position: fixed;
    top: 1.5rem;
    right: 1.5rem;
    width: 50px;
    height: 50px;
    background: var(--black);
    border: none;
    border-radius: 10px;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 1002;
    pointer-events: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    visibility: hidden;
}

.mobile-menu.active .mobile-menu-close {
    display: flex;
    pointer-events: auto;
    visibility: visible;
}

.mobile-menu-close svg {
    width: 24px;
    height: 24px;
    stroke: var(--white);
}

.mobile-menu-close:hover {
    transform: rotate(90deg) scale(1.05);
    background: #333;
}

.mobile-menu-close:active {
    transform: scale(0.95);
}

.mobile-nav-list {
    list-style: none;
    padding: 5rem 2rem 2rem;
    margin: 0;
}

.mobile-nav-list li {
    margin-bottom: 0.5rem;
}

.mobile-nav-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    color: var(--text-primary);
    text-decoration: none;
    border-radius: 12px;
    transition: all 0.2s ease;
    font-weight: 500;
    font-size: 1rem;
}

.mobile-nav-item:hover {
    background: rgba(0, 0, 0, 0.05);
}

.mobile-nav-item.active {
    background: var(--black);
    color: var(--white);
}

.mobile-nav-item .nav-icon {
    width: 22px;
    height: 22px;
    stroke-width: 2;
}

/* Show mobile menu only on mobile/tablet */
@media (max-width: 1166px) {
    .mobile-menu-btn {
        display: flex;
    }
    
    .mobile-menu-overlay {
        display: block;
    }
    
    .mobile-menu {
        display: block;
    }
    
    /* Ensure content is not blocked by hidden mobile menu elements */
    body {
        position: relative;
    }
}















