/* --- CSS Custom Properties --- */
:root {
    --bg-color: #050505;
    --surface-color: rgba(20, 20, 20, 0.7);
    --text-primary: #ffffff;
    --text-secondary: #a0a0a0;
    --accent-1: #00f2fe;
    --accent-2: #4facfe;
    --gradient-accent: linear-gradient(135deg, var(--accent-1), var(--accent-2));
    --transition: 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    --glass-border: 1px solid rgba(255, 255, 255, 0.05);
}

/* --- Base Reset & Typography --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    overflow-x: hidden;
    line-height: 1.6;
}

ul { list-style: none; }
a { text-decoration: none; color: inherit; }

/* Canvas for Particles */
#bg-canvas {
    position: fixed;
    top: 0; left: 0;
    width: 100vw; height: 100vh;
    z-index: -1;
    pointer-events: none;
    opacity: 0.5;
}

/* Container */
.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
}

/* --- Typography Highlights --- */
h1, h2, h3 { color: var(--text-primary); }
span {
    background: var(--gradient-accent);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    -webkit-text-fill-color: transparent;
}

/* --- Components --- */
.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: 30px;
    font-weight: 600;
    letter-spacing: 0.5px;
    transition: var(--transition);
    cursor: pointer;
    font-size: 1rem;
}

.btn-primary {
    background: var(--gradient-accent);
    color: #fff;
    box-shadow: 0 4px 15px rgba(0, 242, 254, 0.3);
    border: none;
}
.btn-primary:hover {
    box-shadow: 0 6px 20px rgba(0, 242, 254, 0.5);
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    color: var(--accent-1);
    border: 2px solid var(--accent-1);
}
.btn-outline:hover {
    background: var(--gradient-accent);
    color: #fff;
    border-color: transparent;
    transform: translateY(-2px);
}

/* --- Navigation --- */
.navbar {
    position: fixed;
    top: 0; left: 0; right: 0;
    padding: 20px 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
    border-bottom: var(--glass-border);
    background: rgba(5, 5, 5, 0.8);
    transition: var(--transition);
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.8rem;
    font-weight: 700;
}

.nav-links {
    display: flex;
    gap: 30px;
}

.nav-links a {
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-secondary);
    transition: var(--transition);
}
.nav-links a:hover {
    color: var(--accent-1);
}

.btn-admin {
    background: rgba(255,255,255,0.1);
    padding: 8px 12px;
    border-radius: 5px;
}
.btn-admin:hover {
    background: var(--gradient-accent);
    color: #fff !important;
}

.menu-toggle {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
}

/* --- Hero Section --- */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: 80px;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.greeting {
    font-size: 1.2rem;
    color: var(--accent-1);
    margin-bottom: 10px;
}

.name {
    font-size: 3.5rem;
    line-height: 1.2;
    margin-bottom: 15px;
}

.title {
    font-size: 1.5rem;
    color: var(--text-secondary);
    margin-bottom: 25px;
    height: 35px; /* Fixed height for typing effect */
}

.description {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 35px;
    max-width: 500px;
}

.hero-buttons {
    display: flex;
    gap: 20px;
}

/* Hero Image & Badges */
.hero-image {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
}

.image-wrapper {
    width: 350px;
    height: 350px;
    border-radius: 50%;
    background: var(--gradient-accent);
    padding: 5px;
    position: relative;
    animation: float 6s ease-in-out infinite;
}

.placeholder-img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: var(--surface-color);
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 8rem;
    color: var(--accent-2);
}

.floating-badge {
    position: absolute;
    background: rgba(20,20,20,0.9);
    backdrop-filter: blur(5px);
    border: var(--glass-border);
    padding: 10px 20px;
    border-radius: 20px;
    font-weight: 600;
    color: #fff;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    gap: 10px;
}
.floating-badge i { color: var(--accent-1); }

.badge-1 { top: 10%; right: -20px; animation: float 5s ease-in-out infinite 1s; }
.badge-2 { bottom: 10%; left: -20px; animation: float 7s ease-in-out infinite 2s; }

/* --- Section Titles --- */
.section-title {
    text-align: center;
    margin-bottom: 60px;
}
.section-title h2 { font-size: 2.5rem; margin-bottom: 10px; }
.section-title p { color: var(--text-secondary); }

/* --- Experiences Section --- */
.experience { padding: 100px 0; }
.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}
.timeline::after {
    content: '';
    position: absolute;
    width: 2px;
    background: rgba(255,255,255,0.1);
    top: 0; bottom: 0; left: 50%;
    margin-left: -1px;
}
.timeline-item {
    padding: 10px 40px;
    position: relative;
    background: inherit;
    width: 50%;
}
.timeline-item:nth-child(odd) { left: 0; text-align: right; }
.timeline-item:nth-child(even) { left: 50%; }

.timeline-dot {
    width: 20px; height: 20px;
    background: var(--accent-1);
    border: 4px solid var(--bg-color);
    position: absolute;
    border-radius: 50%;
    top: 20px; right: -10px;
    z-index: 1;
    box-shadow: 0 0 10px var(--accent-1);
}
.timeline-item:nth-child(even) .timeline-dot { left: -10px; }

.timeline-content {
    padding: 30px;
    background: var(--surface-color);
    border-radius: 15px;
    border: var(--glass-border);
    transition: var(--transition);
}
.timeline-content:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    border-color: rgba(0, 242, 254, 0.3);
}

.timeline-date {
    display: inline-block;
    padding: 5px 15px;
    background: rgba(0, 242, 254, 0.1);
    color: #ffffff;
    -webkit-text-fill-color: #ffffff; /* Override global span style */
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 15px;
    white-space: normal;
    word-break: break-word;
}
.timeline-content h3 { font-size: 1.3rem; margin-bottom: 5px; }
.timeline-content h4 { color: var(--text-secondary); font-weight: 400; font-size: 1rem; margin-bottom: 15px; }
.timeline-content p { color: #ccc; font-size: 0.95rem; }

/* --- Projects Section --- */
.projects {
    padding: 100px 0;
    background: rgba(10,10,10,0.5);
}
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.project-card {
    background: var(--surface-color);
    border-radius: 20px;
    overflow: hidden;
    border: var(--glass-border);
    transition: var(--transition);
    position: relative;
    display: flex;
    flex-direction: column;
}
.project-card:hover {
    transform: translateY(-10px);
    border-color: var(--accent-2);
    box-shadow: 0 15px 40px rgba(0,0,0,0.4);
}

.project-img {
    height: 200px;
    background: linear-gradient(45deg, #1a1a1a, #2a2a2a);
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 4rem;
    color: var(--text-secondary);
    transition: var(--transition);
}
.project-card:hover .project-img { color: var(--accent-1); }

.project-info {
    padding: 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}
.project-info h3 { font-size: 1.4rem; margin-bottom: 15px; }
.project-info p { color: var(--text-secondary); font-size: 0.95rem; margin-bottom: 25px; flex-grow: 1; }

.project-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--accent-1);
    font-weight: 600;
    margin-top: auto;
    transition: var(--transition);
}
.project-link:hover { color: #fff; gap: 12px; }

/* --- Blog Section --- */
.blog { padding: 100px 0; }
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}
.blog-card {
    background: var(--surface-color);
    border: var(--glass-border);
    border-radius: 20px;
    padding: 30px;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}
.blog-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 4px; height: 100%;
    background: var(--gradient-accent);
    opacity: 0;
    transition: var(--transition);
}
.blog-card:hover {
    transform: translateY(-5px);
    border-color: rgba(0, 242, 254, 0.3);
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}
.blog-card:hover::before { opacity: 1; }

.blog-tag {
    display: inline-block;
    padding: 6px 14px;
    background: rgba(0, 242, 254, 0.15);
    color: var(--accent-1);
    -webkit-text-fill-color: var(--accent-1); /* Override global span style */
    background-clip: padding-box; /* Override global span style */
    border-radius: 10px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 15px;
    border: 1px solid rgba(0, 242, 254, 0.2);
}
.blog-content h3 { margin-bottom: 10px; font-size: 1.3rem; }
.blog-content p { color: var(--text-secondary); font-size: 0.95rem; margin-bottom: 20px; }
.blog-link {
    color: var(--text-primary);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
}
.blog-link:hover { color: var(--accent-1); gap: 12px; }

/* --- Footer --- */
.footer {
    padding: 80px 0 30px;
    border-top: var(--glass-border);
    background: linear-gradient(to top, rgba(0,242,254,0.05) 0%, transparent 100%);
}
.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 60px;
}
.footer-brand h2 { font-size: 2.2rem; margin-bottom: 10px; }
.footer-brand p { color: var(--text-secondary); max-width: 400px; }

.footer-links {
    display: flex;
    gap: 20px;
}
.contact-btn {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px 25px;
    background: var(--surface-color);
    border: var(--glass-border);
    border-radius: 15px;
    font-size: 1.1rem;
    transition: var(--transition);
}
.contact-btn i { font-size: 1.5rem; }
.email-btn:hover { background: #ea4335; color: #fff; border-color: #ea4335; }
.ig-btn:hover { background: #E1306C; color: #fff; border-color: #E1306C; }

.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255,255,255,0.05);
    color: var(--text-secondary);
}
.sub-text { font-size: 0.85rem; margin-top: 5px; }

/* --- Coding Activity Section --- */
.coding-activity {
    padding: 100px 0;
    background: linear-gradient(to bottom, rgba(5,5,5,0.8), rgba(10,10,10,0.5));
}
.waka-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}
.waka-card {
    background: var(--surface-color);
    border: var(--glass-border);
    border-radius: 20px;
    padding: 35px;
    display: flex;
    align-items: center;
    gap: 25px;
    transition: var(--transition);
}
.waka-card:hover {
    transform: translateY(-5px);
    border-color: var(--accent-1);
    box-shadow: 0 10px 30px rgba(0, 242, 254, 0.1);
}
.waka-icon {
    font-size: 2.5rem;
    color: var(--accent-1);
    background: rgba(0, 242, 254, 0.1);
    width: 70px;
    height: 70px;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 15px;
}
.waka-info h3 {
    font-size: 1.1rem;
    color: var(--text-secondary);
    font-weight: 500;
    margin-bottom: 5px;
}
.waka-value {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text-primary);
}
.waka-label {
    font-size: 0.8rem;
    color: var(--text-secondary);
    display: block;
    margin-top: 5px;
}
.waka-languages {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}
.lang-badge {
    padding: 4px 10px;
    background: rgba(255,255,255,0.05);
    border: var(--glass-border);
    border-radius: 6px;
    font-size: 0.8rem;
    color: var(--accent-2);
}

/* Activity Pulse */
.waka-pulse {
    margin-top: 50px;
    padding-top: 30px;
    border-top: 1px solid rgba(255,255,255,0.05);
    text-align: center;
}
.waka-pulse h3 {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 20px;
    font-weight: 500;
}
/* Range Selector */
.waka-range-selector {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin: 20px 0 35px;
    flex-wrap: wrap;
}
.waka-month-form {
    display: flex;
    gap: 8px;
    margin-left: 10px;
}
.waka-month-form select {
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.05);
    border: var(--glass-border);
    border-radius: 12px;
    color: var(--text-primary);
    font-size: 0.85rem;
    outline: none;
    cursor: pointer;
    transition: var(--transition);
}
.waka-month-form select:hover {
    background: rgba(255, 255, 255, 0.1);
}
.waka-month-form select option {
    background: #0b1121;
    color: #fff;
}

.range-tab {
    padding: 10px 22px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-secondary);
    transition: all 0.3s ease;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}
.range-tab.active {
    background: var(--gradient-accent);
    color: #fff;
    border-color: transparent;
    box-shadow: 0 4px 15px rgba(0, 242, 254, 0.3);
}
.range-tab:hover:not(.active) {
    background: rgba(255, 255, 255, 0.15);
    color: var(--text-primary);
    transform: translateY(-2px);
    border-color: var(--accent-1);
}

.pulse-grid {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
    max-width: 900px;
    margin: 0 auto;
}

/* 30 Days specific styling */
.pulse-grid.last_30_days {
    gap: 8px;
}
.pulse-grid.last_30_days .day-dot {
    width: 25px;
    height: 25px;
    border-radius: 4px;
}
.pulse-grid.last_30_days .day-name {
    font-size: 0.65rem;
}



/* Calendar Grid Styling */
.waka-calendar-container {
    margin-top: 30px;
    padding: 25px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 20px;
    border: var(--glass-border);
}
.waka-calendar-container h4 {
    margin-bottom: 20px;
    font-size: 1.1rem;
    color: var(--text-primary);
}
.waka-calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 8px;
    text-align: center;
}
.waka-calendar-grid.seven-days {
    gap: 12px;
}

.calendar-header {
    font-weight: 600;
    color: var(--text-secondary);
    font-size: 0.8rem;
    padding-bottom: 10px;
}
.calendar-day {
    aspect-ratio: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s ease;
    cursor: help;
    position: relative;
}
.calendar-day .cal-date {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: 2px;
}
.calendar-day .cal-duration {
    font-size: 0.65rem;
    color: var(--accent-1);
    font-weight: 600;
    line-height: 1;
    margin-bottom: 2px;
}
.calendar-day .cal-dot {
    width: 6px;
    height: 6px;
    background: var(--gradient-accent);
    border-radius: 50%;
    box-shadow: 0 0 8px rgba(0, 242, 254, 0.5);
}
.calendar-day.active {
    background: rgba(0, 242, 254, 0.05);
    border-color: rgba(0, 242, 254, 0.2);
}
.calendar-day.active .cal-date {
    color: var(--text-primary);
}
.calendar-day.active .cal-dot {
    width: 6px;
    height: 6px;
    background: var(--gradient-accent);
    border-radius: 50%;
    margin-top: 4px;
    box-shadow: 0 0 8px rgba(0, 242, 254, 0.5);
}
.calendar-day.empty {
    opacity: 0.2;
    background: transparent;
    border: none;
}
.calendar-day:hover:not(.empty) {
    transform: translateY(-3px);
    background: rgba(255, 255, 255, 0.08);
}


/* --- Responsive Design --- */
@media screen and (max-width: 992px) {
    .hero-content { grid-template-columns: 1fr; text-align: center; }
    .hero-buttons { justify-content: center; }
    .hero-image { order: -1; margin-bottom: 40px; }
    .description { margin: 0 auto 35px; }
    .footer-content { flex-direction: column; text-align: center; gap: 40px; }
    .footer-brand p { margin: 0 auto; }
}

@media screen and (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 70px; right: -100%;
        flex-direction: column;
        background: rgba(10,10,10,0.95);
        backdrop-filter: blur(10px);
        width: 100%; height: calc(100vh - 70px);
        justify-content: center; align-items: center;
        transition: 0.4s ease;
    }
    .nav-links.active { right: 0; }
    .menu-toggle { display: block; }
    .name { font-size: 2.5rem; }
    .timeline::after { left: 31px; }
    .timeline-item { width: 100%; padding-left: 70px; padding-right: 0; }
    .timeline-item:nth-child(even), .timeline-item:nth-child(odd) { left: 0; text-align: left; }
    .timeline-dot { left: 21px !important; }
    .footer-links { flex-direction: column; width: 100%; max-width: 300px; margin: 0 auto; }
    
    /* Hero Image adjustment for mobile */
    .image-wrapper {
        width: 200px;
        height: 200px;
    }
    .placeholder-img {
        font-size: 4rem;
    }
    .floating-badge {
        padding: 6px 12px;
        font-size: 0.75rem;
    }
    .badge-1 { top: 5%; right: -15px; }
    .badge-2 { bottom: 5%; left: -15px; }
}
