/* ===========================
   BASE STYLES
   =========================== */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    background-color: #ffffff;
    color: #222222;
    line-height: 1.6;
    padding: 2rem;
}

body.dark-mode {
    background-color: #121212;
    color: #f0f0f0;
}

body.dark-mode h1,
body.dark-mode h2 {
    color: #59a3ec;
}

/* ===========================
   HEADER + NAV
   =========================== */

body.dark-mode h1,
body.dark-mode h2,
body.dark-mode h3 {
    color: #d3e9ff;
}

header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;

    /* Liquid glass effect */
    background: rgba(255, 255, 255, 0.3); /* translucent background */
    backdrop-filter: blur(10px);          /* blur content behind */
    -webkit-backdrop-filter: blur(10px);  /* Safari support */
    border-bottom: 1px solid rgba(255,255,255,0.2); /* optional soft border */
    box-shadow: 0 2px 6px rgba(0,0,0,0.1); 
    box-sizing: border-box;
}

body.dark-mode header {
    background: rgba(0, 0, 0, 0.5); /* translucent background */
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.logo .name {
    font-size: 150%;
}

.profile-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
}

/* Mobile menu button - hidden by default */
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    z-index: 1001;
}

.mobile-menu-btn span {
    width: 25px;
    height: 3px;
    background-color: #333;
    margin: 3px 0;
    transition: 0.3s;
    border-radius: 2px;
}

body.dark-mode .mobile-menu-btn span {
    background-color: #f0f0f0;
}

/* Mobile menu animation */
.mobile-menu-btn.active span:nth-child(1) {
    transform: rotate(-45deg) translate(-5px, 6px);
}

.mobile-menu-btn.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-btn.active span:nth-child(3) {
    transform: rotate(45deg) translate(-5px, -6px);
}

header nav {
    display: flex;
    background-color: #eeeeee;
    padding: 10px;
    border-radius: 6px; 
    box-shadow: inset 0 -1px 5px rgba(122, 122, 122, 0.1);
}

body.dark-mode header nav {
    background-color: #2c2c2c;
}

.navbar ul {
    list-style: none;
    display: flex;
    gap: 1.5rem;
    margin: 0;
    padding: 0;
}

header nav a {
    text-decoration: none;
    color: #111;
    font-weight: 500;
    padding: 10px 15px;
}

body.dark-mode header nav a {
    color: #ffffff;
}

header nav #contactnav {
    background: #0073e6;
    color: #fff;
    font-weight: 500;
    border-radius: 6px;
    transition: 0.3s;
}

header nav #contactnav:hover {
    background-color: #004aad;
}

.navbar a:hover {
    color: #0073e6;
}

/* ===========================
   DARK MODE TOGGLE
   =========================== */
.dark-mode-toggle {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.sun-dark,
.moon-dark {
    display: none;
}

.sun-light,
.moon-light {
    display: inline-block;
    color: #666;
}

body.dark-mode .sun-light,
body.dark-mode .moon-light {
    display: none;
}

body.dark-mode .sun-dark,
body.dark-mode .moon-dark {
    display: inline-block;
    color: #f0f0f0;
}

.mode-icon {
    width: 24px;
    height: 24px;
    object-fit: contain;
    margin: 0;
}

/* Toggle switch */
.theme-switch {
    position: relative;
    display: inline-block;
    width: 40px;
    height: 20px;
}

.theme-switch input {
    display: none;
}

.slider {
    position: absolute;
    cursor: pointer;
    inset: 0;
    background: #ccc;
    border-radius: 20px;
    transition: 0.4s;
}

.slider:before {
    content: "";
    position: absolute;
    height: 14px;
    width: 14px;
    left: 3px;
    bottom: 3px;
    background: white;
    border-radius: 50%;
    transition: 0.4s;
}

input:checked + .slider {
    background: #0073e6;
}

input:checked + .slider:before {
    transform: translateX(20px);
}

/* ===========================
   HERO / HEADER IMAGE
   =========================== */
.hero-photo {
    width: 100%;
    height: 60vh;
    object-fit: cover;
    display: block;
    border-radius: 0;
    margin: 0;
}

/* ===========================
   SECTIONS
   =========================== */
section {
    padding: 4rem 2rem;
    max-width: 1000px;
    margin: 0 auto;
}

section h2 {
    color: #004aad;
    margin-top: 1.5rem;
    margin-bottom: 1rem;
}

.skills-section {
    padding: 2rem 0;
}

.skills-section h2 {
    margin-bottom: 1rem;
}

.skills-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem 0.75rem; /* vertical gap, horizontal gap */
    line-height: 1.8; /* Add space between wrapped rows */
}




.skill-btn {
    background-color: #eee;
    color: #222;
    padding: 0.25rem .75rem;
    border-radius: 25px;
    cursor: default;
    font-size: 0.9rem;
    transition: background-color 0.3s, color 0.3s;
    white-space: nowrap; /* Prevent text from wrapping within button */
}

.skills,
.software {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 0.5rem; /* horizontal gap | vertical gap */
}

.skill-btn:hover {
    background-color: #222;
    color: #fff;
}

/* =======
   Skills & Software Dark Mode
   ======= */
body.dark-mode .skills-section {
    background-color: #1a1a1a; /* darker background for the section */
    color: #f0f0f0; /* lighter text for headings */
}

body.dark-mode .skills-section h2 {
    color: #59a3ec; /* match your headings in dark mode */
}

body.dark-mode .skill-btn {
    background-color: #2c2c2c; /* dark button background */
    color: #f0f0f0; /* light text */
}

body.dark-mode .skill-btn:hover {
    background-color: #59a3ec; /* hover effect */
    color: #1a1a1a; /* contrast text on hover */
}

/* ===========================
   TIMELINE
   =========================== */
.timeline-section {
    max-width: 100%;
    margin: 0 auto;
}

.timeline-section h2 {
    color: #004aad;
    margin-bottom: 2rem;
    text-align: center;
}

.timeline-container {
    position: relative;
    background: #f9f9f9;
    border-radius: 12px;
    padding: 2rem;
    overflow-x: auto;
    overflow-y: visible;
    min-height: 400px;
}

.timeline-wrapper {
    position: relative;
    width: 2800px; /* 6 years * 400px per year */
    height: 320px;
    margin: 2rem 0;
}

/* Year markers */
.year-markers {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 30px;
    display: flex;
}

.year-marker {
    width: 400px;
    text-align: center;
    font-weight: bold;
    color: #004aad;
    border-right: 2px solid #ddd;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.9);
}

.year-marker:last-child {
    border-right: none;
}

/* Timeline tracks */
.timeline-tracks {
    position: absolute;
    top: 50px;
    left: 0;
    width: 100%;
    height: 250px;
}

.track {
    position: relative;
    height: 120px;
    border-bottom: 2px solid #77777736;
    margin-bottom: 10px;
}

.track:last-child {
    border-bottom: none;
}

.track-label {
    position: absolute;
    left: -80px;
    top: 50%;
    transform: translateY(-50%);
    font-weight: bold;
    color: #004aad;
    writing-mode: vertical-rl;
    text-orientation: mixed;
}

/* Timeline items */
.timeline-item {
    position: absolute;
    height: 50px;
    background: linear-gradient(135deg, #0073e6, #004aad);
    color: white;
    border-radius: 8px;
    padding: 8px 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: flex-start;
    font-size: 12px;
    line-height: 1.2;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    overflow: hidden;
    
}

/* Full height items get larger text */
.timeline-item[style*="height: 100px"],
.timeline-item[style*="height: 90px"],
.timeline-item[style*="height: 80px"],
.timeline-item[style*="height: 70px"] {
    font-size: 14px;
    padding: 12px 16px;
}

.timeline-item[style*="height: 100px"] h4,
.timeline-item[style*="height: 90px"] h4,
.timeline-item[style*="height: 80px"] h4,
.timeline-item[style*="height: 70px"] h4 {
    font-size: 14px;
    margin-bottom: 4px;
}

.timeline-item[style*="height: 100px"] p,
.timeline-item[style*="height: 90px"] p,
.timeline-item[style*="height: 80px"] p,
.timeline-item[style*="height: 70px"] p {
    font-size: 12px;
}

.timeline-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    z-index: 10;
}

.timeline-item.education {
    background: linear-gradient(135deg, #28a745, #198754);
}

.timeline-item.experience {
    background: linear-gradient(135deg, #0073e6, #004aad);
}

.timeline-item h4 {
    font-size: 11px;
    font-weight: bold;
    margin-bottom: 2px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.timeline-item p {
    font-size: 10px;
    opacity: 0.9;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Modal styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.modal-content {
    background-color: #ffffff;
    margin: 10% auto;
    padding: 2rem;
    border-radius: 12px;
    width: 90%;
    max-width: 500px;
    position: relative;
    animation: modalSlideIn 0.3s ease;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.close {
    position: absolute;
    right: 1rem;
    top: 1rem;
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
    color: #666;
    transition: color 0.3s ease;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
}

.close:hover,
.close:focus {
    color: #000;
    background-color: rgba(0, 0, 0, 0.1);
}

.modal h3 {
    color: #004aad;
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.modal-detail {
    margin-bottom: 0.75rem;
    line-height: 1.6;
}

.modal-detail strong {
    color: #333;
    display: inline-block;
    min-width: 80px;
}

/* Modal Dark Mode Styles */
body.dark-mode .modal {
    background-color: rgba(0, 0, 0, 0.7);
}

body.dark-mode .modal-content {
    background-color: #1e1e1e;
    color: #f0f0f0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
    border: 1px solid #333;
}

body.dark-mode .close {
    color: #ccc;
}

body.dark-mode .close:hover,
body.dark-mode .close:focus {
    color: #fff;
    background-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .modal h3 {
    color: #59a3ec;
}

body.dark-mode .modal-detail {
    color: #f0f0f0;
}

body.dark-mode .modal-detail strong {
    color: #59a3ec;
}

/* ======
  Timeline Darkmode
  =======*/

body.dark-mode .timeline-container{
    background-color: #222;
}

body.dark-mode .year-marker{
    background-color: #333;
    color: #fff;
}

body.dark-mode ::-webkit-scrollbar {
    height: 10px; /* scrollbar thickness */
}

body.dark-mode ::-webkit-scrollbar-track {
    background: #1c1c1c; /* track background */
}

body.dark-mode ::-webkit-scrollbar-thumb {
    background: #555;       /* slider handle */
    border-radius: 6px;
}

body.dark-mode ::-webkit-scrollbar-thumb:hover {
    background: #777;       /* brighter on hover */
}

body.dark-mode {
    scrollbar-color: #555 #1c1c1c; /* thumb, track */
    scrollbar-width: thin;
}

/* Responsive design */
@media (max-width: 768px) {
    .timeline-container {
        padding: 1rem;
    }
    
    .timeline-item {
        height: 60px;
        padding: 6px 8px;
    }
    
    .timeline-item h4 {
        font-size: 10px;
    }
    
    .timeline-item p {
        font-size: 9px;
    }
    
    .modal-content {
        margin: 20% auto;
        padding: 1.5rem;
    }
}

/* ===========================
   PROJECT SECTION - LIST LAYOUT
   =========================== */

/* Tabs */
.tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem ;
    margin-bottom: 2rem;
    justify-content: center;
}

.tabs button {
    background-color: #f2f7ff;
    border: 1px solid #0073e6;
    color: #0073e6;
    padding: 0.75rem 1rem;
    border-radius: 25px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.95rem;
}

.tabs button:hover,
.tabs button.active {
    background-color: #0073e6;
    color: #ffffff;
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
    transform: translateY(-2px);
}

.tabs button:focus {
    outline: 2px solid #0073e6;
    outline-offset: 2px;
}

/* Projects List Container */
.projects-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-top: 2rem;
}

/* Project Cards - Horizontal Layout */
.project-card {
    display: none; /* Hidden by default */
    flex-direction: row;
    align-items: flex-start;
    gap: 1.5rem;
    background-color: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    padding: 1.5rem;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
}

.project-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    border-color: #0073e6;
}

/* Square Image on the Left */
.project-card img {
    width: 180px;
    height: 180px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.project-card img:hover {
    transform: scale(1.02);
}

/* Text Content on the Right */
.project-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.project-info h3 {
    color: #004aad;
    margin-bottom: 0.75rem;
    font-size: 1.25rem;
}

.project-info p {
    margin-bottom: 0.5rem;
    line-height: 1.5;
}

.project-info strong {
    color: #333;
    font-weight: 600;
}

/* =======
   PROJECT CARDS DARK MODE
   ======= */
body.dark-mode .tabs button {
    background-color: #2c2c2c;
    border: 1px solid #59a3ec;
    color: #59a3ec;
}

body.dark-mode .tabs button:hover,
body.dark-mode .tabs button.active {
    background-color: #59a3ec;
    color: #1a1a1a;
    box-shadow: 0 4px 8px rgba(0,0,0,0.5);
}

body.dark-mode .project-card {
    background-color: #1e1e1e;
    border: 1px solid #444;
    color: #f0f0f0;
}

body.dark-mode .project-card:hover {
    border-color: #59a3ec;
    box-shadow: 0 8px 25px rgba(0,0,0,0.4);
}

body.dark-mode .project-info h3 {
    color: #59a3ec;
}

body.dark-mode .project-info p {
    color: #cccccc;
}

body.dark-mode .project-info strong {
    color: #f0f0f0;
}

body.dark-mode .project-card img {
    filter: brightness(0.9);
}

/* ===========================
   IMAGE MODAL
   =========================== */
#image-modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(4px);
}

.modal-img {
    display: block;
    margin: auto;
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    border-radius: 8px;
}

.close-image {
    position: absolute;
    top: 20px;
    right: 30px;
    color: white;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    z-index: 2001;
    transition: color 0.3s ease;
}

.close-image:hover {
    color: #ccc;
}

/* -------------------------------------------------- */
/* PROJECT PAGE CONTAINER                             */
/* -------------------------------------------------- */

.project-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 80px 20px;
    display: flex;
    flex-direction: column;
    gap: 40px;
}

/* -------------------------------------------------- */
/* HERO IMAGE                                         */
/* -------------------------------------------------- */

.project-hero {
    width: 100%;
    height: 420px;
    border-radius: 14px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    box-shadow: 0 4px 18px rgba(0,0,0,0.08);
}

body.dark-mode .project-hero {
    box-shadow: 0 4px 18px rgba(255,255,255,0.08);
}

/* -------------------------------------------------- */
/* TITLE                                               */
/* -------------------------------------------------- */

.project-title {
    font-size: 2.4rem;
    font-weight: 700;
    margin: 0;
    text-align: left;
}

/* -------------------------------------------------- */
/* CONTEXT GRID (Problem, Solution, Impact)           */
/* -------------------------------------------------- */

.context-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.context-box {
    background: #fff;
    padding: 22px;
    border-radius: 12px;
    box-shadow: 0 4px 14px rgba(0,0,0,0.08);
}

body.dark-mode .context-box {
    background: rgba(25,25,25,0.8);
    box-shadow: 0 4px 14px rgba(255,255,255,0.06);
}

.context-box h3 {
    margin-bottom: 10px;
    font-size: 1.15rem;
    font-weight: 700;
}

.context-box p {
    line-height: 1.6;
    opacity: 0.9;
    font-size: 1rem;
}

/* -------------------------------------------------- */
/* DEEP DIVE SECTIONS                                 */
/* -------------------------------------------------- */

.project-section {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.project-section h2 {
    font-size: 1.7rem;
    margin: 0;
}

.project-section p {
    line-height: 1.7;
    opacity: 0.92;
    font-size: 1.05rem;
}

.project-section img {
    width: 100%;
    border-radius: 12px;
    box-shadow: 0 4px 18px rgba(0,0,0,0.08);
}

body.dark-mode .project-section img {
    box-shadow: 0 4px 18px rgba(255,255,255,0.08);
}

/* -------------------------------------------------- */
/* PROJECT PAGE HEADER (Simple Back Button Only)      */
/* -------------------------------------------------- */

.project-header {
    width: 100%;
    padding: 20px 20px 0;
    display: flex;
    align-items: center;
}

.back-btn {
    font-size: 1.2rem;
    text-decoration: none;
    font-weight: 600;
    color: #333;
    padding: 8px 14px;
    border-radius: 8px;
    background: rgba(0,0,0,0.05);
    transition: 0.25s ease;
}

.back-btn:hover {
    background: rgba(0,0,0,0.12);
}

body.dark-mode .back-btn {
    color: #fff;
    background: rgba(255,255,255,0.08);
}

body.dark-mode .back-btn:hover {
    background: rgba(255,255,255,0.15);
}

/* ===========================
   FOOTER
   =========================== */
.site-footer {
    text-align: center;
    font-size: 0.9rem;
    border-top: 1px solid #e0e0e0;
    padding: 2rem 1rem;
    background: #f9f9f9;
    color: #555;
    transition: all 0.3s ease;
}

body.dark-mode .site-footer {
    background: #1a1a1a;
    border-top: 1px solid #333;
    color: #cccccc;
}

/* Footer links styling */
.site-footer a {
    color: #0073e6;
    text-decoration: none;
    transition: color 0.3s ease;
}

body.dark-mode .site-footer a {
    color: #59a3ec;
}

.site-footer a:hover {
    color: #004aad;
    text-decoration: underline;
}

/* Mobile Responsiveness */
@media (max-width: 1024px) {
    body {
        padding: 1rem;
    }
    
    section {
        padding: 2rem 1rem;
    }
}

@media (max-width: 768px) {
    body {
        padding: 0.5rem;
        padding-top: 120px; /* Account for taller mobile header */
    }
    
    /* Header adjustments */
    header {
        flex-direction: row;
        justify-content: space-between;
        padding: 1rem;
        min-height: 80px;
    }
    
    /* Show mobile menu button */
    .mobile-menu-btn {
        display: flex;
        order: 2;
    }
    
    /* Mobile navigation */
    .navbar {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
        order: 3;
        box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    }
    
    body.dark-mode .navbar {
        background: rgba(0, 0, 0, 0.95);
    }
    
    .navbar.mobile-open {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }
    
    .navbar ul {
        flex-direction: column;
        gap: 0;
        padding: 1rem 0;
    }
    
    .navbar li {
        border-bottom: 1px solid rgba(0,0,0,0.1);
    }
    
    body.dark-mode .navbar li {
        border-bottom: 1px solid rgba(255,255,255,0.1);
    }
    
    .navbar li:last-child {
        border-bottom: none;
    }
    
    header nav a {
        display: block;
        padding: 1rem 2rem;
        font-size: 1rem;
        border-radius: 0;
        text-align: left;
        width: 100%;
    }
    
    header nav #contactnav {
        background: transparent;
        color: #0073e6;
        border-radius: 0;
    }
    
    body.dark-mode header nav #contactnav {
        color: #59a3ec;
    }
    
    header nav #contactnav:hover {
        background: #0073e6;
        color: #fff;
    }
    
    body.dark-mode header nav #contactnav:hover {
        background: #59a3ec;
        color: #1a1a1a;
    }
    
    /* Dark mode toggle positioning */
    .dark-mode-toggle {
        order: 1;
        margin-left: auto;
        margin-right: 1rem;
    }
    
    .logo {
        order: 0;
    }
    
    /* Sections */
    section {
        padding: 2rem 0.5rem;
        max-width: 100%;
    }
    
    /* Hero image */
    .hero-photo {
        height: 40vh;
    }
    
    /* Skills buttons */
    .skill-btn{
        font-size: 0.8rem;
        padding: 0.4rem 0.8rem;
    }

    
    /* Timeline adjustments */
    .timeline-container {
        padding: 1rem 0.5rem;
        min-height: 300px;
    }
    
    .timeline-wrapper {
        height: 250px;
    }
    
    .track {
        height: 100px;
    }
    
    .track-label {
        left: -60px;
        font-size: 0.9rem;
    }
    
    /* Project tabs */
    .tabs {
        justify-content: center;
        gap: 0.25rem;
    }
    
    .tabs button {
        padding: 0.5rem 0.8rem;
        font-size: 0.8rem;
        border-radius: 20px;
    }
    
    /* Project cards - stack vertically */
    .project-card {
        flex-direction: column;
        text-align: left;
        gap: 1rem;
        padding: 1rem;
    }
    
    .project-card img {
        width: 100%;
        height: 200px;
        max-width: none;
        align-self: stretch;
    }
    
    .project-info h3 {
        font-size: 1.1rem;
        margin-bottom: 0.5rem;
    }
    
    .project-info p {
        font-size: 0.9rem;
        margin-bottom: 0.4rem;
    }
    
    .projects-list {
        gap: 1rem;
    }
    
    /* Footer adjustments */
    .site-footer {
        padding: 1.5rem 0.5rem;
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    /* Extra small screens */
    header {
        padding: 0.75rem;
    }
    
    .logo .name {
        font-size: 120%;
    }
    
    .profile-icon {
        width: 40px;
        height: 40px;
    }
    
    .navbar ul {
        gap: 0.25rem;
    }
    
    header nav a {
        padding: 6px 10px;
        font-size: 0.8rem;
    }
    
    /* Smaller hero on very small screens */
    .hero-photo {
        height: 30vh;
    }
    
    /* Compact timeline */
    .timeline-container {
        padding: 0.75rem 0.25rem;
        min-height: 250px;
    }
    
    .timeline-wrapper {
        height: 200px;
    }
    
    .track {
        height: 80px;
    }
    
    .track-label {
        left: -50px;
        font-size: 0.8rem;
    }
    
    .year-marker {
        font-size: 0.8rem;
    }
    
    /* Smaller project elements */
    .tabs button {
        padding: 0.4rem 0.6rem;
        font-size: 0.75rem;
    }
    
    .project-card {
        padding: 0.75rem;
        gap: 0.75rem;
    }
    
    .project-card img {
        height: 150px;
    }
    
    .project-info h3 {
        font-size: 1rem;
    }
    
    .project-info p {
        font-size: 0.85rem;
    }
    
    /* Modal adjustments */
    .modal-content {
        margin: 5% auto;
        padding: 1.5rem;
        width: 95%;
    }
    
    .modal h3 {
        font-size: 1.1rem;
    }
    
    .modal-detail {
        font-size: 0.9rem;
    }
    
    /* Footer */
    .site-footer {
        padding: 1rem 0.5rem;
    }
    
    .site-footer p {
        margin-bottom: 0.5rem;
    }
}