/* Variables */
:root {
    --primary-color: #0f766e;
    --primary-hover: #0b5e57;
    --secondary-color: #0f172a;
    --accent-color: #d97706;
    --text-color: #0f172a;
    --text-light: #52606d;
    --bg-color: #f7f3ef;
    --card-bg: #ffffff;
    --border-color: #e6e0d8;
    --highlight: #ecf5f3;
    --shadow: 0 24px 45px -25px rgba(15, 23, 42, 0.35);
    --shadow-soft: 0 12px 30px rgba(15, 23, 42, 0.08);
    --glass-bg: rgba(255, 255, 255, 0.75);
    --section-padding: 5.5rem 0;
    --transition: all 0.25s ease;
    --border-radius: 16px;
    --container-width: 1180px;
    --font-body: 'Manrope', 'Segoe UI', sans-serif;
    --font-display: 'Sora', 'Manrope', sans-serif;
    --hero-gradient: radial-gradient(1200px 500px at 10% -10%, rgba(15, 118, 110, 0.18), transparent 60%),
        radial-gradient(800px 400px at 100% 0%, rgba(217, 119, 6, 0.16), transparent 55%);
    --pattern-color: rgba(15, 23, 42, 0.06);
}

body.dark-mode {
    --text-color: #e5e7eb;
    --text-light: #9aa5b1;
    --bg-color: #0b1220;
    --card-bg: #111a2c;
    --border-color: #1f2a44;
    --highlight: #0f2f2b;
    --secondary-color: #0b1220;
    --glass-bg: rgba(11, 18, 32, 0.7);
    --shadow: 0 24px 45px -25px rgba(0, 0, 0, 0.6);
    --shadow-soft: 0 14px 30px rgba(0, 0, 0, 0.35);
    --pattern-color: rgba(226, 232, 240, 0.06);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    font-size: 16px;
    transition: background-color 0.3s ease, color 0.3s ease;
    position: relative;
    min-height: 100vh;
    overflow-x: hidden;
}

body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image: var(--hero-gradient);
    z-index: -2;
    pointer-events: none;
}

body::after {
    content: '';
    position: fixed;
    inset: 0;
    background-image: linear-gradient(120deg, var(--pattern-color) 1px, transparent 1px),
        linear-gradient(0deg, var(--pattern-color) 1px, transparent 1px);
    background-size: 120px 120px;
    opacity: 0.35;
    z-index: -3;
    pointer-events: none;
}

h1, h2, h3, h4 {
    font-family: var(--font-display);
    letter-spacing: -0.02em;
}

h1 {
    letter-spacing: -0.03em;
}

a {
    text-decoration: none;
    color: var(--primary-color);
    transition: var(--transition);
}

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

a:focus-visible,
button:focus-visible {
    outline: 2px solid var(--accent-color);
    outline-offset: 3px;
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
}

.container {
    width: 90%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 1.5rem;
}

.section {
    padding: var(--section-padding);
    position: relative;
    scroll-margin-top: 90px;
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-header h2 {
    font-size: 2.6rem;
    font-weight: 700;
    margin-bottom: 1rem;
    position: relative;
    display: inline-block;
}

.section-divider {
    height: 4px;
    width: 70px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    margin: 0 auto;
    border-radius: 999px;
}

.btn {
    display: inline-block;
    padding: 0.85rem 2.1rem;
    border-radius: 999px;
    font-weight: 600;
    font-size: 1rem;
    transition: var(--transition);
    cursor: pointer;
    text-align: center;
    border: 1px solid transparent;
    text-decoration: none;
}

.primary {
    background: linear-gradient(135deg, var(--primary-color), #14b8a6);
    color: white;
    text-decoration: none;
    box-shadow: 0 14px 28px rgba(15, 118, 110, 0.25);
}

.primary:hover {
    background: linear-gradient(135deg, var(--primary-hover), #0d9488);
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 18px 30px rgba(15, 118, 110, 0.35);
}

.secondary {
    background-color: rgba(15, 118, 110, 0.08);
    border: 1px solid rgba(15, 118, 110, 0.4);
    color: var(--primary-color);
    text-decoration: none;
}

.secondary:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 16px 26px rgba(15, 118, 110, 0.25);
}

.highlight {
    color: var(--primary-color);
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: var(--glass-bg);
    backdrop-filter: blur(5px);
    border-bottom: 1px solid var(--border-color);
    box-shadow: var(--shadow-soft);
    z-index: 1000;
    transition: var(--transition);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.1rem 1.5rem;
}

.logo {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--primary-color);
    letter-spacing: -0.02em;
}

.nav-links {
    display: flex;
    gap: 1.8rem;
}

.nav-links a {
    color: var(--text-color);
    font-weight: 600;
    position: relative;
}

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

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    transition: width 0.3s ease;
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

.theme-switch {
    cursor: pointer;
    font-size: 1.1rem;
    color: var(--text-color);
    transition: var(--transition);
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    width: 42px;
    height: 42px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-soft);
    font: inherit;
    appearance: none;
    position: relative;
    z-index: 1001;
}

.theme-switch:hover {
    color: var(--primary-color);
    transform: translateY(-2px);
}

.hamburger {
    display: none;
    cursor: pointer;
    background: transparent;
    border: 0;
    padding: 0;
    font: inherit;
    appearance: none;
    position: relative;
    z-index: 1001;
}

.bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px auto;
    transition: var(--transition);
    background-color: var(--text-color);
}

/* Hero Section */
.hero {
    padding: 8.5rem 0 2rem;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -120px;
    right: -200px;
    width: 480px;
    height: 480px;
    background: radial-gradient(circle, rgba(15, 118, 110, 0.18), transparent 65%);
    z-index: -1;
}

.hero .container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 2rem;
}

.hero-content {
    max-width: 520px;
}

.hero-content h1 {
    font-size: 3.7rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

.hero-content h2 {
    font-size: 1.8rem;
    font-weight: 500;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
}

.hero-content p {
    font-size: 1.15rem;
    margin-bottom: 2rem;
    color: var(--text-light);
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
}

.hero-social {
    display: flex;
    gap: 1.5rem;
}

.hero-social a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: rgba(15, 118, 110, 0.12);
    color: var(--primary-color);
    border: 1px solid rgba(15, 118, 110, 0.25);
    font-size: 1.2rem;
    transition: var(--transition);
    box-shadow: var(--shadow-soft);
}

.hero-social a:hover {
    background-color: var(--primary-hover);
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 16px 26px rgba(15, 118, 110, 0.25);
}

.hero-image {
    position: relative;
    animation: float 6s ease-in-out infinite;
    max-width: 320px;
    margin: 0 auto;
}

.hero-image::after {
    content: '';
    position: absolute;
    bottom: -10%;
    left: 50%;
    transform: translateX(-50%);
    width: 80%;
    height: 20px;
    background: radial-gradient(ellipse at center, rgba(0, 0, 0, 0.2) 0%, rgba(0, 0, 0, 0) 70%);
    border-radius: 50%;
    filter: blur(8px);
    z-index: -1;
    animation: shadow 6s ease-in-out infinite;
}

.hero-image img {
    border-radius: 26px;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-soft);
    transition: var(--transition);
}

.hero-image img:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow);
}

@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-20px);
    }
}

@keyframes shadow {
    0%, 100% {
        opacity: 0.8;
        transform: translateX(-50%) scale(1);
    }
    50% {
        opacity: 0.4;
        transform: translateX(-50%) scale(0.8);
    }
}

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

/* Scroll Reveal Animations */
[data-reveal],
[data-stagger-item] {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

body:not(.reveal-ready) [data-reveal],
body:not(.reveal-ready) [data-stagger-item] {
    opacity: 1;
    transform: none;
}

[data-reveal].is-visible {
    opacity: 1;
    transform: translateY(0);
}

[data-stagger].is-visible [data-stagger-item] {
    opacity: 1;
    transform: translateY(0);
}

/* About Section */
.about.section {
    background-color: var(--bg-color);
    padding: 2rem 0;
}

.about-content {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 3rem;
}

.about-info p {
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

.about-details {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 2rem;
}

.detail {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.detail i {
    color: var(--primary-color);
    font-size: 1.2rem;
}

.about-buttons {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
}

.about-buttons .btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.about-buttons .btn i {
    font-size: 1.1rem;
}

.core-competencies {
    background: linear-gradient(180deg, var(--card-bg), rgba(15, 118, 110, 0.05));
    padding: 2rem;
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-soft);
}

.core-competencies h3 {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
}

.core-competencies ul li {
    position: relative;
    padding-left: 1.5rem;
    margin-bottom: 1rem;
}

.core-competencies ul li:before {
    content: '•';
    color: var(--primary-color);
    font-size: 1.5rem;
    position: absolute;
    left: 0;
    top: -5px;
}

/* Skills and Experience Section */
.skills-experience {
    background-color: var(--bg-color);
    padding: 2rem 0;
}

.skills-experience-content {
    display: flex;
    flex-direction: column;
    gap: 3rem;
}

.skills-column, .experience-column {
    background-color: var(--card-bg);
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-soft);
    padding: 2rem;
    width: 100%;
}

.column-header {
    margin-bottom: 2rem;
}

.column-header h3 {
    font-size: 1.6rem;
    position: relative;
    padding-bottom: 0.5rem;
    color: var(--text-color);
}

.column-header h3:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 3px;
    background-color: var(--primary-color);
}

.skill-category {
    margin-bottom: 1.5rem;
}

.skill-category:last-child {
    margin-bottom: 0;
}

.skill-category h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--text-color);
}

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

.skill-tag {
    background-color: rgba(15, 118, 110, 0.08);
    border: 1px solid rgba(15, 118, 110, 0.2);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.9rem;
    color: var(--text-color);
    transition: var(--transition);
}

.skill-tag:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-soft);
}

.experience-column {
    background-color: var(--card-bg);
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-soft);
    padding: 2rem;
    width: 100%;
    position: relative;
    overflow: visible;
}

.timeline {
    position: relative;
    padding-left: 2.5rem;
    margin-top: 0.5rem;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 9px;
    top: 10px;
    height: calc(100% - 20px);
    width: 3px;
    background: linear-gradient(180deg, var(--primary-color), rgba(15, 118, 110, 0.15));
    border-radius: 5px;
}

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

.timeline-item:last-child {
    margin-bottom: 0;
}

.timeline-dot {
    position: absolute;
    left: -2.5rem;
    top: 10px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background-color: var(--primary-color);
    border: 4px solid var(--card-bg);
    z-index: 2;
    box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.2);
}

.timeline-content {
    background-color: var(--card-bg);
    border-radius: var(--border-radius);
    padding: 1.5rem 1.8rem;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-soft);
    transition: var(--transition);
    margin-bottom: 0;
}

.timeline-content:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
}

.timeline-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.8rem;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.timeline-header h3 {
    font-size: 1.3rem;
    color: var(--text-color);
    margin-right: 1rem;
}

.timeline-date {
    font-size: 0.9rem;
    color: var(--text-light);
    background-color: rgba(15, 118, 110, 0.12);
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    display: inline-block;
}

.timeline-content h4 {
    margin-bottom: 0.5rem;
    color: var(--primary-color);
    font-size: 1.1rem;
}

.timeline-location {
    font-size: 0.9rem;
    margin-bottom: 1rem;
    color: var(--text-light);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.timeline-location i {
    color: var(--primary-color);
    font-size: 1rem;
}

.tech-environment {
    background-color: rgba(15, 118, 110, 0.08);
    border: 1px solid rgba(15, 118, 110, 0.2);
    padding: 0.8rem 1rem;
    border-radius: var(--border-radius);
    font-size: 0.9rem;
    margin: 1rem 0;
    color: var(--text-color);
}

.timeline-description {
    padding-left: 1.2rem;
    margin-bottom: 0;
}

.timeline-description li {
    margin-bottom: 0.5rem;
    position: relative;
}

.timeline-description li:before {
    content: '•';
    color: var(--primary-color);
    position: absolute;
    left: -1.2rem;
    top: -3px;
    font-size: 1.2rem;
}

/* Projects Section */
.projects {
    background-color: var(--bg-color);
    padding-top: 2rem;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2.2rem;
}

.project-card {
    background-color: var(--card-bg);
    border-radius: var(--border-radius);
    overflow: hidden;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-soft);
    transition: var(--transition);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.project-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow);
}

.project-image {
    position: relative;
    overflow: hidden;
    height: 210px;
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.project-image:hover img {
    transform: scale(1.05);
}

.project-content {
    padding: 1.5rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.project-content h3 {
    font-size: 1.3rem;
    margin-bottom: 0.8rem;
    color: var(--text-color);
}

.project-description-text {
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
    color: var(--text-light);
}

.project-description {
    margin-bottom: 1.5rem;
    padding-left: 1.2rem;
}

.project-description li {
    margin-bottom: 0.5rem;
    position: relative;
    font-size: 0.9rem;
}

.project-description li:before {
    content: '•';
    color: var(--primary-color);
    position: absolute;
    left: -1.2rem;
    top: -3px;
    font-size: 1.2rem;
}

.project-links {
    margin-top: auto;
    display: flex;
    gap: 1rem;
}

.project-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--primary-color);
    transition: var(--transition);
}

.project-link:hover {
    color: var(--accent-color);
    transform: translateX(5px);
}

/* Show More Button */
.show-more-btn {
    background: none;
    border: none;
    color: var(--primary-color);
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    padding: 0.5rem 0;
    margin-top: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: var(--transition);
}

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

.show-more-btn i {
    font-size: 0.8rem;
    transition: var(--transition);
}

.project-description-expandable {
    margin-top: 0.5rem;
    animation: fadeIn 0.3s ease-in-out;
}

/* Contact Section */
.contact {
    background-color: var(--bg-color);
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
}

.contact-info {
    background-color: var(--card-bg);
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-soft);
    padding: 2rem;
}

.contact-item {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
}

.contact-item i {
    font-size: 1.5rem;
    color: var(--primary-color);
}

.contact-item h3 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    color: var(--text-color);
}

.contact-item p a {
    color: var(--text-light);
}

.contact-social {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
}

.contact-social a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: rgba(15, 118, 110, 0.12);
    color: var(--primary-color);
    border: 1px solid rgba(15, 118, 110, 0.25);
    font-size: 1.2rem;
    transition: var(--transition);
    box-shadow: var(--shadow-soft);
}

.contact-social a:hover {
    background-color: var(--primary-hover);
    color: white;
    transform: translateY(-5px);
    box-shadow: 0 16px 26px rgba(15, 118, 110, 0.25);
}

.contact-form {
    background-color: var(--card-bg);
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-soft);
    padding: 2rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-color);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 0.8rem;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    background-color: transparent;
    color: var(--text-color);
    font-family: var(--font-body);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.15);
}

.form-response {
    margin-top: 1rem;
    padding: 0.8rem;
    border-radius: var(--border-radius);
    font-size: 0.9rem;
    display: none;
}

.form-response.success {
    display: block;
    background-color: rgba(16, 185, 129, 0.1);
    color: #10b981;
    border: 1px solid #10b981;
}

.form-response.error {
    display: block;
    background-color: rgba(239, 68, 68, 0.1);
    color: #ef4444;
    border: 1px solid #ef4444;
}

/* Footer */
.footer {
    background: linear-gradient(135deg, var(--secondary-color), #0b3d3a);
    color: white;
    padding: 2rem 0;
    margin-top: 3rem;
}

.footer-content {
    display: flex;
    justify-content: center;
    align-items: center;
}

.footer-social {
    display: flex;
    gap: 1rem;
}

.footer-social a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.1);
    color: white;
    font-size: 1.2rem;
    transition: var(--transition);
}

.footer-social a:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateY(-3px);
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 45px;
    height: 45px;
    background: linear-gradient(135deg, var(--primary-color), #14b8a6);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 99;
    box-shadow: var(--shadow-soft);
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background: linear-gradient(135deg, var(--primary-hover), #0d9488);
    transform: translateY(-5px);
}

/* Media Queries */
@media (max-width: 992px) {
    .hero-content h1 {
        font-size: 3rem;
    }

    .hero-content h2 {
        font-size: 1.6rem;
    }

    .about-content {
        grid-template-columns: 1fr;
    }

    .contact-content {
        grid-template-columns: 1fr;
    }

    .hero-image {
        max-width: 250px;
    }

    .section {
        padding: 4rem 0 2rem;
    }
}

@media (max-width: 768px) {
    :root {
        --section-padding: 3rem 0 2rem;
    }

    .hero {
        padding: 7rem 0 2rem;
    }

    .hero .container {
        grid-template-columns: 1fr;
    }

    .hero-content {
        order: 1;
        text-align: center;
    }

    .hero-content h1 {
        font-size: 2.5rem;
    }

    .hero-content h2 {
        font-size: 1.5rem;
    }

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

    .hero-social {
        justify-content: center;
    }

    .hero-image {
        order: 0;
        margin: 0 auto 2rem;
        max-width: 200px;
    }

    .hamburger {
        display: block;
    }

    .hamburger.active .bar:nth-child(2) {
        opacity: 0;
    }

    .hamburger.active .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }

    .hamburger.active .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }

    .nav-links {
        position: fixed;
        top: 60px;
        left: 0;
        width: 100%;
        height: auto;
        background-color: var(--glass-bg);
        backdrop-filter: blur(14px) saturate(140%);
        -webkit-backdrop-filter: blur(14px) saturate(140%);
        border-bottom: 1px solid var(--border-color);
        flex-direction: column;
        text-align: center;
        padding: 1.75rem 0 2rem;
        gap: 1.5rem;
        transition: transform 0.3s ease, opacity 0.3s ease;
        box-shadow: var(--shadow-soft);
        z-index: 900;
        transform: translateY(-140%);
        opacity: 0;
        pointer-events: none;
    }

    .nav-links.active {
        transform: translateY(0);
        opacity: 1;
        pointer-events: auto;
    }

    .skills-experience-content {
        grid-template-columns: 1fr;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .footer-content {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .timeline::before {
        left: 8px;
    }
}

@media (max-width: 576px) {
    :root {
        --section-padding: 2.5rem 0 1.5rem;
    }

    .hero-content h1 {
        font-size: 2rem;
    }

    .hero-content h2 {
        font-size: 1.3rem;
    }

    .section-header h2 {
        font-size: 2rem;
    }

    .timeline {
        padding-left: 2rem;
    }

    .timeline-dot {
        left: -2rem;
        width: 16px;
        height: 16px;
        border-width: 3px;
        top: 8px;
    }

    .timeline::before {
        left: 7px;
        top: 8px;
        height: calc(100% - 16px);
    }

    .timeline-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .tech-environment {
        padding: 0.6rem 0.8rem;
    }

        .timeline-content {
        padding: 1.2rem;
        border-left-width: 3px;
    }
}

/* Project Image Overlay */
.project-image {
    position: relative;
    cursor: pointer;
    overflow: hidden;
}

.image-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(15, 118, 110, 0.95), rgba(217, 119, 6, 0.85));
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    color: white;
    font-weight: 500;
}

.image-overlay i {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.image-overlay span {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.project-image:hover .image-overlay {
    opacity: 1;
}

/* Lightbox Styles */
.lightbox-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.lightbox-overlay.active {
    opacity: 1;
    visibility: visible;
}

.lightbox-container {
    position: relative;
    width: 90%;
    max-width: 1200px;
    height: 90%;
    display: flex;
    flex-direction: column;
    background: var(--card-bg);
    border-radius: var(--border-radius);
    overflow: hidden;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    transition: background-color 0.3s ease;
}

.lightbox-close:hover {
    background: rgba(0, 0, 0, 0.9);
}

.lightbox-content {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.lightbox-image-container {
    position: relative;
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #000;
    padding: 20px;
}

.lightbox-image-container img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: var(--border-radius);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

/* Special handling for mobile screenshots */
.lightbox-container.mobile-gallery .lightbox-image-container {
    background: linear-gradient(135deg, #0f766e 0%, #14b8a6 100%);
    padding: 40px;
}

/* Special handling for hardware/IoT projects */
.lightbox-container.hardware-gallery .lightbox-image-container {
    background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
    padding: 30px;
}

.lightbox-container.hardware-gallery .lightbox-image-container img {
    border-radius: 12px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.6);
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.lightbox-container.mobile-gallery .lightbox-image-container img {
    max-width: 400px;
    max-height: 80vh;
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.7);
    border: 3px solid rgba(255, 255, 255, 0.1);
    position: relative;
}

/* Add a subtle phone frame effect */
.lightbox-container.mobile-gallery .lightbox-image-container::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 420px;
    height: calc(80vh + 40px);
    max-height: calc(100% - 60px);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 25px;
    pointer-events: none;
    z-index: -1;
}

/* Phone notch effect (optional subtle detail) */
.lightbox-container.mobile-gallery .lightbox-image-container::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 430px;
    height: calc(80vh + 50px);
    max-height: calc(100% - 50px);
    background: rgba(255, 255, 255, 0.02);
    border-radius: 30px;
    pointer-events: none;
    z-index: -2;
}

/* Desktop view - show mobile screenshots elegantly */
@media (min-width: 1200px) {
    .lightbox-container.mobile-gallery .lightbox-image-container img {
        max-width: 350px;
        max-height: 70vh;
    }

    .lightbox-container.mobile-gallery .lightbox-image-container::before {
        width: 370px;
        height: calc(70vh + 40px);
    }

    .lightbox-container.mobile-gallery .lightbox-image-container::after {
        width: 380px;
        height: calc(70vh + 50px);
    }
}

@media (min-width: 768px) and (max-width: 1199px) {
    .lightbox-container.mobile-gallery .lightbox-image-container img {
        max-width: 320px;
        max-height: 65vh;
    }

    .lightbox-container.mobile-gallery .lightbox-image-container::before {
        width: 340px;
        height: calc(65vh + 40px);
    }

    .lightbox-container.mobile-gallery .lightbox-image-container::after {
        width: 350px;
        height: calc(65vh + 50px);
    }
}

.lightbox-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.7);
    color: white;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s ease, opacity 0.3s ease;
    z-index: 5;
}

.lightbox-btn:hover {
    background: rgba(0, 0, 0, 0.9);
}

.lightbox-prev {
    left: 20px;
}

.lightbox-next {
    right: 20px;
}

.lightbox-info {
    padding: 1.5rem;
    background: var(--card-bg);
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--border-color);
}

.lightbox-info h3 {
    margin: 0;
    color: var(--text-color);
    font-size: 1.2rem;
    font-weight: 600;
}

.lightbox-counter {
    color: var(--text-light);
    font-size: 0.9rem;
    font-weight: 500;
}

.lightbox-dots {
    padding: 1rem 1.5rem;
    background: var(--card-bg);
    display: flex;
    justify-content: center;
    gap: 10px;
    border-top: 1px solid var(--border-color);
}

.lightbox-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--border-color);
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.lightbox-dot.active {
    background: var(--primary-color);
    transform: scale(1.2);
}

.lightbox-dot:hover {
    background: var(--primary-hover);
}

/* Mobile Responsive Lightbox */
@media (max-width: 768px) {
    .lightbox-container {
        width: 95%;
        height: 95%;
    }

    .lightbox-close {
        top: 15px;
        right: 15px;
        width: 35px;
        height: 35px;
        font-size: 16px;
    }

    .lightbox-btn {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }

    .lightbox-prev {
        left: 10px;
    }

    .lightbox-next {
        right: 10px;
    }

    .lightbox-info {
        padding: 1rem;
        flex-direction: column;
        gap: 0.5rem;
        text-align: center;
    }

    .lightbox-dots {
        padding: 0.75rem 1rem;
    }

    .lightbox-dot {
        width: 10px;
        height: 10px;
    }
}

@media (max-width: 576px) {
    .lightbox-container {
        width: 100%;
        height: 100%;
        border-radius: 0;
    }

    .lightbox-close {
        top: 10px;
        right: 10px;
        width: 30px;
        height: 30px;
        font-size: 14px;
    }

    .lightbox-btn {
        width: 35px;
        height: 35px;
        font-size: 14px;
    }

    .lightbox-prev {
        left: 5px;
    }

    .lightbox-next {
        right: 5px;
    }

    .image-overlay i {
        font-size: 1.5rem;
    }

    .image-overlay span {
        font-size: 0.8rem;
    }

    /* Mobile screenshots on mobile devices */
    .lightbox-container.mobile-gallery .lightbox-image-container {
        padding: 10px;
        background: linear-gradient(135deg, #0f766e 0%, #14b8a6 100%);
    }

    .lightbox-container.mobile-gallery .lightbox-image-container img {
        max-width: calc(100% - 20px);
        max-height: 75vh;
        border-radius: 15px;
    }
}

.simple-page .simple-nav {
    position: sticky;
    top: 0;
    z-index: 10;
    background: var(--glass-bg);
    backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--border-color);
}

.simple-page .simple-nav .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 0;
    gap: 1rem;
}

.simple-page .simple-logo {
    font-family: var(--font-display);
    font-weight: 700;
    color: var(--text-color);
    font-size: 1.1rem;
}

.simple-page .simple-links {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.simple-page .simple-content {
    padding: 3.5rem 0 5rem;
}

.simple-page .simple-content h1 {
    font-size: 2.2rem;
    margin-bottom: 0.5rem;
}

.simple-page .updated {
    color: var(--text-light);
    margin-bottom: 1.5rem;
}

.simple-page .simple-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-soft);
    padding: 1.75rem;
}

.simple-page .simple-card h2 {
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
    font-size: 1.2rem;
}

.simple-page .simple-card h2:first-of-type {
    margin-top: 0;
}

.simple-page .simple-card ul {
    list-style: disc;
    margin-left: 1.25rem;
}

.simple-page .simple-card li {
    margin-bottom: 0.5rem;
}

.simple-page .simple-meta {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-top: 1rem;
}

.simple-page .simple-meta span {
    background: var(--highlight);
    color: var(--text-color);
    padding: 0.35rem 0.75rem;
    border-radius: 999px;
    font-size: 0.95rem;
}

.simple-page .simple-meta a {
    background: var(--highlight);
    color: var(--text-color);
    padding: 0.35rem 0.75rem;
    border-radius: 999px;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.simple-page .simple-meta a:hover {
    color: var(--primary-color);
}

@media (max-width: 768px) {
    .simple-page .simple-nav .container {
        flex-direction: column;
        align-items: flex-start;
    }
}

@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }

    .hero-image {
        animation: none;
    }
}
