.project-intro {
    display: flex;
    align-items: center;
    margin-top: 50px;
}

.project-image {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-right: 20px;
}

.project-image img {
    width: 300px;
    height: 300px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    clip-path: polygon(30% 0%,
            70% 0%,
            100% 30%,
            100% 70%,
            70% 100%,
            30% 100%,
            0% 70%,
            0% 30%);
}

.project-image img:hover {
    filter: grayscale(10%);
    scale: 1.05;
}

.project-image h1 {
    text-align: center;
}

.project-details {
    max-width: 600px;
}

.project-details h2 {
    font-size: 2.5rem;
    margin: 0;
    color: var(--text-primary);
}

.project-details p {
    color: var(--text-secondary, #555);
}

/* Style for the resume section */
#resume h2 {
    font-size: 2rem;
    margin-bottom: 15px;
}

#resume p {
    font-size: 1.1rem;
    margin-bottom: 10px;
}

#resume ul {
    list-style: none;
    /* Remove bullet points */
    padding-left: 0;
    margin-bottom: 20px;
}

#resume li {
    font-size: 1.1rem;
    margin-bottom: 15px;
    line-height: 1.6;
}

#resume ul ul {
    margin-top: 5px;
    margin-left: 20px;
    /* Add indentation for sublist */
    list-style-type: disc;
    /* Change sublist bullet style */
}

#resume ul ul li {
    font-size: 1rem;
    margin-bottom: 8px;
    color: var(--text-secondary, #555);
    /* Slightly different color for sublist */
}

/* CTA Button styling for resume download */
.cta-button {
    color: #fff;
    background-color: #007bff;
    padding: 5px 13px;
    border-radius: 5px;
    text-decoration: none;
    font-size: 15px;
}

.cta-button:hover {
    background-color: #0056b3;
}

#contact ul {
    list-style-type: none;
    padding-left: 0;
}

#contact ul li {
    margin-bottom: 15px;
}

#contact ul ul {
    margin-top: 5px;
    padding-left: 20px;
    list-style-type: disc;
}

#contact ul li a {
    color: #007bff;
    text-decoration: none;
}

#contact ul li a:hover {
    text-decoration: underline;
}

#about ul {
    list-style-type: none;
    padding-left: 0;
}

#about ul li {
    margin-bottom: 15px;
}

#about ul ul {
    margin-top: 5px;
    padding-left: 20px;
    list-style-type: disc;
}

#about ul li b {
    font-size: 1.2rem;
    color: var(--text-primary);
}

#about ul li ul li {
    font-size: 1rem;
    color: var(--text-secondary, #555);
}

#portfolio {
    display: flex;
    align-items: flex-start;
    /* Aligns items at the top */
    margin-top: 50px;
    gap: 20px;
}

#portfolio .project-details {
    max-width: 600px;
}

#portfolio .project-details h2 {
    font-size: 2.5rem;
    margin: 0;
}

#portfolio .project-details h3 {
    margin-top: 20px;
    font-size: 1.8rem;
}

#portfolio .project-details p {
    /* font-size: 1.2rem; */
    margin: 10px 0;
    color: var(--text-secondary, #555);
    text-align: justify;
}

#portfolio ul {
    list-style-type: none;
    padding-left: 0;
}

#portfolio ul li {
    margin-bottom: 15px;
}

#portfolio ul ul {
    margin-top: 5px;
    padding-left: 20px;
    list-style-type: disc;
}

#portfolio ul li b {
    font-size: 1.2rem;
    color: var(--text-primary);
}

#portfolio ul li ul li {
    font-size: 1rem;
    color: var(--text-secondary, #555);
}

.carousel-main h3 {
    text-align: center;
    font-size: 1.8rem;
}

.project-carousel {
    display: flex;
    align-items: center;
    width: 100%;
    position: relative;
    scrollbar-width: thin;
    /* for Firefox */
    scrollbar-color: rgba(255, 255, 255, 0.6) transparent;
}

/* ✅ For Chrome, Edge, Safari */
.project-carousel::-webkit-scrollbar {
    width: 2px;
}

.project-carousel::-webkit-scrollbar-track {
    background: transparent;
    /* transparent track */
}

.project-carousel::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.4);
    /* semi-transparent thumb */
    border-radius: 4px;
}

.project-carousel::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.6);
}

.carousel-track-wrapper {
    overflow-x: auto;
    /* Allows horizontal scrolling */
    scroll-behavior: smooth;
    /* Smooth scrolling */
    width: 80%;
    padding: 10px;
    margin: 0 2px;
}

.carousel-track {
    display: flex;
}

.carousel-card {
    flex: 0 0 25%;
    /* Display 4 cards at a time, each 25% of the container */
    width: 250px;
    height: 250px;
    padding: 20px;
    background-color: var(--card-bg);
    color: var(--text-primary);
    border: 1px solid var(--border-color, #ddd);
    border-radius: 8px;
    text-align: center;
    box-sizing: border-box;
    margin-right: 10px;
    cursor: pointer;
    overflow-y: hidden;
}

.carousel-card>div {
    display: grid;
}

.carousel-card>div img {
    width: 100%;
}

.carousel-button {
    background-color: #333;
    color: #fff;
    border: none;
    padding: 10px 20px;
    cursor: pointer;
    font-size: 16px;
    border-radius: 5px;
}

.carousel-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Key Projects Kanban */
#key-projects {
    margin: 56px auto 28px;
}

.key-projects-main {
    width: min(96%, 1280px);
    margin: 0 auto;
    padding: 28px 22px 24px;
    border-radius: 22px;
    background:
        radial-gradient(130% 120% at 0% 0%, rgba(255, 86, 154, 0.1), transparent 58%),
        radial-gradient(130% 120% at 100% 100%, rgba(56, 189, 248, 0.1), transparent 58%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(255, 255, 255, 0.01));
    border: 1px solid rgba(255, 255, 255, 0.06);
    box-shadow: 0 22px 48px rgba(0, 0, 0, 0.16);
}

.key-projects-main>h3 {
    text-align: center;
    font-size: 2.1rem;
    margin: 0 0 16px;
}

.key-projects-board {
    display: grid;
    gap: 16px;
}

.key-projects-board__meta {
    display: flex;
    justify-content: center;
}

.key-projects-board__meta p {
    margin: 0;
    padding: 10px 16px;
    border-radius: 999px;
    font-size: 0.92rem;
    color: var(--text-secondary, #9ca3af);
    border: 1px solid rgba(255, 255, 255, 0.07);
    background: rgba(255, 255, 255, 0.02);
}

.key-projects-kanban {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    align-items: start;
}

.kanban-column {
    position: relative;
    margin: 0;
    min-width: 0;
    border-radius: 18px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    background: rgba(255, 255, 255, 0.015);
    overflow: hidden;
}

.kanban-column > * + * {
    margin-block-start: 0;
}

.kanban-column::before {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background:
        linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
    background-size: 18px 18px;
    opacity: 0.4;
}

.kanban-column--shipped {
    box-shadow: inset 0 1px 0 rgba(74, 222, 128, 0.07);
}

.kanban-column--building {
    box-shadow: inset 0 1px 0 rgba(250, 204, 21, 0.08);
}

.kanban-column--planned {
    box-shadow: inset 0 1px 0 rgba(96, 165, 250, 0.08);
}

.kanban-column__header {
    position: relative;
    z-index: 1;
    display: flex;
    justify-content: space-between;
    gap: 10px;
    padding: 14px 14px 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    background: rgba(255, 255, 255, 0.02);
}

.kanban-column__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.04em;
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.03);
}

.kanban-column__eyebrow ion-icon {
    font-size: 14px;
}

.kanban-column--shipped .kanban-column__eyebrow {
    color: #bbf7d0;
    border-color: rgba(34, 197, 94, 0.2);
    background: rgba(34, 197, 94, 0.08);
}

.kanban-column--building .kanban-column__eyebrow {
    color: #fde68a;
    border-color: rgba(245, 158, 11, 0.2);
    background: rgba(245, 158, 11, 0.08);
}

.kanban-column--planned .kanban-column__eyebrow {
    color: #bfdbfe;
    border-color: rgba(59, 130, 246, 0.2);
    background: rgba(59, 130, 246, 0.08);
}

.kanban-column__header p {
    margin: 8px 0 0;
    font-size: 0.85rem;
    line-height: 1.35;
    color: var(--text-secondary, #9ca3af);
}

.kanban-column__count {
    display: inline-grid;
    place-items: center;
    min-width: 34px;
    height: 34px;
    border-radius: 10px;
    font-weight: 700;
    color: var(--text-primary);
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(255, 255, 255, 0.03);
}

.kanban-column__cards {
    position: relative;
    z-index: 1;
    display: grid;
    gap: 12px;
    padding: 14px;
    align-content: start;
    min-height: 220px;
}

.kanban-project-card {
    display: grid;
    gap: 10px;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.07);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.015));
    box-shadow: 0 12px 22px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.kanban-project-card:hover {
    transform: translateY(-3px);
    border-color: rgba(255, 255, 255, 0.14);
    box-shadow: 0 14px 26px rgba(0, 0, 0, 0.14);
}

.kanban-project-card__media {
    all: unset;
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    cursor: pointer;
    background: #0f172a;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.kanban-project-card__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.kanban-project-card__placeholder {
    width: 100%;
    height: 100%;
    display: grid;
    place-items: center;
    color: rgba(255, 255, 255, 0.55);
    background:
        radial-gradient(circle at 20% 20%, rgba(255, 86, 154, 0.12), transparent 60%),
        radial-gradient(circle at 80% 80%, rgba(56, 189, 248, 0.14), transparent 60%),
        linear-gradient(180deg, #111827, #0f172a);
}

.kanban-project-card__placeholder i {
    font-size: 1.5rem;
}

.kanban-project-card__placeholder ion-icon {
    font-size: 1.6rem;
}

.kanban-action-link ion-icon {
    font-size: 14px;
}

.kanban-project-card__body {
    display: grid;
    gap: 8px;
    padding: 0 12px 12px;
}

.kanban-project-card__body h4 {
    margin: 0;
    font-size: 1rem;
    line-height: 1.3;
    color: var(--text-primary);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.kanban-project-card__stack {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    max-width: 100%;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.kanban-project-card__body p {
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.45;
    color: var(--text-secondary, #9ca3af);
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 3.9em;
}

.kanban-project-card__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 2px;
}

.kanban-action-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    border-radius: 10px;
    text-decoration: none;
    font-size: 12px;
    font-weight: 700;
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.9), rgba(14, 165, 233, 0.85));
    cursor: pointer;
}

.kanban-action-link--secondary {
    background: linear-gradient(135deg, rgba(236, 72, 153, 0.9), rgba(139, 92, 246, 0.85));
}

.kanban-action-link--ghost {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.03);
}

.kanban-project-card--empty {
    min-height: 180px;
    align-content: center;
    border-style: dashed;
    opacity: 0.88;
}

.kanban-project-card--empty .kanban-project-card__body {
    padding: 16px 14px;
}

[data-theme="light"] .key-projects-main {
    background:
        radial-gradient(130% 120% at 0% 0%, rgba(255, 86, 154, 0.1), transparent 58%),
        radial-gradient(130% 120% at 100% 100%, rgba(56, 189, 248, 0.1), transparent 58%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(247, 250, 255, 0.96));
    border-color: rgba(15, 23, 42, 0.08);
    box-shadow: 0 18px 34px rgba(15, 23, 42, 0.08);
}

[data-theme="light"] .key-projects-board__meta p,
[data-theme="light"] .kanban-column,
[data-theme="light"] .kanban-column__header,
[data-theme="light"] .kanban-column__count,
[data-theme="light"] .kanban-project-card,
[data-theme="light"] .kanban-project-card__stack,
[data-theme="light"] .kanban-action-link--ghost {
    border-color: rgba(15, 23, 42, 0.08);
}

[data-theme="light"] .kanban-column {
    background: rgba(255, 255, 255, 0.65);
}

[data-theme="light"] .kanban-column::before {
    background:
        linear-gradient(rgba(15, 23, 42, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(15, 23, 42, 0.03) 1px, transparent 1px);
}

[data-theme="light"] .key-projects-board__meta p {
    background: rgba(255, 255, 255, 0.75);
    color: #4b5563;
}

[data-theme="light"] .kanban-column__header {
    background: rgba(255, 255, 255, 0.7);
    border-bottom-color: rgba(15, 23, 42, 0.06);
}

[data-theme="light"] .kanban-column__header p {
    color: #4b5563;
}

[data-theme="light"] .kanban-column__count {
    color: #1f2937;
    background: rgba(255, 255, 255, 0.85);
    border-color: rgba(15, 23, 42, 0.1);
}

[data-theme="light"] .kanban-project-card {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(249, 251, 255, 0.96));
    box-shadow: 0 10px 18px rgba(15, 23, 42, 0.06);
}

[data-theme="light"] .kanban-project-card__media {
    background: #f8fafc;
    border-bottom-color: rgba(15, 23, 42, 0.06);
}

[data-theme="light"] .kanban-project-card__placeholder {
    color: rgba(15, 23, 42, 0.45);
    background:
        radial-gradient(circle at 20% 20%, rgba(255, 86, 154, 0.1), transparent 60%),
        radial-gradient(circle at 80% 80%, rgba(56, 189, 248, 0.12), transparent 60%),
        linear-gradient(180deg, #f8fafc, #eef4ff);
}

[data-theme="light"] .kanban-project-card__stack {
    background: rgba(15, 23, 42, 0.03);
}

[data-theme="light"] .kanban-action-link--ghost {
    background: rgba(15, 23, 42, 0.03);
}

[data-theme="light"] .kanban-column__eyebrow {
    color: #374151;
    background: rgba(255, 255, 255, 0.92);
    border-color: rgba(15, 23, 42, 0.08);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

[data-theme="light"] .kanban-column--shipped .kanban-column__eyebrow {
    color: #15803d;
    border-color: rgba(34, 197, 94, 0.22);
    background: linear-gradient(180deg, rgba(240, 253, 244, 0.95), rgba(220, 252, 231, 0.9));
}

[data-theme="light"] .kanban-column--building .kanban-column__eyebrow {
    color: #b45309;
    border-color: rgba(245, 158, 11, 0.25);
    background: linear-gradient(180deg, rgba(255, 251, 235, 0.96), rgba(254, 243, 199, 0.9));
}

[data-theme="light"] .kanban-column--planned .kanban-column__eyebrow {
    color: #1d4ed8;
    border-color: rgba(59, 130, 246, 0.24);
    background: linear-gradient(180deg, rgba(239, 246, 255, 0.97), rgba(219, 234, 254, 0.9));
}

.enable-animation {
    padding: 0;
}

/* Marquee styles */
.marquee {
    --gap: 1rem;
    position: relative;
    display: flex;
    overflow: hidden;
    user-select: none;
    gap: var(--gap);
}

.marquee__content {
    flex-shrink: 0;
    display: flex;
    justify-content: space-around;
    gap: var(--gap);
    min-width: 100%;
}

.marquee__content li {
    list-style-type: none;
}

@keyframes scroll {
    from {
        transform: translateX(0);
    }

    to {
        transform: translateX(calc(-100% - var(--gap)));
    }
}

/* Pause animation when reduced-motion is set */
@media (prefers-reduced-motion: reduce) {
    .marquee__content {
        animation-play-state: paused !important;
    }
}

/* Enable animation only when the marquee section is visible */
.enable-animation.is-animating .marquee__content {
    animation: scroll 14s linear infinite;
    will-change: transform;
}

/* Reverse animation */
.marquee--reverse .marquee__content {
    animation-direction: reverse;
}

/* Pause on hover */
.marquee--hover-pause:hover .marquee__content {
    animation-play-state: paused;
}

/* Attempt to size parent based on content. Keep in mind that the parent width is equal to both content containers that stretch to fill the parent. */
.marquee--fit-content {
    max-width: fit-content;
}

/* A fit-content sizing fix: Absolute position the duplicate container. This will set the size of the parent wrapper to a single child container. Shout out to Olavi's article that had this solution 👏 @link: https://olavihaapala.fi/2021/02/23/modern-marquee.html  */
.marquee--pos-absolute .marquee__content:last-child {
    position: absolute;
    top: 0;
    left: 0;
}

/* Enable position absolute animation on the duplicate content (last-child) */
.enable-animation .marquee--pos-absolute .marquee__content:last-child {
    animation-name: scroll-abs;
}

@keyframes scroll-abs {
    from {
        transform: translateX(calc(100% + var(--gap)));
    }

    to {
        transform: translateX(0);
    }
}

/* Other page demo styles */
.marquee__content>* {
    flex: 0 0 auto;
    color: white;
    margin: 2px;
    padding: 0 2rem;
    border-radius: 0.25rem;
    text-align: center;
}

.marquee__content img {
    width: 100px;
    height: 100px;
}

#profile-marquee-section {
    position: relative;
    width: min(92%, 1180px);
    margin: 26px auto 36px;
    padding: 16px;
    border-radius: 22px;
    overflow: hidden;
    background:
        radial-gradient(120% 120% at 0% 0%, color-mix(in srgb, var(--accent-color) 16%, transparent), transparent 58%),
        radial-gradient(120% 120% at 100% 100%, rgba(0, 209, 255, 0.12), transparent 62%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.01));
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.18);
    backdrop-filter: blur(8px);
}

#profile-marquee-section::before,
#profile-marquee-section::after {
    content: "";
    position: absolute;
    inset: auto auto 12px 12px;
    width: 140px;
    height: 140px;
    background: radial-gradient(circle, rgba(255, 94, 165, 0.18), transparent 72%);
    filter: blur(8px);
    pointer-events: none;
}

#profile-marquee-section::after {
    inset: 12px 12px auto auto;
    background: radial-gradient(circle, rgba(0, 200, 255, 0.16), transparent 72%);
}

#profile-marquee-section .tech-stack-showcase {
    position: relative;
    z-index: 1;
    display: grid;
    gap: 12px;
}

.tech-stack-showcase__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    padding: 4px 4px 2px;
}

.tech-stack-showcase__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #ffd6e8;
    background: linear-gradient(135deg, rgba(255, 86, 154, 0.26), rgba(75, 177, 255, 0.2));
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.tech-stack-showcase__eyebrow ion-icon {
    font-size: 14px;
}

.tech-stack-showcase__header h4 {
    margin: 8px 0 4px;
    font-size: 1.15rem;
    color: var(--text-primary);
}

.tech-stack-showcase__header p {
    margin: 0;
    color: var(--text-secondary, #9ca3af);
    font-size: 0.95rem;
}

.tech-stack-showcase__legend {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
    min-width: 160px;
}

.tech-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 7px 12px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    color: #fff;
    background: linear-gradient(135deg, rgba(255, 86, 154, 0.9), rgba(126, 69, 255, 0.8));
    box-shadow: 0 8px 18px rgba(255, 86, 154, 0.18);
}

.tech-pill--alt {
    background: linear-gradient(135deg, rgba(31, 174, 255, 0.9), rgba(37, 99, 235, 0.85));
    box-shadow: 0 8px 18px rgba(37, 99, 235, 0.18);
}

#profile-marquee-section .tech-stack-row {
    position: relative;
    border-radius: 18px;
    padding: 10px 12px 12px;
    overflow: hidden;
    isolation: isolate;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.015));
    border: 1px solid rgba(255, 255, 255, 0.06);
}

#profile-marquee-section .tech-stack-row::after {
    content: "";
    position: absolute;
    left: 12px;
    right: 12px;
    top: 40px;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.12), transparent);
}

#profile-marquee-section .tech-stack-row::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
    background-size: 18px 18px;
    mask-image: linear-gradient(to bottom, transparent, rgba(0, 0, 0, 0.7) 20%, rgba(0, 0, 0, 0.7) 80%, transparent);
    pointer-events: none;
    z-index: -1;
}

.tech-stack-row__label {
    display: inline-flex;
    align-items: center;
    margin-bottom: 10px;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.04em;
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

#profile-marquee-section .marquee {
    --gap: 0.9rem;
    padding: 2px 0;
}

#profile-marquee-section .tech-stack-row--languages .marquee {
    transform: rotate(-1deg);
    transform-origin: center;
}

#profile-marquee-section .tech-stack-row--frameworks .marquee {
    transform: rotate(1deg);
    transform-origin: center;
}

#profile-marquee-section .marquee__content {
    gap: var(--gap);
}

#profile-marquee-section .marquee__content>li {
    --tile-shift: 0px;
    position: relative;
    display: grid;
    place-items: center;
    width: 118px;
    height: 96px;
    min-width: 118px;
    margin: 0;
    padding: 10px 12px;
    border-radius: 10px;
    overflow: hidden;
    clip-path: polygon(14% 0, 86% 0, 100% 50%, 86% 100%, 14% 100%, 0 50%);
    border: 1px solid rgba(255, 255, 255, 0.07);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.065), rgba(255, 255, 255, 0.02)),
        rgba(15, 18, 28, 0.35);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.05),
        0 10px 20px rgba(0, 0, 0, 0.12);
    transform: translateY(var(--tile-shift));
    transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease, filter 0.25s ease;
}

#profile-marquee-section .marquee__content>li::before {
    content: "";
    position: absolute;
    inset: -20% auto auto -20%;
    width: 70px;
    height: 70px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.14), transparent 65%);
    pointer-events: none;
}

#profile-marquee-section .marquee__content>li::after {
    content: "";
    position: absolute;
    inset: 2px;
    clip-path: inherit;
    border: 1px solid rgba(255, 255, 255, 0.035);
    pointer-events: none;
}

#profile-marquee-section .marquee__content>li:nth-child(odd) {
    --tile-shift: -6px;
}

#profile-marquee-section .marquee__content>li:nth-child(even) {
    --tile-shift: 6px;
}

#profile-marquee-section .marquee__content>li:hover {
    transform: translateY(calc(var(--tile-shift) - 4px)) scale(1.01);
    border-color: rgba(255, 255, 255, 0.16);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        0 12px 24px rgba(0, 0, 0, 0.18);
    filter: saturate(1.08);
}

#profile-marquee-section .marquee__content img {
    width: 68px;
    height: 68px;
    object-fit: contain;
    filter: drop-shadow(0 5px 10px rgba(0, 0, 0, 0.18));
    transition: transform 0.25s ease;
}

#profile-marquee-section .marquee__content>li:hover img {
    transform: scale(1.05);
}

.tech-stack-row--languages .tech-stack-row__label {
    color: #ffd5ea;
    border-color: rgba(255, 86, 154, 0.2);
    background: rgba(255, 86, 154, 0.08);
}

.tech-stack-row--languages .marquee__content>li {
    border-color: rgba(255, 86, 154, 0.14);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.05),
        0 10px 20px rgba(0, 0, 0, 0.12),
        0 0 0 1px rgba(255, 86, 154, 0.04);
}

.tech-stack-row--frameworks .tech-stack-row__label {
    color: #d8eeff;
    border-color: rgba(31, 174, 255, 0.2);
    background: rgba(31, 174, 255, 0.08);
}

.tech-stack-row--frameworks .marquee__content>li {
    border-color: rgba(31, 174, 255, 0.14);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.05),
        0 10px 20px rgba(0, 0, 0, 0.12),
        0 0 0 1px rgba(31, 174, 255, 0.04);
}

[data-theme="light"] #profile-marquee-section {
    background:
        radial-gradient(130% 120% at 0% 0%, rgba(255, 86, 154, 0.12), transparent 56%),
        radial-gradient(130% 120% at 100% 100%, rgba(31, 174, 255, 0.12), transparent 56%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(246, 250, 255, 0.95));
    border-color: rgba(15, 23, 42, 0.1);
    box-shadow: 0 18px 38px rgba(15, 23, 42, 0.1);
}

[data-theme="light"] #profile-marquee-section .tech-stack-row {
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(245, 249, 255, 0.93));
    border-color: rgba(15, 23, 42, 0.08);
}

[data-theme="light"] #profile-marquee-section .tech-stack-row::before {
    background-image:
        linear-gradient(rgba(15, 23, 42, 0.045) 1px, transparent 1px),
        linear-gradient(90deg, rgba(15, 23, 42, 0.045) 1px, transparent 1px);
}

[data-theme="light"] #profile-marquee-section .tech-stack-row__label,
[data-theme="light"] #profile-marquee-section .marquee__content>li {
    border-color: rgba(15, 23, 42, 0.1);
}

[data-theme="light"] #profile-marquee-section .marquee__content>li {
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.99), rgba(243, 247, 255, 0.95)),
        rgba(255, 255, 255, 0.9);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.8),
        0 10px 18px rgba(15, 23, 42, 0.08);
}

[data-theme="light"] #profile-marquee-section .tech-stack-showcase__eyebrow {
    color: #b4236f;
    background: linear-gradient(135deg, rgba(255, 86, 154, 0.16), rgba(31, 174, 255, 0.1));
    border-color: rgba(180, 35, 111, 0.14);
}

[data-theme="light"] #profile-marquee-section .tech-stack-showcase__header h4 {
    color: #1f2937;
}

[data-theme="light"] #profile-marquee-section .tech-stack-showcase__header p {
    color: #4b5563;
}

[data-theme="light"] #profile-marquee-section .tech-stack-row::after {
    background: linear-gradient(90deg, transparent, rgba(15, 23, 42, 0.1), transparent);
}

[data-theme="light"] #profile-marquee-section .tech-pill {
    color: #fff;
    background: linear-gradient(135deg, #ef5da8, #8b5cf6);
    box-shadow: 0 10px 20px rgba(239, 93, 168, 0.2);
}

[data-theme="light"] #profile-marquee-section .tech-pill--alt {
    background: linear-gradient(135deg, #38bdf8, #2563eb);
    box-shadow: 0 10px 20px rgba(37, 99, 235, 0.18);
}

[data-theme="light"] #profile-marquee-section .tech-stack-row--languages .tech-stack-row__label {
    color: #b4236f;
    border-color: rgba(239, 93, 168, 0.2);
    background: rgba(239, 93, 168, 0.08);
}

[data-theme="light"] #profile-marquee-section .tech-stack-row--frameworks .tech-stack-row__label {
    color: #1d4ed8;
    border-color: rgba(56, 189, 248, 0.24);
    background: rgba(56, 189, 248, 0.08);
}

[data-theme="light"] #profile-marquee-section .tech-stack-row--languages .marquee__content>li {
    border-color: rgba(239, 93, 168, 0.14);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.92),
        0 10px 18px rgba(15, 23, 42, 0.07),
        0 0 0 1px rgba(239, 93, 168, 0.05);
}

[data-theme="light"] #profile-marquee-section .tech-stack-row--frameworks .marquee__content>li {
    border-color: rgba(37, 99, 235, 0.14);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.92),
        0 10px 18px rgba(15, 23, 42, 0.07),
        0 0 0 1px rgba(37, 99, 235, 0.05);
}

section {
    margin-block: 3rem;
}

section>*+* {
    margin-block-start: 0.5rem;
}

/* Reduce initial render work for lower sections on long profile pages */
#about,
#resume,
#key-projects,
#certifications,
#contact {
    content-visibility: auto;
    contain-intrinsic-size: 1px 700px;
}

/* Mobile responsiveness */
@media only screen and (max-width: 768px) {
    .marquee {
        gap: 0;
    }

    .marquee__content {
        gap: 0;
    }

    .enable-animation {
        border: none;
    }

    #key-projects {
        margin-top: 34px;
    }

    .key-projects-main {
        width: 100%;
        padding: 18px 12px 16px;
        border-radius: 16px;
    }

    .key-projects-main>h3 {
        font-size: 1.65rem;
        margin-bottom: 12px;
    }

    .key-projects-board__meta p {
        border-radius: 14px;
        font-size: 0.82rem;
        padding: 9px 12px;
        text-align: center;
    }

    .key-projects-kanban {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .kanban-column {
        border-radius: 14px;
    }

    .kanban-column__header {
        padding: 12px;
    }

    .kanban-column__header p {
        font-size: 0.8rem;
    }

    .kanban-column__cards {
        grid-auto-flow: column;
        grid-auto-columns: minmax(220px, 78%);
        overflow-x: auto;
        padding: 12px;
        gap: 10px;
        align-items: stretch;
        scroll-snap-type: x proximity;
    }

    .kanban-project-card {
        scroll-snap-align: start;
    }

    #portfolio {
        margin-top: 30px;
    }

    /* For tablets and smaller screens */
    #portfolio .project-image img {
        margin: 0;
    }

    #portfolio .project-image {
        width: 100%;
        margin: 0;
    }

    .cta-button {
        background-color: transparent !important;
        color: #333 !important;
        text-decoration: underline;
        padding: 0;
    }

    [data-theme="dark"] .cta-button {
        background-color: transparent !important;
        color: var(--accent-color) !important;
    }

    .carousel-card {
        flex: 0 0 100%;
        /* Display 1 card at a time (100% of the container width) */
        width: 100%;
        margin-right: 0;
    }

    .carousel-track-wrapper {
        width: 100%;
        padding: 0;
    }

    .carousel-button {
        font-size: 14px;
        padding: 5px 10px;
        margin: 5px;
    }

    .carousel-inner {
        margin-top: 20px;
    }

    .box-modal-container {
        overflow-y: auto;
    }

    .carousel-description #descriptionTitle {
        font-size: 16px;
    }

    .carousel-description #descriptionText {
        font-size: 15px;
    }

    .marquee__content {
        padding: 0;
        margin: 0;
    }

    #profile-marquee-section {
        width: 100%;
        margin: 20px auto 26px;
        padding: 12px;
        border-radius: 16px;
    }

    .tech-stack-showcase__header {
        flex-direction: column;
        gap: 10px;
        padding: 0;
    }

    .tech-stack-showcase__header h4 {
        font-size: 1rem;
    }

    .tech-stack-showcase__header p {
        font-size: 0.85rem;
    }

    .tech-stack-showcase__legend {
        justify-content: flex-start;
        min-width: 0;
    }

    #profile-marquee-section .tech-stack-row {
        padding: 9px 10px 10px;
        border-radius: 14px;
    }

    #profile-marquee-section .tech-stack-row::after {
        left: 10px;
        right: 10px;
    }

    #profile-marquee-section .tech-stack-row:first-of-type .marquee {
        padding: 2px 0 0;
        margin: 0;
    }

    #profile-marquee-section .tech-stack-row:last-of-type .marquee {
        padding: 2px 0 0;
        margin: 0;
    }

    #profile-marquee-section .marquee {
        --gap: 0.55rem;
    }

    #profile-marquee-section .tech-stack-row--languages .marquee,
    #profile-marquee-section .tech-stack-row--frameworks .marquee {
        transform: none;
    }

    #profile-marquee-section .marquee__content>li {
        width: 82px;
        min-width: 82px;
        height: 68px;
        padding: 7px;
    }

    #profile-marquee-section .marquee__content>li:nth-child(odd) {
        --tile-shift: -3px;
    }

    #profile-marquee-section .marquee__content>li:nth-child(even) {
        --tile-shift: 3px;
    }

    #profile-marquee-section .marquee__content img {
        width: 46px;
        height: 46px;
    }

    #portfolio .project-details {
        width: 100%;
        margin: auto;
    }

    #portfolio .project-details h3 {
        text-align: center;
    }
}

@media only screen and (max-width: 480px) {
    #profile-marquee-section {
        padding: 10px;
        border-radius: 14px;
    }

    .key-projects-main {
        padding: 16px 10px 14px;
        border-radius: 14px;
    }

    .key-projects-main>h3 {
        font-size: 1.4rem;
    }

    .kanban-column__header {
        padding: 10px;
    }

    .kanban-column__eyebrow {
        font-size: 11px;
        padding: 4px 8px;
    }

    .kanban-column__count {
        min-width: 30px;
        height: 30px;
        border-radius: 8px;
        font-size: 0.85rem;
    }

    .kanban-column__cards {
        grid-auto-columns: minmax(210px, 88%);
        padding: 10px;
    }

    .kanban-project-card__body {
        padding: 0 10px 10px;
    }

    .kanban-project-card__body p {
        -webkit-line-clamp: 2;
        min-height: 2.9em;
    }

    .kanban-action-link {
        padding: 6px 9px;
        font-size: 11px;
    }

    .tech-stack-showcase__eyebrow {
        font-size: 11px;
        padding: 4px 9px;
    }

    .tech-stack-showcase__header h4 {
        font-size: 0.95rem;
    }

    .tech-pill {
        padding: 6px 10px;
        font-size: 11px;
    }

    .tech-stack-row__label {
        font-size: 11px;
    }

    #profile-marquee-section .marquee__content>li {
        width: 72px;
        min-width: 72px;
        height: 60px;
        padding: 6px;
    }

    #profile-marquee-section .marquee__content>li:nth-child(odd),
    #profile-marquee-section .marquee__content>li:nth-child(even) {
        --tile-shift: 0px;
    }

    #profile-marquee-section .marquee__content img {
        width: 40px;
        height: 40px;
    }

    /* For mobile screens */
    #portfolio .project-image img {
        width: 90%;
        height: 250px;
    }

    #portfolio ul li {
        text-align: left;
    }

    #portfolio .project-details p,
    #portfolio ul li ul li {
        text-align: justify;
    }

    #portfolio .project-details p {
        font-size: 16px;
        color: var(--text-secondary, #555);
    }
}

.profile-name {
    margin: 15px 0;
    text-align: center;
    position: relative;
}

.profile-name h2 {
    margin: 0;
    line-height: 1;
    color: var(--text-primary);
}

.first-name {
    font-size: 2.5rem;
    font-weight: 300;
    letter-spacing: 3px;
    margin-bottom: 5px !important;
}

.last-name {
    font-size: 2.5rem;
    /* Reduced from 2.8rem */
    font-weight: 700;
    letter-spacing: 1px;
    /* Reduced from 2px */
    background: linear-gradient(45deg, var(--text-primary), var(--accent-color));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    max-width: 100%;
    /* Ensure text doesn't overflow */
    margin: 0 auto;
    padding: 0.1em 0;
    /* Add padding to prevent clipping */
    display: inline-block;
    /* Change to inline-block */
    white-space: nowrap;
    /* Prevent wrapping */
    overflow: visible;
    /* Allow overflow */
    height: auto;
    /* Auto height */
    line-height: 1.2;
    /* Adjust line height */
}

.name-underline {
    width: 60px;
    height: 4px;
    background: var(--accent-color);
    margin: 10px auto;
    position: relative;
}

.mobile-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    padding: 10px;
    color: var(--text-primary);
    cursor: pointer;
    width: 100%;
    border: none;
    background: transparent;
    margin-top: 10px;
}

.mobile-toggle .arrow-down {
    font-size: 24px;
    transition: transform 0.3s ease;
}

.collapsible-content {
    display: block;
    max-height: 1000px;
    opacity: 1;
    overflow: hidden;
    transition: max-height 1s ease-in-out, opacity 1s ease-in-out;
}

#certifications {
    text-align: center;
    margin: 50px auto;
    padding: 20px 20px 80px 20px;
}

#certifications h2 {
    font-size: 2rem;
    margin-bottom: 10px;
}

#certifications p {
    max-width: 600px;
    margin: 0 auto 30px;
}

.certification-images {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    /* 4 per row */
    gap: 20px;
    justify-items: center;
}

.certification-images img {
    width: 100%;
    max-width: 200px;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    cursor: pointer;
}

.certification-images img:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.2);
}

/* Skills Section */
#skills {
    text-align: center;
    padding: 40px 20px;
    background: var(--bg-secondary);
    border-radius: 10px;
    margin: 50px auto;
    width: 90%;
    max-width: 1100px;
}

#skills h2 {
    font-size: 2rem;
    margin-bottom: 25px;
    color: var(--text-primary);
}

.skills-tabs {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
    margin-bottom: 30px;
}

.skills-tabs .tab {
    background: var(--card-bg);
    border: 1px solid #ccc;
    border-radius: 25px;
    padding: 8px 20px;
    cursor: pointer;
    font-weight: 500;
    color: var(--text-primary);
    transition: all 0.3s ease;
}

.skills-tabs .tab.active {
    background: var(--accent-color);
    color: #fff;
    border: none;
}

/* --- Skills Container --- */
.skills-container {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    /* 2 cards per row */
    gap: 30px;
    justify-items: center;
    width: 100%;
    opacity: 0;
    position: relative;
    right: -40px;
    transition: all 1s ease;
    overflow: hidden;
}

/* Visible and animated */
.skills-container.active {
    opacity: 1;
    right: 0;
    display: grid;
}

/* --- Skills Card --- */
.skills-card {
    background: var(--card-bg);
    border-radius: 15px;
    padding: 25px 30px;
    width: 90%;
    max-width: 500px;
    text-align: left;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.skills-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.12);
}

.skills-card h3 {
    color: var(--text-primary);
    font-size: 1.3rem;
    margin-bottom: 15px;
}

/* --- Skill Item --- */
.skill {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin: 8px 0;
}

.skill span:first-child {
    flex: 1;
    font-weight: 500;
}

.skill span {
    font-weight: 600;
    color: var(--text-secondary);
}

.progress {
    flex: 2;
    background: #e5e7eb;
    border-radius: 10px;
    height: 8px;
    overflow: hidden;
}


.bar {
    height: 100%;
    background: linear-gradient(90deg, #4f46e5, #06b6d4);
    width: 0;
    border-radius: 10px;
    transition: width 1s ease-in-out;
}


.percent {
    flex-basis: 45px;
    text-align: right;
    font-size: 0.9rem;
    color: #4b5563;
}

.hidden {
    display: none;
}

.contact-header {
    display: flex;
    align-items: center;
    gap: 5px;
}

/* Responsive breakpoints */
@media (max-width: 992px) {
    .certification-images {
        grid-template-columns: repeat(3, 1fr);
    }

    .skills-container {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
}

@media only screen and (max-width: 768px) {
    #skills {
        padding: 30px 15px;
        width: 95%;
    }

    .skills-container {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .skills-card {
        width: 100%;
        padding: 20px;
    }

    .skills-card h3 {
        font-size: 1.1rem;
    }

    .skill span,
    .percent {
        font-size: 0.9rem;
    }

    .mobile-toggle {
        display: flex;
    }

    .collapsible-content {
        max-height: 0;
        opacity: 0;
        overflow: hidden;
        display: none;
        transition: all 0.3s ease;
    }

    .collapsible-content.show {
        max-height: 1000px;
        opacity: 1;
        display: block;
    }

    .first-name {
        font-size: 2rem;
    }

    .last-name {
        font-size: 2.3rem;
    }

    .certification-images {
        grid-template-columns: repeat(2, 1fr);
    }

    .certification-images img {
        width: 100%;
        max-width: 500px;
    }

}

@media (max-width: 480px) {
    .certification-images {
        grid-template-columns: 1fr;
    }

    #skills h2 {
        font-size: 1.6rem;
    }

    .skills-card {
        padding: 15px;
    }

    .skills-card h3 {
        font-size: 1rem;
    }
}

/* Profile section surfaces (match Key Projects visual language) */
#portfolio,
#about,
#resume,
#certifications,
#contact {
    width: min(96%, 1280px);
    margin: 48px auto 0;
    padding: 26px 22px;
    border-radius: 22px;
    position: relative;
    isolation: isolate;
    background:
        radial-gradient(120% 110% at 0% 0%, rgba(255, 255, 255, 0.02), transparent 55%),
        radial-gradient(120% 110% at 100% 100%, rgba(255, 255, 255, 0.015), transparent 55%),
        linear-gradient(180deg, rgba(10, 10, 12, 0.95), rgba(14, 14, 17, 0.94));
    border: 1px solid rgba(255, 255, 255, 0.06);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.03),
        0 18px 32px rgba(0, 0, 0, 0.28);
}

#portfolio::before,
#about::before,
#resume::before,
#certifications::before,
#contact::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
    background:
        linear-gradient(rgba(255, 255, 255, 0.012) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.012) 1px, transparent 1px);
    background-size: 20px 20px;
    opacity: 0.35;
    z-index: 0;
}

#portfolio > *,
#about > *,
#resume > *,
#certifications > *,
#contact > * {
    position: relative;
    z-index: 1;
}

/* Normalize profile section mic buttons so About/Resume/Contact match Summary */
#portfolio .voice-icon,
#about .voice-icon,
#resume .voice-icon,
#contact .voice-icon {
    position: absolute;
    top: 12px;
    right: 12px;
    bottom: auto;
    left: auto;
    width: 42px;
    height: 42px;
    padding: 3px;
    margin: 0;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    background:
        radial-gradient(120% 120% at 20% 15%, rgba(255, 86, 154, 0.14), transparent 58%),
        radial-gradient(120% 120% at 100% 100%, rgba(56, 189, 248, 0.14), transparent 60%),
        rgba(15, 15, 19, 0.86);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        0 10px 20px rgba(0, 0, 0, 0.24);
    backdrop-filter: blur(6px);
    object-fit: cover;
    z-index: 3;
}

#portfolio .voice-icon:hover,
#about .voice-icon:hover,
#resume .voice-icon:hover,
#contact .voice-icon:hover {
    border-color: rgba(59, 130, 246, 0.28);
}

@media only screen and (max-width: 768px) {
    #portfolio .voice-icon,
    #about .voice-icon,
    #resume .voice-icon,
    #contact .voice-icon {
        top: 10px;
        right: 10px;
        width: 38px;
        height: 38px;
        padding: 3px;
    }
}

#about > h2,
#resume > h2,
#certifications > h2,
#contact > h2 {
    margin: 0 0 8px;
    font-size: clamp(1.65rem, 2vw, 2.15rem);
    color: var(--text-primary);
    letter-spacing: -0.02em;
}

#about > p,
#resume > p,
#certifications > p,
#contact > p {
    margin: 0 0 16px;
    color: var(--text-secondary, #9ca3af);
    line-height: 1.6;
}

/* Summary / hero panel */
#portfolio {
    align-items: stretch;
    gap: 22px;
}

#portfolio .project-image {
    flex: 0 0 min(360px, 36%);
    margin-right: 0;
    padding: 16px;
    border-radius: 18px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    background:
        radial-gradient(120% 110% at 0% 0%, rgba(255, 255, 255, 0.015), transparent 55%),
        linear-gradient(180deg, rgba(16, 16, 20, 0.92), rgba(20, 20, 24, 0.9));
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.02),
        0 10px 22px rgba(0, 0, 0, 0.22);
}

#portfolio .project-image img {
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 14px 26px rgba(0, 0, 0, 0.25);
}

#portfolio .project-image h1 {
    margin: 14px 0 0;
    font-size: 1.2rem;
    color: var(--text-secondary, #cbd5e1);
    letter-spacing: 0.02em;
}

#portfolio .project-details {
    flex: 1 1 auto;
    max-width: none;
    padding: 16px 18px;
    border-radius: 18px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    background:
        radial-gradient(120% 110% at 100% 0%, rgba(255, 255, 255, 0.015), transparent 55%),
        linear-gradient(180deg, rgba(16, 16, 20, 0.9), rgba(20, 20, 24, 0.88));
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.02),
        0 10px 22px rgba(0, 0, 0, 0.22);
}

#portfolio .project-details h3 {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 10px;
    padding: 6px 12px;
    border-radius: 999px;
    font-size: 0.95rem;
    letter-spacing: 0.02em;
    border: 1px solid rgba(255, 255, 255, 0.09);
    background: linear-gradient(135deg, rgba(255, 86, 154, 0.14), rgba(56, 189, 248, 0.12));
}

#portfolio .project-details p {
    line-height: 1.7;
}

/* About / Resume / Contact lists become cards */
#about > ul,
#resume > ul,
#contact > ul {
    display: grid;
    gap: 12px;
    margin: 14px 0 0;
}

#about > ul > li,
#resume > ul > li,
#contact > ul > li {
    margin: 0;
    padding: 14px 16px;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    background:
        radial-gradient(120% 110% at 0% 0%, rgba(255, 255, 255, 0.012), transparent 55%),
        linear-gradient(180deg, rgba(16, 16, 20, 0.88), rgba(20, 20, 24, 0.86));
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.02),
        0 10px 22px rgba(0, 0, 0, 0.18);
}

#about > ul > li:nth-child(odd) {
    box-shadow: inset 3px 0 0 rgba(255, 86, 154, 0.22);
}

#about > ul > li:nth-child(even),
#contact > ul > li {
    box-shadow: inset 3px 0 0 rgba(56, 189, 248, 0.2);
}

#resume > ul > li {
    box-shadow: inset 3px 0 0 rgba(250, 204, 21, 0.22);
}

#about > ul > li > b,
#contact > ul > li b {
    color: var(--text-primary);
}

#about > ul > li > ul,
#resume > ul > li > ul,
#contact > ul > li > ul {
    margin-top: 8px;
}

#about > ul > li > ul > li,
#resume > ul > li > ul > li,
#contact > ul > li > ul > li {
    line-height: 1.6;
    color: var(--text-secondary, #cbd5e1);
}

#resume > ul > li {
    color: var(--text-primary);
    font-weight: 600;
}

#resume > ul > li > ul > li {
    font-weight: 400;
}

#resume > p:last-of-type {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 12px;
    padding: 12px 14px;
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    background:
        radial-gradient(120% 110% at 100% 0%, rgba(255, 255, 255, 0.012), transparent 55%),
        linear-gradient(180deg, rgba(16, 16, 20, 0.88), rgba(20, 20, 24, 0.86));
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.02),
        0 10px 22px rgba(0, 0, 0, 0.18);
}

#resume > p:last-of-type > a:first-child {
    color: var(--text-secondary, #cbd5e1);
}

#resume .cta-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8px 14px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: linear-gradient(135deg, rgba(255, 86, 154, 0.95), rgba(59, 130, 246, 0.95));
    color: #fff;
    text-decoration: none;
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.18);
}

#resume .cta-button:hover {
    filter: brightness(1.05);
}

/* Certifications */
#certifications {
    text-align: center;
    padding-bottom: 28px;
}

#certifications > p {
    max-width: 720px;
    margin-left: auto;
    margin-right: auto;
}

.certification-images {
    margin-top: 14px;
    gap: 16px;
}

.certification-images img {
    padding: 6px;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.07);
    background:
        radial-gradient(120% 110% at 0% 0%, rgba(255, 255, 255, 0.014), transparent 55%),
        linear-gradient(180deg, rgba(16, 16, 20, 0.9), rgba(20, 20, 24, 0.88));
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.02),
        0 10px 22px rgba(0, 0, 0, 0.22);
}

/* Contact */
#contact .contact-header {
    gap: 8px;
    font-size: 1rem;
}

#contact .contact-header ion-icon {
    font-size: 1.1rem;
    color: #60a5fa;
}

#contact ul ul li a {
    display: inline-block;
    max-width: 100%;
    padding: 7px 11px;
    border-radius: 10px;
    border: 1px solid rgba(56, 189, 248, 0.18);
    background: rgba(56, 189, 248, 0.035);
    color: #93c5fd;
    word-break: break-word;
    overflow-wrap: anywhere;
}

/* Light theme tuning for the same palette */
[data-theme="light"] #portfolio,
[data-theme="light"] #about,
[data-theme="light"] #resume,
[data-theme="light"] #certifications,
[data-theme="light"] #contact {
    background:
        radial-gradient(130% 120% at 0% 0%, rgba(244, 63, 94, 0.085), transparent 58%),
        radial-gradient(120% 110% at 100% 0%, rgba(236, 72, 153, 0.065), transparent 55%),
        radial-gradient(130% 120% at 100% 100%, rgba(251, 113, 133, 0.05), transparent 58%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.965), rgba(255, 248, 250, 0.955));
    border-color: rgba(15, 23, 42, 0.08);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.92),
        0 18px 32px rgba(15, 23, 42, 0.08);
}

[data-theme="light"] #portfolio::before,
[data-theme="light"] #about::before,
[data-theme="light"] #resume::before,
[data-theme="light"] #certifications::before,
[data-theme="light"] #contact::before {
    background:
        linear-gradient(rgba(15, 23, 42, 0.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(15, 23, 42, 0.025) 1px, transparent 1px);
    opacity: 0.55;
}

[data-theme="light"] #portfolio .project-image,
[data-theme="light"] #portfolio .project-details,
[data-theme="light"] #about > ul > li,
[data-theme="light"] #resume > ul > li,
[data-theme="light"] #contact > ul > li,
[data-theme="light"] #resume > p:last-of-type,
[data-theme="light"] .certification-images img {
    background:
        radial-gradient(130% 120% at 0% 0%, rgba(244, 114, 182, 0.05), transparent 62%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(255, 248, 251, 0.94));
    border-color: rgba(15, 23, 42, 0.08);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.88),
        0 10px 20px rgba(15, 23, 42, 0.06);
}

[data-theme="light"] #portfolio .voice-icon,
[data-theme="light"] #about .voice-icon,
[data-theme="light"] #resume .voice-icon,
[data-theme="light"] #contact .voice-icon {
    border-color: rgba(15, 23, 42, 0.12);
    background:
        radial-gradient(120% 120% at 20% 15%, rgba(244, 114, 182, 0.16), transparent 58%),
        radial-gradient(120% 120% at 100% 100%, rgba(59, 130, 246, 0.14), transparent 60%),
        rgba(255, 255, 255, 0.9);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.95),
        0 8px 16px rgba(15, 23, 42, 0.10);
}

[data-theme="light"] #portfolio .project-image h1,
[data-theme="light"] #about > p,
[data-theme="light"] #resume > p,
[data-theme="light"] #certifications > p,
[data-theme="light"] #contact > p,
[data-theme="light"] #portfolio .project-details p,
[data-theme="light"] #about > ul > li > ul > li,
[data-theme="light"] #resume > ul > li > ul > li,
[data-theme="light"] #contact > ul > li > ul > li,
[data-theme="light"] #resume > p:last-of-type > a:first-child {
    color: #4b5563;
}

[data-theme="light"] #portfolio .project-details h3 {
    color: #1f2937;
    border-color: rgba(15, 23, 42, 0.08);
    background: linear-gradient(135deg, rgba(236, 72, 153, 0.11), rgba(59, 130, 246, 0.11));
}

[data-theme="light"] #contact .contact-header ion-icon {
    color: #2563eb;
}

[data-theme="light"] #contact ul ul li a {
    color: #1d4ed8;
    border-color: rgba(59, 130, 246, 0.18);
    background: rgba(59, 130, 246, 0.06);
}

[data-theme="light"] #resume .cta-button {
    color: #fff !important;
    background: linear-gradient(135deg, #ec4899, #3b82f6) !important;
    border-color: rgba(255, 255, 255, 0.45);
    text-decoration: none;
}

@media only screen and (max-width: 768px) {
    #portfolio,
    #about,
    #resume,
    #certifications,
    #contact {
        width: 100%;
        margin-top: 28px;
        padding: 16px 12px;
        border-radius: 16px;
    }

    #portfolio {
        gap: 14px;
        flex-direction: column;
        align-items: stretch;
    }

    #portfolio .project-image,
    #portfolio .project-details {
        width: 100%;
        padding: 12px;
        border-radius: 14px;
    }

    #portfolio .project-details h3 {
        margin-bottom: 8px;
        font-size: 0.9rem;
        padding: 5px 10px;
    }

    #about > ul,
    #resume > ul,
    #contact > ul {
        gap: 10px;
    }

    #about > ul > li,
    #resume > ul > li,
    #contact > ul > li {
        padding: 12px;
        border-radius: 14px;
    }

    #resume > p:last-of-type {
        align-items: flex-start;
        padding: 10px 12px;
        border-radius: 12px;
    }

    #resume .cta-button {
        padding: 8px 12px;
        border-radius: 10px;
        background: linear-gradient(135deg, #ec4899, #3b82f6) !important;
        color: #fff !important;
        text-decoration: none;
    }

    #contact ul ul li a {
        width: 100%;
    }
}

@media (max-width: 480px) {
    #about > h2,
    #resume > h2,
    #certifications > h2,
    #contact > h2 {
        font-size: 1.5rem;
    }

    #portfolio .project-details h3 {
        display: inline-flex;
        max-width: 100%;
    }

    .certification-images {
        gap: 12px;
    }
}

/* Skills section: neutral dark surface (avoid bluish cast) */
[data-theme="dark"] #portfolio,
[data-theme="dark"] #about,
[data-theme="dark"] #resume,
[data-theme="dark"] #contact {
    background:
        radial-gradient(120% 120% at 0% 0%, rgba(236, 72, 153, 0.12), transparent 52%),
        radial-gradient(110% 120% at 100% 0%, rgba(59, 130, 246, 0.1), transparent 50%),
        radial-gradient(130% 120% at 100% 100%, rgba(34, 211, 238, 0.12), transparent 54%),
        radial-gradient(110% 120% at 8% 92%, rgba(244, 114, 182, 0.08), transparent 48%),
        linear-gradient(180deg, rgba(14, 15, 19, 0.96), rgba(17, 18, 23, 0.95));
    border-color: rgba(255, 255, 255, 0.07);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.03),
        0 18px 32px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] #portfolio::before,
[data-theme="dark"] #about::before,
[data-theme="dark"] #resume::before,
[data-theme="dark"] #contact::before {
    background:
        linear-gradient(rgba(255, 255, 255, 0.014) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.014) 1px, transparent 1px);
    opacity: 0.38;
}

[data-theme="dark"] #portfolio .project-image,
[data-theme="dark"] #portfolio .project-details,
[data-theme="dark"] #about > ul > li,
[data-theme="dark"] #resume > ul > li,
[data-theme="dark"] #contact > ul > li,
[data-theme="dark"] #resume > p:last-of-type {
    background:
        radial-gradient(120% 110% at 0% 0%, rgba(59, 130, 246, 0.04), transparent 60%),
        radial-gradient(120% 110% at 100% 100%, rgba(236, 72, 153, 0.04), transparent 60%),
        linear-gradient(180deg, rgba(16, 16, 20, 0.92), rgba(20, 20, 24, 0.9));
    border-color: rgba(255, 255, 255, 0.08);
}

[data-theme="dark"] #certifications {
    background:
        radial-gradient(120% 120% at 0% 0%, rgba(236, 72, 153, 0.12), transparent 52%),
        radial-gradient(110% 120% at 100% 0%, rgba(59, 130, 246, 0.1), transparent 50%),
        radial-gradient(130% 120% at 100% 100%, rgba(34, 211, 238, 0.12), transparent 54%),
        radial-gradient(110% 120% at 8% 92%, rgba(244, 114, 182, 0.08), transparent 48%),
        linear-gradient(180deg, rgba(14, 15, 19, 0.96), rgba(17, 18, 23, 0.95));
    border: 1px solid rgba(255, 255, 255, 0.07);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.03),
        0 18px 32px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] #certifications::before {
    background:
        linear-gradient(rgba(255, 255, 255, 0.014) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.014) 1px, transparent 1px);
    opacity: 0.38;
}

[data-theme="dark"] .certification-images img {
    background:
        radial-gradient(120% 110% at 0% 0%, rgba(59, 130, 246, 0.04), transparent 60%),
        radial-gradient(120% 110% at 100% 100%, rgba(236, 72, 153, 0.04), transparent 60%),
        linear-gradient(180deg, rgba(16, 16, 20, 0.92), rgba(20, 20, 24, 0.9));
    border-color: rgba(255, 255, 255, 0.08);
}

[data-theme="dark"] #skills {
    background:
        radial-gradient(120% 120% at 0% 0%, rgba(236, 72, 153, 0.12), transparent 52%),
        radial-gradient(110% 120% at 100% 0%, rgba(59, 130, 246, 0.1), transparent 50%),
        radial-gradient(130% 120% at 100% 100%, rgba(34, 211, 238, 0.12), transparent 54%),
        radial-gradient(110% 120% at 8% 92%, rgba(244, 114, 182, 0.08), transparent 48%),
        linear-gradient(180deg, rgba(14, 15, 19, 0.96), rgba(17, 18, 23, 0.95));
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.03),
        0 18px 32px rgba(0, 0, 0, 0.28);
}

[data-theme="dark"] .skills-tabs .tab {
    background: rgba(18, 18, 22, 0.92);
    border-color: rgba(255, 255, 255, 0.12);
    color: rgba(255, 255, 255, 0.92);
}

[data-theme="dark"] .skills-tabs .tab:hover {
    border-color: rgba(255, 255, 255, 0.2);
    background: rgba(22, 22, 26, 0.96);
}

[data-theme="dark"] .skills-tabs .tab.active {
    border: 1px solid rgba(59, 130, 246, 0.35);
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.2);
}

[data-theme="dark"] .skills-card {
    background:
        linear-gradient(180deg, rgba(16, 16, 20, 0.96), rgba(20, 20, 24, 0.94));
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.02),
        0 10px 22px rgba(0, 0, 0, 0.22);
}

[data-theme="dark"] .skills-card:hover {
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.03),
        0 14px 28px rgba(0, 0, 0, 0.26);
}

[data-theme="dark"] .progress {
    background: rgba(255, 255, 255, 0.12);
}

[data-theme="dark"] .percent {
    color: rgba(255, 255, 255, 0.7);
}

/* Final mobile width normalization for profile sections */
@media only screen and (max-width: 768px) {
    #portfolio,
    #about,
    #resume,
    #key-projects,
    #certifications,
    #contact,
    #profile-marquee-section,
    .key-projects-main,
    #skills {
        width: 100%;
        max-width: none;
        box-sizing: border-box;
    }

    #profile-marquee-section,
    .key-projects-main,
    #skills {
        border-radius: 16px;
        overflow: hidden;
    }

    #skills {
        margin: 28px auto 0;
        padding: 16px 12px;
    }

    .skills-container {
        width: 100%;
        min-width: 0;
    }

    .skills-card {
        width: 100%;
        max-width: none;
        min-width: 0;
        box-sizing: border-box;
    }

    #portfolio .project-image,
    #portfolio .project-details {
        box-sizing: border-box;
        min-width: 0;
    }

    #contact > ul > li,
    #contact > ul > li > ul,
    #contact > ul > li > ul > li {
        min-width: 0;
    }

    #contact > ul > li > ul {
        padding-left: 0;
        margin-left: 0;
        list-style: none;
    }

    #contact > ul > li > ul > li {
        list-style: none;
        margin-left: 0;
        padding-left: 0;
    }

    #contact ul ul li a {
        display: block;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
        line-height: 1.45;
    }
}

@media only screen and (max-width: 480px) {
    #profile-marquee-section,
    .key-projects-main,
    #skills,
    #portfolio,
    #about,
    #resume,
    #certifications,
    #contact {
        border-radius: 14px;
    }

    #portfolio .project-image img {
        width: 100%;
        max-width: 100%;
        height: auto;
    }
}

/* Reusable mobile image slider (enhances image grids on small screens) */
.mobile-image-slider {
    width: 100%;
}

.mobile-image-slider__controls,
.mobile-image-slider__dots {
    display: none;
}

[data-theme="light"] .mobile-image-slider__btn {
    border-color: rgba(15, 23, 42, 0.12);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(248, 250, 252, 0.92));
    color: #0f172a;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.95),
        0 6px 14px rgba(15, 23, 42, 0.06);
}

[data-theme="light"] .mobile-image-slider__btn:hover:not(:disabled) {
    border-color: rgba(59, 130, 246, 0.28);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(241, 245, 249, 0.96));
}

[data-theme="light"] .mobile-image-slider__counter {
    color: rgba(15, 23, 42, 0.65);
}

[data-theme="light"] .mobile-image-slider__dot {
    background: rgba(15, 23, 42, 0.16);
}

[data-theme="light"] .mobile-image-slider__dot.is-active {
    background: #2563eb;
}

@media only screen and (max-width: 768px) {
    [data-mobile-slider].mobile-image-slider__track {
        display: flex;
        grid-template-columns: none;
        gap: 12px;
        justify-items: stretch;
        align-items: stretch;
        overflow-x: auto;
        overflow-y: hidden;
        padding: 4px 2px 6px;
        scroll-snap-type: x mandatory;
        scroll-behavior: smooth;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    [data-mobile-slider].mobile-image-slider__track::-webkit-scrollbar {
        display: none;
    }

    [data-mobile-slider].mobile-image-slider__track>.mobile-image-slider__slide {
        flex: 0 0 100%;
        min-width: 100%;
        max-width: 100%;
        scroll-snap-align: center;
        scroll-snap-stop: always;
    }

    .kanban-column .mobile-image-slider {
        position: relative;
        z-index: 1;
        padding: 0 12px 12px;
    }

    .kanban-column .kanban-column__cards[data-mobile-slider].mobile-image-slider__track {
        padding: 0;
        gap: 10px;
    }

    .kanban-column .kanban-column__cards[data-mobile-slider].mobile-image-slider__track>.mobile-image-slider__slide {
        flex: 0 0 100%;
        min-width: 100%;
        max-width: 100%;
        scroll-snap-align: center;
    }

    .mobile-image-slider__controls {
        display: grid;
        grid-template-columns: auto 1fr auto;
        align-items: center;
        gap: 10px;
        margin-top: 10px;
    }

    .mobile-image-slider__btn {
        border: 1px solid rgba(255, 255, 255, 0.16);
        background: rgba(17, 24, 39, 0.72);
        color: var(--text-primary);
        border-radius: 999px;
        min-width: 70px;
        min-height: 34px;
        padding: 0 12px;
        font-weight: 600;
        cursor: pointer;
        transition: transform 0.2s ease, border-color 0.2s ease, opacity 0.2s ease;
    }

    .mobile-image-slider__btn:hover:not(:disabled) {
        transform: translateY(-1px);
        border-color: rgba(59, 130, 246, 0.4);
    }

    .mobile-image-slider__btn:disabled {
        opacity: 0.45;
        cursor: not-allowed;
    }

    .mobile-image-slider__counter {
        text-align: center;
        font-size: 0.9rem;
        color: var(--text-secondary);
        white-space: nowrap;
    }

    .mobile-image-slider__dots {
        display: flex;
        justify-content: center;
        align-items: center;
        gap: 8px;
        margin-top: 10px;
    }

    .mobile-image-slider__dot {
        width: 8px;
        height: 8px;
        padding: 0;
        border: 0;
        border-radius: 999px;
        background: rgba(255, 255, 255, 0.24);
        cursor: pointer;
        transition: transform 0.2s ease, background-color 0.2s ease, width 0.2s ease;
    }

    .mobile-image-slider__dot.is-active {
        width: 18px;
        background: #3b82f6;
        transform: scale(1.02);
    }
}

@media only screen and (max-width: 480px) {
    .kanban-column .mobile-image-slider {
        padding: 0 10px 10px;
    }

    .kanban-column .kanban-column__cards[data-mobile-slider].mobile-image-slider__track>.mobile-image-slider__slide {
        flex-basis: 100%;
        min-width: 100%;
        max-width: 100%;
    }

    .mobile-image-slider__btn {
        min-width: 64px;
        min-height: 32px;
        padding: 0 10px;
        font-size: 0.85rem;
    }

    .mobile-image-slider__counter {
        font-size: 0.85rem;
    }
}
