/* --- START OF FILE style.css --- */

/* Basic Reset & Global Styles */
* { margin: 0; padding: 0; box-sizing: border-box; scroll-behavior: smooth; }
:root {
    --primary-color: #BF00FF; --primary-hover-color: #7B1FA2; --primary-very-dark-hover-color: #7B1FA2; --mail-color: #FFFFFF; --link-hover-color: #9370DB; --secondary-color: #999999; --background-color: #080808; --surface-color: #131313; --text-color: #cccccc; --heading-color: #f0f0f0; --border-color: #282828; --linkedin-color: #0A66C2; --github-color: var(--heading-color); --heading-font: 'Montserrat', sans-serif; --body-font: 'Lato', sans-serif; --section-padding: 70px 0; --container-width: 1140px;
    --reveal-translateY: 40px; --reveal-translateX: 150px; --reveal-duration: 0.8s; --reveal-delay: 0.05s;
    --portfolio-slide-width-lg: 33.333%; --portfolio-slide-width-md: 50%; --portfolio-slide-width-sm: 100%; /* Changed default SM to 100% */
    --portfolio-slide-gap: 20px;
    /* Original Backgrounds for Content Boxes */
    --about-bg: linear-gradient(rgba(8, 8, 8, 0.85), rgba(8, 8, 8, 0.85)), url('images/chair3.jpeg') no-repeat center center;
    --timeline-bg: var(--surface-color);
    --contact-bg: var(--surface-color);
}
/* Global Styles */
body { font-family: var(--body-font); line-height: 1.7; color: var(--text-color); background-color: var(--background-color); overflow-x: hidden; }
main { position: relative; z-index: 1; /* Above global canvas */ }
h1, h2, h3, h4, h5, h6 { font-family: var(--heading-font); font-weight: 600; margin-bottom: 1.2rem; line-height: 1.3; color: var(--heading-color); }
h1 { font-size: 3rem; }
h2 { font-size: 2.4rem; color: var(--primary-color); text-align: center; margin-bottom: 4rem; position: relative; z-index: 2; }
h2::after { content: ''; display: block; width: 70px; height: 4px; background: var(--primary-color); border-radius: 2px; margin: 12px auto 0; }
h3 { font-size: 1.6rem; } h4 { font-size: 1.2rem; color: var(--text-color); } p { margin-bottom: 1rem; }
a { color: var(--primary-color); text-decoration: none; transition: color 0.3s ease; } a:hover { color: var(--link-hover-color); }
ul { list-style: none; padding-left: 0; } img { max-width: 100%; height: auto; display: block; }
.container { max-width: var(--container-width); margin-left: auto; margin-right: auto; padding-left: 20px; padding-right: 20px; position: relative; z-index: 2; } /* Default container */

/* --- Global Matrix Canvas Styling --- */
#global-matrix-canvas {
    position: fixed; /* Keep it fixed in the background */
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1; /* Behind ALL other content */
    display: block;
}

/* Header & Nav */
header { background-color: rgba(8, 8, 8, 0.9); backdrop-filter: blur(12px); box-shadow: 0 2px 8px rgba(0,0,0,0.5); position: sticky; top: 0; z-index: 1000; width: 100%; transition: background-color 0.3s ease; border-bottom: 1px solid var(--border-color); }
/* ... header styles ... */
header nav { display: flex; justify-content: space-between; align-items: center; padding: 1rem 0; }
header .logo { font-size: 1.6rem; font-weight: 700; color: var(--heading-color); z-index: 1001; }
header nav ul#main-nav-list { display: flex; }
header nav ul#main-nav-list li { margin-left: 25px; }
header nav ul#main-nav-list li a { color: var(--text-color); font-weight: 600; padding: 8px 0; position: relative; transition: color 0.3s ease; }
header nav ul#main-nav-list li a::after { content: ''; position: absolute; bottom: 0; left: 0; width: 0; height: 2px; background-color: var(--primary-color); transition: width 0.3s ease; }
header nav ul#main-nav-list li a:hover, header nav ul#main-nav-list li a.active { color: var(--primary-color); }
header nav ul#main-nav-list li a:hover::after, header nav ul#main-nav-list li a.active::after { width: 100%; }
.mobile-nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 10px; z-index: 1001; margin-left: 15px; }
.mobile-nav-toggle span { display: block; width: 25px; height: 3px; background-color: var(--heading-color); margin: 5px 0; transition: all 0.3s ease-in-out; border-radius: 1px; }
.mobile-nav-toggle.active span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.mobile-nav-toggle.active span:nth-child(2) { opacity: 0; }
.mobile-nav-toggle.active span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* Buttons */
.btn { display: inline-block; padding: 12px 25px; border-radius: 5px; font-weight: 600; text-align: center; cursor: pointer; margin: 5px; letter-spacing: 0.5px; position: relative; z-index: 1; overflow: hidden; background-color: black; color: var(--primary-color); border: 1px solid var(--primary-color); transition: color 0.4s ease, transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease; }
.btn::before { content: ''; position: absolute; top: 0; left: 0; width: 0; height: 100%; background-color: var(--primary-very-dark-hover-color); transition: width 0.4s cubic-bezier(0.25, 0.8, 0.25, 1); z-index: -1; }
.btn:hover { color: #fff; transform: translateY(-2px); box-shadow: 0 4px 10px rgba(123, 104, 238, 0.25); border-color: var(--primary-color); }
.btn:hover::before { width: 100%; }
.btn-primary {} .btn-secondary { background: linear-gradient(145deg, var(--surface-color), #2b0f38);	 color: #ffffff; border-color: var(--primary-color); } .btn-small { padding: 5px 10px; font-size: 0.7rem; }


/* Hero Section */
.hero-section { color: #fff; padding: var(--section-padding); text-align: center; min-height: 70vh; display: flex; align-items: center; justify-content: center; background: none; /* No section background */ }
.hero-content { position: relative; z-index: 2; /* Above global canvas */ }
/* ... hero content styles ... */
.hero-content .profile-pic { width: 150px; height: 150px; border-radius: 50%; margin: 0 auto 25px auto; border: 5px solid var(--primary-color); object-fit: cover; box-shadow: 0 0 25px rgba(123, 104, 238, 0.4); }
.hero-content h1 { color: #fff; margin-bottom: 0.8rem; font-weight: 700; }
.hero-content .subtitle { font-size: 1.5rem; font-weight: 300; margin-bottom: 2.5rem; color: var(--secondary-color); min-height: 2.2em; }
.typed-cursor { color: var(--primary-color); opacity: 1; animation: blink 0.7s infinite; }
@keyframes blink { 0% { opacity: 1; } 50% { opacity: 0; } 100% { opacity: 1; } }

/* Sections General */
section {
    padding: var(--section-padding);
    position: relative; /* Needed for z-index context */
    background: none; /* REMOVE ALL SECTION BACKGROUNDS */
    overflow: hidden; /* Keep overflow hidden */
}

/* --- Content Box Styling (About, Timeline, Contact) --- */
.content-box {
    border-radius: 8px;
    padding: 40px;
    max-width: calc(var(--container-width) + 80px); /* Adjust based on padding */
    margin: 0 auto;
    position: relative;
    z-index: 1; /* Above global canvas */
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.5);
}
.content-box > .container { padding-left: 0; padding-right: 0; max-width: 100%; }

/* Apply specific backgrounds to content boxes */
#about .content-box { background: var(--about-bg); background-size: cover; }
#timeline .content-box { background-color: var(--timeline-bg); /* Light surface color */ }
#contact .content-box { background-color: var(--contact-bg); /* Light surface color */ }

/* About Section Specifics */
#about .content-box .about-content { max-width: 750px; margin-left: auto; margin-right: auto; text-align: left; }
/* Increase font size for About Me paragraphs */
#about .about-content p {
  font-size: 1.15rem; /* Default paragraph size is likely 1rem or similar. Adjust this value as needed. */
  /* Optional: Adjust line-height if needed for better readability */
  /* line-height: 1.75; */ /* Slightly increase line height */
}
/* Reduce space before the About section */
#about {
  /* Override the default top padding (70px) */
  padding-top: 20px; /* Adjust this value - smaller means less space */
  /* It will inherit padding-bottom: 70px from the general 'section' rule */
}

/* Portfolio & Certifications Sections (No Box, Content over Global Canvas) */
#portfolio > .container,
#certifications > .container {
    position: relative;
    z-index: 1; /* Content above global canvas */
}

/* Portfolio - Carousel */
.portfolio-carousel-wrapper { position: relative; max-width: 1140px; margin: 3rem auto 0 auto; padding: 0 45px; z-index: 2; /* Above canvas */ }
/* ... rest of portfolio styles ... */
.portfolio-carousel { overflow: hidden; width: 100%; }
.portfolio-track { display: flex; transition: transform 0.5s ease-in-out; margin-left: calc(var(--portfolio-slide-gap) / -2); margin-right: calc(var(--portfolio-slide-gap) / -2); }
.portfolio-slide { flex-shrink: 0; flex-basis: var(--portfolio-slide-width-lg); padding: 0 calc(var(--portfolio-slide-gap) / 2); box-sizing: border-box; }
.portfolio-item { background-color: var(--surface-color); border-radius: 8px; box-shadow: 0 5px 15px rgba(0,0,0,0.4); overflow: hidden; display: flex; flex-direction: column; border: 1px solid var(--border-color); height: 100%; transition: transform 0.3s ease, box-shadow 0.3s ease; }
.portfolio-item:hover { transform: translateY(-5px) scale(1.02); box-shadow: 0 8px 20px rgba(0,0,0,0.5); z-index: 10; }
.portfolio-image { height: 170px; width: 100%; overflow: hidden; position: relative; background-color: #222; flex-shrink: 0; }
.portfolio-image a { display: block; width: 100%; height: 100%; }
.portfolio-item img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center; transition: transform 0.4s ease; }
.portfolio-item:hover img { transform: scale(1.05); }
.portfolio-content { padding: 18px; flex-grow: 1; display: flex; flex-direction: column; }
.portfolio-item h3 { margin-bottom: 0.7rem; color: var(--heading-color); font-size: 1.25rem; }
.portfolio-item p { font-size: 0.9rem; color: var(--secondary-color); line-height: 1.5; margin-bottom: 1rem; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; text-overflow: ellipsis;}
.portfolio-item .btn { margin-top: auto; align-self: flex-start; padding: 4px 8px; font-size: 0.65rem; }
.carousel-button { position: absolute; top: 50%; transform: translateY(-50%); background-color: rgba(25, 25, 25, 0.7); color: var(--heading-color); border: 1px solid var(--border-color); border-radius: 50%; width: 38px; height: 38px; font-size: 1rem; cursor: pointer; z-index: 20; display: flex; justify-content: center; align-items: center; transition: background-color 0.3s ease, color 0.3s ease; }
.carousel-button:hover { background-color: var(--primary-very-dark-hover-color); color: #fff; }
.carousel-button:focus { outline: 2px solid var(--primary-color); outline-offset: 2px; }
.carousel-button.prev { left: 5px; } .carousel-button.next { right: 5px; } .carousel-button.disabled { opacity: 0.5; cursor: not-allowed; }

/* --- Timeline & Skills Section --- */
/* Styles apply within the #timeline .content-box */
#timeline .content-box > .container > .btn { display: block; width: fit-content; margin: 0 auto 3.5rem auto; }
#timeline .timeline-skills-wrapper { display: flex; flex-direction: column; gap: 40px; align-items: center; }
#timeline .skills-icon-grid-container { /* Dark grid floating on light box */
    background-color: var(--background-color);
    border: 1px solid var(--border-color); border-radius: 8px; padding: 30px 20px;
    width: 100%; max-width: 900px; margin: 0 auto; box-shadow: 0 5px 15px rgba(0,0,0,0.3);
}
#timeline .skills-grid-title { text-align: center; margin-bottom: 2.5rem; color: var(--heading-color); font-weight: 600; font-size: 1.4rem; }
#timeline .skills-icon-grid { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 30px 40px; }
@keyframes gentleSway { 0% { transform: rotate(-4deg) translateY(-5px); } 50% { transform: rotate(4deg) translateY(5px); } 100% { transform: rotate(-4deg) translateY(-5px); } }
#timeline .skills-icon-grid i { font-size: 3.5rem; padding: 10px; display: inline-block; transition: transform 0.35s cubic-bezier(0.25, 0.8, 0.25, 1); will-change: transform, opacity; backface-visibility: hidden; }

#timeline .skills-icon-grid i.reveal-on-scroll.visible { animation: gentleSway 3.5s ease-in-out infinite alternate; }

#timeline .skills-icon-grid i:hover { transform: scale(1.2) rotate(7deg); animation-play-state: paused; }
#timeline .other-skills-note { text-align: center; margin-top: 3rem; font-size: 1.05rem; color: var(--text-color); line-height: 1.6; max-width: 650px; margin-left: auto; margin-right: auto; padding-top: 1.5rem; border-top: 1px solid var(--border-color); }
#timeline .other-skills-note strong { color: var(--primary-color); font-weight: 600; }

/* Timeline Styles */
.minimal-timeline .timeline { position: relative; padding: 20px 0; width: 100%; max-width: 700px; margin: 0 auto; }
.minimal-timeline .timeline-spine { position: absolute; top: 0; bottom: 0; left: 20px; width: 2px; background-color: var(--border-color); z-index: 1; }
.minimal-timeline .timeline-item { position: relative; padding-left: 60px; padding-bottom: 40px; }
.minimal-timeline .timeline-item:last-child { padding-bottom: 0; }
.minimal-timeline .timeline-icon { position: absolute; left: 8px; top: 4px; width: 24px; height: 24px; background-color: var(--background-color); border: 2px solid var(--primary-color); border-radius: 50%; z-index: 10; display: flex; justify-content: center; align-items: center; color: #fff; font-size: 0.8rem; }
.minimal-timeline .timeline-item-content { position: relative; padding-top: 0; }
.minimal-timeline .timeline-date { display: block; font-size: 0.85rem; color: var(--secondary-color); margin-bottom: 6px; font-weight: 400; }
.minimal-timeline .timeline-item-content h4 { margin-bottom: 8px; color: var(--heading-color); font-weight: 600; font-size: 1.2rem; line-height: 1.4; }
.minimal-timeline .timeline-subtitle { font-size: 1rem; color: var(--primary-color); margin-bottom: 12px; font-weight: 400; }
.minimal-timeline .timeline-item-content p:not(.timeline-subtitle), .minimal-timeline .timeline-item-content ul { font-size: 0.95rem; color: var(--text-color); line-height: 1.7; margin-bottom: 0; }
.minimal-timeline .timeline-item-content ul { list-style: none; padding-left: 0; margin-top: 10px; }
.minimal-timeline .timeline-item-content ul li { margin-bottom: 8px; position: relative; padding-left: 18px; }
.minimal-timeline .timeline-item-content ul li::before { content: ''; position: absolute; left: 0; top: 0.6em; width: 5px; height: 5px; background-color: var(--secondary-color); border-radius: 50%; }



/* Certifications Section */
#certifications > .container > p { color: var(--secondary-color); margin-bottom: 2.5rem; text-align: center; max-width: 700px; margin-left: auto; margin-right: auto; position: relative; z-index: 2; /* Above global canvas */ }
#certifications .certifications-list { max-width: 850px; margin: 2rem auto 0 auto; display: flex; flex-direction: column; gap: 25px; position: relative; z-index: 2; /* Above global canvas */ }
.certification-item { background-color: var(--background-color); border-radius: 8px; padding: 25px 30px; border: 1px solid var(--border-color); box-shadow: 0 4px 15px rgba(0,0,0,0.35); display: flex; align-items: flex-start; gap: 20px; transition: transform 0.3s ease, box-shadow 0.3s ease; }
/* ... rest of cert styles ... */
.certification-item:hover { transform: translateY(-5px); box-shadow: 0 8px 20px rgba(0,0,0,0.45); }
.certification-badge { width: 60px; height: 60px; object-fit: contain; flex-shrink: 0; margin-top: 5px; }
.certification-details { flex-grow: 1; }
.certification-item h4 { margin-bottom: 0.4rem; color: var(--heading-color); font-size: 1.2rem; font-weight: 600; }
.certification-item p { margin-bottom: 0.5rem; font-size: 0.95rem; color: var(--secondary-color); line-height: 1.6; }
.certification-item p:last-child { margin-bottom: 0; }
.certification-item p em { color: var(--text-color); font-style: normal; font-size: 0.9rem; display: block; margin-bottom: 0.3rem; }
.certification-item .btn { margin-top: 10px; }

/* Contact Section */
#contact .content-box { text-align: center; border: 1px solid var(--primary-color); background: linear-gradient(145deg, var(--surface-color), #2b0f38); }
#contact .container > p { color: var(--secondary-color); margin-bottom: 1rem; max-width: 600px; margin-left: auto; margin-right: auto; }
#contact .container > p:first-of-type { color: var(--text-color); font-size: 1.1rem; margin-bottom: 2rem; }
/* ... rest of contact styles ... */
#contact .email-container p a { color: var(--mail-color); font-weight: 600; font-size: 1.2em; }
#contact .email-container p a:hover { text-decoration: underline; color: var(--link-hover-color); }
#contact .email-container { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: center; gap: 3px 8px; margin-bottom: 1.5rem; }
#contact .email-container p { margin-bottom: 0; line-height: 1.5; }
.copy-icon-button { display: inline-flex; align-items: center; justify-content: center; background: none; border: none; color: var(--secondary-color); padding: 5px; cursor: pointer; font-size: 1em; line-height: 1; vertical-align: middle; transition: color 0.2s ease; border-radius: 4px; }
.copy-icon-button i.fa-copy { margin: 0; }
.copy-icon-button:hover, #contact .copy-icon-button:focus { color: var(--primary-color); outline: none; }
.copy-icon-button:focus-visible { outline: 1px dotted var(--primary-color); outline-offset: 2px; }
.copy-status-message { display: inline-block; margin-left: 5px; font-size: 0.85rem; font-weight: 500; transition: opacity 0.3s ease; vertical-align: baseline; color: var(--primary-color); }
#contact .social-links { margin: 2rem 0 1rem 0; padding: 0; }
#contact .social-links a { margin: 0 15px; font-size: 1.1rem; color: var(--secondary-color); transition: color 0.3s ease, transform 0.3s ease; display: inline-flex; align-items: center; gap: 6px; }
#contact .social-links a i { font-size: 1.3em; transition: color 0.3s ease; }
#contact .social-links a .fa-linkedin { color: var(--linkedin-color); }
#contact .social-links a .fa-github { color: var(--github-color); }
#contact .social-links a:hover { color: var(--primary-color); transform: scale(1.1); }
#contact .social-links a:hover i { color: var(--primary-color); }
#contact .content-box .container > .btn-primary { margin-top: 1rem; margin-bottom: 1rem; }


/* Footer */
footer { background-color: #050505; color: #666; text-align: center; padding: 2rem 0; border-top: 1px solid var(--border-color); position: relative; z-index: 1; /* Above canvas */ }
footer p { margin-bottom: 0; font-size: 0.9rem; }

/* --- Reveal Animations --- */
.reveal-on-scroll { opacity: 0; transform: translateY(var(--reveal-translateY)) scale(0.95); transition: opacity var(--reveal-duration) cubic-bezier(0.25, 0.1, 0.25, 1), transform var(--reveal-duration) cubic-bezier(0.25, 0.1, 0.25, 1); will-change: opacity, transform; position: relative; z-index: 2; }
.reveal-on-scroll.visible { opacity: 1; transform: translateY(0) scale(1); }
/* Cert reveals */
.certifications-list .certification-item.reveal-on-scroll { transform: none; transition: opacity var(--reveal-duration) ease-out, transform calc(var(--reveal-duration) * 1.1) cubic-bezier(0.175, 0.885, 0.32, 1.275); z-index: 2; }
.certifications-list .certification-item.reveal-on-scroll:nth-child(odd) { opacity: 0; transform: translateX(calc(-1 * var(--reveal-translateX))); }
.certifications-list .certification-item.reveal-on-scroll:nth-child(even) { opacity: 0; transform: translateX(var(--reveal-translateX)); }
.certifications-list .certification-item.reveal-on-scroll.visible { opacity: 1; transform: translateX(0); }

/* --- Mouse Follower Effects --- */
body { cursor: default; } body.custom-cursor-active { cursor: none; }
/* ... rest of mouse follower styles ... */
body.custom-cursor-active a, body.custom-cursor-active button, body.custom-cursor-active .btn, body.custom-cursor-active .carousel-button, body.custom-cursor-active .portfolio-item a, body.custom-cursor-active .portfolio-item .btn, body.custom-cursor-active .copy-icon-button, body.custom-cursor-active [data-cursor-hover] { cursor: none; }
.cursor-dot, .cursor-outline { position: fixed; top: 0; left: 0; transform: translate(-50%, -50%); border-radius: 50%; z-index: 1100; pointer-events: none; opacity: 0; transition: opacity 0.3s ease-in-out, transform 0.1s ease; }
.cursor-dot { width: 8px; height: 8px; background-color: var(--primary-color); transition: opacity 0.3s ease-in-out; }
.cursor-outline { width: 40px; height: 40px; background-color: rgba(191, 0, 255, 0.2); border: 1px solid rgba(191, 0, 255, 0.4); transition: width 0.3s ease, height 0.3s ease, opacity 0.3s ease, background-color 0.3s ease, border-color 0.3s ease, transform 0.15s cubic-bezier(0.25, 1, 0.5, 1); }
.cursor-outline.hover { width: 60px; height: 60px; background-color: rgba(191, 0, 255, 0.1); border-color: var(--primary-color); }

/* --- Responsive Design Adjustments --- */
@media (min-width: 993px) { #timeline .timeline-skills-wrapper { flex-direction: row; gap: 50px; align-items: flex-start; } #timeline .skills-icon-grid-container { flex: 1 1 50%; max-width: none; margin: 0; order: 1; } #timeline .minimal-timeline .timeline { flex: 1 1 45%; max-width: none; margin: 0; order: 2; } }

@media (max-width: 992px) {
     :root { --container-width: 90%; --section-padding: 60px 0; --portfolio-slide-gap: 15px; }
     .content-box { padding: 30px; max-width: calc(90% + 60px); }
     h1 { font-size: 2.5rem; }
     h2 { font-size: 2rem; }
     .portfolio-slide { flex-basis: var(--portfolio-slide-width-md); padding: 0 calc(var(--portfolio-slide-gap) / 2);} /* 2 per row */
     .portfolio-carousel-wrapper { padding: 0 40px; } /* Keep some padding for 2-per-row */
     #timeline .timeline-skills-wrapper { flex-direction: column; gap: 30px; }
     #timeline .skills-icon-grid-container { order: 1; }
     #timeline .minimal-timeline .timeline { order: 2; margin-bottom: 0; }
     #timeline .skills-icon-grid i { font-size: 3.2rem; gap: 25px 35px;}
}

/* === UPDATED BLOCK for 768px and below (Full Width Slides) === */
@media (max-width: 768px) {
    :root { --section-padding: 50px 0; --portfolio-slide-gap: 0px; /* No gap needed for full width */ --reveal-translateX: 100px; }
    .content-box { padding: 25px; max-width: calc(90% + 50px); border-radius: 6px; }
    h1 { font-size: 2.2rem; }
    h2 { font-size: 1.8rem; }
    h3 { font-size: 1.4rem; }
    header nav { padding: 0.8rem 0; }
    header .logo { font-size: 1.4rem; }
    /* ... rest of header mobile styles ... */
    header nav ul#main-nav-list { display: none; position: absolute; top: 100%; left: 0; width: 100%; background-color: rgba(19, 19, 19, 0.98); backdrop-filter: blur(5px); border-top: 1px solid var(--border-color); box-shadow: 0 5px 10px rgba(0,0,0,0.3); padding: 15px 0; z-index: 999; }
    header nav ul#main-nav-list.active { display: flex; flex-direction: column; align-items: center; }
    header nav ul#main-nav-list li { margin-left: 0; width: 100%; text-align: center; }
    header nav ul#main-nav-list li a { padding: 12px 20px; display: block; width: 100%; font-size: 1rem; border-bottom: 1px solid var(--border-color); }
    header nav ul#main-nav-list li:last-child a { border-bottom: none; }
    header nav ul#main-nav-list li a::after { display: none; }
    header nav ul#main-nav-list li a:hover, header nav ul#main-nav-list li a.active { color: var(--primary-color); background-color: rgba(0,0,0,0.2); }
    .mobile-nav-toggle { display: block; }
    .hero-section { padding: 100px 0 80px 0; min-height: 60vh; }
    .hero-content .subtitle { font-size: 1.3rem; }

    /* --- Portfolio Adjustments for Full Width Slides --- */
    .portfolio-carousel-wrapper {
        padding: 0; /* Remove horizontal padding */
        margin-top: 2rem;
        max-width: 100%; /* Allow wrapper to be full width */
    }
    .portfolio-track {
        margin-left: 0; /* Remove negative margin */
        margin-right: 0; /* Remove negative margin */
    }
    .portfolio-slide {
        flex-basis: 100%; /* Make slide take up full width */
        padding: 0; /* Remove horizontal padding */
    }
    .portfolio-item {
        border-radius: 0; /* Optional: remove radius for edge-to-edge feel */
        border-left: none; /* Optional: remove side borders */
        border-right: none; /* Optional: remove side borders */
        box-shadow: none; /* Optional: remove shadow if it looks odd edge-to-edge */
    }
     .portfolio-item:hover {
        transform: none; /* Disable hover transform */
        box-shadow: none; /* Disable hover shadow */
     }
    .portfolio-content {
        padding: 18px 15px; /* Add back some padding for content inside */
    }
    .carousel-button {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }
    .carousel-button.prev {
        left: 5px; /* Position slightly inset */
    }
    .carousel-button.next {
        right: 5px; /* Position slightly inset */
    }
    /* --- End Portfolio Adjustments --- */

    #timeline .content-box > .container > .btn { margin-bottom: 2.5rem; }
    #timeline .timeline-skills-wrapper { gap: 20px; }
    #timeline .skills-icon-grid-container { max-width: 100%; padding: 25px 15px; }
    #timeline .skills-icon-grid { gap: 20px 30px;}
    #timeline .skills-icon-grid i { font-size: 3rem; }
    #timeline .other-skills-note { font-size: 1rem; }
    #timeline .minimal-timeline .timeline { max-width: 100%; padding-left: 0; margin-top: 2rem; }
    #timeline .minimal-timeline .timeline-spine { left: 15px; }
    #timeline .minimal-timeline .timeline-item { padding-left: 50px; padding-bottom: 30px; }
    #timeline .minimal-timeline .timeline-icon { left: 3px; width: 20px; height: 20px; font-size: 0.7rem; }
    #timeline .minimal-timeline .timeline-item-content h4 { font-size: 1.1rem; }
    #timeline .minimal-timeline .timeline-subtitle { font-size: 0.95rem; }
    #timeline .minimal-timeline .timeline-item-content p:not(.timeline-subtitle), #timeline .minimal-timeline .timeline-item-content ul { font-size: 0.9rem; }
    .certification-item { padding: 20px; flex-direction: column; align-items: center; text-align: center; background-color: var(--background-color); }
    .certification-badge { width: 50px; height: 50px; margin-bottom: 15px; margin-top: 0; }
    .certification-item h4 { font-size: 1.1rem; }
    .certification-item .btn { margin-left: auto; margin-right: auto; padding: 8px 16px; }
    #contact .content-box .container > .btn-primary { margin-top: 1rem; margin-bottom: 0.5rem;}

    /* --- Hide Custom Cursor on Mobile/Touch --- */
    .cursor-dot,
    .cursor-outline {
        display: none !important; /* Force hide the elements */
    }
    /* Ensure default cursor behavior is restored */
    body {
        cursor: default !important;
    }
    /* Prevent links/buttons from inheriting cursor: none */
     a, button, .btn, .carousel-button, .portfolio-item a, .portfolio-item .btn, .copy-icon-button, [data-cursor-hover] {
        cursor: pointer !important; /* Or revert to auto/default if needed */
    }
    /* --- End Hide Custom Cursor --- */

}
/* === END UPDATED BLOCK === */

/* === UPDATED BLOCK for 480px === */
@media (max-width: 480px) {
    /* Inherit most 768px styles */
    :root { --reveal-translateX: 75px; }
    .content-box { padding: 20px; max-width: calc(95% + 40px); border-radius: 4px;}
    h1 { font-size: 1.9rem; }
    .hero-content .subtitle { font-size: 1.1rem; }
    .hero-content .profile-pic { width: 120px; height: 120px; }
    .btn { padding: 10px 20px; }
    .portfolio-item .btn { padding: 6px 12px; font-size: 0.6rem;}
    .certification-item .btn { padding: 6px 12px; }
    .portfolio-image { height: 180px; /* Maybe slightly taller on small phones */}
    .portfolio-content { padding: 15px 12px; /* Slightly less padding */ }
    .portfolio-item h3 { font-size: 1.1rem; }
    .portfolio-item p { font-size: 0.85rem; line-height: 1.4; -webkit-line-clamp: 3; } /* Keep 3 lines */
    .carousel-button {
        width: 30px; /* Slightly smaller buttons */
        height: 30px;
        font-size: 0.9rem;
    }
     .carousel-button.prev {
        left: 3px; /* Adjust inset */
    }
    .carousel-button.next {
        right: 3px; /* Adjust inset */
    }

    #timeline .content-box > .container > .btn { margin-bottom: 2rem; }
    #timeline .skills-icon-grid-container { padding: 20px 10px; }
    #timeline .skills-icon-grid { gap: 20px 25px; }
    #timeline .skills-icon-grid i { font-size: 2.5rem; padding: 5px; }
    #timeline .other-skills-note { font-size: 0.95rem; }
    #contact .social-links a { margin: 0 10px; }
    #contact .email-container { justify-content: center; gap: 5px; }
    #contact .copy-icon-button { padding: 4px; }
    #contact .copy-status-message { display: block; margin-left: 0; margin-top: 3px; width: 100%; text-align: center; }
    #contact .content-box .container > .btn-primary { margin-top: 0.8rem; margin-bottom: 0.2rem;}

    /* NOTE: Cursor hiding rules from 768px media query already apply here */
    /* No need to repeat them unless you need different behavior at 480px */
}
/* === END UPDATED BLOCK === */

/* --- Minimal Blog Page Styles --- */

/* Blog Listing Page (blog.html) */
.blog-listing-section {
    padding-top: 50px;
}

.blog-listing-section .section-subtitle {
    text-align: center;
    max-width: 600px;
    margin: -2.5rem auto 3.5rem auto;
    color: var(--secondary-color);
    font-size: 1.1rem;
}

.minimal-blog-list {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
}

.minimal-post-item {
    padding-bottom: 2.5rem;
    border-bottom: 1px solid var(--border-color);
}
.minimal-blog-list .minimal-post-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.minimal-post-item .post-meta {
    font-size: 0.9rem;
    color: var(--secondary-color);
    margin-bottom: 0.25rem;
}

.minimal-post-item h2 {
    text-align: left;
    margin: 0 0 0.75rem 0;
    font-size: 1.8rem;
    color: var(--heading-color);
}

.minimal-post-item h2::after {
    display: none; /* Remove the underline from the global h2 style */
}

.minimal-post-item h2 a {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s ease;
}

.minimal-post-item h2 a:hover {
    color: var(--primary-color);
}

.minimal-post-item .post-excerpt {
    font-size: 1rem;
    line-height: 1.7;
    color: var(--text-color);
}

/* Single Blog Post Page (post1.html etc.) */
.blog-post-full {
    padding: 60px 0;
}

.blog-post-container {
    max-width: 800px; /* Optimal reading width */
    margin: 0 auto;
}

.blog-post-header {
    text-align: center;
    margin-bottom: 3.5rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--border-color);
}

.blog-post-header h1 {
    font-size: 2.8rem;
    color: var(--heading-color);
}

.blog-post-header .post-meta {
    font-size: 1rem;
    margin-top: -1rem;
    margin-bottom: 1.5rem;
}

.back-to-blog-link {
    display: inline-block;
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s;
}
.back-to-blog-link:hover {
    color: var(--link-hover-color);
}
.back-to-blog-link i {
    margin-right: 8px;
}

/* Content typography from here is largely the same, but refined */
.post-content {
    font-size: 1.1rem;
    line-height: 1.8;
}

.post-content h2 {
    font-size: 1.8rem;
    color: var(--primary-color);
    margin-top: 2.5rem;
    margin-bottom: 1.5rem;
    text-align: left;
}
.post-content h2::after {
   margin: 12px 0 0 0;
}

.post-content p { margin-bottom: 1.5rem; }
.post-content a { text-decoration: underline; }
.post-content ul, .post-content ol { margin-bottom: 1.5rem; padding-left: 25px; }
.post-content li { margin-bottom: 0.75rem; }

.post-content blockquote {
    border-left: 3px solid var(--primary-color);
    padding-left: 1.5rem;
    margin: 2rem 0;
    font-style: italic;
    color: var(--secondary-color);
}

/* Responsive adjustments for minimal blog */
@media (max-width: 768px) {
    .blog-post-header h1 { font-size: 2.2rem; }
    .minimal-post-item h2 { font-size: 1.5rem; }
}

@media (max-width: 480px) {
    .blog-post-header h1 { font-size: 1.9rem; }
    .post-content { font-size: 1rem; }
}

/* --- Light Theme for Blog --- */

/* --- Light Theme for Blog --- */

body.light-theme {
    /* Redefine global color variables for the light theme */
    --background-color: #FFFFFF;
    --surface-color: #F5F5F5;
    --text-color: #333333;       /* Body text */
    --heading-color: #111111;      /* Default heading color, nearly black */
    --border-color: #E0E0E0;       /* Light gray borders */
    --secondary-color: #666666;    /* Lighter gray for dates, etc. */
    
    /* NEW: Monochromatic gray accents */
    --primary-color: #2c3e50;      /* A strong, elegant dark gray for titles */
    --primary-hover-color: #000000; /* Black for a clear hover effect */
    --link-hover-color: #000000;    /* Keep hover consistent */
}

/* Override Header for light theme */
.light-theme header {
    background-color: rgba(255, 255, 255, 0.9);
    border-bottom: 1px solid var(--border-color);
}
.light-theme header .logo {
    color: var(--heading-color);
}
.light-theme header nav ul#main-nav-list li a {
    color: var(--text-color);
}
.light-theme header nav ul#main-nav-list li a:hover,
.light-theme header nav ul#main-nav-list li a.active {
    color: var(--primary-color);
}
.light-theme .mobile-nav-toggle span {
    background-color: var(--heading-color);
}
.light-theme header nav ul#main-nav-list.active {
    background-color: rgba(245, 245, 245, 0.98);
    border-top: 1px solid var(--border-color);
}
.light-theme header nav ul#main-nav-list li a {
    border-bottom: 1px solid var(--border-color);
}

/* Override Footer for light theme */
.light-theme footer {
    background-color: #F8F8F8;
    color: var(--secondary-color);
    border-top: 1px solid var(--border-color);
}

/* Adjustments for minimal blog list on light theme */
.light-theme .minimal-post-item h2 a:hover {
    color: var(--primary-color);
}
.light-theme .post-content blockquote {
    background-color: #fafafa;
}

/* Hide custom cursor on light theme for a more standard blog feel (Optional but recommended) */
.light-theme .cursor-dot,
.light-theme .cursor-outline {
    display: none !important;
}
.light-theme {
    cursor: default !important;
}
.light-theme a, .light-theme button {
    cursor: pointer !important;
}

/* --- Add Animated Underline on Hover for Blog Titles --- */

/* --- For titles on the main blog listing page --- */

/* Target the link inside the title */
.light-theme .minimal-post-item h2 a {
    text-decoration: none; /* Remove any default underline */
    position: relative;
    padding-bottom: 5px; /* Add some space for the line to appear */
}

/* This is the underline itself, hidden by default */
.light-theme .minimal-post-item h2 a::after {
    content: '';
    position: absolute;
    width: 0; /* Starts with zero width, so it's invisible */
    height: 2px;
    bottom: 0;
    left: 0;
    background-color: var(--primary-hover-color); /* Uses the black hover color */
    transition: width 0.3s ease-in-out; /* The animation effect */
}

/* On hover, the underline grows to full width */
.light-theme .minimal-post-item h2 a:hover::after {
    width: 100%;
}


/* --- For the main H1 title on a single post page --- */

.light-theme .blog-post-header h1 {
    display: inline-block; /* Ensures the line is only as wide as the text */
    position: relative;
    padding-bottom: 8px; /* A bit more space for the larger title */
}

.light-theme .blog-post-header h1::after {
    content: '';
    position: absolute;
    width: 0;
    height: 3px; /* A slightly thicker line for the main title */
    bottom: 0;
    left: 50%; /* Start the animation from the center */
    transform: translateX(-50%);
    background-color: var(--primary-hover-color);
    transition: width 0.3s ease-in-out;
}

/* On hover, the underline grows from the center outwards */
.light-theme .blog-post-header h1:hover::after {
    width: 100%;
}

/* --- Preloader Styles --- */
#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999; /* Ensure it's on top of everything */

    /* Centering the GIF */
    display: flex;
    justify-content: center;
    align-items: center;

    /* Background for both themes - a dark, semi-transparent overlay looks good on both */
    background-color: rgba(8, 8, 8, 1);
    backdrop-filter: blur(5px); /* Optional: blurs the content behind it */

    /* For the fade-out animation */
    opacity: 1;
    visibility: visible;
    transition: opacity 0.5s ease-out, visibility 0.5s ease-out;
}

#preloader img {
    max-width: 150px; /* Adjust size of your GIF as needed */
    width: 50%;
    height: auto;
}

/* This class will be added by JavaScript to hide the preloader */
#preloader.preloader-hidden {
    opacity: 0;
    visibility: hidden;
}

/* --- Work in Progress Page Styles --- */

#wip-section {
    /* This vertically centers the content on the page */
    min-height: 65vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 0;
}

.wip-content {
    text-align: center;
    max-width: 600px; /* Prevents text from being too wide */
}

/* Style for the animated icon */
.wip-content .fa-cogs {
    font-size: 5rem; /* Make the icon large */
    color: var(--primary-color); /* Uses the dark gray on the light theme */
    margin-bottom: 2rem;
}

/* Style for the main headline */
.wip-content h2 {
    color: var(--heading-color);
    font-size: 2.5rem;
    margin-bottom: 1rem;
    text-align: center;
}

/* Remove the global H2 underline for this specific title */
.wip-content h2::after {
    display: none;
}

/* Style for the message */
.wip-content p {
    font-size: 1.15rem;
    color: var(--secondary-color);
    line-height: 1.7;
    margin-bottom: 2.5rem;
}

/* This targets any button with .btn on your light pages */
.light-theme .btn {
    color: #FFFFFF; /* Makes the button text white */
    background-color: var(--primary-color); /* Uses the dark gray as the background */
    border-color: var(--primary-color);   /* Matches the border to the background */
}

/* Style for when you hover over the button */
.light-theme .btn:hover {
    color: #FFFFFF; /* Keeps the text white */
    background-color: var(--primary-hover-color); /* Changes background to solid black */
    border-color: var(--primary-hover-color);   /* Matches the border */
}

/* This disables the animated ::before element that is used on your dark theme,
   ensuring we have a clean, solid button on the light theme. */
.light-theme .btn::before {
    display: none;
}


/* The existing .btn styles will automatically apply to the button */
/* --- END OF FILE style.css --- */
