/* ===== CSS Variables ===== */
:root {
    --bg-dark: #1a1a2e;
    --bg-darker: #16162a;
    --bg-card: #222240;
    --accent: #16c79a;
    --accent-hover: #13b38a;
    --text-primary: #ffffff;
    --text-secondary: #b0b0c0;
    --text-muted: #7a7a8e;
    --section-alt: #0f0f23;
    --border: #2e2e4a;
    --shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    --radius: 10px;
    --transition: 0.3s ease;
}

/* ===== Reset & Base ===== */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 70px;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.7;
    overflow-x: hidden;
}

h1, h2, h3, h4 {
    font-family: 'Poppins', sans-serif;
    font-weight: 600;
    line-height: 1.3;
}

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

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

img {
    max-width: 100%;
    display: block;
}

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

.section {
    padding: 80px 0;
}

.section-alt {
    background-color: var(--section-alt);
}

.section-title {
    font-size: 2rem;
    text-align: center;
    margin-bottom: 50px;
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: var(--accent);
    margin: 12px auto 0;
    border-radius: 2px;
}

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

/* ===== Navbar ===== */
#navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: rgba(26, 26, 46, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid transparent;
    transition: border-color var(--transition), box-shadow var(--transition);
}

#navbar.scrolled {
    border-bottom-color: var(--border);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
}

.nav-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 65px;
}

.logo {
    font-family: 'Poppins', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
}

.logo span {
    color: var(--accent);
}

.logo:hover {
    color: var(--text-primary);
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 30px;
}

.nav-links a {
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
    padding: 5px 0;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: width var(--transition);
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--accent);
}

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

/* Hamburger */
.hamburger {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
    padding: 5px;
}

.hamburger span {
    display: block;
    width: 25px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: var(--transition);
}

.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

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

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* ===== Hero ===== */
#hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: 65px;
}

.hero-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 40px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 50px;
}

.hero-text {
    flex: 1;
}

.hero-greeting {
    font-size: 1.1rem;
    color: var(--accent);
    font-weight: 500;
    margin-bottom: 8px;
}

.hero-text h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.hero-text h2 {
    font-size: 1.3rem;
    color: var(--text-secondary);
    font-weight: 400;
    margin-bottom: 20px;
}

.hero-tagline {
    color: var(--text-muted);
    font-size: 1rem;
    max-width: 500px;
    margin-bottom: 30px;
}

.hero-buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

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

.profile-pic-wrapper {
    width: 280px;
    height: 280px;
    border-radius: 50%;
    border: 4px solid var(--accent);
    overflow: hidden;
    position: relative;
}

.profile-pic {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.initials-avatar {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-card);
    font-family: 'Poppins', sans-serif;
    font-size: 4rem;
    font-weight: 700;
    color: var(--accent);
}

/* ===== Buttons ===== */
.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: 6px;
    font-size: 0.95rem;
    font-weight: 600;
    font-family: 'Inter', sans-serif;
    cursor: pointer;
    transition: var(--transition);
    border: 2px solid transparent;
    text-align: center;
}

.btn-primary {
    background: var(--accent);
    color: var(--bg-dark);
    border-color: var(--accent);
}

.btn-primary:hover {
    background: var(--accent-hover);
    border-color: var(--accent-hover);
    color: var(--bg-dark);
}

.btn-outline {
    background: transparent;
    color: var(--accent);
    border-color: var(--accent);
}

.btn-outline:hover {
    background: var(--accent);
    color: var(--bg-dark);
}

/* ===== About ===== */
.about-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.about-content p {
    color: var(--text-secondary);
    margin-bottom: 16px;
    font-size: 1.02rem;
}

.about-content strong {
    color: var(--text-primary);
}

/* ===== Timeline (Education & Experience) ===== */
.timeline {
    max-width: 700px;
    margin: 0 auto;
    position: relative;
    padding-left: 30px;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 8px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--border);
}

.timeline-item {
    position: relative;
    margin-bottom: 40px;
}

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

.timeline-dot {
    position: absolute;
    left: -26px;
    top: 6px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--accent);
    border: 3px solid var(--bg-dark);
}

.section-alt .timeline-dot {
    border-color: var(--section-alt);
}

.timeline-date {
    display: inline-block;
    font-size: 0.85rem;
    color: var(--accent);
    font-weight: 500;
    margin-bottom: 6px;
}

.timeline-content h3 {
    font-size: 1.2rem;
    margin-bottom: 4px;
}

.timeline-place {
    color: var(--text-muted);
    font-size: 0.92rem;
    margin-bottom: 6px;
}

.timeline-content p:last-child {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* ===== Cards (Certifications) ===== */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
}

.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 48px 24px 28px;
    position: relative;
    transition: transform var(--transition), box-shadow var(--transition);
}

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

.card h3 {
    font-size: 1.1rem;
    margin-bottom: 6px;
}

.card-org {
    color: var(--accent);
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 4px;
}

.card-year {
    color: var(--text-muted);
    font-size: 0.85rem;
    margin-bottom: 10px;
}

.card p:last-child {
    color: var(--text-secondary);
    font-size: 0.92rem;
}

.card-badge {
    position: absolute;
    top: 16px;
    right: 16px;
    padding: 3px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.card-badge.completed {
    background: rgba(22, 199, 154, 0.15);
    color: var(--accent);
    border: 1px solid rgba(22, 199, 154, 0.3);
}

.card-badge.in-progress {
    background: rgba(255, 193, 7, 0.15);
    color: #ffc107;
    border: 1px solid rgba(255, 193, 7, 0.3);
}

/* ===== Skills ===== */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 30px;
}

.skill-category h3 {
    font-size: 1.1rem;
    margin-bottom: 14px;
    color: var(--accent);
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.tag {
    background: var(--bg-card);
    border: 1px solid var(--border);
    padding: 7px 16px;
    border-radius: 20px;
    font-size: 0.88rem;
    color: var(--text-secondary);
    transition: var(--transition);
}

.tag:hover {
    border-color: var(--accent);
    color: var(--accent);
}

/* ===== Contact ===== */
.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: start;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 28px;
}

.contact-icon {
    font-size: 1.4rem;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    flex-shrink: 0;
}

.contact-item h4 {
    font-size: 0.95rem;
    margin-bottom: 2px;
}

.contact-item p,
.contact-item a {
    font-size: 0.92rem;
    color: var(--text-secondary);
}

.contact-item a:hover {
    color: var(--accent);
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.form-note {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 4px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 6px;
    color: var(--text-primary);
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    transition: border-color var(--transition);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-muted);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent);
}

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

/* ===== Footer ===== */
#footer {
    background: var(--bg-darker);
    padding: 40px 0;
    text-align: center;
    border-top: 1px solid var(--border);
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

.footer-logo {
    font-family: 'Poppins', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
}

.footer-logo span {
    color: var(--accent);
}

.footer-links {
    display: flex;
    gap: 24px;
}

.footer-links a {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.footer-links a:hover {
    color: var(--accent);
}

.footer-copy {
    color: var(--text-muted);
    font-size: 0.85rem;
}

.footer-badge {
    color: var(--text-muted);
    font-size: 0.8rem;
}

/* ===== Scroll to Top ===== */
#scroll-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--accent);
    color: var(--bg-dark);
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
}

#scroll-top.visible {
    opacity: 1;
    visibility: visible;
}

#scroll-top:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
}

/* ===== Reveal Animation ===== */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 65px;
        left: 0;
        width: 100%;
        flex-direction: column;
        background: rgba(26, 26, 46, 0.98);
        padding: 20px 0;
        gap: 0;
        transform: translateY(-100%);
        opacity: 0;
        transition: var(--transition);
        pointer-events: none;
        border-bottom: 1px solid var(--border);
    }

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

    .nav-links li {
        text-align: center;
    }

    .nav-links a {
        display: block;
        padding: 12px 20px;
        font-size: 1rem;
    }

    .hero-container {
        flex-direction: column-reverse;
        text-align: center;
        padding: 20px;
    }

    .hero-text h1 {
        font-size: 2.2rem;
    }

    .hero-text h2 {
        font-size: 1.1rem;
    }

    .hero-tagline {
        margin-left: auto;
        margin-right: auto;
    }

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

    .profile-pic-wrapper {
        width: 200px;
        height: 200px;
    }

    .initials-avatar {
        font-size: 3rem;
    }

    .section {
        padding: 60px 0;
    }

    .section-title {
        font-size: 1.6rem;
        margin-bottom: 36px;
    }

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

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

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

@media (max-width: 480px) {
    .hero-text h1 {
        font-size: 1.8rem;
    }

    .btn {
        padding: 10px 22px;
        font-size: 0.9rem;
    }

    .profile-pic-wrapper {
        width: 160px;
        height: 160px;
    }
}
