/* About Page Specific Styles */

/* 1. Page Hero */
.about-hero {
    padding: 150px 0 80px;
    text-align: center;
    background: radial-gradient(circle at center, rgba(56, 189, 248, 0.1) 0%, transparent 70%);
}

.about-tagline {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 20px;
    background: linear-gradient(to right, #fff, #94a3b8);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.about-sub {
    font-size: 1.2rem;
    color: var(--text-muted);
    max-width: 700px;
    margin: 0 auto;
}

/* 2. Biography Section */
.bio-section {
    padding: 120px 0 60px;
    /* Increased top padding to clear the header */
}

.bio-content {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 0;
    /* Remove padding from container to let image touch edges if needed, but keeping it inside internal divs is safer. Let's keep padding 0 and contain image.*/
    display: flex;
    /* Remove gap, handle with padding */
    align-items: stretch;
    /* Stretch Items Vertically */
    overflow: hidden;
    /* Ensure image doesn't bleed out */
    flex-wrap: wrap;
    /* Allow wrap for small screens */
}

.bio-image {
    flex: 0 0 40%;
    /* Take 40% of the card width */
    margin: 0;
    /* Remove margins */
    position: relative;
    border-radius: 0;
    /* Remove circle shape */
    border: none;
    /* Remove border */
    overflow: hidden;
    min-height: 100%;
    /* Ensure it fills height */
}

.bio-text {
    flex: 1;
    /* Take remaining space */
    padding: 60px 40px;
    /* Increase vertical padding for nicer look */
    display: flex;
    flex-direction: column;
    justify-content: center;
    /* Center content vertically if image is taller */
}

.bio-text h3 {
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 20px;
}

.bio-text p {
    margin-bottom: 20px;
    color: #cbd5e1;
    font-size: 1.05rem;
}

.bio-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.bio-image:hover img {
    transform: scale(1.05);
}

/* 3. Timeline Section (Minimalist Left-Aligned) */
.timeline-section {
    padding: 80px 0;
}

.timeline-container {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
    padding-left: 50px;
    /* Space for the line */
}

/* The Neon Line (Left Side) */
.timeline-container::after {
    content: '';
    position: absolute;
    width: 2px;
    background: linear-gradient(to bottom, var(--primary), rgba(56, 189, 248, 0.1));
    top: 0;
    bottom: 0;
    left: 20px;
    /* Positioned left */
    box-shadow: 0 0 15px rgba(56, 189, 248, 0.5);
    /* Neon glow */
}

/* Timeline Rows (All Aligned Right) */
.timeline-row {
    position: relative;
    margin-bottom: 40px;
    width: 100%;
}

/* The Glowing Dots (Check-points) */
.timeline-row::after {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    left: -37px;
    /* Position on the line */
    background-color: var(--bg-color);
    border: 2px solid var(--primary);
    top: 5px;
    /* Align with title */
    border-radius: 50%;
    z-index: 2;
    box-shadow: 0 0 10px var(--primary), inset 0 0 5px var(--primary);
    transition: var(--transition);
}

.timeline-row:hover::after {
    background-color: var(--primary);
    box-shadow: 0 0 20px var(--primary);
    transform: scale(1.2);
}

/* Content Cards */
.timeline-card {
    padding: 25px 30px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    transition: var(--transition);
    position: relative;
}

/* Arrow pointing to line */
.timeline-card::before {
    content: '';
    position: absolute;
    left: -10px;
    top: 20px;
    width: 0;
    height: 0;
    border-top: 10px solid transparent;
    border-bottom: 10px solid transparent;
    border-right: 10px solid var(--glass-border);
}

.timeline-card:hover {
    transform: translateX(10px);
    border-color: var(--primary);
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
}

.timeline-card:hover::before {
    border-right-color: var(--primary);
}

.timeline-date {
    display: inline-block;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--bg-color);
    background: var(--primary);
    padding: 4px 12px;
    border-radius: 20px;
    margin-bottom: 15px;
}

.timeline-card h3 {
    font-size: 1.3rem;
    color: #fff;
    margin-bottom: 5px;
}

.timeline-card h4 {
    font-size: 1rem;
    color: var(--text-muted);
    font-style: italic;
    margin-bottom: 10px;
}

/* Responsive adjustment handled naturally by this layout */
@media (max-width: 768px) {
    .timeline-container {
        padding-left: 40px;
    }

    .timeline-container::after {
        left: 15px;
    }

    .timeline-row::after {
        left: -33px;
    }
}

/* Typewriter Effect */
.typewriter-text {
    font-size: 1.1rem;
    color: var(--primary);
    font-family: 'Courier New', monospace;
    font-weight: 600;
    margin-bottom: 20px;
    display: inline-block;
    min-height: 1.5em;
    /* Prevent layout shift */
}

.typewriter-cursor {
    display: inline-block;
    width: 2px;
    height: 1.2em;
    background-color: var(--primary);
    margin-left: 2px;
    animation: blink 1s infinite;
    vertical-align: middle;
}

@keyframes blink {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0;
    }
}

/* Mini GitHub Heatmap */
.mini-heatmap-container {
    margin-top: 20px;
    margin-bottom: 20px;
    padding: 15px;
    background: rgba(13, 19, 33, 0.6);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 15px;
    box-shadow: 0 0 20px rgba(56, 189, 248, 0.15);
    /* Blue glow */
    transition: var(--transition);
}

.mini-heatmap-container:hover {
    box-shadow: 0 0 30px rgba(56, 189, 248, 0.25);
    border-color: var(--primary);
}

.heatmap-icon {
    font-size: 2rem;
    color: var(--text-muted);
    transition: var(--transition);
}

.mini-heatmap-container:hover .heatmap-icon {
    color: #fff;
    transform: scale(1.1);
}

.heatmap-img {
    height: 35px;
    /* Slightly smaller to fit better */
    width: auto;
    opacity: 0.8;
    transition: opacity 0.3s;
    flex-grow: 1;
    /* Take available space */
}

.heatmap-img:hover {
    opacity: 1;
}

/* 6. Certificates & Badges Section (Split Card Layout) */
.cert-section {
    padding: 80px 0;
}

/* Main Card Wrapper (Mimics Bio Content) */
.cert-wrapper {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    display: flex;
    align-items: stretch;
    /* Equal height cols */
    overflow: hidden;
    /* Contain image */
}

/* Left Side: Content */
.cert-content-side {
    flex: 1;
    /* Takes remaining space (~60%) */
    padding: 40px 40px 0 40px;
    /* Remove bottom padding to let badges touch bottom */
    display: flex;
    flex-direction: column;
    height: 100%;
    /* Ensure it spans full height of grid row */
}

.cert-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    /* Slightly smaller min-width to fit */
    gap: 20px;
    margin-top: 10px;
    /* Reduced top margin */
}

.cert-item {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 15px;
    /* Compact padding */
    display: flex;
    align-items: center;
    gap: 15px;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

/* Glass shine effect on hover */
.cert-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.05), transparent);
    transition: 0.5s;
}

.cert-item:hover::before {
    left: 100%;
}

.cert-item:hover {
    background: rgba(56, 189, 248, 0.08);
    border-color: var(--primary);
    transform: translateY(-3px);
    box-shadow: 0 10px 30px -5px rgba(0, 0, 0, 0.3);
}

.cert-icon {
    font-size: 1.8rem;
    min-width: 40px;
    text-align: center;
}

.cert-info h4 {
    font-size: 1rem;
    color: #fff;
    margin-bottom: 3px;
    font-weight: 600;
}

.cert-info span {
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* Right Side: Image */
.cert-image-side {
    flex: 0 0 40%;
    /* Fixed 40% width */
    position: relative;
    border-left: 1px solid var(--glass-border);
    /* Separator line on left */
    min-height: 400px;
}

.cert-image-side img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    /* Cover the area fully */
    display: block;
    /* Remove previous tilt transforms */
    border-radius: 0;
    border: none;
    box-shadow: none;
}

/* Responsive */
@media (max-width: 900px) {
    .cert-wrapper {
        flex-direction: column;
    }

    .cert-image-side {
        width: 100%;
        border-left: none;
        border-top: 1px solid var(--glass-border);
        /* Separator on top if image is bottom, or border-bottom if image top */
        order: -1;
        /* Move image to top on mobile to act as cover */
        height: 250px;
        min-height: auto;
    }

    .cert-content-side {
        padding: 30px 20px;
    }
}

/* Badges Row Styling */
.badges-wrapper {
    margin-top: auto;
    /* Push to bottom */
    padding-top: 30px;
    padding-bottom: 30px;
    /* Add internal padding instead of container padding */
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.badges-wrapper h4 {
    font-size: 0.95rem;
    color: var(--text-muted);
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.badges-row {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.badge-img {
    width: 130px;
    height: 130px;
    object-fit: contain;
    transition: var(--transition);
    filter: drop-shadow(0 5px 15px rgba(0, 0, 0, 0.3));
}

.badge-img:hover {
    transform: scale(1.1) rotate(5deg);
    filter: drop-shadow(0 8px 20px rgba(56, 189, 248, 0.4));
}

/* Bio Integrated Skills */
.bio-skills {
    margin-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 25px;
}

.bio-skills h4 {
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
    margin-bottom: 15px;
    font-weight: 600;
}

.bio-skills-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.mini-skill-tag {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    padding: 8px 16px;
    border-radius: 6px;
    /* Slightly rounded rect for tech look */
    font-size: 0.85rem;
    color: #cbd5e1;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
    cursor: default;
}

.mini-skill-tag:hover {
    background: rgba(56, 189, 248, 0.1);
    border-color: var(--primary);
    color: #fff;
    transform: translateY(-2px);
}

.mini-skill-tag i {
    font-size: 1rem;
}

/* 6. GitHub Stats Section */
.github-section {
    padding: 60px 0;
    text-align: center;
}

.github-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
    margin-top: 30px;
}

.github-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 10px;
    transition: var(--transition);
    height: fit-content;
}

.github-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
    box-shadow: 0 10px 30px -10px rgba(56, 189, 248, 0.2);
}

.github-card img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    display: block;
}